| | |
| | | <div style="margin-top: 1rem; height: 100%"> |
| | | <!-- ç¨æ·å表 --> |
| | | <el-table |
| | | empty-text="ææ æ°æ®" |
| | | height="450" |
| | | v-if="isactive == 1" |
| | | :data="tableData" |
| | |
| | | <el-table-column label="æ¯å¦å¯ç¨" align="center" min-width="2%"> |
| | | <template #default="scope"> |
| | | <el-switch |
| | | :disabled=" |
| | | scope.row.userName == 'admin' || scope.row.user_Id == '1' |
| | | " |
| | | v-model="scope.row.enable" |
| | | :active-value="1" |
| | | :inactive-value="0" |
| | |
| | | |
| | | <!-- ç¨æ·è§è² --> |
| | | <el-table |
| | | empty-text="ææ æ°æ®" |
| | | height="450" |
| | | v-if="isactive == 2" |
| | | :data="grideData" |
| | |
| | | <el-table-column prop="name" label="è§è²æé" align="center"> |
| | | <template #default="scope"> |
| | | <span |
| | | v-if="scope.row.roleId != '20'" |
| | | v-if=" |
| | | scope.row.roleName != 'è¶
级管çå' || scope.row.roleId != '1' |
| | | " |
| | | @click="toDetail(scope.row)" |
| | | style="color: #4386ff; cursor: pointer" |
| | | >管ç</span |
| | |
| | | <el-table-column label="æ¯å¦å¯ç¨" align="center"> |
| | | <template #default="scope"> |
| | | <el-switch |
| | | :disabled=" |
| | | scope.row.roleName == 'è¶
级管çå' || scope.row.roleId == '1' |
| | | " |
| | | v-model="scope.row.enable" |
| | | :active-value="1" |
| | | :inactive-value="0" |
| | |
| | | <el-table-column label="æä½" align="center"> |
| | | <template #default="scope"> |
| | | <span |
| | | v-if="scope.row.roleId != '20'" |
| | | v-if=" |
| | | scope.row.roleName != 'è¶
级管çå' || scope.row.roleId != '1' |
| | | " |
| | | style="color: blue; font-size: 0.88rem; cursor: pointer" |
| | | @click="EditRole(scope.row)" |
| | | >ç¼è¾</span |
| | |
| | | size="small" |
| | | > |
| | | <el-option |
| | | :disabled="item.value == 20" |
| | | :disabled="item.roleId == 1" |
| | | v-for="item in groupOptions" |
| | | :key="item.value" |
| | | :label="item.label" |
| | | :value="item.value" |
| | | :key="item.roleId" |
| | | :label="item.roleName" |
| | | :value="item.roleId" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | |
| | | { value: 1, label: "æ¯" }, |
| | | ]); |
| | | //åç» |
| | | const groupOptions = ref([ |
| | | { value: 20, label: "è¶
级管çå" }, |
| | | { value: 21, label: "è´¨æ£ç»" }, |
| | | { value: 22, label: "çµæ°ç»" }, |
| | | { value: 23, label: "æºæ¢°ç»" }, |
| | | { value: 24, label: "å°æ²ç»" }, |
| | | ]); |
| | | const groupOptions = ref([]); |
| | | const formUser = ref({ |
| | | user_Id: undefined, |
| | | userName: "", |
| | | role_Id: 21, |
| | | role_Id: 2, |
| | | roleName: "", |
| | | phoneNo: "", |
| | | remark: "", |
| | |
| | | tableData.value = res.rows; |
| | | pageTotal.value = res.total; |
| | | }); |
| | | getRole(); |
| | | }; |
| | | //å页请æ±åæ° |
| | | const pageQuery = ref({ |
| | |
| | | headImageUrl: "", |
| | | newPwd: "", |
| | | }; |
| | | fileList.value = []; |
| | | }; |
| | | const resetForm1 = (formEl) => { |
| | | if (!formEl) return; |
| | |
| | | fileList.value = [ |
| | | { |
| | | name: "1", |
| | | url: "http://192.168.0.80:5000" + obj.headImageUrl, |
| | | url: "http://115.159.85.185:9098" + obj.headImageUrl, |
| | | }, |
| | | ]; |
| | | } |
| | |
| | | GetPageDataApi({ ...pageQuery.value, filter }).then((res) => { |
| | | grideData.value = res.rows; |
| | | pageTotal.value = res.total; |
| | | groupOptions.value = res.rows; |
| | | }); |
| | | }; |
| | | //æå°æ°æ® |
| | | const printExcel = () => { |
| | | // æ¥è¯¢æ¡ä»¶ |
| | | const startTime = formatTime(queryForm.selectTime[0]); |
| | | const endTime = formatTime(queryForm.selectTime[1]); |
| | | const startTime = formatTime(queryForm.value.selectTime[0]); |
| | | const endTime = formatTime(queryForm.value.selectTime[1]); |
| | | const filter = [ |
| | | { |
| | | name: queryForm.selectType, |
| | | value: queryForm.selectInput, |
| | | displayType: "String", |
| | | name: queryForm.value.selectType, |
| | | value: queryForm.value.selectInput, |
| | | displayType: "like", |
| | | }, |
| | | { |
| | | name: "pustatus", |
| | | value: queryForm.selectName, |
| | | value: queryForm.value.selectName, |
| | | displayType: "String", |
| | | }, |
| | | { name: "createDate", value: startTime, displayType: "ThanOrEqual" }, |
| | |
| | | ids.value = val.map((item) => item.roleId); |
| | | }; |
| | | const deleteAll = () => { |
| | | if (ids.value.includes(1)) { |
| | | ElMessage({ message: "è¶
级管çåä¸è½å é¤", type: "error" }); |
| | | return; |
| | | } |
| | | if (ids.value.length == 0) { |
| | | ElMessage({ message: "è¯·éæ©è¦å é¤çæ°æ®", type: "error" }); |
| | | return; |