Commit 4f63dee4 by 前端

Merge branch 'hotfix_V5.7.9' into 'SAAS+V5.8.1'

上线合并

See merge request !38
2 parents f5bf4dab 21551c55
<template> <template>
<div> <div>
<GLDialog destroy-on-close="true" :visible.sync="dialogShow" :hasFooter="false" mode="big" bigTitle="产品详情" <GLDialog destroy-on-close="true" :visible.sync="dialogShow" :hasFooter="false" mode="big" bigTitle="产品详情" :close-on-click-modal="false" @onOk="handleSubmit" @onCancel="handleDetailClose">
:close-on-click-modal="false" @onOk="handleSubmit" @onCancel="handleDetailClose">
<div class="detail-content"> <div class="detail-content">
<!-- 商品详情 --> <!-- 商品详情 -->
<div class="goodsInfoCom"> <div class="goodsInfoCom">
...@@ -20,34 +19,29 @@ ...@@ -20,34 +19,29 @@
<span class="num">{{ goodsInfo.purchaseOrderCount || 0 }}笔</span> <span class="num">{{ goodsInfo.purchaseOrderCount || 0 }}笔</span>
</span> </span>
</div> </div>
<div class="productCode" v-if="goodsInfo.upgradeGoodsList && goodsInfo.upgradeGoodsList.length > 0">产品编码:{{ <div class="productCode" v-if="goodsInfo.upgradeGoodsList && goodsInfo.upgradeGoodsList.length > 0">产品编码:{{ goodsInfo.upgradeGoodsList[selectIndex].type }}</div>
goodsInfo.upgradeGoodsList[selectIndex].type }}</div>
<!--选择商品规格 v-if="!isSkuArguments"--> <!--选择商品规格多规格 v-if="!isSkuArguments"-->
<div class="content fix-header fix-bottom" v-if="goodsInfo.specificationType == 2"> <div class="content fix-header fix-bottom" v-if="goodsInfo.specificationType == 2">
<div class="mask"> <div class="mask">
<div class="mask-content"> <div class="mask-content">
<div class="spec-items"> <div class="spec-items">
<div class="spec-menu-item js-spec-menu skuCon" v-for="(item, index) in goodsTypeList" <div class="spec-menu-item js-spec-menu skuCon" v-for="(item, index) in goodsTypeList" :key="item.id">
:key="item.id">
<div class="spec-note label">{{ item.name }}:</div> <div class="spec-note label">{{ item.name }}:</div>
<div class="spec-choices"> <div class="spec-choices">
<span v-for="(el, i) in item.propertyList" :key="el.id" <span v-for="(el, i) in item.propertyList" :key="el.id" class="spec-nor skuItem one-line-ellipsis pointer" :class="{ active: el.selected, disabled: el.disabled }" @click="handleClickSpecs1(item.id, el.id, el, index, i)">{{ el.name }}</span>
class="spec-nor skuItem one-line-ellipsis pointer"
:class="{ active: el.selected, disabled: el.disabled }"
@click="handleClickSpecs1(item.id, el.id, el, index, i)">{{ el.name }}</span>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
<!-- 单规格 -->
<div class="skuCon" v-if="goodsInfo.specificationType == 1"> <div class="skuCon" v-if="goodsInfo.specificationType == 1">
<div class="label">规格:</div> <div class="label">规格:</div>
<div class="itemCon"> <div class="itemCon">
<div class="skuItem one-line-ellipsis pointer" :class="{ active: index === selectIndex }" <div class="skuItem one-line-ellipsis pointer" :class="{ active: index === selectIndex }" v-for="(item, index) in goodsInfo.upgradeGoodsList" :key="index" @click="singleClick(item, index)">
v-for="(item, index) in goodsInfo.upgradeGoodsList" :key="index" @click="singleClick(item, index)"> {{ item.purchaseGoodsName || item.thirdPartyName || item.upgradeGoodsName }}
{{ item.upgradeGoodsName }}
</div> </div>
</div> </div>
</div> </div>
...@@ -64,12 +58,8 @@ ...@@ -64,12 +58,8 @@
<div class="munCom" v-if="upgradeGoodsInfo.suitCarType == 2"> <div class="munCom" v-if="upgradeGoodsInfo.suitCarType == 2">
<div class="label">适用车型:</div> <div class="label">适用车型:</div>
<div class="munItem car-select"> <div class="munItem car-select">
<el-select ref="choose" :clearable="false" width='300' collapse-tags multiple @focus="handleCarDialog" <el-select ref="choose" :clearable="false" width="300" collapse-tags multiple @focus="handleCarDialog" value-key="carTypeId" v-model="goodsInfo.suitCarTypeList" style="margin-left: 20px;width: 300px;" placeholder="请选择">
value-key="carTypeId" v-model="goodsInfo.suitCarTypeList" style="margin-left: 20px;width: 300px;" <el-option v-for="children in goodsInfo.suitCarTypeList" :key="children.carTypeId" :label="children.carTypeName" :value="children"></el-option>
placeholder="请选择">
<el-option v-for="(children) in goodsInfo.suitCarTypeList" :key="children.carTypeId"
:label="children.carTypeName" :value="children">
</el-option>
</el-select> </el-select>
</div> </div>
</div> </div>
...@@ -93,11 +83,8 @@ ...@@ -93,11 +83,8 @@
</div> </div>
</div> </div>
</GLDialog> </GLDialog>
<carBandDialog v-if="relateStoreVisible" :upgradeGoodsInfo="goodsInfo" @handleRelateStoreConfirm="handleConfirm" <carBandDialog v-if="relateStoreVisible" :upgradeGoodsInfo="goodsInfo" @handleRelateStoreConfirm="handleConfirm" :relateStoreVisible.sync="relateStoreVisible" :goodsInfo="goodsInfo"></carBandDialog>
:relateStoreVisible.sync="relateStoreVisible" :goodsInfo="goodsInfo">
</carBandDialog>
</div> </div>
</template> </template>
<script> <script>
...@@ -537,12 +524,12 @@ let goodType = [ ...@@ -537,12 +524,12 @@ let goodType = [
] ]
} }
] ]
import carBandDialog from './carBandDialog'; import carBandDialog from './carBandDialog'
import { membraneTypeList } from '@/utils/constants.js' import { membraneTypeList } from '@/utils/constants.js'
export default { export default {
name: 'GoodsDetailCom', name: 'GoodsDetailCom',
components: { components: {
carBandDialog, carBandDialog
}, },
props: { props: {
visible: { visible: {
...@@ -551,7 +538,7 @@ export default { ...@@ -551,7 +538,7 @@ export default {
}, },
selectItemInfo: { selectItemInfo: {
type: Object, type: Object,
default: () => { } default: () => {}
}, },
goodsId: { goodsId: {
type: [String, Number] type: [String, Number]
...@@ -562,22 +549,28 @@ export default { ...@@ -562,22 +549,28 @@ export default {
data() { data() {
return { return {
options: [{ options: [
value: '选项1', {
label: '黄金糕' value: '选项1',
}, { label: '黄金糕'
value: '选项2', },
label: '双皮奶' {
}, { value: '选项2',
value: '选项3', label: '双皮奶'
label: '蚵仔煎' },
}, { {
value: '选项4', value: '选项3',
label: '龙须面' label: '蚵仔煎'
}, { },
value: '选项5', {
label: '北京烤鸭' value: '选项4',
}], label: '龙须面'
},
{
value: '选项5',
label: '北京烤鸭'
}
],
relateStoreVisible: false, relateStoreVisible: false,
// maskVisible: true, // maskVisible: true,
isSkuArguments: true, isSkuArguments: true,
...@@ -591,7 +584,7 @@ export default { ...@@ -591,7 +584,7 @@ export default {
selectItemList: [], selectItemList: [],
membraneTypeList, membraneTypeList,
goodsInfo: { goodsInfo: {
suitCarTypeList: [], suitCarTypeList: []
}, },
selectIndex: 0, selectIndex: 0,
handleItemInfo: { handleItemInfo: {
...@@ -929,7 +922,7 @@ export default { ...@@ -929,7 +922,7 @@ export default {
}, '') }, '')
if (flag) { if (flag) {
return this.$message({ return this.$message({
message:'请选择规格', message: '请选择规格',
type: 'error', type: 'error',
customClass: 'msgHierarchy' customClass: 'msgHierarchy'
}) })
...@@ -942,7 +935,7 @@ export default { ...@@ -942,7 +935,7 @@ export default {
params = { params = {
goodsNumber: this.handleItemInfo.goodsNumber, goodsNumber: this.handleItemInfo.goodsNumber,
upgradeGoodsId: item.upgradeGoodsId, upgradeGoodsId: item.upgradeGoodsId,
suitCarTypeList: this.goodsInfo.suitCarTypeList, suitCarTypeList: this.goodsInfo.suitCarTypeList
} }
} }
}) })
...@@ -953,11 +946,11 @@ export default { ...@@ -953,11 +946,11 @@ export default {
params = { params = {
goodsNumber: this.handleItemInfo.goodsNumber, goodsNumber: this.handleItemInfo.goodsNumber,
upgradeGoodsId: this.handleItemInfo.upgradeGoodsId, upgradeGoodsId: this.handleItemInfo.upgradeGoodsId,
suitCarTypeList: this.goodsInfo.suitCarTypeList, suitCarTypeList: this.goodsInfo.suitCarTypeList
} }
if (!params.upgradeGoodsId) { if (!params.upgradeGoodsId) {
this.$message({ this.$message({
message:'商品不存在', message: '商品不存在',
type: 'error', type: 'error',
customClass: 'msgHierarchy' customClass: 'msgHierarchy'
}) })
...@@ -967,7 +960,7 @@ export default { ...@@ -967,7 +960,7 @@ export default {
// 如果是专用商品 但没有选适配车型 // 如果是专用商品 但没有选适配车型
if (this.upgradeGoodsInfo.suitCarType == 2 && !this.goodsInfo.suitCarTypeList?.length) { if (this.upgradeGoodsInfo.suitCarType == 2 && !this.goodsInfo.suitCarTypeList?.length) {
return this.$message({ return this.$message({
message:'请完善商品适用车型', message: '请完善商品适用车型',
type: 'error', type: 'error',
customClass: 'msgHierarchy' customClass: 'msgHierarchy'
}) })
...@@ -977,7 +970,7 @@ export default { ...@@ -977,7 +970,7 @@ export default {
this.$apis.purchaseShopping.shoppingCarAdd(params).then(res => { this.$apis.purchaseShopping.shoppingCarAdd(params).then(res => {
console.log(res, 'res') console.log(res, 'res')
this.$message({ this.$message({
message:'加入购物车成功', message: '加入购物车成功',
type: 'success', type: 'success',
customClass: 'msgHierarchy' customClass: 'msgHierarchy'
}) })
......
...@@ -117,10 +117,16 @@ export default { ...@@ -117,10 +117,16 @@ export default {
line: 1 line: 1
}, },
{ {
label: '供应商名称',
prop: 'thirdPartyName',
width: 110
},
{
label: '产品编码', label: '产品编码',
prop: 'type', prop: 'type',
width: 100 width: 100
}, },
{ {
label: '规格', label: '规格',
prop: 'specificationData', prop: 'specificationData',
...@@ -139,6 +145,11 @@ export default { ...@@ -139,6 +145,11 @@ export default {
line: 1 line: 1
}, },
{ {
label: '产品别名',
prop: 'purchaseGoodsName',
width: 100
},
{
label: '所属分类', label: '所属分类',
prop: 'goodsTypeName', prop: 'goodsTypeName',
width: 150 width: 150
......
<template> <template>
<GLDialog v-if="dialogShow" bigTitle="退货" mode="big" :visible.sync="dialogShow" :close-on-click-modal="false" <GLDialog v-if="dialogShow" bigTitle="退货" mode="big" :visible.sync="dialogShow" :close-on-click-modal="false" @onOk="handleConfirm" @onCancel="dialogShow = false" :hasFooter="true">
@onOk="handleConfirm" @onCancel="dialogShow = false" :hasFooter="true">
<div class="detail-content" v-if="dialogShow"> <div class="detail-content" v-if="dialogShow">
<div class="addressTitle"> <div class="addressTitle">
<img src="@/images/addressIcon.webp" alt="" class="icon" /> <img src="@/images/addressIcon.webp" alt="" class="icon" />
...@@ -17,8 +16,7 @@ ...@@ -17,8 +16,7 @@
</span> </span>
<span class="address"> <span class="address">
收货地址: 收货地址:
<span class="label">{{ detailInfo.provinceName }}{{ detailInfo.cityName }}{{ detailInfo.areaName }}{{ <span class="label">{{ detailInfo.provinceName }}{{ detailInfo.cityName }}{{ detailInfo.areaName }}{{ detailInfo.contactAddress }}</span>
detailInfo.contactAddress }}</span>
</span> </span>
<span class="address" v-if="detailInfo.purchaseOrderRemark"> <span class="address" v-if="detailInfo.purchaseOrderRemark">
备注: 备注:
...@@ -31,24 +29,21 @@ ...@@ -31,24 +29,21 @@
</div> </div>
<div class="table-class"> <div class="table-class">
<!-- :pageConf="pageConf" --> <!-- :pageConf="pageConf" -->
<GLTable ref="purchaseOrderDetailTable" :tableParams="tableParams" @refreshTable="refreshTable" <GLTable ref="purchaseOrderDetailTable" :tableParams="tableParams" @refreshTable="refreshTable" :tableData="detailInfo.tableData" :tableTotal="detailInfo.tableTotal">
:tableData="detailInfo.tableData" :tableTotal="detailInfo.tableTotal">
<template slot="film" slot-scope="scope"> <template slot="film" slot-scope="scope">
<el-tooltip v-if="scope.scope.filmRollList && scope.scope.filmRollList.length > 1" placement="top" <el-tooltip v-if="scope.scope.filmRollList && scope.scope.filmRollList.length > 1" placement="top" effect="light">
effect="light">
<div class="film-txt">(...{{ scope.scope.filmRollList.length }})</div> <div class="film-txt">(...{{ scope.scope.filmRollList.length }})</div>
<div slot="content"> <div slot="content">
<div class="tool-title">膜卷号</div> <div class="tool-title">膜卷号</div>
<div v-for="(item, index) in scope.scope.filmRollList" :key="index">{{ item }}</div> <div v-for="(item, index) in scope.scope.filmRollList" :key="index">{{ item }}</div>
</div> </div>
</el-tooltip> </el-tooltip>
<div v-else-if="scope.scope.filmRollList && scope.scope.filmRollList.length == 1">{{ <div v-else-if="scope.scope.filmRollList && scope.scope.filmRollList.length == 1">{{ scope.scope.filmRollList[0] }}</div>
scope.scope.filmRollList[0] }}</div>
<div v-else>--</div> <div v-else>--</div>
</template> </template>
<template slot="upgradeGoodsName" slot-scope="scope"> <template slot="upgradeGoodsName" slot-scope="scope">
<div> <div>
<img v-if="scope.scope.refundStatus == 'Y'" class="return" src="@/assets/retrun.png" alt=""> <img v-if="scope.scope.refundStatus == 'Y'" class="return" src="@/assets/retrun.png" alt="" />
<span>{{ scope.scope.upgradeGoodsName }}</span> <span>{{ scope.scope.upgradeGoodsName }}</span>
</div> </div>
</template> </template>
...@@ -71,7 +66,7 @@ export default { ...@@ -71,7 +66,7 @@ export default {
}, },
paramsObj: { paramsObj: {
type: Object, type: Object,
default: () => { } default: () => {}
} }
}, },
computed: { computed: {
...@@ -106,6 +101,11 @@ export default { ...@@ -106,6 +101,11 @@ export default {
line: 1 line: 1
}, },
{ {
label: '供应商名称',
prop: 'thirdPartyName',
width: 110
},
{
label: '产品编码', label: '产品编码',
prop: 'type', prop: 'type',
width: 100 width: 100
...@@ -122,6 +122,11 @@ export default { ...@@ -122,6 +122,11 @@ export default {
line: 1 line: 1
}, },
{ {
label: '产品别名',
prop: 'purchaseGoodsName',
width: 100
},
{
label: '所属分类', label: '所属分类',
prop: 'goodsTypeName', prop: 'goodsTypeName',
width: 150 width: 150
...@@ -179,28 +184,31 @@ export default { ...@@ -179,28 +184,31 @@ export default {
let selectedData = this.$refs.purchaseOrderDetailTable.mutiSelectArr[this.tableParams.mutiSelectName] || [] let selectedData = this.$refs.purchaseOrderDetailTable.mutiSelectArr[this.tableParams.mutiSelectName] || []
// selectedData = selectedData.filter(item => item.refundStatus == 'N') // selectedData = selectedData.filter(item => item.refundStatus == 'N')
if (selectedData.some(item => item.refundStatus == 'Y')) { if (selectedData.some(item => item.refundStatus == 'Y')) {
return this.$message.error('商品已退货,请确认后重新操作'); return this.$message.error('商品已退货,请确认后重新操作')
} }
if (!selectedData.length) { if (!selectedData.length) {
return this.$message.error('请勾选需退货的商品'); return this.$message.error('请勾选需退货的商品')
} }
let params = { let params = {
orderCode: this.paramsObj.orderCode, orderCode: this.paramsObj.orderCode,
purchaseOrderGoodsIdList: selectedData.map(item => item.id) purchaseOrderGoodsIdList: selectedData.map(item => item.id)
} }
console.log(selectedData, 'selectedData') console.log(selectedData, 'selectedData')
this.$apis.purchaseShopping.purchaseOrderGoodsRefund(params).then(res => { this.$apis.purchaseShopping
console.log(res) .purchaseOrderGoodsRefund(params)
if (res.code == 0) { .then(res => {
this.$message.success('操作成功') console.log(res)
this.dialogShow = false if (res.code == 0) {
this.$emit('handleConfirm') this.$message.success('操作成功')
} else { this.dialogShow = false
this.$message.error(res.message) this.$emit('handleConfirm')
} } else {
}).catch((err) => { this.$message.error(res.message)
console.log(err) }
}) })
.catch(err => {
console.log(err)
})
// this.dialogShow = false // this.dialogShow = false
}, },
dynamicParams() { dynamicParams() {
...@@ -216,7 +224,7 @@ export default { ...@@ -216,7 +224,7 @@ export default {
formatter: cellValue => { formatter: cellValue => {
return membraneTypeList.includes(cellValue.goodsType) ? `${cellValue.purchaseNumber}卷` : `${cellValue.purchaseNumber}件` return membraneTypeList.includes(cellValue.goodsType) ? `${cellValue.purchaseNumber}卷` : `${cellValue.purchaseNumber}件`
} }
}, }
// { // {
// label: '已入库数量', // label: '已入库数量',
// prop: 'inputNumber', // prop: 'inputNumber',
...@@ -303,7 +311,7 @@ export default { ...@@ -303,7 +311,7 @@ export default {
font-size: 14px; font-size: 14px;
color: #666666; color: #666666;
>span { > span {
margin-right: 20px; margin-right: 20px;
margin-bottom: 10px; margin-bottom: 10px;
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!