소스 검색

商品信息

xkwg 4 년 전
부모
커밋
1af486fa7b
2개의 변경된 파일258개의 추가작업 그리고 228개의 파일을 삭제
  1. 127 91
      src/views/information/goods/components/disable/index.vue
  2. 131 137
      src/views/information/goods/components/spotDetail/index.vue

+ 127 - 91
src/views/information/goods/components/disable/index.vue

@@ -1,6 +1,6 @@
 <template>
   <!-- 停用现货品种-->
-  <a-modal class="commonModal warehouse-disable"
+  <a-modal class="commonModal spot-detail"
            title="停用现货品种"
            v-model:visible="visible"
            centered
@@ -16,96 +16,130 @@
                 :loading="loading"
                 @click="submit">确认停用</a-button>
     </template>
-    <a-form class="inlineForm"
-            :form="form"
-            @submit="handleSearch">
-      <a-row :gutter="24">
-        <a-col :span="12">
-          <a-form-item label="客户类型">
-            <span class="white">{{ selectedRow.userinfotype === '2' ? '企业' : '个人' }}</span>
-          </a-form-item>
-        </a-col>
-        <a-col :span="12">
-          <a-form-item label="企业名称">
-            <span class="white">{{ formatValue(selectedRow.customername) }}</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.nickname) }}</span>
-          </a-form-item>
-        </a-col>
-        <a-col :span="12">
-          <a-form-item label="证件类型">
-            <span class="white">{{ formatValue(selectedRow.cardtypename) }}</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.legalpersonname) }}</span>
-          </a-form-item>
-        </a-col>
-        <a-col :span="12">
-          <a-form-item label="证件号码">
-            <span class="white">{{ formatValue(selectedRow.cardnum) }}</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.taxpayernum) }}</span>
-          </a-form-item>
-        </a-col>
-        <a-col :span="12">
-          <a-form-item label="营业执照">
-            <a class="blue">查看附件</a>
-          </a-form-item>
-        </a-col>
-      </a-row>
-      <a-row :gutter="24">
-        <a-col :span="12">
-          <a-form-item label="联系人">
-            <span class="white">{{ formatValue(selectedRow.contactname) }}</span>
-          </a-form-item>
-        </a-col>
-        <a-col :span="12">
-          <a-form-item label="联系人手机号">
-            <span class="white">{{ formatValue(selectedRow.mobile) }}</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.telphone) }}</span>
-          </a-form-item>
-        </a-col>
-        <a-col :span="12">
-          <a-form-item label="状态">
-            <span class="green">{{ formatValue(getStatusName(selectedRow.status)) }}</span>
-          </a-form-item>
-        </a-col>
-      </a-row>
-      <a-row :gutter="24">
-        <a-col :span="24">
-          <a-form-item label="通讯地址">
-            <span class="white">{{ formatValue(selectedRow.address) }}</span>
-          </a-form-item>
-        </a-col>
-      </a-row>
-      <a-row :gutter="24">
-        <a-col :span="24">
-          <a-form-item label="备注">
-            <span class="white">{{ formatValue(selectedRow.remark) }}</span>
-          </a-form-item>
-        </a-col>
-      </a-row>
-    </a-form>
+      <a-form class="inlineForm"
+              ref="formRef"
+              :model="formState"
+              :rules="rules">
+          <fieldset class="formFieldSet">
+              <legend>基本信息</legend>
+              <a-row :gutter="24">
+                  <a-col :span="12">
+                      <a-form-item label="现货品种名称"
+                                   name="deliverygoodsname">
+                          <span class="white">{{ formatValue(selectedRow.data.deliverygoodsname) }}</span>
+                      </a-form-item>
+                  </a-col>
+                  <a-col :span="12">
+                      <a-form-item label="现货品种代码"
+                                   name="deliverygoodscode">
+                          <span class="white">{{ formatValue(selectedRow.data.deliverygoodsname) }}</span>
+                      </a-form-item>
+                  </a-col>
+              </a-row>
+              <a-row :gutter="24">
+                  <a-col :span="12">
+                      <a-form-item label="单位"
+                                   name="unitid">
+                          <span class="white">{{ formatValue(selectedRow.data.enumdicname) }}</span>
+                      </a-form-item>
+                  </a-col>
+                  <a-col :span="12">
+                      <a-form-item label="状态"
+                                   name="unitid">
+                          <span class="green">{{ getValidName(selectedRow.data.isvalid) }}</span>
+                      </a-form-item>
+                  </a-col>
+              </a-row>
+              <a-row :gutter="24">
+                  <a-col :span="24">
+                      <a-form-item label="备注"
+                                   name="remark">
+                          <span class="white">{{ formatValue(selectedRow.data.remark) }}</span>
+                      </a-form-item>
+                  </a-col>
+              </a-row>
+          </fieldset>
+          <fieldset class="formFieldSet">
+              <legend>品类信息</legend>
+              <a-row :gutter="24"
+                     class="dialogRowTitle">
+                  <a-col :span="8">
+            <span>
+              品类
+            </span>
+                  </a-col>
+                  <a-col :span="8">
+            <span>
+              单位
+            </span>
+                  </a-col>
+                  <a-col :span="8">
+            <span>
+              标仓系数
+            </span>
+                  </a-col>
+                  <template v-for="item in selectedRow.gmlist" :key="item.wrstandardid">
+                      <a-col :span="8" class="bt1">
+                          <div class="white">{{ item.wrstandardname }}</div>
+                      </a-col>
+                      <a-col :span="8">
+                          <div class="white">{{ item.enumdicname }}</div>
+                      </a-col>
+                      <a-col :span="8">
+                          <div class="white">{{ item.convertfactor }}</div>
+                      </a-col>
+                  </template>
+              </a-row>
+          </fieldset>
+          <fieldset class="formFieldSet">
+              <legend>品牌信息</legend>
+              <a-row :gutter="24"
+                     class="dialogRowTitle dialogRowTitle2">
+                  <a-col :span="24">
+            <span>
+              品牌
+            </span>
+                  </a-col>
+                  <template v-for="item in selectedRow.gblist" :key="item.brandid">
+                      <a-col :span="24" class="bt1">
+                          <div class="white">{{ item.brandname }}</div>
+                      </a-col>
+                  </template>
+              </a-row>
+          </fieldset>
+          <fieldset class="formFieldSet">
+              <legend>套保品种信息</legend>
+              <a-row :gutter="24"
+                     class="dialogRowTitle">
+                  <a-col :span="8">
+            <span>
+              套保品种
+            </span>
+                  </a-col>
+                  <a-col :span="8">
+            <span>
+              单位
+            </span>
+                  </a-col>
+                  <a-col :span="8">
+            <span>
+              套保系数
+            </span>
+                  </a-col>
+                  <template v-for="item in selectedRow.mgList" :key="item.mg.middlegoodsid">
+                      <a-col :span="8" class="bt1">
+                          <div class="white">{{ item.mg.middlegoodsname }}</div>
+                      </a-col>
+                      <a-col :span="8">
+                          <div class="white">{{ item.mg.enumdicname }}</div>
+                      </a-col>
+                      <a-col :span="8">
+                          <div class="white">{{ item.mg.needhedgeratio }}</div>
+                      </a-col>
+                  </template>
+              </a-row>
+          </fieldset>
+      </a-form>
   </a-modal>
 </template>
 
@@ -119,6 +153,7 @@ import { getStatusName } from '@/views/information/custom/setup';
 import { Modal } from 'ant-design-vue';
 import { stopDeliveryGoods } from '@/views/information/goods/components/setup';
 import { ErmcpDeliveryGoodsDetailEx } from '@/services/go/ermcp/goodsInfo/interface';
+import {getValidName} from "@/views/information/goods/setup";
 
 export default defineComponent({
     name: 'custom-disable',
@@ -156,6 +191,7 @@ export default defineComponent({
             maskClosableFlag,
             formatValue,
             getStatusName,
+            getValidName,
         };
     },
 });

+ 131 - 137
src/views/information/goods/components/spotDetail/index.vue

@@ -1,164 +1,150 @@
 <template>
-  <!-- 现货品种详情 -->
-  <a-modal class="commonModal spot-detail"
-           title="详情"
-           v-if="visible"
-           v-model:visible="visible"
-           centered
-           :maskClosable="maskClosableFlag"
-           @cancel="cancel"
-           width="890px">
-    <template #footer>
-      <a-button key="submit"
-                type="primary"
-                :loading="loading"
-                @click="submit">完成</a-button>
-    </template>
-    <a-form class="inlineForm"
-            ref="formRef"
-            :model="formState"
-            :rules="rules">
-      <fieldset class="formFieldSet">
-        <legend>基本信息</legend>
-        <a-row :gutter="24">
-          <a-col :span="12">
-            <a-form-item label="现货品种名称"
-                         name="deliverygoodsname">
-              <span class="white">{{ formatValue(selectedRow.data.deliverygoodsname) }}</span>
-            </a-form-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-item label="现货品种代码"
-                         name="deliverygoodscode">
-              <span class="white">{{ formatValue(selectedRow.data.deliverygoodsname) }}</span>
-            </a-form-item>
-          </a-col>
-        </a-row>
-        <a-row :gutter="24">
-          <a-col :span="12">
-            <a-form-item label="单位"
-                         name="unitid">
-              <span class="white">{{ formatValue(selectedRow.data.enumdicname) }}</span>
-            </a-form-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-item label="状态"
-                         name="unitid">
-              <span class="green">{{ getValidName(selectedRow.data.isvalid) }}</span>
-            </a-form-item>
-          </a-col>
-        </a-row>
-        <a-row :gutter="24">
-          <a-col :span="24">
-            <a-form-item label="备注"
-                         name="remark">
-              <span class="white">{{ formatValue(selectedRow.data.remark) }}</span>
-            </a-form-item>
-          </a-col>
-        </a-row>
-      </fieldset>
-      <fieldset class="formFieldSet">
-        <legend>品类信息</legend>
-        <a-row :gutter="24"
-               class="dialogRowTitle">
-          <a-col :span="8">
+    <!-- 现货品种详情 -->
+    <a-modal class="commonModal spot-detail"
+             title="详情"
+             v-if="visible"
+             v-model:visible="visible"
+             centered
+             :maskClosable="maskClosableFlag"
+             @cancel="cancel"
+             width="890px">
+        <template #footer>
+            <a-button key="submit"
+                      type="primary"
+                      :loading="loading"
+                      @click="submit">完成
+            </a-button>
+        </template>
+        <a-form class="inlineForm"
+                ref="formRef"
+                :model="formState"
+                :rules="rules">
+            <fieldset class="formFieldSet">
+                <legend>基本信息</legend>
+                <a-row :gutter="24">
+                    <a-col :span="12">
+                        <a-form-item label="现货品种名称"
+                                     name="deliverygoodsname">
+                            <span class="white">{{ formatValue(selectedRow.data.deliverygoodsname) }}</span>
+                        </a-form-item>
+                    </a-col>
+                    <a-col :span="12">
+                        <a-form-item label="现货品种代码"
+                                     name="deliverygoodscode">
+                            <span class="white">{{ formatValue(selectedRow.data.deliverygoodsname) }}</span>
+                        </a-form-item>
+                    </a-col>
+                </a-row>
+                <a-row :gutter="24">
+                    <a-col :span="12">
+                        <a-form-item label="单位"
+                                     name="unitid">
+                            <span class="white">{{ formatValue(selectedRow.data.enumdicname) }}</span>
+                        </a-form-item>
+                    </a-col>
+                    <a-col :span="12">
+                        <a-form-item label="状态"
+                                     name="unitid">
+                            <span class="green">{{ getValidName(selectedRow.data.isvalid) }}</span>
+                        </a-form-item>
+                    </a-col>
+                </a-row>
+                <a-row :gutter="24">
+                    <a-col :span="24">
+                        <a-form-item label="备注"
+                                     name="remark">
+                            <span class="white">{{ formatValue(selectedRow.data.remark) }}</span>
+                        </a-form-item>
+                    </a-col>
+                </a-row>
+            </fieldset>
+            <fieldset class="formFieldSet">
+                <legend>品类信息</legend>
+                <a-row :gutter="24"
+                       class="dialogRowTitle">
+                    <a-col :span="8">
             <span>
               品类
             </span>
-          </a-col>
-          <a-col :span="8">
+                    </a-col>
+                    <a-col :span="8">
             <span>
               单位
             </span>
-          </a-col>
-          <a-col :span="8">
+                    </a-col>
+                    <a-col :span="8">
             <span>
               标仓系数
             </span>
-          </a-col>
-        <a-col :span="8" class="bt1">
-            <div class="white">TWX-1</div>
-        </a-col>
-        <a-col :span="8">
-            <div class="white">吨</div>
-        </a-col>
-        <a-col :span="8">
-            <div class="white">1.0</div>
-        </a-col>
-        <a-col :span="8">
-            <div class="white">TWX-2</div>
-        </a-col>
-        <a-col :span="8">
-            <div class="white">吨</div>
-        </a-col>
-        <a-col :span="8">
-            <div class="white">1.1</div>
-        </a-col>
-        </a-row>
-      </fieldset>
-      <fieldset class="formFieldSet">
-        <legend>品牌信息</legend>
-        <a-row :gutter="24"
-               class="dialogRowTitle dialogRowTitle2">
-          <a-col :span="24">
+                    </a-col>
+                    <template v-for="item in selectedRow.gmlist" :key="item.wrstandardid">
+                        <a-col :span="8" class="bt1">
+                            <div class="white">{{ item.wrstandardname }}</div>
+                        </a-col>
+                        <a-col :span="8">
+                            <div class="white">{{ item.enumdicname }}</div>
+                        </a-col>
+                        <a-col :span="8">
+                            <div class="white">{{ item.convertfactor }}</div>
+                        </a-col>
+                    </template>
+                </a-row>
+            </fieldset>
+            <fieldset class="formFieldSet">
+                <legend>品牌信息</legend>
+                <a-row :gutter="24"
+                       class="dialogRowTitle dialogRowTitle2">
+                    <a-col :span="24">
             <span>
               品牌
             </span>
-          </a-col>
-        <a-col :span="24" class="bt1">
-            <div class="white">江铜</div>
-        </a-col>
-        <a-col :span="24" class="bt1">
-            <div class="white">云铜</div>
-        </a-col>
-        </a-row>
-      </fieldset>
-      <fieldset class="formFieldSet">
-        <legend>套保品种信息</legend>
-        <a-row :gutter="24"
-               class="dialogRowTitle">
-          <a-col :span="8">
+                    </a-col>
+                    <template v-for="item in selectedRow.gblist" :key="item.brandid">
+                        <a-col :span="24" class="bt1">
+                            <div class="white">{{ item.brandname }}</div>
+                        </a-col>
+                    </template>
+                </a-row>
+            </fieldset>
+            <fieldset class="formFieldSet">
+                <legend>套保品种信息</legend>
+                <a-row :gutter="24"
+                       class="dialogRowTitle">
+                    <a-col :span="8">
             <span>
               套保品种
             </span>
-          </a-col>
-          <a-col :span="8">
+                    </a-col>
+                    <a-col :span="8">
             <span>
               单位
             </span>
-          </a-col>
-          <a-col :span="8">
+                    </a-col>
+                    <a-col :span="8">
             <span>
               套保系数
             </span>
-          </a-col>
-            <a-col :span="8"  class="bt1">
-                <div class="white">标准铜</div>
-            </a-col>
-            <a-col :span="8">
-                <div class="white">吨</div>
-            </a-col>
-            <a-col :span="8">
-                <div class="white">1.0</div>
-            </a-col>
-            <a-col :span="8">
-                <div class="white">标准银</div>
-            </a-col>
-            <a-col :span="8">
-                <div class="white">吨</div>
-            </a-col>
-            <a-col :span="8">
-                <div class="white">1.1</div>
-            </a-col>
-        </a-row>
-      </fieldset>
-    </a-form>
-  </a-modal>
+                    </a-col>
+                    <template v-for="item in selectedRow.mgList" :key="item.mg.middlegoodsid">
+                        <a-col :span="8" class="bt1">
+                            <div class="white">{{ item.mg.middlegoodsname }}</div>
+                        </a-col>
+                        <a-col :span="8">
+                            <div class="white">{{ item.mg.enumdicname }}</div>
+                        </a-col>
+                        <a-col :span="8">
+                            <div class="white">{{ item.mg.needhedgeratio }}</div>
+                        </a-col>
+                    </template>
+                </a-row>
+            </fieldset>
+        </a-form>
+    </a-modal>
 </template>
 
 <script lang="ts">
 import {defineComponent, PropType, ref} from 'vue';
-import { closeModal } from '@/common/setup/modal/index';
+import {closeModal} from '@/common/setup/modal/index';
 import {formatValue, initData} from '@/common/methods/index';
 import {ErmcpDeliveryGoodsDetailEx} from "@/services/go/ermcp/goodsInfo/interface";
 import {getValidName} from "@/views/information/goods/setup";
@@ -173,14 +159,17 @@ export default defineComponent({
         },
     },
     setup() {
-        const { visible, cancel } = closeModal('detail');
+        const {visible, cancel} = closeModal('detail');
 
         const loading = ref<boolean>(false);
         const maskClosableFlag = ref<boolean>(false);
+
         function submit() {
             cancel();
         }
-        initData(() => {});
+
+        initData(() => {
+        });
         return {
             visible,
             cancel,
@@ -199,8 +188,10 @@ export default defineComponent({
     fieldset {
         padding-right: 170px;
     }
+
     .upload {
         display: inline-flex;
+
         .ant-btn.uploadBtn {
             width: 60px;
             height: 30px;
@@ -211,11 +202,13 @@ export default defineComponent({
             font-size: 14px;
             color: @m-white0;
             .rounded-corners(3px);
+
             &:hover {
                 background: rgba(@m-blue0, 0);
                 color: rgba(@m-white0, 0.8);
             }
         }
+
         .look {
             color: @m-blue0;
             font-size: 14px;
@@ -223,6 +216,7 @@ export default defineComponent({
             cursor: pointer;
         }
     }
+
     div.white {
         width: 100%;
         text-align: center;