main
陈伟 9 months ago
parent 22d7aeb566
commit 835f23f39a
  1. 2
      src/common/model/goods/Index.js
  2. 9
      src/common/model/goods/MultiSpec.js
  3. 2
      src/common/model/groupon/goods/Index.js
  4. 2
      src/common/model/sharp/goods/Index.js
  5. 11
      src/views/dataCenter/goods/Copy.vue
  6. 6
      src/views/dataCenter/goods/Create.vue
  7. 8
      src/views/dataCenter/goods/Update.vue
  8. 16
      src/views/dataCenter/goods/modules/MultiSpec.vue

@ -114,7 +114,7 @@ export default {
}
// 单规格数据
if (goodsInfo.spec_type == 10) {
const skuOne = _.pick(goodsInfo.skuList[0], ['goods_price', 'line_price', 'stock_num', 'goods_weight'])
const skuOne = _.pick(goodsInfo.skuList[0], ['goods_price', 'line_price', 'cost_price', 'stock_num', 'goods_weight'])
goodsFormData = { ...goodsFormData, ...skuOne }
}
// 商品限购数据

@ -17,11 +17,17 @@ const defaultColumns = [
scopedSlots: { customRender: 'goods_price' }
},
{
title: '成本价',
dataIndex: 'cost_price',
width: 120,
scopedSlots: { customRender: 'cost_price' }
},
/* {
title: '划线价格',
dataIndex: 'line_price',
width: 120,
scopedSlots: { customRender: 'line_price' }
},
}, */
{
title: '库存数量',
dataIndex: 'stock_num',
@ -49,6 +55,7 @@ const defaultSkuItemData = {
// imageList: [],
goods_price: '',
line_price: '',
cost_price: '',
stock_num: '',
goods_weight: '',
goods_sku_no: ''

@ -53,7 +53,7 @@ export default {
'goods_name', 'goods_no', 'delivery_type', 'sort',
])
// 单规格数据
const skuOne = _.pick(goodsInfo.skuList[0], ['goods_price', 'line_price', 'stock_num', 'goods_weight'])
const skuOne = _.pick(goodsInfo.skuList[0], ['goods_price', 'line_price', 'cost_price', 'stock_num', 'goods_weight'])
return {
...goodsFormData,
...skuOne

@ -53,7 +53,7 @@ export default {
'goods_name', 'goods_no', 'delivery_type', 'sort',
])
// 单规格数据
const skuOne = _.pick(goodsInfo.skuList[0], ['goods_price', 'line_price', 'stock_num', 'goods_weight'])
const skuOne = _.pick(goodsInfo.skuList[0], ['goods_price', 'line_price', 'cost_price', 'stock_num', 'goods_weight'])
return {
...goodsFormData,
...skuOne

@ -154,6 +154,15 @@
<span class="ml-10"></span>
</a-form-item>
<a-form-item
label="成本价"
:labelCol="labelCol"
:wrapperCol="wrapperCol"
extra="成本价仅用于商品页展示"
>
<a-input-number :min="0" :precision="2" v-decorator="['cost_price']" />
<span class="ml-10"></span>
</a-form-item>
<!-- <a-form-item
label="划线价"
:labelCol="labelCol"
:wrapperCol="wrapperCol"
@ -161,7 +170,7 @@
>
<a-input-number :min="0" :precision="2" v-decorator="['line_price']" />
<span class="ml-10"></span>
</a-form-item>
</a-form-item> -->
<a-form-item
label="当前库存数量"
:labelCol="labelCol"

@ -184,12 +184,12 @@
<span class="ml-10"></span>
</a-form-item>
<a-form-item
label="划线价"
label="成本价"
:labelCol="labelCol"
:wrapperCol="wrapperCol"
extra="划线价仅用于商品页展示"
extra="成本价仅用于商品页展示"
>
<a-input-number :min="0" :precision="2" v-decorator="['line_price']" />
<a-input-number :min="0" :precision="2" v-decorator="['cost_price']" />
<span class="ml-10"></span>
</a-form-item>
<a-form-item

@ -194,12 +194,12 @@
<span class="ml-10"></span>
</a-form-item>
<a-form-item
label="划线价"
label="成本价"
:labelCol="labelCol"
:wrapperCol="wrapperCol"
extra="划线价仅用于商品页展示"
extra="成本价仅用于商品页展示"
>
<a-input-number :min="0" :precision="2" v-decorator="['line_price']" />
<a-input-number :min="0" :precision="2" v-decorator="['cost_price']" />
<span class="ml-10"></span>
</a-form-item>
<a-form-item
@ -611,7 +611,7 @@ export default {
//
const tabsFieldsMap = [
['goods_type', 'goods_name', 'categorys', 'imagesIds', 'delivery_id', 'is_ind_delivery_type', 'delivery_type','is_brand', 'is_in_store'],
['spec_type', 'goods_price', 'is_restrict', 'restrict_total', 'restrict_single'],
['spec_type', 'goods_price', 'is_restrict', 'restrict_total', 'restrict_single', 'cost_price'],
['content'],
['alone_grade_equity', 'first_money', 'second_money', 'third_money']
]

@ -71,11 +71,17 @@
:precision="2"
/>
<a-input-number
v-model="multiSpecData.skuBatchForm.cost_price"
placeholder="成本价"
:min="0"
:precision="2"
/>
<!-- <a-input-number
v-model="multiSpecData.skuBatchForm.line_price"
placeholder="划线价格"
:min="0"
:precision="2"
/>
/> -->
<a-input-number
v-model="multiSpecData.skuBatchForm.stock_num"
placeholder="库存数量"
@ -112,10 +118,14 @@
<template slot="goods_price" slot-scope="text, item">
<a-input-number v-model="item.goods_price" size="small" :min="0.01" :precision="2" />
</template>
<!-- 成本价 -->
<template slot="cost_price" slot-scope="text, item">
<a-input-number v-model="item.cost_price" size="small" :min="0" :precision="2" />
</template>
<!-- 划线价格 -->
<template slot="line_price" slot-scope="text, item">
<!-- <template slot="line_price" slot-scope="text, item">
<a-input-number v-model="item.line_price" size="small" :min="0" :precision="2" />
</template>
</template> -->
<!-- 库存数量 -->
<template slot="stock_num" slot-scope="text, item">
<a-input-number v-model="item.stock_num" size="small" :min="0" :precision="0" />

Loading…
Cancel
Save