Przeglądaj źródła

Merge remote-tracking branch 'origin/master'

liuwenxun 4 lat temu
rodzic
commit
7e018c0902

+ 23 - 1
security-protection-platform/src/api/common/index.js

@ -19,7 +19,29 @@ const api = {
19 19
      return resp
20 20
    })
21 21
  },
22
22
  // 获取公司类型列表
23
  getCompanyTypesList () {
24
    return $default.get('/sp/employeeManagement/queryCompanyList').then(resp => {
25
      return resp
26
    }).catch((err) => { return err })
27
  },
28
  // 获取部门类型列表
29
  queryCycleChildOrg (id) {
30
    return $default.get(`/sp/employeeManagement/queryCycleChildOrg?orgId=${id}`).then(resp => {
31
      const data = resp.data.data
32
      if (!Array.isArray(data)) return resp
33
      // 将平铺的数组变为树形数组
34
      resp.data = nest(data)
35
      return resp
36
    }).catch((err) => { return err })
37
  },
38
  // 获取员工列表
39
  getStaffTypesList (id) {
40
    return $default.get(`/sp/employeeManagement/queryEmployeeListByOrgId?orgId=${id}`).then(resp => {
41
      return resp
42
    }).catch((err) => { return err })
43
  },
44
  // 查询单个用户信息详情
23 45
  getEmployeeByOrgid (orgId) {
24 46
    return $default
25 47
      .get(`/sp/workEmployee/queryEmployeeByOrg?orgId=${orgId}`)

+ 3 - 0
security-protection-platform/src/api/system/index.js

@ -187,6 +187,9 @@ const api = {
187 187
  },
188 188
  getDepartments() {
189 189
    return $default.get('/sp/workEmployee/queryAllOrganize')
190
  },
191
  getListFileUrl(data) {
192
    return $default.get(`/sp/uploadFile/getListFileUrl?fileNameList=${data.join(',')}`)
190 193
  }
191 194
}
192 195

+ 16 - 4
security-protection-platform/src/modules/attendance/abnormal/index.vue

@ -8,7 +8,7 @@
8 8
        </div>
9 9
        <div class="keep-row">
10 10
          <span>部门/员工:</span>
11
          <dept-staff-cascader v-model="form" @inited="handleInited" />
11
          <dept-staff-cascader v-model="form" @inited="handleInited" @getOrgId="getDailyOrgId" @getDepId="getDailyDepId" @getStaffId="getDailyStaffId" />
12 12
        </div>
13 13
        <div class="search-btn">
14 14
          <t-button color="primary" @click="handSearchAttendance">查询</t-button>
@ -84,11 +84,14 @@ export default {
84 84
    const now = new Date()
85 85
    return {
86 86
      form: {
87
        month: formatDateTime(new Date().setMonth(now.getMonth() - 1), 'yyyy-MM'),
88
        userid: null,
89
        depId: '',
90
        orgId: '',
87 91
        current: 1,
88
        pageSize: 10,
89
        month: formatDateTime(now.setMonth(now.getMonth() - 1), 'yyyy-MM')
92
        pageSize: 10
90 93
      },
91
      total: 40,
94
      total: 0,
92 95
      attendanceModal: false,
93 96
      agreement: '',
94 97
      tableData: [],
@ -98,6 +101,15 @@ export default {
98 101
    }
99 102
  },
100 103
  methods: {
104
    getDailyOrgId(id) {
105
      this.form.orgId = id
106
    },
107
    getDailyDepId(id) {
108
      this.form.depId = id
109
    },
110
    getDailyStaffId(id) {
111
      this.form.userid = id
112
    },
101 113
    handleInited() {
102 114
      this.getTableData()
103 115
    },

+ 116 - 41
security-protection-platform/src/modules/attendance/components/DeptStaffCascader/index.vue

@ -1,9 +1,28 @@
1 1
<template>
2
  <t-cascader v-model="staff" :data-source="source" :loader="loadStuffData" :change-on-select="true" />
2
  <div class="row">
3
    <div class="col-3">
4
      <t-select v-model="companyTypeId" width="200px" @change="getOrgId">
5
        <t-option v-for="item in companyTypesList" :key="item.id" :value="item.id">{{ item.name }}</t-option>
6
      </t-select>
7
    </div>
8
    <div class="col-3" style="margin-left:35px">
9
      <!-- <t-select v-model="departmentTypeId" width="200px">
10
            <t-option v-for="item in departmentTypesList" :key="item.id" :value="item.id">{{ item.name }}</t-option>
11
          </t-select> -->
12
      <template>
13
        <t-select-tree v-model="departmentTypeId" :node-data="departmentTypesList" width="200px" node-key="id" @change="getDepId"></t-select-tree>
14
      </template>
15
    </div>
16
    <div class="col-3" style="margin-left:35px">
17
      <t-select v-model="staffTypeId" width="200px" @change="getStaffId">
18
        <t-option v-for="item in staffTypesList" :key="item.id" :value="item.id">{{ item.name }}</t-option>
19
      </t-select>
20
    </div>
21
  </div>
3 22
</template>
4 23
5 24
<script>
6
import commonapi from '@/api/common'
25
import commonApi from '@/api/common'
7 26
export default {
8 27
  props: {
9 28
    value: {
@ -15,7 +34,14 @@ export default {
15 34
  },
16 35
  data() {
17 36
    return {
18
      source: []
37
      source: [],
38
      // 公司、部门、员工、列表
39
      companyTypesList: [],
40
      departmentTypesList: [],
41
      staffTypesList: [],
42
      companyTypeId: '',
43
      departmentTypeId: '',
44
      staffTypeId: ''
19 45
    }
20 46
  },
21 47
  computed: {
@ -30,54 +56,103 @@ export default {
30 56
      }
31 57
    }
32 58
  },
59
  watch: {
60
    companyTypeId (val) {
61
      // 重置部门回显
62
      this.departmentTypeId = ''
63
      // 查询部门列表
64
      this.queryCycleChildOrg(val)
65
    },
66
    departmentTypeId (val) {
67
      // 重置人员回显
68
      this.staffTypeId = ''
69
      // 重置人员列表
70
      this.staffTypesList = []
71
      // 减少查询请求
72
      if (val !== '') {
73
        this.getStaffTypesList(val)
74
      }
75
    }
76
  },
33 77
  created() {
34
    this.getDepartments()
78
    this.getCompanyTypesList()
35 79
  },
36 80
  methods: {
37
38
    getDepartments() {
39
      commonapi.getDepartments().then(resp => {
40
        this.staff = []
41
42
        this.source = resp.data.map(item => {
43
          const children = item.departments.map(dept => {
44
            return {
45
              label: dept.name,
46
              value: dept.id,
47
              children: [],
48
              loading: false
81
    getOrgId() {
82
      console.log(123);
83
      this.$emit('getOrgId', this.companyTypeId)
84
    },
85
    getDepId() {
86
      this.$emit('getDepId', this.departmentTypeId)
87
    },
88
    getStaffId() {
89
      this.$emit('getStaffId', this.staffTypeId)
90
    },
91
    // 向服务器发送请求获取公司类型列表数据
92
    async getCompanyTypesList () {
93
      const res = await commonApi.getCompanyTypesList()
94
      if (res.status === 200) {
95
        this.companyTypesList = res.data.data
96
      } else {
97
        this.$Message.danger('公司类型列表数据获取失败!')
98
      }
99
    },
100
    // 获取部门列表
101
    async queryCycleChildOrg (id) {
102
      const res = await commonApi.queryCycleChildOrg(id)
103
      if (res.status === 200) {
104
        const data = []
105
        // 递归 实现tree组件所需部门数据结构
106
        this.nextDepartment(res.data, data)
107
        // 深拷贝data
108
        const data1 = JSON.parse(JSON.stringify(data))
109
        // 用部门id映射关系代替code与parentCode父子映射关系
110
        data.forEach(item => {
111
          // 删除pid为"-1"的的pid属性,否则tree渲染的时候没有根节点渲染不出来
112
          if (item.pid === '-1') {
113
            delete item.pid
114
          }
115
          item.id = item.orgId
116
          data1.some((item1) => {
117
            if (item.pid === item1.id) {
118
              item.pid = item1.orgId
119
            } else {
120
              return false
49 121
            }
50 122
          })
51
52
          children.unshift({
53
            label: '全部',
54
            value: item.id,
55
            children: [],
56
            loading: false
57
          })
58
59
          return {
123
        })
124
        // eslint-disable-next-line no-return-assign
125
        this.departmentTypesList = data.filter(item => item.data = item.id)
126
      } else {
127
        this.$Message.danger('部门类型列表数据获取失败!')
128
      }
129
    },
130
    // 向服务器发送请求获取用户类型列表数据
131
    async getStaffTypesList (id) {
132
      const res = await commonApi.getStaffTypesList(id)
133
      if (res.status === 200) {
134
        this.staffTypesList = res.data.data
135
      } else {
136
        this.$Message.danger('用户类型列表数据获取失败!')
137
      }
138
    },
139
    // 如果部门还有下级 递归
140
    nextDepartment (data, arr) {
141
      if (data.length > 0) {
142
        data.forEach(item => {
143
          arr.push({
144
            orgId: item.id + '',
145
            id: item.code,
60 146
            label: item.name,
61
            value: item.id,
62
            children
63
          }
147
            pid: item.parentCode
148
          })
149
          this.nextDepartment(item.departments, arr)
64 150
        })
65
66
        // if (this.source.length > 0) {
67
        //   const orgId = this.source[0].value
68
        //   // const depId = this.source[0].children[0].value
69
        //   this.staff = [orgId]
70
        // }
71
72
        this.$emit('inited')
73
      }, err => {
74
        this.$Message.danger('获取部门列表失败!')
75
        console.log(err)
76
      })
151
      }
77 152
    },
78 153
    loadStuffData(item, callback) {
79 154
      item.loading = true
80
      commonapi.getEmployeeByOrgid(item.value).then(res => {
155
      commonApi.getEmployeeByOrgid(item.value).then(res => {
81 156
        console.log(res)
82 157
        let arr = []
83 158

+ 86 - 4
security-protection-platform/src/modules/attendance/report/index.vue

@ -11,7 +11,7 @@
11 11
            </div>
12 12
            <div class="keep-row">
13 13
              <span>部门/员工:</span>
14
              <dept-staff-cascader v-model="dailyForm" @inited="handleDailyInited" />
14
              <dept-staff-cascader v-model="dailyForm" @inited="handleDailyInited" @getOrgId="getDailyOrgId" @getDepId="getDailyDepId" @getStaffId="getDailyStaffId" />
15 15
            </div>
16 16
            <div class="search-btn">
17 17
              <t-button color="primary" @click="handSearchDay">查询</t-button>
@ -41,7 +41,7 @@
41 41
            </div>
42 42
            <div class="keep-row">
43 43
              <span>部门/员工:</span>
44
              <dept-staff-cascader v-model="monthlyForm" />
44
              <dept-staff-cascader v-model="monthlyForm" @getOrgId="getMonthOrgId" @getDepId="getMonthDepId" @getStaffId="getMonthStaffId" />
45 45
            </div>
46 46
            <div class="search-btn">
47 47
              <t-button color="primary" @click="handSearchMonth">查询</t-button>
@ -113,7 +113,6 @@ import atdapi from '@/api/attendance'
113 113
import formatDateTime from '@/utils/formatDateTime.js'
114 114
import AttendanceDialog from '../components/AttendanceDialog'
115 115
import DeptStaffCascader from '../components/DeptStaffCascader'
116
117 116
export default {
118 117
  components: { AttendanceDialog, DeptStaffCascader },
119 118
  data () {
@ -128,7 +127,10 @@ export default {
128 127
      loadDetail: false,
129 128
      loadDailyTable: false,
130 129
      loadMonthTable: false,
131
130
      // 公司、部门、员工、列表
131
      companyTypesList: [],
132
      departmentTypesList: [],
133
      getStaffTypesList: [],
132 134
      monthlyTotal: 0,
133 135
      dailyTotal: 0,
134 136
      monthlyForm: {
@ -150,6 +152,24 @@ export default {
150 152
    }
151 153
  },
152 154
  methods: {
155
    getDailyOrgId(id) {
156
      this.dailyForm.orgId = id
157
    },
158
    getDailyDepId(id) {
159
      this.dailyForm.depId = id
160
    },
161
    getDailyStaffId(id) {
162
      this.dailyForm.userid = id
163
    },
164
    getMonthOrgId(id) {
165
      this.monthlyForm.orgId = id
166
    },
167
    getMonthDepId(id) {
168
      this.monthlyForm.depId = id
169
    },
170
    getMonthStaffId(id) {
171
      this.monthlyForm.userid = id
172
    },
153 173
    handleDailyInited () {
154 174
      // this.getDailyTable()
155 175
    },
@ -178,6 +198,68 @@ export default {
178 198
      this.monthlyForm.current = val
179 199
      this.getMonthTable()
180 200
    },
201
    // // 向服务器发送请求获取公司类型列表数据
202
    // async getCompanyTypesList () {
203
    //   const res = await commonApi.getCompanyTypesList()
204
    //   if (res.status === 200) {
205
    //     this.companyTypesList = res.data.data
206
    //   } else {
207
    //     this.$Message.danger('公司类型列表数据获取失败!')
208
    //   }
209
    // },
210
    // // 获取部门列表
211
    // async queryCycleChildOrg (id) {
212
    //   const res = await commonApi.queryCycleChildOrg(id)
213
    //   if (res.status === 200) {
214
    //     const data = []
215
    //     // 递归 实现tree组件所需部门数据结构
216
    //     this.nextDepartment(res.data, data)
217
    //     // 深拷贝data
218
    //     const data1 = JSON.parse(JSON.stringify(data))
219
    //     // 用部门id映射关系代替code与parentCode父子映射关系
220
    //     data.forEach(item => {
221
    //       // 删除pid为"-1"的的pid属性,否则tree渲染的时候没有根节点渲染不出来
222
    //       if (item.pid === '-1') {
223
    //         delete item.pid
224
    //       }
225
    //       item.id = item.orgId
226
    //       data1.some((item1) => {
227
    //         if (item.pid === item1.id) {
228
    //           item.pid = item1.orgId
229
    //         } else {
230
    //           return false
231
    //         }
232
    //       })
233
    //     })
234
    //     // eslint-disable-next-line no-return-assign
235
    //     this.departmentTypesList = data.filter(item => item.data = item.id)
236
    //   } else {
237
    //     this.$Message.danger('部门类型列表数据获取失败!')
238
    //   }
239
    // },
240
    // // 向服务器发送请求获取用户类型列表数据
241
    // async getStaffTypesList (id) {
242
    //   const res = await commonApi.getStaffTypesList(id)
243
    //   if (res.status === 200) {
244
    //     this.staffTypesList = res.data.data
245
    //   } else {
246
    //     this.$Message.danger('用户类型列表数据获取失败!')
247
    //   }
248
    // },
249
    // // 如果部门还有下级 递归
250
    // nextDepartment (data, arr) {
251
    //   if (data.length > 0) {
252
    //     data.forEach(item => {
253
    //       arr.push({
254
    //         orgId: item.id + '',
255
    //         id: item.code,
256
    //         label: item.name,
257
    //         pid: item.parentCode
258
    //       })
259
    //       this.nextDepartment(item.departments, arr)
260
    //     })
261
    //   }
262
    // },
181 263
    // 重置日报数据
182 264
    resetDailyData() {
183 265
      this.$nextTick(() => {

+ 12 - 2
security-protection-platform/src/modules/system/monitor/HomePageSettings/ShiftCameraDialog.vue

@ -30,7 +30,7 @@
30 30
          <div>
31 31
            <img
32 32
              :class="item.resourceToolId == form.resourceToolId ? 'hover' : ''"
33
              :src="item.pictureUrl"
33
              :src="item.imageUrl"
34 34
              style="height: 120px; width: 158px"
35 35
              alt=""
36 36
            />
@ -129,10 +129,20 @@ export default {
129 129
        nameAsLike: this.searchValue // 设备名称(模糊匹配)
130 130
      }
131 131
      sysapi.getResourceTool(params).then((resp) => {
132
        this.cameraList = resp.data.data.data || []
132
        const res = resp.data.data.data || []
133
        let data = []
134
        res.forEach(item => data.push(item.pictureUrl))
135
        this.getListFileUrl(res, data)
133 136
        this.total = resp.data.data.total
134 137
      })
135 138
    },
139
    async getListFileUrl(res, data) {
140
      const resp = await sysapi.getListFileUrl(data)
141
      res.filter((item, index) => {
142
        item.imageUrl = resp.data.data[index]
143
      })
144
      this.cameraList = res
145
    },
136 146
    groupClick(item) {
137 147
      // 选中更换摄像头
138 148
      this.form.resourceToolName = item.resourceToolName

+ 91 - 19
security-protection-platform/src/modules/usermana/components/modal/addUser.vue

@ -1,33 +1,33 @@
1 1
<template>
2
  <t-modal :visibled.sync="isVisibled" :mask-closable="false">
2
  <t-modal :visibled.sync="isVisibled" :mask-closable="false" width="600px">
3 3
    <template slot="header">
4 4
      <div class="device-modal-title">{{ isEdit?'用户编辑':'新增用户' }}</div>
5 5
    </template>
6 6
    <t-form ref="addUserModal" :model="addUserModal" :rules="addUserModalRules" label-position="right">
7 7
      <t-form-item label="姓名:" prop="name">
8
        <t-input v-model="addUserModal.name" placeholder="请输入姓名"></t-input>
8
        <t-input v-model="addUserModal.name" style="width:300px" placeholder="请输入姓名"></t-input>
9 9
      </t-form-item>
10 10
      <t-form-item label="员工编号:" prop="code">
11
        <t-input v-model="addUserModal.code" placeholder="请输入员工编号"></t-input>
11
        <t-input v-model="addUserModal.code" placeholder="请输入员工编号" style="width:300px"></t-input>
12 12
      </t-form-item>
13 13
      <t-form-item label="公司:" prop="apartments">
14
        <t-select v-model="addUserModal.apartments" placeholder="请选择公司" clearable>
14
        <t-select v-model="addUserModal.apartments" width="300px" placeholder="请选择公司" clearable>
15 15
          <t-option v-for="(item,index) in companyList" :value="item.id" :key="index">{{ item.name }}</t-option>
16 16
        </t-select>
17 17
      </t-form-item>
18 18
      <t-form-item v-if="addUserModal.apartments!==''" label="部门:" prop="organizeCode">
19
        <t-select-tree v-model="addUserModal.organizeCode" :node-data="departmentTypesList" node-value="code" node-key="code"></t-select-tree>
19
        <t-select-tree v-model="addUserModal.organizeCode" :node-data="departmentTypesList" width="300px" node-value="data" node-key="data"></t-select-tree>
20 20
      </t-form-item>
21 21
      <t-form-item label="职务:" prop="mainJobPosition">
22
        <t-select v-model="addUserModal.mainJobPosition" placeholder="请选择职务" clearable>
22
        <t-select v-model="addUserModal.mainJobPosition" width="300px" placeholder="请选择职务" clearable>
23 23
          <t-option v-for="(item,index) in jobPoisitonList" :value="item.code" :key="index">{{ item.value }}</t-option>
24 24
        </t-select>
25 25
      </t-form-item>
26 26
      <t-form-item label="年龄:" prop="birthday">
27
        <t-date-picker v-model="addUserModal.birthday" placeholder="请输入年龄" @date-change="startPickerDateChange"></t-date-picker>
27
        <t-date-picker v-model="addUserModal.birthday" style="width:300px" placeholder="请输入年龄" @date-change="startPickerDateChange"></t-date-picker>
28 28
      </t-form-item>
29 29
      <t-form-item label="手机:" prop="mainWirelessCall">
30
        <t-input v-model="addUserModal.mainWirelessCall" placeholder="请输入11位手机号"></t-input>
30
        <t-input v-model="addUserModal.mainWirelessCall" style="width:300px" placeholder="请输入11位手机号"></t-input>
31 31
      </t-form-item>
32 32
      <t-form-item label="人脸图片:" style="display:flex" prop="facePicture">
33 33
        <div style="display:flex">
@ -49,14 +49,32 @@
49 49
              <span style="color:rgba(0, 0, 0, 0.45)">上传照片</span>
50 50
            </div>
51 51
          </t-upload>
52
          <img v-show="showPicture" :src="showPicture" style="width:120px;height:160px;margin-left:12px"/>
52
          <img v-show="showPicture" :src="showPicture" class="upload-img"/>
53
          <!-- <div v-show="showPicture" class="upload-edit">
54
            修改 </div> -->
55
          <t-upload
56
            v-show="showPicture"
57
            ref="uploader"
58
            :show-uploaded="false"
59
            :allowed-ext="['jpg','jpeg','png']"
60
            :max-size="2048"
61
            :before-upload="$_onUploadBeforeUpload"
62
            multiple
63
            type="drag"
64
            action="http://10.19.90.34:8018/sp/employeeManagement/uploadEmployeePicture"
65
            class="upload-edit"
66
            @success = "$_onUploadSuccess"
67
          >
68
            <div>上传</div>
69
          </t-upload>
70
          <img v-show="showPicture" :src="showPicture" class="upload-edit-img"/>
53 71
        </div>
54 72
        <span style="color:rgba(0, 0, 0, 0.45);font-size:12px">照片格式:jpg、png或bmp文件,且不超过2M</span>
55 73
      </t-form-item>
56 74
    </t-form>
57 75
    <template slot="footer">
58 76
      <t-button @click="resetModalData">取消</t-button>
59
      <t-button v-if="isEdit" :loading="loadingSubmit" color="primary" @click="submitModalData">修改</t-button>
77
      <t-button v-if="isEdit" :loading="loadingSubmit" color="primary" @click="editModalData">修改</t-button>
60 78
      <t-button v-else color="primary" @click="submitModalData">提交</t-button>
61 79
    </template>
62 80
  </t-modal>
@ -167,10 +185,6 @@ export default {
167 185
      this.getCompanyList()
168 186
    }
169 187
  },
170
  created() {
171
    // console.log(this.editUserModal)
172
    // this.addUserModal.apartments = this.editUserModal.field4
173
  },
174 188
  mounted() {
175 189
    this.getJobPositionList()
176 190
  },
@ -202,12 +216,41 @@ export default {
202 216
        }
203 217
      })
204 218
    },
219
    // 修改用户个人信息
220
    editModalData() {
221
      this.loadingSubmit = true
222
      let obj = {
223
        id: this.editUserModal.employeeId, // 主键ID
224
        name: this.addUserModal.name, // 员工姓名
225
        code: this.addUserModal.code, // 员工编号
226
        organizeCode: this.addUserModal.organizeCode, // 部门CODE
227
        mainWirelessCall: this.addUserModal.mainWirelessCall, // 手机号码
228
        mainJobPosition: this.addUserModal.mainJobPosition, // 职务
229
        field1: this.addUserModal.field1, // 照片标识
230
        field4: this.addUserModal.apartments, // 公司ID
231
        birthday: +new Date(this.addUserModal.birthday) // 生日(时间戳)
232
      }
233
      sysapi.editUserDetail(obj).then(res => {
234
        if (res.status === 200) {
235
          this.$Message.success('修改成功!')
236
          this.isVisibled = false
237
          this.resetModalData()
238
          this.$emit('getUserList')
239
        } else {
240
          this.$Message.danger('修改失败!')
241
        }
242
        this.loadingSubmit = false
243
      })
244
    },
205 245
    // 重置表单数据
206 246
    resetModalData () {
207 247
      this.$refs['addUserModal'].resetFields()
208 248
      this.imgUrl = ''
249
      this.isEdit = false
209 250
      this.isVisibled = false
251
      this.showPicture = ''
210 252
    },
253
    // 获得编辑回显数据
211 254
    getCompanyList() {
212 255
      this.$nextTick(() => {
213 256
        this.addUserModal = {
@ -216,11 +259,12 @@ export default {
216 259
          'organizeCode': this.editUserModal.organizationCode, // 部门CODE
217 260
          'mainWirelessCall': this.editUserModal.mainWirelessCall, // 手机号码
218 261
          'mainJobPosition': this.editUserModal.employeePosition, // 职务
219
          'field1': this.editUserModal.field1, // 照片标识
220
          'apartments': this.editUserModal.field4, // 公司ID
262
          'apartments': '', // 公司ID
221 263
          'birthday': formatDateTime(new Date(this.editUserModal.birthday - 0)) // 生日(时间戳)
222 264
        }
223
        // this.isEdit = true
265
        this.addUserModal.apartments = parseInt(this.editUserModal.field4)
266
        this.showPicture = this.editUserModal.pictureUrl// 照片标识
267
        this.isEdit = true
224 268
      })
225 269
    },
226 270
    // 查询职务列表
@ -258,6 +302,9 @@ export default {
258 302
        })
259 303
        // eslint-disable-next-line no-return-assign
260 304
        this.departmentTypesList = data.filter(item => item.data = item.id)
305
        this.$nextTick(() => {
306
          this.addUserModal.organizeCode = this.editUserModal.organizationCode
307
        })
261 308
      } else {
262 309
        this.$Message.danger('部门类型列表数据获取失败!')
263 310
      }
@ -273,7 +320,7 @@ export default {
273 320
            id: item.code,
274 321
            label: item.name,
275 322
            pid: item.parentCode,
276
            code: item.code
323
            data: item.code
277 324
          })
278 325
          this.nextDepartment(item.departments, arr)
279 326
        })
@ -339,8 +386,33 @@ export default {
339 386
<style lang="scss" scoped>
340 387
.demo-upload-list{
341 388
  .upload--drag{
342
  background-color:#FFFFFF
389
  background-color:#FFFFFF;
390
  align-items: center;
391
  justify-content: center;
392
  display: flex
393
}
394
}
395
.upload-img{
396
  width:120px;
397
  height:160px;
398
  margin-left:12px
399
}
400
.upload-edit{
401
  width:120px;
402
  height:160px;
403
  margin-left:12px;
404
  background-color:rgba(0, 0, 0, 0.5);
405
  justify-content: center;
406
  align-items: center;
407
  color: white;
408
  display: flex;
409
  cursor: pointer;
410
  z-index: 2;
343 411
}
412
.upload-edit-img{
413
  margin-left:-120px;
414
  width:120px;
415
  height:160px;
344 416
}
345 417
.picture-upload{
346 418
  display:flex;

+ 1 - 1
security-protection-platform/src/modules/usermana/index.vue

@ -64,7 +64,7 @@
64 64
        </t-pager>
65 65
      </div>
66 66
    </t-card>
67
    <add-user-modal :edit-user-modal="currentEditDevice" :company-list="companyTypesList" :visible.sync="addDeviceModal"></add-user-modal>
67
    <add-user-modal :edit-user-modal="currentEditDevice" :company-list="companyTypesList" :visible.sync="addDeviceModal" @getUserList="getUserList"></add-user-modal>
68 68
    <auditModal :auditshow.sync="auditshow" :auditid="auditid" :company-name="companyName" @refeshUserList="getUserList"></auditModal>
69 69
  </div>
70 70
</template>