Browse Source

Merge branch 'master' of http://47.101.159.18:3000/Muchinfo/MTP2.0_WEB

marymelisa 4 năm trước cách đây
mục cha
commit
2630f2e0d4
34 tập tin đã thay đổi với 1423 bổ sung1174 xóa
  1. 2 0
      src/common/constants/buttonType.ts
  2. 2 0
      src/common/setup/table/clolumn.ts
  3. 2 4
      src/services/go/ermcp/account/index.ts
  4. 40 38
      src/services/go/ermcp/account/interface.ts
  5. 1 0
      src/views/business/purchase/components/detail/index.vue
  6. 1 2
      src/views/business/purchase/components/settlement/index.vue
  7. 316 220
      src/views/business/sell/components/settlement/index.vue
  8. 2 2
      src/views/information/account_info/compoments/add-business/index.vue
  9. 29 28
      src/views/information/account_info/compoments/add-child-futures/index.vue
  10. 1 1
      src/views/information/account_info/compoments/add-child-futures/setup.ts
  11. 202 204
      src/views/information/account_info/compoments/add-managers-permission/index.vue
  12. 1 1
      src/views/information/account_info/compoments/add-traders/index.vue
  13. 98 111
      src/views/information/account_info/compoments/cancel-futures/index.vue
  14. 150 109
      src/views/information/account_info/compoments/credit-futures/index.vue
  15. 30 62
      src/views/information/account_info/compoments/detail-futures/index.vue
  16. 16 11
      src/views/information/account_info/compoments/managers-permission-delete/index.vue
  17. 11 11
      src/views/information/account_info/compoments/managers-permission-detail/index.vue
  18. 7 6
      src/views/information/account_info/compoments/managers-permission-modify/index.vue
  19. 2 0
      src/views/information/account_info/compoments/managers-permission/index.vue
  20. 120 65
      src/views/information/account_info/compoments/modify-futures-son/index.vue
  21. 36 9
      src/views/information/account_info/list/account_info_futures/index.vue
  22. 27 0
      src/views/information/account_info/list/account_info_futures/setup.ts
  23. 2 2
      src/views/information/custom/compoments/modify/index.vue
  24. 13 10
      src/views/information/spot-contract/components/detail/index.vue
  25. 3 1
      src/views/manage/business-review/components/settlementDetail/index.vue
  26. 136 119
      src/views/manage/business-review/list/settlement/index.vue
  27. 1 1
      src/views/manage/finance-review/components/fundsDetail/index.vue
  28. 1 1
      src/views/manage/finance-review/components/invoiceCancel/index.vue
  29. 1 1
      src/views/manage/finance-review/components/invoiceDetail/index.vue
  30. 153 139
      src/views/manage/finance-review/list/funds/index.vue
  31. 1 1
      src/views/manage/inventory-review/components/checkoutCancel/index.vue
  32. 1 1
      src/views/search/inventory/components/add/index.vue
  33. 8 7
      src/views/search/inventory/list/inventory_applyrecord/index.vue
  34. 7 7
      src/views/search/inventory/list/inventory_current/index.vue

+ 2 - 0
src/common/constants/buttonType.ts

@@ -102,4 +102,6 @@ export interface ButtonType {
     inventory_review_checkin_cancel: string; // 入库 撤销
     inventory_review_checkout_audit: string; // 出库 审核
     inventory_review_checkout_cancel: string; // 出库 撤销
+
+    inventory_current_add: string; // 库存查询 新增
 }

+ 2 - 0
src/common/setup/table/clolumn.ts

@@ -45,6 +45,8 @@ export function getTableColumns() {
             }
             if (columnwidth) {
                 item.width = +columnwidth
+            } else {
+                item.width = 120 // 默认120
             }
             // 以下添加过滤数据对应的方法
             filterKeyList.forEach(el => {

+ 2 - 4
src/services/go/ermcp/account/index.ts

@@ -60,9 +60,7 @@ export function QueryFuturesCompany(): Promise<ErmcpFuturesCompany[]> {
  * @param roleid  角色id(可多个,逗号隔开)
  * @constructor
  */
-export function QueryAccMgrRoleMenu(roleid?: string): Promise<ErmcpRoleMenuEx[]> {
-    const userid = getUserId()
-    const param = roleid ? { roleid, userid } : { userid }
+export function QueryAccMgrRoleMenu(param: { userid: number, roleid?: string }): Promise<ErmcpRoleMenuEx[]> {
     return commonSearch_go('/Ermcp/QueryAccMgrRoleMenu', param).catch((err) => {
         throw new Error(`查询账户管理角色详情: ${err.message}`);
     });
@@ -84,7 +82,7 @@ export function QueryAccMgrRole(): Promise<ErmcpRole> {
  * @param req
  * @constructor
  */
-export function QueryAccMgrTaAccountInfo(req: QueryAccMgrTaAccountInfoReq): Promise<ErmcpTaAccountInfo> {
+export function QueryAccMgrTaAccountInfo(req: QueryAccMgrTaAccountInfoReq): Promise<ErmcpTaAccountInfo[]> {
     return commonSearch_go('/Ermcp/QueryAccMgrTaAccountInfo', req).catch((err) => {
         throw new Error(`查询账户管理授信: ${err.message}`);
     });

+ 40 - 38
src/services/go/ermcp/account/interface.ts

@@ -173,44 +173,46 @@ export interface QueryAccMgrTaAccountInfoReq {
  * 查询账户管理授信(账户管理/账户设置/授信) 返回
  */
 export interface ErmcpTaAccountInfo {
-    accountname	:string;//机构名称
-    areauserid	:number;//所属机构\交易用户ID
-    begindate	:string;//开始交易日
-    biztype	:number;//业务类型 - 1:套保 2:套利
-    brandname	:string;//品牌名称
-    buypreinvoicedamount	:number;//采购预收票额(预收票额)
-    buyprepaidamount	:number;//采购预付款额(预付货款额)
-    buytodayinvoiceamount	:number;//采购今收票额(今收票额)
-    buytodayrefundamount	:number;//采购今收退款额(今收退款额)
-    buytodaysettleamount	:number;//采购今付款额(今付货款额)
-    buyuninvoicedamount	:number;//采购应收票额(应收票额)
-    buyunpaidamount	:number;//采购应付款额(应付货款额)
-    currencyid	:number;//结算币种ID
-    currencyname	:string;//币种名称
-    cycletime	:string;//周期时间 月(YYYYMM) 季(YYYYQ) 年(YYYY) 周(YYYYIW) 全(number;
-//)【原值】
-    cycletype	:number;//周期类型 - 1:月 2:季 3:年 4:周 5:全报表【原值】
-    deliverygoodscode	:string;//现货品种代码
-    deliverygoodsid	:number;//现货品种ID
-    deliverygoodsname	:string;//现货品种名称
-    enddate	:string;//结束交易日
-    reckondate	:string;//日照时期(yyyyMMdd)
-    sellpreinvoicedamount	:number;//销售预开票额(预开票额)
-    sellprepaidamount	:number;//销售预收款额(预收货款额)
-    selltodayinvoiceamount	:number;//销售今开票额(今开票额)
-    selltodayrefundamount	:number;//销售今付退款额(今付退款额)
-    selltodaysettleamount	:number;//销售今收款额(今收货款额)
-    selluninvoicedamount	:number;//销售应开票额(应开票额)
-    sellunpaidamount	:number;//销售应收款额(应收货款额)
-    spotgoodsbrandid	:number;//现货品牌ID
-    todaypaysum	:number;//今付款合计
-    todayreceivesum	:number;//今收款合计
-    updatetime	:string;//更新时间
-    wrfactortypeid	:number;//仓单要素类型ID(212+Unix秒时间戳(1number;
-//位)+xxxxxx)
-    wrstandardcode	:string;//品类代码
-    wrstandardid	:number;//现货商品ID
-    wrstandardname	:string;//品类名称
+    accountname: string;//机构名称
+    areauserid: number;//所属机构\交易用户ID
+    begindate: string;//开始交易日
+    biztype: number;//业务类型 - 1:套保 2:套利
+    brandname: string;//品牌名称
+    buypreinvoicedamount: number;//采购预收票额(预收票额)
+    buyprepaidamount: number;//采购预付款额(预付货款额)
+    buytodayinvoiceamount: number;//采购今收票额(今收票额)
+    buytodayrefundamount: number;//采购今收退款额(今收退款额)
+    buytodaysettleamount: number;//采购今付款额(今付货款额)
+    buyuninvoicedamount: number;//采购应收票额(应收票额)
+    buyunpaidamount: number;//采购应付款额(应付货款额)
+    currencyid: number;//结算币种ID
+    currentbalance: number;//当前余额
+    mortgagecredit: number;//授信总额
+    currencyname: string;//币种名称
+    cycletime: string;//周期时间 月(YYYYMM) 季(YYYYQ) 年(YYYY) 周(YYYYIW) 全(number;
+    //)【原值】
+    cycletype: number;//周期类型 - 1:月 2:季 3:年 4:周 5:全报表【原值】
+    deliverygoodscode: string;//现货品种代码
+    deliverygoodsid: number;//现货品种ID
+    deliverygoodsname: string;//现货品种名称
+    enddate: string;//结束交易日
+    reckondate: string;//日照时期(yyyyMMdd)
+    sellpreinvoicedamount: number;//销售预开票额(预开票额)
+    sellprepaidamount: number;//销售预收款额(预收货款额)
+    selltodayinvoiceamount: number;//销售今开票额(今开票额)
+    selltodayrefundamount: number;//销售今付退款额(今付退款额)
+    selltodaysettleamount: number;//销售今收款额(今收货款额)
+    selluninvoicedamount: number;//销售应开票额(应开票额)
+    sellunpaidamount: number;//销售应收款额(应收货款额)
+    spotgoodsbrandid: number;//现货品牌ID
+    todaypaysum: number;//今付款合计
+    todayreceivesum: number;//今收款合计
+    updatetime: string;//更新时间
+    wrfactortypeid: number;//仓单要素类型ID(212+Unix秒时间戳(1number;
+    //位)+xxxxxx)
+    wrstandardcode: string;//品类代码
+    wrstandardid: number;//现货商品ID
+    wrstandardname: string;//品类名称
 }
 
 

+ 1 - 0
src/views/business/purchase/components/detail/index.vue

@@ -114,6 +114,7 @@ export default defineComponent({
         const loading = ref<boolean>(false);
 
         function submit() {
+
             cancel();
         }
 

+ 1 - 2
src/views/business/purchase/components/settlement/index.vue

@@ -343,8 +343,7 @@ export default defineComponent({
                 }
                 // 调整金额 
                 if(ReckonAdjustAmount) {
-                  const temp = checkedObj.value.adjustAmount === 1 ? 1  : -1
-                  param.ReckonAdjustAmount = ReckonAdjustAmount * temp
+                  param.ReckonAdjustAmount = ReckonAdjustAmount
                 }
                 if(Remark) {
                   param.Remark = Remark

+ 316 - 220
src/views/business/sell/components/settlement/index.vue

@@ -1,226 +1,298 @@
 <template>
   <!-- 交收登记-->
-  <a-modal  class="commonModal paddingDialog settlement"
+  <a-modal class="commonModal paddingDialog settlement"
            title="交收登记"
            v-model:visible="visible"
            @cancel="cancel"
            centered
            width="890px">
     <template #footer>
-        <a-button key="submit"
-                  class="cancelBtn"
-                  @click="cancel">取消
-        </a-button>
-        <a-button key="submit"
-                  type="primary"
-                  :loading="loading"
-                  @click="submit">交收登记
-        </a-button>
+      <a-button key="submit"
+                class="cancelBtn"
+                @click="cancel">取消
+      </a-button>
+      <a-button key="submit"
+                type="primary"
+                :loading="loading"
+                @click="submit">交收登记
+      </a-button>
     </template>
-      <fieldset class="formFieldSet">
-          <legend>合同基本信息</legend>
-          <a-form class="inlineForm">
-              <a-row :gutter="24">
-                  <a-col :span="12">
-                      <a-form-item label="合同编号">
-                          <span class="white">{{ formatValue(selectedRow.contractno) }}</span>
-                      </a-form-item>
-                  </a-col>
-                  <a-col :span="12">
-                      <a-form-item label="定价类型">
-                          <span class="white">{{ getPriceTypeName(selectedRow.pricetype) }}</span>
-                      </a-form-item>
-                  </a-col>
-              </a-row>
-              <a-row :gutter="24">
-                  <a-col :span="12">
-                      <a-form-item :label="selectedRow.contracttype===1? '采购方': '销售方'">
-                          <span class="white">{{ formatValue(selectedRow.accountname) }}</span>
-                      </a-form-item>
-                  </a-col>
-                  <a-col :span="12">
-                      <a-form-item label="现货品种">
-                          <span class="white">{{ formatValue(selectedRow.deliverygoodsname) }}</span>
-                      </a-form-item>
-                  </a-col>
-              </a-row>
-              <a-row :gutter="24">
-                  <a-col :span="12">
-                      <a-form-item label="合同签署量">
-                          <span class="white">{{ formatValue(selectedRow.qty + selectedRow.enumdicname) }}</span>
-                      </a-form-item>
-                  </a-col>
-                  <a-col :span="12">
-                      <a-form-item label="合同暂定价">
-                          <span class="white">{{ formatValue(selectedRow.price) }}</span>
-                      </a-form-item>
-                  </a-col>
-              </a-row>
-          </a-form>
-      </fieldset>
-      <fieldset class="formFieldSet">
-          <legend>已登记信息</legend>
-          <a-form class="inlineForm">
-              <a-row :gutter="24">
-                  <a-col :span="12">
-                      <a-form-item label="已定价量">
-                          <span class="white">{{ selectedRow.pricedqty + selectedRow.enumdicname }}</span>
-                      </a-form-item>
-                  </a-col>
-                  <a-col :span="12">
-                      <a-form-item label="已交收量">
-                          <span class="white">{{ selectedRow.reckonrealqty + selectedRow.enumdicname }}</span>
-                      </a-form-item>
-                  </a-col>
-                  <a-col :span="12">
-                      <a-form-item label="调整金额">
-                          <span class="white">{{ selectedRow.reckonadjustamount + selectedRow.currencyname }}</span>
-                      </a-form-item>
-                  </a-col>
-                  <a-col :span="12">
-                      <a-form-item label="保证金">
-                          <span class="white">{{ selectedRow.margin + selectedRow.currencyname }}</span>
-                      </a-form-item>
-                  </a-col>
-                  <a-col :span="24">
-                      <a-form-item label="其他费用">
-                          <span class="white">{{ selectedRow.reckonotheramount + selectedRow.currencyname }}</span>
-                      </a-form-item>
-                  </a-col>
-              </a-row>
-          </a-form>
-      </fieldset>
-      <fieldset class="formFieldSet">
-          <legend>本次交收信息</legend>
-          <a-form class="inlineForm"
-                  ref="formRef"
-                  :model="formState"
-                  :rules="rules">
-              <a-checkbox-group class="commonCheckboxGroup">
-                  <a-row>
+    <fieldset class="formFieldSet">
+      <legend>合同基本信息</legend>
+      <a-form class="inlineForm">
+        <a-row :gutter="24">
+          <a-col :span="12">
+            <a-form-item label="合同编号">
+              <span class="white">{{ formatValue(selectedRow.contractno) }}</span>
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="定价类型">
+              <span class="white">{{ getPriceTypeName(selectedRow.pricetype) }}</span>
+            </a-form-item>
+          </a-col>
+        </a-row>
+        <a-row :gutter="24">
+          <a-col :span="12">
+            <a-form-item :label="selectedRow.contracttype===1? '采购方': '销售方'">
+              <span class="white">{{ formatValue(selectedRow.accountname) }}</span>
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="现货品种">
+              <span class="white">{{ formatValue(selectedRow.deliverygoodsname) }}</span>
+            </a-form-item>
+          </a-col>
+        </a-row>
+        <a-row :gutter="24">
+          <a-col :span="12">
+            <a-form-item label="合同签署量">
+              <span class="white">{{ formatValue(selectedRow.qty + selectedRow.enumdicname) }}</span>
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="合同暂定价">
+              <span class="white">{{ formatValue(selectedRow.price) }}</span>
+            </a-form-item>
+          </a-col>
+        </a-row>
+      </a-form>
+    </fieldset>
+    <fieldset class="formFieldSet">
+      <legend>已登记信息</legend>
+      <a-form class="inlineForm">
+        <a-row :gutter="24">
+          <a-col :span="12">
+            <a-form-item label="已定价量">
+              <span class="white">{{ selectedRow.pricedqty + selectedRow.enumdicname }}</span>
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="已交收量">
+              <span class="white">{{ selectedRow.reckonrealqty + selectedRow.enumdicname }}</span>
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="调整金额">
+              <span class="white">{{ selectedRow.reckonadjustamount + selectedRow.currencyname }}</span>
+            </a-form-item>
+          </a-col>
+          <a-col :span="12">
+            <a-form-item label="保证金">
+              <span class="white">{{ selectedRow.margin + selectedRow.currencyname }}</span>
+            </a-form-item>
+          </a-col>
+          <a-col :span="24">
+            <a-form-item label="其他费用">
+              <span class="white">{{ selectedRow.reckonotheramount + selectedRow.currencyname }}</span>
+            </a-form-item>
+          </a-col>
+        </a-row>
+      </a-form>
+    </fieldset>
+    <fieldset class="formFieldSet">
+      <legend>本次交收信息</legend>
+      <a-form class="inlineForm"
+              ref="formRef"
+              :model="formState"
+              :rules="rules">
+        <a-checkbox-group class="commonCheckboxGroup">
+          <a-row>
+            <a-col :span="12">
+              <a-form-item class="relative">
+                <template #label>
+                  <a-checkbox value="交收量"
+                              v-model:checked="checkedObj.qty"
+                              @change="()=>checkedObj.qty = !checkedObj.qty">交收量</a-checkbox>
+                </template>
+                <a-form-item class="relative"
+                             v-if="checkedObj.qty"
+                             name="ReckonRealQty">
+                  <a-input-number v-model:value="formState.ReckonRealQty"
+                                  class="dialogInput"
+                                  style="width: 200px"
+                                  placeholder="请输入交收量"
+                                  suffix="单位" />
+                  <div class="tip mt10"><span>待交收量:{{selectedRow.unsureqty}}吨</span><a class="blue fr"
+                       @click="formState.ReckonRealQty=selectedRow.unsureqty">全部登记</a></div>
+                </a-form-item>
+                <a-form-item class="relative"
+                             v-else>
+                  <a-input-number disabled
+                                  class="dialogInput"
+                                  style="width: 200px"
+                                  placeholder="请输入交收量"
+                                  suffix="单位" />
+                  <div class="tip mt10"><span class="fl">未定价量:--吨</span><a class="blue fr">全部登记</a></div>
+                </a-form-item>
+              </a-form-item>
+            </a-col>
+            <a-col :span="12">
+              <a-form-item class="relative">
+                <template #label>
+                  <a-checkbox value="其他费用"
+                              v-model:checked="checkedObj.amount"
+                              @change="()=>checkedObj.amount = !checkedObj.amount">其他费用</a-checkbox>
+                </template>
+                <a-form-item v-if="checkedObj.amount"
+                             name="ReckonOtherAmount">
+                  <a-input-number v-model:value="formState.ReckonOtherAmount"
+                                  class="dialogInput"
+                                  style="width: 200px"
+                                  placeholder="请输入其他费用"
+                                  suffix="元" />
+                </a-form-item>
+                <a-form-item v-else>
+                  <a-input-number readonly
+                                  class="dialogInput"
+                                  style="width: 200px"
+                                  placeholder="请输入其他费用"
+                                  suffix="元" />
+                </a-form-item>
+              </a-form-item>
+            </a-col>
+            <a-col :span="12"
+                   class="mt10">
+              <a-form-item class="relative">
+                <template #label>
+                  <a-checkbox value="调整保证金"
+                              v-model:checked="checkedObj.margin"
+                              @change="()=>checkedObj.margin = !checkedObj.margin">调整保证金</a-checkbox>
+                </template>
+                <a-form-item class="relative"
+                             v-if="checkedObj.margin">
+                  <a-radio-group class="commonRadioGroup"
+                                 v-model:value="checkedObj.adjustMargin">
+                    <a-row style="width: 200px">
                       <a-col :span="12">
-                          <a-form-item class="relative">
-                              <template #label>
-                                  <a-checkbox value="交收量" v-model:checked="checkedObj.qty" @change="()=>checkedObj.qty = !checkedObj.qty">交收量</a-checkbox>
-                              </template>
-                              <a-form-item class="relative" v-if="checkedObj.qty" name="ReckonRealQty">
-                                  <a-input-number  v-model:value="formState.ReckonRealQty" class="dialogInput" style="width: 200px" placeholder="请输入交收量" suffix="单位"/>
-                                  <div class="tip mt10"><span>待交收量:{{selectedRow.unsureqty}}吨</span><a class="blue fr" @click="formState.ReckonRealQty=selectedRow.unsureqty">全部登记</a></div>
-                              </a-form-item>
-                              <a-form-item class="relative" v-else>
-                                  <a-input-number disabled class="dialogInput" style="width: 200px" placeholder="请输入交收量" suffix="单位" />
-                                  <div class="tip mt10"><span class="fl">未定价量:--吨</span><a class="blue fr">全部登记</a></div>
-                              </a-form-item>
-                          </a-form-item>
+                        <a-radio :value="1">追加</a-radio>
                       </a-col>
                       <a-col :span="12">
-                          <a-form-item class="relative">
-                              <template #label>
-                                  <a-checkbox value="其他费用"  v-model:checked="checkedObj.amount" @change="()=>checkedObj.amount = !checkedObj.amount">其他费用</a-checkbox>
-                              </template>
-                              <a-form-item v-if="checkedObj.amount" name="ReckonOtherAmount">
-                                  <a-input-number v-model:value="formState.ReckonOtherAmount" class="dialogInput" style="width: 200px" placeholder="请输入其他费用" suffix="元"/>
-                              </a-form-item>
-                              <a-form-item v-else>
-                                  <a-input-number readonly class="dialogInput" style="width: 200px" placeholder="请输入其他费用" suffix="元"/>
-                              </a-form-item>
-                          </a-form-item>
+                        <a-radio :value="2">退还</a-radio>
                       </a-col>
-                      <a-col :span="12" class="mt10">
-                          <a-form-item class="relative">
-                              <template #label>
-                                  <a-checkbox value="调整保证金" v-model:checked="checkedObj.margin" @change="()=>checkedObj.margin = !checkedObj.margin">调整保证金</a-checkbox>
-                              </template>
-                              <a-form-item class="relative" v-if="checkedObj.margin">
-                                  <a-radio-group class="commonRadioGroup"  v-model:value="checkedObj.adjustMargin">
-                                      <a-row style="width: 200px">
-                                          <a-col :span="12">
-                                              <a-radio :value="1">追加</a-radio>
-                                          </a-col>
-                                          <a-col :span="12">
-                                              <a-radio :value="2">退还</a-radio>
-                                          </a-col>
-                                      </a-row>
-                                  </a-radio-group>
-                                  <div class="tip mt10">
-                                      <a-form-item  name="AddMargin"  v-if="checkedObj.adjustMargin === 1">
-                                          <a-input-number v-model:value="formState.AddMargin" class="dialogInput" style="width: 200px;" placeholder="请输入调整保证金" suffix="元"/>
-                                      </a-form-item >
-                                      <a-form-item  name="DecMargin" v-else>
-                                          <a-input-number  v-model:value="formState.DecMargin" class="dialogInput" style="width: 200px;" placeholder="请输入调整保证金" suffix="元" />
-                                      </a-form-item >
-                                  </div>
-                              </a-form-item >
-                              <a-form-item class="relative" v-else>
-                                  <a-radio-group class="commonRadioGroup" disabled>
-                                      <a-row style="width: 200px">
-                                          <a-col :span="12">
-                                              <a-radio :value="1">追加</a-radio>
-                                          </a-col>
-                                          <a-col :span="12">
-                                              <a-radio :value="2">退还</a-radio>
-                                          </a-col>
-                                      </a-row>
-                                  </a-radio-group>
-                                  <div class="tip mt10">
-                                      <a-input-number disabled class="dialogInput" style="width: 200px;" placeholder="请输入调整保证金" suffix="元"/>
-                                  </div>
-                              </a-form-item>
-                          </a-form-item >
+                    </a-row>
+                  </a-radio-group>
+                  <div class="tip mt10">
+                    <a-form-item name="AddMargin"
+                                 v-if="checkedObj.adjustMargin === 1">
+                      <a-input-number v-model:value="formState.AddMargin"
+                                      class="dialogInput"
+                                      style="width: 200px;"
+                                      placeholder="请输入调整保证金"
+                                      suffix="元" />
+                    </a-form-item>
+                    <a-form-item name="DecMargin"
+                                 v-else>
+                      <a-input-number v-model:value="formState.DecMargin"
+                                      class="dialogInput"
+                                      style="width: 200px;"
+                                      placeholder="请输入调整保证金"
+                                      suffix="元" />
+                    </a-form-item>
+                  </div>
+                </a-form-item>
+                <a-form-item class="relative"
+                             v-else>
+                  <a-radio-group class="commonRadioGroup"
+                                 disabled>
+                    <a-row style="width: 200px">
+                      <a-col :span="12">
+                        <a-radio :value="1">追加</a-radio>
                       </a-col>
-                      <a-col :span="12" class="mt10">
-                          <a-form-item class="relative">
-                              <template #label>
-                                  <a-checkbox value="调整金额" v-model:checked="checkedObj.justAmount" @change="()=>checkedObj.justAmount = !checkedObj.justAmount">调整金额</a-checkbox>
-                              </template>
-                              <a-form-item class="relative" v-if="checkedObj.justAmount">
-                                  <a-radio-group class="commonRadioGroup" v-model:value="checkedObj.adjustAmount">
-                                      <a-row style="width: 200px">
-                                          <a-col :span="12">
-                                              <a-radio :value="1" @focus="()=>{formState.ReckonAdjustAmount  ?formState.ReckonAdjustAmount= Math.abs(formState.ReckonAdjustAmount):0}">增加</a-radio>
-                                          </a-col>
-                                          <a-col :span="12">
-                                              <a-radio :value="2" @focus="()=>{formState.ReckonAdjustAmount  ?formState.ReckonAdjustAmount= -1* Math.abs(formState.ReckonAdjustAmount):0}">减少</a-radio>
-                                          </a-col>
-                                      </a-row>
-                                  </a-radio-group>
-                                  <div class="tip mt10">
-                                      <a-form-item  name="ReckonAdjustAmount">
-                                          <a-input-number v-model:value="formState.ReckonAdjustAmount" @change="formState.ReckonAdjustAmount= Math.abs(formState.ReckonAdjustAmount)" class="dialogInput" style="width: 200px;" placeholder="请输入调整金额" suffix="元" v-if="checkedObj.adjustAmount===1"/>
-                                          <a-input-number v-model:value="formState.ReckonAdjustAmount" @change="formState.ReckonAdjustAmount= -1*Math.abs(formState.ReckonAdjustAmount)" class="dialogInput" style="width: 200px;" placeholder="请输入调整金额" suffix="元" v-else/>
-                                      </a-form-item >
-                                  </div>
-                              </a-form-item>
-                              <a-form-item class="relative" v-else>
-                                  <a-radio-group class="commonRadioGroup" disabled>
-                                      <a-row style="width: 200px">
-                                          <a-col :span="12">
-                                              <a-radio :value="1">增加</a-radio>
-                                          </a-col>
-                                          <a-col :span="12">
-                                              <a-radio :value="2">减少</a-radio>
-                                          </a-col>
-                                      </a-row>
-                                  </a-radio-group>
-                                  <div class="tip mt10">
-                                      <a-input-number disabled class="dialogInput" style="width: 200px;" placeholder="请输入调整金额" suffix="元"/>
-                                  </div>
-                              </a-form-item>
-                          </a-form-item>
+                      <a-col :span="12">
+                        <a-radio :value="2">退还</a-radio>
                       </a-col>
-                      <a-col :span="24">
-                          <a-form-item label="备注"
-                                       class="relative mt20 pl40">
-                              <a-input class="dialogInput"
-                                       style="width: 600px"
-                                       placeholder="请输入备注信息" v-model:value="formState.Remark"/>
-                          </a-form-item>
+                    </a-row>
+                  </a-radio-group>
+                  <div class="tip mt10">
+                    <a-input-number disabled
+                                    class="dialogInput"
+                                    style="width: 200px;"
+                                    placeholder="请输入调整保证金"
+                                    suffix="元" />
+                  </div>
+                </a-form-item>
+              </a-form-item>
+            </a-col>
+            <a-col :span="12"
+                   class="mt10">
+              <a-form-item class="relative">
+                <template #label>
+                  <a-checkbox value="调整金额"
+                              v-model:checked="checkedObj.justAmount"
+                              @change="()=>checkedObj.justAmount = !checkedObj.justAmount">调整金额</a-checkbox>
+                </template>
+                <a-form-item class="relative"
+                             v-if="checkedObj.justAmount">
+                  <a-radio-group class="commonRadioGroup"
+                                 v-model:value="checkedObj.adjustAmount">
+                    <a-row style="width: 200px">
+                      <a-col :span="12">
+                        <a-radio :value="1"
+                                 @focus="()=>{formState.ReckonAdjustAmount  ?formState.ReckonAdjustAmount= Math.abs(formState.ReckonAdjustAmount):0}">增加</a-radio>
+                      </a-col>
+                      <a-col :span="12">
+                        <a-radio :value="2"
+                                 @focus="()=>{formState.ReckonAdjustAmount  ?formState.ReckonAdjustAmount= -1* Math.abs(formState.ReckonAdjustAmount):0}">减少</a-radio>
+                      </a-col>
+                    </a-row>
+                  </a-radio-group>
+                  <div class="tip mt10">
+                    <a-form-item name="ReckonAdjustAmount">
+                      <a-input-number v-model:value="formState.ReckonAdjustAmount"
+                                      @change="formState.ReckonAdjustAmount= Math.abs(formState.ReckonAdjustAmount)"
+                                      class="dialogInput"
+                                      style="width: 200px;"
+                                      placeholder="请输入调整金额"
+                                      suffix="元"
+                                      v-if="checkedObj.adjustAmount===1" />
+                      <a-input-number v-model:value="formState.ReckonAdjustAmount"
+                                      @change="formState.ReckonAdjustAmount= -1*Math.abs(formState.ReckonAdjustAmount)"
+                                      class="dialogInput"
+                                      style="width: 200px;"
+                                      placeholder="请输入调整金额"
+                                      suffix="元"
+                                      v-else />
+                    </a-form-item>
+                  </div>
+                </a-form-item>
+                <a-form-item class="relative"
+                             v-else>
+                  <a-radio-group class="commonRadioGroup"
+                                 disabled>
+                    <a-row style="width: 200px">
+                      <a-col :span="12">
+                        <a-radio :value="1">增加</a-radio>
+                      </a-col>
+                      <a-col :span="12">
+                        <a-radio :value="2">减少</a-radio>
                       </a-col>
-                  </a-row>
-              </a-checkbox-group>
-              <a-form-item name="IsChecked"></a-form-item>
-          </a-form>
-      </fieldset>
+                    </a-row>
+                  </a-radio-group>
+                  <div class="tip mt10">
+                    <a-input-number disabled
+                                    class="dialogInput"
+                                    style="width: 200px;"
+                                    placeholder="请输入调整金额"
+                                    suffix="元" />
+                  </div>
+                </a-form-item>
+              </a-form-item>
+            </a-col>
+            <a-col :span="24">
+              <a-form-item label="备注"
+                           class="relative mt20 pl40">
+                <a-input class="dialogInput"
+                         style="width: 600px"
+                         placeholder="请输入备注信息"
+                         v-model:value="formState.Remark" />
+              </a-form-item>
+            </a-col>
+          </a-row>
+        </a-checkbox-group>
+        <a-form-item name="IsChecked"></a-form-item>
+      </a-form>
+    </fieldset>
   </a-modal>
 </template>
 
@@ -251,20 +323,44 @@ export default defineComponent({
             const wrapEl = unref(formRef);
             wrapEl.validate().then((nameList:any) => {
                 delete nameList.IsChecked;
-                loading.value = true;
-                const params: SettlementReq = checkedObj.value.adjustMargin === 1?{
-                    ReckonRealQty: formState.ReckonRealQty!, // 交收量
-                    ReckonOtherAmount: formState.ReckonOtherAmount!, // 其它费用
-                    AddMargin: formState.AddMargin!, // 追加保证金
-                    ReckonAdjustAmount: checkedObj.value.adjustAmount === 1 ? formState.ReckonRealQty! : -1*formState.ReckonRealQty!, // 调整金额 +-代表增减
-                }:{
-                    ReckonRealQty: formState.ReckonRealQty!, // 交收量
-                    ReckonOtherAmount: formState.ReckonOtherAmount!, // 其它费用
-                    DecMargin: formState.DecMargin!, // 减少保证金
-                    ReckonAdjustAmount: checkedObj.value.adjustAmount === 1 ? formState.ReckonRealQty! : -1*formState.ReckonRealQty!, // 调整金额 +-代表增减
-                };
+                 const param: SettlementReq =  {};
+                const {ReckonRealQty, ReckonOtherAmount, AddMargin, ReckonAdjustAmount, DecMargin, Remark } = formState
+                // 交收量
+                if(ReckonRealQty) {
+                  param.ReckonRealQty = ReckonRealQty
+                }
+                 // 其它费用
+                if(ReckonOtherAmount) {
+                  param.ReckonOtherAmount = ReckonOtherAmount
+                }
+                // 追加保证金
+                if(AddMargin) {
+                  param.AddMargin = AddMargin
+                }
+                // 减少保证金
+                if(DecMargin) {
+                  param.DecMargin = DecMargin
+                }
+                // 调整金额 
+                if(ReckonAdjustAmount) {
+                  param.ReckonAdjustAmount = ReckonAdjustAmount
+                }
+                if(Remark) {
+                  param.Remark = Remark
+                }
+                // const params: SettlementReq = checkedObj.value.adjustMargin === 1?{
+                //     ReckonRealQty: formState.ReckonRealQty!, // 交收量
+                //     ReckonOtherAmount: formState.ReckonOtherAmount!, // 其它费用
+                //     AddMargin: formState.AddMargin!, // 追加保证金
+                //     ReckonAdjustAmount: checkedObj.value.adjustAmount === 1 ? formState.ReckonRealQty! : -1*formState.ReckonRealQty!, // 调整金额 +-代表增减
+                // }:{
+                //     ReckonRealQty: formState.ReckonRealQty!, // 交收量
+                //     ReckonOtherAmount: formState.ReckonOtherAmount!, // 其它费用
+                //     DecMargin: formState.DecMargin!, // 减少保证金
+                //     ReckonAdjustAmount: checkedObj.value.adjustAmount === 1 ? formState.ReckonRealQty! : -1*formState.ReckonRealQty!, // 调整金额 +-代表增减
+                // };
                 // 发出交收请求
-                settlementReq(props.selectedRow.spotcontractid, params, loading)
+                settlementReq(props.selectedRow.spotcontractid, param, loading)
                     .then(() => {
                         cancel();
                         context.emit('refresh');

+ 2 - 2
src/views/information/account_info/compoments/add-business/index.vue

@@ -39,7 +39,7 @@
                        name="logincode">
             <a-input class="dialogInput"
                      style="width: 200px"
-                     v-model:value="formState.accountname"
+                     v-model:value="formState.logincode"
                      placeholder="请输入账户名称" />
           </a-form-item>
         </a-col>
@@ -48,7 +48,7 @@
                        name="accountname">
             <a-input class="dialogInput"
                      style="width: 200px"
-                     v-model:value="formState.logincode"
+                     v-model:value="formState.accountname"
                      placeholder="请输入登录账号" />
           </a-form-item>
         </a-col>

+ 29 - 28
src/views/information/account_info/compoments/add-child-futures/index.vue

@@ -76,18 +76,19 @@
                       style="width: 200px"
                       v-model:value="formState.traderUserId"
                       placeholder="请选择交易用户">
-              <a-select-option v-for="item in tableList"
+              <a-select-option v-for="item in userList"
                                :key="item.roleid"
                                :value="item.roleid">
                 {{item.rolename}}
               </a-select-option>
             </a-select>
-            <a-button @click="addTrader" class="operBtn">新增</a-button>
+            <a-button @click="addTrader"
+                      class="operBtn">新增</a-button>
           </a-form-item>
         </a-col>
       </a-row>
     </a-form>
-    <AddTrader @refresh="queryTable" />
+    <AddTrader @refresh="updateTrader" />
   </a-modal>
 </template>
 
@@ -100,11 +101,12 @@ import { validateAction } from '@/common/setup/form';
 import { FormState } from './interface';
 import { handleBusinessForm, handleTradeTemplate } from './setup';
 import { hedgeOutMainReq } from '@/services/proto/accountinfo';
-import { ErmcpTaAccountEx } from '@/services/go/ermcp/account/interface';
+import { ErmcpLoginUserEx, ErmcpTaAccountEx } from '@/services/go/ermcp/account/interface';
 import { handlerManagerList } from '@/common/setup/user';
 import {getLongTypeLoginID} from "@/services/bus/login";
 import {getUserId} from "@/services/bus/account";
 import AddTrader from '../add-traders/index.vue'
+import { ErmcpTradeConfigTMP } from '@/services/go/ermcp/business-review/interface';
 
 export default defineComponent({
     name: 'account_info_futures_btn_add',
@@ -116,6 +118,18 @@ export default defineComponent({
             type: Object as PropType<ErmcpTaAccountEx>,
             default: {},
         },
+        userList: {
+            type: Array as PropType<ErmcpLoginUserEx[]>,
+            default: [],
+        },
+        marginList: {
+            type: Array as PropType<ErmcpTradeConfigTMP[]>,
+            default: [],
+        },
+        feeList: {
+            type: Array as PropType<ErmcpTradeConfigTMP[]>,
+            default: [],
+        },
     },
     setup(props, context) {
         // 控制关闭弹窗
@@ -124,19 +138,9 @@ export default defineComponent({
         const {openAction: addTrader} = openModal('account_info_trade_btn_add') 
         const loading = ref<boolean>(false);
         const { rules, formState, formRef } = handleBusinessForm();
-        // 交易用户
-        const { tableList, queryTable } = handlerManagerList(loading, 2);
-        // 交易模板
-        const { marginList, feeList, queryTemplate } = handleTradeTemplate();
-        watchEffect(() => {
-            if (visible.value) {
-                queryTable();
-                queryTemplate();
-            }
-        });
-        // function addTrader() {
-        //   context.emit('addTrader')
-        // }
+        function updateTrader() {
+          context.emit('updateTrader')
+        }
         function submit() {
             validateAction<FormState>(formRef, formState).then((res) => {
                 let reqParam: HedgeOutMainConfigReq = {
@@ -169,14 +173,11 @@ export default defineComponent({
             formState,
             rules,
             formRef,
-            tableList,
-            marginList,
-            feeList,
             visible,
             cancel,
             submit,
             addTrader,
-            queryTable,
+            updateTrader,
             loading,
         };
     },
@@ -185,14 +186,14 @@ export default defineComponent({
 
 <style lang="less">
 .add-futures-son {
-  .inlineForm {
-    .operBtn {
-          position: absolute;
-          top: -5px;
-          margin-bottom: 0;
-          margin-top: 0;
+    .inlineForm {
+        .operBtn {
+            position: absolute;
+            top: -5px;
+            margin-bottom: 0;
+            margin-top: 0;
+        }
     }
-  }
 }
 </style
 >;

+ 1 - 1
src/views/information/account_info/compoments/add-child-futures/setup.ts

@@ -33,7 +33,7 @@ export function handleTradeTemplate() {
     // 手续费
     const feeList = ref<ErmcpTradeConfigTMP[]>([])
     function queryTemplate() {
-        QueryTradeConfigTMP().then(res => {
+        return QueryTradeConfigTMP().then(res => {
             marginList.value.length = 0
             feeList.value.length = 0
             res.forEach(el => {

+ 202 - 204
src/views/information/account_info/compoments/add-managers-permission/index.vue

@@ -1,84 +1,84 @@
 <template>
-    <!-- 新增权限模板 -->
-    <a-modal class="commonModal add-roles"
-             title="新增权限模板"
-             v-model:visible="visible"
-             @cancel="cancel"
-             centered
-             :maskClosable="false"
-             width="1230px">
-        <template #footer>
-            <a-button key="cancel"
-                      type="primary"
-                      :loading="loading"
-                      @click="cancel">取消
-            </a-button>
-            <a-button key="submit"
-                      type="primary"
-                      :loading="loading"
-                      @click="submit">新增
-            </a-button>
-        </template>
-        <a-form class="inlineForm"
-                ref="formRef"
-                :model="formState"
-                :rules="rules">
-            <a-row :gutter="24">
-                <a-col :span="24">
-                    <a-form-item label="模板名称">
-                        <a-input class="dialogInput"
-                                 style="width: 200px"
-                                 v-model:value="name"
-                                 placeholder="请输入模板名称"/>
-                    </a-form-item>
-                </a-col>
-                <a-col :span="24">
-                    <a-form-item label="权限功能"
-                                 name="">
-                    </a-form-item>
-                </a-col>
-                <a-col :span="24">
-                    <div class="powerTable">
-                        <!-- <a-checkbox-group class="commonCheckboxGroup"
+  <!-- 新增权限模板 -->
+  <a-modal class="commonModal add-roles"
+           title="新增权限模板"
+           v-model:visible="visible"
+           @cancel="cancel"
+           centered
+           :maskClosable="false"
+           width="1230px">
+    <template #footer>
+      <a-button key="cancel"
+                type="primary"
+                :loading="loading"
+                @click="cancel">取消
+      </a-button>
+      <a-button key="submit"
+                type="primary"
+                :loading="loading"
+                @click="submit">新增
+      </a-button>
+    </template>
+    <a-form class="inlineForm"
+            ref="formRef"
+            :model="formState"
+            :rules="rules">
+      <a-row :gutter="24">
+        <a-col :span="24">
+          <a-form-item label="模板名称">
+            <a-input class="dialogInput"
+                     style="width: 200px"
+                     v-model:value="name"
+                     placeholder="请输入模板名称" />
+          </a-form-item>
+        </a-col>
+        <a-col :span="24">
+          <a-form-item label="权限功能"
+                       name="">
+          </a-form-item>
+        </a-col>
+        <a-col :span="24">
+          <div class="powerTable">
+            <!-- <a-checkbox-group class="commonCheckboxGroup"
 
                                          > -->
-                        <div class="powerRow"
-                             v-for="(item, i) in tableList"
-                             :key="i + '0'">
-                            <div class="powerLeft">
-                                <a-checkbox v-model:checked="item.Menu.ishadrole">
-                                    {{item.Menu.resourcename}}
-                                </a-checkbox>
-                            </div>
-                            <div class="powerRight">
-                                <div class="line"
-                                     v-for="(sub, j) in item.SubMenu"
-                                     :key="j + '1'">
-                                    <div class="left">
-                                        <a-checkbox v-model:checked="sub.Menu.ishadrole"
-                                                    @change="secondChange(item, sub)"
-                                                    :value="sub.Menu.resourcecode">
-                                            {{sub.Menu.resourcename}}
-                                        </a-checkbox>
-                                    </div>
-                                    <div class="right">
-                                        <a-checkbox v-for="(subNext, l) in sub.SubMenu"
-                                                    :key="l + '3'"
-                                                    v-model:checked="subNext.Menu.ishadrole"
-                                                    @change="thirdChange(item, sub, subNext)"
-                                                    :value="subNext.Menu.resourcecode">
-                                            {{subNext.Menu.resourcename}}
-                                        </a-checkbox>
-                                    </div>
-                                </div>
-                            </div>
-                        </div>
-                        <!-- </a-checkbox-group> -->
-                    </div>
-                </a-col>
-            </a-row>
-        </a-form>
-    </a-modal>
+            <div class="powerRow"
+                 v-for="(item, i) in tableList"
+                 :key="i + '0'">
+              <div class="powerLeft">
+                <a-checkbox v-model:checked="item.Menu.ishadrole">
+                  {{item.Menu.resourcename}}
+                </a-checkbox>
+              </div>
+              <div class="powerRight">
+                <div class="line"
+                     v-for="(sub, j) in item.SubMenu"
+                     :key="j + '1'">
+                  <div class="left">
+                    <a-checkbox v-model:checked="sub.Menu.ishadrole"
+                                @change="secondChange(item, sub)"
+                                :value="sub.Menu.resourcecode">
+                      {{sub.Menu.resourcename}}
+                    </a-checkbox>
+                  </div>
+                  <div class="right">
+                    <a-checkbox v-for="(subNext, l) in sub.SubMenu"
+                                :key="l + '3'"
+                                v-model:checked="subNext.Menu.ishadrole"
+                                @change="thirdChange(item, sub, subNext)"
+                                :value="subNext.Menu.resourcecode">
+                      {{subNext.Menu.resourcename}}
+                    </a-checkbox>
+                  </div>
+                </div>
+              </div>
+            </div>
+            <!-- </a-checkbox-group> -->
+          </div>
+        </a-col>
+      </a-row>
+    </a-form>
+  </a-modal>
 </template>
 
 <script lang="ts">
@@ -106,9 +106,8 @@
             const name = ref<string>('')
             watchEffect(() => {
                 if (visible.value) {
-                    queryResultLoadingAndInfo(QueryAccMgrRoleMenu, loading).then((res) => {
-                        console.log('res', res);
-
+                    const param = {userid: getUserId(), roleid: '0'}
+                    queryResultLoadingAndInfo(QueryAccMgrRoleMenu, loading, param).then((res) => {
                         tableList.value = res;
                     });
                 }
@@ -190,157 +189,156 @@
 </script>
 
 <style lang="less">
-    .add-roles {
-        .ant-modal-content {
-            .ant-modal-body {
-                overflow-x: hidden;
-            }
+.add-roles {
+    .ant-modal-content {
+        .ant-modal-body {
+            overflow-x: hidden;
         }
+    }
 
-        .powerTable {
-            width: 100%;
-            height: 100%;
-            border: 3px solid @m-grey11;
-            background-color: @m-black12;
-            font-size: 14px;
-            color: @m-white0;
-            .flex;
-            flex-direction: column;
-            overflow-x: auto;
-            overflow-y: hidden;
+    .powerTable {
+        width: 100%;
+        height: 100%;
+        border: 3px solid @m-grey11;
+        background-color: @m-black12;
+        font-size: 14px;
+        color: @m-white0;
+        .flex;
+        flex-direction: column;
+        overflow-x: auto;
+        overflow-y: hidden;
 
-            .ant-checkbox-group.commonCheckboxGroup .ant-checkbox-wrapper {
-                width: 120px;
+        .ant-checkbox-group.commonCheckboxGroup .ant-checkbox-wrapper {
+            width: 120px;
 
-                span + span {
-                    margin-right: 0;
-                }
+            span + span {
+                margin-right: 0;
             }
+        }
 
-            .powerRow {
-                width: 100%;
-                display: inline-flex;
-                border-bottom: 3px solid @m-grey11;
-
-                > div {
-                    align-self: center;
-                    align-items: center;
-                    white-space: nowrap;
-                    line-height: 40px;
-                }
+        .powerRow {
+            width: 100%;
+            display: inline-flex;
+            border-bottom: 3px solid @m-grey11;
 
-                .powerLeft {
-                    width: 120px;
-                    padding: 0 8px;
-                }
+            > div {
+                align-self: center;
+                align-items: center;
+                white-space: nowrap;
+                line-height: 40px;
+            }
 
-                .powerRight {
-                    flex: 1;
-                    max-width: calc(100% - 120px);
-                    .flex;
-                    flex-direction: column;
+            .powerLeft {
+                width: 120px;
+                padding: 0 8px;
+            }
 
-                    .line {
-                        width: 100%;
-                        display: inline-flex;
-                        border-bottom: 3px solid @m-grey11;
+            .powerRight {
+                flex: 1;
+                max-width: calc(100% - 120px);
+                .flex;
+                flex-direction: column;
 
-                        > div {
-                            padding: 0 8px;
-                        }
+                .line {
+                    width: 100%;
+                    display: inline-flex;
+                    border-bottom: 3px solid @m-grey11;
 
-                        .left {
-                            width: 140px;
-                            min-width: 140px;
-                            border-left: 3px solid @m-grey11;
-                            border-right: 3px solid @m-grey11;
-                        }
+                    > div {
+                        padding: 0 8px;
+                    }
 
-                        .right {
-                            flex: 1;
-                            width: calc(100% - 120px);
-                        }
+                    .left {
+                        width: 140px;
+                        min-width: 140px;
+                        border-left: 3px solid @m-grey11;
+                        border-right: 3px solid @m-grey11;
                     }
 
-                    .line:last-child {
-                        border-bottom: 0;
+                    .right {
+                        flex: 1;
+                        width: calc(100% - 120px);
                     }
                 }
 
-                // .powerMiddle {
-                //     width: 180px;
-                //     .flex;
-                //     flex-direction: column;
-                //     div {
-                //         width: 100%;
-                //         height: 40px;
-                //         line-height: 40px;
-                //         padding: 0 8px;
-                //         border: 3px solid @m-grey11;
-                //         border-top: 0;
-                //     }
-                //     div:last-child {
-                //         border-bottom: 0;
-                //     }
-                // }
-                // .powerRight {
-                //     flex: 1;
-                //     .flex;
-                //     flex-direction: column;
-                //     div {
-                //         width: 100%;
-                //         height: 40px;
-                //         line-height: 40px;
-                //         padding: 0 8px;
-                //         justify-content: flex-start;
-                //         border-bottom: 3px solid @m-grey11;
-                //     }
-                //     div:last-child {
-                //         border-bottom: 0;
-                //     }
-                // }
+                .line:last-child {
+                    border-bottom: 0;
+                }
             }
+
+            // .powerMiddle {
+            //     width: 180px;
+            //     .flex;
+            //     flex-direction: column;
+            //     div {
+            //         width: 100%;
+            //         height: 40px;
+            //         line-height: 40px;
+            //         padding: 0 8px;
+            //         border: 3px solid @m-grey11;
+            //         border-top: 0;
+            //     }
+            //     div:last-child {
+            //         border-bottom: 0;
+            //     }
+            // }
+            // .powerRight {
+            //     flex: 1;
+            //     .flex;
+            //     flex-direction: column;
+            //     div {
+            //         width: 100%;
+            //         height: 40px;
+            //         line-height: 40px;
+            //         padding: 0 8px;
+            //         justify-content: flex-start;
+            //         border-bottom: 3px solid @m-grey11;
+            //     }
+            //     div:last-child {
+            //         border-bottom: 0;
+            //     }
+            // }
         }
-        .ant-checkbox-wrapper {
-            color: @m-white0;
-            font-size: 14px;
-            .ant-checkbox {
-                margin-right: 2px;
-                .ant-checkbox-inner {
-                    background: #15202B;
-                    border: 1px solid #2B3F52;
-                    border-radius: 3px;
-                }
+    }
+    .ant-checkbox-wrapper {
+        color: @m-white0;
+        font-size: 14px;
+        .ant-checkbox {
+            margin-right: 2px;
+            .ant-checkbox-inner {
+                background: #15202b;
+                border: 1px solid #2b3f52;
+                border-radius: 3px;
             }
-            .ant-checkbox.ant-checkbox-checked {
-                .ant-checkbox-inner {
-                    &::after {
-                        border-color: #3A87F7;
-                    }
-                }
+        }
+        .ant-checkbox.ant-checkbox-checked {
+            .ant-checkbox-inner {
                 &::after {
-                    border-color: #3A87F7;
+                    border-color: #3a87f7;
                 }
             }
-            span+span {
-                margin-right: 15px;
+            &::after {
+                border-color: #3a87f7;
+            }
+        }
+        span + span {
+            margin-right: 15px;
+            color: @m-white0;
+            font-size: 14px;
+        }
+    }
+    .ant-checkbox-wrapper-disabled {
+        .ant-checkbox-disabled {
+            outline-color: #2b3f52;
+            .ant-checkbox-input {
                 color: @m-white0;
                 font-size: 14px;
             }
-        }
-        .ant-checkbox-wrapper-disabled {
-            .ant-checkbox-disabled {
-                outline-color: #2B3F52;
-                .ant-checkbox-input {
-                    color: @m-white0;
-                    font-size: 14px;
-                }
-                .ant-checkbox-inner {
-                    border-color: #2B3F52 !important;
-                }
+            .ant-checkbox-inner {
+                border-color: #2b3f52 !important;
             }
         }
-        
     }
+}
 </style
 >;

+ 1 - 1
src/views/information/account_info/compoments/add-traders/index.vue

@@ -60,7 +60,7 @@ export default defineComponent({
         function submit() {
             validateAction<TraderFormState>(formRef, formState).then((res) => {
                 const reqParam: LoginaccountOperateReq = {
-                    operatetype: 10, // uint32 操作类型-1:新增 2:修改 3:新增管理员 4:修改管理员 5:锁定 6:解锁 7:注销 8:恢复 9:重置密码 10:新增登录帐号 11:停用用户 12:恢复用户 13:修改用户信息
+                    operatetype: 1, // uint32 操作类型-1:新增 2:修改 3:新增管理员 4:修改管理员 5:锁定 6:解锁 7:注销 8:恢复 9:重置密码 10:新增登录帐号 11:停用用户 12:恢复用户 13:修改用户信息
                     roleids: [24],
                     logintaaccounts: [],
                     accountname: res.rolename,

+ 98 - 111
src/views/information/account_info/compoments/cancel-futures/index.vue

@@ -19,62 +19,42 @@
                 @click="submit">注销
       </a-button>
     </template>
-    <a-form class="inlineForm"
-            :model="formState">
+    <a-form class="inlineForm">
       <a-row :gutter="24">
         <a-col :span="12">
-          <a-form-item label="所属户"
-                       name="">
-            <span class="white">{{rolename}}</span>
+          <a-form-item label="所属期货账户"
+                       name="userinfotype">
+            <span class="white">{{selectedData.mainAcc.accountname}}/{{selectedData.mainAcc.hedgeaccountcode}}</span>
           </a-form-item>
         </a-col>
         <a-col :span="12">
           <a-form-item label="账户名称"
-                       name="logincode">
-            <a-input class="dialogInput"
-                     readonly
-                     style="width: 200px"
-                     v-model:value="formState.logincode"
-                     placeholder="请输入账户名称" />
+                       name="accountname">
+            <span class="white">{{secondeData.accountname}}</span>
           </a-form-item>
         </a-col>
         <a-col :span="12">
-          <a-form-item label="登录账号"
-                       name="accountname">
-            <a-input class="dialogInput"
-                     style="width: 200px"
-                     readonly
-                     v-model:value="formState.accountname"
-                     placeholder="请输入登录账号" />
+          <a-form-item label="期货保证金"
+                       name="trademargintmpid">
+            <span class="white"
+                  v-if="marginList.length">{{marginList[0].tradeconfigtmpname}}</span>
+            <span class="white"
+                  v-else>--</span>
           </a-form-item>
         </a-col>
         <a-col :span="12">
-          <a-form-item label="手机号码"
-                       name="mobile">
-            <a-input class="dialogInput"
-                     v-model:value="formState.mobile"
-                     style="width: 200px"
-                     readonly
-                     placeholder="请输入手机号码" />
+          <a-form-item label="期货手续费"
+                       name="tradefeetmpid">
+            <span class="white"
+                  v-if="feeList.length">{{feeList[0].tradeconfigtmpname}}</span>
+            <span class="white"
+                  v-else>--</span>
           </a-form-item>
         </a-col>
         <a-col :span="24">
-          <a-form-item label="授权期货账户"
-                       class="checkboxGroupItem"
-                       name="logintaaccounts">
-            <a-checkbox-group class="commonCheckboxGroup"
-                              v-model:value="formState.logintaaccounts">
-              <a-row>
-                <a-col :span="12"
-                       v-for="(item, index) in selectedData.acclist"
-                       :key="index">
-                  <a-checkbox disabled
-                              :value="item.accountid">
-                    {{item.accountname}}/{{item.accountid}}
-                  </a-checkbox>
-                </a-col>
-              </a-row>
-            </a-checkbox-group>
+          <a-form-item label="指定交易用户"
+                       name="traderUserId">
+            <span class="white">{{getRoleName()}}</span>
           </a-form-item>
         </a-col>
       </a-row>
@@ -83,80 +63,87 @@
 </template>
 
 <script lang="ts">
-import { closeModal } from '@/common/setup/modal/index';
-import { defineComponent, ref, PropType, watchEffect } from 'vue';
-import { Modal } from 'ant-design-vue';
-import {LoginaccountOperateReq, TaaccountOperateReq} from '@/services/proto/accountinfo/interface';
-import { requestResultLoadingAndInfo } from '@/common/methods/request/resultInfo';
-import {loginAccountOperate, taAccountOperateReq} from '@/services/proto/accountinfo';
-import { ErmcpLoginUser, ErmcpLoginUserEx, ErmcpTaAccount } from '@/services/go/ermcp/account/interface';
-import { handleBusinessForm, handleRoleName } from '../setup';
-import { mergeTwoObj } from '@/utils/objHandle';
-import {getLongTypeLoginID} from "@/services/bus/login";
+    import {closeModal} from '@/common/setup/modal/index';
+    import {defineComponent, ref, PropType, watchEffect} from 'vue';
+    import {Modal} from 'ant-design-vue';
+    import {LoginaccountOperateReq, TaaccountOperateReq} from '@/services/proto/accountinfo/interface';
+    import {requestResultLoadingAndInfo} from '@/common/methods/request/resultInfo';
+    import {loginAccountOperate, taAccountOperateReq} from '@/services/proto/accountinfo';
+    import {
+        ErmcpLoginUser,
+        ErmcpLoginUserEx,
+        ErmcpTaAccount,
+        ErmcpTaAccountEx
+    } from '@/services/go/ermcp/account/interface';
+    import {handleBusinessForm, handleRoleName} from '../setup';
+    import {mergeTwoObj} from '@/utils/objHandle';
+    import {getLongTypeLoginID} from "@/services/bus/login";
+    import {ErmcpTradeConfigTMP} from '@/services/go/ermcp/business-review/interface';
 
-export default defineComponent({
-    name: 'account_info_futures_btn_child_cancel',
-    components: {},
-    props: {
-        selectedData: {
-            type: Object as PropType<ErmcpTaAccount>,
-            default: {},
-        },
-        tableList: {
-            type: Array as PropType<ErmcpLoginUserEx[]>,
-            default: [],
-        },
-        accountList: {
-            default: [],
-            type: Object as PropType<ErmcpTaAccount[]>,
+    export default defineComponent({
+        name: 'account_info_futures_btn_child_cancel',
+        components: {},
+        props: {
+            selectedData: {
+                type: Object as PropType<ErmcpTaAccountEx>,
+                default: {},
+            },
+            secondeData: {
+                default: {},
+                type: Object as PropType<ErmcpTaAccount>,
+            },
+            userList: {
+                type: Array as PropType<ErmcpLoginUserEx[]>,
+                default: [],
+            },
+            marginList: {
+                type: Array as PropType<ErmcpTradeConfigTMP[]>,
+                default: [],
+            },
+            feeList: {
+                type: Array as PropType<ErmcpTradeConfigTMP[]>,
+                default: [],
+            },
         },
-    },
-    setup(props, context) {
-        // 控制关闭弹窗
-        const { visible, cancel } = closeModal('account_info_futures_btn_child_cancel');
-        const loading = ref<boolean>(false);
-        const { formState } = handleBusinessForm();
-        const { rolename, getRoleName } = handleRoleName();
-        watchEffect(() => {
-            if (visible.value) {
-                // const { selectedData, tableList } = props;
-                // mergeTwoObj(formState, selectedData);
-                // getRoleName(tableList, selectedData);
-                // formState.logintaaccounts = selectedData.acclist.map((e) => e.accountid);
-                // formState.accountname = props.selectedData.loginname;
+        setup(props, context) {
+            // 控制关闭弹窗
+            const {visible, cancel} = closeModal('account_info_futures_btn_child_cancel');
+            const loading = ref<boolean>(false);
+
+            function submit() {
+                Modal.confirm({
+                    title: '是否确认注销该账户',
+                    okText: '确认注销',
+                    cancelText: '取消',
+                    onOk() {
+                        let reqParam: TaaccountOperateReq = {
+                            accountid: props.secondeData.accountid,  // uint64 期货账户ID
+                            tradestatus: 7, // uint32 7注销
+                            modifierid: Number(getLongTypeLoginID()), // uint64 修改人
+                            areauserid: Number(props.secondeData.relateduserid), // uint64 机构用户ID
+                        };
+                        requestResultLoadingAndInfo(taAccountOperateReq, reqParam, loading, ['账户注销成功', '账户注销失败:']).then(() => {
+                            cancel();
+                            context.emit('refresh');
+                        });
+                    },
+                    onCancel() {
+                    },
+                });
             }
-        });
-        function submit() {
-            Modal.confirm({
-                title: '是否确认注销该账户',
-                okText: '确认注销',
-                cancelText: '取消',
-                onOk() {
-                    let reqParam: TaaccountOperateReq = {
-                        accountid: props.selectedData.accountid, // uint64 期货账户ID
-                        tradestatus: 7,// double 授信金额正为加负为减
-                        modifierid: Number(getLongTypeLoginID()),// uint64 修改人
-                        areauserid: props.selectedData.relateduserid,// uint64 机构用户ID
-                    };
-                    requestResultLoadingAndInfo(taAccountOperateReq, reqParam, loading, ['账户注销成功', '账户注销失败:']).then(() => {
-                        cancel();
-                        context.emit('refresh');
-                    });
-                },
-                onCancel() {},
-            });
+                        function getRoleName() {
+          const item = props.userList.find(e => e.roleid === props.secondeData.relateduserid)
+          return item ? item.rolename : '--'
         }
-
-        return {
-            formState,
-            rolename,
-            visible,
-            cancel,
-            submit,
-            loading,
-        };
-    },
-});
+            return {
+                visible,
+                cancel,
+                submit,
+                loading,
+                getRoleName,
+            };
+        },
+    });
 </script>
 
 <style lang="less">

+ 150 - 109
src/views/information/account_info/compoments/credit-futures/index.vue

@@ -1,120 +1,161 @@
 <template>
-  <!-- 授信-->
-  <a-modal class="add-custom custom-detail"
-           title="授信"
-           v-model:visible="visible"
-           centered
-           :maskClosable="maskClosableFlag"
-           @cancel="cancel"
-           width="890px">
-    <template #footer>
-      <a-button key="submit"
-                type="primary"
-                :loading="loading"
-                @click="cancel">取消
-      </a-button>
-      <a-button key="submit"
-                type="primary"
-                :loading="loading"
-                @click="submit">授信
-      </a-button>
-    </template>
-    <a-form class="inlineForm">
-      <a-row :gutter="24">
-        <a-col :span="12">
-          <a-form-item label="账户名称"
-                       name="userid">
-            <span class="white">王二5001</span>
-          </a-form-item>
-        </a-col>
-        <a-col :span="12">
-          <a-form-item label="资金账号"
-                       name="">
-            <span class="white">250000000017</span>
-          </a-form-item>
-        </a-col>
-        <a-col :span="12">
-          <a-form-item label="授信总额"
-                       name="">
-            <span class="white"> 请输入授信金额</span>
-          </a-form-item>
-        </a-col>
-        <a-col :span="12">
-          <a-form-item label="子账户当前余额"
-                       name="">
-            <span class="white">10000.00</span>
-          </a-form-item>
-        </a-col>
-        <a-col :span="12">
-          <a-form-item label="授信金额"
-                       class="relative"
-                       name="">
-            <a-input class="dialogInput" style="width: 200px" placeholder="请输入授信金额"></a-input>
-            <div class="tip">正数为增加,负数为减少</div>
-          </a-form-item>
-        </a-col>
-      </a-row>
-    </a-form>
-  </a-modal>
+    <!-- 授信-->
+    <a-modal class="add-custom custom-detail"
+             title="授信"
+             v-model:visible="visible"
+             centered
+             :maskClosable="maskClosableFlag"
+             @cancel="cancel"
+             width="890px">
+        <template #footer>
+            <a-button key="submit"
+                      type="primary"
+                      :loading="loading"
+                      @click="cancel">取消
+            </a-button>
+            <a-button key="submit"
+                      type="primary"
+                      :loading="loading"
+                      @click="submit">授信
+            </a-button>
+        </template>
+        <a-form class="inlineForm">
+            <a-row :gutter="24">
+                <a-col :span="12">
+                    <a-form-item label="账户名称"
+                                 name="userid">
+                        <span class="white">{{secondeData.accountname}}</span>
+                    </a-form-item>
+                </a-col>
+                <a-col :span="12">
+                    <a-form-item label="资金账号"
+                                 name="">
+                        <span class="white">{{secondeData.accountid}}</span>
+                    </a-form-item>
+                </a-col>
+                <a-col :span="12">
+                    <a-form-item label="授信总额"
+                                 name="">
+                        <span class="white"> {{mortgagecredit}}</span>
+                    </a-form-item>
+                </a-col>
+                <a-col :span="12">
+                    <a-form-item label="子账户当前余额"
+                                 name="">
+                        <span class="white">{{currentbalance}}</span>
+                    </a-form-item>
+                </a-col>
+                <a-col :span="12">
+                    <a-form-item label="授信金额"
+                                 class="relative"
+                                 name="">
+                        <a-input class="dialogInput"
+                                 style="width: 200px"
+                                 v-model:value="money"
+                                 placeholder="请输入授信金额"></a-input>
+                        <div class="tip">正数为增加,负数为减少</div>
+                    </a-form-item>
+                </a-col>
+            </a-row>
+        </a-form>
+    </a-modal>
 </template>
 
 <script lang="ts">
-import { defineComponent, PropType, ref } from 'vue';
-import { closeModal } from '@/common/setup/modal/index';
-import {ErmcpLoginUser, ErmcpTaAccount, ErmcpTaAccountEx} from '@/services/go/ermcp/account/interface';
-import { Modal } from 'ant-design-vue';
-import { requestResultLoadingAndInfo } from '@/common/methods/request/resultInfo';
-import {LoginaccountOperateReq, TaaccountTransfersxmoneyReq} from '@/services/proto/accountinfo/interface';
-import {loginAccountOperate, taAccountTransfersXMoneyReq} from '@/services/proto/accountinfo';
-import {getLongTypeLoginID} from "@/services/bus/login";
+    import {defineComponent, PropType, ref, toRaw, watchEffect} from 'vue';
+    import {closeModal} from '@/common/setup/modal/index';
+    import {ErmcpLoginUser, ErmcpTaAccount, ErmcpTaAccountEx} from '@/services/go/ermcp/account/interface';
+    import {message, Modal} from 'ant-design-vue';
+    import {requestResultLoadingAndInfo} from '@/common/methods/request/resultInfo';
+    import {LoginaccountOperateReq, TaaccountTransfersxmoneyReq} from '@/services/proto/accountinfo/interface';
+    import {loginAccountOperate, taAccountTransfersXMoneyReq} from '@/services/proto/accountinfo';
+    import {getLongTypeLoginID} from "@/services/bus/login";
+    import {QueryAccMgrTaAccountInfo} from '@/services/go/ermcp/account';
+    import {getUserId} from '@/services/bus/account';
 
-export default defineComponent({
-    name: 'account_info_futures_btn_child_credit',
-    components: {},
-    props: {
-        selectedData: {
-            type: Object as PropType<ErmcpTaAccount>,
-            default: {},
+    export default defineComponent({
+        name: 'account_info_futures_btn_child_credit',
+        components: {},
+        props: {
+            selectedData: {
+                type: Object as PropType<ErmcpTaAccount>,
+                default: {},
+            },
+            secondeData: {
+                default: {},
+                type: Object as PropType<ErmcpTaAccount>,
+            },
         },
-    },
-    setup(props, context) {
-        const { visible, cancel } = closeModal('account_info_futures_btn_child_credit');
-        const loading = ref<boolean>(false);
-        function submit() {
-            Modal.confirm({
-                title: '是否确认授信账户',
-                okText: '确认授信',
-                cancelText: '取消',
-                onOk() {
-                    let reqParam: TaaccountTransfersxmoneyReq = {
-                        accountid: props.selectedData.accountid, // uint64 期货账户ID
-                        sxmoney: 1,// double 授信金额正为加负为减
-                        modifierid: Number(getLongTypeLoginID()),// uint64 修改人
-                        areauserid: props.selectedData.relateduserid,// uint64 机构用户ID
-                    };
-                    requestResultLoadingAndInfo(taAccountTransfersXMoneyReq, reqParam, loading, ['账户授信成功', '账户授信失败:']).then(() => {
-                        cancel();
-                        context.emit('refresh');
-                    });
-                },
-                onCancel() {},
-            });
-        }
-        return {
-            visible,
-            cancel,
-            maskClosableFlag: false,
-            submit,
-            loading,
-        };
-    },
-});
+        setup(props, context) {
+            const {visible, cancel} = closeModal('account_info_futures_btn_child_credit');
+            const loading = ref<boolean>(false);
+            // 当前余额
+            const currentbalance = ref<number>(0)
+            // 授信总额
+            const mortgagecredit = ref<number>(0)
+            const money = ref<number | null>(null)
+            watchEffect(() => {
+                if (visible.value && props.secondeData?.accountid) {
+                    const param = {
+                        userid: getUserId(),
+                        accountid: props.secondeData.accountid
+                    }
+                    QueryAccMgrTaAccountInfo(param).then(res => {
+                        console.log(res);
+                        if (res.length) {
+                            currentbalance.value = res[0].currentbalance
+                            mortgagecredit.value = res[0].mortgagecredit
+                        }
+                    })
+                }
+            })
+
+            function submit() {
+                Modal.confirm({
+                    title: '是否确认授信账户',
+                    okText: '确认授信',
+                    cancelText: '取消',
+                    onOk() {
+                        const param = toRaw(money)
+                        if (param) {
+                            let reqParam: TaaccountTransfersxmoneyReq = {
+                                accountid: props.secondeData.accountid, // uint64 期货账户ID
+                                sxmoney: Number(param.value as number),// double 授信金额正为加负为减
+                                modifierid: Number(getLongTypeLoginID()),// uint64 修改人
+                                areauserid: Number(props.secondeData.relateduserid),// uint64 机构用户ID
+                            };
+                            requestResultLoadingAndInfo(taAccountTransfersXMoneyReq, reqParam, loading, ['账户授信成功', '账户授信失败:']).then(() => {
+                                cancel();
+                                context.emit('refresh');
+                            });
+                        } else {
+                            message.error('请输入授信金额')
+                        }
+
+                    },
+                    onCancel() {
+                    },
+                });
+            }
+
+            return {
+                visible,
+                cancel,
+                maskClosableFlag: false,
+                submit,
+                loading,
+                currentbalance,
+                mortgagecredit,
+                money,
+            };
+        },
+    });
 </script>
 
 <style lang="less">
-.custom-detail {
-    .ant-form.inlineForm {
-        margin-top: 20px;
+    .custom-detail {
+        .ant-form.inlineForm {
+            margin-top: 20px;
+        }
     }
-}
 </style>;

+ 30 - 62
src/views/information/account_info/compoments/detail-futures/index.vue

@@ -12,8 +12,7 @@
                 type="primary"
                 @click="cancel">关闭</a-button>
     </template>
-    <a-form class="inlineForm"
-            :model="formState">
+    <a-form class="inlineForm">
       <a-row :gutter="24">
         <a-col :span="12">
           <a-form-item label="所属期货账户"
@@ -24,56 +23,31 @@
         <a-col :span="12">
           <a-form-item label="账户名称"
                        name="accountname">
-            <a-input class="dialogInput"
-                     readonly
-                     style="width: 200px"
-                     v-model:value="formState.accountname"
-                     placeholder="请输入账户名称" />
+            <span class="white">{{secondeData.accountname}}</span>
           </a-form-item>
         </a-col>
         <a-col :span="12">
           <a-form-item label="期货保证金"
                        name="trademargintmpid">
-            <a-select class="inlineFormSelect"
-                      style="width: 200px"
-                      v-model:value="formState.tradefeetmpid"
-                      placeholder="请选择期货手续费">
-              <a-select-option v-for="item in feeList"
-                               :key="item.tradeconfigtmpid"
-                               :value="item.tradeconfigtmpid">
-                {{item.tradeconfigtmpname}}
-              </a-select-option>
-            </a-select>
+            <span class="white"
+                  v-if="marginList.length">{{marginList[0].tradeconfigtmpname}}</span>
+            <span class="white"
+                  v-else>--</span>
           </a-form-item>
         </a-col>
         <a-col :span="12">
           <a-form-item label="期货手续费"
                        name="tradefeetmpid">
-            <a-select class="inlineFormSelect"
-                      style="width: 200px"
-                      v-model:value="formState.tradefeetmpid"
-                      placeholder="请选择期货手续费">
-              <a-select-option v-for="item in feeList"
-                               :key="item.tradeconfigtmpid"
-                               :value="item.tradeconfigtmpid">
-                {{item.tradeconfigtmpname}}
-              </a-select-option>
-            </a-select>
+            <span class="white"
+                  v-if="feeList.length">{{feeList[0].tradeconfigtmpname}}</span>
+            <span class="white"
+                  v-else>--</span>
           </a-form-item>
         </a-col>
         <a-col :span="24">
           <a-form-item label="指定交易用户"
                        name="traderUserId">
-            <a-select class="inlineFormSelect"
-                      style="width: 200px"
-                      v-model:value="formState.traderUserId"
-                      placeholder="请选择交易用户">
-              <a-select-option v-for="item in tableList"
-                               :key="item.roleid"
-                               :value="item.roleid">
-                {{item.rolename}}
-              </a-select-option>
-            </a-select>
+            <span class="white">{{getRoleName()}}</span>
           </a-form-item>
         </a-col>
       </a-row>
@@ -89,51 +63,45 @@ import { handleBusinessForm } from '../add-child-futures/setup';
 import { ErmcpLoginUser, ErmcpLoginUserEx, ErmcpTaAccount, ErmcpTaAccountEx } from '@/services/go/ermcp/account/interface';
 import { handlerManagerList } from '@/common/setup/user';
 import { handleTradeTemplate } from '../add-child-futures/setup';
+import { ErmcpTradeConfigTMP } from '@/services/go/ermcp/business-review/interface';
 
 export default defineComponent({
     name: 'trader-detail',
     components: {},
-    props: {
+        props: {
         selectedData: {
             type: Object as PropType<ErmcpTaAccountEx>,
             default: {},
         },
-        secondeData: {
-            type: Object as PropType<ErmcpTaAccountEx>,
+                secondeData: {
             default: {},
+            type: Object as PropType<ErmcpTaAccount>,
+        },
+        userList: {
+            type: Array as PropType<ErmcpLoginUserEx[]>,
+            default: [],
+        },
+        marginList: {
+            type: Array as PropType<ErmcpTradeConfigTMP[]>,
+            default: [],
         },
-        accountList: {
+        feeList: {
+            type: Array as PropType<ErmcpTradeConfigTMP[]>,
             default: [],
-            type: Object as PropType<ErmcpTaAccount[]>,
         },
     },
     setup(props) {
         const { visible, cancel } = closeModal('detail');
-        const { formState } = handleBusinessForm();
         const loading = ref<boolean>(false);
-                // 交易用户
-        const { tableList, queryTable } = handlerManagerList(loading, 2);
-        // 交易模板
-        const { marginList, feeList, queryTemplate } = handleTradeTemplate();
-        watchEffect(() => {
-            if (visible.value && props.secondeData) {
-              console.log('selectedData', props.secondeData);
-               queryTable();
-                queryTemplate();
-                mergeTwoObj(formState, props.secondeData);
-                // getRoleName(tableList, selectedData);
-                // formState.logintaaccounts = selectedData.acclist.map((e) => e.accountid);
-                // formState.accountname = props.selectedData.loginname;
-            }
-        });
+        function getRoleName() {
+          const item = props.userList.find(e => e.roleid === props.secondeData.relateduserid)
+          return item ? item.rolename : '--'
+        }
         return {
-                        formState,
-            tableList,
-            marginList,
-            feeList,
             visible,
             cancel,
             loading,
+            getRoleName,
         };
     },
 });

+ 16 - 11
src/views/information/account_info/compoments/managers-permission-delete/index.vue

@@ -1,7 +1,7 @@
 <template>
-  <!-- 新增权限模板 -->
+  <!-- 删除权限模板 -->
   <a-modal class="commonModal add-roles"
-           title="修改权限模板"
+           title="删除权限模板"
            v-model:visible="visible"
            @cancel="cancel"
            centered
@@ -16,7 +16,7 @@
       <a-button key="submit"
                 type="primary"
                 :loading="loading"
-                @click="submit">修改
+                @click="submit">删除
       </a-button>
     </template>
     <a-form class="inlineForm"
@@ -43,7 +43,8 @@
                  v-for="(item, i) in tableList"
                  :key="i + '0'">
               <div class="powerLeft">
-                <a-checkbox v-model:checked="item.Menu.ishadrole">
+                <a-checkbox v-model:checked="item.Menu.ishadrole"
+                            disabled>
                   {{item.Menu.resourcename}}
                 </a-checkbox>
               </div>
@@ -54,7 +55,8 @@
                   <div class="left">
                     <a-checkbox v-model:checked="sub.Menu.ishadrole"
                                 @change="secondChange(item, sub)"
-                                :value="sub.Menu.resourcecode">
+                                :value="sub.Menu.resourcecode"
+                                disabled>
                       {{sub.Menu.resourcename}}
                     </a-checkbox>
                   </div>
@@ -63,7 +65,8 @@
                                 :key="l + '3'"
                                 v-model:checked="subNext.Menu.ishadrole"
                                 @change="thirdChange(item, sub, subNext)"
-                                :value="subNext.Menu.resourcecode">
+                                :value="subNext.Menu.resourcecode"
+                                disabled>
                       {{subNext.Menu.resourcename}}
                     </a-checkbox>
                   </div>
@@ -108,10 +111,12 @@
             const name = ref<string>('')
             watchEffect(() => {
                 if (visible.value) {
-                    queryResultLoadingAndInfo(QueryAccMgrRoleMenu, loading).then((res) => {
+                    const { modifiername, areauserid, autoid} = props.selectedData;
+                    name.value = modifiername
+                    const param = {userid: areauserid, roleid: autoid.toString()}
+                    queryResultLoadingAndInfo(QueryAccMgrRoleMenu, loading, param).then((res) => {
                         tableList.value = res;
                     });
-                    name.value = props.selectedData.modifiername
                 }
             });
 
@@ -142,8 +147,8 @@
                     return
                 }
                 const reqParam: ManagerRoleOperateReq = {
-                    autoid: getUserId(), // uint64 角色ID
-                    operatetype: 1, // uint32 操作类型-1:新增 2:修改
+                    autoid: props.selectedData.autoid, // uint64 角色ID
+                    operatetype: 3, // uint32 操作类型-1:新增 2:修改
                     areauserid: getAreaUserId(), // uint64 所属机构
                     modifierid: Number(getLongTypeLoginID()), // uint64 修改人ID
                     rolename: name.value, // string 角色名称
@@ -154,7 +159,7 @@
                     }) // MemberFuncMenu 机构菜单
 
                 }
-                requestResultLoadingAndInfo(roleOperate, reqParam, loading, ['新增成功', '新增失败:']).then(() => {
+                requestResultLoadingAndInfo(roleOperate, reqParam, loading, ['删除成功', '删除失败:']).then(() => {
                     cancel();
                     context.emit('refresh');
                 });

+ 11 - 11
src/views/information/account_info/compoments/managers-permission-detail/index.vue

@@ -11,12 +11,7 @@
       <a-button key="cancel"
                 type="primary"
                 :loading="loading"
-                @click="cancel">取消
-      </a-button>
-      <a-button key="submit"
-                type="primary"
-                :loading="loading"
-                @click="submit">删除
+                @click="cancel">完成
       </a-button>
     </template>
     <a-form class="inlineForm"
@@ -43,7 +38,8 @@
                  v-for="(item, i) in tableList"
                  :key="i + '0'">
               <div class="powerLeft">
-                <a-checkbox v-model:checked="item.Menu.ishadrole">
+                <a-checkbox v-model:checked="item.Menu.ishadrole"
+                            disabled>
                   {{item.Menu.resourcename}}
                 </a-checkbox>
               </div>
@@ -54,7 +50,8 @@
                   <div class="left">
                     <a-checkbox v-model:checked="sub.Menu.ishadrole"
                                 @change="secondChange(item, sub)"
-                                :value="sub.Menu.resourcecode">
+                                :value="sub.Menu.resourcecode"
+                                disabled>
                       {{sub.Menu.resourcename}}
                     </a-checkbox>
                   </div>
@@ -63,7 +60,8 @@
                                 :key="l + '3'"
                                 v-model:checked="subNext.Menu.ishadrole"
                                 @change="thirdChange(item, sub, subNext)"
-                                :value="subNext.Menu.resourcecode">
+                                :value="subNext.Menu.resourcecode"
+                                disabled>
                       {{subNext.Menu.resourcename}}
                     </a-checkbox>
                   </div>
@@ -108,10 +106,12 @@
             const name = ref<string>('')
             watchEffect(() => {
                 if (visible.value) {
-                    queryResultLoadingAndInfo(QueryAccMgrRoleMenu, loading).then((res) => {
+                    const { modifiername, areauserid, autoid} = props.selectedData;
+                    name.value = modifiername
+                    const param = {userid: areauserid, roleid: autoid.toString()}
+                    queryResultLoadingAndInfo(QueryAccMgrRoleMenu, loading, param).then((res) => {
                         tableList.value = res;
                     });
-                    name.value = props.selectedData.modifiername
                 }
             });
 

+ 7 - 6
src/views/information/account_info/compoments/managers-permission-modify/index.vue

@@ -109,8 +109,10 @@
             const name = ref<string>('')
             watchEffect(() => {
                 if (visible.value) {
-                    name.value = props.selectedData.modifiername
-                    queryResultLoadingAndInfo(QueryAccMgrRoleMenu, loading).then((res) => {
+                    const { modifiername, areauserid, autoid} = props.selectedData;
+                    name.value = modifiername
+                    const param = {userid: areauserid, roleid: autoid.toString()}
+                    queryResultLoadingAndInfo(QueryAccMgrRoleMenu, loading, param).then((res) => {
                         tableList.value = res;
                     });
                 }
@@ -143,8 +145,8 @@
                     return
                 }
                 const reqParam: ManagerRoleOperateReq = {
-                    autoid: getUserId(), // uint64 角色ID
-                    operatetype: 1, // uint32 操作类型-1:新增 2:修改
+                    autoid: props.selectedData.autoid, // uint64 角色ID
+                    operatetype: 2, // uint32 操作类型-1:新增 2:修改
                     areauserid: getAreaUserId(), // uint64 所属机构
                     modifierid: Number(getLongTypeLoginID()), // uint64 修改人ID
                     rolename: name.value, // string 角色名称
@@ -153,9 +155,8 @@
                             resourcecode: item
                         } as MemberFuncMenu
                     }) // MemberFuncMenu 机构菜单
-
                 }
-                requestResultLoadingAndInfo(roleOperate, reqParam, loading, ['新增成功', '新增失败:']).then(() => {
+                requestResultLoadingAndInfo(roleOperate, reqParam, loading, ['修改成功', '修改失败:']).then(() => {
                     cancel();
                     context.emit('refresh');
                 });

+ 2 - 0
src/views/information/account_info/compoments/managers-permission/index.vue

@@ -82,6 +82,8 @@ export default defineComponent({
         
         function queryTable() {
              queryResultLoadingAndInfo(QueryAccMgrRole, loading).then((res) => {
+                 console.log(res);
+                 
                     tableList.value = res.map((e: ErmcpRole, i: number) => Object.assign(e, {key: `${i}`}))
                 });
         }

+ 120 - 65
src/views/information/account_info/compoments/modify-futures-son/index.vue

@@ -8,10 +8,14 @@
            :maskClosable="false"
            width="890px">
     <template #footer>
+      <a-button key="cancel"
+                type="primary"
+                :loading="loading"
+                @click="cancel">取消</a-button>
       <a-button key="submit"
                 type="primary"
                 :loading="loading"
-                @click="submit">完成</a-button>
+                @click="submit">修改</a-button>
     </template>
     <a-form class="inlineForm"
             ref="formRef"
@@ -21,35 +25,54 @@
         <a-col :span="12">
           <a-form-item label="所属期货账户"
                        name="userinfotype">
-            <span class="white">王小小/824327648</span>
+            <span class="white">{{selectedData.mainAcc.accountname}}/{{selectedData.mainAcc.hedgeaccountcode}}</span>
           </a-form-item>
         </a-col>
         <a-col :span="12">
           <a-form-item label="账户名称"
-                       name="">
+                       name="accountname">
             <a-input class="dialogInput"
+                     v-model:value="formState.accountname"
                      style="width: 200px"
                      placeholder="请输入账户名称" />
           </a-form-item>
         </a-col>
         <a-col :span="12">
           <a-form-item label="期货保证金"
-                       name="">
-            <a-input class="dialogInput"
-                     style="width: 200px"
-                     placeholder="请输入期货保证金" />
+                       name="trademargintmpid">
+            <a-select class="inlineFormSelect"
+                      style="width: 200px"
+                      v-model:value="formState.trademargintmpid"
+                      placeholder="请选择保证金模板">
+              <a-select-option v-for="item in marginList"
+                               :key="item.tradeconfigtmpid"
+                               :value="item.tradeconfigtmpid">
+                {{item.tradeconfigtmpname}}
+              </a-select-option>
+            </a-select>
           </a-form-item>
         </a-col>
         <a-col :span="12">
           <a-form-item label="期货手续费"
-                       name="">
+                       name="tradefeetmpid">
             <a-select class="inlineFormSelect"
                       style="width: 200px"
+                      v-model:value="formState.tradefeetmpid"
                       placeholder="请选择期货手续费">
-              <a-select-option value="权限一">权限一</a-select-option>
+              <a-select-option v-for="item in feeList"
+                               :key="item.tradeconfigtmpid"
+                               :value="item.tradeconfigtmpid">
+                {{item.tradeconfigtmpname}}
+              </a-select-option>
             </a-select>
           </a-form-item>
         </a-col>
+        <a-col :span="24">
+          <a-form-item label="指定交易用户"
+                       name="traderUserId">
+            <span class="white">{{getRoleName()}}</span>
+          </a-form-item>
+        </a-col>
       </a-row>
     </a-form>
   </a-modal>
@@ -57,10 +80,7 @@
 
 <script lang="ts">
 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, reactive, toRaw, UnwrapRef, watchEffect, PropType } from 'vue';
 import {validateAction} from "@/common/setup/form";
 import {FormState} from "@/views/information/account_info/compoments/add-child-futures/interface";
 import {HedgeOutMainConfigReq} from "@/services/proto/accountinfo/interface";
@@ -68,70 +88,105 @@ import {getLongTypeLoginID} from "@/services/bus/login";
 import {getUserId} from "@/services/bus/account";
 import {requestResultLoadingAndInfo} from "@/common/methods/request/resultInfo";
 import {hedgeOutMainReq} from "@/services/proto/accountinfo";
+import { handleAddOrModifyFuturesForm } from '../setup';
+import { handlerManagerList } from '@/common/setup/user';
+import { handleBusinessForm, handleTradeTemplate } from '../add-child-futures/setup';
+import { ErmcpLoginUserEx, ErmcpTaAccount, ErmcpTaAccountEx } from '@/services/go/ermcp/account/interface';
+import { mergeTwoObj } from '@/utils/objHandle';
+import { ErmcpTradeConfigTMP } from '@/services/go/ermcp/business-review/interface';
 
 export default defineComponent({
     name: 'account_info_futures_btn_child_modify',
     components: {},
-    setup(name, context) {
+        props: {
+        selectedData: {
+            default: {},
+            type: Object as PropType<ErmcpTaAccountEx>,
+        },
+        secondeData: {
+            default: {},
+            type: Object as PropType<ErmcpTaAccount>,
+        },
+                userList: {
+            type: Array as PropType<ErmcpLoginUserEx[]>,
+            default: [],
+        },
+        marginList: {
+            type: Array as PropType<ErmcpTradeConfigTMP[]>,
+            default: [],
+        },
+        feeList: {
+            type: Array as PropType<ErmcpTradeConfigTMP[]>,
+            default: [],
+        },
+    },
+    setup(props, context) {
         // 控制关闭弹窗
         const { visible, cancel } = closeModal('account_info_futures_btn_child_modify');
 
         const loading = ref<boolean>(false);
-        // 证件类型
-        // 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';
-        // }
+        const { rules, formState, formRef } = handleBusinessForm();
+        watchEffect(() => {
+            if (visible.value) {
+              // 默认第一个 服务只放回一个,这里是个坑
+              const {userList, secondeData, marginList,
+            feeList} = props
+            if (userList.length) {
+              formState.traderUserId = userList[0].roleid
+            }
+                if(marginList.length) {
+                    formState.trademargintmpid = marginList[0].tradeconfigtmpid
+                  }
+                  if(feeList.length) {
+                    formState.tradefeetmpid = feeList[0].tradeconfigtmpid
+                  }
+                mergeTwoObj(formState, secondeData);
+            }
+            
+        });
+        function getRoleName() {
+          const item = props.userList.find(e => e.roleid === props.secondeData.relateduserid)
+          return item ? item.rolename : '--'
+        }
         // 增加accountid 就是修改
-        // function submit() {
-        //     validateAction<FormState>(formRef, formState).then((res) => {
-        //         let reqParam: HedgeOutMainConfigReq = {
-        //             marketid: 15101, // uint64 内部市场ID(HedgeOutMainConfig)
-        //             limitnumber: 0, // uint64 挂单笔数限额默认0(HedgeOutMainConfig)
-        //             status: 1, // int32 渠道账号状态 1-可买入可卖出 2-可卖出不可买入默认1(HedgeOutMainConfig)
-        //             accountname: res.accountname, // string 账户名称accountname1(Taaccount)
-        //             taaccounttype: 1, // int32 账号类型 - 1:外部账号 2:内部账号 3:内部做市自营账号 4:内部做市接单账号(Taaccount)
-        //             currencyid: 1, // int32 货币ID默认为1(Taaccount)
-        //             outthreshold: 0, // double 出金阈值默认为0(Taaccount)
-        //             ismain: 0, // int32 是否母账号 0:不是母账户 1:是母账户(Taaccount)
-        //             parentaccountid: props.selectedData.mainAcc.accountid, // uint64 所属根账号(Taaccount)
-        //             relateduserid: res.traderUserId, // uint64 关联用户(Taaccount)
-        //             fromaccountid: props.selectedData.mainAcc.accountid, // uint64 所属上级账户(Taaccount)
-        //             trademargintmpid: res.trademargintmpid, // uint64 保证金模板id(TAACCOUNTCONFIG)
-        //             tradefeetmpid: res.tradefeetmpid, // uint64 手续费模板ID(TAACCOUNTCONFIG)
-        //             maxsubaccouts: 0, // uint64 最大子账户数[最大99999][外部母账户用 默认0(TAACCOUNTCONFIG)
-        //             creatorid: Number(getLongTypeLoginID()), // uint64 创建人
-        //             modifierid: Number(getLongTypeLoginID()), // uint64 修改人
-        //             areauserid: getUserId(), // uint64 机构用户ID
-        //         };
-        //
-        //         requestResultLoadingAndInfo(hedgeOutMainReq, reqParam, loading, ['新增期货子账户成功', '新增期货子账户失败:']).then(() => {
-        //             cancel();
-        //             context.emit('refresh');
-        //         });
-        //     });
-        // }
+        function submit() {
+            validateAction<FormState>(formRef, formState).then((res) => {
+                let reqParam: HedgeOutMainConfigReq = {
+                    accountid: props.secondeData.accountid,
+                    marketid: 15101, // uint64 内部市场ID(HedgeOutMainConfig)
+                    limitnumber: 0, // uint64 挂单笔数限额默认0(HedgeOutMainConfig)
+                    status: 1, // int32 渠道账号状态 1-可买入可卖出 2-可卖出不可买入默认1(HedgeOutMainConfig)
+                    accountname: res.accountname, // string 账户名称accountname1(Taaccount)
+                    taaccounttype: 1, // int32 账号类型 - 1:外部账号 2:内部账号 3:内部做市自营账号 4:内部做市接单账号(Taaccount)
+                    currencyid: 1, // int32 货币ID默认为1(Taaccount)
+                    outthreshold: 0, // double 出金阈值默认为0(Taaccount)
+                    ismain: 0, // int32 是否母账号 0:不是母账户 1:是母账户(Taaccount)
+                    parentaccountid: props.selectedData.mainAcc.accountid, // uint64 所属根账号(Taaccount)
+                    relateduserid: res.traderUserId, // uint64 关联用户(Taaccount)
+                    fromaccountid: props.selectedData.mainAcc.accountid, // uint64 所属上级账户(Taaccount)
+                    trademargintmpid: res.trademargintmpid, // uint64 保证金模板id(TAACCOUNTCONFIG)
+                    tradefeetmpid: res.tradefeetmpid, // uint64 手续费模板ID(TAACCOUNTCONFIG)
+                    maxsubaccouts: 0, // uint64 最大子账户数[最大99999][外部母账户用 默认0(TAACCOUNTCONFIG)
+                    creatorid: Number(getLongTypeLoginID()), // uint64 创建人
+                    modifierid: Number(getLongTypeLoginID()), // uint64 修改人
+                    areauserid: getUserId(), // uint64 机构用户ID
+                };
+        
+                requestResultLoadingAndInfo(hedgeOutMainReq, reqParam, loading, ['修改期货子账户成功', '修改期货子账户失败:']).then(() => {
+                    cancel();
+                    context.emit('refresh');
+                });
+            });
+        }
         return {
-            // formState,
-            // rules,
-            // formRef,
-            // cardTypeList,
-            // isPersonal,
+            formState,
+            rules,
+            formRef,
             visible,
             cancel,
-            // submit,
-            // loading,
+            submit,
+            getRoleName,
+            loading,
         };
     },
 });

+ 36 - 9
src/views/information/account_info/list/account_info_futures/index.vue

@@ -59,17 +59,33 @@
     </a-collapse>
     <Add @refresh="queryTable" />
     <AddChild :selectedData="firstData"
+              :userList="userList"
+              :marginList="marginList"
+              :feeList="feeList"
+              @updateTrader="queryUserList"
               @refresh="queryTable" />
     <Modify :selectedData="firstData"
             @refresh="queryTable" />
     <ModifyChild @refresh="queryTable"
+                 :userList="userList"
+                 :marginList="marginList"
+                 :feeList="feeList"
+                 :secondeData="secondeData"
                  :selectedData="firstData" />
     <Detail :selectedData="firstData"
-            :secondeData="secondeData" />
+            :secondeData="secondeData"
+            :userList="userList"
+            :marginList="marginList"
+            :feeList="feeList" />
     <Cancel @refresh="queryTable"
+            :userList="userList"
+            :marginList="marginList"
+            :feeList="feeList"
+            :secondeData="secondeData"
             :selectedData="firstData" />
     <Credit @refresh="queryTable"
-            :selectedData="firstData" />
+            :selectedData="firstData"
+            :secondeData="secondeData" />
   </div>
 </template>
 
@@ -77,7 +93,7 @@
 import { defineComponent, initData, _getBtnList, contextMenu, BtnList } from '@/common/export/table';
 import filterCustomTable from '@/views/information/goods/components/filterTable/index.vue';
 import { getAccountStatus, handleModalData } from '../setup';
-import { queryTableList } from './setup';
+import { handleTradeTemplate, queryTableList } from './setup';
 import { getUserName } from '@/services/bus/user';
 import Add from '../../compoments/add-futures/index.vue';
 import AddChild from '../../compoments/add-child-futures/index.vue';
@@ -88,6 +104,7 @@ import Cancel from '../../compoments/cancel-futures/index.vue';
 import Credit from '../../compoments/credit-futures/index.vue';
 import { ErmcpTaAccountEx } from '@/services/go/ermcp/account/interface';
 import { ref } from 'vue';
+import { handlerManagerList } from '@/common/setup/user';
 
 export default defineComponent({
     name: 'account_info_futures',
@@ -110,8 +127,14 @@ export default defineComponent({
         const { selectedData: addModelData, openAction } = handleModalData<ErmcpTaAccountEx>();
         // 修改 重置密码、详情等弹窗
         const { selectedData: moreModelData, openAction: moreOptenAction } = handleModalData<ErmcpTaAccountEx>();
+                // 交易用户
+        const { tableList: userList, queryTable: queryUserList } = handlerManagerList(loading, 2);
+        // 交易模板
+        const { marginList, feeList, queryTemplate } = handleTradeTemplate();
         initData(() => {
             queryTable();
+            queryUserList();
+            queryTemplate()
         });
         const firstData = ref<ErmcpTaAccountEx | null>(null)
         const secondeData = ref<ErmcpTaAccountEx | null>(null)
@@ -153,6 +176,10 @@ export default defineComponent({
             firstBtn,
             secondBtn,
             thirdBtn,
+            userList,
+            marginList,
+            feeList,
+            queryUserList,
         };
     },
 });
@@ -177,12 +204,12 @@ export default defineComponent({
         }
     }
     .ant-collapse.busyCollapse {
-      .operBtn.ant-btn {
-        margin-top: 0;
-        margin-bottom: 0;
-        height: 26px;
-        line-height: 26px;
-      }
+        .operBtn.ant-btn {
+            margin-top: 0;
+            margin-bottom: 0;
+            height: 26px;
+            line-height: 26px;
+        }
     }
     .ant-row.headRow {
         .ant-col:nth-child(2) {

+ 27 - 0
src/views/information/account_info/list/account_info_futures/setup.ts

@@ -1,6 +1,8 @@
 import { queryResultLoadingAndInfo } from "@/common/methods/request/resultInfo";
 import { QueryAccMgrTaaccount } from "@/services/go/ermcp/account";
 import { ErmcpTaAccountEx } from "@/services/go/ermcp/account/interface";
+import { QueryTradeConfigTMP } from "@/services/go/ermcp/business-review";
+import { ErmcpTradeConfigTMP } from "@/services/go/ermcp/business-review/interface";
 import { ref } from "vue";
 
 export function queryTableList() {
@@ -13,4 +15,29 @@ export function queryTableList() {
             .then(res => tableList.value = res)
     }
     return { loading, tableList, queryTable }
+}
+
+/**
+ * 处理交易模板
+ */
+export function handleTradeTemplate() {
+    // 保证金
+    const marginList = ref<ErmcpTradeConfigTMP[]>([])
+    // 手续费
+    const feeList = ref<ErmcpTradeConfigTMP[]>([])
+    function queryTemplate() {
+        return QueryTradeConfigTMP().then(res => {
+            marginList.value.length = 0
+            feeList.value.length = 0
+            res.forEach(el => {
+                const { tradeconfigtmptype } = el
+                if (tradeconfigtmptype === 1) { // 保证金
+                    marginList.value.push(el)
+                } else if (tradeconfigtmptype === 2) { // 手续费
+                    feeList.value.push(el)
+                }
+            })
+        })
+    }
+    return { marginList, feeList, queryTemplate }
 }

+ 2 - 2
src/views/information/custom/compoments/modify/index.vue

@@ -330,11 +330,11 @@ export default defineComponent({
         function submit(OperateType: 1 | 2) {
             validateAction<FormState>(formRef, formState).then((param) => {
                 const reqParam: ModifyUserInfoApplyReq = {
-                    customername: param.customername, // 必填
+                    customername: Number(param.userinfotype) === 1 ? param.username : param.customername, // 必填
+                    username: param.username,
                     userid: userid.value,
                     memberareaid: getUserId(),
                     userinfotype: Number(param.userinfotype),
-                    username: param.customername,
                     userstate: OperateType, // 1: 保存草稿 2: 新增
                     cardtype: param.cardtype, // 证件类型
                     cardnum: param.cardnum, // 证件号码

+ 13 - 10
src/views/information/spot-contract/components/detail/index.vue

@@ -93,16 +93,19 @@
         setup: function (props, context) {
             const {visible, cancel} = closeModal('detail');
 
-            const tabList = [
-                {key: 1, name: '合同详情'},
-                {key: 2, name: '点价记录'},
-                {key: 3, name: '交收记录'},
-                {key: 4, name: '款项记录'},
-                {key: 5, name: '发票记录'},
-                {key: 6, name: '入库记录'},
-                {key: 7, name: '出库记录'},
-                {key: 8, name: '变更记录'},
-            ];
+            let tabList = ref<any[]> (props.selectedRow.contracctstatus === 4 || 0 ?  // 审核拒绝和未提交不显示后面的选项
+                [{key: 1, name: '合同详情'},]
+                : [
+                    {key: 1, name: '合同详情'},
+                    {key: 2, name: '点价记录'},
+                    {key: 3, name: '交收记录'},
+                    {key: 4, name: '款项记录'},
+                    {key: 5, name: '发票记录'},
+                    {key: 6, name: '入库记录'},
+                    {key: 7, name: '出库记录'},
+                    {key: 8, name: '变更记录'},
+                ]);
+
             const activeKey = ref<number>(1);
 
             const loading = ref<boolean>(false);

+ 3 - 1
src/views/manage/business-review/components/settlementDetail/index.vue

@@ -59,7 +59,8 @@
           <a-col :span="12">
             <a-form-item label="调整保证金">
               <span class="white">{{
-                                  formatValue(selectedRow.addmargin !== 0 ? "+" + formatValue(selectedRow.addmargin) : (selectedRow.decmargin === 0 ? 0.0 : "-" + formatValue(selectedRow.decmargin)))
+                                  formatValue(selectedRow.addmargin !== 0 && selectedRow.addmargin !== undefined ?
+                  "+" + formatValue(selectedRow.addmargin) : (selectedRow.decmargin === 0 ? 0.0 : "-" + formatValue(selectedRow.decmargin)))
                               }}</span>
             </a-form-item>
           </a-col>
@@ -114,6 +115,7 @@ export default defineComponent({
             }
         });
         function submit() {
+            console.log(props.selectedRow.addmargin)
             context.emit('refresh');
             cancel();
         }

+ 136 - 119
src/views/manage/business-review/list/settlement/index.vue

@@ -1,140 +1,157 @@
 <template>
-  <!-- 管理-业务审核-交收 -->
-  <div class="business-review-js"
-       :loading="loading">
-    <Filter @search="search">
-      <BtnList :btnList="commonBtn" />
-    </Filter>
-    <contextMenu :contextMenuList="forDataBtn">
-      <a-table :columns="columns"
-               class="topTable hiddenFirstCol"
-               :pagination="false"
-               :expandedRowKeys="expandedRowKeys"
-               :customRow="Rowclick"
-               rowKey="key"
-               :data-source="tableList">
-        <!-- 额外的展开行 -->
-        <template #expandedRowRender="{ record }">
-          <BtnList :btnList="record.btnList" />
-        </template>
+    <!-- 管理-业务审核-交收 -->
+    <div class="business-review-js"
+         :loading="loading">
+        <Filter @search="search">
+            <BtnList :btnList="commonBtn"/>
+        </Filter>
+        <contextMenu :contextMenuList="forDataBtn">
+            <a-table :columns="columns"
+                     class="topTable hiddenFirstCol"
+                     :pagination="false"
+                     :expandedRowKeys="expandedRowKeys"
+                     :customRow="Rowclick"
+                     rowKey="key"
+                     :data-source="tableList">
+                <!-- 额外的展开行 -->
+                <template #expandedRowRender="{ record }">
+                    <BtnList :btnList="record.btnList"/>
+                </template>
 
-        <template #contracttype="{ text }">
-          <a>{{ getContractTypeName(text) }}</a>
-        </template>
+                <template #contracttype="{ text }">
+                    <a>{{ getContractTypeName(text) }}</a>
+                </template>
 
-        <template #applystatus="{ text }">
-          <a>{{ getApplyStatusName(text) }}</a>
-        </template>
+                <template #applystatus="{ text }">
+                    <a>{{ getApplyStatusName(text) }}</a>
+                </template>
 
-      </a-table>
-    </contextMenu>
-    <!-- 点价记录详情 -->
-    <SettlementDetail :selectedRow="selectedRow"
-                      @refresh="getTableData" />
-    <!-- 交收审核 -->
-    <SettlementAudit :selectedRow="selectedRow"
-                     @refresh="getTableData" />
-    <!-- 撤销点价登记 -->
-    <SettlementCancel :selectedRow="selectedRow"
-                      @refresh="getTableData" />
-  </div>
+                <template #addmargin||decmargin="{ record }">
+                    <a>{{
+                        (record.addmargin !== 0 && record.addmargin !== undefined ?
+                        "+" + (record.addmargin) : (record.decmargin === 0 || record.decmargin === undefined ? "" : "-" + (record.decmargin)))
+                        }} </a>
+                </template>
+
+            </a-table>
+        </contextMenu>
+        <!-- 点价记录详情 -->
+        <SettlementDetail :selectedRow="selectedRow"
+                          @refresh="getTableData"/>
+        <!-- 交收审核 -->
+        <SettlementAudit :selectedRow="selectedRow"
+                         @refresh="getTableData"/>
+        <!-- 撤销点价登记 -->
+        <SettlementCancel :selectedRow="selectedRow"
+                          @refresh="getTableData"/>
+    </div>
 </template>
 
 <script lang="ts">
-import { defineComponent, initData, getTableColumns, getTableEvent, getBtnList, contextMenu, BtnList } from '@/common/export/table';
+    import {
+        defineComponent,
+        initData,
+        getTableColumns,
+        getTableEvent,
+        getBtnList,
+        contextMenu,
+        BtnList
+    } from '@/common/export/table';
 
-import { SettlementDetail, SettlementAudit, SettlementCancel, Filter } from '../../components';
+    import {SettlementDetail, SettlementAudit, SettlementCancel, Filter} from '../../components';
 
-import { queryTableList, QryBussinessJsRsp } from './setup';
-import { getContractTypeName, getPriceTypeName } from '@/views/information/spot-contract/setup';
-import { getApplyStatusName } from '@/views/manage/business-review/setup';
-import { invoiceStatusName } from '@/views/manage/finance-review/setup';
-import { Column, ColumnType } from '@/common/setup/table';
+    import {queryTableList, QryBussinessJsRsp} from './setup';
+    import {getContractTypeName, getPriceTypeName} from '@/views/information/spot-contract/setup';
+    import {getApplyStatusName} from '@/views/manage/business-review/setup';
+    import {invoiceStatusName} from '@/views/manage/finance-review/setup';
+    import {Column, ColumnType} from '@/common/setup/table';
 
-export default defineComponent({
-    name: 'business-review-js',
-    components: {
-        contextMenu,
-        Filter,
-        BtnList,
-        SettlementDetail,
-        SettlementAudit,
-        SettlementCancel,
-    },
-    setup() {
-        // 表头数据
-        const { columns, registerColumn, updateColumn, filteredInfo } = getTableColumns();
-        // 表格事件
-        const { expandedRowKeys, selectedRow, Rowclick } = getTableEvent<QryBussinessJsRsp>({});
-        // 表格操作按钮列表
-        const { commonBtn, forDataBtn } = getBtnList('business_review_settlement', true);
-        // 表格列表数据
-        const { loading, tableList, queryTable } = queryTableList({});
-        function getTableData() {
-            // 获取列表数据
-            queryTable().then(() => {
-                tableList.value.forEach((el) => {
-                    if (el.applystatus === 1) {
-                        // 1:待审核
-                        Object.assign(el, { btnList: forDataBtn.value });
-                    } else {
-                        const item = forDataBtn.value.find((e) => e.lable === '详情');
-                        item && Object.assign(el, { btnList: [item] });
-                    }
-                });
-            });
-        }
-        initData(() => {
-            // 获取列表数据
-            getTableData();
-            // 注册表头信息 过滤
-            registerColumn('table_pcweb_business_aduit_js', ['contracttype', 'contractno', 'deliverygoodsname'], (e: Column, item: ColumnType, filtered: any) => {
-                if (e.columnfield === 'buyusernameOrsellusername') {
-                    item.onFilter = (value: string, record: QryBussinessJsRsp) => {
-                        const { contracttype, buyusername, sellusername } = record;
-                        if (contracttype === 1) {
-                            // 采购
-                            return sellusername.includes(value);
+    export default defineComponent({
+        name: 'business-review-js',
+        components: {
+            contextMenu,
+            Filter,
+            BtnList,
+            SettlementDetail,
+            SettlementAudit,
+            SettlementCancel,
+        },
+        setup() {
+            // 表头数据
+            const {columns, registerColumn, updateColumn, filteredInfo} = getTableColumns();
+            // 表格事件
+            const {expandedRowKeys, selectedRow, Rowclick} = getTableEvent<QryBussinessJsRsp>({});
+            // 表格操作按钮列表
+            const {commonBtn, forDataBtn} = getBtnList('business_review_settlement', true);
+            // 表格列表数据
+            const {loading, tableList, queryTable} = queryTableList({});
+
+            function getTableData() {
+                // 获取列表数据
+                queryTable().then(() => {
+                    tableList.value.forEach((el) => {
+                        if (el.applystatus === 1) {
+                            // 1:待审核
+                            Object.assign(el, {btnList: forDataBtn.value});
                         } else {
-                            return buyusername.includes(value);
+                            const item = forDataBtn.value.find((e) => e.lable === '详情');
+                            item && Object.assign(el, {btnList: [item]});
                         }
-                    };
-                    item.filteredValue = filtered.buyusernameOrsellusername || null;
-                }
+                    });
+                });
+            }
+
+            initData(() => {
+                // 获取列表数据
+                getTableData();
+                // 注册表头信息 过滤
+                registerColumn('table_pcweb_business_aduit_js', ['contracttype', 'contractno', 'deliverygoodsname'], (e: Column, item: ColumnType, filtered: any) => {
+                    if (e.columnfield === 'buyusernameOrsellusername') {
+                        item.onFilter = (value: string, record: QryBussinessJsRsp) => {
+                            const {contracttype, buyusername, sellusername} = record;
+                            if (contracttype === 1) {
+                                // 采购
+                                return sellusername.includes(value);
+                            } else {
+                                return buyusername.includes(value);
+                            }
+                        };
+                        item.filteredValue = filtered.buyusernameOrsellusername || null;
+                    }
+                });
             });
-        });
 
-        // 查询
-        function search(value: any) {
-            filteredInfo.value = value;
-            // 更新表信息
-            updateColumn();
-        }
+            // 查询
+            function search(value: any) {
+                filteredInfo.value = value;
+                // 更新表信息
+                updateColumn();
+            }
 
-        return {
-            columns,
-            filteredInfo,
-            expandedRowKeys,
-            selectedRow,
-            Rowclick,
-            commonBtn,
-            forDataBtn,
-            loading,
-            tableList,
-            search,
-            getPriceTypeName,
-            getContractTypeName,
-            getApplyStatusName,
-            invoiceStatusName,
-            getTableData,
-        };
-    },
-});
+            return {
+                columns,
+                filteredInfo,
+                expandedRowKeys,
+                selectedRow,
+                Rowclick,
+                commonBtn,
+                forDataBtn,
+                loading,
+                tableList,
+                search,
+                getPriceTypeName,
+                getContractTypeName,
+                getApplyStatusName,
+                invoiceStatusName,
+                getTableData,
+            };
+        },
+    });
 </script>
 
 <style lang="less">
-.business-review-js {
-}
+    .business-review-js {
+    }
 </style
 >;
 

+ 1 - 1
src/views/manage/finance-review/components/fundsDetail/index.vue

@@ -51,7 +51,7 @@
           </a-col>
           <a-col :span="12">
             <a-form-item label="登记金额">
-              <span class="white">{{ formatValue(selectedRow.payamount) }}</span>
+              <span class="white">{{(selectedRow.deductamount === undefined || selectedRow.deductamount === 0) ? formatValue(selectedRow.payamount): formatValue(selectedRow.deductamount)}}</span>
             </a-form-item>
           </a-col>
         </a-row>

+ 1 - 1
src/views/manage/finance-review/components/invoiceCancel/index.vue

@@ -11,7 +11,7 @@
       <a-button key="submit"
                 type="primary"
                 :loading="loading"
-                @click="submit">关闭
+                @click="cancel">关闭
       </a-button>
 
       <a-button key="submit"

+ 1 - 1
src/views/manage/finance-review/components/invoiceDetail/index.vue

@@ -109,7 +109,7 @@ export default defineComponent({
         const loading = ref<boolean>(false);
         const maskClosableFlag = ref<boolean>(false);
 
-        function submit() {
+        function submit(){
             context.emit('refresh');
             cancel();
         }

+ 153 - 139
src/views/manage/finance-review/list/funds/index.vue

@@ -1,158 +1,172 @@
 <template>
-  <!-- 管理 - 财务审核 - 款项 -->
-  <div class="business-review-js"
-       :loading="loading">
-    <Filter @search="search">
-      <BtnList :btnList="commonBtn" />
-    </Filter>
-    <contextMenu :contextMenuList="forDataBtn">
-      <a-table :columns="columns"
-               class="topTable hiddenFirstCol"
-               :pagination="false"
-               :expandedRowKeys="expandedRowKeys"
-               :customRow="Rowclick"
-               rowKey="key"
-               :data-source="tableList">
-        <!-- 额外的展开行 -->
-        <template #expandedRowRender="{ record }">
-          <BtnList :btnList="record.btnList" />
-        </template>
-        <!-- 现货合同类型 -->
-        <template #contractstatus="{ record }">
-          <a>{{ getApplyStatusName(record.applystatus) }}</a>
-        </template>
-        <!-- 合同类型-->
-        <template #contracttype="{ record }">
-          <a>{{ getContractTypeName(record.contracttype) }}</a>
-        </template>
-        <!-- 状态 -->
-        <template #applystatus="{ text }">
-          <a>{{ getApplyStatusName(text) }}</a>
-        </template>
-        <!-- 点价类型 -->
-        <template #operateapplytype="{ text }">
-          <a>{{ operateApplyTypeName(text) }}</a>
-        </template>
-        <!-- 款项类型 -->
-        <template #kxtype="{ record }">
-          <a>{{ stateName(record.deductamount, record.contracttype) }}</a>
-        </template>
-        <!-- 对手方 -->
-        <template #buyusernameOrsellusername="{ record }">
-          <a>{{ record.contracttype === 1 ? record.sellusername : record.buyusername }}</a>
-        </template>
+    <!-- 管理 - 财务审核 - 款项 -->
+    <div class="business-review-js"
+         :loading="loading">
+        <Filter @search="search">
+            <BtnList :btnList="commonBtn"/>
+        </Filter>
+        <contextMenu :contextMenuList="forDataBtn">
+            <a-table :columns="columns"
+                     class="topTable hiddenFirstCol"
+                     :pagination="false"
+                     :expandedRowKeys="expandedRowKeys"
+                     :customRow="Rowclick"
+                     rowKey="key"
+                     :data-source="tableList">
+                <!-- 额外的展开行 -->
+                <template #expandedRowRender="{ record }">
+                    <BtnList :btnList="record.btnList"/>
+                </template>
+                <!-- 现货合同类型 -->
+                <template #contractstatus="{ record }">
+                    <a>{{ getApplyStatusName(record.applystatus) }}</a>
+                </template>
+                <!-- 合同类型-->
+                <template #contracttype="{ record }">
+                    <a>{{ getContractTypeName(record.contracttype) }}</a>
+                </template>
+                <!-- 状态 -->
+                <template #applystatus="{ text }">
+                    <a>{{ getApplyStatusName(text) }}</a>
+                </template>
+                <!-- 点价类型 -->
+                <template #operateapplytype="{ text }">
+                    <a>{{ operateApplyTypeName(text) }}</a>
+                </template>
+                <!-- 款项类型 -->
+                <template #kxtype="{ record }">
+                    <a>{{ stateName(record.deductamount, record.contracttype) }}</a>
+                </template>
+                <!-- 对手方 -->
+                <template #buyusernameOrsellusername="{ record }">
+                    <a>{{ record.contracttype === 1 ? record.sellusername : record.buyusername }}</a>
+                </template>
+                <!-- 金额 如果是退款 则使用deductamount  如果是付款则使用payamount-->
+                <template #payamount="{ record }">
+                    <a>{{ (record.deductamount === undefined || record.deductamount === 0) ? record.payamount: record.deductamount }}</a>
+                </template>
 
-      </a-table>
-    </contextMenu>
-    <!-- 点价记录详情 -->
-    <FundsDetail :selectedRow="selectedRow"
-                 @refresh="getTableData" />
-    <!-- 交收审核 -->
-    <FundsAudit :selectedRow="selectedRow"
-                @refresh="getTableData" />
-    <!-- 撤销点价登记 -->
-    <FundsCancel :selectedRow="selectedRow"
-                 @refresh="getTableData" />
-  </div>
+            </a-table>
+        </contextMenu>
+        <!-- 点价记录详情 -->
+        <FundsDetail :selectedRow="selectedRow"
+                     @refresh="getTableData"/>
+        <!-- 交收审核 -->
+        <FundsAudit :selectedRow="selectedRow"
+                    @refresh="getTableData"/>
+        <!-- 撤销点价登记 -->
+        <FundsCancel :selectedRow="selectedRow"
+                     @refresh="getTableData"/>
+    </div>
 </template>
 
 <script lang="ts">
-import { defineComponent, initData, getTableColumns, getTableEvent, getBtnList, contextMenu, BtnList } from '@/common/export/table';
+    import {
+        defineComponent,
+        initData,
+        getTableColumns,
+        getTableEvent,
+        getBtnList,
+        contextMenu,
+        BtnList
+    } from '@/common/export/table';
 
-import { Filter, FundsAudit, FundsCancel, FundsDetail } from '../../components';
+    import {Filter, FundsAudit, FundsCancel, FundsDetail} from '../../components';
 
-import { queryTableList, QryBussinessKxRsp } from './setup';
-import { invoiceStatusName, kxtypeName, operateApplyTypeName, stateName } from '@/views/manage/finance-review/setup';
-import { getApplyStatusName } from '@/views/manage/business-review/setup';
-import { getContractTypeName } from '@/views/information/spot-contract/setup';
-import { Column, ColumnType } from '@/common/setup/table';
+    import {queryTableList, QryBussinessKxRsp} from './setup';
+    import {invoiceStatusName, kxtypeName, operateApplyTypeName, stateName} from '@/views/manage/finance-review/setup';
+    import {getApplyStatusName} from '@/views/manage/business-review/setup';
+    import {getContractTypeName} from '@/views/information/spot-contract/setup';
+    import {Column, ColumnType} from '@/common/setup/table';
 
-export default defineComponent({
-    name: 'business-review-js',
-    components: {
-        contextMenu,
-        Filter,
-        BtnList,
-        FundsDetail,
-        FundsAudit,
-        FundsCancel,
-    },
-    setup() {
-        // 表头数据
-        const { columns, registerColumn, updateColumn, filteredInfo } = getTableColumns();
-        // 表格事件
-        const { expandedRowKeys, selectedRow, Rowclick } = getTableEvent<QryBussinessKxRsp>({});
-        // 表格操作按钮列表
-        const { commonBtn, forDataBtn } = getBtnList('finance_review_funds', true);
-        // 表格列表数据
-        const { loading, tableList, queryTable } = queryTableList({});
-        function getTableData() {
-            // 获取列表数据
-            queryTable().then(() => {
-                tableList.value.forEach((el) => {
-                    if (el.applystatus === 1) {
-                        // 1:待审核
-                        Object.assign(el, { btnList: forDataBtn.value });
-                    } else {
-                        const item = forDataBtn.value.find((e) => e.lable === '详情');
-                        item && Object.assign(el, { btnList: [item] });
-                    }
-                });
-            });
-        }
-        initData(() => {
-            // 获取列表数据
-            getTableData();
-            // 注册表头信息 过滤
-            registerColumn('table_pcweb_fincial_aduit_kx', ['contracttype', 'contractno', 'deliverygoodsname'], (e: Column, item: ColumnType, filtered: any) => {
-                if (e.columnfield === 'buyusernameOrsellusername') {
-                    item.onFilter = (value: string, record: QryBussinessKxRsp) => {
-                        const { contracttype, buyusername, sellusername } = record;
-                        if (contracttype === 1) {
-                            // 采购
-                            return sellusername.includes(value);
+    export default defineComponent({
+        name: 'business-review-js',
+        components: {
+            contextMenu,
+            Filter,
+            BtnList,
+            FundsDetail,
+            FundsAudit,
+            FundsCancel,
+        },
+        setup() {
+            // 表头数据
+            const {columns, registerColumn, updateColumn, filteredInfo} = getTableColumns();
+            // 表格事件
+            const {expandedRowKeys, selectedRow, Rowclick} = getTableEvent<QryBussinessKxRsp>({});
+            // 表格操作按钮列表
+            const {commonBtn, forDataBtn} = getBtnList('finance_review_funds', true);
+            // 表格列表数据
+            const {loading, tableList, queryTable} = queryTableList({});
+
+            function getTableData() {
+                // 获取列表数据
+                queryTable().then(() => {
+                    tableList.value.forEach((el) => {
+                        if (el.applystatus === 1) {
+                            // 1:待审核
+                            Object.assign(el, {btnList: forDataBtn.value});
                         } else {
-                            return buyusername.includes(value);
+                            const item = forDataBtn.value.find((e) => e.lable === '详情');
+                            item && Object.assign(el, {btnList: [item]});
                         }
-                    };
-                    item.filteredValue = filtered.buyusernameOrsellusername || null;
-                }
+                    });
+                });
+            }
+
+            initData(() => {
+                // 获取列表数据
+                getTableData();
+                // 注册表头信息 过滤
+                registerColumn('table_pcweb_fincial_aduit_kx', ['contracttype', 'contractno', 'deliverygoodsname'], (e: Column, item: ColumnType, filtered: any) => {
+                    if (e.columnfield === 'buyusernameOrsellusername') {
+                        item.onFilter = (value: string, record: QryBussinessKxRsp) => {
+                            const {contracttype, buyusername, sellusername} = record;
+                            if (contracttype === 1) {
+                                // 采购
+                                return sellusername.includes(value);
+                            } else {
+                                return buyusername.includes(value);
+                            }
+                        };
+                        item.filteredValue = filtered.buyusernameOrsellusername || null;
+                    }
+                });
             });
-        });
 
-        // 查询
-        function search(value: any) {
-            filteredInfo.value = value;
-            // 更新表信息
-            updateColumn();
-        }
+            // 查询
+            function search(value: any) {
+                filteredInfo.value = value;
+                // 更新表信息
+                updateColumn();
+            }
 
-        return {
-            columns,
-            filteredInfo,
-            expandedRowKeys,
-            selectedRow,
-            Rowclick,
-            commonBtn,
-            forDataBtn,
-            loading,
-            tableList,
-            search,
-            invoiceStatusName,
-            getApplyStatusName,
-            operateApplyTypeName,
-            getContractTypeName,
-            kxtypeName,
-            stateName,
-            getTableData,
-        };
-    },
-});
+            return {
+                columns,
+                filteredInfo,
+                expandedRowKeys,
+                selectedRow,
+                Rowclick,
+                commonBtn,
+                forDataBtn,
+                loading,
+                tableList,
+                search,
+                invoiceStatusName,
+                getApplyStatusName,
+                operateApplyTypeName,
+                getContractTypeName,
+                kxtypeName,
+                stateName,
+                getTableData,
+            };
+        },
+    });
 </script>
 
 <style lang="less">
-.business-review-js {
-}
+    .business-review-js {
+    }
 </style
 >;
 

+ 1 - 1
src/views/manage/inventory-review/components/checkoutCancel/index.vue

@@ -11,7 +11,7 @@
       <a-button key="submit"
                 type="primary"
                 :loading="loading"
-                @click="submit">关闭
+                @click="cancel">关闭
       </a-button>
 
       <a-button key="submit"

+ 1 - 1
src/views/search/inventory/components/add/index.vue

@@ -37,7 +37,7 @@ export default defineComponent({
         },
     },
     setup(props, context) {
-        const { visible, cancel } = closeModal('spot_contract_btn_add');
+        const { visible, cancel } = closeModal('inventory_current_add');
 
         const loading = ref<boolean>(false);
         function submit(OperateType: 1 | 2) {

+ 8 - 7
src/views/search/inventory/list/inventory_applyrecord/index.vue

@@ -3,9 +3,9 @@
   <div class="inventory_current"
        :loading="loading">
     <Filter @search="search">
-      <BtnList :btnList="commonBtn" />
+      <BtnList :btnList="firstBtn" />
     </Filter>
-    <contextMenu :contextMenuList="forDataBtn">
+    <contextMenu :contextMenuList="secondBtn">
       <a-table :columns="columns"
                class="topTable hiddenFirstCol"
                :pagination="false"
@@ -15,7 +15,7 @@
                :data-source="tableList">
         <!-- 额外的展开行 -->
         <template #expandedRowRender="{  }">
-          <BtnList :btnList="forDataBtn" />
+          <BtnList :btnList="secondBtn" />
         </template>
         <!-- <template #userinfotype="{ text }">
                   <a>{{ text === '2' ? '企业' : '个人'}}</a>
@@ -46,7 +46,7 @@
 </template>
 
 <script lang="ts">
-import { defineComponent, initData, getTableColumns, getTableEvent, getBtnList, contextMenu, BtnList } from '@/common/export/table';
+import { defineComponent, initData, getTableColumns, getTableEvent, getBtnList, contextMenu, BtnList, _getBtnList } from '@/common/export/table';
 import Filter from '../../components/filterTable/index.vue';
 import Add from '../../components/add/index.vue';
 
@@ -67,7 +67,8 @@ export default defineComponent({
         // 表格事件
         const { expandedRowKeys, selectedRow, Rowclick } = getTableEvent<Ermcp3AreaStockApply>({});
         // 表格操作按钮列表
-        const { commonBtn, forDataBtn } = getBtnList('inventory_applyrecord', false);
+        const [firstBtn, secondBtn] = _getBtnList('inventory_applyrecord', false).value;
+        
         // 表格列表数据
         const { loading, tableList, queryTable } = queryTableList();
 
@@ -90,8 +91,8 @@ export default defineComponent({
             expandedRowKeys,
             selectedRow,
             Rowclick,
-            commonBtn,
-            forDataBtn,
+            firstBtn,
+            secondBtn,
             loading,
             tableList,
             search,

+ 7 - 7
src/views/search/inventory/list/inventory_current/index.vue

@@ -3,9 +3,9 @@
   <div class="inventory_current"
        :loading="loading">
     <Filter @search="search">
-      <BtnList :btnList="commonBtn" />
+      <BtnList :btnList="firstBtn" />
     </Filter>
-    <contextMenu :contextMenuList="forDataBtn">
+    <contextMenu :contextMenuList="secondBtn">
       <a-table :columns="columns"
                class="topTable hiddenFirstCol"
                :pagination="false"
@@ -15,7 +15,7 @@
                :data-source="tableList">
         <!-- 额外的展开行 -->
         <template #expandedRowRender="{  }">
-          <BtnList :btnList="forDataBtn" />
+          <BtnList :btnList="secondBtn" />
         </template>
       </a-table>
     </contextMenu>
@@ -25,7 +25,7 @@
 </template>
 
 <script lang="ts">
-import { defineComponent, initData, getTableColumns, getTableEvent, getBtnList, contextMenu, BtnList } from '@/common/export/table';
+import { defineComponent, initData, getTableColumns, getTableEvent, getBtnList, contextMenu, BtnList, _getBtnList } from '@/common/export/table';
 import Filter from '../../components/filterTable/index.vue';
 import Add from '../../components/add/index.vue';
 
@@ -46,7 +46,7 @@ export default defineComponent({
         // 表格事件
         const { expandedRowKeys, selectedRow, Rowclick } = getTableEvent<Ermcp3AreaStock>({});
         // 表格操作按钮列表
-        const { commonBtn, forDataBtn } = getBtnList('inventory_current', false);
+        const [firstBtn, secondBtn] = _getBtnList('inventory_current', false).value;
         // 表格列表数据
         const { loading, tableList, queryTable } = queryTableList();
 
@@ -69,8 +69,8 @@ export default defineComponent({
             expandedRowKeys,
             selectedRow,
             Rowclick,
-            commonBtn,
-            forDataBtn,
+            firstBtn,
+            secondBtn,
             loading,
             tableList,
             search,