Commit 41e47121 by chenwq

Merge branch 'SAAS+V5.8.2' of http://192.168.3.233:8090/saas_plus/dj-car-life-sy…

…stem into SAAS+V5.8.2-cwq
2 parents 35df4a8c fcfcd98a
......@@ -418,11 +418,15 @@ export function batchCreateStrategy(data = {}) {
*
* 查询策略 驻店员工/区域运营/飞行督导列表
*/
// export function getStrategyStaffList(data = {}) {
// data.method = "dj.api.strategy.staff.page";
// return request(data, RequestMethods.POST);
// }
export function getStrategyStaffList(data = {}) {
data.method = "dj.api.strategy.staff.page";
return request(data, RequestMethods.POST);
}
/**
*
* 查询策略 驻店员工/区域运营/飞行督导列表 - 去重新接口
*/
export function getStrategyStaffListNew(data = {}) {
data.method = "dj.api.strategy.staff.page.distinct.phone";
return request(data, RequestMethods.POST);
}
......
......@@ -64,7 +64,7 @@ const STRATEGY_TYPE_CONFIG = {
0: { name: "学习", color: "#409EFF" },
1: { name: "优秀案例分享", color: "#36CBCB" },
2: { name: "带教", color: "#67C23A" },
3: { name: "任务下发", color: "#FFD666" },
3: { name: "通知", color: "#FFD666" },
4: { name: "销售精英到店提拉", color: "#B3E19D" },
5: { name: "强力促销", color: "#E6A23C" },
6: { name: "最终盘点与低客单产品购入", color: "#9254DE" },
......
......@@ -379,7 +379,7 @@ export default {
twoBrandIds: twoBrandIds || [],
regionalOperatorId: regionOps,
onlineOperatorId: onlineOps,
flightSupervision: supervisorOps,
flightSupervisionId: supervisorOps,
// periodType: this.timeRangeType.value,
cycleType: {
1: 2,
......
......@@ -78,12 +78,19 @@
<script>
import {
getStrategyStaffList,
getStrategyStaffListNew,
} from "@api/earlyWarningManager";
import multipleMixin from "./multipleMixin";
export default {
name: "MultipleStaff",
mixins: [multipleMixin],
props: {
strategyType: {
type: [Number, String],
default: null,
},
},
data() {
return {
dialogConfig: {
......@@ -92,14 +99,25 @@ export default {
width: "1092px",
},
},
targetId: "staffUuid",
getListApi: getStrategyStaffList,
searchForm: {
staffName: "",
},
tableParams: {
};
},
computed: {
isPhoneMode() {
return this.strategyType == 0 || this.strategyType == 1;
},
targetId() {
return this.isPhoneMode ? "phoneNumber" : "staffUuid";
},
getListApi() {
return this.isPhoneMode ? getStrategyStaffListNew : getStrategyStaffList;
},
tableParams() {
return {
listName: "list",
mutiSelectUniqueKey: "staffUuid",
mutiSelectUniqueKey: this.targetId,
mutiSelectName: "contentIndex",
tableColumns: [
{
......@@ -124,23 +142,23 @@ export default {
},
},
],
},
};
};
},
},
mounted() {
},
methods: {
beforeSearchFn() {
return new Promise((resolve) => {
let { positionTypeList, merchantList, paramsInfo, delMerchantList } = this;
let { positionTypeList, merchantList, paramsInfo, delMerchantList, biz } = this;
let { staffName } = this.searchForm;
let merchantIdList = [];
if (merchantList.length)
merchantIdList = merchantList.map(item => item.merchantId);
else merchantIdList = paramsInfo.merchantIds;
else merchantIdList = paramsInfo?.merchantIds || [];
let params = {
positionTypeList,
sceneType: paramsInfo.bizs == 2 ? 1 : 0, // 业务场景(0.会员权益(延保权益),1.精品升级(轻改))
sceneType: biz == 2 ? 1 : 0, // 业务场景(0.会员权益(延保权益),1.精品升级(轻改))
staffName,
merchantIdList,
};
......
......@@ -2,7 +2,7 @@ const STRATEGYTYPEOPTIONS = [
{ label: "学习", value: 0 },
{ label: "优秀案例分享", value: 1 },
{ label: "带教", value: 2 },
{ label: "任务下发", value: 3 },
{ label: "通知", value: 3 },
{ label: "销售精英到店提拉", value: 4 },
{ label: "强力促销", value: 5 },
{ label: "最终盘点与低客单产品购入", value: 6 },
......
......@@ -136,12 +136,14 @@
</div>
<MultipleStaff ref="staffTagRef"
:choose-data="formData.staffList"
:strategy-type="strategyType"
:visible="staffTagVisible"
@choose="formatMultipleList($event, 'staffList')"
@dialogClose="staffTagVisible = false">
</MultipleStaff>
<MultipleStaff ref="staffTagRef"
:choose-data="formData.staffList_1"
:strategy-type="strategyType"
:visible="staffTag1Visible"
@choose="formatMultipleList($event, 'staffList_1')"
@dialogClose="staffTag1Visible = false">
......
<template>
<div :class="['warning-item flex',`bg-${item.type || 1}`]">
<img
:src="icon"
class="warning-icon"
>
<div class="warning-text text-hide">{{ item.text }}</div>
<div class="warning-item flex" :class="[`bg-${item.type || 1}`]">
<img class="warning-icon"
:src="icon">
<div class="warning-text text-hide">
{{ item.text }}
</div>
</div>
</template>
<script type='text/ecmascript-6'>
const type_1 = require('@/assets/strategy/icon-strategy-type01.png'),
type_2 = require('@/assets/strategy/icon-strategy-type02.png'),
type_3 = require('@/assets/strategy/icon-strategy-type03.png'),
type_4 = require('@/assets/strategy/icon-strategy-type04.png'),
type_5 = require('@/assets/strategy/icon-strategy-type05.png'),
type_6 = require('@/assets/strategy/icon-strategy-type06.png')
const type_1 = require("@/assets/strategy/icon-strategy-type01.png");
const type_2 = require("@/assets/strategy/icon-strategy-type01.png");
const type_3 = require("@/assets/strategy/icon-strategy-type02.png");
const type_6 = require("@/assets/strategy/icon-strategy-type06.png");
const type_4 = require("@/assets/strategy/icon-strategy-type07.png");
const type_5 = require("@/assets/strategy/icon-strategy-type08.png");
export default {
name: 'EarlyWarningTips',
props: {
item: {
type: Object,
default: () => ({})
}
},
computed: {
icon () {
return {
1: type_1,
2: type_2,
3: type_3,
4: type_4,
5: type_5,
6: type_6
}[this.item.type] || ''
}
},
data () {
return {
}
},
mounted () {
},
methods: {
}
}
name: "EarlyWarningTips",
props: {
item: {
type: Object,
default: () => ({}),
},
},
data() {
return {
};
},
computed: {
icon() {
return {
1: type_1,
2: type_2,
3: type_3,
4: type_4,
5: type_5,
6: type_6,
}[this.item.type] || "";
},
},
mounted() {
},
methods: {
},
};
</script>
<style scoped lang='scss'>
.flex {
display: flex;
align-items: center;
display: flex;
align-items: center;
}
.warning-item {
width: 100%;
border-radius: 4px;
color: #333333;
font-size: 13px;
margin-top: 12px;
height: 30px;
background: #2c66f714;
box-sizing: border-box;
padding: 0 8px;
word-break: break-all;
.warning-icon {
width: 18px;
height: 18px;
margin-right: 6px;
}
.warning-text {
width: calc(100% - 24px);
}
width: 100%;
border-radius: 4px;
color: #333333;
font-size: 13px;
margin-top: 12px;
height: 30px;
background: #2c66f714;
box-sizing: border-box;
padding: 0 8px;
word-break: break-all;
.warning-icon {
width: 18px;
height: 18px;
margin-right: 6px;
}
.warning-text {
width: calc(100% - 24px);
}
}
.bg-1 {
background: #f2472414;
background: #f2472414;
}
.bg-2 {
background: #ff9d0a14;
background: #f2472414;
}
.bg-3 {
background: #ff9d0a14;
}
.bg-4 {
background: #f2472414;
}
.bg-5 {
background: #ff9d0a14;
}
.bg-6 {
background: #2c66f714;
}
</style>
\ No newline at end of file
import dayjs from "dayjs"
import dayjs from "dayjs";
const STRATEGYTYPEOPTIONS = {
0: '学习',
1: '优秀案例分享',
2: '带教',
3: '任务下发',
4: '销售精英到店提拉',
5: '强力促销',
6: '最终盘点与低客单产品购入',
7: '留言'
}
0: "学习",
1: "优秀案例分享",
2: "带教",
3: "通知",
4: "销售精英到店提拉",
5: "强力促销",
6: "最终盘点与低客单产品购入",
7: "留言",
};
const DATE_RANGE = {
label: '执行周期',
label: "执行周期",
format: (val) => {
let {
startDate,
endDate
} = val
return `${dayjs(startDate).format('YYYY-MM-DD')}至 ${dayjs(endDate).format('YYYY-MM-DD')}`
}
}
endDate,
} = val;
return `${dayjs(startDate).format("YYYY-MM-DD")}至 ${dayjs(endDate).format("YYYY-MM-DD")}`;
},
};
const TITLE = {
label: '标题',
key: 'title',
}
label: "标题",
key: "title",
};
const CREATED = {
label: '操作人',
key: 'createdBy',
}
label: "操作人",
key: "createdBy",
};
const CREATED_DATE = {
label: '操作时间',
label: "操作时间",
format: (val) => {
return dayjs(val.createdDate).format('YYYY-MM-DD HH:mm:ss')
}
}
return dayjs(val.createdDate).format("YYYY-MM-DD HH:mm:ss");
},
};
const STRATEGY_FORM_01 = [
TITLE,
DATE_RANGE,
CREATED,
CREATED_DATE
]
CREATED_DATE,
];
const STRATEGY_FORM_2456 = [
CREATED,
DATE_RANGE,
{
label: '执行人',
label: "执行人",
format: (val) => {
let {
executePersons
} = val
return executePersons?.map(item => item.username).join('/')
executePersons,
} = val;
return executePersons?.map(item => item.username).join("/");
},
hide: (val) => {
let {
strategyType
} = val
return [5, 6].includes(strategyType)
}
strategyType,
} = val;
return [5, 6].includes(strategyType);
},
},
CREATED_DATE
]
CREATED_DATE,
];
const STRATEGY_FORM_3 = [
CREATED,
TITLE,
CREATED_DATE,
{
label: '副标题',
key: 'subTitle',
class: 'bespread',
label: "副标题",
key: "subTitle",
class: "bespread",
},
{
label: '执行时间',
key: 'startDate',
label: "执行时间",
key: "startDate",
},
]
];
const STRATEGY_FORM_7 = [
CREATED,
CREATED_DATE,
{
label: '处理人',
label: "处理人",
format: (val) => {
let {
executePersons
} = val
return executePersons?.map(item => item.username).join('/') || '-'
executePersons,
} = val;
return executePersons?.map(item => item.username).join("/") || "-";
},
},
]
];
export {
STRATEGYTYPEOPTIONS,
STRATEGY_FORM_01,
STRATEGY_FORM_2456,
STRATEGY_FORM_3,
STRATEGY_FORM_7
}
STRATEGY_FORM_7,
STRATEGY_FORM_2456,
STRATEGYTYPEOPTIONS,
};
......@@ -2,7 +2,7 @@
* @Author: 'wangzhihui' '1733904062@qq.com'
* @Date: 2026-04-01 09:57:49
* @LastEditors: 'wangzhihui' '1733904062@qq.com'
* @LastEditTime: 2026-06-02 17:54:09
* @LastEditTime: 2026-06-04 19:16:23
* @FilePath: \dj-car-life-system\src\views\earlyWarningManager\strategyCentre\storeSignboard\components\StrategyList\contant.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
......@@ -12,7 +12,7 @@ const STRATEGYTYPEOPTIONS = {
0: "学习",
1: "优秀案例分享",
2: "带教",
3: "任务下发",
3: "通知",
4: "销售精英到店提拉",
5: "强力促销",
6: "最终盘点与低客单产品购入",
......@@ -35,7 +35,7 @@ function STAFF_FORMAT(label) {
label,
format: (val) => {
let { staffList } = val;
return staffList.filter(item => !item.userPosition).map(item => item.userName).join("/") || "-";
return staffList.map(item => item.userName).join("/") || "-";
},
};
}
......@@ -89,12 +89,19 @@ const STRATEGY_8 = [
STAFF_FORMAT("需带教人员"),
];
const STRATEGY_9 = [
STAFF_FORMAT("问题人员"),
// STAFF_FORMAT("问题人员"),
{
label: "问题人员",
format: (val) => {
let { staffList } = val;
return staffList.filter(item => item.userPosition != 8 && item.userPosition != 9).map(item => item.userName).join("/") || "-";
},
},
{
label: "执行人员",
format: (val) => {
let { staffList } = val;
return staffList.filter(item => item.userPosition != 0).map(item => item.userName).join("/") || "-";
return staffList.filter(item => item.userPosition == 8 || item.userPosition == 9).map(item => item.userName).join("/") || "-";
},
},
];
......@@ -104,7 +111,7 @@ const STRATEGY_10_11_12 = [
label: "执行人员",
format: (val) => {
let { staffList } = val;
return staffList.filter(item => item.userPosition != 0).map(item => item.userName).join("/") || "-";
return staffList.filter(item => item.userPosition == 8 || item.userPosition == 9).map(item => item.userName).join("/") || "-";
},
},
];
......
......@@ -601,7 +601,7 @@ export default {
height: calc(100% - 91px);
margin-top: 8px;
box-sizing: border-box;
padding: 12px 20px 12px 13px;
padding: 12px 22px 12px 26px;
z-index: 9;
.help {
position: absolute;
......@@ -683,6 +683,7 @@ export default {
height: 100%;
flex-direction: column;
justify-content: center;
.label {
color: #666666;
font-size: 13px;
......
......@@ -31,83 +31,154 @@ function parseDatetime(value) {
return "-";
}
function renderText(h, { data, schemaItem, schema }) {
return h("span", schemaItem.meta.fieldValue || "-");
}
function renderDatetime(h, { data, schemaItem, schema }) {
const formatted = parseDatetime(schemaItem.meta.fieldValue);
return h("span", formatted);
}
function renderLink(h, { data, schemaItem, schema }) {
const { fieldValue, linkAlias } = schemaItem.meta;
if (!fieldValue)
return h("span", "-");
const linkProps = {
attrs: {
href: fieldValue,
target: "_blank",
type: "primary",
// tooltip: true,
// parentProps: {
// style: {
// display: "inline-block",
// height: "32px",
// width: "auto",
// maxWidth: "100%",
// verticalAlign: "top",
// },
// },
// // tooltipProps: el-tooltip 的传参
// render: (h, { data, schemaItem, schema }) => {
// return h("div", { class: "text-hide" }, data.description || "-");
// },
function renderText() {
return {
tooltip: true,
tooltipProps: {
render: (h, { data, schemaItem, schema }) => {
return h("div", schemaItem.meta.fieldValue || "-");
},
},
on: {
click: (e) => {
e.preventDefault();
window.open(fieldValue, "_blank");
parentProps: {
style: {
display: "inline-block",
height: "32px",
width: "auto",
maxWidth: "100%",
verticalAlign: "top",
},
},
render: (h, { data, schemaItem, schema }) => {
return h("div", { class: "text-hide" }, schemaItem.meta.fieldValue || "-");
},
};
return h("el-link", linkProps, linkAlias || fieldValue);
}
function renderImage(h, { data, schemaItem, schema }) {
const { fieldValue } = schemaItem.meta;
if (!fieldValue || !Array.isArray(fieldValue) || fieldValue.length === 0) {
return h("span", "-");
}
return h(DescriptionImageList, { props: { list: fieldValue, size: 80 } });
function renderDatetime() {
return {
render: (h, { data, schemaItem, schema }) => {
const formatted = parseDatetime(schemaItem.meta.fieldValue);
return h("span", formatted);
},
};
}
function renderAttachment(h, { data, schemaItem, schema }) {
const { fieldValue } = schemaItem.meta;
if (!fieldValue || !Array.isArray(fieldValue) || fieldValue.length === 0) {
return h("span", "-");
}
const containerChildren = fieldValue.map((item, index) => {
const fileName = item.name || item.fileName || item.url || `附件${index + 1}`;
const fileUrl = item.value || item.url || "";
const rowChildren = [
h("span", {
function renderLink() {
return {
tooltip: true,
tooltipProps: {
render: (h, { data, schemaItem, schema }) => {
return h("div", schemaItem.meta.fieldValue || "-");
},
},
parentProps: {
style: {
display: "inline-block",
height: "32px",
width: "auto",
maxWidth: "100%",
verticalAlign: "top",
},
},
render: (h, { data, schemaItem, schema }) => {
const { fieldValue, linkAlias } = schemaItem.meta;
if (!fieldValue)
return h("span", "-");
const linkProps = {
class: "text-hide link-type",
style: {
width: "100%",
},
attrs: {
class: "file-name text-hide",
title: fileName,
style: "max-width: 50%",
href: fieldValue,
target: "_blank",
type: "primary",
},
}, fileName),
];
rowChildren.push(
h("el-link", {
attrs: { href: fileUrl, target: "_blank" },
props: { type: "primary", underline: false },
style: { marginLeft: "8px", lineHeight: 1 },
on: {
click: (e) => {
if (!fileUrl)
return;
e.preventDefault();
window.open(fileUrl, "_blank");
window.open(fieldValue, "_blank");
},
},
}, "下载"),
);
};
return h("el-link", linkProps, linkAlias || fieldValue);
},
};
}
return h("div", { attrs: { class: "attachment-item", style: "display: flex; align-items: center; margin-bottom: 8px;" } }, rowChildren);
});
function renderImage() {
return {
render: (h, { data, schemaItem, schema }) => {
const { fieldValue } = schemaItem.meta;
if (!fieldValue || !Array.isArray(fieldValue) || fieldValue.length === 0) {
return h("span", "-");
}
return h(DescriptionImageList, { props: { list: fieldValue, size: 80 } });
},
};
}
return h("div", { attrs: { class: "attachment-list" } }, containerChildren);
function renderAttachment() {
return {
render: (h, { data, schemaItem, schema }) => {
const { fieldValue } = schemaItem.meta;
if (!fieldValue || !Array.isArray(fieldValue) || fieldValue.length === 0) {
return h("span", "-");
}
const containerChildren = fieldValue.map((item, index) => {
const fileName = item.name || item.fileName || item.url || `附件${index + 1}`;
const fileUrl = item.value || item.url || "";
const rowChildren = [
h("span", {
attrs: {
class: "file-name text-hide",
title: fileName,
style: "max-width: 50%",
},
}, fileName),
];
rowChildren.push(
h("el-link", {
attrs: { href: fileUrl, target: "_blank", title: fileUrl },
props: { type: "primary", underline: false },
style: { marginLeft: "8px", lineHeight: 1 },
on: {
click: (e) => {
if (!fileUrl)
return;
e.preventDefault();
window.open(fileUrl, "_blank");
},
},
}, "下载"),
);
return h("div", { attrs: { class: "attachment-item" } }, rowChildren);
});
return h("div", { attrs: { class: "attachment-list" } }, containerChildren);
},
};
}
export default {
......
......@@ -15,12 +15,13 @@ export async function getTaskCenterTaskDescriptionSchema() {
display: "inline-block",
height: "32px",
width: "auto",
maxWidth: "100%",
verticalAlign: "top",
},
},
// tooltipProps: el-tooltip 的传参
render: (h, { data, schemaItem, schema }) => {
return h("span", {}, data.description || "-");
return h("div", { class: "text-hide" }, data.description || "-");
},
isHide: ({ formModel }) => !formModel.description,
},
......
......@@ -69,7 +69,7 @@ export default {
},
labelWidth: "120px",
meta: item,
render: cover2Descriptions[toUpper(item.fieldType)],
...cover2Descriptions?.[toUpper(item.fieldType)]?.(),
})));
this.descriptionSchema = schema;
} else {
......@@ -238,6 +238,29 @@ export default {
margin: 0 0 12px;
background-color: #ebeef5;
}
::v-deep .link-type {
overflow: hidden;
.el-link--inner {
display: inline-block;
height: 32px;
width: auto;
max-width: 100%;
vertical-align: top;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
}
::v-deep .attachment-list {
.attachment-item {
margin-bottom: 8px;
display: flex;
align-items: center;
&:last-child {
margin-bottom: 0;
}
}
}
::v-deep .form-item {
margin-bottom: 12px;
}
......
......@@ -31,9 +31,9 @@
操作日志
</div>
<el-table v-loading="loading"
style="width: 100%"
border
:data="tableData"
style="width: 100%">
:data="tableData">
<el-table-column align="center"
label="序号"
type="index"
......@@ -119,7 +119,7 @@ export default {
pageSize: 1000,
currentPage: 1,
upgradeGoodsId: this.row.upgradeGoodsId,
merchantId: this.row.merchantId,
merchantId: this.row.yqMerchantId,
};
getReplenishLogListApi(params).then((res) => {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!