Forráskód Böngészése

Merge remote-tracking branch 'origin/master'

yu.jie 4 éve
szülő
commit
1563eee108

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

@@ -105,8 +105,8 @@ export default defineComponent({
         const { rolename, getRoleName } = handleRoleName();
         watchEffect(() => {
             if (visible.value) {
-                // const { selectedData, tableList } = props;
-                // mergeTwoObj(formState, selectedData);
+                const { selectedData, tableList } = props;
+                mergeTwoObj(formState, selectedData);
                 // getRoleName(tableList, selectedData);
                 // formState.logintaaccounts = selectedData.acclist.map((e) => e.accountid);
                 // formState.accountname = props.selectedData.loginname;

+ 3 - 1
src/views/information/account_info/list/account_info_futures/index.vue

@@ -52,7 +52,9 @@
                 <a-col :span="12">{{getAccountStatus(sub.tradestatus)}}</a-col>
               </a-row>
             </template>
-            <BtnList :btnList="thirdBtn" />
+            <BtnList :selectedData="sub"
+                     :btnList="thirdBtn"
+                     @onClick="moreOptenAction" />
           </a-collapse-panel>
         </a-collapse>
       </a-collapse-panel>

+ 8 - 5
src/views/information/goods/components/add/index.vue

@@ -4,7 +4,7 @@
            wrapClassName=""
            title="新增现货品种"
            v-model:visible="visible"
-           @cancel="cancel"
+           @cancel="closeAction"
            centered
            :maskClosable="maskClosableFlag"
            width="850px">
@@ -349,9 +349,7 @@ export default defineComponent({
                     }),
                 };
                 requestResultLoadingAndInfo(addDeliveryGoodsApply, reqParam, loading, ['新增现货品种成功', '新增现货品种失败:']).then(() => {
-                    // 清空数据
-                    Object.assign(formState, initFormData());
-                    cancel();
+                    closeAction();
                     context.emit('refresh');
                 });
             });
@@ -388,12 +386,17 @@ export default defineComponent({
                 value.unitid = obj.agreeunit;
             }
         }
+        function closeAction() {
+            //清空添加成功后的数据,确保在此新增打开是个空数据
+            Object.assign(formState, initFormData());
+            cancel();
+        }
         initData(() => {
             getGoodsGroup();
         });
         return {
             visible,
-            cancel,
+            closeAction,
             formRef,
             formState,
             addOne,

+ 4 - 4
src/views/information/goods/components/modify/index.vue

@@ -343,7 +343,7 @@ export default defineComponent({
             gldwrstandards: {
                 unitid: { required: true, validator: validateUnit, trigger: 'change' },
                 wrstandardname: { required: true, message: '请输入品类', trigger: 'blur' },
-                convertfactor: { required: true, message: '请输入标仓系数', trigger: 'blur' },
+                convertfactor: { required: true, message: '请输入标仓系数', trigger: 'blur', type: 'number' },
             },
             glddgfactoryItems: {
                 dgfactoryitemvalue: { required: true, message: '请输入品牌', trigger: 'blur' },
@@ -412,11 +412,11 @@ export default defineComponent({
                 mergeTwoObj(formState, props.selctedDeliveryGoods);
                 mergeTwoObj(formState, data);
                 // 单位
-                formState.unitid = data.agreeunit;
+                formState.unitid = data.goodsunitid;
                 // 品类
                 formState.gldwrstandards = gmlist.map((e) => {
                     const { wrstandardid, wrstandardname, convertfactor, unitid } = e;
-                    return { wrstandardid, wrstandardname, convertfactor: convertfactor.toString(), unitid };
+                    return { wrstandardid, wrstandardname, convertfactor: convertfactor, unitid };
                 });
                 // 品牌
                 formState.glddgfactoryItems = gblist.map((e) => {
@@ -627,7 +627,7 @@ export default defineComponent({
                 }
             }
 
-            .ant-col.tc {
+            .ant-col {
                 text-align: center;
             }
         }

+ 1 - 1
src/views/information/goods/components/modify/interface.ts

@@ -2,7 +2,7 @@ export interface GLDWRStandardEx {
     wrstandardid?: number // uint64 型号ID(修改时有值)
     wrstandardname: string // string 型号名称
     unitid: number | undefined// uint64 单位ID
-    convertfactor: string// double 标仓系数(接口为3.1及以上版本时传)
+    convertfactor: number | null// double 标仓系数(接口为3.1及以上版本时传)
 }
 
 // 现货商品品牌数据 0 29 173

+ 2 - 2
src/views/information/goods/components/modify/setup.ts

@@ -17,7 +17,7 @@ export function handleFromState() {
         type: 1,// int32 类型 1 新增 2 修改
         remark: '', // string 备注
         gldwrstandards: [
-            { wrstandardname: '', unitid: undefined, convertfactor: '', }
+            { wrstandardname: '', unitid: undefined, convertfactor: null, }
         ], //        GLDWRStandardEx 现货商品型号数据
         glddgfactoryItems: [
             { dgfactoryitemvalue: '', }
@@ -33,7 +33,7 @@ export function handleFromState() {
      */
     function addOne(key: Key): void {
         if (key === 'gldwrstandards') {
-            formState[key].push({ wrstandardname: '', unitid: undefined, convertfactor: '' })
+            formState[key].push({ wrstandardname: '', unitid: undefined, convertfactor: null })
         } else if (key === 'glddgfactoryItems') {
             formState[key].push({ dgfactoryitemvalue: '', })
         } else if (key === 'wrsconvertdetails') {

+ 8 - 6
src/views/information/spot-contract/components/add/index.vue

@@ -5,7 +5,7 @@
            v-model:visible="visible"
            centered
            :maskClosable="maskClosableFlag"
-           @cancel="cancel"
+           @cancel="closeAction"
            width="890px">
     <template #footer>
       <a-button key="submit"
@@ -484,15 +484,17 @@ export default defineComponent({
                 }
                 sendReq(param, loading, OperateType)
                     .then((res) => {
-                        //清空添加成功后的数据,确保在此新增打开是个空数据
-                        Object.assign(formState, initFormData());
                         context.emit('refresh');
-                        cancel();
+                        closeAction();
                     })
                     .catch((err) => {});
             });
         }
-
+        function closeAction() {
+            //清空添加成功后的数据,确保在此新增打开是个空数据
+            Object.assign(formState, initFormData());
+            cancel();
+        }
         initData(() => {
             queryCustomList();
             getDeliveryGoods();
@@ -502,7 +504,7 @@ export default defineComponent({
         });
         return {
             visible,
-            cancel,
+            closeAction,
             submit,
             formRef,
             loading,

+ 1 - 0
src/views/information/spot-contract/components/modify/index.vue

@@ -482,6 +482,7 @@ export default defineComponent({
                 deliverygoodsid && deliveryGoodsChange(deliverygoodsid);
                 formState.Qty = qty.toString();
                 formState.Price = price.toString();
+                contractChange(formState.ContractType)
             }
         });
         function submit() {