|
@@ -25,6 +25,7 @@
|
|
|
<a-form-item label="账户名称"
|
|
<a-form-item label="账户名称"
|
|
|
name="logincode">
|
|
name="logincode">
|
|
|
<a-input class="dialogInput"
|
|
<a-input class="dialogInput"
|
|
|
|
|
+ readonly
|
|
|
style="width: 200px"
|
|
style="width: 200px"
|
|
|
v-model:value="formState.logincode"
|
|
v-model:value="formState.logincode"
|
|
|
placeholder="请输入账户名称" />
|
|
placeholder="请输入账户名称" />
|
|
@@ -35,25 +36,18 @@
|
|
|
name="accountname">
|
|
name="accountname">
|
|
|
<a-input class="dialogInput"
|
|
<a-input class="dialogInput"
|
|
|
style="width: 200px"
|
|
style="width: 200px"
|
|
|
|
|
+ readonly
|
|
|
v-model:value="formState.accountname"
|
|
v-model:value="formState.accountname"
|
|
|
placeholder="请输入登录账号" />
|
|
placeholder="请输入登录账号" />
|
|
|
</a-form-item>
|
|
</a-form-item>
|
|
|
</a-col>
|
|
</a-col>
|
|
|
<a-col :span="12">
|
|
<a-col :span="12">
|
|
|
- <a-form-item label="登录密码"
|
|
|
|
|
- name="password">
|
|
|
|
|
- <a-input-password class="dialogInput"
|
|
|
|
|
- style="width: 200px"
|
|
|
|
|
- v-model:value="formState.password"
|
|
|
|
|
- placeholder="请输入登录密码" />
|
|
|
|
|
- </a-form-item>
|
|
|
|
|
- </a-col>
|
|
|
|
|
- <a-col :span="24">
|
|
|
|
|
<a-form-item label="手机号码"
|
|
<a-form-item label="手机号码"
|
|
|
name="mobile">
|
|
name="mobile">
|
|
|
<a-input class="dialogInput"
|
|
<a-input class="dialogInput"
|
|
|
v-model:value="formState.mobile"
|
|
v-model:value="formState.mobile"
|
|
|
style="width: 200px"
|
|
style="width: 200px"
|
|
|
|
|
+ readonly
|
|
|
placeholder="请输入手机号码" />
|
|
placeholder="请输入手机号码" />
|
|
|
</a-form-item>
|
|
</a-form-item>
|
|
|
</a-col>
|
|
</a-col>
|
|
@@ -62,10 +56,10 @@
|
|
|
class="checkboxGroupItem"
|
|
class="checkboxGroupItem"
|
|
|
name="logintaaccounts">
|
|
name="logintaaccounts">
|
|
|
<a-checkbox-group class="commonCheckboxGroup"
|
|
<a-checkbox-group class="commonCheckboxGroup"
|
|
|
- v-model:value="formState.logintaaccounts">
|
|
|
|
|
|
|
+ v-model:checked="checkedList">
|
|
|
<a-row>
|
|
<a-row>
|
|
|
<a-col :span="12"
|
|
<a-col :span="12"
|
|
|
- v-for="(item, index) in accountList"
|
|
|
|
|
|
|
+ v-for="(item, index) in selectedData.acclist"
|
|
|
:key="index">
|
|
:key="index">
|
|
|
<a-checkbox :value="item.accountid">{{item.accountname}}/{{item.accountid}}</a-checkbox>
|
|
<a-checkbox :value="item.accountid">{{item.accountname}}/{{item.accountid}}</a-checkbox>
|
|
|
</a-col>
|
|
</a-col>
|
|
@@ -82,8 +76,8 @@
|
|
|
import { defineComponent, PropType, ref, watchEffect } from 'vue';
|
|
import { defineComponent, PropType, ref, watchEffect } from 'vue';
|
|
|
import { closeModal } from '@/common/setup/modal/index';
|
|
import { closeModal } from '@/common/setup/modal/index';
|
|
|
import { mergeTwoObj } from '@/utils/objHandle';
|
|
import { mergeTwoObj } from '@/utils/objHandle';
|
|
|
-import { handleBusinessForm } from '../setup';
|
|
|
|
|
-import { ErmcpLoginUser, ErmcpLoginUserEx } from '@/services/go/ermcp/account/interface';
|
|
|
|
|
|
|
+import { handleBusinessForm, handleRoleName } from '../setup';
|
|
|
|
|
+import { ErmcpLoginUser, ErmcpLoginUserEx, ErmcpTaAccount } from '@/services/go/ermcp/account/interface';
|
|
|
|
|
|
|
|
export default defineComponent({
|
|
export default defineComponent({
|
|
|
name: 'trader-detail',
|
|
name: 'trader-detail',
|
|
@@ -97,21 +91,22 @@ export default defineComponent({
|
|
|
type: Array as PropType<ErmcpLoginUserEx[]>,
|
|
type: Array as PropType<ErmcpLoginUserEx[]>,
|
|
|
default: [],
|
|
default: [],
|
|
|
},
|
|
},
|
|
|
|
|
+ accountList: {
|
|
|
|
|
+ default: [],
|
|
|
|
|
+ type: Object as PropType<ErmcpTaAccount[]>,
|
|
|
|
|
+ },
|
|
|
},
|
|
},
|
|
|
setup(props) {
|
|
setup(props) {
|
|
|
const { visible, cancel } = closeModal('detail');
|
|
const { visible, cancel } = closeModal('detail');
|
|
|
const { formState } = handleBusinessForm();
|
|
const { formState } = handleBusinessForm();
|
|
|
- const rolename = ref<string>('');
|
|
|
|
|
|
|
+ const { rolename, getRoleName } = handleRoleName();
|
|
|
|
|
+ const checkedList = ref<number[]>([]);
|
|
|
watchEffect(() => {
|
|
watchEffect(() => {
|
|
|
if (visible.value) {
|
|
if (visible.value) {
|
|
|
- mergeTwoObj(formState, props.selectedData);
|
|
|
|
|
- props.tableList.forEach((el) => {
|
|
|
|
|
- el.userlist.forEach((item) => {
|
|
|
|
|
- if (item.loginid === props.selectedData.loginid) {
|
|
|
|
|
- rolename.value = el.rolename;
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ const { selectedData, tableList } = props;
|
|
|
|
|
+ mergeTwoObj(formState, selectedData);
|
|
|
|
|
+ getRoleName(tableList, selectedData);
|
|
|
|
|
+ checkedList.value = selectedData.acclist.map((e) => e.accountid);
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
return {
|
|
return {
|
|
@@ -120,6 +115,7 @@ export default defineComponent({
|
|
|
formState,
|
|
formState,
|
|
|
maskClosableFlag: false,
|
|
maskClosableFlag: false,
|
|
|
rolename,
|
|
rolename,
|
|
|
|
|
+ checkedList,
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
});
|
|
});
|