Commit e4cf0989 by 张立顺

Merge branch 'SAAS+V4.43-0807' into SAAS+V4.43.1-0819

2 parents e6801af1 636dc6de
Showing 50 changed files with 3011 additions and 233 deletions
......@@ -1290,6 +1290,22 @@
}
}
},
"@babel/runtime-corejs3": {
"version": "7.25.0",
"resolved": "https://registry.npmmirror.com/@babel/runtime-corejs3/-/runtime-corejs3-7.25.0.tgz",
"integrity": "sha512-BOehWE7MgQ8W8Qn0CQnMtg2tHPHPulcS/5AVpFvs2KCK1ET+0WqZqPvnpRpFN81gYoFopdIEJX9Sgjw3ZBccPg==",
"requires": {
"core-js-pure": "^3.30.2",
"regenerator-runtime": "^0.14.0"
},
"dependencies": {
"regenerator-runtime": {
"version": "0.14.1",
"resolved": "https://registry.npmmirror.com/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz",
"integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw=="
}
}
},
"@babel/template": {
"version": "7.18.10",
"resolved": "https://registry.npmmirror.com/@babel/template/-/template-7.18.10.tgz",
......@@ -3508,6 +3524,27 @@
"whatwg-fetch": "^3.6.2"
},
"dependencies": {
"@vue/vue-loader-v15": {
"version": "npm:vue-loader@15.11.1",
"resolved": "https://registry.npmmirror.com/vue-loader/-/vue-loader-15.11.1.tgz",
"integrity": "sha512-0iw4VchYLePqJfJu9s62ACWUXeSqM30SQqlIftbYWM3C+jpPcEHKSPUZBLjSF9au4HTHQ/naF6OGnO3Q/qGR3Q==",
"dev": true,
"requires": {
"@vue/component-compiler-utils": "^3.1.0",
"hash-sum": "^1.0.2",
"loader-utils": "^1.1.0",
"vue-hot-reload-api": "^2.3.0",
"vue-style-loader": "^4.1.0"
},
"dependencies": {
"hash-sum": {
"version": "1.0.2",
"resolved": "https://registry.npmmirror.com/hash-sum/-/hash-sum-1.0.2.tgz",
"integrity": "sha512-fUs4B4L+mlt8/XAtSOGMUO1TXmAelItBPtJG7CyHJfYTdDjwisntGO2JQz7oUsatOY9o68+57eziUVNw/mRHmA==",
"dev": true
}
}
},
"acorn-walk": {
"version": "8.2.0",
"resolved": "https://registry.npmmirror.com/acorn-walk/-/acorn-walk-8.2.0.tgz",
......@@ -3897,27 +3934,6 @@
"lodash": "^4.17.4"
}
},
"@vue/vue-loader-v15": {
"version": "npm:vue-loader@15.11.1",
"resolved": "https://registry.npmjs.org/vue-loader/-/vue-loader-15.11.1.tgz",
"integrity": "sha512-0iw4VchYLePqJfJu9s62ACWUXeSqM30SQqlIftbYWM3C+jpPcEHKSPUZBLjSF9au4HTHQ/naF6OGnO3Q/qGR3Q==",
"dev": true,
"requires": {
"@vue/component-compiler-utils": "^3.1.0",
"hash-sum": "^1.0.2",
"loader-utils": "^1.1.0",
"vue-hot-reload-api": "^2.3.0",
"vue-style-loader": "^4.1.0"
},
"dependencies": {
"hash-sum": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/hash-sum/-/hash-sum-1.0.2.tgz",
"integrity": "sha512-fUs4B4L+mlt8/XAtSOGMUO1TXmAelItBPtJG7CyHJfYTdDjwisntGO2JQz7oUsatOY9o68+57eziUVNw/mRHmA==",
"dev": true
}
}
},
"@vue/vue2-jest": {
"version": "27.0.0",
"resolved": "https://registry.npmmirror.com/@vue/vue2-jest/-/vue2-jest-27.0.0.tgz",
......@@ -5863,6 +5879,11 @@
}
}
},
"core-js-pure": {
"version": "3.37.1",
"resolved": "https://registry.npmmirror.com/core-js-pure/-/core-js-pure-3.37.1.tgz",
"integrity": "sha512-J/r5JTHSmzTxbiYYrzXg9w1VpqrYt+gexenBE9pugeyhwPZTAEJddyiReJWsLO6uNQ8xJZFbod6XC7KKwatCiA=="
},
"core-util-is": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz",
......@@ -17080,7 +17101,7 @@
},
"vue-hot-reload-api": {
"version": "2.3.4",
"resolved": "https://registry.npmjs.org/vue-hot-reload-api/-/vue-hot-reload-api-2.3.4.tgz",
"resolved": "https://registry.npmmirror.com/vue-hot-reload-api/-/vue-hot-reload-api-2.3.4.tgz",
"integrity": "sha512-BXq3jwIagosjgNVae6tkHzzIk6a8MHFtzAdwhnV5VlvPTFxDCvIttgSiHWjdGoTJvXtmRu5HacExfdarRcFhog==",
"dev": true
},
......@@ -17242,6 +17263,23 @@
"makeerror": "1.0.12"
}
},
"wangeditor": {
"version": "4.7.15",
"resolved": "https://registry.npmmirror.com/wangeditor/-/wangeditor-4.7.15.tgz",
"integrity": "sha512-aPTdREd8BxXVyJ5MI+LU83FQ7u1EPd341iXIorRNYSOvoimNoZ4nPg+yn3FGbB93/owEa6buLw8wdhYnMCJQLg==",
"requires": {
"@babel/runtime": "^7.11.2",
"@babel/runtime-corejs3": "^7.11.2",
"tslib": "^2.1.0"
},
"dependencies": {
"tslib": {
"version": "2.6.3",
"resolved": "https://registry.npmmirror.com/tslib/-/tslib-2.6.3.tgz",
"integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ=="
}
}
},
"watchpack": {
"version": "2.4.0",
"resolved": "https://registry.npmmirror.com/watchpack/-/watchpack-2.4.0.tgz",
......
......@@ -55,6 +55,7 @@
"vue-router": "3.0.5",
"vuedraggable": "^2.24.3",
"vuex": "^3.0.1",
"wangeditor": "4.7.15",
"webpack-theme-color-replacer": "^1.4.2",
"webpack5-svg-sprite-loader": "^5.1.1",
"xlsx": "^0.16.9",
......
......@@ -65,3 +65,39 @@ export function getBrandList(data) {
data.method = `dj.api.smartcarlife.common.car.brand.page`
return request(data)
}
// 分页查询标签员工
export function getListLabelStaffPage(data) {
data.method = `dj.api.smartcarlife.contentManagerTask.listLabelStaffPage`
return request(data)
}
// 员工群发-分页查询列表
export function contentManagerTaskPage(data) {
data.method = `dj.api.smartcarlife.contentManagerTask.page`
return request(data, "POST")
}
// 员工群发-删除记录
export function deleteTaskById(data) {
data.method = `dj.api.smartcarlife.contentManagerTask.deleteById`
return request(data, "POST")
}
// 员工群发-分页查询内容管理统计信息
export function getStatisticPage(data) {
data.method = `dj.api.smartcarlife.contentManagerTask.statistic.page`
return request(data, "POST")
}
// 员工群发-添加/修改记录
export function insertOrUpdate(data) {
data.method = `dj.api.smartcarlife.contentManagerTask.insertOrUpdate`
return request(data, "POST")
}
// 根据ID查询详细信息
export function contentManagerTaskById(data) {
data.method = `dj.api.smartcarlife.contentManagerTask.getById`
return request(data, "POST")
}
......@@ -2,12 +2,17 @@
* @Description: AI对练相关接口
* @Author: huyue
* @Date: 2024-04-19 11:02:02
* @LastEditors: huyue
* @LastEditTime: 2024-05-08 11:32:07
* @LastEditors: 王志慧 wangzh@didihu.com.cn
* @LastEditTime: 2024-07-20 10:42:14
*/
import request from "./request"
const path = 'dj.api.smartcarlife.ai.sparring.'
const path = "dj.api.smartcarlife.ai.sparring."
// 结束任务
export function stopTask(data) {
data.method = `${path}stop.task`
return request(data)
}
// 获取练习列表
export function getList(data) {
data.method = `${path}task.page`
......@@ -17,7 +22,7 @@ export function getList(data) {
// 新建任务
export function createTask(data) {
data.method = `${path}task.create`
return request(data, 'post')
return request(data, "post")
}
// 对练详情
......@@ -63,8 +68,24 @@ export function getSparringDetail(data) {
return request(data)
}
// 查询对练详情列表
export function staffRecordPage(data) {
data.method = `${path}staff.record.page`
return request(data)
}
// 更新任务提示词状态
export function updateTaskPromptStatus(data) {
data.method = `${path}task.updatePrompt`
return request(data)
}
//质检结果
export function getSparringCheckResult(data) {
data.method = `dj.api.carboutique.ai.sparring.detail.check.result`
}
// 获取对练报告详情
export function getSparringReportDetail(data) {
data.method = `${path}report.detail`
return request(data)
}
......@@ -905,3 +905,17 @@ export const inviteStatusList = [
{ confId: 6, confValue: "已撤销" },
{ confId: 7, confValue: "已支付" }
]
// 内容管理-员工群发-内容类型
export const contentTypeList = [
{ confId: 1, confValue: "图文" },
{ confId: 2, confValue: "视频" },
{ confId: 3, confValue: "pdf" }
]
// 内容管理-员工群发-发送状态
export const sendStatusList = [
{ confId: 1, confValue: "草稿" },
{ confId: 2, confValue: "待发送" },
{ confId: 3, confValue: "已发送" }
]
......@@ -5,20 +5,21 @@
</template>
<script>
import E from 'wangeditor'
import { uploadImg, syncUploadVideo, uploadVideo } from "@/api/sys.base"
import E from "wangeditor"
export default {
name: 'TextBox',
name: "TextBox",
data() {
return {
editor: '',
content: '',
editor: "",
content: "",
editorOption: {}
}
},
props: {
excludeMenus: {
type: Array,
default: () => ['code']
default: () => ["code"]
},
boxHeight: {
type: Number,
......@@ -31,37 +32,41 @@ export default {
methods: {
getEdit() {
const _this = this
this.editor = new E('#div-demo')
this.editor = new E("#div-demo")
this.editor.config.uploadImgShowBase64 = true
this.editor.config.showMenuTooltips = true
this.editor.config.menuTooltipPosition = 'down'
this.editor.config.menuTooltipPosition = "down"
this.editor.config.height = this.boxHeight
this.editor.config.width = 500
this.editor.config.width = "500px"
this.editor.config.excludeMenus = this.excludeMenus
this.editor.config.onchange = html => {
this.editor.config.onchange = (html) => {
// console.log(html);
this.content = html // 绑定当前逐渐地值
this.$emit('change', this.content) // 将内容同步到父组件中
this.$emit("change", this.content) // 将内容同步到父组件中
}
this.editor.config.onfocus = () => {
this.$emit('focus')
this.$emit("focus")
}
// 上传图片
this.editor.config.customUploadImg = function(resultFiles, insertImgFn) {
this.editor.config.customUploadImg = function (resultFiles, insertImgFn) {
var file = resultFiles[0]
var reader = new FileReader()
// 默认1MB
const limitSize = 10
const isLt = file.size / 1024 / 1024 < limitSize
if (!isLt) {
_this.$message.error('上传图片大小不能超过' + limitSize + 'MB!')
_this.$message.error("上传图片大小不能超过" + limitSize + "MB!")
return true
}
reader.readAsDataURL(file)
reader.onload = e => {
reader.onload = (e) => {
const imgFile = e.target.result
const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1]
_this.$apis.common.pictureUpload({ file: base64 }).then(res => {
const base64 =
file.name.split(".")[file.name.split(".").length - 1] +
"@" +
imgFile.split(",")[1]
// _this.$apis.common.pictureUpload({ file: base64 }).then(res => {
uploadImg({ file: base64, compress: 0 }).then((res) => {
if (res) {
// console.log(res)
insertImgFn(res)
......@@ -73,21 +78,27 @@ export default {
}
}
// 上传视频
this.editor.config.customUploadVideo = function(resultFiles, insertVideoFn) {
this.editor.config.customUploadVideo = function (
resultFiles,
insertVideoFn
) {
var file = resultFiles[0]
var reader = new FileReader()
// 默认1MB
const limitSize = 10
const isLt = file.size / 1024 / 1024 < limitSize
if (!isLt) {
_this.$message.error('上传视频大小不能超过' + limitSize + 'MB!')
_this.$message.error("上传视频大小不能超过" + limitSize + "MB!")
return true
}
reader.readAsDataURL(file)
reader.onload = e => {
reader.onload = (e) => {
const videoFile = e.target.result
const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + videoFile.split(',')[1]
_this.$apis.common.pictureUpload({ file: base64 }).then(res => {
const base64 =
file.name.split(".")[file.name.split(".").length - 1] +
"@" +
videoFile.split(",")[1]
_this.$apis.common.pictureUpload({ file: base64 }).then((res) => {
if (res) {
// console.log(res)
insertVideoFn(res)
......@@ -116,6 +127,7 @@ export default {
<style lang="scss" scoped>
#div-demo {
width: 575px;
// margin: 16px 300px 0 0;
}
.el-form .editor {
......
......@@ -36,12 +36,12 @@ export const routerName = {
}
]
},
{
authId: "90705",
parentId: "907",
category: "Button",
label: "编辑单店信息"
},
// {
// authId: "90705",
// parentId: "907",
// category: "Button",
// label: "编辑单店信息"
// },
{
authId: "90706",
parentId: "907",
......
......@@ -234,7 +234,7 @@ export const routerName = {
parentId: "912",
cache: false
},
component: _import("residentManage/exercise/index"),
component: _import("residentManage/exercise/exerciseTab"),
auth: [
{
authId: "9120801",
......@@ -283,6 +283,30 @@ export const routerName = {
parentId: "91208"
}
]
},
{
authId: "9120805",
// parentId: "91208",
// label: "明细",
// handle: "handleToDetail",
// addRoutePath: [
// {
// authId: "912080401",
// name: "明细",
// parentId: "91208"
// }
// ]
parentId: "91208",
label: "结束",
handle: "btnClickEnd",
ruleObj: {
attr: "taskState",
rule: {
1: "结束",
2: "结束"
},
disabledStatusList: [2]
}
}
]
},
......
......@@ -106,7 +106,7 @@ export const routerName = {
1: "停用"
}
}
},
}
],
component: _import("contentManager/contentManagerList")
},
......@@ -121,6 +121,7 @@ export const routerName = {
activePath: "/contentManagerList"
},
component: _import("contentManager/contentAdd")
// component: _import("contentManager/SopContentAdd")
},
91303: {
path: "/contentDetail",
......@@ -154,5 +155,120 @@ export const routerName = {
}
],
component: _import("contentManager/statisticsList")
},
91305: {
path: "/staffMassSending",
name: "staffMassSending",
meta: {
title: "员工群发",
authId: "91305",
parentId: "913",
cache: false
},
auth: [
{
authId: "9130501",
parentId: "91305",
label: "新增群发",
icon: "plus",
category: "Button",
type: "primary",
handle: "handleAdd",
addRoutePath: [
{
authId: "91306",
name: "内容编辑",
parentId: "91305"
}
]
},
{
authId: "9130502",
parentId: "91305",
label: "查看",
handle: "handleDetail",
addRoutePath: [
{
authId: "91307",
name: "查看",
parentId: "91305"
}
]
},
{
authId: "9130503",
parentId: "91305",
label: "编辑",
handle: "handleAdd"
},
{
authId: "9130504",
parentId: "91305",
label: "统计",
handle: "goStatisticsPage",
addRoutePath: [
{
authId: "9130506",
name: "统计",
parentId: "91305"
}
]
},
{
authId: "9130505",
parentId: "91305",
label: "删除",
handle: "handleDel"
}
],
component: _import("contentManager/staffMassSending/index")
},
9130506: {
path: "/statisticsPage",
name: "statisticsPage",
meta: {
title: "统计",
authId: "9130506",
parentId: "91305",
cache: false,
activePath: "/statisticsPage"
},
auth: [
{
authId: "913050601",
parentId: "9130506",
label: "导出",
category: "Button",
type: "primary",
handle: "handleExport"
}
],
component: _import("contentManager/staffMassSending/statisticsPage")
},
91306: {
path: "/SopContentAdd",
name: "SopContentAdd",
meta: {
title: "内容编辑",
authId: "91306",
parentId: "91301",
cache: false,
activePath: "/staffMassSending"
},
component: _import("contentManager/SopContentAdd")
},
91307: {
path: "/sopContentDetail",
name: "sopContentDetail",
meta: {
title: "查看",
authId: "91307",
parentId: "91301",
cache: false,
activePath: "/staffMassSending"
},
component: _import("contentManager/sopContentDetail")
}
}
......@@ -3,27 +3,31 @@
<draggable
:value="imageUrlArr"
@end="dragEnd"
:disabled="!picOptions.isDrag">
:disabled="!picOptions.isDrag"
>
<transition-group class="activity-img-box">
<template v-if="imageUrlArr && imageUrlArr.length > 0">
<div v-for="(item, index) in imageUrlArr" :key="index">
<div
class="pic-box"
:style="{ width: picOptions.width, height: picOptions.height }"
v-if="picOptions.type == 'video'">
v-if="picOptions.type == 'video'"
>
<video id="video" width="100%" height="100%" preload loop muted>
<source :src="item" type="video/mp4" />
</video>
<div class="mask">
<div
class="pic-pane-close"
@click="handleEnlarge(item, 'video')">
@click="handleEnlarge(item, 'video')"
>
<img :src="require('@/assets/view.png')" alt="" />
</div>
<div
class="pic-pane-close"
@click="close('video', index)"
v-if="picOptions.isClose">
v-if="picOptions.isClose"
>
<img :src="require('@/assets/icon-delete.png')" alt="" />
</div>
</div>
......@@ -31,11 +35,13 @@
<div
class="pic-box"
:style="{ width: picOptions.width, height: picOptions.height }"
v-else>
v-else
>
<img class="photo-activity" :src="item" alt="" />
<div
class="mask"
:style="{ width: picOptions.width, height: picOptions.height }">
:style="{ width: picOptions.width, height: picOptions.height }"
>
<div class="pic-pane-close" @click="handleEnlarge(item, 'img')">
<img :src="require('@/assets/view.png')" alt="" />
</div>
......@@ -53,12 +59,14 @@
<template
v-if="
(imageUrlArr && imageUrlArr.length < 10 && limit > 1) ||
(imageUrlArr && imageUrlArr.length == 0 && limit == 1)
">
(imageUrlArr && imageUrlArr.length == 0 && limit == 1)
"
>
<div
class="upload-img"
:style="{ width: picOptions.width, height: picOptions.height }"
@click="selectFile()">
@click="selectFile()"
>
<i class="el-icon-plus avatar-uploader-desc-icon"></i>
<div class="avatar-uploader-desc-word">
上传{{ picOptions.type == "video" ? "视频" : "图片" }}
......@@ -70,16 +78,30 @@
:style="{ width: picOptions.width, height: picOptions.height }"
style="opacity: 0; z-index: -1"
:accept="picOptions.type == 'video' ? '.mp4' : '.jpg, .jpeg, .png,'"
@change="(e) => handleImgChange(e)" />
@change="(e) => handleImgChange(e)"
/>
</div>
</template>
<el-dialog
class="image-dialog"
:visible.sync="dialogVisibleImg"
:append-to-body="true"
width="50%">
<img :src="dialogSrc" width="100%" v-if="dialogType == 'img'" />
<video width="100%" autoplay controls :src="dialogSrc" v-else></video>
width="50%"
>
<img
:src="dialogSrc"
class="preVideo"
width="100%"
v-if="dialogType == 'img'"
/>
<video
width="100%"
autoplay
controls
:src="dialogSrc"
v-else
class="preVideo"
></video>
</el-dialog>
</div>
</template>
......@@ -325,7 +347,7 @@ export default {
background: rgba(0, 0, 0, 0.04);
border: 1px dashed rgba(0, 0, 0, 0.15);
border-radius: 4px;
overflow: hidden;
input {
position: absolute;
// top: 0;
......@@ -347,4 +369,7 @@ export default {
}
}
}
.preVideo {
max-height: 60vh;
}
</style>
<!-- 关联门店弹窗 -->
<template>
<d2-dialog
:title="title"
:is-visible.sync="relateStoreVisible"
width="50%"
btn-ok-label="确定"
@confirmDialog="handleRelateStoreConfirm"
@closeDialog="handleRelateStoreClose"
class="relateStore"
>
<slot />
<el-row class="tableCon">
<div class="tableBox">
<!-- height="300px" -->
<el-table
ref="seletingTable"
:data="selectingData"
class="table"
border
v-loading="$store.state.d2admin.loading.value"
>
<el-table-column label="序号" type="index" align="center" width="60">
<template slot-scope="scope">{{
(pageNum - 1) * pageSize + scope.$index + 1
}}</template>
</el-table-column>
<!-- @select="handleChange"
@select-all="handleAll" -->
<!-- <el-table-column type="selection" width="55" align="center" /> -->
<!-- <el-table-column prop="merchantName" label="门店名称" align="center">
</el-table-column> -->
<el-table-column prop="staffName" label="员工名称" align="center">
</el-table-column>
<el-table-column prop="phoneNumber" label="手机号" align="center">
</el-table-column>
</el-table>
<el-pagination
small
background
@current-change="handleCurrentChange"
:current-page.sync="pageNum"
:page-size="pageSize"
layout="total, prev, pager, next"
:total="total"
/>
</div>
</el-row>
</d2-dialog>
</template>
<script>
export default {
name: "SelectEmployees",
data() {
return {
selectedData: [],
selectingData: [],
// 分页
total: 0,
pageNum: 1,
pageSize: 10
}
},
props: {
title: {
type: String,
default: "驻店员工"
},
relateStoreVisible: {
type: Boolean,
default: false
},
storeApi: {
type: Function,
default: () => {}
},
storeSelected: {
type: Array,
default: () => []
},
storeSearchForm: {
type: Object,
default: () => {}
},
merchantIds: {
type: Array,
default: () => []
}
},
mounted() {
this.selectedData = this.storeSelected
this.getSelectingList()
console.log(this.selectedData, "---------")
},
methods: {
recoverySelection() {
var exitIds = this.selectedData.map((item) => item.staffUuid)
this.selectingData.forEach((item) => {
exitIds.includes(item.staffUuid) &&
this.$refs.seletingTable.toggleRowSelection(item, true)
})
},
getSelectingList() {
const _storeSearchForm = this.storeSearchForm
// 会员权益/积分商城获取账户中心所有门店 接口不同 接口新增查询参数merchantName 不需单独处理
// if ([0, 4].includes(this.selectedScene)) {
// // 会员权益,积分商城场景查询门店名称参数
// _storeSearchForm.merchantIdName = _storeSearchForm.merchantName // 账户中心所有门店接口查询条件
// }
console.log(this.storeSearchForm, "this.storeSearchForm")
this.storeSearchForm.labelInfoList.length &&
this.storeApi({
...this.storeSearchForm,
pageNum: this.pageNum,
pageSize: this.pageSize
// merchantNoList: this.merchantIds
}).then((res) => {
// res?.forEach((val) => {
// 账户中心门店返回商户号字段是merchantNo
// if (val.merchantNo) val.merchantId = Number(val.merchantNo)
// val?.sceneList?.forEach((subVal) => {
// if (subVal.scene == this.selectedScene) {
// val.yqMerchantId = subVal?.yqMerchant?.merchantId || "-"
// val.yqMerchantName = subVal?.yqMerchant?.merchantName || "-"
// }
// })
// })
this.selectingData = res.list
this.total = res.total
this.$nextTick(() => {
this.recoverySelection()
})
})
},
handleChange(selection, row) {
var addOrDelete = !!selection.find(
(item) => item.staffUuid === row.staffUuid
)
addOrDelete
? this.selectedData.push(row)
: (this.selectedData = this.selectedData.filter(
(item) => item.staffUuid !== row.staffUuid
))
},
handleAll(selection) {
this.selectingData.forEach((item) => {
var isExit = this.selectedData.findIndex(
(subItem) => subItem.staffUuid === item.staffUuid
)
if (selection.length && isExit === -1) {
this.selectedData.push(item)
} else if (!selection.length && isExit !== -1) {
this.selectedData.splice(isExit, 1)
}
})
},
handleDelete(row) {
this.selectedData = this.selectedData.filter(
(item) => item.staffUuid !== row.staffUuid
)
const obj = this.selectingData.find((v) => v.staffUuid == row.staffUuid)
this.$refs.seletingTable.toggleRowSelection(obj)
},
handleCurrentChange(val) {
this.pageNum = val
this.getSelectingList()
},
handleRelateStoreConfirm() {
this.$emit("handleRelateStoreConfirm", this.selectedData)
},
handleRelateStoreClose() {
this.$emit("handleRelateStoreClose")
}
}
}
</script>
<style lang="scss">
.relateStore .table {
margin: 0 auto 20px !important;
width: 98%;
}
.relateStore .tableCon {
margin-top: 20px;
display: flex;
.tableBox {
flex: 1;
}
}
.service-store .relateStore .el-table .cell,
.d2-form .relateStore .el-table .cell {
line-height: 26px !important;
}
.service-store .relateStore .el-table--medium td,
.d2-form .relateStore .el-table--medium td {
padding: 6px 8px !important;
}
.relateStore .red {
color: red;
}
.relateStore .tip-icon {
position: absolute;
display: inline-block;
height: 10px;
width: 10px;
line-height: 10px;
color: #ffffff;
background-color: red;
border: 1px solid red;
border-radius: 50%;
cursor: pointer;
font-size: 6px;
margin-left: 2px;
}
</style>
......@@ -6,14 +6,18 @@
size="small"
icon="el-icon-puls"
key="btn-i"
@click="selectFile()">上传文件</el-button>
:disabled="imageUrlArr.length"
@click="selectFile()"
>上传文件</el-button
>
<input
type="file"
ref="uploadImgRef"
class="upload-img"
style="opacity: 0; z-index: -1"
accept=".pdf"
@change="(e) => handleImgChange(e)" />
@change="(e) => handleImgChange(e)"
/>
</div>
<template v-if="imageUrlArr && imageUrlArr.length > 0">
<div class="file-wrap" v-for="(item, index) in imageUrlArr" :key="index">
......@@ -26,14 +30,16 @@
class="process"
:style="{
width: item.image ? '432px' : (compress * 432) / 100 + 'px'
}"></div>
}"
></div>
</div>
<img
v-if="item.image"
class="del-btn"
:src="require('@/assets/icon-delete.png')"
alt=""
@click="delFile(index)" />
@click="delFile(index)"
/>
</div>
</template>
</div>
......
......@@ -16,8 +16,9 @@
<el-image
v-if="orderInfo[item.prop]"
style="width: 88px; height: 88px"
:src="orderInfo[item.prop]"
:preview-src-list="[orderInfo[item.prop]]">
:src="orderInfo[item.prop] || ''"
:preview-src-list="[orderInfo[item.prop]]"
>
</el-image>
<span v-else>--</span>
</div>
......@@ -25,7 +26,8 @@
<div
v-for="(i, idx) in orderInfo[item.prop]"
:key="idx"
class="img-box mar">
class="img-box mar"
>
<!-- <el-image
v-if="orderInfo.type == 0"
style="width: 88px; height: 88px"
......@@ -37,7 +39,8 @@
@click="showMiniView"
:src="i"
style="width: 88px; height: 88px; cursor: pointer"
v-if="orderInfo.type == 0" />
v-if="orderInfo.type == 0"
/>
<video
controls
style="
......@@ -47,7 +50,8 @@
border-radius: 4px;
"
v-else-if="orderInfo.type == 1"
:src="i"></video>
:src="i"
></video>
<div v-if="orderInfo.type == 2" class="file-box">
<div @click="toOpenPDF(i)" class="file-box-inner">
<img class="icon" src="../../assets/pdf.png" />
......@@ -77,8 +81,8 @@
orderInfo.showMerchant == 1
? "指定品牌"
: orderInfo.showMerchant == 2
? "指定门店"
: "全部门店"
? "指定门店"
: "全部门店"
}}
</div>
<el-table
......@@ -91,21 +95,25 @@
}"
:row-style="{ height: '48px' }"
style="width: 100%"
:height="orderInfo[item.prop].length > 10 ? '350' : ''">
:height="orderInfo[item.prop].length > 10 ? '350' : ''"
>
<el-table-column
type="index"
align="center"
width="80"
label="序号"></el-table-column>
label="序号"
></el-table-column>
<el-table-column
prop="assignName"
align="center"
:label="orderInfo.showMerchant == 1 ? '品牌名称' : '园区店名称'" />
:label="orderInfo.showMerchant == 1 ? '品牌名称' : '园区店名称'"
/>
<el-table-column
v-if="orderInfo.showMerchant == 2"
prop="assignId"
align="center"
label="园区店号" />
label="园区店号"
/>
</el-table>
</div>
</div>
......@@ -116,7 +124,8 @@
:visible="showImageView"
:list="orderInfo.contentList"
:title="orderInfo.title"
@closeDialog="closeDialog"></previewEffectDialog>
@closeDialog="closeDialog"
></previewEffectDialog>
</d2-container>
</template>
......
<!-- 员工群发 - 列表 -->
<template>
<div>
<!-- class="order-detail" -->
<d2-container>
<!-- <div class="offline-account"> -->
<div class="header" slot="header" style="padding: 10px 20px">
<d2-search
ref="showSearch"
class="show-search"
:search-form="searchForm"
:label-width="labelWidth"
:form-data="showFormData"
/>
<div class="up-btns">
<el-button @click="handleSearch" size="small" type="primary">
查询
</el-button>
<el-button size="small" @click="handleReset"> 重置 </el-button>
</div>
</div>
<!-- </d2-container>
<d2-container> -->
<div class="d2-container-content">
<d2-table-header>
<auth-button category="Button" />
</d2-table-header>
<d2-table
ref="recordTable"
:get-list-api="getListApi"
:search-form="searchFormSearch"
:table-params="tableParams"
:before-search-fn="beforeSearchFn"
>
<div slot="auth-button" slot-scope="scope">
<span style="margin-right: 10px">
<auth-button :data="scope.scope" :show-btn-ids="['9130502']" />
</span>
<span
style="margin-right: 10px"
v-if="scope.scope.sendStatus == 1 || scope.scope.sendStatus == 2"
>
<auth-button :data="scope.scope" :show-btn-ids="['9130503']" />
</span>
<span style="margin-right: 10px" v-if="scope.scope.sendStatus == 3">
<auth-button :data="scope.scope" :show-btn-ids="['9130504']" />
</span>
<span
style="margin-right: 10px"
v-if="scope.scope.sendStatus == 1 || scope.scope.sendStatus == 2"
>
<auth-button :data="scope.scope" :show-btn-ids="['9130505']" />
</span>
</div>
</d2-table>
</div>
</d2-container>
<!-- 新增提现 -->
<!-- <add-dialog :add-visible="addVisible"
v-if="addVisible"
@dialogClose="addDialogClose" /> -->
</div>
</template>
<script>
import { Util, deepClone } from "@/common/util"
import { mapActions, mapState } from "vuex"
import { contentTypeList, sendStatusList } from "@/common/constants.js"
// import { rewithdraw } from '@api/withdrawalManage'
import { contentManagerTaskPage, deleteTaskById } from "@api/contentManager"
// import addDialog from './components/addDialog'
export default {
name: "StaffMassSendingIndex",
components: {
// addDialog
},
data() {
return {
userInfo: this.$store.state.d2admin.user.info,
labelWidth: "100px",
searchForm: {
title: "",
contentType: "",
sendStatus: ""
},
searchFormSearch: {},
showFormData: [
{
label: "标题",
name: "title",
type: "input",
maxlength: "20",
isClear: true
},
{
label: "类型",
name: "contentType",
type: "select",
optionList: [],
optionId: "confId",
optionLabel: "confValue",
optionsName: "contentTypeList"
},
{
label: "状态",
name: "sendStatus",
type: "select",
optionList: [],
optionId: "confId",
optionLabel: "confValue",
optionsName: "sendStatusList"
}
],
getListApi: contentManagerTaskPage,
tableParams: {
btnId: new Date().getTime() + parseInt(Math.random() * 1000),
listName: "list",
// tableOption: { width: '200px' },
tableOption: true,
tableColumns: [
{
label: "标题",
prop: "title"
// width: '200px'
},
{
label: "类型",
prop: "contentType",
width: "100px",
formatter: (cellValue) => {
return this.baseData.contentTypeList.find(
(item) => item.confId === cellValue.contentType
)?.confValue
}
},
{
label: "发送时间",
prop: "sendTime",
width: "150px",
formatter: (cellValue) => {
if (cellValue.sendType == 1) {
// 发送方式(1.即时推送,2:定时推送)
return "立即发送"
} else {
return cellValue.sendTime
? Util.dateFormate(cellValue.sendTime, "YYYY-MM-DD HH:mm:ss")
: "--"
}
}
},
{
label: "发送员工",
prop: "sendTotal",
width: "100px"
},
{
label: "状态",
prop: "sendStatus",
width: "100px",
formatter: (cellValue) => {
return this.baseData.sendStatusList.find(
(item) => item.confId === cellValue.sendStatus
)?.confValue
}
},
{
label: "创建时间",
prop: "createdDate",
width: "150px",
formatter: (cellValue) => {
return cellValue.createdDate
? Util.dateFormate(cellValue.createdDate, "YYYY-MM-DD HH:mm:ss")
: "--"
}
}
]
},
baseData: {
contentTypeList: deepClone(contentTypeList),
sendStatusList: deepClone(sendStatusList)
},
infos: [],
recordInfo: null,
addVisible: false
}
},
computed: {
...mapState({
dowloadList: (state) => state.d2admin.user.dowloadList
})
},
mounted() {
this.getBaseData()
},
methods: {
...mapActions({
get: "d2admin/base/get",
close: "d2admin/page/close"
}),
...mapActions("d2admin/user", ["actionSetDownloadList"]),
async getBaseData() {
this.getOptionsList()
},
beforeSearchFn() {
return new Promise((resolve) => {
this.searchFormSearch = deepClone(this.searchForm)
resolve()
})
},
getOptionsList() {
this.showFormData.forEach((item, index) => {
if (item.type === "select") {
if (
this.baseData[item.optionsName].length &&
this.baseData[item.optionsName][0][
this.showFormData[index].optionLabel
] !== "全部"
) {
const temp = {}
temp[this.showFormData[index].optionId] = ""
temp[this.showFormData[index].optionLabel] = "全部"
this.baseData[item.optionsName].unshift(temp)
}
this.$set(
this.showFormData[index],
"optionList",
this.baseData[item.optionsName]
)
}
})
},
handleSearch() {
this.$refs.recordTable.refreshTable(false, true)
},
handleReset() {
this.searchForm = {
title: "",
contentType: "",
sendStatus: ""
}
this.$refs.recordTable.refreshTable(false, true)
},
handleAdd(scope) {
console.log(scope)
// this.addVisible = !this.addVisible
if (scope) {
this.$router.push({
name: "SopContentAdd",
query: {
id: scope.id
}
})
} else {
this.$router.push({ name: "SopContentAdd" })
}
},
handleDetail(row) {
this.$router.push({
name: "sopContentDetail",
query: {
id: row.id
}
})
},
addDialogClose(obj) {
this[obj.attrName] = !this[obj.attrName]
if (obj.flag) {
this.$refs.recordTable.refreshTable()
}
},
// 删除
handleDel(row) {
this.$confirm("删除后不可恢复,是否确定删除?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
closeOnClickModal: false
})
.then(() => {
deleteTaskById({ id: row.id }).then((res) => {
this.notice.okTips()
this.$refs.recordTable.refreshTable()
})
})
.catch((err) => {
console.log(err)
})
},
goStatisticsPage(row) {
this.$router.push({
name: "statisticsPage",
query: {
id: row.id,
title: row.title
}
})
}
}
}
</script>
<style scoped>
.count-txt {
font-weight: 700;
color: #2a58ad;
margin: 0 2px;
}
.leftSpan {
display: inline-block;
box-sizing: border-box;
margin-right: 10px;
}
</style>
<!-- 员工群发 - 统计列表 -->
<template>
<div>
<!-- class="order-detail" -->
<d2-container>
<!-- <div class="offline-account"> -->
<div class="header"
slot="header"
style="padding: 10px 20px">
<div class="header-bar">
<h3>{{ title }}</h3>
<div class="btn">
<el-button size="small"
@click="handleRecord"> 返回 </el-button>
</div>
</div>
<d2-search ref="showSearch"
class="show-search"
:search-form="searchForm"
:label-width="labelWidth"
:form-data="showFormData" />
<div class="up-btns">
<el-button @click="handleSearch"
size="small"
type="primary">
查询
</el-button>
<el-button size="small"
@click="handleReset"> 重置 </el-button>
</div>
</div>
<!-- </d2-container>
<d2-container> -->
<div class="d2-container-content">
<d2-table-header>
<auth-button category="Button" />
</d2-table-header>
<d2-table ref="recordTable"
:get-list-api="getListApi"
:search-form="searchFormSearch"
:table-params="tableParams"
:before-search-fn="beforeSearchFn">
</d2-table>
</div>
</d2-container>
</div>
</template>
<script>
import { Util, deepClone } from "@/common/util"
import { mapActions, mapState } from "vuex"
import { getStatisticPage } from "@api/contentManager"
export default {
name: "StatisticPage",
data() {
return {
userInfo: this.$store.state.d2admin.user.info,
labelWidth: "100px",
searchForm: {
staffName: "",
phoneNumber: "",
lookDate: ""
},
searchFormSearch: {},
showFormData: [
{
label: "员工姓名",
name: "staffName",
type: "input",
maxlength: "20",
isClear: true
},
{
label: "手机号",
name: "phoneNumber",
type: "input",
inputType: "number",
maxlength: "11",
isClear: true
},
{
label: "查看时间",
name: "lookDate",
type: "datePicker",
isClear: true,
pickerOptions: "rangePickerOptions"
}
],
getListApi: getStatisticPage,
tableParams: {
btnId: new Date().getTime() + parseInt(Math.random() * 1000),
listName: "list",
tableOption: false,
tableColumns: [
{
label: "员工姓名",
prop: "staffName"
// width: '200px'
},
{
label: "员工手机号",
prop: "phoneNumber"
// width: '150px'
},
{
label: "发送时间",
prop: "sendTime",
// width: '150px',
formatter: (cellValue) => {
return cellValue.sendTime
? Util.dateFormate(cellValue.sendTime, "YYYY-MM-DD HH:mm:ss")
: "--"
}
},
{
label: "首次查看时间",
prop: "firstViewTime",
// width: '150px',
formatter: (cellValue) => {
return cellValue.firstViewTime
? Util.dateFormate(
cellValue.firstViewTime,
"YYYY-MM-DD HH:mm:ss"
)
: "--"
}
},
{
label: "总浏览时长",
prop: "totalViewTime",
formatter: (cellValue) => {
return cellValue.totalViewTime ? cellValue.totalViewTime + "s" : '--'
}
}
]
},
baseData: {},
title: ""
}
},
computed: {
...mapState({
dowloadList: (state) => state.d2admin.user.dowloadList
})
},
mounted() {
this.title = this.$route.query.title
this.getBaseData()
},
methods: {
...mapActions({
get: "d2admin/base/get",
close: "d2admin/page/close"
}),
...mapActions("d2admin/user", ["actionSetDownloadList"]),
async getBaseData() {
this.getOptionsList()
},
beforeSearchFn() {
return new Promise((resolve) => {
this.searchFormSearch = deepClone(this.searchForm)
if (this.searchFormSearch.lookDate) {
this.searchFormSearch.startDate = Util.dateFormate(
this.searchFormSearch.lookDate[0],
"YYYY-MM-DD"
)
this.searchFormSearch.endDate = Util.dateFormate(
this.searchFormSearch.lookDate[1],
"YYYY-MM-DD"
)
delete this.searchFormSearch.lookDate
}
this.searchFormSearch.taskId = this.$route.query.id
resolve()
})
},
getOptionsList() {
this.showFormData.forEach((item, index) => {
if (item.type === "select") {
if (
this.baseData[item.optionsName].length &&
this.baseData[item.optionsName][0][
this.showFormData[index].optionLabel
] !== "全部"
) {
const temp = {}
temp[this.showFormData[index].optionId] = ""
temp[this.showFormData[index].optionLabel] = "全部"
this.baseData[item.optionsName].unshift(temp)
}
this.$set(
this.showFormData[index],
"optionList",
this.baseData[item.optionsName]
)
}
})
},
handleSearch() {
this.$refs.recordTable.refreshTable(false, true)
},
handleReset() {
this.searchForm = {
staffName: "",
phoneNumber: "",
lookDate: ""
}
this.$refs.recordTable.refreshTable(false, true)
},
handleExport() {
var params = this.searchFormSearch
// 去除为null的值
for (const key in params) {
if (
params[key] === null ||
params[key] === "" ||
params[key].length == 0
) {
delete params[key]
}
}
// 内容管理统计信息导出
params.method =
"dj.api.smartcarlife.contentManagerTask.statistic.export.async"
const list = [
...this.dowloadList,
{
name: "统计信息",
exportParam: JSON.stringify(params),
status: "waiting",
timeid: new Date().getTime()
}
]
this.actionSetDownloadList({ list, type: "dowloadList" })
},
handleRecord() {
this.$router.push({ name: "staffMassSending" })
}
}
}
</script>
<style scoped lang="scss">
.count-txt {
font-weight: 700;
color: #2a58ad;
margin: 0 2px;
}
.leftSpan {
display: inline-block;
box-sizing: border-box;
margin-right: 10px;
}
.header-bar {
display: flex;
align-items: center;
.btn {
margin-left: 15px;
}
}
</style>
......@@ -54,7 +54,6 @@
</el-table-column>
<el-table-column prop="outputValue" label="区域督导" width="150">
<template slot-scope="scope">
<!-- multiple -->
<el-select clearable filterable value-key="userId" v-model="scope.row['areaSupervision']" class="select"
collapse-tags placeholder="请选择">
<el-option v-for="item in supervisionOptionsList" :key="item.userId" :label="item.userName"
......
......@@ -30,9 +30,8 @@
<auth-button category="Button" :show-btn-ids="['90706']" />
</div>
<div class="inputTargetBtn">
<div @click="goCheck" v-if="checkBtnFlag"
style="margin-right: 32px;"><i class="el-icon-chat-round"></i>查看企微推送对象</div>
<div @click="outputVisible = true" v-if="editBtnFlag"><i class="el-icon-edit"></i>编辑单店信息</div>
<div @click="goCheck" v-if="checkBtnFlag"><i class="el-icon-chat-round"></i>查看企微推送对象</div>
<!-- <div @click="outputVisible = true" v-if="editBtnFlag"><i class="el-icon-edit"></i>编辑单店信息</div> -->
</div>
</div>
</el-card>
......
......@@ -17,7 +17,7 @@
v-for="(item, index) in defenceDetail.detailList"
:key="item.is"
>
<div class="dialog-head" >
<div class="dialog-head">
<img
class="attack-score"
src="../../../assets/attack-score.png"
......@@ -25,7 +25,9 @@
/>
<div class="text">攻防得分</div>
<div class="score">{{ item.defScore ? item.defScore : "-" }}</div>
<div class="text" @click="handleMapping(item.mergedOffset)">对话开始时间</div>
<div class="text" @click="handleMapping(item.mergedOffset)">
对话开始时间
</div>
<div class="time" @click="handleMapping(item.mergedOffset)">
{{ item.conStartTime ? item.conStartTime : "-" }}
</div>
......@@ -59,7 +61,7 @@
<div class="dig-content" @click="currentDialog(item)">
{{ item.answer }}
</div>
<br/>
<br />
<div class="suggest">
<div class="improve">
<img src="@/assets/improve.png" class="improve-img" />
......@@ -92,7 +94,15 @@
<img src="@/assets/empty-2.png" />
</div>
<div class="text">
{{ detailObj.defence === 1||detailObj.defence === 0||detailObj.defence === 4 ? '数据分析中,请稍等' : detailObj.defence === 3?'未发现攻防':'未进行攻防识别' }}
{{
detailObj.defence === 1 ||
detailObj.defence === 0 ||
detailObj.defence === 4
? "数据分析中,请稍等"
: detailObj.defence === 3
? "未发现攻防"
: "未进行攻防识别"
}}
</div>
</div>
</template>
......@@ -140,12 +150,13 @@ export default {
},
methods: {
handleMapping(time) {
Array.prototype.slice.call(this.$parent.$parent.$children).forEach(dom=>{
if(dom.currentDialog){
dom.currentDialog(time)
}
})
Array.prototype.slice
.call(this.$parent.$parent.$children)
.forEach((dom) => {
if (dom.currentDialog) {
dom.currentDialog(time)
}
})
},
getDefenceDetail() {
let params = {
......@@ -157,7 +168,7 @@ export default {
})
},
regText(highlight, value) {
highlight = highlight && JSON.parse(highlight)
highlight = highlight ? JSON.parse(highlight):[]
let replacedText = value
if (value) {
highlight.forEach((item) => {
......@@ -233,7 +244,7 @@ export default {
.time {
font-weight: 400;
font-size: 14px;
color: #2A58AD;
color: #2a58ad;
margin-left: 6px;
cursor: pointer;
}
......@@ -290,7 +301,6 @@ export default {
text-align: left;
margin: -14px 0 0 40px;
line-height: 20px;
}
.suggest {
width: fit-content;
......
......@@ -107,7 +107,7 @@ export default {
isMuted: true,
dialogList: [],
totalTime: "0:00",
currentTime: "0:00",
currentTime: "00:00",
isCircle: false,
activeName: "dialog",
loading: true
......@@ -129,9 +129,9 @@ export default {
toMinutesAndSeconds(seconds) {
let minutes = Math.floor(seconds / 60)
let remainingSeconds = parseInt(seconds % 60)
minutes = minutes > 10 ? minutes : `0${minutes}`
minutes = minutes > 9 ? minutes : `0${minutes}`
remainingSeconds =
remainingSeconds > 10 ? remainingSeconds : `0${remainingSeconds}`
remainingSeconds > 9 ? remainingSeconds : `0${remainingSeconds}`
return `${minutes}:${remainingSeconds}`
},
handleprogress() {
......
// 雷达图
const radarChartOption = {
tooltip: {},
radar: {
// 初始指示器
indicator: [],
name: {
rich: {
star: {
fontSize: 12,
backgroundColor: {
image: 'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/aiCheck/star-1.png'
}
},
halfStar: {
fontSize: 12,
backgroundColor: {
image: 'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/aiCheck/pc-star-2.png'
}
},
emptyStar: {
fontSize: 12,
backgroundColor: {
image: 'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/aiCheck/pc-star-0.png'
}
},
name: {
color: '#333',
fontSize: 12,
align: 'center'
}
},
formatter: function (v, indicator) {
const createStarRating = (rating) => {
const fullStars = Math.floor(rating)
const halfStar = (rating) % 1 === 0.5
const emptyStars = 5 - fullStars - (halfStar ? 1 : 0)
let stars = ''
for (let i = 0; i < fullStars; i++) {
stars += '{star|}'
}
if (halfStar) {
stars += '{halfStar|}'
}
for (let i = 0; i < emptyStars; i++) {
stars += '{emptyStar|}'
}
return stars
}
return `{name|${v}}\n${createStarRating(indicator.score)}`
},
width: 65,
height: 28
},
nameGap: 0,
shape: 'polygon',
axisLine: {
show: false
},
splitLine: {
lineStyle: {
color: '#EDEDED'
}
},
splitArea: {
areaStyle: {
color: ['#fff', '#fff', '#fff', '#fff', '#fff']
}
},
startAngle: 90
},
series: [{
type: 'radar',
silent: false,
// 数据
data: [
{
value: [50, 60, 70, 20, 60],
name: '雷达图',
symbol: 'none',
lineStyle: {
color: "#3F64B0",
width: 1,
},
areaStyle: {
color: "#496CB5",
opacity: 0.2
},
blur: {
lineStyle: {
color: "#3F64B0",
width: 1,
}
}
}
]
}],
tooltip: {
show: false
}
}
// 流利度
const waveChartOption = {
title: {
text: '语速变化曲线',
left: 'left',
textStyle: {
color: '#333333',
fontSize: 14,
height: 20,
fontWeight: 400
},
padding: [0, 0, 0, 15]
},
grid: {
left: 20,
right: 20,
bottom: 20,
top: 40
},
legend: {
data: ['目标范围'],
right: 'right',
top: 'top',
itemWidth: 0,
itemHeight: 0,
formatter: function(name) {
return '{name|} ' + name
},
textStyle: {
rich: {
name: {
width: 12,
height: 6,
backgroundColor: '#E5EDFE',
}
}
},
selectedMode: false
},
xAxis: {
type: 'category',
boundaryGap: false,
data: [],
axisLabel: {
color: '#999EA8',
},
axisTick: {
show: false, // 隐藏x轴刻度
},
axisLine: {
lineStyle: {
color: '#F2F1FF',
width: 1
}
}
},
yAxis: {
type: 'value',
show: true, // 隐藏y轴
axisLine: {
show: false
},
// min: 0,
axisTick: {
show: false
},
axisLabel: {
show: false
},
splitLine: {
show: true,
lineStyle: {
type: 'dashed',
color: '#E5E5EF',
width: 1
}
},
},
series: [
{
name: '语速',
type: 'line',
data: [], // 设置语速数据的y轴数据
symbol: 'none', // 隐藏数据点
smooth: true, // 使线条平滑
lineStyle: {
color: '#496CB5',
width: 1,
},
markArea: {
silent: true,
data: [],
itemStyle: {
color: '#3275FA',
opacity: 0.1
}
}
},
{
name: '目标范围',
type: 'line'
}
]
}
// 冗余词
const pieChartOption = {
title: {
text: '冗余词统计',
left: 'left',
textStyle: {
color: '#333333',
fontSize: 14
}
},
tooltip: {
trigger: 'item'
},
legend: {
orient: 'vertical',
top: 'middle',
right: 40,
formatter: function(name) {
const data = pieChartOption.series[0].data;
let value = 0;
for (let i = 0; i < data.length; i++) {
if (data[i].name === name) {
value = data[i].value;
}
}
return `${name}\u2003\u2003\u2003\u2003${value}`;
},
width: 60,
itemWidth: 10,
itemHeight: 10
},
graphic: {
type: 'text',
left: 180,
top: 'center',
style: {
text: '冗余词',
textAlign: 'center',
fill: '#292D33',
fontSize: 14,
}
},
series: [
{
name: '冗余词',
type: 'pie',
radius: ['50%', '70%'],
center: [200, '50%'],
avoidLabelOverlap: true,
itemStyle: {
borderColor: '#fff',
borderWidth: 2
},
label: {
show: true,
position: 'inside',
formatter: '{c}',
color: '#fff',
rich: {
align: 'center',
verticalAlign: 'middle',
fontSize: 12,
}
},
labelLine: {
show: false
},
data: []
}
]
}
// 语音表达-清晰度
const waveChartOption1 = {
title: {
text: '清晰度变化曲线',
left: 'left',
textStyle: {
color: '#333333',
fontSize: 14,
height: 20,
fontWeight: 400
},
padding: [0, 0, 0, 15]
},
grid: {
left: 20,
right: 20,
bottom: 20,
top: 40
},
legend: {
data: ['目标范围'],
right: 'right',
top: 'top',
itemWidth: 0,
itemHeight: 0,
formatter: function(name) {
return '{name|} ' + name
},
textStyle: {
rich: {
name: {
width: 12,
height: 6,
backgroundColor: '#E5EDFE',
}
}
},
selectedMode: false
},
xAxis: {
type: 'category',
boundaryGap: false,
data: [],
axisLabel: {
color: '#999EA8',
},
axisTick: {
show: false, // 隐藏x轴刻度
},
axisLine: {
lineStyle: {
color: '#F2F1FF',
width: 1
}
}
},
yAxis: {
type: 'value',
show: true, // 隐藏y轴
axisLine: {
show: false
},
// min: 0,
axisTick: {
show: false
},
axisLabel: {
show: false
},
splitLine: {
show: true,
lineStyle: {
type: 'dashed',
color: '#E5E5EF',
width: 1
}
},
},
series: [
{
name: '清晰度',
type: 'line',
data: [], // 设置清晰度数据的y轴数据
symbol: 'none', // 隐藏数据点
smooth: true, // 使线条平滑
lineStyle: {
color: '#496CB5',
width: 1,
},
markArea: {
silent: true,
data: [],
itemStyle: {
color: '#3275FA',
opacity: 0.1
}
}
},
{
name: '目标范围',
type: 'line'
}
]
}
// 语音表达-语调
const waveChartOption2 = {
title: {
text: '语调变化曲线',
left: 'left',
textStyle: {
color: '#333333',
fontSize: 14,
height: 20,
fontWeight: 400
},
padding: [0, 0, 0, 15]
},
grid: {
left: 20,
right: 20,
bottom: 20,
top: 40
},
legend: {
data: ['目标范围'],
right: 'right',
top: 'top',
itemWidth: 0,
itemHeight: 0,
formatter: function(name) {
return '{name|} ' + name
},
textStyle: {
rich: {
name: {
width: 12,
height: 6,
backgroundColor: '#E5EDFE',
}
}
},
selectedMode: false
},
xAxis: {
type: 'category',
boundaryGap: false,
data: [],
axisLabel: {
color: '#999EA8',
},
axisTick: {
show: false, // 隐藏x轴刻度
},
axisLine: {
lineStyle: {
color: '#F2F1FF',
width: 1
}
}
},
yAxis: {
type: 'value',
show: true, // 隐藏y轴
axisLine: {
show: false
},
// min: 0,
axisLabel: {
show: false
},
axisTick: {
show: false
},
splitLine: {
show: true,
lineStyle: {
type: 'dashed',
color: '#E5E5EF',
width: 1
}
},
},
series: [
{
name: '语调',
type: 'line',
data: [],
symbol: 'none', // 隐藏数据点
smooth: true, // 使线条平滑
lineStyle: {
color: '#496CB5',
width: 1,
},
markArea: {
silent: true,
data: [],
itemStyle: {
color: '#3275FA',
opacity: 0.1
}
}
},
{
name: '目标范围',
type: 'line'
}
]
}
export default {
radarChartOption: radarChartOption,
waveChartOption: waveChartOption,
pieChartOption: pieChartOption,
waveChartOption1: waveChartOption1,
waveChartOption2: waveChartOption2
}
\ No newline at end of file
// 语速结果
const speedText = ['急速', '极慢', '快速', '缓慢', '适中']
// 语速描述
const speedDescribe = [
'您的语速极快,几乎听不出单词之间的停顿,可能会导致听众难以理解,尤其是在不熟悉的话题或复杂的讨论中。',
'您的语速极慢,每个词之间有明显的停顿,通常用于强调某些信息或确保听众能够完全理解。',
'您的语速较快,词汇之间的间隔较短,可能需要听众集中注意力才能跟上,但仍然可以保持清晰度。',
'您的语速较慢,适合于清晰的沟通和教学,给听众足够的时间来消化和理解信息。',
'您的语速适中,既不过快也不过慢,是大多数日常对话和正式演讲的理想速度,便于听众跟随和理解。'
]
// 冗余词描述
const toneList = [
'您的语言表达充斥着大量不必要的重复词汇,几乎让人无法理解其意图,严重影响沟通效果。',
'您的冗余词汇使用过多,导致表达显得啰嗦,可能会让听者或读者感到困惑,需要仔细分辨才能理解核心信息。',
'您的表达中频繁出现冗余词汇,虽然不影响主要信息的传达,但会使语言显得有些啰嗦。',
'您偶尔出现一些不必要的词汇,但整体上不影响理解,语言仍然保持较高的清晰度。',
'您的语言表达简洁明了,没有任何不必要的冗余词汇,信息传达直接高效。'
]
// 冗余词汇
const toneWords = ['嗯', '额', '哦', '啊', '呵', '哈', '呀', '呢', '吗', '呗']
// 清晰度结果
const definitionText = ['模糊', '含糊', '适中', '明白', '清晰']
// 清晰度描述
const definitionDescribe = [
'您的发音严重不准确,大量音节和音素模糊不清,听众很难理解说话者的意图,沟通效果极差。',
'您的发音不够准确,有些音节和音素模糊不清,听众可能需要更加集中注意力或请求重复才能理解全部内容。',
'您的发音基本准确,部分音节可能不够清晰,但大部分信息仍然可以传达给听众,偶尔需要听众集中注意力才能完全理解。',
'您的发音较为准确,大部分音节和音素清晰,偶尔有轻微的模糊,但不影响整体理解。',
'您的发音准确,每个音节和音素都清晰可辨,没有任何模糊或含糊的地方,听众可以轻松理解每一个词。'
]
// 语调结果
const intonationText = ['单调', '平和', '适中', '激昂', '丰富']
// 语调描述
const intonationDescribe = [
'您的语调过于单调,听起来平淡无奇,容易让听众感到十分乏味或缺乏兴趣。',
'您的语调几乎不变,缺乏情感和活力,可能会让听众感到乏味。',
'您的语调有轻微的升降和强弱变化,足够表达基本的情感和强调,但变化不大。',
'您的语调有明显的升降和强弱变化,能够有效地传达情感和强调重点,使语言更加生动和吸引人。',
'您的语调变化丰富,能够充分表达复杂的情感和细微的差别,使语言表达更加生动和有感染力。'
]
// 冗余词颜色
const colorContentData = [{
name: '嗯',
color: '#5D95FF'
}, {
name: '额',
color: '#63D7E1'
}, {
name: '哦',
color: '#5FD190'
}, {
name: '啊',
color: '#AED14B'
}, {
name: '呵',
color: '#FFB13B'
}, {
name: '哈',
color: '#F7CD23'
}, {
name: '呀',
color: '#F48670'
}, {
name: '呢',
color: '#F8A9DE'
}, {
name: '吗',
color: '#D8A2FC'
}, {
name: '呗',
color: '#858DFF'
}]
export default {
speedText,
speedDescribe,
toneList,
toneWords,
definitionText,
definitionDescribe,
intonationText,
intonationDescribe,
colorContentData
}
<!-- 关联活动订单弹窗 -->
<template>
<d2-dialog
title="质检详情"
title="查看结果"
:is-visible="isQualityVisible"
class="qualityDailog"
width="80%"
@closeDialog="handleClose"
@confirmDialog="handleClose">
@confirmDialog="handleClose"
:isShowFooter="false"
:noCancel="true"
>
<div>
<el-tabs v-model="activeName" @tab-click="handleReset">
<el-tab-pane label="质检分析" name="analyse">
<quality-analyse v-if="activeName == 'analyse'" v-bind="$attrs" ref="analyseList" />
<el-tab-pane label="评测报告" name="evaluating">
<evaluating-report
v-if="activeName == 'evaluating'"
v-bind="$attrs"
ref="evaluatingReport"
/>
</el-tab-pane>
<el-tab-pane label="对练详情" name="dialogue">
<dialogue-detail
v-if="activeName == 'dialogue'"
ref="dialogueDetail"
v-bind="$attrs" />
v-bind="$attrs"
/>
</el-tab-pane>
<el-tab-pane label="质检详情" name="analyse">
<quality-analyse
v-if="activeName == 'analyse'"
v-bind="$attrs"
ref="analyseList"
/>
</el-tab-pane>
</el-tabs>
</div>
......@@ -28,15 +43,17 @@ import { Util } from "@/common/util"
import { shopmallOrderList } from "@api/order"
import QualityAnalyse from "./qualityInspectionAnalyse"
import DialogueDetail from "./pairDetail"
import evaluatingReport from "./evaluatingReport"
export default {
name: "DialogResult",
components: {
QualityAnalyse,
DialogueDetail
DialogueDetail,
evaluatingReport
},
data() {
return {
activeName: "analyse",
activeName: "evaluating",
userInfo: this.$store.state.d2admin.user.info,
countObj: {},
searchForm: {
......
<!-- 流利度 -->
<template>
<div>
<div class="box">
<div class="box-item">
<div class="left">
<div class="title">语速</div>
<div class="value">{{ speedData.starText }}</div>
</div>
<div class="line"></div>
<div class="content-text">{{ speedData.starDescribe }}</div>
</div>
<div class="box-item">
<div class="left">
<div class="title">冗余词</div>
<div class="value">{{ wordsData.wordNum }}个</div>
</div>
<div class="line"></div>
<div class="content-text">{{ wordsData.resultWords }}</div>
</div>
</div>
<div class="chart-box">
<div class="wave-chart" id="wave-chart"></div>
<div class="pie-chart">
<div v-if="wordsData.wordNum > 0" class="pie-chart" id="pie-chart"></div>
<div class="empty-box" v-else>
<div class="icon">
<img src="@/assets/empty-3.png" />
</div>
<div class="text">
无冗余词
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import chartOption from './chartOption'
import * as echarts from 'echarts'
import contantData from './contantData'
export default {
name: 'fluency',
props: {
itemData: {
type: Object,
default: () => ({})
}
},
data() {
return {
wordsData: {},
speedData: {}
}
},
mounted() {
this.initData()
},
methods: {
initData() {
this.filterWordsData()
this.filterSpeedData()
this.$nextTick(() => {
window.addEventListener("resize", () => this.resize())
})
},
resize() {
this.waveChart && this.waveChart.resize()
this.pieChart && this.pieChart.resize()
},
// 处理冗余词数据
filterWordsData() {
const toneWords = contantData.toneWords
const toneList = contantData.toneList
// 构建一个正则表达式,匹配数组h中每个元素的叠词
const regex = new RegExp(`(${toneWords.map(str => str.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&')).join('|')})\\1+`, 'g');
const {redundantWords} = this.itemData.fluency
let words = ''
try {
words = JSON.parse(redundantWords).content
} catch (error) {
}
const matches = words.match(regex)||[];
let redundantWordsList = new Map()
matches.forEach((i) => {
const l = i.slice(0, 1);
const v = redundantWordsList.get(l);
if (v) {
redundantWordsList.set(l, v + (i.length - 1));
} else {
redundantWordsList.set(l, i.length - 1);
}
});
const positionX = [...redundantWordsList.keys()]
const positionY = [...redundantWordsList.values()];
const wordNum = positionY.reduce((cur,prev)=>{
return cur+prev
},0)
let star = 5 - Math.ceil(wordNum/2)
if(star < 1) {
star = 1
}
this.wordsData = {
wordNum,
resultWords: toneList[star - 1],
positionX,
positionY
}
if (wordNum > 0) this.initPieChart()
},
// 处理语速数据
filterSpeedData() {
const { speechSpeed } = this.itemData.fluency
let data = {}
try {
data = JSON.parse(speechSpeed)
} catch (error) {
}
this.speedData = {
starText: contantData.speedText[data?.star - 1],
starDescribe: contantData.speedDescribe[data?.star - 1],
x: data?.x,
y: data?.y,
min: data?.min,
max: data?.max
}
if (data?.x && data?.y) this.initWaveChart()
},
initWaveChart() {
this.$nextTick(() => {
this.waveChart = echarts.init(document.getElementById('wave-chart'))
chartOption.waveChartOption.xAxis.data = this.speedData.x
chartOption.waveChartOption.yAxis.max = this.speedData.max > Math.max(...this.speedData.y) ? this.speedData.max : Math.max(...this.speedData.y)
chartOption.waveChartOption.series[0].data = this.speedData.y
chartOption.waveChartOption.series[0].markArea.data = [
[{ xAxis: this.speedData.x[0], yAxis: this.speedData.min }, { xAxis: this.speedData.x[this.speedData.x.length - 1], yAxis: this.speedData.max }]
]
chartOption.waveChartOption.xAxis.axisLabel.formatter = (value, index) => {
if (index == 0 || index == this.speedData.x.length - 1) {
return value
} else {
return ''
}
}
this.waveChart.setOption(chartOption.waveChartOption)
})
},
initPieChart() {
this.$nextTick(() => {
let result = this.wordsData?.positionX.map((name, index) => {
let color = contantData.colorContentData.find((item) => item.name == name)?.color
return { name: name, value: this.wordsData?.positionY[index], itemStyle: {color: color} };
})
this.pieChart = echarts.init(document.getElementById('pie-chart'))
chartOption.pieChartOption.series[0].data = result
this.pieChart.setOption(chartOption.pieChartOption)
})
}
}
}
</script>
<style lang="scss" scoped>
.box{
display: flex;
.box-item{
flex: 1;
box-sizing: border-box;
height: 92px;
padding: 16px 20px;
margin-right: 16px;
display: flex;
align-items: center;
color: #333333;
background: #FBFBFB;
border-radius: 4px;
&:last-child{
margin: 0;
}
.left{
flex-shrink: 0;
width: 100px;
.title{
font-weight: 14px;
margin-bottom: 8px;
}
.value{
font-weight: 700;
font-size: 22px;
}
}
.line{
flex-shrink: 0;
width: 1px;
height: 44px;
background: #E5E5E5;
margin: 0 32px;
}
.content-text{
color: #999EA8;
font-size: 12px;
}
}
}
.chart-box{
height: 216px;
display: flex;
margin-top: 12px;
.wave-chart{
box-sizing: border-box;
height: 100%;
flex: 1;
margin-right: 16px;
padding: 8px 16px;
}
.pie-chart{
height: 100%;
flex: 1;
}
.empty-box {
display: flex;
flex-direction: column;
font-size: 12px;
color: #999999;
text-align: center;
width: 100%;
height: 100%;
box-sizing: border-box;
border-radius: 0 4px 4px 4px;
.icon {
width: 270px;
height: 120px;
margin: 0 auto 8px;
img {
width: 100%;
height: 100%;
}
}
}
}
</style>
\ No newline at end of file
<!-- 语音表达 -->
<template>
<div>
<div class="box">
<div class="box-item">
<div class="left">
<div class="title">清晰度</div>
<div class="value">{{ definitionData.starText }}</div>
</div>
<div class="line"></div>
<div class="content-text">{{ definitionData.starDescribe }}</div>
</div>
<div class="box-item">
<div class="left">
<div class="title">语调</div>
<div class="value">{{ intonationData.starText }}</div>
</div>
<div class="line"></div>
<div class="content-text">{{ intonationData.starDescribe }}</div>
</div>
</div>
<div class="chart-box">
<div class="wave-chart" id="wave-chart-1"></div>
<div class="wave-chart" id="wave-chart-2"></div>
</div>
</div>
</template>
<script>
import chartOption from './chartOption'
import * as echarts from 'echarts'
import contantData from './contantData'
export default {
name: 'fluency',
props: {
itemData: {
type: Object,
default: () => {}
}
},
data() {
return {
intonationData: {},
definitionData: {}
}
},
mounted() {
this.initData()
},
methods: {
initData() {
this.filterIntonationData()
this.filterDefinitionData()
this.$nextTick(() => {
window.addEventListener("resize", () => this.resize())
})
},
resize() {
this.waveChart1 && this.waveChart1.resize()
this.waveChart2 && this.waveChart2.resize()
},
filterIntonationData() {
const { intonation } = this.itemData.deliver
let data = {}
try {
data = JSON.parse(intonation)
} catch (error) {
}
this.intonationData = {
starText: contantData.intonationText[data?.star - 1],
starDescribe: contantData.intonationDescribe[data?.star - 1],
x: data?.x,
y: data?.y,
min: data?.min,
max: data?.max
}
if (data?.x && data?.y) this.initWaveChart(1)
},
filterDefinitionData() {
const { definition } = this.itemData.deliver
let data = {}
try {
data = JSON.parse(definition)
} catch (error) {
}
this.definitionData = {
starText: contantData.definitionText[data?.star - 1],
starDescribe: contantData.definitionDescribe[data?.star - 1],
x: data?.x,
y: data?.y,
min: data?.min,
max: data?.max
}
if (data?.x && data?.y) this.initWaveChart(2)
},
initWaveChart(num) {
this.$nextTick(() => {
if (num == 1) {
this.waveChart1 = echarts.init(document.getElementById('wave-chart-1'))
chartOption.waveChartOption1.xAxis.data = this.intonationData.x
chartOption.waveChartOption1.yAxis.max = this.intonationData.max > Math.max(...this.intonationData.y) ? this.intonationData.max : Math.max(...this.intonationData.y)
chartOption.waveChartOption1.series[0].data = this.intonationData.y
chartOption.waveChartOption1.series[0].markArea.data = [
[{ xAxis: this.intonationData.x[0], yAxis: this.intonationData.min }, { xAxis: this.intonationData.x[this.intonationData.x.length - 1], yAxis: this.intonationData.max }]
]
chartOption.waveChartOption1.xAxis.axisLabel.formatter = (value, index) => {
if (index == 0 || index == this.intonationData.x.length - 1) {
return value
} else {
return ''
}
}
this.waveChart1.setOption(chartOption.waveChartOption1)
}
if (num == 2) {
this.waveChart2 = echarts.init(document.getElementById('wave-chart-2'))
chartOption.waveChartOption2.xAxis.data = this.definitionData.x
chartOption.waveChartOption2.yAxis.max = this.definitionData.max > Math.max(...this.definitionData.y) ? this.definitionData.max : Math.max(...this.definitionData.y)
chartOption.waveChartOption2.series[0].data = this.definitionData.y
chartOption.waveChartOption2.series[0].markArea.data = [
[{ xAxis: this.definitionData.x[0], yAxis: this.definitionData.min }, { xAxis: this.definitionData.x[this.definitionData.x.length - 1], yAxis: this.definitionData.max }]
]
chartOption.waveChartOption2.xAxis.axisLabel.formatter = (value, index) => {
if (index == 0 || index == this.definitionData.x.length - 1) {
return value
} else {
return ''
}
}
this.waveChart2.setOption(chartOption.waveChartOption2)
}
})
},
}
}
</script>
<style lang="scss" scoped>
.box{
display: flex;
.box-item{
flex: 1;
box-sizing: border-box;
height: 92px;
padding: 16px 20px;
margin-right: 16px;
display: flex;
align-items: center;
color: #333333;
background: #FBFBFB;
border-radius: 4px;
&:last-child{
margin: 0;
}
.left{
flex-shrink: 0;
width: 100px;
.title{
font-weight: 14px;
margin-bottom: 8px;
}
.value{
font-weight: 700;
font-size: 22px;
}
}
.line{
flex-shrink: 0;
width: 1px;
height: 44px;
background: #E5E5E5;
margin: 0 32px;
}
.content-text{
color: #999EA8;
font-size: 12px;
}
}
}
.chart-box{
height: 216px;
display: flex;
margin-top: 12px;
.wave-chart{
box-sizing: border-box;
height: 100%;
flex: 1;
margin-right: 16px;
padding: 8px 16px;
&:last-child{
margin: 0;
}
}
}
</style>
\ No newline at end of file
......@@ -5,25 +5,29 @@
<div class="title">{{ item.text }}</div>
<div
class="content"
v-html="item.formatter && item.formatter(detailObj)"></div>
v-html="item.formatter && item.formatter(detailObjData)"
></div>
</div>
</div>
<d2-search
ref="showSearch"
class="show-search"
:search-form="searchForm"
:form-data="showFormData">
:form-data="showFormData"
>
<div slot="firstClassify">
<el-select
v-model="searchForm.firstClassify"
clearable
placeholder="请选择"
@change="changeClassify">
@change="changeClassify"
>
<el-option
v-for="item in baseData.firstClassifyList"
:key="item"
:label="item"
:value="item">
:value="item"
>
</el-option>
</el-select>
</div>
......@@ -31,12 +35,14 @@
<el-select
v-model="searchForm.secondClassify"
clearable
placeholder="请选择">
placeholder="请选择"
>
<el-option
v-for="item in baseData.secondClassifyList"
:key="item"
:label="item"
:value="item">
:value="item"
>
</el-option>
</el-select>
</div>
......@@ -44,7 +50,8 @@
<el-input-range
start-placeholder="请输入"
end-placeholder="请输入"
:display-value="searchForm.qualityTestScore"></el-input-range>
:display-value="searchForm.qualityTestScore"
></el-input-range>
</template>
</d2-search>
<div class="up-btns">
......@@ -67,7 +74,8 @@
:search-form="searchFormSearch"
:table-params="tableParams"
:before-search-fn="beforeSearchFn"
:has-page="false">
:has-page="false"
>
<div slot="scoreHtml" slot-scope="scope">
<template v-if="scope.scope.score || scope.scope.score === 0">
{{ scope.scope.score }}
......@@ -95,7 +103,7 @@ import { Util, deepClone } from "@/common/util"
// import { conversationCheckList, getPointCategory } from "@api/resident"
import { getQualityResult } from "@api/exercise"
export default {
name: 'QualityInspectionAnalyse',
name: "QualityInspectionAnalyse",
components: {
ElInputRange
},
......@@ -107,6 +115,7 @@ export default {
},
data() {
return {
detailObjData: {},
sList: [
{
text: "话术评分",
......@@ -117,10 +126,17 @@ export default {
}
},
{
text: '预计营销结果',
formatter: data => {
const classStr = data.estimatedResult == '成交' ? (data.estimatedResult == '战败' ? 'redStr' : 'greenStr') : 'grayStr'
return `<span class="${classStr}" style="font-weight:700;font-size:20px;">${data.estimatedResult ? data.estimatedResult : '--'}</span>`
text: "预计营销结果",
formatter: (data) => {
const classStr =
data.estimatedResult == "成交"
? data.estimatedResult == "战败"
? "redStr"
: "greenStr"
: "grayStr"
return `<span class="${classStr}" style="font-weight:700;font-size:20px;">${
data.estimatedResult ? data.estimatedResult : "--"
}</span>`
}
}
],
......@@ -180,13 +196,13 @@ export default {
{
label: "命中文本",
prop: "hitText",
addHtml: 'hitTextHtml'
addHtml: "hitTextHtml"
},
{
label: "话术建议",
prop: "suggestions",
addHtml: 'suggestions',
align: 'left'
addHtml: "suggestions",
align: "left"
}
]
},
......@@ -202,29 +218,29 @@ export default {
}
},
mounted() {
// this.getPointCategory()
this.getPointCategory()
},
methods: {
formatSrt(str) {
return str ? str.replace(/\n/g, "<br/>") : '--'
return str ? str.replace(/\n/g, "<br/>") : "--"
},
toMinutesAndSeconds(seconds) {
seconds = Math.floor(seconds / 1000)
let formattedTime = ''
if (seconds < 60) return seconds + '秒'
let formattedTime = ""
if (seconds < 60) return seconds + "秒"
else if (seconds > 3600) {
const hours = Math.floor(seconds / 3600)
const minutes = Math.floor((seconds % 3600) / 60)
if (hours > 0) formattedTime += hours + '小时'
if (minutes > 0 || hours > 0) formattedTime += minutes + '分'
if (hours > 0) formattedTime += hours + "小时"
if (minutes > 0 || hours > 0) formattedTime += minutes + "分"
return formattedTime
} else {
const hours = Math.floor(seconds / 3600)
const minutes = Math.floor((seconds % 3600) / 60)
const remainingSeconds = seconds % 60
if (hours > 0) formattedTime += hours + '小时'
if (minutes > 0 || hours > 0) formattedTime += minutes + '分'
if (remainingSeconds > 0) formattedTime += remainingSeconds + '秒'
if (hours > 0) formattedTime += hours + "小时"
if (minutes > 0 || hours > 0) formattedTime += minutes + "分"
if (remainingSeconds > 0) formattedTime += remainingSeconds + "秒"
return formattedTime
}
},
......@@ -237,13 +253,21 @@ export default {
// }
// },
getPointCategory() {
this.classifyMap = new Map()
getPointCategory().then((res) => {
// this.classifyMap = new Map()
getQualityResult({
pageSize: 10,
currentPage: 1,
staffRecordId: this.detailObj.id
}).then((res) => {
console.log(res)
this.baseData.firstClassifyList = Object.keys(res)
for (const item in res) {
this.classifyMap.set(item, res[item])
this.detailObjData = {
score: res.score,
estimatedResult: this.detailObj.estimatedResult
}
// this.baseData.firstClassifyList = Object.keys(res)
// for (const item in res) {
// this.classifyMap.set(item, res[item])
// }
})
},
changeClassify() {
......@@ -255,10 +279,10 @@ export default {
beforeSearchFn() {
return new Promise((resolve) => {
this.searchFormSearch = deepClone(this.searchForm)
this.searchFormSearch.taskStaffId = this.detailObj.id
this.searchFormSearch.staffRecordId = this.detailObj.id
// this.searchFormSearch.pageSize = 99999
if (this.searchFormSearch.qualityTestScore) {
console.log(this.searchForm, '===')
console.log(this.searchForm, "===")
this.searchFormSearch.qualityTestScoreBegin =
this.searchFormSearch.qualityTestScore[0]
this.searchFormSearch.qualityTestScoreEnd =
......@@ -287,6 +311,7 @@ export default {
</script>
<style lang="scss" scoped>
.analyse {
padding: 16px;
.statistics {
display: flex;
align-items: center;
......@@ -307,7 +332,7 @@ export default {
}
.content {
color: #333333;
line-height:32px;
line-height: 32px;
}
}
}
......@@ -344,14 +369,13 @@ export default {
}
</style>
<style>
.redStr {
color: #eb4e4e;
}
.greenStr {
color: #2cca74;
}
.grayStr{
.grayStr {
color: #999999;
}
</style>
......@@ -7,7 +7,8 @@
btn-ok-label="确定"
@confirmDialog="handleRelateStoreConfirm"
@closeDialog="handleRelateStoreClose"
class="relateStore">
class="relateStore"
>
<slot />
<el-row class="tableCon">
<div class="tableBox">
......@@ -17,8 +18,10 @@
height="464px"
class="table"
border
v-loading="$store.state.d2admin.loading.value"
@select="handleChange"
@select-all="handleAll">
@select-all="handleAll"
>
<el-table-column type="selection" width="55" align="center" />
<el-table-column prop="merchantName" label="门店名称" align="center">
</el-table-column>
......@@ -34,13 +37,16 @@
:current-page.sync="pageNum"
:page-size="pageSize"
layout="total, prev, pager, next"
:total="total" />
:total="total"
/>
</div>
<el-table
class="tableBox table"
:data="selectedData"
v-loading="loading"
border
height="464px">
height="464px"
>
<el-table-column prop="merchantName" label="门店名称" align="center">
<template slot-scope="scope">
<span>{{ scope.row.merchantName }}</span>
......@@ -61,7 +67,8 @@
<el-button
class="el-icon-delete"
@click="handleDelete(scope.row)"
type="text" />
type="text"
/>
</template>
</el-table-column>
</el-table>
......@@ -113,7 +120,7 @@ export default {
mounted() {
this.selectedData = this.storeSelected
this.getSelectingList()
console.log(this.selectedData, '---------')
console.log(this.selectedData, "---------")
},
methods: {
......@@ -161,8 +168,8 @@ export default {
addOrDelete
? this.selectedData.push(row)
: (this.selectedData = this.selectedData.filter(
(item) => item.staffUuid !== row.staffUuid
))
(item) => item.staffUuid !== row.staffUuid
))
},
handleAll(selection) {
this.selectingData.forEach((item) => {
......
<!-- 服务态度 -->
<template>
<div class="box">
<div class="box-item">
<div class="left">
<div class="title">积极程度</div>
<div class="value">{{ itemData.reportItemDescription }}</div>
</div>
<div class="line"></div>
<div class="content-text">{{ itemData.content || '-' }}</div>
</div>
</div>
</template>
<script>
export default {
name: 'serviceAttitude',
props: {
itemData: {
type: Object,
default: () => {}
}
},
data() {
return {
}
}
}
</script>
<style lang="scss" scoped>
.box{
display: flex;
.box-item{
width: calc(50% - 8px);
box-sizing: border-box;
height: 92px;
padding: 16px 20px;
margin-right: 16px;
display: flex;
align-items: center;
color: #333333;
background: #FBFBFB;
border-radius: 4px;
&:last-child{
margin: 0;
}
.left{
flex-shrink: 0;
width: 100px;
.title{
font-weight: 14px;
margin-bottom: 8px;
}
.value{
font-weight: 700;
font-size: 22px;
}
}
.line{
flex-shrink: 0;
width: 1px;
height: 44px;
background: #E5E5E5;
margin: 0 32px;
}
.content-text{
color: #999EA8;
font-size: 12px;
}
}
}
</style>
\ No newline at end of file
<!--
* @Description: AI对练记录
* @Author: huyue
* @Date: 2024-04-15 16:26:57
* @LastEditors: huyue
* @LastEditTime: 2024-05-07 10:56:13
-->
<template>
<d2-container class="m-t-40">
<div class="header" slot="header" style="padding: 10px 20px">
<d2-search
ref="showSearch"
class="show-search"
label-width="110px"
:search-form="searchForm"
:form-data="showFormData"
>
<div class="up-btns">
<el-button size="small" type="primary" @click="handleSearch">
查询
</el-button>
<el-button size="small" @click="handleReset"> 重置 </el-button>
</div>
</d2-search>
</div>
<div class="d2-container-content" style="position: positive">
<d2-table-header>
<auth-button
category="Button"
style="
{
display: inline-block;
}
"
:show-btn-ids="['9120802']"
/>
</d2-table-header>
<d2-table
ref="exerciseTable"
:has-num="true"
:search-form="searchFormSearch"
:table-params="tableParams"
:get-list-api="getListApi"
:before-search-fn="beforeSearchFn"
>
<!-- v-if="scope.scope.sparringStatus === 1" -->
<template slot="auth-button-other" slot-scope="scope">
<el-button type="text" @click="btnClick(scope)">查看结果</el-button>
</template>
<div slot="taskState" slot-scope="scope">
<div class="online-status">
<span
:class="[
scope.scope.taskState === 0
? 'dot blue'
: scope.scope.taskState === 1
? 'dot orange'
: 'dot gray'
]"
></span
>{{ statusObj[scope.scope.taskState] }}
</div>
</div>
</d2-table>
</div>
<!-- <d2-dialog
:title="title"
:is-visible.sync="relateStoreVisible"
width="70%"
btn-ok-label="确定"
@confirmDialog="handleRelateStoreConfirm"
@closeDialog="handleRelateStoreClose"
class="relateStore"
>
<evaluatingReport></evaluatingReport>
</d2-dialog> -->
<quality-detail
:is-quality-visible="isQualityVisible"
v-if="isQualityVisible"
:detail-obj="detailObj"
@closeDialog="closeDialog"
></quality-detail>
</d2-container>
</template>
<script>
import { mapActions, mapState } from "vuex"
import { Util, deepClone } from "@/common/util"
import { staffRecordPage, updateTaskPromptStatus } from "@api/exercise"
// import evaluatingReport from "./components/evaluatingReport"
import QualityDetail from "./components/dialogResult.vue"
export default {
name: "exerciseRecord",
components: {
QualityDetail
},
data() {
return {
title: "查看结果",
isQualityVisible: false,
searchForm: {
sparringStatus: 1
},
showFormData: [
{
label: "手机号",
name: "staffPhone",
type: "input",
isclear: true
},
{
label: "员工名称",
name: "staffName",
type: "input",
isclear: true
},
{
label: "完成时间",
name: "completionTime",
type: "datePicker",
isclear: true
}
],
statusObj: { 0: "未开始", 1: "进行中", 2: "已结束" },
activeName: "all",
// table相关
getListApi: staffRecordPage,
searchFormSearch: { sparringStatus: 1 },
tableParams: {
listName: "list",
tableOption: true,
tableColumns: [
{
label: "手机号",
prop: "staffInfo.staffPhone",
formatter: (cellValue) => {
return cellValue.staffInfo.staffPhone
}
},
{
label: "员工名称",
prop: "staffInfo.staffName",
formatter: (cellValue) => {
return cellValue.staffInfo.staffName
}
},
{
label: "客户类型",
prop: "roleTypeDesc"
},
{
label: "得分",
prop: "score"
},
{
label: "对练时长",
prop: "sparringDuration",
formatter: (cellValue) => {
let timeInMs = cellValue.sparringDuration
const totalSeconds = Math.floor(timeInMs / 1000)
const hours = Math.floor(totalSeconds / 3600)
const minutes = Math.floor((totalSeconds % 3600) / 60)
const seconds = totalSeconds % 60
if (hours > 0) {
return `${hours}时${minutes}分${seconds}秒`
} else {
return `${minutes}分${seconds}秒`
}
}
},
{
label: "完成时间",
prop: "completionTime"
}
]
}
}
},
computed: {
...mapState({
dowloadList: (state) => state.d2admin.user.dowloadList
})
},
methods: {
...mapActions({
get: "d2admin/base/get",
close: "d2admin/page/close"
}),
...mapActions("d2admin/user", ["actionSetDownloadList"]),
handleSearch() {
this.$refs.exerciseTable.refreshTable(true, true)
},
closeDialog() {
this.isQualityVisible = false
},
btnClick(scope) {
console.log(scope, "scope")
// staffInfo
// 查看结果
this.detailObj = {
...scope.scope.staffInfo,
...scope.scope
}
this.isQualityVisible = true
},
beforeSearchFn() {
console.log(this.searchForm)
return new Promise((resolve) => {
this.searchFormSearch = this.getParams()
resolve()
})
},
getParams() {
var params = deepClone(this.searchForm)
const { activeName } = this
// params.taskId = this.taskInfo.id
if (params.completionTime && params.completionTime.length) {
params.startTime = Util.dateFormate(
params.completionTime[0],
"YYYY-MM-DD HH:mm:ss"
)
params.endTime =
Util.dateFormate(params.completionTime[1], "YYYY-MM-DD") + " 23:59:59"
delete params.completionTime
}
params.sparringStatus = 1
// console.log(params, "4444444444")
return params
},
handleReset() {
console.log("handleReset")
this.searchForm = {}
// this.activeName = "all"
this.searchFormSearch = {}
this.$refs.exerciseTable.refreshTable(true, true)
},
// tab 列表切换
handleTabChange(tab, event) {
console.log(tab, event)
this.searchForm.taskState = tab.name != "all" ? tab.name : ""
this.handleSearch()
},
// 状态改变
handleSwitch(scope, e) {
console.log(scope)
const { promptOnOff, id } = scope.scope
this.$confirm(
`是否确认${promptOnOff ? "关闭" : "开启"}提示词?`,
"提示",
{
confirmButtonText: "确定",
type: "warning"
}
).then(() => {
console.log("dia开启")
updateTaskPromptStatus({
id,
promptOnOff: !promptOnOff
})
.then((res) => {
if (res && res.id) {
this.$message.success("修改成功")
} else {
this.$message.error("修改失败")
}
this.$refs.exerciseTable.refreshTable(true)
})
.catch((err) => {
console.log(err)
this.$message.error("修改失败")
})
})
},
// 明细
handleToDetail(row) {
this.close({ tagName: "/exercise" })
this.$router.push({
path: "/exerciseDetail",
query: { detail: JSON.stringify(row) }
})
},
// 查看
handleToView(row) {
this.close({ tagName: "/exercise" })
this.$router.push({
path: "/exerciseView",
query: { detail: JSON.stringify(row) }
})
},
// 新建任务
handleToAdd() {
this.close({ tagName: "/exercise" })
this.$router.push({
path: "/exerciseAdd"
})
},
// 导出
handleExport() {
console.log("导出", this.searchFormSearch, this.getParams())
var params = this.getParams()
params.method =
"dj.api.smartcarlife.ai.sparring.task.staff.record.list.export"
const list = [
...this.dowloadList,
{
name: "对练明细记录列",
exportParam: JSON.stringify(params),
status: "waiting",
timeid: new Date().getTime()
}
]
this.actionSetDownloadList({ list, type: "dowloadList" })
}
}
}
</script>
<style scoped lang="scss">
.m-t-40 {
margin-top: 40px;
}
.online-status {
display: flex;
justify-content: center;
align-items: center;
.dot {
display: inline-block;
width: 8px;
height: 8px;
border-radius: 50%;
margin-right: 8px;
}
.gray {
background-color: #c5c5c5;
}
.orange {
background-color: #fdb757;
}
.blue {
background-color: #2a58ad;
}
}
</style>
<!-- ai对练 对练记录和任务列表 -->
<template>
<div class="in-exerciseTab-list-wrap">
<div class="header" slot="header" style="background: #e7eaec">
<el-tabs v-model="activeName" @tab-click="handleClick">
<el-tab-pane
v-for="(item, index) in tabPaneList"
:label="item.label"
:name="item.name"
:key="index"
>
</el-tab-pane>
</el-tabs>
<components :is="tabName" :scene-type="activeName"></components>
</div>
</div>
</template>
<script>
import index from "./index.vue"
import exerciseRecord from "./exerciseRecord.vue"
export default {
name: "exerciseTab",
components: {
exerciseRecord,
exerciseTask: index
},
data() {
return {
activeName: "0",
tabPaneList: [
{
label: "对练记录",
name: "0"
},
{
label: "任务列表",
name: "1"
}
],
// tabName: "exerciseTask"
tabName: "exerciseRecord"
}
},
mounted() {
if (this.$route.query.tabPane) {
this.activeName = this.$route.query.tabPane
this.tabName = this.$route.query.tabLabel
}
},
watch: {},
methods: {
handleClick() {
const arr = {
0: "exerciseRecord",
1: "exerciseTask"
}
this.tabName = arr[+this.activeName]
this.$router.push({
query: {
...this.$route.query,
tabPane: this.activeName,
tabLabel: this.tabName
}
})
// this.$route.query.tabPane = this.activeName
// this.$route.query.tabLabel = this.tabName
}
}
}
</script>
<style scoped lang="scss">
.in-exerciseTab-list-wrap {
padding: 0 24px;
.header {
::v-deep .el-tabs__header {
margin: 0;
padding: 0 20px;
}
}
}
</style>
......@@ -34,7 +34,7 @@
<span>{{ aiType[taskInfo.aiType] }}</span>
</el-form-item>
<el-form-item label="提示词:">
<span>{{ taskInfo.promptOnOff == 1 ? '开' : '关' }}</span>
<span>{{ taskInfo.promptOnOff == 1 ? "开" : "关" }}</span>
</el-form-item>
</div>
<div class="d2-container-content">
......@@ -45,69 +45,82 @@
<div style="width: 728px">
<d2-table
ref="exerciseViewTable"
:row-style="{height: '50px'}"
:row-style="{ height: '50px' }"
:has-num="true"
:search-form="searchForm"
:table-params="tableParams"
:get-list-api="getListApi">
:get-list-api="getListApi"
>
</d2-table>
</div>
</el-form-item>
</div><el-form-item style="margin-top: 40px;text-align: center;">
<el-button class="width_100 cancel-btn" type="primary" plain @click="handleClose"> 返回 </el-button>
</div>
<el-form-item style="margin-top: 40px; text-align: center">
<el-button
class="width_100 cancel-btn"
type="primary"
plain
@click="handleClose"
>
返回
</el-button>
</el-form-item>
</el-form>
</d2-container>
</div>
</template>
<script>
import { mapActions } from 'vuex'
import { mapActions } from "vuex"
import { getTaskStaffList } from "@api/exercise"
import { scenarioType } from './contant'
import { scenarioType } from "./contant"
export default {
data() {
return {
scenarioType,
tableData: [
{
staffName: '张三',
phoneNumber: '13812345678',
registerTime: '2019-09-09 12:00:00'
staffName: "张三",
phoneNumber: "13812345678",
registerTime: "2019-09-09 12:00:00"
},
{
staffName: '张三',
phoneNumber: '13812345678'
staffName: "张三",
phoneNumber: "13812345678"
}
],
getListApi: getTaskStaffList,
searchForm: {},
tableParams: {
listName: "list",
tableColumns: [{
label: "驻店名称",
prop: "yqMerchantName"
}, {
label: "驻店员工名称",
prop: "staffName"
}, {
label: "手机号",
prop: "staffPhone"
}]
tableColumns: [
{
label: "驻店名称",
prop: "yqMerchantName"
},
{
label: "驻店员工名称",
prop: "staffName"
},
{
label: "手机号",
prop: "staffPhone"
}
]
},
taskInfo: {},
taskType: {
1: '实战演练'
1: "实战演练"
},
aiType: {
1: '独裁型',
2: '沉默型',
3: '理智型',
4: '人际型',
5: '犹豫型',
6: '新手司机',
7: '老手司机',
8: '女司机',
9: '价格型'
1: "独裁型",
2: "沉默型",
3: "理智型",
4: "人际型",
5: "犹豫型",
6: "新手司机",
7: "老手司机",
8: "女司机",
9: "价格型"
}
}
},
......@@ -118,12 +131,18 @@ export default {
},
methods: {
...mapActions({
get: 'd2admin/base/get',
close: 'd2admin/page/close'
get: "d2admin/base/get",
close: "d2admin/page/close"
}),
handleClose() {
this.close({ tagName: '/exerciseView' })
this.$router.push({ name: 'exercise' })
this.close({ tagName: "/exerciseView" })
this.$router.push({
name: "exercise",
query: {
tabPane: "1",
tabLabel: "exerciseTask"
}
})
}
}
}
......
......@@ -259,7 +259,12 @@ export default {
},
{
label: "区域督导",
prop: "areaSupervision"
prop: "areaSupervisionList",
width: "200px",
formatter: (cellValue) => {
let areaSuper = (cellValue.areaSupervisionList && cellValue.areaSupervisionList.length) ? cellValue.areaSupervisionList.map(item => item.userName).join('/') : '-'
return areaSuper
}
},
{
label: "门店标签",
......
......@@ -69,18 +69,18 @@
</el-checkbox-group>
</el-form-item>
<el-form-item label="设置区域督导:"
prop="areaSupervision">
prop="areaSupervisionList">
<el-select clearable
multiple
filterable
value-key="userId"
v-model="form.areaSupervision"
collapse-tags
v-model="form.areaSupervisionList"
class="el_select itd"
placeholder="请选择">
<el-option v-for="item in supervisionOptionsList"
:key="item.userId"
:label="item.userName"
:value="item">
:value="item.userId">
</el-option>
</el-select>
<span class="item-tips">注:区域督导在账户中心创建广联数科员工,角色类型选区域督导</span>
......@@ -104,8 +104,9 @@
</el-form-item>
<el-form-item label="1.1服务商负责人:"
prop="boutiqueServiceDirectorUserId">
<el-select v-model="form.shopMerchantConfig.boutiqueServiceDirectorUserId"
<el-select v-model="directorList[2]"
clearable
multiple
filterable
value-key="userId"
placeholder="请选择"
......@@ -119,8 +120,9 @@
</el-form-item>
<el-form-item label="2.1服务商负责人:"
prop="quotationServiceDirectorUserId">
<el-select v-model="form.shopMerchantConfig.quotationServiceDirectorUserId"
<el-select v-model="directorList[4]"
clearable
multiple
filterable
value-key="userId"
placeholder="请选择"
......@@ -134,8 +136,9 @@
</el-form-item>
<el-form-item label="1.1业务负责人:"
prop="boutiqueDirectorUserId">
<el-select v-model="form.shopMerchantConfig.boutiqueDirectorUserId"
<el-select v-model="directorList[1]"
clearable
multiple
filterable
value-key="userId"
placeholder="请选择"
......@@ -149,8 +152,9 @@
</el-form-item>
<el-form-item label="2.1业务负责人:"
prop="quotationDirectorUserId">
<el-select v-model="form.shopMerchantConfig.quotationDirectorUserId"
<el-select v-model="directorList[3]"
clearable
multiple
filterable
value-key="userId"
placeholder="请选择"
......@@ -319,12 +323,12 @@ export default {
businessType: '',
list: [],
deployScene: [],
areaSupervision: {},
areaSupervisionList: [],
residentManager: {},
currentMonthOutputValue: '',
nextMonthOutputValue: '',
serviceMerchantServiceChargeConfig: {},
shopMerchantConfig: {}
shopMerchantConfig: {},
// boutiqueSunshineInspiration: '',
// quotationSunshineInspiration: '',
// boutiqueMarketInspiration: '',
......@@ -332,6 +336,12 @@ export default {
// boutiqueDirectorUserId: '',
// quotationDirectorUserId: ''
},
directorList: {
1: [],
2: [],
3: [],
4: []
},
outputValueListByYear: [],
year: '',
nowYear: null,
......@@ -407,6 +417,16 @@ export default {
return new Promise((resolve, reject) => {
getShopSetting({ merchantId }).then(res => {
// this.setInfo = res
let areaSupervisionList = []
res.areaSupervisionList?.forEach(item => {
const target = this.supervisionOptionsList.find(ele => ele.userId == item.userId)
if(target) areaSupervisionList.push(item.userId)
})
res.areaSupervisionList = areaSupervisionList
res.shopMerchantConfig?.directorList?.forEach(item => {
const target = this[(item.directorType==4 || item.directorType == 2) ? 'serviceBossList' : 'sellerMerchantStaffList']?.find(ele => ele.userId == item.directorUserId)
if(target) this.directorList[item.directorType].push(item.directorUserId)
})
this.form = deepClone(res)
if (!this.form.serviceMerchantServiceChargeConfig) {
// 未设置过时,手续费默认为打开并且费率为2
......@@ -438,12 +458,12 @@ export default {
checkSelectOption() {
let _form = this.form
let selectItemKey = [
{ item: 'areaSupervision', optionsList: 'supervisionOptionsList', key: 'userId'},
// { item: 'areaSupervision', optionsList: 'supervisionOptionsList', key: 'userId'},
{ item: 'residentManager', optionsList: 'residentManagerOptionsList', key: 'userId'},
{ item: 'boutiqueServiceDirectorUserId', optionsList: 'serviceBossList' },
{ item: 'quotationServiceDirectorUserId', optionsList: 'serviceBossList' },
{ item: 'boutiqueDirectorUserId', optionsList: 'sellerMerchantStaffList' },
{ item: 'quotationDirectorUserId', optionsList: 'sellerMerchantStaffList' }
// { item: 'boutiqueServiceDirectorUserId', optionsList: 'serviceBossList' },
// { item: 'quotationServiceDirectorUserId', optionsList: 'serviceBossList' },
// { item: 'boutiqueDirectorUserId', optionsList: 'sellerMerchantStaffList' },
// { item: 'quotationDirectorUserId', optionsList: 'sellerMerchantStaffList' }
]
selectItemKey.map(val => {
if (typeof _form[val.item] == 'object') {
......@@ -630,15 +650,18 @@ export default {
})
_params.list = list
}
if (!_params.areaSupervision) {
_params.areaSupervision = {}
} else {
_params.areaSupervision = {
userId: _params.areaSupervision.userId,
userType: _params.areaSupervision.userType,
userName: _params.areaSupervision.userName,
userNum: _params.areaSupervision.userNum
}
if(_params.areaSupervisionList?.length){
_params.areaSupervisionList = _params.areaSupervisionList.map(item=>{
let target = this.supervisionOptionsList.find(ele => ele.userId == item)
return {
userId: target?.userId,
userType: target?.userType,
userName: target?.userName,
userNum: target?.userNum
}
})
}else{
_params.areaSupervisionList = []
}
if (!_params.residentManager) {
_params.residentManager = {}
......@@ -679,24 +702,37 @@ export default {
}
}
const shopMerchantConfig = _params.shopMerchantConfig
_params.boutiqueDirectorUserId = shopMerchantConfig.boutiqueDirectorUserId
if (shopMerchantConfig.boutiqueDirectorUserId) {
_params.boutiqueDirectorName = this.sellerMerchantStaffList.find(item => item.userId === shopMerchantConfig.boutiqueDirectorUserId)?.userName
}
_params.quotationDirectorUserId = shopMerchantConfig.quotationDirectorUserId
if (shopMerchantConfig.quotationDirectorUserId) {
_params.quotationDirectorName = this.sellerMerchantStaffList.find(item => item.userId === shopMerchantConfig.quotationDirectorUserId)?.userName
}
// 1.1服务商负责人
_params.boutiqueServiceDirectorUserId = shopMerchantConfig.boutiqueServiceDirectorUserId
if (shopMerchantConfig.boutiqueServiceDirectorUserId) {
_params.boutiqueServiceDirectorName = this.serviceBossList.find(item => item.userId === shopMerchantConfig.boutiqueServiceDirectorUserId)?.userName
}
// 2.1服务商负责人
_params.quotationServiceDirectorUserId = shopMerchantConfig.quotationServiceDirectorUserId
if (shopMerchantConfig.quotationServiceDirectorUserId) {
_params.quotationServiceDirectorName = this.serviceBossList.find(item => item.userId === shopMerchantConfig.quotationServiceDirectorUserId)?.userName
// _params.boutiqueDirectorUserId = shopMerchantConfig.boutiqueDirectorUserId
// if (shopMerchantConfig.boutiqueDirectorUserId) {
// _params.boutiqueDirectorName = this.sellerMerchantStaffList.find(item => item.userId === shopMerchantConfig.boutiqueDirectorUserId)?.userName
// }
// _params.quotationDirectorUserId = shopMerchantConfig.quotationDirectorUserId
// if (shopMerchantConfig.quotationDirectorUserId) {
// _params.quotationDirectorName = this.sellerMerchantStaffList.find(item => item.userId === shopMerchantConfig.quotationDirectorUserId)?.userName
// }
// // 1.1服务商负责人
// _params.boutiqueServiceDirectorUserId = shopMerchantConfig.boutiqueServiceDirectorUserId
// if (shopMerchantConfig.boutiqueServiceDirectorUserId) {
// _params.boutiqueServiceDirectorName = this.serviceBossList.find(item => item.userId === shopMerchantConfig.boutiqueServiceDirectorUserId)?.userName
// }
// // 2.1服务商负责人
// _params.quotationServiceDirectorUserId = shopMerchantConfig.quotationServiceDirectorUserId
// if (shopMerchantConfig.quotationServiceDirectorUserId) {
// _params.quotationServiceDirectorName = this.serviceBossList.find(item => item.userId === shopMerchantConfig.quotationServiceDirectorUserId)?.userName
// }
// 1.精品升级业务负责人,2.精品升级业务服务商负责人,3.会员权益业务负责人,4.会员权益业务服务商负责人)
let directorList = []
for(let key in this.directorList) {
this.directorList[key]?.forEach(item => {
const target = this[(key==4 || key == 2) ? 'serviceBossList' : 'sellerMerchantStaffList']?.find(ele => ele.userId == item)
directorList.push({
directorUserId : target?.userId,
directorType: key,
directorName: target?.userName,
})
})
}
_params.directorList = directorList
_params.boutiqueSunshineInspiration = shopMerchantConfig.boutiqueSunshineInspiration
_params.quotationSunshineInspiration = shopMerchantConfig.quotationSunshineInspiration
_params.boutiqueMarketInspiration = shopMerchantConfig.boutiqueMarketInspiration
......
......@@ -961,6 +961,21 @@
resolved "https://registry.npmmirror.com/@babel/regjsgen/-/regjsgen-0.8.0.tgz#f0ba69b075e1f05fb2825b7fad991e7adbb18310"
integrity sha512-x/rqGMdzj+fWZvCOYForTghzbtqPDZ5gPwaoNGHdgDfF2QA/XZbCBp4Moo5scrkAMPhB7z26XM/AaHuIJdgauA==
"@babel/runtime-corejs3@^7.11.2":
version "7.24.8"
resolved "https://registry.npmjs.org/@babel/runtime-corejs3/-/runtime-corejs3-7.24.8.tgz#c0ae5a1c380f8442920866d0cc51de8024507e28"
integrity sha512-DXG/BhegtMHhnN7YPIvxWd303/9aXvYFD1TjNL3CD6tUrhI2LVsg3Lck0aql5TRH29n4sj3emcROypkZVUfSuA==
dependencies:
core-js-pure "^3.30.2"
regenerator-runtime "^0.14.0"
"@babel/runtime@^7.11.2":
version "7.24.8"
resolved "https://registry.npmjs.org/@babel/runtime/-/runtime-7.24.8.tgz#5d958c3827b13cc6d05e038c07fb2e5e3420d82e"
integrity sha512-5F7SDGs1T72ZczbRwbGO9lQi0NLjQxzl6i4lJxLxfW9U5UluCSyEJeniWvnhl3/euNiqQVbo8zruhsDfid0esA==
dependencies:
regenerator-runtime "^0.14.0"
"@babel/runtime@^7.12.13", "@babel/runtime@^7.12.5", "@babel/runtime@^7.14.0", "@babel/runtime@^7.8.4":
version "7.21.0"
resolved "https://registry.npmmirror.com/@babel/runtime/-/runtime-7.21.0.tgz#5b55c9d394e5fcf304909a8b00c07dc217b56673"
......@@ -3727,6 +3742,11 @@ core-js-compat@^3.25.1, core-js-compat@^3.8.3:
dependencies:
browserslist "^4.21.5"
core-js-pure@^3.30.2:
version "3.37.1"
resolved "https://registry.npmjs.org/core-js-pure/-/core-js-pure-3.37.1.tgz#2b4b34281f54db06c9a9a5bd60105046900553bd"
integrity sha512-J/r5JTHSmzTxbiYYrzXg9w1VpqrYt+gexenBE9pugeyhwPZTAEJddyiReJWsLO6uNQ8xJZFbod6XC7KKwatCiA==
core-js@^2.4.0:
version "2.6.12"
resolved "https://registry.npmmirror.com/core-js/-/core-js-2.6.12.tgz#d9333dfa7b065e347cc5682219d6f690859cc2ec"
......@@ -9144,6 +9164,11 @@ regenerator-runtime@^0.13.11, regenerator-runtime@^0.13.7:
resolved "https://registry.npmmirror.com/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz#f6dca3e7ceec20590d07ada785636a90cdca17f9"
integrity sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg==
regenerator-runtime@^0.14.0:
version "0.14.1"
resolved "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz#356ade10263f685dda125100cd862c1db895327f"
integrity sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==
regenerator-transform@^0.15.1:
version "0.15.1"
resolved "https://registry.npmmirror.com/regenerator-transform/-/regenerator-transform-0.15.1.tgz#f6c4e99fc1b4591f780db2586328e4d9a9d8dc56"
......@@ -10457,6 +10482,11 @@ tslib@^2.0.3:
resolved "https://registry.npmmirror.com/tslib/-/tslib-2.5.0.tgz#42bfed86f5787aeb41d031866c8f402429e0fddf"
integrity sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg==
tslib@^2.1.0:
version "2.6.3"
resolved "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz#0438f810ad7a9edcde7a241c3d80db693c8cbfe0"
integrity sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==
type-check@^0.4.0, type-check@~0.4.0:
version "0.4.0"
resolved "https://registry.npmmirror.com/type-check/-/type-check-0.4.0.tgz#07b8203bfa7056c0657050e3ccd2c37730bab8f1"
......@@ -10843,6 +10873,15 @@ walker@^1.0.7:
dependencies:
makeerror "1.0.12"
wangeditor@4.7.15:
version "4.7.15"
resolved "https://registry.npmjs.org/wangeditor/-/wangeditor-4.7.15.tgz#38c5e279a79d0428e4fd77ae5be46367e9c819e5"
integrity sha512-aPTdREd8BxXVyJ5MI+LU83FQ7u1EPd341iXIorRNYSOvoimNoZ4nPg+yn3FGbB93/owEa6buLw8wdhYnMCJQLg==
dependencies:
"@babel/runtime" "^7.11.2"
"@babel/runtime-corejs3" "^7.11.2"
tslib "^2.1.0"
watchpack@^2.4.0:
version "2.4.0"
resolved "https://registry.npmmirror.com/watchpack/-/watchpack-2.4.0.tgz#fa33032374962c78113f93c7f2fb4c54c9862a5d"
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!