品牌管理
continuous-integration/drone/push Build is passing Details

This commit is contained in:
余同学 2024-10-20 17:00:39 +08:00
parent 37ec774348
commit 4733d3c3b2
4 changed files with 358 additions and 69 deletions

View File

@ -93,6 +93,33 @@ export default {
open: null,
list: [],
},
{
menuId: getUUID(),
parentId: 0,
parentName: null,
name: "品牌管理",
url: "",
perms: "",
type: 0,
elIcon: "el-icon-money",
orderNum: 0,
open: null,
list: [
{
menuId: getUUID(),
parentId: 0,
parentName: null,
name: "品牌管理",
url: "brand/config/index",
perms: "",
type: 1,
elIcon: "el-icon-postcard",
orderNum: 0,
open: null,
list: [],
},
],
},
// {
// "menuId": getUUID(),
// "parentId": 0,

View File

@ -0,0 +1,108 @@
<template>
<div style="height: calc(100vh - 200px)">
<div class="brandPage">
<span class="pattern"></span>
品牌管理
</div>
<div class="brandInfo">
<span class="pattern"></span>
品牌信息
<span @click="infoUpdate" class="brandInfo-update">编辑</span>
</div>
<div class="info-content">
<div class="info-item">品牌名称</div>
<div class="info-item">品牌ID:</div>
<div class="info-item">品牌LOGO:</div>
<div class="info-item">品牌背景:</div>
<div class="info-item">品牌首页:</div>
<div class="info-item">宣传语:</div>
<div class="info-item">宣传视频:</div>
</div>
<div class="brandInfo">
<span class="pattern"></span>
账号信息
</div>
<div class="info-content">
<div class="info-item">管理员账号</div>
<div class="info-item">
管理员密码:
<span @click="infoUpdate" class="brandInfo-update">修改</span>
</div>
</div>
<div class="brandInfo">
<span class="pattern"></span>
其他信息
</div>
<div class="info-content">
<div class="info-item">品牌联系人</div>
<div class="info-item">联系方式:</div>
</div>
<div class="brandInfo">
<span class="pattern"></span>
推广营销工具
</div>
<div class="info-content">
<div class="info-item">
品牌分销推广:
<span @click="infoUpdate" class="brandInfo-update">配置</span>
</div>
</div>
<!-- 编辑品牌信息 -->
<addOrUpdate ref="addOrUpdate"></addOrUpdate>
</div>
</template>
<script>
import addOrUpdate from "./popup/add-or-update.vue";
export default {
components: { addOrUpdate },
data() {
return {};
},
methods: {
infoUpdate() {
this.$nextTick(() => {
this.$refs.addOrUpdate.toggle().update();
});
console.log("123");
},
},
};
</script>
<style lang="scss" scoped>
.brandPage {
width: 100%;
font-size: 18px;
padding-bottom: 15px;
margin-bottom: 20px;
border-bottom: 2px solid rgba(28, 146, 152, 1);
}
.pattern {
display: inline-block;
width: 2px;
height: 15px;
background: rgba(28, 146, 152, 1);
}
.brandInfo {
// margin-top: 20px;
font-size: 18px;
}
.brandInfo-update {
display: inline-block;
font-size: 15px;
color: rgba(28, 146, 152, 1);
margin-left: 10px;
}
.info-content {
display: flex;
// justify-content: space-between;
flex-wrap: wrap;
padding: 20px 10px;
.info-item {
width: 40%;
margin-bottom: 20px;
font-size: 18px;
}
}
</style>

View File

@ -0,0 +1,148 @@
<template>
<div>
<obj-modal
ref="modal"
labelWidth="150px"
:modalCols="modalCols"
:modalConfig="modalConfig"
:modalData="modalData"
:modalHandles="modalHandles"
>
</obj-modal>
</div>
</template>
<script>
import { debounce, cloneDeep } from "lodash";
import { Divider } from "element-ui";
export default {
components: {},
data() {
return {
isAdd: true,
//
modalConfig: {
title: "编辑品牌",
show: false,
width: "60%",
},
modalData: {},
value1: [],
ProductData: {},
};
},
methods: {
queryTableData(pageNo, pageSize) {},
toggle(e) {
if (this.modalConfig.show == false) {
this.modalConfig.show = true;
} else {
this.modalConfig.show = false;
}
if (e) {
this.init(cloneDeep(e));
}
return {
add: () => {
this.$nextTick(() => {
this.modalData = {};
});
this.isAdd = true;
},
update: () => {
this.isAdd = false;
},
};
},
init(row) {},
},
computed: {
modalCols() {
return [
{
label: "商品折扣(折)",
prop: "discount",
type: "Input",
width: "300px",
rules: { required: true, message: "请输入打折数" },
type: "jsx",
render: () => {
return (
<div>
<el-input-number
min={0}
max={9.9}
v-model={this.modalData.discount}
></el-input-number>
<span> 提示 请输入9.9数字 :8=售价*0.8</span>
</div>
);
},
},
{
label: "限制购买(数量)",
prop: "limitCount",
type: "Input",
width: "300px",
rules: { required: true, message: "请输入价格" },
type: "jsx",
render: () => {
return (
<div>
<el-input-number
min={1}
max={99}
v-model={this.modalData.limitCount}
step={1}
step-strictly
></el-input-number>
<span> 提示 请输入99数字 超出数量以原价购买</span>
</div>
);
},
},
{
label: "活动时间",
prop: "DiscountTime",
type: "Input",
width: "300px",
rules: { required: true, message: "请输入活动时间" },
type: "jsx",
render: () => {
return (
<el-date-picker
// format="yyyy-MM-dd HH:mm:ss"
value-format="yyyy-MM-dd HH:mm:ss"
v-model={this.modalData.DiscountTime}
type="daterange"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
></el-date-picker>
);
},
},
];
},
modalHandles() {
return [
{
label: "取消",
handle: () => {
this.toggle();
},
},
{
label: this.isAdd ? "确认添加" : "确认",
type: "primary",
loading: this.isLoading,
submit: true,
handle: () => {},
},
];
},
},
asyncComputed: {},
};
</script>
<style lang="scss" scoped>
</style>

View File

@ -1,5 +1,6 @@
<template>
<div style="height: calc(100vh - 200px)">
<div>
<div v-if="shopId" style="height: calc(100vh - 200px)">
<obj-table-plus
ref="oTable"
style="height: 100%"
@ -69,6 +70,10 @@
@queryList="$refs.oTable.reload()"
></AddDiscount>
</div>
<div style="height: calc(100vh - 200px)" v-else>
<el-empty :image-size="200" description="请先去完成商品哦"></el-empty>
</div>
</div>
</template>
<script>
@ -95,6 +100,7 @@ export default {
},
productFilterType: "SALE",
selectList: [],
shopId: sessionStorage.getItem("userInfo").shopId,
};
},
methods: {