品牌管理
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
37ec774348
commit
4733d3c3b2
|
@ -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,
|
||||
|
|
|
@ -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>
|
|
@ -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>
|
|
@ -1,73 +1,78 @@
|
|||
<template>
|
||||
<div style="height: calc(100vh - 200px)">
|
||||
<obj-table-plus
|
||||
ref="oTable"
|
||||
style="height: 100%"
|
||||
:tableCols="tableCols"
|
||||
:tableProp="tableProp"
|
||||
@query="queryList"
|
||||
v-model="dataList"
|
||||
:tableEvent="tableEvent"
|
||||
>
|
||||
<template slot="tableTop">
|
||||
<el-form :inline="true" :model="formInline" class="demo-form-inline">
|
||||
<el-form-item label="平台分类">
|
||||
<el-select v-model="formInline.region" placeholder="活动区域">
|
||||
<el-option label="区域一" value="shanghai"></el-option>
|
||||
<el-option label="区域二" value="beijing"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="商户分类">
|
||||
<el-select v-model="formInline.region" placeholder="活动区域">
|
||||
<el-option label="区域一" value="shanghai"></el-option>
|
||||
<el-option label="区域二" value="beijing"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="商品搜索">
|
||||
<el-input
|
||||
v-model="formInline.user"
|
||||
placeholder="商品搜索"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="$refs.oTable.reload()"
|
||||
>查询</el-button
|
||||
<div>
|
||||
<div v-if="shopId" style="height: calc(100vh - 200px)">
|
||||
<obj-table-plus
|
||||
ref="oTable"
|
||||
style="height: 100%"
|
||||
:tableCols="tableCols"
|
||||
:tableProp="tableProp"
|
||||
@query="queryList"
|
||||
v-model="dataList"
|
||||
:tableEvent="tableEvent"
|
||||
>
|
||||
<template slot="tableTop">
|
||||
<el-form :inline="true" :model="formInline" class="demo-form-inline">
|
||||
<el-form-item label="平台分类">
|
||||
<el-select v-model="formInline.region" placeholder="活动区域">
|
||||
<el-option label="区域一" value="shanghai"></el-option>
|
||||
<el-option label="区域二" value="beijing"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="商户分类">
|
||||
<el-select v-model="formInline.region" placeholder="活动区域">
|
||||
<el-option label="区域一" value="shanghai"></el-option>
|
||||
<el-option label="区域二" value="beijing"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="商品搜索">
|
||||
<el-input
|
||||
v-model="formInline.user"
|
||||
placeholder="商品搜索"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="$refs.oTable.reload()"
|
||||
>查询</el-button
|
||||
>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-tabs v-model="activeName" @tab-click="handleClick">
|
||||
<el-tab-pane label="在售" name="在售"></el-tab-pane>
|
||||
<el-tab-pane label="仓库中" name="仓库中"></el-tab-pane>
|
||||
<el-tab-pane label="折扣" name="折扣"></el-tab-pane>
|
||||
</el-tabs>
|
||||
<div class="mb-2">
|
||||
<el-button type="primary" size="small" @click="addProduct"
|
||||
>添加商品</el-button
|
||||
>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-tabs v-model="activeName" @tab-click="handleClick">
|
||||
<el-tab-pane label="在售" name="在售"></el-tab-pane>
|
||||
<el-tab-pane label="仓库中" name="仓库中"></el-tab-pane>
|
||||
<el-tab-pane label="折扣" name="折扣"></el-tab-pane>
|
||||
</el-tabs>
|
||||
<div class="mb-2">
|
||||
<el-button type="primary" size="small" @click="addProduct"
|
||||
>添加商品</el-button
|
||||
>
|
||||
<el-button
|
||||
:disabled="selectList.length <= 0"
|
||||
type="danger"
|
||||
size="small"
|
||||
@click="deleteProduct"
|
||||
>批量删除</el-button
|
||||
>
|
||||
</div>
|
||||
</template>
|
||||
</obj-table-plus>
|
||||
<!-- 添加或编辑 -->
|
||||
<add-or-update
|
||||
@queryList="$refs.oTable.reload()"
|
||||
ref="addOrUpdate"
|
||||
></add-or-update>
|
||||
<!-- 改价格 -->
|
||||
<AddPrice ref="AddPrice" @queryList="$refs.oTable.reload()"></AddPrice>
|
||||
<!-- 改库存 -->
|
||||
<addStock ref="addStock" @queryList="$refs.oTable.reload()"></addStock>
|
||||
<!-- 打折扣 -->
|
||||
<AddDiscount
|
||||
ref="AddDiscount"
|
||||
@queryList="$refs.oTable.reload()"
|
||||
></AddDiscount>
|
||||
<el-button
|
||||
:disabled="selectList.length <= 0"
|
||||
type="danger"
|
||||
size="small"
|
||||
@click="deleteProduct"
|
||||
>批量删除</el-button
|
||||
>
|
||||
</div>
|
||||
</template>
|
||||
</obj-table-plus>
|
||||
<!-- 添加或编辑 -->
|
||||
<add-or-update
|
||||
@queryList="$refs.oTable.reload()"
|
||||
ref="addOrUpdate"
|
||||
></add-or-update>
|
||||
<!-- 改价格 -->
|
||||
<AddPrice ref="AddPrice" @queryList="$refs.oTable.reload()"></AddPrice>
|
||||
<!-- 改库存 -->
|
||||
<addStock ref="addStock" @queryList="$refs.oTable.reload()"></addStock>
|
||||
<!-- 打折扣 -->
|
||||
<AddDiscount
|
||||
ref="AddDiscount"
|
||||
@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>
|
||||
|
||||
|
@ -95,6 +100,7 @@ export default {
|
|||
},
|
||||
productFilterType: "SALE",
|
||||
selectList: [],
|
||||
shopId: sessionStorage.getItem("userInfo").shopId,
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
|
@ -289,7 +295,7 @@ export default {
|
|||
render: ({ row }) => {
|
||||
let edit = () => {
|
||||
console.log(row);
|
||||
|
||||
|
||||
this.$refs.addOrUpdate.toggle(row).update();
|
||||
};
|
||||
let priceAdjustment = () => {
|
||||
|
|
Loading…
Reference in New Issue