|
@@ -5,6 +5,7 @@
|
|
|
v-model:visible="visible"
|
|
v-model:visible="visible"
|
|
|
@cancel="cancel"
|
|
@cancel="cancel"
|
|
|
centered
|
|
centered
|
|
|
|
|
+ :loading="loading"
|
|
|
:maskClosable="false"
|
|
:maskClosable="false"
|
|
|
width="890px">
|
|
width="890px">
|
|
|
<template #footer>
|
|
<template #footer>
|
|
@@ -21,37 +22,41 @@
|
|
|
<a-col :span="12">
|
|
<a-col :span="12">
|
|
|
<a-form-item label="所属用户"
|
|
<a-form-item label="所属用户"
|
|
|
name="">
|
|
name="">
|
|
|
- <span class="white">王凌团队</span>
|
|
|
|
|
|
|
+ <span class="white">{{selectedData.rolename}}</span>
|
|
|
</a-form-item>
|
|
</a-form-item>
|
|
|
</a-col>
|
|
</a-col>
|
|
|
<a-col :span="12">
|
|
<a-col :span="12">
|
|
|
<a-form-item label="账户名称"
|
|
<a-form-item label="账户名称"
|
|
|
- name="">
|
|
|
|
|
|
|
+ name="logincode">
|
|
|
<a-input class="dialogInput"
|
|
<a-input class="dialogInput"
|
|
|
style="width: 200px"
|
|
style="width: 200px"
|
|
|
|
|
+ v-model:value="formState.logincode"
|
|
|
placeholder="请输入账户名称" />
|
|
placeholder="请输入账户名称" />
|
|
|
</a-form-item>
|
|
</a-form-item>
|
|
|
</a-col>
|
|
</a-col>
|
|
|
<a-col :span="12">
|
|
<a-col :span="12">
|
|
|
<a-form-item label="登录账号"
|
|
<a-form-item label="登录账号"
|
|
|
- name="">
|
|
|
|
|
|
|
+ name="accountname">
|
|
|
<a-input class="dialogInput"
|
|
<a-input class="dialogInput"
|
|
|
style="width: 200px"
|
|
style="width: 200px"
|
|
|
|
|
+ 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="登录密码"
|
|
<a-form-item label="登录密码"
|
|
|
- name="">
|
|
|
|
|
|
|
+ name="password">
|
|
|
<a-input-password class="dialogInput"
|
|
<a-input-password class="dialogInput"
|
|
|
style="width: 200px"
|
|
style="width: 200px"
|
|
|
|
|
+ v-model:value="formState.password"
|
|
|
placeholder="请输入登录密码" />
|
|
placeholder="请输入登录密码" />
|
|
|
</a-form-item>
|
|
</a-form-item>
|
|
|
</a-col>
|
|
</a-col>
|
|
|
<a-col :span="24">
|
|
<a-col :span="24">
|
|
|
<a-form-item label="手机号码"
|
|
<a-form-item label="手机号码"
|
|
|
- name="">
|
|
|
|
|
|
|
+ name="mobile">
|
|
|
<a-input class="dialogInput"
|
|
<a-input class="dialogInput"
|
|
|
|
|
+ v-model:value="formState.mobile"
|
|
|
style="width: 200px"
|
|
style="width: 200px"
|
|
|
placeholder="请输入手机号码" />
|
|
placeholder="请输入手机号码" />
|
|
|
</a-form-item>
|
|
</a-form-item>
|
|
@@ -59,22 +64,14 @@
|
|
|
<a-col :span="24">
|
|
<a-col :span="24">
|
|
|
<a-form-item label="授权期货账户"
|
|
<a-form-item label="授权期货账户"
|
|
|
class="checkboxGroupItem"
|
|
class="checkboxGroupItem"
|
|
|
- name="">
|
|
|
|
|
- <a-checkbox-group class="commonCheckboxGroup">
|
|
|
|
|
|
|
+ name="logintaaccounts">
|
|
|
|
|
+ <a-checkbox-group class="commonCheckboxGroup"
|
|
|
|
|
+ v-model:value="formState.logintaaccounts">
|
|
|
<a-row>
|
|
<a-row>
|
|
|
- <a-col :span="12">
|
|
|
|
|
- <a-checkbox value="A">期货子账户/250000010003</a-checkbox>
|
|
|
|
|
- </a-col>
|
|
|
|
|
- <a-col :span="12">
|
|
|
|
|
- <a-checkbox value="B">铜套保专用账户/25000000011</a-checkbox>
|
|
|
|
|
- </a-col>
|
|
|
|
|
<a-col :span="12"
|
|
<a-col :span="12"
|
|
|
- class="mt20">
|
|
|
|
|
- <a-checkbox value="C">银套保专用账户/250000010003</a-checkbox>
|
|
|
|
|
- </a-col>
|
|
|
|
|
- <a-col :span="12"
|
|
|
|
|
- class="mt20">
|
|
|
|
|
- <a-checkbox value="D">铁矿石套保专用账户/25000000013Q</a-checkbox>
|
|
|
|
|
|
|
+ v-for="(item, index) in accountList"
|
|
|
|
|
+ :key="index">
|
|
|
|
|
+ <a-checkbox :value="item.accountid">{{item.accountname}}/{{item.accountid}}</a-checkbox>
|
|
|
</a-col>
|
|
</a-col>
|
|
|
</a-row>
|
|
</a-row>
|
|
|
</a-checkbox-group>
|
|
</a-checkbox-group>
|
|
@@ -87,55 +84,54 @@
|
|
|
|
|
|
|
|
<script lang="ts">
|
|
<script lang="ts">
|
|
|
import { closeModal } from '@/common/setup/modal/index';
|
|
import { closeModal } from '@/common/setup/modal/index';
|
|
|
-import { initData } from '@/common/methods/index';
|
|
|
|
|
-import { defineComponent, ref, reactive, toRaw, UnwrapRef } from 'vue';
|
|
|
|
|
-import { AllEnums } from '@/services/go/commonService/interface';
|
|
|
|
|
-import { RuleObject, ValidateErrorEntity } from 'ant-design-vue/es/form/interface';
|
|
|
|
|
|
|
+import { defineComponent, ref, PropType, watchEffect } from 'vue';
|
|
|
|
|
+import { ErmcpLoginUserEx, ErmcpTaAccount } from '@/services/go/ermcp/account/interface';
|
|
|
|
|
+import { queryTableList } from '../../list/account_info_futures/setup';
|
|
|
|
|
+import { queryResultLoadingAndInfo } from '@/common/methods/request/resultInfo';
|
|
|
|
|
+import { handleBusinessForm } from '../setup';
|
|
|
|
|
+import { validateAction } from '@/common/methods/form';
|
|
|
|
|
+import { BusinessFormState } from '../interface';
|
|
|
|
|
|
|
|
export default defineComponent({
|
|
export default defineComponent({
|
|
|
- name: 'add-custom',
|
|
|
|
|
|
|
+ name: 'account_info_trade_btn_add',
|
|
|
components: {},
|
|
components: {},
|
|
|
- setup() {
|
|
|
|
|
|
|
+ props: {
|
|
|
|
|
+ selectedData: {
|
|
|
|
|
+ default: {},
|
|
|
|
|
+ type: Object as PropType<ErmcpLoginUserEx>,
|
|
|
|
|
+ },
|
|
|
|
|
+ },
|
|
|
|
|
+ setup(props) {
|
|
|
|
|
+ const { loading, tableList, queryTable } = queryTableList();
|
|
|
|
|
+ const accountList = ref<ErmcpTaAccount[]>([]);
|
|
|
// 控制关闭弹窗
|
|
// 控制关闭弹窗
|
|
|
const { visible, cancel } = closeModal('account_info_trade_btn_add');
|
|
const { visible, cancel } = closeModal('account_info_trade_btn_add');
|
|
|
- // 证件类型
|
|
|
|
|
- // const cardTypeList = ref<AllEnums[]>(getCardType());
|
|
|
|
|
- // // 表单
|
|
|
|
|
- // const formRef = ref();
|
|
|
|
|
- // const formState: UnwrapRef<FormState> = reactive(initFormState());
|
|
|
|
|
- // const rules = {
|
|
|
|
|
- // userinfotype: [{ required: true, message: '请选择客户类型', trigger: 'change' }],
|
|
|
|
|
- // customername: [{ required: true, message: '请输入企业名称', trigger: 'blur' }],
|
|
|
|
|
- // nickname: [{ required: true, message: '请输入企业简称', trigger: 'blur' }],
|
|
|
|
|
- // cardtype: [{ required: true, message: '请选择证件类型', trigger: 'change' }],
|
|
|
|
|
- // };
|
|
|
|
|
- // // 下单方法
|
|
|
|
|
- // const { loading, applyAction } = handleApply();
|
|
|
|
|
- // function isPersonal(): boolean {
|
|
|
|
|
- // return formState.userinfotype === '1';
|
|
|
|
|
- // }
|
|
|
|
|
- // function submit() {
|
|
|
|
|
- // formRef.value
|
|
|
|
|
- // .validate()
|
|
|
|
|
- // .then(() => {
|
|
|
|
|
- // const param = toRaw(formState);
|
|
|
|
|
- // applyAction(param);
|
|
|
|
|
- // console.log('values', formState);
|
|
|
|
|
- // })
|
|
|
|
|
- // .catch((error: ValidateErrorEntity<FormState>) => {
|
|
|
|
|
- // console.log('error', error);
|
|
|
|
|
- // });
|
|
|
|
|
- // }
|
|
|
|
|
|
|
+ const { rules, formState, formRef } = handleBusinessForm();
|
|
|
|
|
+ watchEffect(() => {
|
|
|
|
|
+ if (visible.value) {
|
|
|
|
|
+ // 处理授权期货账户
|
|
|
|
|
+ queryResultLoadingAndInfo(queryTable, loading).then(() => {
|
|
|
|
|
+ accountList.value.length = 0;
|
|
|
|
|
+ tableList.value.forEach(({ mainAcc, subacclist }) => {
|
|
|
|
|
+ accountList.value.push(mainAcc);
|
|
|
|
|
+ subacclist.forEach((e) => accountList.value.push(e));
|
|
|
|
|
+ });
|
|
|
|
|
+ });
|
|
|
|
|
+ }
|
|
|
|
|
+ });
|
|
|
|
|
+
|
|
|
|
|
+ function submit() {
|
|
|
|
|
+ validateAction<BusinessFormState>(formRef, formState).then((res) => {});
|
|
|
|
|
+ }
|
|
|
return {
|
|
return {
|
|
|
- // formState,
|
|
|
|
|
- // rules,
|
|
|
|
|
- // formRef,
|
|
|
|
|
- // cardTypeList,
|
|
|
|
|
- // isPersonal,
|
|
|
|
|
|
|
+ formState,
|
|
|
|
|
+ rules,
|
|
|
|
|
+ formRef,
|
|
|
visible,
|
|
visible,
|
|
|
cancel,
|
|
cancel,
|
|
|
- // submit,
|
|
|
|
|
- // loading,
|
|
|
|
|
|
|
+ submit,
|
|
|
|
|
+ loading,
|
|
|
|
|
+ accountList,
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
});
|
|
});
|
|
@@ -236,3 +232,4 @@ export default defineComponent({
|
|
|
}
|
|
}
|
|
|
</style
|
|
</style
|
|
|
>;
|
|
>;
|
|
|
|
|
+
|