فهرست منبع

Merge branch 'master' of http://47.101.159.18:3000/Muchinfo/MTP20_WEB_GLOBAL

li.shaoyi 2 سال پیش
والد
کامیت
3634a4d394

+ 21 - 0
src/business/bank/index.ts

@@ -268,3 +268,24 @@ export function useAccountFundInfo() {
         fund
     }
 }
+
+/// 账户资金信息请求
+export function useBankAccouuntSign() {
+    /// 数据
+    const fund = shallowRef<Partial<Proto.AccountFundInfoRsp>>({})
+
+    /// 账户资金信息
+    accountFundInfoReq({
+        data: {
+            QueryBitMask: 2,
+            OrderId: new Date().getTime(),
+            AccountId: accountStore.currentAccountId,
+        }
+    }).then((res) => {
+        fund.value = res
+    })
+
+    return {
+        fund
+    }
+}

+ 1 - 1
src/packages/gstj/views/order/position/components/spot/listing/Index.vue

@@ -14,7 +14,7 @@
                     <Cell title="可用量" :value="selectedRow.enableqty" />
                 </CellGroup>
                 <CellGroup title="挂牌信息" inset>
-                    <Performance ref="performanceRef" name="PerformanceTemplateID"
+                    <Performance ref="performanceRef" :tmptype="'0,2'" name="PerformanceTemplateID"
                         v-model="formData.PerformanceTemplateID" />
                     <Field name="OrderQty" :rules="formRules.OrderQty" label="挂牌数量">
                         <template #input>

+ 1 - 1
src/packages/gstj/views/spot/add/components/buy/index.vue

@@ -2,7 +2,7 @@
     <app-view class="g-form">
         <Form ref="formRef" class="g-form__container" @submit="formSubmit">
             <CellGroup inset>
-                <Performance ref="performanceRef" name="PerformanceTemplateID" v-model="formData.PerformanceTemplateID" />
+                <Performance ref="performanceRef" :tmptype="'0,2'" name="PerformanceTemplateID" v-model="formData.PerformanceTemplateID" />
                 <Field name="WRFactorTypeId" label="现货仓单" placeholder="请选择" v-model="selectedRow.wrfactortypeid"
                     :rules="formRules.WRFactorTypeId" @click="showWarehouseReceipt = true" is-link readonly />
                 <template v-if="selectedRow.wrfactortypeid">

+ 1 - 1
src/packages/gstj/views/spot/detail/components/listing/index.vue

@@ -2,7 +2,7 @@
     <app-popup class="supply-demand-listing" :title="buyorsell === BuyOrSell.Sell ? '我要卖' : '我要买'" v-model:show="showModal"
         :refresh="refresh">
         <Form class="supply-demand-listing__form" ref="formRef" @submit="onSubmit">
-            <Performance ref="performanceRef" name="PerformanceTemplateID" v-model="formData.PerformanceTemplateID" />
+            <Performance ref="performanceRef" :tmptype="'0,2'" name="PerformanceTemplateID" v-model="formData.PerformanceTemplateID" />
             <Field name="FixedPrice" :rules="formRules.FixedPrice" label="挂牌价格">
                 <template #input>
                     <Stepper v-model="formData.FixedPrice" theme="round" :decimal-length="2" :auto-fixed="false"

+ 2 - 1
src/packages/mobile/components/modules/performance/index.vue

@@ -2,7 +2,7 @@
     <Field type="number" :label="label" @click="show = true" is-link readonly>
         <template #input>
             <input :placeholder="placeholder" :value="templateName" />
-            <PerformanceList v-model:show="show" :market-id="marketId" :selected-id="modelValue" @change="onChange" />
+            <PerformanceList v-model:show="show" :tmptype="tmptype" :market-id="marketId" :selected-id="modelValue" @change="onChange" />
         </template>
     </Field>
 </template>
@@ -15,6 +15,7 @@ import PerformanceList from './list/index.vue'
 defineProps({
     modelValue: Number,
     marketId: Number,
+    tmptype: String,
     label: {
         type: String,
         default: '履约模板'

+ 3 - 1
src/packages/mobile/components/modules/performance/list/index.vue

@@ -38,6 +38,7 @@ const props = defineProps({
         type: Boolean,
         default: false
     },
+    tmptype: String,
     selectedId: Number,
     marketId: Number,
 })
@@ -52,7 +53,8 @@ const showModal = computed({
 
 const { dataList } = useRequest(queryPermancePlanTmp, {
     params: {
-        marketid: props.marketId
+        marketid: props.marketId,
+        tmptype: props.tmptype
     },
     onFinally: () => {
         const item = dataList.value.find((e) => e.autoid === props.selectedId)

+ 15 - 1
src/packages/mobile/views/bank/sign/Index.vue

@@ -38,17 +38,31 @@ import { useDoCancelBankSign } from '@/business/bank'
 import { useNavigation } from '../../../router/navigation'
 import { useErrorInfoStore } from '@/stores'
 import { shallowRef } from 'vue'
+import { useRequest } from '@/hooks/request'
+import { queryBankAccountSign } from '@/services/api/bank'
 
 const componentMap = new Map<string, unknown>([
     ['edit', defineAsyncComponent(() => import('./components/edit/Index.vue'))],
 ])
 
-const { componentRef, componentId, openComponent, closeComponent } = useComponent()
+const { componentRef, componentId, openComponent, closeComponent } = useComponent(() => {
+    run()
+})
+
 const { cancelSubmit, bankInfo, formRefresh } = useDoCancelBankSign()
 const { router } = useNavigation()
 /// 是否为编辑
 const isedit = shallowRef(false)
 
+/// 查询
+const { run } = useRequest(queryBankAccountSign, {
+    onSuccess: (res) => {
+        if (res.data.length != 0) {
+            bankInfo.value = res.data[0]
+        }
+    }
+})
+
 const formSubmit = () => {
     dialog({
         message: '确认解约?',

+ 1 - 1
src/packages/mobile/views/order/position/components/spot/listing/Index.vue

@@ -14,7 +14,7 @@
                     <Cell title="可用量" :value="selectedRow.enableqty" />
                 </CellGroup>
                 <CellGroup title="挂牌信息" inset>
-                    <Performance ref="performanceRef" name="PerformanceTemplateID"
+                    <Performance ref="performanceRef" :tmptype="'0,2'" name="PerformanceTemplateID"
                         v-model="formData.PerformanceTemplateID" />
                     <Field name="OrderQty" :rules="formRules.OrderQty" label="挂牌数量">
                         <template #input>

+ 1 - 1
src/packages/mobile/views/spot/add/components/buy/index.vue

@@ -2,7 +2,7 @@
     <app-view class="g-form">
         <Form ref="formRef" class="g-form__container" @submit="formSubmit">
             <CellGroup inset>
-                <Performance ref="performanceRef" name="PerformanceTemplateID" v-model="formData.PerformanceTemplateID" />
+                <Performance ref="performanceRef" :tmptype="'0,2'" name="PerformanceTemplateID" v-model="formData.PerformanceTemplateID" />
                 <Field name="WRFactorTypeId" label="现货仓单" placeholder="请选择" v-model="selectedRow.wrfactortypeid"
                     :rules="formRules.WRFactorTypeId" @click="showWarehouseReceipt = true" is-link readonly />
                 <template v-if="selectedRow.wrfactortypeid">

+ 1 - 1
src/packages/mobile/views/spot/add/components/sell/index.vue

@@ -2,7 +2,7 @@
     <app-view class="g-form">
         <Form ref="formRef" class="g-form__container" @submit="formSubmit">
             <CellGroup inset>
-                <Performance ref="performanceRef" name="PerformanceTemplateID" v-model="formData.PerformanceTemplateID" />
+                <Performance ref="performanceRef" :tmptype="'0,2'" name="PerformanceTemplateID" v-model="formData.PerformanceTemplateID" />
                 <Field name="DeliveryGoodsID" label="品类" :rules="formRules.DeliveryGoodsID" is-link>
                     <template #input>
                         <app-select v-model="formData.DeliveryGoodsID" :options="ftDeliveryGoodsList"

+ 1 - 1
src/packages/mobile/views/spot/detail/components/listing/index.vue

@@ -2,7 +2,7 @@
     <app-popup class="supply-demand-listing" :title="buyorsell === BuyOrSell.Sell ? '我要卖' : '我要买'" v-model:show="showModal"
         :refresh="refresh">
         <Form class="supply-demand-listing__form" ref="formRef" @submit="onSubmit">
-            <Performance ref="performanceRef" name="PerformanceTemplateID" v-model="formData.PerformanceTemplateID" />
+            <Performance ref="performanceRef" :tmptype="'0,2'" name="PerformanceTemplateID" v-model="formData.PerformanceTemplateID" />
             <Field name="FixedPrice" :rules="formRules.FixedPrice" label="挂牌价格">
                 <template #input>
                     <Stepper v-model="formData.FixedPrice" theme="round" :decimal-length="2" :auto-fixed="false"

+ 3 - 1
src/packages/pc/components/modules/performance/index.vue

@@ -16,6 +16,7 @@ import AppPerformanceRule from '../performance-rule/index.vue'
 
 const props = defineProps({
     modelValue: Number,
+    tmptype: String,
     marketId: Number,
     placeholder: {
         type: String,
@@ -27,7 +28,8 @@ const emit = defineEmits(['update:modelValue'])
 
 const { data, dataList } = useRequest(queryPermancePlanTmp, {
     params: {
-        marketid: props.marketId
+        marketid: props.marketId,
+        tmptype: props.tmptype
     },
     onSuccess: (res) => {
         data.value = res.data.find((e) => e.autoid === props.modelValue)

+ 13 - 4
src/packages/pc/views/account/sign/index.vue

@@ -3,9 +3,9 @@
     <app-table :data="dataList" v-model:columns="tableColumns" :loading="loading" :row-key="rowKey"
         :expand-row-keys="expandKeys" @row-click="rowClick">
         <template #header>
-            <el-button type="primary" v-if="authStatus === AuthStatus.Certified"
+            <el-button type="primary" v-if="authStatus === AuthStatus.Certified && ![SignStatus.Audit, SignStatus.Signed].includes(signStatus)"
                 @click="openComponent('sign')">添加签约账户</el-button>
-            <el-button type="warning" v-else @click="openComponent('certification')">实名认证</el-button>
+            <el-button type="warning" v-if="authStatus === AuthStatus.Uncertified" @click="openComponent('certification')">实名认证</el-button>
         </template>
         <!-- 证件类型 -->
         <template #cardtype="{ value }">
@@ -47,9 +47,18 @@ const componentMap = new Map<string, unknown>([
     ['certification', defineAsyncComponent(() => import('./components/certification/index.vue'))], // 实名认证
 ])
 
+const authStatus = shallowRef(AuthStatus.Certified) // 实名认证状态
+const signStatus = shallowRef(SignStatus.Unsigned)
+
 const { rowKey, expandKeys, rowClick, selectedRow } = useComposeTable<Model.BankAccountSignRsp>({ rowKey: 'applyexchticket' })
-const { loading, dataList, run } = useRequest(queryBankAccountSign, {})
-const authStatus = shallowRef(AuthStatus.Uncertified) // 实名认证状态
+const { loading, dataList, run } = useRequest(queryBankAccountSign, {
+    onSuccess: (res) => {
+        /// 签约状态
+        if (res.data.length != 0) {
+            signStatus.value = res.data[0].signstatus
+        }
+    }
+})
 
 const { componentRef, componentId, openComponent, closeComponent } = useComponent(() => {
     run()

+ 1 - 1
src/packages/pc/views/footer/spot/position/components/listing/index.vue

@@ -7,7 +7,7 @@
                 <span>{{ selectedRow.wrstandardcode }}/{{ selectedRow.wrstandardname }}</span>
             </el-form-item>
             <el-form-item prop="PerformanceTemplateID" label="履约方式">
-                <Performance :market-id="17201" v-model="formData.PerformanceTemplateID" />
+                <Performance :market-id="17201" :tmptype="'0,2'" v-model="formData.PerformanceTemplateID" />
             </el-form-item>
             <el-form-item label="仓库">
                 <span>{{ selectedRow.warehousename }}</span>

+ 1 - 1
src/packages/pc/views/market/trade/spot/listing/index.vue

@@ -3,7 +3,7 @@
     <app-drawer title="挂牌" v-model:show="show" :width="800" :loading="loading" :refresh="refresh">
         <el-form ref="formRef" class="el-form--horizontal" label-width="100px" :model="formData" :rules="formRules">
             <el-form-item prop="PerformanceTemplateID" label="履约方式">
-                <Performance :market-id="17201" v-model="formData.PerformanceTemplateID" />
+                <Performance :market-id="17201" :tmptype="'0,2'" v-model="formData.PerformanceTemplateID" />
             </el-form-item>
             <el-form-item prop="DeliveryGoodsID" label="品种">
                 <el-select placeholder="请选择" v-model="formData.DeliveryGoodsID" @change="onDeliveryGoodsChange">

+ 1 - 1
src/packages/pc/views/market/trade/spot/order/listing/index.vue

@@ -3,7 +3,7 @@
     <app-drawer title="挂牌" v-model:show="show" :loading="loading" :refresh="refresh">
         <el-form ref="formRef" class="el-form--vertical" label-width="100px" :model="formData" :rules="formRules">
             <el-form-item prop="PerformanceTemplateID" label="履约方式">
-                <Performance :market-id="17201" v-model="formData.PerformanceTemplateID" />
+                <Performance :market-id="17201" :tmptype="'0,2'" v-model="formData.PerformanceTemplateID" />
             </el-form-item>
             <el-form-item prop="FixedPrice" label="挂牌价格">
                 <el-input-number placeholder="请输入" :min="0" :precision="2" v-model="formData.FixedPrice" />