避免空值报错
This commit is contained in:
@@ -158,6 +158,14 @@ class ReceivableReport extends Component {
|
||||
|
||||
async onUpdateCompany(v) {
|
||||
console.log(v)
|
||||
// 检查v是否为空或v[0]不存在
|
||||
if (!v || !v[0]) {
|
||||
this.state.selectCompany = {};
|
||||
this.state.selectPartner = {};
|
||||
this.state.domainUsers = [];
|
||||
await this.onSearch();
|
||||
return;
|
||||
}
|
||||
// 执行一次 查询
|
||||
// 通过 read 重新查询一次, 更多只返回了 id
|
||||
let values = await this.serviceOrm.call(
|
||||
|
||||
Reference in New Issue
Block a user