Handy_Cao 7 月之前
父節點
當前提交
b52f217f0a

+ 22 - 1
public/locales/en-US.json

@@ -1091,7 +1091,28 @@
                     "subtitle2": "Commodity query permission",
                     "accountname": "Name",
                     "userName": "Administrator",
-                    "reckonaccountid": "Capital account"
+                    "reckonaccountid": "Capital account",
+                    "subtitle1": "风险率信息",
+                    "username": "交易商:",
+                    "accountid": "资金账户:",
+                    "customertype": "风险率类型:",
+                    "riskcontrolmode": "风控模式:",
+                    "riskcontrolmode1": "交易商",
+                    "riskcontrolmode2": "做市会员",
+                    "customertype1": "客户类别:",
+                    "riskratiocalcmode": "风险率计算方式:",
+                    "riskratiocalcmode1": "占用/净值",
+                    "riskratiocalcmode2": "值/占用",
+                    "notemarginriskratio": "提示保证金风险率:",
+                    "addmarginriskratio": "追加保证金风险率:",
+                    "cutriskratio": "斩仓风险率:",
+                    "cutbackriskratio": "斩仓恢复风险率:",
+                    "notesaferatio": "提示安全度:",
+                    "addsaferatio": "追加安全度:",
+                    "recoversaferatio": "恢复正常安全度:",
+                    "cutsaferatio": "斩仓安全度:",
+                    "isdefault": "是否默认:",
+                    "markets": "斩仓市场顺序:"
                 }
             },
             "marketing": {

+ 22 - 1
public/locales/th-TH.json

@@ -1091,7 +1091,28 @@
                     "subtitle2": "สิทธิการค้นหาสินค้า",
                     "accountname": "ชื่อ",
                     "userName": "ผู้ดูแลระบบ",
-                    "reckonaccountid": "บัญชีเงิน"
+                    "reckonaccountid": "บัญชีเงิน",
+                    "subtitle1": "风险率信息",
+                    "username": "交易商:",
+                    "accountid": "资金账户:",
+                    "customertype": "风险率类型:",
+                    "riskcontrolmode": "风控模式:",
+                    "riskcontrolmode1": "交易商",
+                    "riskcontrolmode2": "做市会员",
+                    "customertype1": "客户类别:",
+                    "riskratiocalcmode": "风险率计算方式:",
+                    "riskratiocalcmode1": "占用/净值",
+                    "riskratiocalcmode2": "值/占用",
+                    "notemarginriskratio": "提示保证金风险率:",
+                    "addmarginriskratio": "追加保证金风险率:",
+                    "cutriskratio": "斩仓风险率:",
+                    "cutbackriskratio": "斩仓恢复风险率:",
+                    "notesaferatio": "提示安全度:",
+                    "addsaferatio": "追加安全度:",
+                    "recoversaferatio": "恢复正常安全度:",
+                    "cutsaferatio": "斩仓安全度:",
+                    "isdefault": "是否默认:",
+                    "markets": "斩仓市场顺序:"
                 }
             },
             "marketing": {

+ 22 - 1
public/locales/vi-VN.json

@@ -1091,7 +1091,28 @@
                     "subtitle2": "Quyền truy vấn sản phẩm",
                     "accountname": "Tên",
                     "userName": "Quản trị viên",
-                    "reckonaccountid": "Tài khoản tiền"
+                    "reckonaccountid": "Tài khoản tiền",
+                    "subtitle1": "风险率信息",
+                    "username": "交易商:",
+                    "accountid": "资金账户:",
+                    "customertype": "风险率类型:",
+                    "riskcontrolmode": "风控模式:",
+                    "riskcontrolmode1": "交易商",
+                    "riskcontrolmode2": "做市会员",
+                    "customertype1": "客户类别:",
+                    "riskratiocalcmode": "风险率计算方式:",
+                    "riskratiocalcmode1": "占用/净值",
+                    "riskratiocalcmode2": "值/占用",
+                    "notemarginriskratio": "提示保证金风险率:",
+                    "addmarginriskratio": "追加保证金风险率:",
+                    "cutriskratio": "斩仓风险率:",
+                    "cutbackriskratio": "斩仓恢复风险率:",
+                    "notesaferatio": "提示安全度:",
+                    "addsaferatio": "追加安全度:",
+                    "recoversaferatio": "恢复正常安全度:",
+                    "cutsaferatio": "斩仓安全度:",
+                    "isdefault": "是否默认:",
+                    "markets": "斩仓市场顺序:"
                 }
             },
             "marketing": {

+ 23 - 2
public/locales/zh-CN.json

@@ -1091,7 +1091,28 @@
                     "subtitle2": "商品查询权限",
                     "accountname": "名称",
                     "userName": "管理员",
-                    "reckonaccountid": "资金账户"
+                    "reckonaccountid": "资金账户",
+                    "subtitle1": "风险率信息",
+                    "username": "交易商:",
+                    "accountid": "资金账户:",
+                    "customertype": "风险率类型:",
+                    "riskcontrolmode": "风控模式:",
+                    "riskcontrolmode1": "交易商",
+                    "riskcontrolmode2": "做市会员",
+                    "customertype1": "客户类别:",
+                    "riskratiocalcmode": "风险率计算方式:",
+                    "riskratiocalcmode1": "占用/净值",
+                    "riskratiocalcmode2": "值/占用",
+                    "notemarginriskratio": "提示保证金风险率:",
+                    "addmarginriskratio": "追加保证金风险率:",
+                    "cutriskratio": "斩仓风险率:",
+                    "cutbackriskratio": "斩仓恢复风险率:",
+                    "notesaferatio": "提示安全度:",
+                    "addsaferatio": "追加安全度:",
+                    "recoversaferatio": "恢复正常安全度:",
+                    "cutsaferatio": "斩仓安全度:",
+                    "isdefault": "是否默认:",
+                    "markets": "斩仓市场顺序:"
                 }
             },
             "marketing": {
@@ -1216,7 +1237,7 @@
                 "tips1": "请选择会员",
                 "tips2": "输入代码或名称",
                 "details": {
-                    "title": "编辑",
+                    "title": "详情",
                     "subtitle": "基本信息设置",
                     "subtitle1": "风险率信息",
                     "username": "交易商:",

+ 22 - 1
public/locales/zh-TW.json

@@ -1091,7 +1091,28 @@
                     "subtitle2": "商品查詢權限",
                     "accountname": "名稱",
                     "userName": "管理員",
-                    "reckonaccountid": "資金帳戶"
+                    "reckonaccountid": "資金帳戶",
+                    "subtitle1": "风险率信息",
+                    "username": "交易商:",
+                    "accountid": "资金账户:",
+                    "customertype": "风险率类型:",
+                    "riskcontrolmode": "风控模式:",
+                    "riskcontrolmode1": "交易商",
+                    "riskcontrolmode2": "做市会员",
+                    "customertype1": "客户类别:",
+                    "riskratiocalcmode": "风险率计算方式:",
+                    "riskratiocalcmode1": "占用/净值",
+                    "riskratiocalcmode2": "值/占用",
+                    "notemarginriskratio": "提示保证金风险率:",
+                    "addmarginriskratio": "追加保证金风险率:",
+                    "cutriskratio": "斩仓风险率:",
+                    "cutbackriskratio": "斩仓恢复风险率:",
+                    "notesaferatio": "提示安全度:",
+                    "addsaferatio": "追加安全度:",
+                    "recoversaferatio": "恢复正常安全度:",
+                    "cutsaferatio": "斩仓安全度:",
+                    "isdefault": "是否默认:",
+                    "markets": "斩仓市场顺序:"
                 }
             },
             "marketing": {

+ 6 - 15
src/packages/pc/views/member/institution/broker/components/details/index.vue

@@ -2,16 +2,17 @@
 <template>
     <app-drawer :title="t('member.institution.broker.details.title')" width="900" v-model:show="show" :loading="loading" :refresh="refresh">
         <app-table-details :title="t('member.institution.broker.details.subtitle')" :data="data?.organ" :label-width="160" :cell-props="detailProps1" :column="2" />
-        <!-- <app-table-details title="商品查询权限" :data="goodslimit" :label-width="160" :cell-props="detailProps2" :column="1">
-            
-        </app-table-details> -->
         <span>
-            <span>{{ t('member.institution.broker.details.subtitle1') }}</span>
+            <span>市场</span>
+            <span>市场权限:</span>
             <span v-for="item in goodslimit" v-bind:key="item.id">
                 <span>{{ item.title }}: </span>
-                <span>{{ item.value }}</span>
             </span> 
         </span>
+        <span>
+            <span>市场</span>
+            <span>移动端开户地址: {{ data?.transurl }}</span>
+        </span>
         <template #footer>
             <el-button @click="onCancel(false)">{{ t('operation.close') }}</el-button>
         </template>
@@ -70,16 +71,6 @@ const goodslimit = computed(() => {
     }) ?? []
 })
 
-// const detailProps2 = computed(() => {
-//     return data.value?.markets.map<CellProp>(e =>({ 
-//         prop: e.marketid.toString(), 
-//         label: e.marketname,
-//         formatValue: (val) => {
-//             return data.value?.operategoodsinfo.filter(e => e.marketid === val).map(e => e.goodsname).join(',')
-//         },
-//      }) ) ?? []
-// }) 
-
 const onCancel = (isRefresh = false) => {
     show.value = false
     refresh.value = isRefresh

+ 0 - 14
src/packages/pc/views/member/institution/industry/components/details/index.vue

@@ -2,14 +2,10 @@
 <template>
     <app-drawer :title="t('member.institution.industry.details.title')" width="900" v-model:show="show" :loading="loading" :refresh="refresh">
         <app-table-details :title="t('member.institution.industry.details.subtitle')" :data="data?.organ" :label-width="160" :cell-props="detailProps1" :column="2" />
-        <!-- <app-table-details title="商品查询权限" :data="goodslimit" :label-width="160" :cell-props="detailProps2" :column="1">
-            
-        </app-table-details> -->
         <span>
             <span>{{ t('member.institution.industry.details.subtitle2') }}</span>
             <span v-for="item in goodslimit" v-bind:key="item.id">
                 <span>{{ item.title }}: </span>
-                <span>{{ item.value }}</span>
             </span> 
         </span>
         <template #footer>
@@ -70,16 +66,6 @@ const goodslimit = computed(() => {
     }) ?? []
 })
 
-// const detailProps2 = computed(() => {
-//     return data.value?.markets.map<CellProp>(e =>({ 
-//         prop: e.marketid.toString(), 
-//         label: e.marketname,
-//         formatValue: (val) => {
-//             return data.value?.operategoodsinfo.filter(e => e.marketid === val).map(e => e.goodsname).join(',')
-//         },
-//      }) ) ?? []
-// }) 
-
 const onCancel = (isRefresh = false) => {
     show.value = false
     refresh.value = isRefresh

+ 44 - 32
src/packages/pc/views/member/institution/marketer/components/details/index.vue

@@ -1,17 +1,9 @@
 <!-- 会员机构管理-机构管理-做市会员管理-详情 -->
 <template>
-    <app-drawer :title="t('member.institution.marketer.details.title')" width="900" v-model:show="show" :loading="loading" :refresh="refresh">
+    <app-drawer title="详情" width="900" v-model:show="show" :loading="loading" :refresh="refresh">
         <app-table-details :title="t('member.institution.marketer.details.subtitle')" :data="data?.organ" :label-width="160" :cell-props="detailProps1" :column="2" />
-        <!-- <app-table-details title="商品查询权限" :data="goodslimit" :label-width="160" :cell-props="detailProps2" :column="1">
-            
-        </app-table-details> -->
-        <span>
-            <span>{{ t('member.institution.marketer.details.subtitle2') }}</span>
-            <span v-for="item in goodslimit" v-bind:key="item.id">
-                <span>{{ item.title }}: </span>
-                <span>{{ item.value }}</span>
-            </span> 
-        </span>
+        <app-table-details title="默认做市商资金账户" :data="data?.roleNight[0]" :label-width="160" :cell-props="detailProps2" :column="1" />
+        <app-table-details title="风险率信息" :data="marker" :label-width="160" :cell-props="detailProps3" :column="2" />
         <template #footer>
             <el-button @click="onCancel(false)">{{ t('operation.close') }}</el-button>
         </template>
@@ -24,12 +16,17 @@ import { ElMessage } from 'element-plus'
 import { i18n } from '@/stores'
 import { useRequest } from '@/hooks/request'
 import { CellProp } from '@pc/components/base/table-details/types'
-
+import { useEnum } from '@/hooks/enum'
 import { queryRoleDetail } from '@/services/api/member'
+import { getConfirmationName } from '@/constants/common'
+import { getRiskRatioTypeForMarketer } from '@/services/api/investor'
 import AppDrawer from '@pc/components/base/drawer/index.vue'
 import AppTableDetails from '@pc/components/base/table-details/index.vue'
 
 const { global: { t } } = i18n
+const customerTypeEnum = useEnum('customerType')
+// 风险率类型
+const marketerTypeEnum = useEnum('marketerType')
 
 const props = defineProps({
     record: {
@@ -41,6 +38,7 @@ const props = defineProps({
 const show = shallowRef(true)
 const refresh = shallowRef(false)
 const loading = shallowRef(false)
+const marker = shallowRef<Investor.RiskRatioTypeForMarketerRsp>()
 
 const { data } = useRequest(queryRoleDetail, {
     params: {
@@ -49,6 +47,16 @@ const { data } = useRequest(queryRoleDetail, {
     },
     onError: (err) => {
         ElMessage.error(err)
+    },
+    onSuccess: (res) => {
+        getRiskRatioTypeForMarketer({
+            data: {
+                riskcontrolmode: 2,
+                customertype: res.data.customertype.customertype
+            }
+        }).then((data) => {
+            marker.value = data.data
+        })
     }
 })
 
@@ -56,29 +64,33 @@ const detailProps1: CellProp[] = [
     { prop: 'accountname', label: 'member.institution.marketer.details.accountname' },
     { prop: 'userName', label: 'member.institution.marketer.details.userName', formatValue: () => {
         return data.value?.users.username
-    }, },
-    { prop: 'reckonaccountid', label: 'member.institution.marketer.details.reckonaccountid' }
+    } },
+    { prop: 'customertype', label: '客户类别:', formatValue: () => customerTypeEnum.getEnumTypeName(data.value?.customertype.customertype) }
 ]
 
-const goodslimit = computed(() => {
-    return data.value?.markets.map(e => {
-        return {
-            id: e.marketid,
-            title: e.marketname,
-            value: data.value?.operategoodsinfo?.filter(g => g.marketid === e.marketid).map(e => e.goodsname).join(','),
-        }
-    }) ?? []
-})
+const detailProps2: CellProp[] = [
+    { prop: 'enumdicname', label: '*币种'},
+    { prop: 'reckonaccountid', label: '*资金账户' }
+]
 
-// const detailProps2 = computed(() => {
-//     return data.value?.markets.map<CellProp>(e =>({ 
-//         prop: e.marketid.toString(), 
-//         label: e.marketname,
-//         formatValue: (val) => {
-//             return data.value?.operategoodsinfo.filter(e => e.marketid === val).map(e => e.goodsname).join(',')
-//         },
-//      }) ) ?? []
-// }) 
+const detailProps3 = computed<CellProp[]>(() => {
+    const { notesaferatio } = marker.value ?? {}
+    return [
+        { prop: 'riskcontrolmode', label: 'member.institution.marketer.details.riskcontrolmode', formatValue: (val) => val === 1 ? t('member.institution.marketer.details.riskcontrolmode1') : t('member.institution.marketer.details.riskcontrolmode2') },
+        { prop: 'customertype', label: 'member.institution.marketer.details.customertype1', formatValue: (val) => marketerTypeEnum.getEnumTypeName(val) },
+        { prop: 'riskratiocalcmode', label: 'member.institution.marketer.details.riskratiocalcmode', formatValue: (val) => val === 1 ? t('member.institution.marketer.details.riskratiocalcmode1') : t('member.institution.marketer.details.riskratiocalcmode2') },
+        { prop: 'notemarginriskratio', label: 'member.institution.marketer.details.notemarginriskratio', formatValue: (val) => val + '%', show: !notesaferatio },
+        { prop: 'addmarginriskratio', label: 'member.institution.marketer.details.addmarginriskratio', formatValue: (val) => val + '%', show: !notesaferatio },
+        { prop: 'cutriskratio', label: 'member.institution.marketer.details.cutriskratio', formatValue: (val) => val + '%', show: !notesaferatio },
+        { prop: 'cutbackriskratio', label: 'member.institution.marketer.details.cutbackriskratio', formatValue: (val) => val + '%', show: !notesaferatio },
+        { prop: 'notesaferatio', label: 'member.institution.marketer.details.notesaferatio', formatValue: (val) => val + '%', show: !!notesaferatio },
+        { prop: 'addsaferatio', label: 'member.institution.marketer.details.addsaferatio', formatValue: (val) => val + '%', show: !!notesaferatio },
+        { prop: 'recoversaferatio', label: 'member.institution.marketer.details.recoversaferatio', formatValue: (val) => val + '%', show: !!notesaferatio },
+        { prop: 'cutsaferatio', label: 'member.institution.marketer.details.cutsaferatio', formatValue: (val) => val + '%', show: !!notesaferatio },
+        { prop: 'isdefault', label: 'member.institution.marketer.details.isdefault', formatValue: (val) => getConfirmationName(val) },
+        { prop: 'markets', label: 'member.institution.marketer.details.markets' },
+    ]
+})
 
 const onCancel = (isRefresh = false) => {
     show.value = false

+ 0 - 30
src/packages/pc/views/member/institution/marketing/components/details/index.vue

@@ -2,16 +2,6 @@
 <template>
     <app-drawer :title="t('member.institution.marketing.details.title')" width="900" v-model:show="show" :loading="loading" :refresh="refresh">
         <app-table-details :title="t('member.institution.marketing.details.subtitle')" :data="data?.organ" :label-width="160" :cell-props="detailProps1" :column="2" />
-        <!-- <app-table-details title="商品查询权限" :data="goodslimit" :label-width="160" :cell-props="detailProps2" :column="1">
-            
-        </app-table-details> -->
-        <span>
-            <span>{{ t('member.institution.marketing.details.subtitle2') }}</span>
-            <span v-for="item in goodslimit" v-bind:key="item.id">
-                <span>{{ item.title }}: </span>
-                <span>{{ item.value }}</span>
-            </span> 
-        </span>
         <template #footer>
             <el-button @click="onCancel(false)">{{ t('operation.close') }}</el-button>
         </template>
@@ -60,26 +50,6 @@ const detailProps1: CellProp[] = [
     { prop: 'reckonaccountid', label: 'member.institution.marketing.details.reckonaccountid' }
 ]
 
-const goodslimit = computed(() => {
-    return data.value?.markets.map(e => {
-        return {
-            id: e.marketid,
-            title: e.marketname,
-            value: data.value?.operategoodsinfo?.filter(g => g.marketid === e.marketid).map(e => e.goodsname).join(','),
-        }
-    }) ?? []
-})
-
-// const detailProps2 = computed(() => {
-//     return data.value?.markets.map<CellProp>(e =>({ 
-//         prop: e.marketid.toString(), 
-//         label: e.marketname,
-//         formatValue: (val) => {
-//             return data.value?.operategoodsinfo.filter(e => e.marketid === val).map(e => e.goodsname).join(',')
-//         },
-//      }) ) ?? []
-// }) 
-
 const onCancel = (isRefresh = false) => {
     show.value = false
     refresh.value = isRefresh

+ 1 - 15
src/packages/pc/views/member/institution/operation/components/details/index.vue

@@ -2,9 +2,6 @@
 <template>
     <app-drawer :title="t('member.institution.operation.details.title')" width="900" v-model:show="show" :loading="loading" :refresh="refresh">
         <app-table-details :title="t('member.institution.operation.details.subtitle')" :data="data?.organ" :label-width="160" :cell-props="detailProps1" :column="2" />
-        <!-- <app-table-details title="商品查询权限" :data="goodslimit" :label-width="160" :cell-props="detailProps2" :column="1">
-            
-        </app-table-details> -->
         <span>
             <span>{{ t('member.institution.operation.details.subtitle2') }}</span>
             <span v-for="item in goodslimit" v-bind:key="item.id">
@@ -24,7 +21,6 @@ import { ElMessage } from 'element-plus'
 import { i18n } from '@/stores'
 import { useRequest } from '@/hooks/request'
 import { CellProp } from '@pc/components/base/table-details/types'
-
 import { queryRoleDetail } from '@/services/api/member'
 import AppDrawer from '@pc/components/base/drawer/index.vue'
 import AppTableDetails from '@pc/components/base/table-details/index.vue'
@@ -61,7 +57,7 @@ const detailProps1: CellProp[] = [
 ]
 
 const goodslimit = computed(() => {
-    return data.value?.markets.map(e => {
+    return data.value?.operatemarkets.map(e => {
         return {
             id: e.marketid,
             title: e.marketname,
@@ -70,16 +66,6 @@ const goodslimit = computed(() => {
     }) ?? []
 })
 
-// const detailProps2 = computed(() => {
-//     return data.value?.markets.map<CellProp>(e =>({ 
-//         prop: e.marketid.toString(), 
-//         label: e.marketname,
-//         formatValue: (val) => {
-//             return data.value?.operategoodsinfo.filter(e => e.marketid === val).map(e => e.goodsname).join(',')
-//         },
-//      }) ) ?? []
-// }) 
-
 const onCancel = (isRefresh = false) => {
     show.value = false
     refresh.value = isRefresh

+ 1 - 16
src/packages/pc/views/member/institution/self/components/details/index.vue

@@ -2,14 +2,10 @@
 <template>
     <app-drawer :title="t('member.institution.self.details.title')" width="900" v-model:show="show" :loading="loading" :refresh="refresh">
         <app-table-details :title="t('member.institution.self.details.subtitle')" :data="data?.organ" :label-width="160" :cell-props="detailProps1" :column="2" />
-        <!-- <app-table-details title="商品查询权限" :data="goodslimit" :label-width="160" :cell-props="detailProps2" :column="1">
-            
-        </app-table-details> -->
         <span>
             <span>{{ t('member.institution.self.details.market') }}</span>
             <span v-for="item in goodslimit" v-bind:key="item.id">
                 <span>{{ item.title }}: </span>
-                <span>{{ item.value }}</span>
             </span> 
         </span>
         <template #footer>
@@ -64,22 +60,11 @@ const goodslimit = computed(() => {
     return data.value?.markets.map(e => {
         return {
             id: e.marketid,
-            title: e.marketname,
-            value: data.value?.operategoodsinfo?.filter(g => g.marketid === e.marketid).map(e => e.goodsname).join(','),
+            title: e.marketname
         }
     }) ?? []
 })
 
-// const detailProps2 = computed(() => {
-//     return data.value?.markets.map<CellProp>(e =>({ 
-//         prop: e.marketid.toString(), 
-//         label: e.marketname,
-//         formatValue: (val) => {
-//             return data.value?.operategoodsinfo.filter(e => e.marketid === val).map(e => e.goodsname).join(',')
-//         },
-//      }) ) ?? []
-// }) 
-
 const onCancel = (isRefresh = false) => {
     show.value = false
     refresh.value = isRefresh

+ 1 - 1
src/packages/pc/views/member/institution/tradecfg/components/add/index.vue

@@ -5,7 +5,7 @@
         <el-form ref="formRef" label-width="140px" :model="formData" :rules="formRules" :show-message="false">
             <fieldset class="g-fieldset el-form--horizontal">
                 <legend class="g-fieldset__legend">{{ t('investor.custom.tradecfg.edit.subtitle1') }}</legend>
-                <el-form-item :label="t('member.institution.tradecfg.add.subtitle1')" @change="onTradeTypeChange">
+                <el-form-item :label="t('member.institution.tradecfg.add.subtitle')" @change="onTradeTypeChange">
                     <el-radio-group v-model="formData.tradetype">
                         <el-radio :label="t('member.institution.tradecfg.add.userid1')" :value="1" />
                         <el-radio :label="t('member.institution.tradecfg.add.userid2')" :value="2" />