Commit 704e5a30 by wangzhihui

```

feat(goods): 添加供应商编码字段到商品选择对话框

- 在selectGoodsDialog组件中新增供应商编码列显示
- 修改列插入逻辑,将供应商编码列正确插入到指定位置
- 移除重复的供应商编码列添加代码

feat(purchase): 增加上架表单中的产品别名验证和限制

- 将goodsAlias字段验证规则迁移到purchaseGoodsName字段
- 添加产品别名长度不超过30个字符的验证
- 移除冗余的goodsAlias字段初始化

feat(goods): 扩展上架列表中的供应商信息展示

- 在purchaseOnShelves列表中添加供应商名称列
- 调整供应商编码和产品编码列的数据获取路径
- 修正列配置结构以支持嵌套数据访问

refactor(delivery): 优化发货详情对话框模板结构

- 格式化长标签属性以提高代码可读性
- 统一模板语法风格,改善代码格式
- 添加缺失的parentProp配置以正确获取嵌套数据

feat(delivery): 补充发货详情表格中的产品信息列

- 新增供应商名称、供应商编码和产品别名列
- 配置相应的数据格式化器处理空值情况
- 调整列顺序以保持逻辑一致性

refactor(review): 优化审核页面布局和样式

- 简化模板中的多余换行和空格
- 添加缺失的样式类以改善视觉效果
- 调整CSS选择器格式以符合规范
```
1 parent 477bdf25
......@@ -242,7 +242,16 @@ export default {
formatter: (cellValue) => {
return this.filterSpecsStr(cellValue);
},
}, {
},
{
label: "供应商编码",
prop: "thirdPartyCode",
width: 100,
formatter: (cellValue) => {
return cellValue?.thirdPartyCode || "-";
},
},
{
label: "运营成本/元",
prop: "operationCost",
width: 150
......@@ -308,7 +317,7 @@ export default {
keyFn: this.keyDowmGetList,
});
const typeIndex = this.tableParams.tableColumns.findIndex(item => item.prop === 'type');
const typeIndex = this.tableParams.tableColumns.findIndex(item => item.prop === 'upgradeGoodsName');
if (typeIndex > -1) {
this.tableParams.tableColumns.splice(typeIndex + 1, 0, {
label: "供应商名称",
......@@ -319,18 +328,6 @@ export default {
},
});
}
const specIndex = this.tableParams.tableColumns.findIndex(item => item.prop === 'specificationData');
if (specIndex > -1) {
this.tableParams.tableColumns.splice(specIndex + 1, 0, {
label: "供应商编码",
prop: "thirdPartyCode",
width: 100,
formatter: (cellValue) => {
return cellValue?.thirdPartyCode || "-";
},
});
}
}
},
searchInput(e, key) {
......
......@@ -382,8 +382,7 @@ export default {
}
}
],
goodsAlias: [
{ required: true, message: "请输入产品别名", trigger: "blur" },
purchaseGoodsName: [
{
validator: (rule, value, callback) => {
value.length > 30 ? callback(new Error("产品别名不能超过30个字符")) : callback()
......
......@@ -97,8 +97,8 @@ export default {
label: '产品别名',
type: 'input',
width: '432px',
value: "purchaseGoodsName",
handleInput: true
maxlength: 30,
value: "purchaseGoodsName"
},
{
name: 'purchasePrice',
......@@ -172,7 +172,6 @@ export default {
// validMinSellPriceFlag: true,
// validMinSellPrice: 'Y',
suitCarType: 1,
goodsAlias: '',
purchaseGoodsName: ''
},
secondGoodsList: [],
......
......@@ -300,7 +300,17 @@ export default {
// formatter: (cellValue) => {
// return cellValue.upgradeGoods.upgradeGoodsName || '-'
// }
}, {
},
{
label: '供应商名称',
prop: 'thirdPartyName',
parentProp: 'upgradeGoods',
width: 100,
formatter: (cellValue) => {
return cellValue?.upgradeGoods?.thirdPartyName || '-'
}
},
{
label: '规格',
prop: 'thirdPartyCode',
width: 140,
......@@ -327,22 +337,16 @@ export default {
label: '产品编码',
prop: 'type',
parentProp: 'upgradeGoods',
// formatter: (cellValue) => {
// return cellValue.upgradeGoods.type || '-'
// }
}, {
label: '供应商名称',
prop: 'thirdPartyName',
width: 100,
formatter: (cellValue) => {
return cellValue?.thirdPartyName || '-'
return cellValue.upgradeGoods.type || '-'
}
}, {
label: '供应商编码',
prop: 'thirdPartyCode',
parentProp: 'upgradeGoods',
width: 100,
formatter: (cellValue) => {
return cellValue?.thirdPartyCode || '-'
return cellValue?.upgradeGoods.thirdPartyCode || '-'
}
}, {
label: '上架商户',
......
<!-- 发货单详情弹窗 -->
<template>
<div>
<baseDialog title="详细信息" :is-show.sync="detailVisible" :config="dialogConfig.setting" :dialog-config="dialogConfig.config" width="1050px" :no-cancel="true" btn-ok-label="关闭" @closeDialog="handleClose" @confirmDialog="handleClose">
<baseDialog title="详细信息" :is-show.sync="detailVisible" :config="dialogConfig.setting"
:dialog-config="dialogConfig.config" width="1050px" :no-cancel="true" btn-ok-label="关闭" @closeDialog="handleClose"
@confirmDialog="handleClose">
<div class="stockMonthDailog">
<div class="addressTitle">
<img src="../images/addressIcon.webp" alt="" class="icon">
......@@ -30,11 +32,13 @@
<span>{{ itemList.deliveryDate }}</span>
</div>
<div>
<el-button style="padding: 0;" v-if="itemList.putStatus == 0" type="text" @click="handleEdit(itemList)">编辑</el-button>
<el-button style="padding: 0;" v-if="itemList.putStatus == 0" type="text"
@click="handleEdit(itemList)">编辑</el-button>
<el-button style="padding: 0;" type="text" @click="handleSign(itemList)">发货签收单</el-button>
</div>
</div>
<d2-table ref="recordTable" :table-data="itemList.deliveryDetailList" :table-params="tableParams" :has-page="false">
<d2-table ref="recordTable" :table-data="itemList.deliveryDetailList" :table-params="tableParams"
:has-page="false">
<span slot="deliveryCard" slot-scope="scope">
<template v-if="scope.scope.deliveryCardList && scope.scope.deliveryCardList.length > 1">
<!-- {{ scope.scope.deliveryCardList.length || 0 }} -->
......@@ -52,12 +56,17 @@
</div>
</div>
</baseDialog>
<baseDialog title="查看发货卡号" :config="carDialogConfig.setting" :dialog-config="carDialogConfig.config" :is-show.sync="handleDeliveryCardVisible" width="500px" :no-cancel="true" btn-ok-label="关闭" @closeDialog="handleDeliveryCardVisible = false" @confirmDialog="handleDeliveryCardVisible = false">
<d2-table class="deliveryCardCon" ref="recordTable" :table-data="deliveryCardList" :table-params="innerParams" :has-page="false">
<baseDialog title="查看发货卡号" :config="carDialogConfig.setting" :dialog-config="carDialogConfig.config"
:is-show.sync="handleDeliveryCardVisible" width="500px" :no-cancel="true" btn-ok-label="关闭"
@closeDialog="handleDeliveryCardVisible = false" @confirmDialog="handleDeliveryCardVisible = false">
<d2-table class="deliveryCardCon" ref="recordTable" :table-data="deliveryCardList" :table-params="innerParams"
:has-page="false">
</d2-table>
</baseDialog>
<!-- 编辑 -->
<glsk-form-dialog v-if="editVisible" :selectVisible="editVisible" :dialogConfig="editDialogConfig" label-width="104px" dialog-width="520px" :formRules="editRules" :editData="editData" :editFormData="editFormData" :base-data="baseData" @handleClose="editVisible = false" @handleConfirm="handleEditConfirm"></glsk-form-dialog>
<glsk-form-dialog v-if="editVisible" :selectVisible="editVisible" :dialogConfig="editDialogConfig" label-width="104px"
dialog-width="520px" :formRules="editRules" :editData="editData" :editFormData="editFormData" :base-data="baseData"
@handleClose="editVisible = false" @handleConfirm="handleEditConfirm"></glsk-form-dialog>
</div>
</template>
......@@ -120,6 +129,11 @@ export default {
prop: 'upgradeGoodsName'
},
{
label: "供应商名称",
prop: 'thirdPartyName',
width: 100,
},
{
label: '产品编码',
prop: 'type'
},
......@@ -128,6 +142,15 @@ export default {
prop: 'specificationData'
},
{
label: '供应商编码',
prop: 'thirdPartyCode',
width: 100
},
{
label: "产品别名",
prop: "purchaseGoodsName",
},
{
label: '发货数量',
prop: 'purchaseNumber',
formatter: cellValue => {
......@@ -321,7 +344,7 @@ export default {
font-size: 14px;
color: #666666;
> span {
>span {
margin-right: 20px;
margin-bottom: 10px;
}
......@@ -347,10 +370,12 @@ export default {
display: flex;
width: 319px;
}
.detail-label {
width: 70px;
flex-shrink: 0;
}
span {
color: #333333ff;
}
......
......@@ -233,10 +233,7 @@ export default {
: `${cellValue.goodsNumber}件`;
},
},
{
label: "产品别名",
prop: "purchaseGoodsName",
},
{
label: "已发货数量",
prop: "purchaseNumber",
......@@ -248,6 +245,10 @@ export default {
},
},
{
label: "产品别名",
prop: "purchaseGoodsName",
},
{
label: "单价",
prop: "upgradePurchasePrice",
formatter: (row) => {
......
......@@ -609,9 +609,7 @@ export default {
label: '供应商名称',
prop: 'thirdPartyName',
width: 100,
formatter: (cellValue) => {
return cellValue?.upgradeGoods?.thirdPartyName || '-'
}
},
{
label: "产品编码",
......@@ -634,9 +632,7 @@ export default {
label: '供应商编码',
prop: 'thirdPartyCode',
width: 100,
formatter: (cellValue) => {
return cellValue?.upgradeGoods?.thirdPartyCode || '-'
}
},
{
label: "系列",
......
<!-- 编辑 - 审核 -->
<template>
<d2-container v-loading="loading">
<div class="edit-page edit-tmpl">
<div class="title">
产品信息
</div>
<div class="content-box">
<d2-table ref="purchaseOrderDetailTable"
:table-params="tableParams"
:table-data="detailInfo.tableData"
:layout="layout"
:table-total="detailInfo.tableTotal"
@refreshTable="refreshTable">
<template #upgradeGoodsName="scope">
<div>
<img v-if="scope.scope.refundStatus == 'Y'"
class="return"
src="@/assets/retrun.png"
alt="">
<span>{{ scope.scope.upgradeGoodsName }}</span>
</div>
</template>
<template #filmRollNo="scope">
<div v-if="scope.scope.filmRollList && scope.scope.filmRollList.length == 1">
{{ scope.scope.filmRollList[0] }}
</div>
<div v-else-if="scope.scope.filmRollList && scope.scope.filmRollList.length > 1">
<el-popover placement="top"
width="200"
trigger="hover">
<div class="film-roll-box">
<div class="title">
膜卷号
</div>
<div v-for="(subItem, subIndex) in scope.scope.filmRollList"
:key="subIndex"
class="merchant-item">
{{ subItem }}
</div>
</div>
<template #reference>
<div>
<!-- <img style="width: 14px;height: 13px;" src="./images/merchant_icon.png"> -->
<span style="color: #2A58AD;">(…{{ scope.scope.filmRollList.length }})</span>
</div>
</template>
</el-popover>
</div>
<div v-else>
<span style="overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">{{ '-' }}</span>
</div>
</template>
<template #carName="scope">
<el-tooltip v-if="scope.scope.suitCarTypeList && scope.scope.suitCarTypeList.length" placement="top">
<template #content>
<div class="car-type-list">
<div v-for="(item, index) in scope.scope.suitCarTypeList" :key="index">
{{
`${item.brandName}-${item.childName}-${item.seriesName}-${item.carTypeName}` }}
</div>
</div>
</template>
<div>{{ scope.scope.suitCarTypeList | formatCar }}</div>
</el-tooltip>
<div v-else>
-
</div>
</template>
</d2-table>
</div>
</div>
<div class="content-box">
<glsx-combi-form ref="editFormRef"
class="edit-form-container"
label-width="150px"
default-width="470px"
:is-block="isBlock"
:form-ref="editChildRef"
:form-obj="infoForm"
:form-data="editFormData"
:form-rules="formRules">
</glsx-combi-form>
<ExamineRecord :use-expand="false"
:list="detailInfo.auditDetaiList"
style="margin-top:20px;" />
<d2-container v-loading="loading">
<div class="edit-page edit-tmpl">
<div class="title">
产品信息
</div>
<div class="content-box">
<d2-table ref="purchaseOrderDetailTable" :table-params="tableParams" :table-data="detailInfo.tableData"
:layout="layout" :table-total="detailInfo.tableTotal" @refreshTable="refreshTable">
<template #upgradeGoodsName="scope">
<div>
<img v-if="scope.scope.refundStatus == 'Y'" class="return" src="@/assets/retrun.png" alt="">
<span>{{ scope.scope.upgradeGoodsName }}</span>
</div>
</template>
<template #filmRollNo="scope">
<div v-if="scope.scope.filmRollList && scope.scope.filmRollList.length == 1">
{{ scope.scope.filmRollList[0] }}
</div>
<div v-else-if="scope.scope.filmRollList && scope.scope.filmRollList.length > 1">
<el-popover placement="top" width="200" trigger="hover">
<div class="film-roll-box">
<div class="title">
膜卷号
</div>
<div v-for="(subItem, subIndex) in scope.scope.filmRollList" :key="subIndex"
class="merchant-item">
{{ subItem }}
</div>
</div>
<template #reference>
<div>
<!-- <img style="width: 14px;height: 13px;" src="./images/merchant_icon.png"> -->
<span style="color: #2A58AD;">(…{{ scope.scope.filmRollList.length }})</span>
</div>
</template>
</el-popover>
</div>
<div v-else>
<span style="overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">{{ '-' }}</span>
</div>
</template>
<template #carName="scope">
<el-tooltip v-if="scope.scope.suitCarTypeList && scope.scope.suitCarTypeList.length"
placement="top">
<template #content>
<div class="car-type-list">
<div v-for="(item, index) in scope.scope.suitCarTypeList" :key="index">
{{
`${item.brandName}-${item.childName}-${item.seriesName}-${item.carTypeName}` }}
</div>
</div>
</template>
<div>{{ scope.scope.suitCarTypeList | formatCar }}</div>
</el-tooltip>
<div v-else>
-
</div>
</template>
</d2-table>
</div>
</div>
<div class="content-box">
<glsx-combi-form ref="editFormRef" class="edit-form-container" label-width="150px" default-width="470px"
:is-block="isBlock" :form-ref="editChildRef" :form-obj="infoForm" :form-data="editFormData"
:form-rules="formRules">
</glsx-combi-form>
<ExamineRecord :use-expand="false" :list="detailInfo.auditDetaiList" style="margin-top:20px;" />
</div>
<div class="footer">
<el-button type="primary"
:loading="loading"
@click="handleConfirm">
确定
</el-button>
<el-button @click="handleCancel">
取消
</el-button>
</div>
</d2-container>
</div>
<div class="footer">
<el-button type="primary" :loading="loading" @click="handleConfirm">
确定
</el-button>
<el-button @click="handleCancel">
取消
</el-button>
</div>
</d2-container>
</template>
<script>
......@@ -140,6 +121,11 @@ export default {
prop: "upgradeGoodsName",
},
{
label: "供应商名称",
prop: 'thirdPartyName',
width: 100,
},
{
label: "产品编码",
prop: "type",
},
......@@ -147,6 +133,12 @@ export default {
label: "规格",
prop: "specificationData",
},
{
label: '供应商编码',
prop: 'thirdPartyCode',
width: 100
},
{
label: "采购数量",
prop: "goodsNumber",
......@@ -163,6 +155,7 @@ export default {
return this.paramsObj.purchaseType == 1 ? condition : `${cellValue.goodsNumber}件`;
},
},
{
label: "已发货数量",
prop: "purchaseNumber",
......@@ -172,6 +165,10 @@ export default {
},
},
{
label: "产品别名",
prop: "purchaseGoodsName",
},
{
label: "单价",
prop: "upgradePurchasePrice",
formatter: (row) => {
......@@ -420,6 +417,7 @@ export default {
::v-deep .d2-container-full {
bottom: 60px !important;
}
.edit-page.edit-tmpl {
background: #ffffff;
......@@ -433,11 +431,13 @@ export default {
color: #333333;
}
}
.content-box {
padding: 20px;
background: #ffffff;
box-sizing: border-box;
}
.car-type-list {
max-height: 300px;
overflow-y: scroll;
......@@ -481,7 +481,7 @@ export default {
font-size: 14px;
color: #666666;
> span {
>span {
margin-right: 20px;
margin-bottom: 10px;
}
......@@ -505,6 +505,7 @@ export default {
margin-bottom: 8px;
}
}
.remark-input {
width: 85%;
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!