Commit e47110af by zhangxw

Merge branch 'SAAS+V4.45.0-0926' of http://192.168.3.233:8090/saas_plus/dj-car-l…

…ife-system into SAAS+V4.45.0-0926
2 parents 64a29b5f c38d6bcd
......@@ -270,5 +270,29 @@ export const routerName = {
activePath: "/staffMassSending"
},
component: _import("contentManager/sopContentDetail")
},
91309: {
path: "/packageConfig",
name: "packageConfig",
meta: {
title: "平板配置",
authId: "91309",
parentId: "913",
cache: false
},
auth: [],
component: _import("contentManager/packageConfig/index")
},
91310: {
path: "/packageEdit",
name: "packageEdit",
meta: {
title: "素材配置",
authId: "91310",
parentId: "91309",
cache: false
},
auth: [],
component: _import("contentManager/packageConfig/edit")
}
}
<!-- 月度库存结算单弹窗 -->
<template>
<d2-dialog
title="新增门店"
:is-visible="dialogVisible"
class="dailog-box"
width="36%"
@closeDialog="handleClose"
@confirmDialog="handleConfirm"
>
<div class="dialog-title">
请选择新增门店,新增门店的素材会复用默认门店的素材,可自定义修改
</div>
<el-select
class="form-select"
v-model="formData.scene"
placeholder="请选择"
>
<el-option
v-for="(i, indx) in sceneList"
:key="indx"
:label="i.label"
:value="i.id"
></el-option>
</el-select>
</d2-dialog>
</template>
<script>
export default {
name: "addDialog",
data() {
return {
sceneList: [
{
label: "1",
id: "1"
}
],
formData: {}
}
},
props: {
dialogVisible: Boolean
},
methods: {
handleConfirm() {
this.handleClose()
},
handleClose() {
this.$emit("dialogClose")
}
}
}
</script>
<style lang="scss">
.dialog-title {
font-size: 14px;
line-height: 30px;
margin-bottom: 15px;
}
.form-select {
width: 50%;
}
</style>
<template>
<d2-container class="edit-content">
<div class="content-form">
<div class="content-info">
<div class="title">
<div class="line"></div>
<span>素材配置</span>
</div>
<div class="info-form-main">
<el-tabs v-model="packageName" type="card">
<el-tab-pane
v-for="(item, index) in configInfo.packageInfo"
:label="item.name"
:name="item.name"
:key="index"
>
<div class="tab-content">
<div class="tab-header">套餐包</div>
<div class="child-tab">
<el-tabs v-model="packageSubName" type="card">
<el-tab-pane
v-for="(sub, idx) in item.subItem"
:label="sub.name"
:name="sub.name"
:key="idx"
>
<table
cellspacing="0"
cellpadding="0"
border="0"
class="table-box"
>
<tr>
<th>序号</th>
<th>车型展示图</th>
<th>选购卡名称</th>
<th>选购卡描述</th>
<th>详图</th>
<th>操作</th>
</tr>
<tr v-for="(pItem, pindex) in sub.subItem">
<td>1</td>
<td class="flex">
<glsx-preview
:image-url-arr="item.cover"
limit="1"
></glsx-preview>
</td>
<td>
<el-input
v-model="pItem.name"
placeholder="请输入选购卡名称"
></el-input>
</td>
<td>
<el-input
type="textarea"
v-model="pItem.desc"
placeholder="请输入选购卡描述"
></el-input>
</td>
<td class="flex">
<glsx-preview
:image-url-arr="pItem.cover"
limit="1"
></glsx-preview>
</td>
<td>
<el-button
type="text"
v-if="pindex == sub.subItem.length - 1"
@click="handleAdd"
>
新增一行
</el-button>
<el-button
type="text"
v-if="pindex != 0"
@click="handleDel()"
>
删除此项
</el-button>
</td>
</tr>
</table>
</el-tab-pane>
</el-tabs>
</div>
</div>
</el-tab-pane>
</el-tabs>
</div>
</div>
</div>
</d2-container>
</template>
<script>
import preview from "../components/preview"
export default {
components: {
glsxPreview: preview
},
data() {
return {
configInfo: {
packageInfo: [
{
id: 5,
name: "问界M5",
subItem: [
{
id: 51,
name: "原厂",
subItem: [
{
id: 511,
cover: [],
name: "名称1"
},
{
id: 511,
cover: [],
name: "名称1"
}
]
},
{
id: 52,
name: "专享",
subItem: [
{
id: 511,
cover: [],
name: "名称2"
},
{
id: 511,
cover: [],
name: "名称2"
}
]
}
]
},
{
name: "问界M7"
}
],
MembraneInfo: [],
boutiqueInfo: []
},
packageName: "",
packageSubName: ""
}
},
watch: {
// packageName() {
// this.packageIndex = this.packageInfo.findIndex(
// (item) => item.name === this.packageName
// )
// },
// packageSubName() {
// this.packageSubIndex = this.packageInfo[
// this.packageIndex
// ].subItem.findIndex((item) => item.name === this.packageSubName)
// }
},
mounted() {
const { packageInfo } = this.configInfo
this.packageName = packageInfo[0].name
this.packageSubName = packageInfo[0].subItem[0].name
},
methods: {
handleAdd() {},
handleDel() {}
}
}
</script>
<style lang="scss" scoped>
.content-form {
.content-info {
background: #fff;
}
.title {
height: 50px;
line-height: 50px;
padding: 0 20px;
border-bottom: 1px solid #e5e5e5;
font-size: 16px;
font-weight: 600;
color: #333333;
display: flex;
align-items: center;
.line {
width: 4px;
height: 16px;
background: #185efe;
border-radius: 2px;
margin-right: 8px;
}
}
.info-form-main {
padding: 20px;
.tab-content {
border: 1px solid #ebeef5;
.tab-header {
height: 50px;
line-height: 50px;
padding: 0 20px;
border-bottom: 1px solid #e5e5e5;
font-size: 16px;
font-weight: 600;
color: #333333;
display: flex;
align-items: center;
}
.child-tab {
padding: 20px;
.table-box {
border: 1px solid #ebeef5;
width: 100%;
color: #666666;
font-size: 14px;
tr {
line-height: 60px;
&:first-child {
line-height: 30px;
background: #f5f7fa;
}
th,
td {
padding: 10px 20px;
text-align: center;
border-bottom: 1px solid #ebeef5;
.el-textarea {
vertical-align: middle;
}
&.flex {
display: flex;
justify-content: center;
::v-deep.photo-activity {
position: static;
}
}
}
}
}
}
}
}
}
</style>
<template>
<div>
<d2-container>
<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>
<el-button size="small" type="primary" @click="handleAdd">
新增门店
</el-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">
<el-button type="text" @click="handleEdit(scope.scope)">
编辑
</el-button>
</div>
</d2-table>
</div>
</d2-container>
<!-- 新增提现 -->
<add-dialog
:dialogVisible="dialogVisible"
v-if="dialogVisible"
@dialogClose="addDialogClose"
/>
</div>
</template>
<script>
import { deepClone } from "@/common/util"
import { contentManagerTaskPage } from "@api/contentManager"
import addDialog from "./components/addDialog"
export default {
name: "StaffMassSendingIndex",
components: {
addDialog
},
data() {
return {
dialogVisible: false,
labelWidth: "100px",
searchForm: {
title: "",
contentType: "",
sendStatus: ""
},
searchFormSearch: {},
showFormData: [
{
label: "门店名称",
name: "title",
type: "input",
maxlength: "20",
isClear: true
},
{
label: "商户号",
name: "title",
type: "input",
maxlength: "20",
isClear: true
}
],
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: "title"
},
{
label: "业务场景",
prop: "title"
},
{
label: "状态",
prop: "title"
},
{
label: "配置类型",
prop: "contentType",
width: "100px"
}
]
}
}
},
methods: {
beforeSearchFn() {
return new Promise((resolve) => {
this.searchFormSearch = deepClone(this.searchForm)
resolve()
})
},
handleAdd() {
this.dialogVisible = true
},
handleSearch() {
this.$refs.recordTable.refreshTable(false, true)
},
handleEdit(row) {
this.$router.push({
name: "packageEdit",
query: {
id: row.id
}
})
},
handleReset() {
this.searchForm = {
title: "",
contentType: "",
sendStatus: ""
}
this.$refs.recordTable.refreshTable(false, true)
},
addDialogClose() {
this.dialogVisible = false
this.$refs.recordTable.refreshTable()
}
}
}
</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>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!