提交 8066864f authored 作者: lidongxu's avatar lidongxu

refactor(display_schedule): 修复:链路中心_AP 上报_平铺模式纯表格,填报模式添加表单

上级 936718d3
......@@ -43,7 +43,7 @@
</span>
</template>
<template #default="{ row }">
<div v-if="col.type === 'select'"
<div v-if="col.type === 'select' && operation === '填报模式'"
class="cell-style">
<!-- 实际主货架-数量(要根据实际主货架-形式不为空时才可以选择否则为 0) -->
<div v-if="col.prop === 'actualMainShelfQty'">
......@@ -78,7 +78,7 @@
{{ col.func(row) }}
</div>
<!-- 输入框 -->
<div v-else-if="col.type === 'input'"
<div v-else-if="col.type === 'input' && operation === '填报模式'"
class="cell-style">
<div>
<span>{{ row[col.referenceKey] || '-' }}</span>
......@@ -87,7 +87,6 @@
placeholder=""
@input="submitChange(row, col)" />
</div>
</div>
<!-- 为其他类型或未定义类型提供默认显示 -->
<div v-else>
......@@ -117,37 +116,204 @@ const operation = ref('平铺模式');
const tableRef = ref(null)
// 全部列
const baseColumns = ref([
// 一级类
{
label: "基础信息",
label: "基础信息", // 类型标题
children: [
{ label: '计划月份', prop: 'salesMonth', visible: true, type: 'string', fill: false, fixed: 'left' },
{ label: "销售大区", prop: "regionName", visible: true, type: 'string', fill: false },
{ label: "销售战区", prop: "districtName", visible: true, type: 'string', fill: false },
{ label: "经销商-省份", prop: "dealerProvince", visible: true, type: 'string', fill: false },
{ label: "经销商-城市", prop: "dealerCity", visible: true, type: 'string', fill: false },
{ label: "经销商-代码", prop: "dealerCode", visible: true, type: 'string', fill: false },
{ label: "经销商-类型", prop: "dealerType", visible: true, type: 'string', fill: false },
{ label: "开户日期", prop: "openingDate", visible: true, type: 'string', fill: false },
{ label: "闭户日期", prop: "closingDate", visible: true, type: 'string', fill: false },
{ label: "大区总监", prop: "regionManager", visible: true, type: 'string', fill: false },
{ label: "战区经理", prop: "districtManager", visible: true, type: 'string', fill: false },
{ label: "城市经理", prop: "cityManager", visible: true, type: 'string', fill: false },
{ label: "门店名称", prop: "storeName", visible: true, type: 'string', fill: true, fixed: 'left' },
{ label: "门店编码", prop: "storeCode", visible: true, type: 'string', fill: true, fixed: 'left' },
{ label: "经销商名称", prop: "dealerName", visible: true, type: 'string', fill: true, fixed: 'left' },
{ label: "系统类型", prop: "lineType", visible: true, type: 'string', fill: true, fixed: 'left' },
{ label: "门店-省份", prop: "storeProvince", visible: true, type: 'string', fill: false },
{ label: "门店-城市", prop: "storeCity", visible: true, type: 'string', fill: false },
{ label: "系统名称", prop: "lineName", visible: true, type: 'string', fill: true },
{ label: "渠道大类", prop: "channelDl", visible: true, type: 'string', fill: false },
{ label: "渠道小类", prop: "channelXl", visible: true, type: 'string', fill: false },
{ label: "门店类型", prop: "storeType", visible: true, type: 'string', fill: false },
{ label: "系统业态", prop: "systemFormat", visible: true, type: 'string', fill: false },
{ label: "门店面积", prop: "storeArea", visible: true, type: 'string', fill: false },
{ label: "门店分级(销量坎级)", prop: "storeLevel", visible: true, type: 'string', fill: false },
{ label: "门店地址", prop: "storeAddress", visible: true, type: 'string', fill: false },
{ label: "品项数", prop: "productCount", visible: true, type: 'string', fill: false }
{
label: '计划月份', // 列标题
prop: 'salesMonth', // 列属性
visible: true, // 是否显示
type: 'string', // 列类型
fill: false, // 是否为填报列
fixed: 'left' // 是否固定在左侧
},
{
label: "销售大区",
prop: "regionName",
visible: true,
type: 'string',
fill: false
},
{
label: "销售战区",
prop: "districtName",
visible: true,
type: 'string',
fill: false
},
{
label: "经销商-省份",
prop: "dealerProvince",
visible: true,
type: 'string',
fill: false
},
{
label: "经销商-城市",
prop: "dealerCity",
visible: true,
type: 'string',
fill: false
},
{
label: "经销商-代码",
prop: "dealerCode",
visible: true,
type: 'string',
fill: false
},
{
label: "经销商-类型",
prop: "dealerType",
visible: true,
type: 'string',
fill: false
},
{
label: "开户日期",
prop: "openingDate",
visible: true,
type: 'string',
fill: false
},
{
label: "闭户日期",
prop: "closingDate",
visible: true,
type: 'string',
fill: false
},
{
label: "大区总监",
prop: "regionManager",
visible: true,
type: 'string',
fill: false
},
{
label: "战区经理",
prop: "districtManager",
visible: true,
type: 'string',
fill: false
},
{
label: "城市经理",
prop: "cityManager",
visible: true,
type: 'string',
fill: false
},
{
label: "门店名称",
prop: "storeName",
visible: true,
type: 'string',
fill: true,
fixed: 'left'
},
{
label: "门店编码",
prop: "storeCode",
visible: true,
type: 'string',
fill: true,
fixed: 'left'
},
{
label: "经销商名称",
prop: "dealerName",
visible: true,
type: 'string',
fill: true,
fixed: 'left'
},
{
label: "系统类型",
prop: "lineType",
visible: true,
type: 'string',
fill: true,
fixed: 'left'
},
{
label: "门店-省份",
prop: "storeProvince",
visible: true,
type: 'string',
fill: false
},
{
label: "门店-城市",
prop: "storeCity",
visible: true,
type: 'string',
fill: false
},
{
label: "系统名称",
prop: "lineName",
visible: true,
type: 'string',
fill: true
},
{
label: "渠道大类",
prop: "channelDl",
visible: true,
type: 'string',
fill: false
},
{
label: "渠道小类",
prop: "channelXl",
visible: true,
type: 'string',
fill: false
},
{
label: "门店类型",
prop: "storeType",
visible: true,
type: 'string',
fill: false
},
{
label: "系统业态",
prop: "systemFormat",
visible: true,
type: 'string',
fill: false
},
{
label: "门店面积",
prop: "storeArea",
visible: true,
type: 'string',
fill: false
},
{
label: "门店分级(销量坎级)",
prop: "storeLevel",
visible: true,
type: 'string',
fill: false
},
{
label: "门店地址",
prop: "storeAddress",
visible: true,
type: 'string',
fill: false
},
{
label: "品项数",
prop: "productCount",
visible: true,
type: 'string',
fill: false
}
],
prop: 'baseColumns',
visible: true
......@@ -155,8 +321,20 @@ const baseColumns = ref([
{
label: "大业态测试",
children: [
{ label: "大业态测试-动销模型", prop: "lfSalesModel", visible: true, type: 'string', fill: false },
{ label: "大业态测试-月均POS", prop: "lfMonthlyPos", visible: true, type: 'string', fill: false },
{
label: "大业态测试-动销模型",
prop: "lfSalesModel",
visible: true,
type: 'string',
fill: false
},
{
label: "大业态测试-月均POS",
prop: "lfMonthlyPos",
visible: true,
type: 'string',
fill: false
}
],
prop: 'lfColumns',
visible: true
......@@ -165,10 +343,34 @@ const baseColumns = ref([
label: "费用计划",
prop: 'fpColumns',
children: [
// { label: "计划主货架-形式", prop: "plannedMainShelfType", visible: true, type: 'string' },
// { label: "计划主货架-数量", prop: "plannedMainShelfQty", visible: true, type: 'string' },
{ label: "计划主货架-单个费用", prop: "plannedMainShelfUnitCost", visible: true, type: 'string', fill: false },
{ label: "计划主货架-总费用", prop: "plannedMainShelfTotalCost", visible: true, type: 'string', fill: false },
{
label: "计划主货架-形式",
prop: "plannedMainShelfType",
visible: true,
type: 'string',
fill: false
},
{
label: "计划主货架-数量",
prop: "plannedMainShelfQty",
visible: true,
type: 'string',
fill: false
},
{
label: "计划主货架-单个费用",
prop: "plannedMainShelfUnitCost",
visible: true,
type: 'string',
fill: false
},
{
label: "计划主货架-总费用",
prop: "plannedMainShelfTotalCost",
visible: true,
type: 'string',
fill: false
},
{
label: "实际主货架-形式",
prop: "actualMainShelfType",
......@@ -200,7 +402,7 @@ const baseColumns = ref([
label: "实际主货架-是否执行",
prop: "actualMainShelfExecuted",
visible: true,
type: 'formula', // 公式
type: 'formula',
func: (row) => {
row.actualMainShelfExecuted = ((parseInt(row.actualMainShelfType) >= parseInt(row.plannedMainShelfType)) && (parseInt(row.actualMainShelfQty) >= parseInt(row.plannedMainShelfQty))) ? '是' : '否';
return row.actualMainShelfExecuted;
......@@ -208,16 +410,22 @@ const baseColumns = ref([
formulaStr: '公式:(实际主货架形式 >= 计划主货架形式)并且(实际主货架数量 >= 计划主货架数量)',
fill: true
},
// {
// label: "计划端架-数量", prop: "plannedEndCapQty", visible: true, type: 'string',
// fill: true
// },
{
label: "计划端架-总费用", prop: "plannedEndCapTotalCost", visible: true, type: 'string',
label: "计划端架-数量", prop: "plannedEndCapQty", visible: true, type: 'string',
fill: false
},
{
label: "计划端架-总费用",
prop: "plannedEndCapTotalCost",
visible: true,
type: 'string',
fill: false
},
{
label: "计划端架-单个费用", prop: "plannedEndCapUnitCost", visible: true, type: 'string',
label: "计划端架-单个费用",
prop: "plannedEndCapUnitCost",
visible: true,
type: 'string',
fill: false
},
{
......@@ -238,7 +446,7 @@ const baseColumns = ref([
label: "实际端架-是否执行",
prop: "actualEndCapExecuted",
visible: true,
type: 'formula', // 公式
type: 'formula',
func: (row) => {
row.actualEndCapExecuted = ((parseFloat(row.actualEndCapQty) >= parseFloat(row.plannedEndCapQty))) ? '是' : '否';
return row.actualEndCapExecuted;
......@@ -254,19 +462,31 @@ const baseColumns = ref([
fill: true
},
{
label: "计划地堆-数量", prop: "plannedFloorStackQty", visible: true, type: 'string',
label: "计划地堆-数量",
prop: "plannedFloorStackQty",
visible: true,
type: 'string',
fill: true
},
{
label: "计划主题地堆-是否", prop: "plannedThemedFloorStack", visible: true, type: 'string',
label: "计划主题地堆-是否",
prop: "plannedThemedFloorStack",
visible: true,
type: 'string',
fill: true
},
{
label: "计划地堆-总费用", prop: "plannedFloorStackTotalCost", visible: true, type: 'string',
label: "计划地堆-总费用",
prop: "plannedFloorStackTotalCost",
visible: true,
type: 'string',
fill: false
},
{
label: "计划折算1㎡-单个费用", prop: "plannedFloorStackUnitCostPerSqm", visible: true, type: 'string',
label: "计划折算1㎡-单个费用",
prop: "plannedFloorStackUnitCostPerSqm",
visible: true,
type: 'string',
fill: false
},
{
......@@ -281,7 +501,7 @@ const baseColumns = ref([
{ label: '1', value: 1 },
{ label: '2', value: 2 },
{ label: '3', value: 3 },
{ label: '4', value: 4 },
{ label: '4', value: 4 }
],
referenceKey: "plannedFloorStackArea",
fill: true
......@@ -307,7 +527,7 @@ const baseColumns = ref([
type: 'select',
options: [
{ label: '是', value: '是' },
{ label: '否', value: '否' },
{ label: '否', value: '否' }
],
referenceKey: "plannedThemedFloorStack",
fill: true
......@@ -316,7 +536,7 @@ const baseColumns = ref([
label: "实际地堆是否执行",
prop: "actualFloorStackExecuted",
visible: true,
type: 'formula', // 公式
type: 'formula',
func: (row) => {
row.actualFloorStackExecuted = ((parseFloat(row.actualFloorStackArea) >= parseFloat(row.plannedFloorStackArea)) && (parseInt(row.actualFloorStackQty) >= parseInt(row.plannedFloorStackQty))) ? '是' : '否';
return row.actualFloorStackExecuted;
......@@ -324,12 +544,18 @@ const baseColumns = ref([
formulaStr: '公式:(实际地堆平米数 >= 计划地堆平米数)并且(实际地堆数量 >= 计划地堆数量)',
fill: true
},
// {
// label: "计划多点陈列-数量+形式", prop: "plannedMultiDisplay", visible: true, type: 'string',
// fill: true
// },
{
label: "计划多点陈列-总费用", prop: "plannedMultiDisplayTotalCost", visible: true, type: 'string',
label: "计划多点陈列-数量+形式",
prop: "plannedMultiDisplay",
visible: true,
type: 'string',
fill: false
},
{
label: "计划多点陈列-总费用",
prop: "plannedMultiDisplayTotalCost",
visible: true,
type: 'string',
fill: false
},
{
......@@ -351,23 +577,29 @@ const baseColumns = ref([
type: 'select',
options: [
{ label: '是', value: '是' },
{ label: '否', value: '否' },
{ label: '否', value: '否' }
],
fill: true
},
{
label: "合计费用-费用", prop: "totalCost", visible: true, type: 'string',
label: "合计费用-费用",
prop: "totalCost",
visible: true,
type: 'string',
fill: false
},
{
label: "合计费用-费率", prop: "totalCostRate", visible: true, type: 'string',
label: "合计费用-费率",
prop: "totalCostRate",
visible: true,
type: 'string',
fill: false
},
{
label: "常规陈列是否执行",
prop: "regularDisplayExecuted",
visible: true,
type: 'formula', // 公式
type: 'formula',
func: (row) => {
// 实际主货架-是否执行 && 实际端架-是否执行 && 实际地堆-是否执行 && 实际多点陈列-是否执行
row.regularDisplayExecuted = (row.actualMainShelfExecuted === '是' && row.actualEndCapExecuted === '是' && row.actualFloorStackExecuted === '是' && row.actualMultiDisplayExecuted === '是') ? '是' : '否';
......@@ -377,19 +609,31 @@ const baseColumns = ref([
fill: true
},
{
label: "综合标签-拜访辅助列", prop: "visitAssistTag", visible: true, type: 'string',
label: "综合标签-拜访辅助列",
prop: "visitAssistTag",
visible: true,
type: 'string',
fill: false
},
{
label: "付费陈列- 是否", prop: "paidDisplay", visible: true, type: 'string',
label: "付费陈列- 是否",
prop: "paidDisplay",
visible: true,
type: 'string',
fill: false
},
{
label: "当月拜访目标", prop: "monthlyVisitTarget", visible: true, type: 'string',
label: "当月拜访目标",
prop: "monthlyVisitTarget",
visible: true,
type: 'string',
fill: false
},
{
label: "当月是否拜访", prop: "monthlyVisited", visible: true, type: 'string',
label: "当月是否拜访",
prop: "monthlyVisited",
visible: true,
type: 'string',
fill: false
}
],
......@@ -497,7 +741,7 @@ const tableData = ref([])
const isLoading = ref(true)
const params = reactive({
pageNum: 1,
pageSize: 10,
pageSize: 20,
})
const total = ref(0)
......@@ -521,67 +765,67 @@ getTableList()
const getColumnMinWidth = (column) => {
// 根据列名或属性判断合适的最小宽度
const widthMap = {
'salesMonth': 85,
'regionName': 85,
'districtName': 85,
'dealerProvince': 100,
'dealerCity': 100,
'dealerCode': 100,
'dealerName': 210,
'dealerType': 140,
'openingDate': 100,
'closingDate': 100,
'regionManager': 85,
'districtManager': 85,
'cityManager': 85,
'storeCode': 100,
'storeName': 170,
'storeProvince': 85,
'storeCity': 85,
'lineName': 85,
'lineType': 85,
'channelDl': 85,
'channelXl': 135,
'storeType': 85,
'systemFormat': 85,
'storeArea': 85,
'storeLevel': 160,
'storeAddress': 250,
'productCount': 75,
'lfSalesModel': 150,
'lfMonthlyPos': 150,
'plannedMainShelfType': 125,
'plannedMainShelfQty': 125,
'plannedMainShelfUnitCost': 150,
'plannedMainShelfTotalCost': 140,
'actualMainShelfType': 135,
'actualMainShelfQty': 125,
'actualMainShelfExecuted': 165,
'plannedEndCapQty': 110,
'plannedEndCapTotalCost': 125,
'plannedEndCapUnitCost': 135,
'actualEndCapQty': 110,
'actualEndCapExecuted': 150,
'plannedFloorStackArea': 165,
'plannedFloorStackQty': 110,
'plannedThemedFloorStack': 135,
'plannedFloorStackTotalCost': 125,
'plannedFloorStackUnitCostPerSqm': 155,
'actualFloorStackArea': 165,
'actualFloorStackQty': 110,
'actualThemedFloorStack': 135,
'actualFloorStackExecuted': 145,
'plannedMultiDisplay': 170,
'plannedMultiDisplayTotalCost': 150,
'actualMultiDisplay': 170,
'actualMultiDisplayExecuted': 165,
'totalCost': 110,
'totalCostRate': 110,
'regularDisplayExecuted': 145,
'visitAssistTag': 155,
'paidDisplay': 115,
'monthlyVisitTarget': 105,
'monthlyVisited': 105
'salesMonth': 90,
'regionName': 90,
'districtName': 90,
'dealerProvince': 105,
'dealerCity': 105,
'dealerCode': 105,
'dealerName': 215,
'dealerType': 145,
'openingDate': 105,
'closingDate': 105,
'regionManager': 90,
'districtManager': 90,
'cityManager': 90,
'storeCode': 105,
'storeName': 175,
'storeProvince': 90,
'storeCity': 90,
'lineName': 90,
'lineType': 90,
'channelDl': 90,
'channelXl': 140,
'storeType': 90,
'systemFormat': 90,
'storeArea': 90,
'storeLevel': 165,
'storeAddress': 255,
'productCount': 80,
'lfSalesModel': 155,
'lfMonthlyPos': 155,
'plannedMainShelfType': 130,
'plannedMainShelfQty': 130,
'plannedMainShelfUnitCost': 155,
'plannedMainShelfTotalCost': 145,
'actualMainShelfType': 140,
'actualMainShelfQty': 130,
'actualMainShelfExecuted': 170,
'plannedEndCapQty': 115,
'plannedEndCapTotalCost': 130,
'plannedEndCapUnitCost': 140,
'actualEndCapQty': 115,
'actualEndCapExecuted': 155,
'plannedFloorStackArea': 170,
'plannedFloorStackQty': 115,
'plannedThemedFloorStack': 140,
'plannedFloorStackTotalCost': 130,
'plannedFloorStackUnitCostPerSqm': 160,
'actualFloorStackArea': 170,
'actualFloorStackQty': 115,
'actualThemedFloorStack': 140,
'actualFloorStackExecuted': 150,
'plannedMultiDisplay': 175,
'plannedMultiDisplayTotalCost': 155,
'actualMultiDisplay': 175,
'actualMultiDisplayExecuted': 170,
'totalCost': 115,
'totalCostRate': 115,
'regularDisplayExecuted': 150,
'visitAssistTag': 160,
'paidDisplay': 120,
'monthlyVisitTarget': 110,
'monthlyVisited': 110
};
return widthMap[column.prop] || 100; // 默认宽度
......
......@@ -43,7 +43,7 @@
</span>
</template>
<template #default="{ row }">
<div v-if="col.type === 'select'"
<div v-if="col.type === 'select' && operation === '填报模式'"
class="cell-style">
<div>
<el-tooltip effect="dark"
......@@ -69,7 +69,7 @@
{{ col.func(row) }}
</div>
<!-- 输入框 -->
<div v-else-if="col.type === 'input'"
<div v-else-if="col.type === 'input' && operation === '填报模式'"
class="cell-style">
<div>
<el-tooltip effect="dark"
......@@ -86,7 +86,7 @@
</div>
</div>
<!-- 日期选择 -->
<div v-else-if="col.type === 'date'"
<div v-else-if="col.type === 'date' && operation === '填报模式'"
class="cell-style">
<div>
<span class="ellipsis-tooltip">{{ row[col.referenceKey] || '-' }}</span>
......@@ -131,25 +131,142 @@ const baseColumns = ref([
{
label: "基础信息",
children: [
{ label: '计划月份', prop: 'salesMonth', visible: true, type: 'string', fill: false, fixed: 'left' },
{ "label": "销售大区", "prop": "regionName", visible: true, type: "string", fill: false },
{ "label": "销售战区", "prop": "districtName", visible: true, type: "string", fill: false },
{ "label": "经销商-省份", "prop": "dealerProvince", visible: true, type: "string", fill: false },
{ "label": "经销商-城市", "prop": "dealerCity", visible: true, type: "string", fill: false },
{ "label": "经销商-代码", "prop": "dealerCode", visible: true, type: "string", fill: false },
{ "label": "经销商名称", "prop": "dealerName", visible: true, type: "string", fill: true, fixed: 'left' },
{ "label": "经销商类型", "prop": "dealerType", visible: true, type: "string", fill: false },
{ "label": "开户日期", "prop": "openingDate", visible: true, type: "string", fill: false },
{ "label": "闭户日期", "prop": "closingDate", visible: true, type: "string", fill: false },
{ "label": "大区总监", "prop": "regionManager", visible: true, type: "string", fill: false },
{ "label": "战区经理", "prop": "districtManager", visible: true, type: "string", fill: false },
{ "label": "城市经理", "prop": "cityManager", visible: true, type: "string", fill: false },
{ "label": "系统名称", "prop": "lineName", visible: true, type: "string", fill: true, fixed: 'left' },
{ "label": "系统类型", "prop": "lineType", visible: true, type: "string", fill: false },
{ "label": "渠道大类", "prop": "channelDl", visible: true, type: "string", fill: false },
{ "label": "渠道小类", "prop": "channelXl", visible: true, type: "string", fill: false },
{ "label": "系统业态", "prop": "lineLf", visible: true, type: "string", fill: false },
{ "label": "门店数", "prop": "storeCount", visible: true, type: "string", fill: false }
{
label: '计划月份',
prop: 'salesMonth',
visible: true,
type: 'string',
fill: false,
fixed: 'left'
},
{
label: "销售大区",
prop: "regionName",
visible: true,
type: "string",
fill: false
},
{
label: "销售战区",
prop: "districtName",
visible: true,
type: "string",
fill: false
},
{
label: "经销商-省份",
prop: "dealerProvince",
visible: true,
type: "string",
fill: false
},
{
label: "经销商-城市",
prop: "dealerCity",
visible: true,
type: "string",
fill: false
},
{
label: "经销商-代码",
prop: "dealerCode",
visible: true,
type: "string",
fill: false
},
{
label: "经销商名称",
prop: "dealerName",
visible: true,
type: "string",
fill: true,
fixed: 'left'
},
{
label: "经销商类型",
prop: "dealerType",
visible: true,
type: "string",
fill: false
},
{
label: "开户日期",
prop: "openingDate",
visible: true,
type: "string",
fill: false
},
{
label: "闭户日期",
prop: "closingDate",
visible: true,
type: "string",
fill: false
},
{
label: "大区总监",
prop: "regionManager",
visible: true,
type: "string",
fill: false
},
{
label: "战区经理",
prop: "districtManager",
visible: true,
type: "string",
fill: false
},
{
label: "城市经理",
prop: "cityManager",
visible: true,
type: "string",
fill: false
},
{
label: "系统名称",
prop: "lineName",
visible: true,
type: "string",
fill: true,
fixed: 'left'
},
{
label: "系统类型",
prop: "lineType",
visible: true,
type: "string",
fill: false
},
{
label: "渠道大类",
prop: "channelDl",
visible: true,
type: "string",
fill: false
},
{
label: "渠道小类",
prop: "channelXl",
visible: true,
type: "string",
fill: false
},
{
label: "系统业态",
prop: "lineLf",
visible: true,
type: "string",
fill: false
},
{
label: "门店数",
prop: "storeCount",
visible: true,
type: "string",
fill: false
}
],
prop: 'baseColumns',
visible: true
......@@ -157,38 +274,80 @@ const baseColumns = ref([
{
label: "档期基础信息",
children: [
{ "label": "档期执行月份", "prop": "promotionExecutionMonth", visible: true, type: "string", fill: false },
{ "label": "档期计划-促销规格", "prop": "plannedPromotionSpec", visible: true, type: "string", fill: false },
{ "label": "档期计划-促销口味", "prop": "plannedPromotionFlavor", visible: true, type: "string", fill: false },
{
"label": "档期执行-促销规格",
"prop": "actualPromotionSpec",
label: "档期执行月份",
prop: "promotionExecutionMonth",
visible: true,
type: "string",
fill: false
},
{
label: "档期计划-促销规格",
prop: "plannedPromotionSpec",
visible: true,
type: "string",
fill: false
},
{
label: "档期计划-促销口味",
prop: "plannedPromotionFlavor",
visible: true,
type: "string",
fill: false
},
{
label: "档期执行-促销规格",
prop: "actualPromotionSpec",
visible: true,
type: 'select',
options: [
{ label: '虎皮105g', value: '虎皮105g' },
{ label: '虎皮210g', value: '虎皮210g' },
{ label: '去骨72g', value: '去骨72g' },
{ label: '去骨138g', value: '去骨138g' },
{ label: '小鸡腿80g', value: '小鸡腿80g' },
{ label: '老卤95g', value: '老卤95g' },
{ label: '鸡肉豆堡', value: '鸡肉豆堡' },
{ label: '牛肉豆堡', value: '牛肉豆堡' },
{
label: '虎皮105g',
value: '虎皮105g'
},
{
label: '虎皮210g',
value: '虎皮210g'
},
{
label: '去骨72g',
value: '去骨72g'
},
{
label: '去骨138g',
value: '去骨138g'
},
{
label: '小鸡腿80g',
value: '小鸡腿80g'
},
{
label: '老卤95g',
value: '老卤95g'
},
{
label: '鸡肉豆堡',
value: '鸡肉豆堡'
},
{
label: '牛肉豆堡',
value: '牛肉豆堡'
}
],
referenceKey: "plannedPromotionSpec",
fill: true
},
{
"label": "档期执行-促销口味",
"prop": "actualPromotionFlavor",
label: "档期执行-促销口味",
prop: "actualPromotionFlavor",
visible: true,
type: 'input',
referenceKey: "plannedPromotionFlavor",
fill: true
},
{
"label": "档期规格是否执行",
"prop": "specExecutionStatus",
label: "档期规格是否执行",
prop: "specExecutionStatus",
visible: true,
type: 'formula',
func: (row) => {
......@@ -197,7 +356,7 @@ const baseColumns = ref([
},
formulaStr: '公式:(档期计划促销规格 = 档期执行促销规格)',
fill: true
},
}
],
prop: 'scheduleInfo',
visible: true
......@@ -206,8 +365,20 @@ const baseColumns = ref([
label: "合计费用",
prop: 'totalCostParent',
children: [
{ "label": "合计费用", "prop": "totalCost", visible: true, type: "string", fill: false },
{ "label": "合计费率", "prop": "totalCostRate", visible: true, type: "string", fill: false },
{
label: "合计费用",
prop: "totalCost",
visible: true,
type: "string",
fill: false
},
{
label: "合计费率",
prop: "totalCostRate",
visible: true,
type: "string",
fill: false
}
],
visible: true
},
......@@ -215,40 +386,76 @@ const baseColumns = ref([
label: "促销计划",
prop: 'promotionPlan',
children: [
{ "label": "计划-档期形式", "prop": "plannedPromotionFormat", visible: true, type: "string", fill: false },
{ "label": "计划-核销方式", "prop": "plannedVerificationMethod", visible: true, type: "string", fill: false },
{ "label": "计划-档期规则", "prop": "plannedPromotionRules", visible: true, type: "string", fill: false },
{ "label": "计划-档期前补差天数", "prop": "plannedPrePromotionAdjustDays", visible: true, type: "string", fill: false },
{ "label": "计划-档期后补差天数", "prop": "plannedPostPromotionAdjustDays", visible: true, type: "string", fill: false },
{
"label": "计划-档期开始时间",
"prop": "plannedPromotionStartDate",
label: "计划-档期形式",
prop: "plannedPromotionFormat",
visible: true,
type: "string",
fill: false
},
{
"label": "实际-档期开始时间",
"prop": "actualPromotionStartDate",
label: "计划-核销方式",
prop: "plannedVerificationMethod",
visible: true,
type: "string",
fill: false
},
{
label: "计划-档期规则",
prop: "plannedPromotionRules",
visible: true,
type: "string",
fill: false
},
{
label: "计划-档期前补差天数",
prop: "plannedPrePromotionAdjustDays",
visible: true,
type: "string",
fill: false
},
{
label: "计划-档期后补差天数",
prop: "plannedPostPromotionAdjustDays",
visible: true,
type: "string",
fill: false
},
{
label: "计划-档期开始时间",
prop: "plannedPromotionStartDate",
visible: true,
type: "string",
fill: false
},
{
label: "实际-档期开始时间",
prop: "actualPromotionStartDate",
visible: true,
type: 'date',
format: 'MM-DD',
referenceKey: "plannedPromotionStartDate",
fill: true
},
{ "label": "计划-档期结束时间", "prop": "plannedPromotionEndDate", visible: true, type: "string", fill: false },
{
"label": "实际-档期结束时间",
"prop": "actualPromotionEndDate",
label: "计划-档期结束时间",
prop: "plannedPromotionEndDate",
visible: true,
type: "string",
fill: false
},
{
label: "实际-档期结束时间",
prop: "actualPromotionEndDate",
visible: true,
type: 'date',
format: 'MM-DD',
fill: true,
referenceKey: "plannedPromotionEndDate",
referenceKey: "plannedPromotionEndDate"
},
{
"label": "档期是否开展",
"prop": "promotionImplementationStatus",
label: "档期是否开展",
prop: "promotionImplementationStatus",
visible: true,
type: 'formula',
func: (row) => {
......@@ -259,8 +466,8 @@ const baseColumns = ref([
fill: true
},
{
"label": "时间是否执行",
"prop": "timeExecutionStatus",
label: "时间是否执行",
prop: "timeExecutionStatus",
visible: true,
type: 'formula',
func: (row) => {
......@@ -270,51 +477,106 @@ const baseColumns = ref([
formulaStr: '公式:(实际档期开始时间 = 计划档期开始时间,并且实际档期结束时间 = 计划档期结束时间)',
fill: true
},
{ "label": "计划-补差开始时间", "prop": "plannedAdjustmentStartDate", visible: true, type: "string", fill: false },
{ "label": "计划-补差结束时间", "prop": "plannedAdjustmentEndDate", visible: true, type: "string", fill: false },
{ "label": "计划促销机制", "prop": "plannedPromotionMechanism", visible: true, type: "string", fill: false },
{
"label": "实际促销机制",
"prop": "actualPromotionMechanism",
label: "计划-补差开始时间",
prop: "plannedAdjustmentStartDate",
visible: true,
type: "string",
fill: false
},
{
label: "计划-补差结束时间",
prop: "plannedAdjustmentEndDate",
visible: true,
type: "string",
fill: false
},
{
label: "计划促销机制",
prop: "plannedPromotionMechanism",
visible: true,
type: "string",
fill: false
},
{
label: "实际促销机制",
prop: "actualPromotionMechanism",
visible: true,
type: 'input',
fill: true
},
{
"label": "促销机制是否执行",
"prop": "promotionMechanismExecutionStatus",
label: "促销机制是否执行",
prop: "promotionMechanismExecutionStatus",
visible: true,
type: 'select',
options: [
{ label: '是', value: '是' },
{ label: '否', value: '否' },
{
label: '是',
value: '是'
},
{
label: '否',
value: '否'
}
],
fill: true
},
{ "label": "预估袋数", "prop": "estimatedBagCount", visible: true, type: "string", fill: false },
{
"label": "档期备货量(袋)",
"prop": "promotionStockQuantity",
label: "预估袋数",
prop: "estimatedBagCount",
visible: true,
type: "string",
fill: false
},
{
label: "档期备货量(袋)",
prop: "promotionStockQuantity",
visible: true,
type: 'input',
format: 'number',
fill: true
},
{ "label": "单包厂价(单包)", "prop": "unitFactoryPrice", visible: true, type: "string", fill: false },
{ "label": "正常供价(单包)", "prop": "normalSupplyPrice", visible: true, type: "string", fill: false },
{ "label": "日常零售价(单包)", "prop": "regularRetailPrice", visible: true, type: "string", fill: false },
{ "label": "计划促销售价(单包)", "prop": "plannedPromotionPrice", visible: true, type: "string", fill: false },
{
"label": "实际促销售价(单包)",
"prop": "actualPromotionPrice",
label: "单包厂价(单包)",
prop: "unitFactoryPrice",
visible: true,
type: "string",
fill: false
},
{
label: "正常供价(单包)",
prop: "normalSupplyPrice",
visible: true,
type: "string",
fill: false
},
{
label: "日常零售价(单包)",
prop: "regularRetailPrice",
visible: true,
type: "string",
fill: false
},
{
label: "计划促销售价(单包)",
prop: "plannedPromotionPrice",
visible: true,
type: "string",
fill: false
},
{
label: "实际促销售价(单包)",
prop: "actualPromotionPrice",
visible: true,
type: 'input',
format: 'number',
fill: true
},
{
"label": "促销价是否执行",
"prop": "promotionPriceExecutionStatus", visible: true,
label: "促销价是否执行",
prop: "promotionPriceExecutionStatus",
visible: true,
type: 'formula',
func: (row) => {
row.promotionPriceExecutionStatus = row.plannedPromotionPrice == row.actualPromotionPrice ? '是' : '否';
......@@ -323,17 +585,65 @@ const baseColumns = ref([
formulaStr: '公式:(计划促销售价 = 实际促销售价)',
fill: true
},
{ "label": "正常经销商毛利现状", "prop": "normalDealerMarginStatus", visible: true, type: "string", fill: false },
{ "label": "系统前台毛利保证", "prop": "systemFrontendMarginGuarantee", visible: true, type: "string", fill: false },
{ "label": "系统后台毛利保证", "prop": "systemBackendMarginGuarantee", visible: true, type: "string", fill: false },
{ "label": "系统促销毛利保证", "prop": "systemPromotionMarginGuarantee", visible: true, type: "string", fill: false },
{ "label": "经销商毛利保证", "prop": "dealerMarginGuarantee", visible: true, type: "string", fill: false },
{ "label": "单袋补差金额(费用)", "prop": "unitBagAdjustmentAmount", visible: true, type: "string", fill: false },
{ "label": "补差费比(%)", "prop": "adjustmentCostRatio", visible: true, type: "string", fill: false },
{ "label": "整体补差(费用)", "prop": "totalAdjustmentCost", visible: true, type: "string", fill: false },
{
"label": "档期是否执行",
"prop": "promotionExecutionStatus",
label: "正常经销商毛利现状",
prop: "normalDealerMarginStatus",
visible: true,
type: "string",
fill: false
},
{
label: "系统前台毛利保证",
prop: "systemFrontendMarginGuarantee",
visible: true,
type: "string",
fill: false
},
{
label: "系统后台毛利保证",
prop: "systemBackendMarginGuarantee",
visible: true,
type: "string",
fill: false
},
{
label: "系统促销毛利保证",
prop: "systemPromotionMarginGuarantee",
visible: true,
type: "string",
fill: false
},
{
label: "经销商毛利保证",
prop: "dealerMarginGuarantee",
visible: true,
type: "string",
fill: false
},
{
label: "单袋补差金额(费用)",
prop: "unitBagAdjustmentAmount",
visible: true,
type: "string",
fill: false
},
{
label: "补差费比(%)",
prop: "adjustmentCostRatio",
visible: true,
type: "string",
fill: false
},
{
label: "整体补差(费用)",
prop: "totalAdjustmentCost",
visible: true,
type: "string",
fill: false
},
{
label: "档期是否执行",
prop: "promotionExecutionStatus",
visible: true,
type: 'formula',
func: (row) => {
......@@ -343,29 +653,48 @@ const baseColumns = ref([
},
formulaStr: '公式:(促销价是否执行 = 是,并且促销机制是否执行 = 是,并且促销规格是否执行 = 是,并且档期是否开展 = 是)',
fill: true
},
}
],
visible: true
}, {
},
{
label: "海报计划",
prop: 'posterPlan',
children: [
{ "label": "计划-海报形式", "prop": "plannedPosterFormat", visible: true, type: "string", fill: false },
{ "label": "计划-海报费用", "prop": "plannedPosterCost", visible: true, type: "string", fill: false },
{
"label": "实际-海报形式",
"prop": "actualPosterFormat",
label: "计划-海报形式",
prop: "plannedPosterFormat",
visible: true,
type: "string",
fill: false
},
{
label: "计划-海报费用",
prop: "plannedPosterCost",
visible: true,
type: "string",
fill: false
},
{
label: "实际-海报形式",
prop: "actualPosterFormat",
visible: true,
type: 'select',
options: [
{ label: '电子', value: '电子' },
{ label: '纸制', value: '纸制' }
{
label: '电子',
value: '电子'
},
{
label: '纸制',
value: '纸制'
}
],
fill: true
},
{
"label": "海报是否执行",
"prop": "posterExecutionStatus",
label: "海报是否执行",
prop: "posterExecutionStatus",
visible: true,
type: 'formula',
func: (row) => {
......@@ -374,7 +703,7 @@ const baseColumns = ref([
},
formulaStr: '公式:(计划海报形式 = 实际海报形式)',
fill: true
},
}
],
visible: true
},
......@@ -382,9 +711,27 @@ const baseColumns = ref([
label: "档期陈列",
prop: 'displayPlan',
children: [
{ "label": "门店数", "prop": "storeCountInt", visible: true, type: "string", fill: false },
{ "label": "店均费用", "prop": "averageStoreCost", visible: true, type: "string", fill: false },
{ "label": "费用", "prop": "cost", visible: true, type: "string", fill: false },
{
label: "门店数",
prop: "storeCountInt",
visible: true,
type: "string",
fill: false
},
{
label: "店均费用",
prop: "averageStoreCost",
visible: true,
type: "string",
fill: false
},
{
label: "费用",
prop: "cost",
visible: true,
type: "string",
fill: false
}
],
visible: true
}
......@@ -496,7 +843,7 @@ const tableData = ref([])
const isLoading = ref(true)
const params = reactive({
pageNum: 1,
pageSize: 10,
pageSize: 20,
})
const total = ref(0)
......@@ -530,80 +877,78 @@ getTableList()
const getColumnMinWidth = (column) => {
// 根据列名或属性判断合适的最小宽度
const widthMap = {
'salesMonth': 85,
'regionName': 85,
'districtName': 85,
'dealerProvince': 100,
'dealerCity': 100,
'dealerCode': 100,
'dealerName': 210,
'dealerType': 110,
'openingDate': 100,
'closingDate': 100,
'regionManager': 85,
'districtManager': 85,
'cityManager': 85,
'lineName': 85,
'lineType': 85,
'channelDl': 85,
'channelXl': 135,
'lineLf': 85,
'storeCount': 70,
'promotionExecutionMonth': 105,
'plannedPromotionSpec': 135,
'plannedPromotionFlavor': 135,
'actualPromotionSpec': 135,
'actualPromotionFlavor': 135,
'specExecutionStatus': 145,
'totalCost': 100,
'totalCostRate': 80,
'plannedPromotionFormat': 110,
'plannedVerificationMethod': 110,
'plannedPromotionRules': 110,
'plannedPrePromotionAdjustDays': 150,
'plannedPostPromotionAdjustDays': 150,
'plannedPromotionStartDate': 135,
'actualPromotionStartDate': 135,
'plannedPromotionEndDate': 135,
'actualPromotionEndDate': 135,
'promotionImplementationStatus': 120,
'timeExecutionStatus': 120,
'plannedAdjustmentStartDate': 135,
'plannedAdjustmentEndDate': 135,
'plannedPromotionMechanism': 110,
'actualPromotionMechanism': 110,
'promotionMechanismExecutionStatus': 130,
'estimatedBagCount': 85,
'promotionStockQuantity': 130,
'unitFactoryPrice': 130,
'normalSupplyPrice': 130,
'regularRetailPrice': 145,
'plannedPromotionPrice': 160,
'actualPromotionPrice': 160,
'promotionPriceExecutionStatus': 135,
'normalDealerMarginStatus': 145,
'systemFrontendMarginGuarantee': 130,
'systemBackendMarginGuarantee': 130,
'systemPromotionMarginGuarantee': 130,
'dealerMarginGuarantee': 120,
'unitBagAdjustmentAmount': 160,
'adjustmentCostRatio': 120,
'totalAdjustmentCost': 130,
'promotionExecutionStatus': 120,
'plannedPosterFormat': 110,
'plannedPosterCost': 110,
'actualPosterFormat': 110,
'posterExecutionStatus': 120,
'storeCountInt': 70,
'averageStoreCost': 110,
'cost': 110
'salesMonth': 90,
'regionName': 90,
'districtName': 90,
'dealerProvince': 105,
'dealerCity': 105,
'dealerCode': 105,
'dealerName': 215,
'dealerType': 115,
'openingDate': 105,
'closingDate': 105,
'regionManager': 90,
'districtManager': 90,
'cityManager': 90,
'lineName': 90,
'lineType': 90,
'channelDl': 90,
'channelXl': 140,
'lineLf': 90,
'storeCount': 75,
'promotionExecutionMonth': 110,
'plannedPromotionSpec': 140,
'plannedPromotionFlavor': 140,
'actualPromotionSpec': 140,
'actualPromotionFlavor': 140,
'specExecutionStatus': 150,
'totalCost': 105,
'totalCostRate': 85,
'plannedPromotionFormat': 115,
'plannedVerificationMethod': 115,
'plannedPromotionRules': 115,
'plannedPrePromotionAdjustDays': 155,
'plannedPostPromotionAdjustDays': 155,
'plannedPromotionStartDate': 140,
'actualPromotionStartDate': 140,
'plannedPromotionEndDate': 140,
'actualPromotionEndDate': 140,
'promotionImplementationStatus': 125,
'timeExecutionStatus': 125,
'plannedAdjustmentStartDate': 140,
'plannedAdjustmentEndDate': 140,
'plannedPromotionMechanism': 115,
'actualPromotionMechanism': 115,
'promotionMechanismExecutionStatus': 135,
'estimatedBagCount': 90,
'promotionStockQuantity': 135,
'unitFactoryPrice': 135,
'normalSupplyPrice': 135,
'regularRetailPrice': 150,
'plannedPromotionPrice': 165,
'actualPromotionPrice': 165,
'promotionPriceExecutionStatus': 140,
'normalDealerMarginStatus': 150,
'systemFrontendMarginGuarantee': 135,
'systemBackendMarginGuarantee': 135,
'systemPromotionMarginGuarantee': 135,
'dealerMarginGuarantee': 125,
'unitBagAdjustmentAmount': 165,
'adjustmentCostRatio': 125,
'totalAdjustmentCost': 135,
'promotionExecutionStatus': 125,
'plannedPosterFormat': 115,
'plannedPosterCost': 115,
'actualPosterFormat': 115,
'posterExecutionStatus': 125,
'storeCountInt': 75,
'averageStoreCost': 115,
'cost': 115
};
return widthMap[column.prop] || 150; // 默认宽度
};
const isContentOverflow = (key, content) => {
// 创建临时元素用于测量
if (!content) return false;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论