QuKatie 3 rokov pred
rodič
commit
9e9d967dd2

+ 1 - 1
src/views/basicData/commodityType/detailsPageEdit.vue

@@ -373,7 +373,7 @@ export default {
           },
           {
             label: "中文规格",
-            prop: "Typeno",
+            prop: "typeno",
             rules: [
               {
                 required: false,

+ 30 - 11
src/views/maintenance/priceLibrary/config/mainList.json

@@ -61,79 +61,98 @@
       "overHidden": true
     },
     {
+      "label": "价格类型",
+      "prop": "billType",
+      "index": 7,
+      "width": 100,
+      "overHidden": true,
+      "dicData":[],
+      "props": {
+        "label": "dictValue",
+        "value": "dictKey"
+      }
+    },
+    {
       "label": "最新价格",
       "prop": "price",
-      "index": 7,
+      "index": 8,
       "width": 100,
       "overHidden": true
     },
     {
       "label": "历史价格1",
       "prop": "priceOne",
-      "index": 8,
+      "index": 9,
       "width": 100,
       "overHidden": true
     },
     {
       "label": "历史价格1日期",
       "prop": "priceOneTime",
-      "index": 9,
+      "index": 10,
       "width": 100,
       "overHidden": true
     },
     {
       "label": "历史价格2",
       "prop": "priceTwo",
-      "index": 10,
+      "index": 11,
       "width": 100,
       "overHidden": true
     },
     {
       "label": "历史价格2日期",
       "prop": "priceTwoTime",
-      "index": 11,
+      "index": 12,
       "width": 100,
       "overHidden": true
     },
     {
       "label": "历史价格3",
       "prop": "priceThree",
-      "index": 12,
+      "index": 13,
       "width": 100,
       "overHidden": true
     },
     {
       "label": "历史价格3日期",
       "prop": "priceThreeTime",
-      "index": 13,
+      "index": 14,
       "width": 100,
       "overHidden": true
     },
     {
       "label": "备注",
       "prop": "remarks",
-      "index": 14,
+      "index": 15,
       "width": 100,
       "overHidden": true
     },
     {
       "label": "有效期开始",
       "prop": "startTime",
-      "index": 15,
+      "index": 16,
       "width": 100,
       "overHidden": true
     },
     {
       "label": "有效期结束",
       "prop": "endTime",
-      "index": 16,
+      "index": 17,
       "width": 100,
       "overHidden": true
     },
     {
       "label": "业务员",
       "prop": "person",
-      "index": 17,
+      "index": 18,
+      "width": 100,
+      "overHidden": true
+    },
+    {
+      "label": "状态",
+      "prop": "status",
+      "index": 18,
       "width": 100,
       "overHidden": true
     }

+ 25 - 8
src/views/maintenance/priceLibrary/detailsPage.vue

@@ -51,6 +51,7 @@
 <script>
 import { detail, submit } from "@/api/maintenance/priceLibrary";
 import { contrastObj } from "@/util/contrastData";
+import { orderStates } from "@/enums/order-stauts";
 import _ from "lodash";
 export default {
   name: "detailsPageEdit",
@@ -159,7 +160,6 @@ export default {
             },
             span: 8
           },
-
           {
             label: "最新价格",
             prop: "price",
@@ -170,8 +170,25 @@ export default {
                 trigger: "blur"
               }
             ],
-            span: 8,
-            row: true
+            span: 8
+          },
+          {
+            label: "状态",
+            prop: "status",
+            type: "select",
+            dicData: orderStates,
+            props: {
+              label: "name",
+              value: "code"
+            },
+            rules: [
+              {
+                required: true,
+                message: "",
+                trigger: "blur"
+              }
+            ],
+            span: 8
           },
           {
             label: "有效期开始",
@@ -306,12 +323,12 @@ export default {
         done();
         if (valid) {
           this.subLoading = true;
-          this.form.tradeType="CK"
-          this.configuration.dicData.forEach(e=>{
-            if(this.form.corpId==e.id){
-              this.form.corpName=e.cname
+          this.form.tradeType = "CK";
+          this.configuration.dicData.forEach(e => {
+            if (this.form.corpId == e.id) {
+              this.form.corpName = e.cname;
             }
-          })
+          });
           submit({
             ...this.form
           })

+ 20 - 7
src/views/maintenance/priceLibrary/index.vue

@@ -29,9 +29,9 @@
           <el-button type="info" size="small">报表</el-button>
         </template>
         <template slot="cnameSearch">
-          <goods-select 
-          v-model="search.cname"
-          :configuration="goodsConfiguration"
+          <goods-select
+            v-model="search.cname"
+            :configuration="goodsConfiguration"
           />
         </template>
         <template slot="corpIdSearch">
@@ -46,6 +46,9 @@
         <template slot-scope="scope" slot="grossProfitRate">
           {{ scope.row.grossProfitRate ? scope.row.grossProfitRate : 0 }}%
         </template>
+        <template slot-scope="scope" slot="status">
+          {{ scope.row.status | orderStateFormat }}
+        </template>
         <template slot-scope="scope" slot="menu">
           <el-button
             type="text"
@@ -77,10 +80,11 @@
 
 <script>
 import option from "./config/mainList.json";
-import { getList, remove} from "@/api/maintenance/priceLibrary";
+import { getList, remove } from "@/api/maintenance/priceLibrary";
 import detailPage from "./detailsPage.vue";
 import { defaultDate } from "@/util/date";
 import { micrometerFormat } from "@/util/validate";
+import { orderStateFormat } from "@/enums/order-stauts";
 import _ from "lodash";
 export default {
   name: "customerInformation",
@@ -146,6 +150,15 @@ export default {
         };
       }
     });
+    this.getWorkDicts("billType").then(res => {
+      this.findObject(this.option.column, "billType").dicData =
+        res.data.data;
+    });
+  },
+  filters: {
+    orderStateFormat(val) {
+      return orderStateFormat(val);
+    }
   },
   methods: {
     cellStyle() {
@@ -198,10 +211,10 @@ export default {
       this.page.pageSize = val;
     },
     onLoad(page, params) {
-      params={
+      params = {
         ...params,
-        tradeType:"CK"
-      }
+        tradeType: "CK"
+      };
       this.loading = true;
       getList(page.currentPage, page.pageSize, params)
         .then(res => {