|
@@ -86,26 +86,45 @@
|
|
|
<!-- 业务部门 -->
|
|
<!-- 业务部门 -->
|
|
|
<DkFormItem prop="orgId" :label="$t('orgName')" :required="true">
|
|
<DkFormItem prop="orgId" :label="$t('orgName')" :required="true">
|
|
|
<SelectMagnifier v-model="formData.orgId" :display-text="formData.orgName"
|
|
<SelectMagnifier v-model="formData.orgId" :display-text="formData.orgName"
|
|
|
|
|
+ ref="orgId"
|
|
|
:type="this.$config.MagnifierType.org"
|
|
:type="this.$config.MagnifierType.org"
|
|
|
:multiple="false"></SelectMagnifier>
|
|
:multiple="false"></SelectMagnifier>
|
|
|
</DkFormItem>
|
|
</DkFormItem>
|
|
|
<!--登录标识-->
|
|
<!--登录标识-->
|
|
|
- <DkFormItem prop="flgCanLogin">
|
|
|
|
|
|
|
+<!-- <DkFormItem prop="flgCanLogin">-->
|
|
|
|
|
+<!-- <template>-->
|
|
|
|
|
+<!-- <i-switch v-model="formData.flgCanLogin">-->
|
|
|
|
|
+<!-- <span slot="open"></span>-->
|
|
|
|
|
+<!-- <span slot="close"></span>-->
|
|
|
|
|
+<!-- </i-switch>-->
|
|
|
|
|
+<!-- </template>-->
|
|
|
|
|
+<!-- </DkFormItem>-->
|
|
|
|
|
+ <!--电脑登录标识-->
|
|
|
|
|
+ <DkFormItem prop="flgCanPcLogin" :label="$t('flgCanPcLogin')">
|
|
|
<template>
|
|
<template>
|
|
|
- <i-switch v-model="formData.flgCanLogin">
|
|
|
|
|
|
|
+ <i-switch v-model="formData.flgCanPcLogin">
|
|
|
<span slot="open"></span>
|
|
<span slot="open"></span>
|
|
|
<span slot="close"></span>
|
|
<span slot="close"></span>
|
|
|
</i-switch>
|
|
</i-switch>
|
|
|
</template>
|
|
</template>
|
|
|
</DkFormItem>
|
|
</DkFormItem>
|
|
|
- <!--登录系统-->
|
|
|
|
|
- <DkFormItem prop="loginType" v-if="formData.flgCanLogin">
|
|
|
|
|
- <SelectPop v-model="formData.loginType" ref="loginTypeId"
|
|
|
|
|
- :options="loginTypeList"
|
|
|
|
|
- :multiple="false"
|
|
|
|
|
- labelKey="loginTypeName" valueKey="loginTypeId">
|
|
|
|
|
- </SelectPop>
|
|
|
|
|
|
|
+ <!--手机登录标识-->
|
|
|
|
|
+ <DkFormItem prop="flgCanWxLogin" :label="$t('flgCanWxLogin')">
|
|
|
|
|
+ <template>
|
|
|
|
|
+ <i-switch v-model="formData.flgCanWxLogin">
|
|
|
|
|
+ <span slot="open"></span>
|
|
|
|
|
+ <span slot="close"></span>
|
|
|
|
|
+ </i-switch>
|
|
|
|
|
+ </template>
|
|
|
</DkFormItem>
|
|
</DkFormItem>
|
|
|
|
|
+ <!--登录系统-->
|
|
|
|
|
+<!-- <DkFormItem prop="loginType" v-if="formData.flgCanLogin">-->
|
|
|
|
|
+<!-- <SelectPop v-model="formData.loginType" ref="loginTypeId"-->
|
|
|
|
|
+<!-- :options="loginTypeList"-->
|
|
|
|
|
+<!-- :multiple="false"-->
|
|
|
|
|
+<!-- labelKey="loginTypeName" valueKey="loginTypeId">-->
|
|
|
|
|
+<!-- </SelectPop>-->
|
|
|
|
|
+<!-- </DkFormItem>-->
|
|
|
<!-- 角色 -->
|
|
<!-- 角色 -->
|
|
|
<DkFormItem prop="roleIds" :label="$t('roleName')" :data-type="$config.dataType.array">
|
|
<DkFormItem prop="roleIds" :label="$t('roleName')" :data-type="$config.dataType.array">
|
|
|
<SelectPop v-model="formData.roleIds" ref="roleId"
|
|
<SelectPop v-model="formData.roleIds" ref="roleId"
|
|
@@ -176,6 +195,7 @@ export default {
|
|
|
],
|
|
],
|
|
|
// 表单
|
|
// 表单
|
|
|
formData: {
|
|
formData: {
|
|
|
|
|
+ staffID:null,
|
|
|
staffCode: '',
|
|
staffCode: '',
|
|
|
staffName: '',
|
|
staffName: '',
|
|
|
staffPhone: '',
|
|
staffPhone: '',
|
|
@@ -183,6 +203,8 @@ export default {
|
|
|
orgName: null,
|
|
orgName: null,
|
|
|
roleIds: null,
|
|
roleIds: null,
|
|
|
flgCanLogin:false,
|
|
flgCanLogin:false,
|
|
|
|
|
+ flgCanPcLogin:false,
|
|
|
|
|
+ flgCanWxLogin:false,
|
|
|
loginType:null,
|
|
loginType:null,
|
|
|
remarks: ''
|
|
remarks: ''
|
|
|
},
|
|
},
|
|
@@ -489,14 +511,39 @@ export default {
|
|
|
// 查询数据
|
|
// 查询数据
|
|
|
return this.excute(this.$service.staffService, this.$service.staffService.selectByCond, params);
|
|
return this.excute(this.$service.staffService, this.$service.staffService.selectByCond, params);
|
|
|
},
|
|
},
|
|
|
-
|
|
|
|
|
|
|
+ /**
|
|
|
|
|
+ * @desc : 参数赋值
|
|
|
|
|
+ * @author : 姜宁
|
|
|
|
|
+ * @date : 2024/7/29 14:30
|
|
|
|
|
+ */
|
|
|
|
|
+ setParams(params) {
|
|
|
|
|
+ let loginType = 4;
|
|
|
|
|
+ // 登录标识赋值
|
|
|
|
|
+ if (params.flgCanPcLogin || params.flgCanWxLogin){
|
|
|
|
|
+ params.flgCanLogin = true
|
|
|
|
|
+ if (params.flgCanPcLogin && params.flgCanWxLogin){
|
|
|
|
|
+ loginType = 3;
|
|
|
|
|
+ }
|
|
|
|
|
+ else if(params.flgCanPcLogin && !params.flgCanWxLogin){
|
|
|
|
|
+ loginType = 1;
|
|
|
|
|
+ }
|
|
|
|
|
+ else{
|
|
|
|
|
+ loginType = 2;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ else{
|
|
|
|
|
+ params.flgCanLogin = false
|
|
|
|
|
+ }
|
|
|
|
|
+ params.loginType = loginType;
|
|
|
|
|
+ return params
|
|
|
|
|
+ },
|
|
|
/**
|
|
/**
|
|
|
* @desc : 提交事件
|
|
* @desc : 提交事件
|
|
|
* @author : 常皓宁
|
|
* @author : 常皓宁
|
|
|
* @date : 2024/3/5 14:19
|
|
* @date : 2024/3/5 14:19
|
|
|
*/
|
|
*/
|
|
|
saveData() {
|
|
saveData() {
|
|
|
- console.log('this.params', this.params)
|
|
|
|
|
|
|
+ console.log("this.params:",this.params)
|
|
|
if (this.modalParams.button === this.$config.formMode.add) {
|
|
if (this.modalParams.button === this.$config.formMode.add) {
|
|
|
delete this.params.staffId // 解决提示主键重复的问题,删除主键代码
|
|
delete this.params.staffId // 解决提示主键重复的问题,删除主键代码
|
|
|
return this.excute(this.$service.staffService, this.$service.staffService.insert, this.params)
|
|
return this.excute(this.$service.staffService, this.$service.staffService.insert, this.params)
|
|
@@ -504,13 +551,13 @@ export default {
|
|
|
return this.excute(this.$service.staffService, this.$service.staffService.update, this.params)
|
|
return this.excute(this.$service.staffService, this.$service.staffService.update, this.params)
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
-
|
|
|
|
|
/**
|
|
/**
|
|
|
* @desc : 新建完毕后清空窗体
|
|
* @desc : 新建完毕后清空窗体
|
|
|
* @author : 常皓宁
|
|
* @author : 常皓宁
|
|
|
* @date : 2024/5/17 9:07
|
|
* @date : 2024/5/17 9:07
|
|
|
*/
|
|
*/
|
|
|
clear() {
|
|
clear() {
|
|
|
|
|
+ this.staffID = null
|
|
|
this.formData.staffCode = null
|
|
this.formData.staffCode = null
|
|
|
this.formData.staffName = null
|
|
this.formData.staffName = null
|
|
|
this.formData.staffPhone = null
|
|
this.formData.staffPhone = null
|
|
@@ -518,6 +565,8 @@ export default {
|
|
|
this.formData.orgName = null
|
|
this.formData.orgName = null
|
|
|
this.formData.roleIds = null
|
|
this.formData.roleIds = null
|
|
|
this.formData.flgCanLogin = false
|
|
this.formData.flgCanLogin = false
|
|
|
|
|
+ this.formData.flgCanPcLogin = false
|
|
|
|
|
+ this.formData.flgCanWxLogin = false
|
|
|
this.formData.loginType = null
|
|
this.formData.loginType = null
|
|
|
this.formData.remarks = null
|
|
this.formData.remarks = null
|
|
|
},
|
|
},
|
|
@@ -530,6 +579,19 @@ export default {
|
|
|
detail(id) {
|
|
detail(id) {
|
|
|
return this.excuteNoParam(this.$service.staffService, this.$service.staffService.selectById, [id], false)
|
|
return this.excuteNoParam(this.$service.staffService, this.$service.staffService.selectById, [id], false)
|
|
|
},
|
|
},
|
|
|
|
|
+ /**
|
|
|
|
|
+ * @desc : 编辑赋值
|
|
|
|
|
+ * @author : 姜宁
|
|
|
|
|
+ * @date : 2024/7/29 14:52
|
|
|
|
|
+ */
|
|
|
|
|
+ setValuesByEdit(data) {
|
|
|
|
|
+ if (data.loginType == 1 || data.loginType == 3){
|
|
|
|
|
+ this.formData.flgCanPcLogin = true
|
|
|
|
|
+ }
|
|
|
|
|
+ if (data.loginType == 2 || data.loginType == 3){
|
|
|
|
|
+ this.formData.flgCanWxLogin = true
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
// endregion
|
|
// endregion
|
|
|
},
|
|
},
|
|
|
created() {
|
|
created() {
|