ソースを参照

fix:价格修改

maliang 2 週間 前
コミット
cb6dbf5247

+ 33 - 66
jshERP-web/src/views/bill/dialog/BillDetail.vue

@@ -479,7 +479,7 @@
             >
               <template slot="unitPrice" slot-scope="text, record">
                 {{ record.unitPrice }}
-                <a-tooltip title="采购价和默认采购价不一致">
+                <a-tooltip title="价和默认采购价不一致">
                   <a-icon type="info-circle" style="color: #f5222d" v-show="record.unitPrice!=record.defaultPurchaseDecimal" />
                 </a-tooltip>
               </template>
@@ -607,7 +607,7 @@
             >
               <template slot="unitPrice" slot-scope="text, record">
                 {{ record.unitPrice }}
-                <a-tooltip title="采购价和默认采购价不一致">
+                <a-tooltip title="价和默认采购价不一致">
                   <a-icon type="info-circle" style="color: #f5222d" v-show="record.unitPrice!=record.defaultPurchaseDecimal" />
                 </a-tooltip>
               </template>
@@ -907,21 +907,11 @@
               :dataSource="dataSource"
               :scroll="{ x: '100%'}"
             >
-              <template slot="customBarCode" slot-scope="text, record">
-                <div :style="record.imgName ? 'float:left;line-height:30px' : 'float:left;'">{{ record.barCode }}</div>
-                <a-popover placement="right" trigger="click">
-                  <template slot="content"
-                    ><img :src="getImgUrl(record.imgName, record.imgLarge)" width="500px"
-                  /></template>
-                  <div class="item-info" v-if="record.imgName">
-                    <img
-                      v-if="record.imgName"
-                      :src="getImgUrl(record.imgName, record.imgSmall)"
-                      class="item-img"
-                      title="查看大图"
-                    />
-                  </div>
-                </a-popover>
+              <template slot="unitPrice" slot-scope="text, record">
+                {{ record.unitPrice }}
+                <a-tooltip title="单价和默认销售价不一致">
+                  <a-icon type="info-circle" style="color: #f5222d" v-show="record.unitPrice!=record.defaultWholesaleDecimal" />
+                </a-tooltip>
               </template>
             </a-table>
           </div>
@@ -1043,21 +1033,11 @@
               :dataSource="dataSource"
               :scroll="{ x: '100%' }"
             >
-              <template slot="customBarCode" slot-scope="text, record">
-                <div :style="record.imgName ? 'float:left;line-height:30px' : 'float:left;'">{{ record.barCode }}</div>
-                <a-popover placement="right" trigger="click">
-                  <template slot="content"
-                    ><img :src="getImgUrl(record.imgName, record.imgLarge)" width="500px"
-                  /></template>
-                  <div class="item-info" v-if="record.imgName">
-                    <img
-                      v-if="record.imgName"
-                      :src="getImgUrl(record.imgName, record.imgSmall)"
-                      class="item-img"
-                      title="查看大图"
-                    />
-                  </div>
-                </a-popover>
+              <template slot="unitPrice" slot-scope="text, record">
+                {{ record.unitPrice }}
+                <a-tooltip title="单价和默认销售价不一致">
+                  <a-icon type="info-circle" style="color: #f5222d" v-show="record.unitPrice!=record.defaultWholesaleDecimal" />
+                </a-tooltip>
               </template>
             </a-table>
           </div>
@@ -1361,21 +1341,17 @@
               :dataSource="dataSource"
               :scroll="{ x: '100%' }"
             >
-              <template slot="customBarCode" slot-scope="text, record">
-                <div :style="record.imgName ? 'float:left;line-height:30px' : 'float:left;'">{{ record.barCode }}</div>
-                <a-popover placement="right" trigger="click">
-                  <template slot="content"
-                    ><img :src="getImgUrl(record.imgName, record.imgLarge)" width="500px"
-                  /></template>
-                  <div class="item-info" v-if="record.imgName">
-                    <img
-                      v-if="record.imgName"
-                      :src="getImgUrl(record.imgName, record.imgSmall)"
-                      class="item-img"
-                      title="查看大图"
-                    />
-                  </div>
-                </a-popover>
+              <template slot="unitPrice" slot-scope="text, record">
+                {{ record.unitPrice }}
+                <a-tooltip title="单价和默认采购价不一致">
+                  <a-icon type="info-circle" style="color: #f5222d" v-show="record.unitPrice!=record.defaultPurchaseDecimal" />
+                </a-tooltip>
+              </template>
+              <template slot="wholesaleDecimal" slot-scope="text, record">
+                {{ record.wholesaleDecimal }}
+                <a-tooltip title="销售价和默认销售价不一致">
+                  <a-icon type="info-circle" style="color: #f5222d" v-show="record.wholesaleDecimal!=record.defaultWholesaleDecimal" />
+                </a-tooltip>
               </template>
             </a-table>
           </div>
@@ -1481,21 +1457,11 @@
               :dataSource="dataSource"
               :scroll="{ x: '100%' }"
             >
-              <template slot="customBarCode" slot-scope="text, record">
-                <div :style="record.imgName ? 'float:left;line-height:30px' : 'float:left;'">{{ record.barCode }}</div>
-                <a-popover placement="right" trigger="click">
-                  <template slot="content"
-                    ><img :src="getImgUrl(record.imgName, record.imgLarge)" width="500px"
-                  /></template>
-                  <div class="item-info" v-if="record.imgName">
-                    <img
-                      v-if="record.imgName"
-                      :src="getImgUrl(record.imgName, record.imgSmall)"
-                      class="item-img"
-                      title="查看大图"
-                    />
-                  </div>
-                </a-popover>
+              <template slot="unitPrice" slot-scope="text, record">
+                {{ record.unitPrice }}
+                <a-tooltip title="单价和默认销售价不一致">
+                  <a-icon type="info-circle" style="color: #f5222d" v-show="record.unitPrice!=record.defaultWholesaleDecimal" />
+                </a-tooltip>
               </template>
             </a-table>
           </div>
@@ -2155,7 +2121,7 @@ export default {
         { title: '品牌', dataIndex: 'brand', width: 90 },
         { title: '扩展信息', dataIndex: 'materialOther', width: 90 },
         { title: '库存', dataIndex: 'stock', width: 90 },
-        { title: '单位', dataIndex: 'unit', width: 90 },
+        { title: '单价', dataIndex: 'unitPrice', width: 90, scopedSlots: { customRender: 'unitPrice' } },
         { title: '出库数量', dataIndex: 'operNumber', width: 90 },
         { title: '单价', dataIndex: 'unitPrice', width: 90 },
         { title: '金额', dataIndex: 'allPrice', width: 90 },
@@ -2179,7 +2145,7 @@ export default {
         { title: '库存', dataIndex: 'stock', width: 90 },
         { title: '单位', dataIndex: 'unit', width: 90 },
         { title: '出库数量', dataIndex: 'operNumber', width: 90 },
-        { title: '单价', dataIndex: 'unitPrice', width: 90 },
+        { title: '单价', dataIndex: 'unitPrice', width: 90, scopedSlots: { customRender: 'unitPrice' } },
         { title: '金额', dataIndex: 'allPrice', width: 90 },
         { title: '税率(%)', dataIndex: 'taxRate', width: 90 },
         { title: '税额', dataIndex: 'taxMoney', width: 90 },
@@ -2224,7 +2190,8 @@ export default {
         { title: '库存', dataIndex: 'stock', width: 90 },
         { title: '单位', dataIndex: 'unit', width: 90 },
         { title: '入库数量', dataIndex: 'operNumber', width: 90 },
-        { title: '单价', dataIndex: 'unitPrice', width: 90 },
+        { title: '单价', dataIndex: 'unitPrice', width: 90, scopedSlots: { customRender: 'unitPrice' } },
+        { title: '销售价', dataIndex: 'wholesaleDecimal', width: 90, scopedSlots: { customRender: 'wholesaleDecimal' } },
         { title: '金额', dataIndex: 'allPrice', width: 90 },
         { title: '入库人', dataIndex: 'warehousingUserName', width: 90 },
         { title: '入库时间', dataIndex: 'warehousingTime', width: 90 },
@@ -2243,7 +2210,7 @@ export default {
         { title: '库存', dataIndex: 'stock', width: 90 },
         { title: '单位', dataIndex: 'unit', width: 90 },
         { title: '出库数量', dataIndex: 'operNumber', width: 90 },
-        { title: '单价', dataIndex: 'unitPrice', width: 90 },
+        { title: '单价', dataIndex: 'unitPrice', width: 90, scopedSlots: { customRender: 'unitPrice' } },
         { title: '金额', dataIndex: 'allPrice', width: 90 },
         { title: '出库人', dataIndex: 'warehousingUserName', width: 90 },
         { title: '出库时间', dataIndex: 'warehousingTime', width: 90 },

+ 3 - 3
jshERP-web/src/views/bill/modules/OtherOutModal.vue

@@ -152,13 +152,13 @@
             >
             </a-select>
           </template>
-          <template #wholesaleDecimal="{ handleChange, value, index,allValues }">
+          <!-- <template #wholesaleDecimal="{ handleChange, value, index,allValues }">
             <a-input :value="value" @change="($event) => onChangePrice($event,handleChange)">
               <a-tooltip slot="suffix" title="修改后和默认价格不一致">
                 <a-icon type="info-circle" style="color: #f5222d" v-show="getDefaultWholesaleDecimal(index,'defaultWholesaleDecimal',value,allValues)" />
               </a-tooltip>
             </a-input>
-          </template>
+          </template> -->
           <template #unitPrice="{ handleChange, value, index,allValues }">
             <a-input :value="value" @change="($event) => onChangePrice($event,handleChange)">
               <a-tooltip slot="suffix" title="修改后和默认价格不一致">
@@ -312,7 +312,7 @@ export default {
             width: '120px',
             type: FormTypes.normal,
           },
-          { title: '销售价', key: 'wholesaleDecimal', width: '120px', type: FormTypes.slot,validateRules: [{ required: true, message: '${title}不能为空' },{ pattern: /^(?!0+(\.0{1,4})?$)(?:[1-9]\d*|0)(?:\.\d{1,4})?$/, message: '金额格式不正确!' }] },
+          // { title: '销售价', key: 'wholesaleDecimal', width: '120px', type: FormTypes.slot,validateRules: [{ required: true, message: '${title}不能为空' },{ pattern: /^(?!0+(\.0{1,4})?$)(?:[1-9]\d*|0)(?:\.\d{1,4})?$/, message: '金额格式不正确!' }] },
           {
             title: '出库数量',
             key: 'operNumber',