Browse Source

Merge branch 'develop_cuxiao' of jianguan-web/qpls-md-html into pre-release

李磊 1 year ago
parent
commit
747f95b597

+ 1 - 1
public/version.json

@@ -1,5 +1,5 @@
 {
 {
   "message": "发现有新版本发布,确定更新系统?",
   "message": "发现有新版本发布,确定更新系统?",
   "vendorJsVersion": "",
   "vendorJsVersion": "",
-  "version": 1693383865079
+  "version": 1696918058872
 }
 }

+ 9 - 0
src/api/checkWarehouse.js

@@ -203,3 +203,12 @@ export const checkWarehouseDetailPrint = params => {
   }
   }
   return axios.request(data)
   return axios.request(data)
 }
 }
+
+// 盈亏成本单价修改
+export const detailModifyCost = (params) => {
+  return axios({
+    url: '/checkWarehouse/detail/modifyCost',
+    data: params,
+    method: 'post'
+  })
+}

+ 13 - 2
src/views/financialManagement/warehousingAudit/detail.vue

@@ -46,6 +46,17 @@
               :data="loadData"
               :data="loadData"
               :defaultLoadData="false"
               :defaultLoadData="false"
               bordered>
               bordered>
+              <!-- 产品编码 -->
+              <template slot="code" slot-scope="text, record">
+                <span>{{ record.dealerProductEntity.code }}</span>
+                <a-badge v-if="record.promotionFlag && record.promotionFlag=='GIFT'" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
+                <a-badge v-if="record.promotionFlag && record.promotionFlag=='DISCOUNT'" count="特" :number-style="{ backgroundColor: '#faad14', zoom:'80%',marginLeft:'5px' }"></a-badge>
+              </template>
+              <!-- 成本价 -->
+              <template slot="unitPrice" slot-scope="text, record">
+                <span v-if="record.promotionFlag && (record.promotionFlag=='GIFT' || record.promotionFlag=='DISCOUNT')">{{ record.discountedPrice||record.discountedPrice==0? toThousands(record.discountedPrice): '--' }}{{ record.origPrice ? '(' + toThousands(record.origPrice) + ')' : '' }}</span>
+                <span v-else>{{ toThousands(record.discountedPrice||0) }}</span>
+              </template>
             </s-table>
             </s-table>
           </a-collapse-panel>
           </a-collapse-panel>
         </a-collapse>
         </a-collapse>
@@ -96,7 +107,7 @@ export default {
       const _this = this
       const _this = this
       const arr = [
       const arr = [
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: '15%', align: 'center', scopedSlots: { customRender: 'code' } },
         { title: '产品名称', dataIndex: 'dealerProductEntity.name', width: '15%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '产品名称', dataIndex: 'dealerProductEntity.name', width: '15%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '采购数量', dataIndex: 'qty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '采购数量', dataIndex: 'qty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
@@ -108,7 +119,7 @@ export default {
         { title: '仓位', dataIndex: 'warehouseLocationEntity.name', width: '9%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
         { title: '仓位', dataIndex: 'warehouseLocationEntity.name', width: '9%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
       ]
       ]
       if (this.$hasPermissions('M_ShowAllCost')) {
       if (this.$hasPermissions('M_ShowAllCost')) {
-        arr.splice(7, 0, { title: '成本价', dataIndex: 'discountedPrice', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
+        arr.splice(7, 0, { title: '成本价', dataIndex: 'discountedPrice', width: '7%', align: 'right', scopedSlots: { customRender: 'unitPrice' } })
         arr.splice(8, 0, { title: '入库小计', dataIndex: 'realPutAmount', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
         arr.splice(8, 0, { title: '入库小计', dataIndex: 'realPutAmount', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
       }
       }
       return arr
       return arr

+ 40 - 4
src/views/inventoryManagement/inventoryChecking/makeInventory.vue

@@ -149,6 +149,21 @@
           <template slot="checkProfitLossQty" slot-scope="text, record">
           <template slot="checkProfitLossQty" slot-scope="text, record">
             <span :style="{ color: record.checkProfitLossQty>0?'red':record.checkProfitLossQty<0?'green':'', fontWeight: record.checkProfitLossQty!=0?'bold':'' }">{{ (record.checkProfitLossQty || record.checkProfitLossQty==0) ? Math.abs(record.checkProfitLossQty) : '--' }}</span>
             <span :style="{ color: record.checkProfitLossQty>0?'red':record.checkProfitLossQty<0?'green':'', fontWeight: record.checkProfitLossQty!=0?'bold':'' }">{{ (record.checkProfitLossQty || record.checkProfitLossQty==0) ? Math.abs(record.checkProfitLossQty) : '--' }}</span>
           </template>
           </template>
+          <!-- 盈亏成本单价 -->
+          <template slot="checkProfitLossCost" slot-scope="text, record">
+              <span v-if="record.checkProfitLossQty<=0||record.stockQty==record.checkQty" :style="{ color: record.checkProfitLossQty<0?'green':'', fontWeight: record.checkProfitLossQty!=0?'bold':'' }">{{ record.cost }}</span>
+              <div v-else>
+                <a-input-number
+                  size="small"
+                  v-model="record.cost"
+                  :precision="2"
+                  :min="0"
+                  :max="999999"
+                  placeholder="请输入"
+                  @blur="e => checkCostBlur(e.target.value, record)"
+                  style="width:100%;color: red;fontWeight:bold'"/>
+              </div>
+          </template>
         </s-table>
         </s-table>
       </a-card>
       </a-card>
     </a-spin>
     </a-spin>
@@ -178,7 +193,7 @@ import ProductType from '@/views/common/productType.js'
 import printModal from './printModal.vue'
 import printModal from './printModal.vue'
 import exportModal from './exportModal.vue'
 import exportModal from './exportModal.vue'
 import { hdPrint } from '@/libs/JGPrint.js'
 import { hdPrint } from '@/libs/JGPrint.js'
-import { checkWarehouseDetailList, checkWarehouseDetailCount, checkWarehouseInventory, checkWarehouseDetail, checkWarehouseDetailSave, checkWarehouseCheckZero, checkWarehouseWarehouse, checkWarehouseDetailExport, checkWarehouseDetailPrint } from '@/api/checkWarehouse'
+import { checkWarehouseDetailList, checkWarehouseDetailCount, checkWarehouseInventory, checkWarehouseDetail, checkWarehouseDetailSave, checkWarehouseCheckZero, checkWarehouseWarehouse, checkWarehouseDetailExport, checkWarehouseDetailPrint, detailModifyCost } from '@/api/checkWarehouse'
 export default {
 export default {
   name: 'MakeInventory',
   name: 'MakeInventory',
   components: { STable, VSelect, ProductType, printModal, exportModal },
   components: { STable, VSelect, ProductType, printModal, exportModal },
@@ -233,13 +248,14 @@ export default {
     columns () {
     columns () {
       const arr = [
       const arr = [
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '产品编码', dataIndex: 'productCode', width: '21%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '产品名称', dataIndex: 'productName', width: '21%', align: 'left', customRender: function (text) { return text || '--' } },
+        { title: '产品编码', dataIndex: 'productCode', width: '17%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品名称', dataIndex: 'productName', width: '17%', align: 'left', customRender: function (text) { return text || '--' } },
         { title: '产品分类', scopedSlots: { customRender: 'productType' }, width: '14%' },
         { title: '产品分类', scopedSlots: { customRender: 'productType' }, width: '14%' },
         { title: '单位', dataIndex: 'productUnit', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单位', dataIndex: 'productUnit', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '库存数量', dataIndex: 'stockQty', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '库存数量', dataIndex: 'stockQty', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '盘点数量', scopedSlots: { customRender: 'checkQty' }, width: '8%', align: 'center' },
         { title: '盘点数量', scopedSlots: { customRender: 'checkQty' }, width: '8%', align: 'center' },
-        { title: '盈亏数量', scopedSlots: { customRender: 'checkProfitLossQty' }, width: '8%', align: 'center' }
+        { title: '盈亏数量', scopedSlots: { customRender: 'checkProfitLossQty' }, width: '8%', align: 'center' },
+        { title: '盈亏成本单价', scopedSlots: { customRender: 'checkProfitLossCost' }, width: '8%', align: 'center' }
       ]
       ]
       if (this.basicInfoData && this.basicInfoData.warehouseFlag == '1') {
       if (this.basicInfoData && this.basicInfoData.warehouseFlag == '1') {
         arr.splice(4, 0, { title: '仓库', dataIndex: 'warehouseName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } })
         arr.splice(4, 0, { title: '仓库', dataIndex: 'warehouseName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } })
@@ -281,6 +297,26 @@ export default {
         this.handleAdd(record, 'edit')
         this.handleAdd(record, 'edit')
       }
       }
     },
     },
+    // 成本
+    checkCostBlur (val, row) {
+      if (!val) {
+        this.$message.warning('请输入盈亏成本单价!')
+        return
+      }
+      this.spinning = true
+      const params = {
+        id: row.id, checkWarehouseSn: row.checkWarehouseSn, cost: val
+      }
+      detailModifyCost(params).then(res => {
+        if (res.status == 200) {
+          this.$message.success(res.message)
+          this.$refs.table.refresh()
+          this.spinning = false
+        } else {
+          this.spinning = false
+        }
+      })
+    },
     //  添加/编辑
     //  添加/编辑
     handleAdd (row, isEdit) {
     handleAdd (row, isEdit) {
       if (!isEdit && !row.checkQty) {
       if (!isEdit && !row.checkQty) {

+ 4 - 2
src/views/inventoryManagement/inventoryChecking/selfDisk.vue

@@ -380,7 +380,8 @@ export default {
         productProduceDate: row.productProduceDate || undefined,
         productProduceDate: row.productProduceDate || undefined,
         productExpiryDate: row.productExpiryDate || undefined,
         productExpiryDate: row.productExpiryDate || undefined,
         warehouseSn: row.warehouseSn || undefined,
         warehouseSn: row.warehouseSn || undefined,
-        warehouseLocationSn: row.warehouseLocationSn || undefined
+        warehouseLocationSn: row.warehouseLocationSn || undefined,
+        cost: row.lastStockCost
       }
       }
       this.spinning = true
       this.spinning = true
       checkWarehouseDetailSave(params).then(res => {
       checkWarehouseDetailSave(params).then(res => {
@@ -423,7 +424,8 @@ export default {
             productProduceDate: item.productProduceDate || undefined,
             productProduceDate: item.productProduceDate || undefined,
             productExpiryDate: item.productExpiryDate || undefined,
             productExpiryDate: item.productExpiryDate || undefined,
             warehouseSn: item.warehouseSn || undefined,
             warehouseSn: item.warehouseSn || undefined,
-            warehouseLocationSn: item.warehouseLocationSn || undefined
+            warehouseLocationSn: item.warehouseLocationSn || undefined,
+            cost: item.lastStockCost
           })
           })
         })
         })
       } else if (type == 'all') { //  全部添加
       } else if (type == 'all') { //  全部添加

+ 6 - 7
src/views/numsGoodsShelves/shelfSet/basicInfoModal.vue

@@ -64,8 +64,7 @@
 import { commonMixin } from '@/utils/mixin'
 import { commonMixin } from '@/utils/mixin'
 import { VSelect } from '@/components'
 import { VSelect } from '@/components'
 import custList from '@/views/common/custList.vue'
 import custList from '@/views/common/custList.vue'
-// , updateShelfPriceShow
-import { shelfSave } from '@/api/shelf'
+import { shelfSave, updateShelfPriceShow } from '@/api/shelf'
 export default {
 export default {
   name: 'ShelfSetBasicInfoModal',
   name: 'ShelfSetBasicInfoModal',
   components: { VSelect, custList },
   components: { VSelect, custList },
@@ -97,13 +96,13 @@ export default {
       },
       },
       form: {
       form: {
         customerSn: undefined,
         customerSn: undefined,
-        shelfName: ''
-        // showPrice: undefined
+        shelfName: '',
+        showPrice: undefined
       },
       },
       rules: {
       rules: {
         shelfName: [{ required: true, message: '请输入货架名称', trigger: 'change' }],
         shelfName: [{ required: true, message: '请输入货架名称', trigger: 'change' }],
-        customerSn: [{ required: true, message: '请选择关联客户', trigger: 'change' }]
-        // showPrice: [{ required: true, message: '请选择价格显示', trigger: 'change' }]
+        customerSn: [{ required: true, message: '请选择关联客户', trigger: 'change' }],
+        showPrice: [{ required: true, message: '请选择价格显示', trigger: 'change' }]
       }
       }
     }
     }
   },
   },
@@ -170,7 +169,7 @@ export default {
         const _this = this
         const _this = this
         this.$nextTick(() => {
         this.$nextTick(() => {
           _this.form.shelfName = _this.nowData.shelfName
           _this.form.shelfName = _this.nowData.shelfName
-          _this.form.showPrice = _this.nowData.showPrice
+          // _this.form.showPrice = _this.nowData.showPrice
           const custome = _this.nowData.customerEntity
           const custome = _this.nowData.customerEntity
           if (custome) {
           if (custome) {
             _this.form.customerSn = custome.customerSn || ''
             _this.form.customerSn = custome.customerSn || ''

+ 1 - 0
src/views/productManagement/newProduct/detail.vue

@@ -26,6 +26,7 @@
             <a-descriptions-item label="商品尺寸:">{{ (detailsData && detailsData.size) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="商品尺寸:">{{ (detailsData && detailsData.size) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="重量:">{{ (detailsData && detailsData.weight) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="重量:">{{ (detailsData && detailsData.weight) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="计量单位:">{{ (detailsData && detailsData.unit) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="计量单位:">{{ (detailsData && detailsData.unit) || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="包装数:">{{ (detailsData && detailsData.packQty) || '--' }}{{ detailsData.packQty ? detailsData.unit : '' }}/{{ detailsData.packQtyUnit||'--' }}</a-descriptions-item>
             <!-- <a-descriptions-item label="市级价:" v-if="this.specialPriceObj.dealerLevel&&this.specialPriceObj.dealerLevel == 'PROVINCE'">{{ detailsData&&(detailsData.cityPrice||detailsData.cityPrice==0) ? toThousands(detailsData.cityPrice):'--' }}</a-descriptions-item>
             <!-- <a-descriptions-item label="市级价:" v-if="this.specialPriceObj.dealerLevel&&this.specialPriceObj.dealerLevel == 'PROVINCE'">{{ detailsData&&(detailsData.cityPrice||detailsData.cityPrice==0) ? toThousands(detailsData.cityPrice):'--' }}</a-descriptions-item>
             <a-descriptions-item label="特约价:" v-if="(this.specialPriceObj.isShowSpecialPrice&&this.specialPriceObj.isShowSpecialPrice != 0)">{{ detailsData && (detailsData.specialPrice||detailsData.specialPrice==0)?toThousands(detailsData.specialPrice) : '--' }}</a-descriptions-item>
             <a-descriptions-item label="特约价:" v-if="(this.specialPriceObj.isShowSpecialPrice&&this.specialPriceObj.isShowSpecialPrice != 0)">{{ detailsData && (detailsData.specialPrice||detailsData.specialPrice==0)?toThousands(detailsData.specialPrice) : '--' }}</a-descriptions-item>
             <a-descriptions-item label="终端价:">{{ detailsData && (detailsData.terminalPrice || detailsData.terminalPrice==0)?toThousands(detailsData.terminalPrice):'--' }}</a-descriptions-item>
             <a-descriptions-item label="终端价:">{{ detailsData && (detailsData.terminalPrice || detailsData.terminalPrice==0)?toThousands(detailsData.terminalPrice):'--' }}</a-descriptions-item>

+ 33 - 8
src/views/purchasingManagement/purchaseOrder/detail.vue

@@ -60,7 +60,8 @@
                 <div style="display: inline-block;" v-if="$hasPermissions('M_ShowAllCost')">
                 <div style="display: inline-block;" v-if="$hasPermissions('M_ShowAllCost')">
                   采购金额合计:<strong>{{ detail && (detail.discountedAmount || detail.discountedAmount==0) ? toThousands(detail.discountedAmount,2) : '--' }}</strong>,
                   采购金额合计:<strong>{{ detail && (detail.discountedAmount || detail.discountedAmount==0) ? toThousands(detail.discountedAmount,2) : '--' }}</strong>,
                   审核订单金额:<strong>{{ detail && (detail.totalPushedAmount || detail.totalPushedAmount==0) ? toThousands(detail.totalPushedAmount,2) : '--' }}</strong>,
                   审核订单金额:<strong>{{ detail && (detail.totalPushedAmount || detail.totalPushedAmount==0) ? toThousands(detail.totalPushedAmount,2) : '--' }}</strong>,
-                  已取消金额:<strong>{{ detail && (detail.totalCancelAmount || detail.totalCancelAmount==0) ? toThousands(detail.totalCancelAmount,2) : '--' }}</strong>
+                  已取消金额:<strong>{{ detail && (detail.totalCancelAmount || detail.totalCancelAmount==0) ? toThousands(detail.totalCancelAmount,2) : '--' }}</strong>,
+                  <span v-if="isShowSalesFlag" style="color: #ed1c24;">优惠金额:<strong>{{ detail && (detail.discountAmount || detail.discountAmount==0) ? detail.discountAmount.toFixed(2) : '--' }}</strong></span>
                 </div>
                 </div>
               </div>
               </div>
             </a-alert>
             </a-alert>
@@ -74,6 +75,12 @@
               :data="loadData"
               :data="loadData"
               :defaultLoadData="false"
               :defaultLoadData="false"
               bordered>
               bordered>
+              <!-- 产品编码 -->
+              <template slot="code" slot-scope="text, record">
+                <span>{{ record.dealerProductEntity.code }}</span>
+                <a-badge v-if="record.promotionFlag && record.promotionFlag=='GIFT'" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
+                <a-badge v-if="record.promotionFlag && record.promotionFlag=='DISCOUNT'" count="特" :number-style="{ backgroundColor: '#faad14', zoom:'80%',marginLeft:'5px' }"></a-badge>
+              </template>
               <!-- 采购数量 -->
               <!-- 采购数量 -->
               <template slot="origqty" slot-scope="text, record">
               <template slot="origqty" slot-scope="text, record">
                 <div>{{ text }}</div>
                 <div>{{ text }}</div>
@@ -83,6 +90,16 @@
               <template slot="outOfStockNum" slot-scope="text, record">
               <template slot="outOfStockNum" slot-scope="text, record">
                 <span>{{ record.outOfStockNum }}</span>
                 <span>{{ record.outOfStockNum }}</span>
               </template>
               </template>
+              <!-- 采购单价 -->
+              <template slot="unitPrice" slot-scope="text, record">
+                <span v-if="record.promotionFlag && (record.promotionFlag=='GIFT' || record.promotionFlag=='DISCOUNT')">{{ record.price||record.price==0? toThousands(record.price): '--' }}{{ record.origPrice ? '(' + toThousands(record.origPrice) + ')' : '' }}</span>
+                <span v-else>{{ toThousands(record.price) }}</span>
+              </template>
+              <!-- 采购金额 -->
+              <template slot="amount" slot-scope="text, record">
+                <span v-if="record.promotionFlag && (record.promotionFlag=='GIFT' || record.promotionFlag=='DISCOUNT')">{{ record.discountedAmount||record.discountedAmount==0?toThousands(record.discountedAmount) : '--' }}{{ record.totalOrigAmount ? '(' + toThousands(record.totalOrigAmount) + ')' : '' }}</span>
+                <span v-else>{{ toThousands(record.discountedAmount) }}</span>
+              </template>
             </s-table>
             </s-table>
           </a-collapse-panel>
           </a-collapse-panel>
         </a-collapse>
         </a-collapse>
@@ -161,6 +178,7 @@ export default {
   data () {
   data () {
     return {
     return {
       spinning: false,
       spinning: false,
+      isShowSalesFlag: false,
       // 加载数据方法 必须为 Promise 对象
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
       loadData: parameter => {
         this.disabled = true
         this.disabled = true
@@ -172,6 +190,7 @@ export default {
             for (var i = 0; i < data.list.length; i++) {
             for (var i = 0; i < data.list.length; i++) {
               data.list[i].no = no + i + 1
               data.list[i].no = no + i + 1
             }
             }
+            this.isShowSalesFlag = data.list.some(con => { return con.promotionFlag != 0 })
             this.localDataSource = data.list
             this.localDataSource = data.list
             this.disabled = false
             this.disabled = false
           }
           }
@@ -185,10 +204,10 @@ export default {
   },
   },
   computed: {
   computed: {
     columns () {
     columns () {
-      let _this=this
+      const _this = this
       const arr = [
       const arr = [
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: '16%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: '16%', align: 'center', scopedSlots: { customRender: 'code' } },
         { title: '产品名称', dataIndex: 'dealerProductEntity.name', width: '16%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '产品名称', dataIndex: 'dealerProductEntity.name', width: '16%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单位', dataIndex: 'dealerProductEntity.unit', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单位', dataIndex: 'dealerProductEntity.unit', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
@@ -197,12 +216,12 @@ export default {
         { title: '采购数量', dataIndex: 'qty', width: '7%', align: 'center', scopedSlots: { customRender: 'origqty' } },
         { title: '采购数量', dataIndex: 'qty', width: '7%', align: 'center', scopedSlots: { customRender: 'origqty' } },
         // { title: '审核订单金额', dataIndex: 'pushedAmount', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         // { title: '审核订单金额', dataIndex: 'pushedAmount', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '审核订单数量', dataIndex: 'pushedQty', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '审核订单数量', dataIndex: 'pushedQty', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '已取消数量', dataIndex: 'cancelQty', width: '7%', align: 'center', customRender: function (text) { return text || '--' } }
+        { title: '已取消数量', dataIndex: 'cancelQty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
       ]
       ]
       if (this.$hasPermissions('M_ShowAllCost')) {
       if (this.$hasPermissions('M_ShowAllCost')) {
-        arr.splice(5, 0, { title: '采购单价', dataIndex: 'discountedPrice', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text,2) : '--') } })
-        arr.splice(6, 0, { title: '采购金额', dataIndex: 'discountedAmount', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text,2) : '--') } })
-        arr.splice(8, 0, { title: '审核订单金额', dataIndex: 'pushedAmount', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text,2) : '--') } })
+        arr.splice(5, 0, { title: '采购单价', dataIndex: 'price', width: '7%', align: 'right', scopedSlots: { customRender: 'unitPrice' } })
+        arr.splice(6, 0, { title: '采购金额', dataIndex: 'discountedAmount', width: '7%', align: 'right', scopedSlots: { customRender: 'amount' } })
+        arr.splice(8, 0, { title: '审核订单金额', dataIndex: 'pushedAmount', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
       }
       }
       return arr
       return arr
     }
     }
@@ -220,7 +239,13 @@ export default {
     getDetail () {
     getDetail () {
       purchaseDetailBySn({ sn: this.outBizSn || this.$route.params.sn }).then(res => {
       purchaseDetailBySn({ sn: this.outBizSn || this.$route.params.sn }).then(res => {
         if (res.status == 200) {
         if (res.status == 200) {
-          this.detail = res.data
+          const dataInfo = res.data
+          if (dataInfo.totalOrigAmount && dataInfo.totalAmount) {
+            dataInfo.discountAmount = dataInfo.totalOrigAmount - dataInfo.totalAmount
+          } else {
+            dataInfo.discountAmount = null
+          }
+          this.detail = dataInfo
         } else {
         } else {
           this.detail = null
           this.detail = null
         }
         }

+ 2 - 1
src/views/purchasingManagement/purchaseOrder/list.vue

@@ -110,7 +110,8 @@
         <template slot="purchaseBillNo" slot-scope="text, record">
         <template slot="purchaseBillNo" slot-scope="text, record">
           <span class="table-td-link" v-if="$hasPermissions('B_purchaseDetail')" @click="handleDetail(record)">{{ record.purchaseBillNo }}</span>
           <span class="table-td-link" v-if="$hasPermissions('B_purchaseDetail')" @click="handleDetail(record)">{{ record.purchaseBillNo }}</span>
           <span v-else>{{ record.purchaseBillNo }}</span>
           <span v-else>{{ record.purchaseBillNo }}</span>
-          <a-badge count="改" :offset="[10,0]" v-if="record.billStatus=='HQ_CHANGE'||record.billStatus=='SUPERIOR_CHANGE'"></a-badge>
+          <a-badge v-if="record.promotionFlag && record.promotionFlag==1" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
+          <a-badge count="改" v-if="record.billStatus=='HQ_CHANGE'||record.billStatus=='SUPERIOR_CHANGE'" :number-style="{ zoom:'80%',marginLeft:'5px' }"></a-badge>
         </template>
         </template>
         <!-- 审核 -->
         <!-- 审核 -->
         <template slot="audit" slot-scope="text, record">
         <template slot="audit" slot-scope="text, record">

+ 31 - 6
src/views/purchasingManagement/purchaseOrderNew/detail.vue

@@ -64,7 +64,8 @@
           <div style="display: inline-block;" v-if="$hasPermissions('M_ShowAllCost')">
           <div style="display: inline-block;" v-if="$hasPermissions('M_ShowAllCost')">
             采购金额合计:<strong>{{ detail && (detail.discountedAmount || detail.discountedAmount==0) ? toThousands(detail.discountedAmount,2) : '--' }}</strong>,
             采购金额合计:<strong>{{ detail && (detail.discountedAmount || detail.discountedAmount==0) ? toThousands(detail.discountedAmount,2) : '--' }}</strong>,
             审核订单金额:<strong>{{ detail && (detail.totalPushedAmount || detail.totalPushedAmount==0) ? toThousands(detail.totalPushedAmount,2) : '--' }}</strong>,
             审核订单金额:<strong>{{ detail && (detail.totalPushedAmount || detail.totalPushedAmount==0) ? toThousands(detail.totalPushedAmount,2) : '--' }}</strong>,
-            已取消金额:<strong>{{ detail && (detail.totalCancelAmount || detail.totalCancelAmount==0) ? toThousands(detail.totalCancelAmount,2) : '--' }}</strong>
+            已取消金额:<strong>{{ detail && (detail.totalCancelAmount || detail.totalCancelAmount==0) ? toThousands(detail.totalCancelAmount,2) : '--' }}</strong>,
+            <span v-if="isShowSalesFlag" style="color: #ed1c24;">优惠金额:<strong>{{ detail && (detail.discountAmount || detail.discountAmount==0) ? detail.discountAmount.toFixed(2) : '--' }}</strong></span>
           </div>
           </div>
         </div>
         </div>
         <!-- 列表 -->
         <!-- 列表 -->
@@ -77,6 +78,12 @@
           :data="loadData"
           :data="loadData"
           :defaultLoadData="false"
           :defaultLoadData="false"
           bordered>
           bordered>
+          <!-- 产品编码 -->
+          <template slot="code" slot-scope="text, record">
+            <span>{{ record.dealerProductEntity.code }}</span>
+            <a-badge v-if="record.promotionFlag && record.promotionFlag=='GIFT'" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
+            <a-badge v-if="record.promotionFlag && record.promotionFlag=='DISCOUNT'" count="特" :number-style="{ backgroundColor: '#faad14', zoom:'80%',marginLeft:'5px' }"></a-badge>
+          </template>
           <!-- 采购数量 -->
           <!-- 采购数量 -->
           <template slot="origqty" slot-scope="text, record">
           <template slot="origqty" slot-scope="text, record">
             <div>{{ text }}</div>
             <div>{{ text }}</div>
@@ -86,6 +93,16 @@
           <template slot="outOfStockNum" slot-scope="text, record">
           <template slot="outOfStockNum" slot-scope="text, record">
             <span>{{ record.outOfStockNum }}</span>
             <span>{{ record.outOfStockNum }}</span>
           </template>
           </template>
+          <!-- 采购单价 -->
+          <template slot="unitPrice" slot-scope="text, record">
+            <span v-if="record.promotionFlag && (record.promotionFlag=='GIFT' || record.promotionFlag=='DISCOUNT')">{{ record.price||record.price==0? toThousands(record.price): '--' }}{{ record.origPrice ? '(' + toThousands(record.origPrice) + ')' : '' }}</span>
+            <span v-else>{{ toThousands(record.price||0) }}</span>
+          </template>
+          <!-- 采购金额 -->
+          <template slot="amount" slot-scope="text, record">
+            <span v-if="record.promotionFlag && (record.promotionFlag=='GIFT' || record.promotionFlag=='DISCOUNT')">{{ record.discountedAmount||record.discountedAmount==0?toThousands(record.discountedAmount) : '--' }}{{ record.totalOrigAmount ? '(' + toThousands(record.totalOrigAmount) + ')' : '' }}</span>
+            <span v-else>{{ toThousands(record.discountedAmount||0) }}</span>
+          </template>
         </s-table>
         </s-table>
       </a-card>
       </a-card>
     </a-spin>
     </a-spin>
@@ -113,6 +130,7 @@ export default {
     return {
     return {
       spinning: false,
       spinning: false,
       isShowBisiceInfo: false,
       isShowBisiceInfo: false,
+      isShowSalesFlag: false,
       // 加载数据方法 必须为 Promise 对象
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
       loadData: parameter => {
         this.disabled = true
         this.disabled = true
@@ -124,6 +142,7 @@ export default {
             for (var i = 0; i < data.list.length; i++) {
             for (var i = 0; i < data.list.length; i++) {
               data.list[i].no = no + i + 1
               data.list[i].no = no + i + 1
             }
             }
+            this.isShowSalesFlag = data.list.some(con => { return con.promotionFlag != 0 })
             this.localDataSource = data.list
             this.localDataSource = data.list
             this.disabled = false
             this.disabled = false
           }
           }
@@ -140,7 +159,7 @@ export default {
       const _this = this
       const _this = this
       const arr = [
       const arr = [
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: '16%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: '10%', align: 'center', scopedSlots: { customRender: 'code' } },
         { title: '产品名称', dataIndex: 'dealerProductEntity.name', width: '16%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '产品名称', dataIndex: 'dealerProductEntity.name', width: '16%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单位', dataIndex: 'dealerProductEntity.unit', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单位', dataIndex: 'dealerProductEntity.unit', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
@@ -149,11 +168,11 @@ export default {
         { title: '采购数量', dataIndex: 'qty', width: '7%', align: 'center', scopedSlots: { customRender: 'origqty' } },
         { title: '采购数量', dataIndex: 'qty', width: '7%', align: 'center', scopedSlots: { customRender: 'origqty' } },
         // { title: '审核订单金额', dataIndex: 'pushedAmount', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         // { title: '审核订单金额', dataIndex: 'pushedAmount', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '审核订单数量', dataIndex: 'pushedQty', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '审核订单数量', dataIndex: 'pushedQty', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '已取消数量', dataIndex: 'cancelQty', width: '7%', align: 'center', customRender: function (text) { return text || '--' } }
+        { title: '已取消数量', dataIndex: 'cancelQty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
       ]
       ]
       if (this.$hasPermissions('M_ShowAllCost')) {
       if (this.$hasPermissions('M_ShowAllCost')) {
-        arr.splice(5, 0, { title: '采购单价', dataIndex: 'discountedPrice', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
-        arr.splice(6, 0, { title: '采购金额', dataIndex: 'discountedAmount', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
+        arr.splice(5, 0, { title: '采购单价', dataIndex: 'price', width: '11%', align: 'right', scopedSlots: { customRender: 'unitPrice' } })
+        arr.splice(6, 0, { title: '采购金额', dataIndex: 'discountedAmount', width: '11%', align: 'right', scopedSlots: { customRender: 'amount' } })
         arr.splice(8, 0, { title: '审核订单金额', dataIndex: 'pushedAmount', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
         arr.splice(8, 0, { title: '审核订单金额', dataIndex: 'pushedAmount', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
       }
       }
       return arr
       return arr
@@ -172,7 +191,13 @@ export default {
     getDetail () {
     getDetail () {
       purchaseDetailBySn({ sn: this.outBizSn || this.$route.params.sn }).then(res => {
       purchaseDetailBySn({ sn: this.outBizSn || this.$route.params.sn }).then(res => {
         if (res.status == 200) {
         if (res.status == 200) {
-          this.detail = res.data
+          const dataInfo = res.data
+          if (dataInfo.totalOrigAmount && dataInfo.totalAmount) {
+            dataInfo.discountAmount = dataInfo.totalOrigAmount - dataInfo.totalAmount
+          } else {
+            dataInfo.discountAmount = null
+          }
+          this.detail = dataInfo
         } else {
         } else {
           this.detail = null
           this.detail = null
         }
         }

+ 7 - 6
src/views/purchasingManagement/purchaseOrderNew/list.vue

@@ -1,7 +1,7 @@
 <template>
 <template>
   <div class="purchaseNewOrderList-wrap jg-page-wrap">
   <div class="purchaseNewOrderList-wrap jg-page-wrap">
     <a-card size="small" :bordered="false" class="table-page-search-wrapper">
     <a-card size="small" :bordered="false" class="table-page-search-wrapper">
-        <!-- 搜索条件 -->
+      <!-- 搜索条件 -->
       <div ref="tableSearch">
       <div ref="tableSearch">
         <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
         <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
           <a-row type="flex" justify="start" :gutter="15">
           <a-row type="flex" justify="start" :gutter="15">
@@ -100,7 +100,8 @@
           <template slot="purchaseBillNo" slot-scope="text, record">
           <template slot="purchaseBillNo" slot-scope="text, record">
             <span class="table-td-link" v-if="$hasPermissions('B_purchaseDetail')" @click="handleDetail(record)">{{ record.purchaseBillNo }}</span>
             <span class="table-td-link" v-if="$hasPermissions('B_purchaseDetail')" @click="handleDetail(record)">{{ record.purchaseBillNo }}</span>
             <span v-else>{{ record.purchaseBillNo }}</span>
             <span v-else>{{ record.purchaseBillNo }}</span>
-            <a-badge count="改" :offset="[10,0]" v-if="record.billStatus=='HQ_CHANGE'||record.billStatus=='SUPERIOR_CHANGE'"></a-badge>
+            <a-badge v-if="record.promotionFlag && record.promotionFlag==1" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
+            <a-badge count="改" v-if="record.billStatus=='HQ_CHANGE'||record.billStatus=='SUPERIOR_CHANGE'" :number-style="{ zoom:'80%',marginLeft:'5px' }"></a-badge>
           </template>
           </template>
           <!-- 审核 -->
           <!-- 审核 -->
           <template slot="audit" slot-scope="text, record">
           <template slot="audit" slot-scope="text, record">
@@ -135,8 +136,8 @@
       </a-spin>
       </a-spin>
       <!-- 选择基本信息弹框 -->
       <!-- 选择基本信息弹框 -->
       <basic-info-modal :openModal="openModal" @ok="handleOk" @close="openModal=false" />
       <basic-info-modal :openModal="openModal" @ok="handleOk" @close="openModal=false" />
-  </a-card>
-  </div> 
+    </a-card>
+  </div>
 </template>
 </template>
 
 
 <script>
 <script>
@@ -385,5 +386,5 @@ export default {
 }
 }
 </script>
 </script>
 <style lang="less">
 <style lang="less">
-   
-</style>
+
+</style>

+ 13 - 2
src/views/purchasingManagement/purchaseOutOfStock/detailModal.vue

@@ -39,6 +39,17 @@
         :data="loadData"
         :data="loadData"
         :scroll="{ y: 500 }"
         :scroll="{ y: 500 }"
         bordered>
         bordered>
+        <!-- 产品编码 -->
+        <template slot="code" slot-scope="text, record">
+          <span>{{ record.productCode }}</span>
+          <a-badge v-if="record.promotionFlag && record.promotionFlag=='GIFT'" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
+          <a-badge v-if="record.promotionFlag && record.promotionFlag=='DISCOUNT'" count="特" :number-style="{ backgroundColor: '#faad14', zoom:'80%',marginLeft:'5px' }"></a-badge>
+        </template>
+        <!-- 缺货单价 -->
+        <template slot="unitPrice" slot-scope="text, record">
+          <span v-if="record.promotionFlag && (record.promotionFlag=='GIFT' || record.promotionFlag=='DISCOUNT')">{{ record.price||record.price==0? toThousands(record.price): '--' }}{{ record.origPrice ? '(' + toThousands(record.origPrice) + ')' : '' }}</span>
+          <span v-else>{{ toThousands(record.price||0) }}</span>
+        </template>
       </s-table>
       </s-table>
       <div class="btn-cont">
       <div class="btn-cont">
         <a-button id="inventoryQueryDetail-detail-modal-back" @click="isShow = false">返回列表</a-button>
         <a-button id="inventoryQueryDetail-detail-modal-back" @click="isShow = false">返回列表</a-button>
@@ -75,12 +86,12 @@ export default {
       const _this = this
       const _this = this
       const arr = [
       const arr = [
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '产品编码', dataIndex: 'productCode', width: '17%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品编码', dataIndex: 'productCode', scopedSlots: { customRender: 'code' }, width: '12%', align: 'center' },
         { title: '产品名称', dataIndex: 'productName', width: '17%', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
         { title: '产品名称', dataIndex: 'productName', width: '17%', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
         { title: '原厂编码', dataIndex: 'origCode', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '原厂编码', dataIndex: 'origCode', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单位', dataIndex: 'unit', width: '10%', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
         { title: '单位', dataIndex: 'unit', width: '10%', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
         { title: '缺货数量', dataIndex: 'qty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '缺货数量', dataIndex: 'qty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '单价', dataIndex: 'price', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
+        { title: '单价', dataIndex: 'price', width: '11%', align: 'right', scopedSlots: { customRender: 'unitPrice' } },
         { title: '缺货金额', dataIndex: 'totalAmount', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } }
         { title: '缺货金额', dataIndex: 'totalAmount', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } }
       ]
       ]
       return arr
       return arr

+ 6 - 1
src/views/purchasingManagement/purchaseOutOfStock/list.vue

@@ -68,6 +68,11 @@
         :scroll="{ y: tableHeight }"
         :scroll="{ y: tableHeight }"
         :defaultLoadData="false"
         :defaultLoadData="false"
         bordered>
         bordered>
+        <!-- 创建时间 -->
+        <template slot="createDate" slot-scope="text, record">
+          <span>{{ record.createDate }}</span>
+          <a-badge v-if="record.promotionFlag && record.promotionFlag==1" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
+        </template>
         <!-- 操作 -->
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
         <template slot="action" slot-scope="text, record">
           <a-button
           <a-button
@@ -143,7 +148,7 @@ export default {
       const _this = this
       const _this = this
       const arr = [
       const arr = [
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: '14%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '创建时间', dataIndex: 'createDate', scopedSlots: { customRender: 'createDate' }, width: '14%', align: 'center' },
         { title: '采购单号', dataIndex: 'purchaseBillNo', width: '14%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '采购单号', dataIndex: 'purchaseBillNo', width: '14%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '供应商', dataIndex: 'purchaseTargetName', width: '18%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '供应商', dataIndex: 'purchaseTargetName', width: '18%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '缺货款数', dataIndex: 'totalCategory', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '缺货款数', dataIndex: 'totalCategory', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },

+ 1 - 1
src/views/purchasingManagement/purchaseReturn/list.vue

@@ -71,7 +71,7 @@
         <template slot="purchaseReturnNo" slot-scope="text, record">
         <template slot="purchaseReturnNo" slot-scope="text, record">
           <span class="table-td-link" v-if="$hasPermissions('B_purchaseReturnDetail')" @click="handleDetail(record)">{{ record.purchaseReturnNo }}</span>
           <span class="table-td-link" v-if="$hasPermissions('B_purchaseReturnDetail')" @click="handleDetail(record)">{{ record.purchaseReturnNo }}</span>
           <span v-else>{{ record.purchaseReturnNo }}</span>
           <span v-else>{{ record.purchaseReturnNo }}</span>
-          <a-badge count="改" :offset="[10,0]" v-if="record.state=='HQ_CHANGE'"></a-badge>
+          <a-badge count="改" :number-style="{ zoom:'80%',marginLeft:'5px' }" v-if="record.state=='HQ_CHANGE'"></a-badge>
         </template>
         </template>
         <!-- 审核 -->
         <!-- 审核 -->
         <template slot="audit" slot-scope="text, record">
         <template slot="audit" slot-scope="text, record">

+ 1 - 1
src/views/purchasingManagement/purchaseReturnApplyForm/list.vue

@@ -87,7 +87,7 @@
         <template slot="purchaseReturnApplyNo" slot-scope="text, record">
         <template slot="purchaseReturnApplyNo" slot-scope="text, record">
           <span class="table-td-link" v-if="$hasPermissions('B_purchaseReturnApplyDetail')" @click="handleDetail(record)">{{ record.purchaseReturnApplyNo }}</span>
           <span class="table-td-link" v-if="$hasPermissions('B_purchaseReturnApplyDetail')" @click="handleDetail(record)">{{ record.purchaseReturnApplyNo }}</span>
           <span v-else>{{ record.purchaseReturnApplyNo }}</span>
           <span v-else>{{ record.purchaseReturnApplyNo }}</span>
-          <a-badge count="改" :offset="[10,0]" v-if="record.changeFlag=='1'"></a-badge>
+          <a-badge count="改" :number-style="{ zoom:'80%',marginLeft:'5px' }" v-if="record.changeFlag=='1'"></a-badge>
         </template>
         </template>
         <!-- 操作 -->
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
         <template slot="action" slot-scope="text, record">

+ 1 - 1
src/views/purchasingManagement/purchaseReturnOutSync/list.vue

@@ -90,7 +90,7 @@
         <template slot="purchaseReturnNo" slot-scope="text, record">
         <template slot="purchaseReturnNo" slot-scope="text, record">
           <span class="table-td-link" v-if="$hasPermissions('B_purchaseReturn_outSnycDetail')" @click="handleDetail(record)">{{ record.purchaseReturnNo }}</span>
           <span class="table-td-link" v-if="$hasPermissions('B_purchaseReturn_outSnycDetail')" @click="handleDetail(record)">{{ record.purchaseReturnNo }}</span>
           <span v-else>{{ record.purchaseReturnNo }}</span>
           <span v-else>{{ record.purchaseReturnNo }}</span>
-          <a-badge count="改" :offset="[10,0]" v-if="record.state=='HQ_CHANGE'"></a-badge>
+          <a-badge count="改" :number-style="{ zoom:'80%',marginLeft:'5px' }" v-if="record.state=='HQ_CHANGE'"></a-badge>
         </template>
         </template>
         <!-- 审核 -->
         <!-- 审核 -->
         <template slot="audit" slot-scope="text, record">
         <template slot="audit" slot-scope="text, record">

+ 19 - 3
src/views/purchasingManagement/signWarehousing/edit.vue

@@ -40,6 +40,12 @@
           :tableId="item.receivingBillSn"
           :tableId="item.receivingBillSn"
           :index="bindex"
           :index="bindex"
           bordered>
           bordered>
+          <!-- 产品编码 -->
+          <template slot="code" slot-scope="text, record">
+            <span>{{ record.dealerProductEntity.code }}</span>
+            <a-badge v-if="record.promotionFlag && record.promotionFlag=='GIFT'" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
+            <a-badge v-if="record.promotionFlag && record.promotionFlag=='DISCOUNT'" count="特" :number-style="{ backgroundColor: '#faad14', zoom:'80%',marginLeft:'5px' }"></a-badge>
+          </template>
           <!-- 采购数量 -->
           <!-- 采购数量 -->
           <template slot="origqty" slot-scope="text, record, index">
           <template slot="origqty" slot-scope="text, record, index">
             <div>{{ text }}</div>
             <div>{{ text }}</div>
@@ -73,6 +79,16 @@
               :allowClear="false"
               :allowClear="false"
               style="width: 100%;" />
               style="width: 100%;" />
           </template>
           </template>
+          <!-- 采购单价 -->
+          <template slot="unitPrice" slot-scope="text, record">
+            <span v-if="record.promotionFlag && (record.promotionFlag=='GIFT' || record.promotionFlag=='DISCOUNT')">{{ (record.discountedPrice ||record.discountedPrice==0) ? toThousands(record.discountedPrice): '--' }}{{ record.origPrice ? '(' + toThousands(record.origPrice) + ')' : '' }}</span>
+            <span v-else>{{ toThousands(record.discountedPrice) }}</span>
+          </template>
+          <!-- 本次发货金额 -->
+          <template slot="amount" slot-scope="text, record">
+            <span v-if="record.promotionFlag && (record.promotionFlag=='GIFT' || record.promotionFlag=='DISCOUNT')">{{ (record.discountedAmount ||record.discountedAmount==0)?toThousands(record.discountedAmount) : '--' }}{{ record.totalOrigAmount ? '(' + toThousands(record.totalOrigAmount) + ')' : '' }}</span>
+            <span v-else>{{ toThousands(record.discountedAmount) }}</span>
+          </template>
         </s-table>
         </s-table>
         <div style="text-align: center;">
         <div style="text-align: center;">
           <a-button
           <a-button
@@ -160,7 +176,7 @@ export default {
       const _this = this
       const _this = this
       const arr = [
       const arr = [
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品编码', dataIndex: 'dealerProductEntity.code', scopedSlots: { customRender: 'code' }, width: '12%', align: 'center' },
         { title: '产品名称', dataIndex: 'dealerProductEntity.name', width: '17%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '产品名称', dataIndex: 'dealerProductEntity.name', width: '17%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '采购数量', dataIndex: 'qty', width: '6%', align: 'center', scopedSlots: { customRender: 'origqty' } },
         { title: '采购数量', dataIndex: 'qty', width: '6%', align: 'center', scopedSlots: { customRender: 'origqty' } },
@@ -170,8 +186,8 @@ export default {
         { title: '仓库仓位', scopedSlots: { customRender: 'warehousePosition' }, width: '14%', align: 'center' }
         { title: '仓库仓位', scopedSlots: { customRender: 'warehousePosition' }, width: '14%', align: 'center' }
       ]
       ]
       if (this.$hasPermissions('M_ShowAllCost')) {
       if (this.$hasPermissions('M_ShowAllCost')) {
-        arr.splice(4, 0, { title: '采购单价', dataIndex: 'discountedPrice', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
-        arr.splice(8, 0, { title: '本次发货金额', dataIndex: 'discountedAmount', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
+        arr.splice(4, 0, { title: '采购单价', dataIndex: 'discountedPrice', width: '6%', align: 'right', scopedSlots: { customRender: 'unitPrice' } })
+        arr.splice(8, 0, { title: '本次发货金额', dataIndex: 'discountedAmount', width: '8%', align: 'right', scopedSlots: { customRender: 'amount' } })
         arr.splice(10, 0, { title: '本次入库金额', dataIndex: 'realPutAmount', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
         arr.splice(10, 0, { title: '本次入库金额', dataIndex: 'realPutAmount', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
       }
       }
       return arr
       return arr

+ 1 - 0
src/views/purchasingManagement/signWarehousing/list.vue

@@ -60,6 +60,7 @@
         <template slot="purchaseBillNo" slot-scope="text, record">
         <template slot="purchaseBillNo" slot-scope="text, record">
           <span class="table-td-link" v-if="$hasPermissions('B_purchaseDetail')" @click="handleDetail(record)">{{ record.purchaseBillNo || '--' }}</span>
           <span class="table-td-link" v-if="$hasPermissions('B_purchaseDetail')" @click="handleDetail(record)">{{ record.purchaseBillNo || '--' }}</span>
           <span v-else>{{ record.purchaseBillNo || '--' }}</span>
           <span v-else>{{ record.purchaseBillNo || '--' }}</span>
+          <a-badge v-if="record.promotionFlag && record.promotionFlag==1" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
         </template>
         </template>
         <!-- 发货单号 -->
         <!-- 发货单号 -->
         <template slot="sendBillNo" slot-scope="text, record">
         <template slot="sendBillNo" slot-scope="text, record">

+ 16 - 5
src/views/purchasingManagement/signWarehousing/stockOrderDetail.vue

@@ -54,7 +54,7 @@
             <div style="display: inline-block;" v-if="$hasPermissions('M_ShowAllCost')">本次发货金额合计:<strong>{{ detail && (detail.totalPutAmount || detail.totalPutAmount==0) ? toThousands(detail.totalPutAmount, 2) : '--' }}</strong>,</div>
             <div style="display: inline-block;" v-if="$hasPermissions('M_ShowAllCost')">本次发货金额合计:<strong>{{ detail && (detail.totalPutAmount || detail.totalPutAmount==0) ? toThousands(detail.totalPutAmount, 2) : '--' }}</strong>,</div>
             本次入库数量合计:<strong>{{ detail && (detail.totalRealPutQty || detail.totalRealPutQty==0) ? detail.totalRealPutQty : '--' }}</strong>
             本次入库数量合计:<strong>{{ detail && (detail.totalRealPutQty || detail.totalRealPutQty==0) ? detail.totalRealPutQty : '--' }}</strong>
             <div style="display: inline-block;" v-if="$hasPermissions('M_ShowAllCost')">,
             <div style="display: inline-block;" v-if="$hasPermissions('M_ShowAllCost')">,
-            本次入库金额合计:<strong>{{ detail && (detail.totalRealPutAmount || detail.totalRealPutAmount==0) ? toThousands(detail.totalRealPutAmount, 2) : '--' }}</strong>
+              本次入库金额合计:<strong>{{ detail && (detail.totalRealPutAmount || detail.totalRealPutAmount==0) ? toThousands(detail.totalRealPutAmount, 2) : '--' }}</strong>
             </div>
             </div>
           </div>
           </div>
         </a-alert>
         </a-alert>
@@ -68,6 +68,12 @@
           :data="loadData"
           :data="loadData"
           :defaultLoadData="false"
           :defaultLoadData="false"
           bordered>
           bordered>
+          <!-- 产品编码 -->
+          <template slot="code" slot-scope="text, record">
+            <span>{{ record.dealerProductEntity.code }}</span>
+            <a-badge v-if="record.promotionFlag && record.promotionFlag=='GIFT'" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
+            <a-badge v-if="record.promotionFlag && record.promotionFlag=='DISCOUNT'" count="特" :number-style="{ backgroundColor: '#faad14', zoom:'80%',marginLeft:'5px' }"></a-badge>
+          </template>
           <!-- 采购数量 -->
           <!-- 采购数量 -->
           <template slot="qty" slot-scope="text, record">
           <template slot="qty" slot-scope="text, record">
             <div>{{ record.qty }}</div>
             <div>{{ record.qty }}</div>
@@ -76,6 +82,11 @@
           <template slot="outOfStockNum" slot-scope="text, record">
           <template slot="outOfStockNum" slot-scope="text, record">
             <span>{{ record.outOfStockNum }}</span>
             <span>{{ record.outOfStockNum }}</span>
           </template>
           </template>
+          <!-- 采购单价 -->
+          <template slot="unitPrice" slot-scope="text, record">
+            <span v-if="record.promotionFlag && (record.promotionFlag=='GIFT' || record.promotionFlag=='DISCOUNT')">{{ (record.discountedPrice||record.discountedPrice==0)? toThousands(record.discountedPrice): '--' }}{{ record.origPrice ? '(' + toThousands(record.origPrice) + ')' : '' }}</span>
+            <span v-else>{{ toThousands(record.discountedPrice) }}</span>
+          </template>
         </s-table>
         </s-table>
       </a-card>
       </a-card>
     </a-spin>
     </a-spin>
@@ -126,16 +137,16 @@ export default {
       const _this = this
       const _this = this
       const arr = [
       const arr = [
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '产品编码', dataIndex: 'dealerProductEntity.code', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品编码', dataIndex: 'dealerProductEntity.code', scopedSlots: { customRender: 'code' }, width: '15%', align: 'center' },
         { title: '产品名称', dataIndex: 'dealerProductEntity.name', width: '14%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '产品名称', dataIndex: 'dealerProductEntity.name', width: '14%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '原厂编码', dataIndex: 'dealerProductEntity.origCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '采购数量', width: '6%', align: 'center', scopedSlots: { customRender: 'qty' } },
         { title: '采购数量', width: '6%', align: 'center', scopedSlots: { customRender: 'qty' } },
         { title: '单位', dataIndex: 'dealerProductEntity.unit', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单位', dataIndex: 'dealerProductEntity.unit', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '本次发货数量', dataIndex: 'putQty', width: '9%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '本次发货数量', dataIndex: 'putQty', width: '9%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '本次入库数量', dataIndex: 'realPutQty', width: '9%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '本次入库数量', dataIndex: 'realPutQty', width: '9%', align: 'center', customRender: function (text) { return text || '--' } }
       ]
       ]
       if (this.$hasPermissions('M_ShowAllCost')) {
       if (this.$hasPermissions('M_ShowAllCost')) {
-        arr.splice(4, 0, { title: '采购单价', dataIndex: 'discountedPrice', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
+        arr.splice(4, 0, { title: '采购单价', dataIndex: 'discountedPrice', width: '10%', align: 'right', scopedSlots: { customRender: 'unitPrice' } })
         arr.splice(8, 0, { title: '本次发货金额', dataIndex: 'discountedAmount', width: '9%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
         arr.splice(8, 0, { title: '本次发货金额', dataIndex: 'discountedAmount', width: '9%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
         arr.splice(10, 0, { title: '本次入库金额', dataIndex: 'realPutAmount', width: '9%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
         arr.splice(10, 0, { title: '本次入库金额', dataIndex: 'realPutAmount', width: '9%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
       }
       }

+ 2 - 1
src/views/reportData/stockImportReport/detailList.vue

@@ -102,7 +102,8 @@
       class="sTable"
       class="sTable"
       ref="table"
       ref="table"
       size="small"
       size="small"
-      :rowKey="(record) => record.id"
+      :rowKey="(record) => record.no"
+      rowKeyName="no"
       :columns="columns"
       :columns="columns"
       :data="loadData"
       :data="loadData"
       :defaultLoadData="false"
       :defaultLoadData="false"

+ 2 - 1
src/views/reportData/stockImportReport/list.vue

@@ -54,7 +54,8 @@
       class="sTable"
       class="sTable"
       ref="table"
       ref="table"
       size="small"
       size="small"
-      :rowKey="(record) => record.id"
+      :rowKey="(record) => record.stockImportSn"
+      rowKeyName="stockImportSn"
       :columns="columns"
       :columns="columns"
       :data="loadData"
       :data="loadData"
       :defaultLoadData="false"
       :defaultLoadData="false"

+ 1 - 1
src/views/salesManagement/salesQuery/list.vue

@@ -156,7 +156,7 @@
         <template slot="salesBillNo" slot-scope="text, record">
         <template slot="salesBillNo" slot-scope="text, record">
           <span class="table-td-link" v-if="$hasPermissions('B_salesDetail')" @click="handleDetail(record)">{{ record.salesBillNo }}</span>
           <span class="table-td-link" v-if="$hasPermissions('B_salesDetail')" @click="handleDetail(record)">{{ record.salesBillNo }}</span>
           <span v-else>{{ record.salesBillNo }}</span>
           <span v-else>{{ record.salesBillNo }}</span>
-          <a-badge count="改" :offset="[10,0]" v-if="record.billStatus=='SUPERIOR_CHANGE'"></a-badge>
+          <a-badge count="改" :number-style="{ zoom:'80%',marginLeft:'5px' }" v-if="record.billStatus=='SUPERIOR_CHANGE'"></a-badge>
         </template>
         </template>
         <!-- 审核 -->
         <!-- 审核 -->
         <template slot="audit" slot-scope="text, record">
         <template slot="audit" slot-scope="text, record">

+ 1 - 1
src/views/salesManagement/salesQueryNew/list.vue

@@ -156,7 +156,7 @@
           <template slot="salesBillNo" slot-scope="text, record">
           <template slot="salesBillNo" slot-scope="text, record">
             <span class="table-td-link" v-if="$hasPermissions('B_salesDetail')" @click="handleDetail(record)">{{ record.salesBillNo }}</span>
             <span class="table-td-link" v-if="$hasPermissions('B_salesDetail')" @click="handleDetail(record)">{{ record.salesBillNo }}</span>
             <span v-else>{{ record.salesBillNo }}</span>
             <span v-else>{{ record.salesBillNo }}</span>
-            <a-badge count="改" :offset="[10,0]" v-if="record.billStatus=='SUPERIOR_CHANGE'"></a-badge>
+            <a-badge count="改" :number-style="{ zoom:'80%',marginLeft:'5px' }" v-if="record.billStatus=='SUPERIOR_CHANGE'"></a-badge>
           </template>
           </template>
           <!-- 审核 -->
           <!-- 审核 -->
           <template slot="audit" slot-scope="text, record">
           <template slot="audit" slot-scope="text, record">