mirror of
https://gitee.com/java110/PropertyApp.git
synced 2026-02-23 21:36:39 +08:00
优化代码
This commit is contained in:
parent
246cc5625d
commit
1776347723
@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="select-single-resource" v-if="showModel">
|
<view class="select-single-resource" v-if="showModel">
|
||||||
<view>
|
<view>
|
||||||
<view class="cu-form-group margin-top">
|
<!-- <view class="cu-form-group margin-top">
|
||||||
<view class="title">公司</view>
|
<view class="title">公司</view>
|
||||||
<picker :value="orgIndex" :range="orgCloums" :range-key="'orgName'" @change="orgChange">
|
<picker :value="orgIndex" :range="orgCloums" :range-key="'orgName'" @change="orgChange">
|
||||||
<view class="picker">
|
<view class="picker">
|
||||||
@ -16,7 +16,7 @@
|
|||||||
{{depCloums[depIndex].orgName}}
|
{{depCloums[depIndex].orgName}}
|
||||||
</view>
|
</view>
|
||||||
</picker>
|
</picker>
|
||||||
</view>
|
</view> -->
|
||||||
<view class="cu-form-group margin-top">
|
<view class="cu-form-group margin-top">
|
||||||
<view class="title">员工</view>
|
<view class="title">员工</view>
|
||||||
<picker :value="staffIndex" :range="staffCloums" :range-key="'name'" @change="staffChange">
|
<picker :value="staffIndex" :range="staffCloums" :range-key="'name'" @change="staffChange">
|
||||||
@ -80,7 +80,8 @@
|
|||||||
|
|
||||||
mounted() {
|
mounted() {
|
||||||
this.communityId = getCurrentCommunity().communityId;
|
this.communityId = getCurrentCommunity().communityId;
|
||||||
this._loadOrgList();
|
//this._loadOrgList();
|
||||||
|
this._loadStaffList();
|
||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
@ -123,9 +124,9 @@
|
|||||||
let _data = {
|
let _data = {
|
||||||
page: 1,
|
page: 1,
|
||||||
row: 50,
|
row: 50,
|
||||||
parentOrgId: this.selectedOrg.orgId,
|
// parentOrgId: this.selectedOrg.orgId,
|
||||||
departmentOrgId: this.selectedDep.orgId,
|
// departmentOrgId: this.selectedDep.orgId,
|
||||||
orgId: this.selectedDep.orgId,
|
// orgId: this.selectedDep.orgId,
|
||||||
communityId: this.communityId,
|
communityId: this.communityId,
|
||||||
};
|
};
|
||||||
queryStaffListInfo(this, _data)
|
queryStaffListInfo(this, _data)
|
||||||
@ -170,7 +171,7 @@
|
|||||||
staffChange: function(e){
|
staffChange: function(e){
|
||||||
this.staffIndex = e.target.value //取其下标
|
this.staffIndex = e.target.value //取其下标
|
||||||
this.selectedStaff = '';
|
this.selectedStaff = '';
|
||||||
if (this.orgIndex == 0) {
|
if (this.staffIndex == 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
let selected = this.staffCloums[this.staffIndex] //获取选中的数组
|
let selected = this.staffCloums[this.staffIndex] //获取选中的数组
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user