添加注释,修改分销设置提交方式,左侧菜单无法选中问题

This commit is contained in:
mabo
2021-07-23 18:05:05 +08:00
parent ae329419a6
commit 9130485631
66 changed files with 301 additions and 2758 deletions

View File

@@ -175,7 +175,7 @@ export default {
}
});
},
// 删除模板
delTemplate(id) {
API_floor.removePageHome(id).then((res) => {
if (res.success) {
@@ -184,8 +184,7 @@ export default {
}
});
},
},
computed: {},
}
};
</script>

View File

@@ -25,13 +25,6 @@
<i-input v-model="searchData" size="large" placeholder="输入你想查找的商品">
<Button slot="append">搜索</Button>
</i-input>
<!-- <Tag
v-for="(item, index) in promotionTags"
:key="index"
class="mt_10"
>
{{item}}
</Tag> -->
</div>
</div>
<div class="nav-con">
@@ -185,6 +178,7 @@ export default {
if(item) this.selectedNav = item;
this.$refs.liliDialog.open('link')
},
// 已选链接
selectedLink(val) {
console.log(val);
if(this.showModalNav){
@@ -202,9 +196,11 @@ export default {
)
console.log(this.navList.list)
},
// 拖动结束回调
handleMoveEnd ({newIndex, oldIndex}) {
console.log('index', newIndex, oldIndex)
},
// 修改顶部广告
handleModel (type) {
if(type == 'topAdvert'){
this.showModal = true;
@@ -212,6 +208,7 @@ export default {
this.showModalNav = true;
}
},
// 选择图片
handleSelectImg() {
this.$refs.ossManage.selectImage = true;
this.picModelFlag = true;
@@ -236,9 +233,6 @@ export default {
model: this.data.list[newIndex].type + '_' + key
})
},
},
watch: {
}
}
</script>

View File

@@ -58,38 +58,6 @@
</div>
</div>
</template>
<!-- 首页品牌 -->
<!-- <template v-if="element.type == 'brand'">
<div class="brand">
<div class="brand-view">
<div class="brand-view-content" v-for="(brand,index) in element.options.brandViewList" :key="index">
<div class="brand-view-title">
<span><span class="fontsize_18 fw_bold">{{brand.nameCn}}</span> <span class="fw_bold">{{brand.nameEn}}</span></span>
<span>更多&gt;</span>
</div>
<div class="brand-view-img">
<img :src="brand.img" alt="">
</div>
</div>
</div>
<ul class="brand-list">
<li v-for="(sign,index) in element.options.signList" :key="index">
<div class="brand-img">
<img :src="sign.img" alt="">
</div>
<div class="brand-mash">
<Icon type="ios-heart-outline" />
<div>关注人数{{ sign.follow }}</div>
<div>点击进入</div>
</div>
</li>
<li class="refresh">
<Icon type="md-refresh" />
<div>换一批</div>
</li>
</ul>
</div>
</template> -->
<!-- 好货推荐 -->
<template v-if="element.type == 'recommend'">
<recommend :data="element"></recommend>
@@ -188,15 +156,14 @@ export default {
selected:{}, // 已选数据
picModelFlag: false // 图片选择器
}
},
mounted () {
},
methods: {
// 编辑模块
handleSelectModel (item) {
this.selected = item;
this.showModal = true
},
// 删除模块
handleModelDelete () {
this.$Modal.confirm({
title: '提示',
@@ -212,28 +179,25 @@ export default {
handleSelectLink(item,index) { // 调起选择链接弹窗
this.$refs.liliDialog.open('link')
},
// 确定选择链接
selectedLink(val) {
this.selected.url = this.$options.filters.formatLinkType(val);;
},
// 拖动结束回调
handleMoveEnd ({newIndex, oldIndex}) {
console.log('index', newIndex, oldIndex)
},
handleEditModel (type) {
this.showModal = true;
},
handleSelectImg(){ // 选择图片
this.$refs.ossManage.selectImage = true;
this.picModelFlag = true;
},
// 回显图片
callbackSelected (val) {
this.picModelFlag = false;
this.selected.img = val.url;
}
},
watch: {
}
}
</script>
<style lang="scss" scoped>

View File

@@ -139,6 +139,7 @@ export default {
// 编辑模块
this.showModal = true;
},
// 添加轮播图
handleAdd () {
this.data.options.list.push({ img: "", url: "" });
this.$forceUpdate();
@@ -161,6 +162,7 @@ export default {
this.selected.url = this.$options.filters.formatLinkType(val);
console.log(this.selected.url);
},
// 选择图片
handleSelectImg(item) {
this.selected = item;
this.$refs.ossManage.selectImage = true;

View File

@@ -81,6 +81,7 @@ export default {
}
},
methods:{
// 打开装修modal
handleSelectModel (item,type) {
this.selected = item;
this.showModal = true
@@ -88,7 +89,7 @@ export default {
handleSelectLink(item,index) { // 调起选择链接弹窗
this.$refs.liliDialog.open('link')
},
// 选择链接回调
selectedLink(val) {
this.selected.url = this.$options.filters.formatLinkType(val);;
},
@@ -96,6 +97,7 @@ export default {
this.$refs.ossManage.selectImage = true;
this.picModelFlag = true;
},
// 选择图片回调
callbackSelected (val) {
this.picModelFlag = false;
this.selected.img = val.url;

View File

@@ -160,6 +160,7 @@ export default {
}
},
methods:{
// 装修modal
handleSelectModel (item, type) {
this.selected = item;
console.warn(item);
@@ -181,9 +182,11 @@ export default {
this.$refs.liliDialog.goodsData = [this.selected]
}, 500);
},
// 选择链接回调
selectedLink (val) {
this.selected.url = this.$options.filters.formatLinkType(val);
},
// 选择商品回调
selectedGoodsData (val) {
console.log(val);
let goods = val[0]
@@ -193,17 +196,11 @@ export default {
this.selected.name = goods.goodsName
this.selected.url = `/goodsDetail?skuId=${goods.id}&goodsId=${goods.goodsId}`
},
handleMoveEnd ({newIndex, oldIndex}) {
console.log('index', newIndex, oldIndex)
},
handleEditModel (type) {
this.showModal = true;
},
handleSelectImg(){ // 选择图片
this.$refs.ossManage.selectImage = true;
this.picModelFlag = true;
},
// 选择图片回显
callbackSelected (val) {
this.picModelFlag = false;
this.selected.img = val.url;

View File

@@ -50,7 +50,6 @@
<tr v-for="(item, index) in conData.options.navList" :key="index">
<td><Input v-model="item.title" /></td>
<td><Input v-model="item.desc" /></td>
<!-- <td><Input v-model="item.sort"/></td> -->
<td v-if="index!=0">
<Button type="error" size="small" @click="handleDelNav(index)">删除</Button>
</td>
@@ -62,7 +61,6 @@
<!-- 选择商品链接 -->
<liliDialog
ref="liliDialog"
@selectedLink="selectedLink"
@selectedGoodsData="selectedGoodsData"
></liliDialog>
</div>
@@ -91,31 +89,25 @@ export default {
conData:function(val){
this.$emit('content',val)
}
},
mounted() {
},
methods:{
// tab点击切换
changeCurr(index){
this.currentIndex = index;
},
// 编辑
handleSelectModel (item,type) {
this.selected = item;
this.showModal = true
},
handleSelectLink(item,index) { // 调起选择链接弹窗
this.$refs.liliDialog.open('link')
},
handleSelectGoods(item) { // 调起选择链接弹窗
handleSelectGoods(item) { // 调起选择商品弹窗
if(item) this.selected = item;
this.$refs.liliDialog.open('goods', 'single')
setTimeout(() => {
this.$refs.liliDialog.goodsData = [this.selected]
}, 500);
},
selectedLink(val) {
this.selected.url = this.$options.filters.formatLinkType(val);
},
// 选择商品回调
selectedGoodsData(val){
console.log(val)
let goods = val[0]

View File

@@ -227,6 +227,7 @@ export default {
};
},
methods: {
// 编辑
handleSelectModel(item, type) {
this.selected = item;
if (type) {
@@ -243,9 +244,11 @@ export default {
// 调起选择商品
this.$refs.liliDialog.open('goods', 'single')
},
// 选择链接回调
selectedLink(val) {
this.selected.url = this.$options.filters.formatLinkType(val);
},
// 选择商品回调
selectedGoodsData(val) {
console.log(val);
let goods = val[0];
@@ -259,6 +262,7 @@ export default {
this.$refs.ossManage.selectImage = true;
this.picModelFlag = true;
},
// 选择图片回调
callbackSelected(val) {
this.picModelFlag = false;
this.selected.img = val.url;

View File

@@ -86,9 +86,6 @@ export default {
this.modelForm = { list: [] };
}
}
// this.$refs.modelForm.topAdvert = {};
// this.$refs.modelForm.navList = {}
});
},
},

View File

@@ -94,19 +94,12 @@ export default {
linkType: "", // 选择类型
};
},
methods: {},
mounted() {
},
methods: {
// 点击链接
clickLink(item) {
this.$refs.liliDialog.open('link')
},
//点击图片解析成base64
changeFile(item, index) {
const file = document.getElementById("files" + index).files[0];
@@ -122,7 +115,6 @@ export default {
// 点击选择照片
handleClickFile(item, index) {
document.getElementById("files" + index).click();
// console.log(let files = files)
},
},
};

View File

@@ -69,14 +69,12 @@
</div>
</div>
</div>
<!-- <Button type="primary" @click="addDecorate()" ghost>添加</Button> -->
<liliDialog ref="liliDialog" :types="linkType"></liliDialog>
</div>
</div>
</div>
</template>
<script>
export default {
data() {
return {
@@ -91,18 +89,12 @@ export default {
],
linkType: "", // 选择类型
};
},
methods: {},
mounted() {
},
methods: {
// 点击链接
clickLink(item) {
this.$refs.liliDialog.open('link')
},
//点击图片解析成base64
changeFile(item, index) {
const file = document.getElementById("files" + index).files[0];
@@ -118,7 +110,6 @@ export default {
// 点击选择照片
handleClickFile(item, index) {
document.getElementById("files" + index).click();
// console.log(let files = files)
},
},
};

View File

@@ -168,20 +168,15 @@ export default {
},
},
props: ["res"],
mounted() {},
methods: {
// 选择风格
selectStyle() {
this.styleFlag = !this.styleFlag;
},
// 回调选择的链接
selectedLink(val) {
this.selectedLinks.url = val;
console.log(this.selectedLinks);
},
// 回调的商品信息
selectedGoodsData(val) {
if (!val) return false;
@@ -194,10 +189,8 @@ export default {
this.res.options.list[0].listWay = this.res.options.list[0].listWay.concat(
val
);
this.linkType = "";
},
// 绑定商品
bindGoodsId(val) {
this.selectedGoods = val;
@@ -208,7 +201,7 @@ export default {
this.$emit("handleDrawer", item);
this.styleFlag = false;
},
// 打开图片选择器
liliDialogFlag(flag) {
this.$refs.liliDialog.goodsFlag = flag;
this.$refs.liliDialog.flag = true;
@@ -216,14 +209,9 @@ export default {
// 点击链接赋值一个唯一值,并将当前选择的模块赋值
clickLink(val, index) {
// this.selectedLinkIndex = index
// val.___only = new Date().getTime(), //赋值当前时间戳 唯一
this.selectedLinks = val;
console.log(this.selectedLinks);
this.liliDialogFlag(false);
},
//点击图片解析成base64
changeFile(item, index) {
const file = document.getElementById("files" + index).files[0];
@@ -247,21 +235,17 @@ export default {
};
this.res.options.list.push(way);
},
// 图片选择器回显
callbackSelected(val) {
this.picModelFlag = false;
this.selectedGoods.img = val.url;
},
// 点击选择照片
// 点击选择图片
handleClickFile(item, index) {
this.$refs.ossManage.selectImage = true;
this.selectedGoods = item;
this.picModelFlag = true;
// console.log(let files = files)
},
// 关闭
closeDecorate(index) {
this.$nextTick(() => {

View File

@@ -108,6 +108,7 @@ export default {
},
methods: {
// 初始化数据
init() {
if (!this.$route.query.id) return false;
API_Other.getHomeData(this.$route.query.id).then(res=>{
@@ -117,12 +118,6 @@ export default {
this.handleComponent( this.contentData.list[0], 0)
})
},
handleSpinShow() {
this.$Spin.show();
setTimeout(() => {
this.$Spin.hide();
}, 3000);
},
// 中间组件拖动,右侧数据绑定不变
handleContentlEnd(evt) {
@@ -159,7 +154,7 @@ export default {
this.selected = index;
this.$set(this, "decorateData", val);
},
// 右侧栏回调
handleDrawer(val) {
let newIndex = this.selected;

View File

@@ -18,17 +18,12 @@ export default {
layout, // 装修模块
name: "index", // 装修的页面
};
},
mounted() {
},
methods: {
selected(val) {
selected(val) { // 顶部栏点击切换
this.name = val;
},
},
}
}
};
</script>
<style scoped lang="scss">

View File

@@ -20,9 +20,6 @@ export default {
},
deep: true
}
},
mounted() {
console.log(this.res);
}
};
</script>

View File

@@ -14,9 +14,6 @@
export default {
title: "两张横图",
props: ["res"],
mounted () {
}
};
</script>
<style lang="scss" scoped>

View File

@@ -52,11 +52,12 @@ export default {
};
},
props: ["res"],
mounted() {},
methods: {
// 删除商品
closeGoods(val, index) {
this.res.list[0].listWay.splice(index,1)
},
// 切换商品列表
handleClickTitle(val, index) {
this.selected.index = index;
this.selected.val = val.title;

View File

@@ -29,7 +29,7 @@
</template>
<script>
export default {
props: ["res"],
props: ["res"]
};
</script>
<style lang="scss" scoped>

View File

@@ -29,7 +29,7 @@
</template>
<script>
export default {
props: ["res"],
props: ["res"]
};
</script>
<style lang="scss" scoped>

View File

@@ -29,7 +29,7 @@
</template>
<script>
export default {
props: ["res"],
props: ["res"]
};
</script>
<style lang="scss" scoped>

View File

@@ -18,10 +18,7 @@
<script>
export default {
title: "左一右二",
props: ["res"],
mounted() {
}
props: ["res"]
};
</script>
<style lang="scss" scoped>

View File

@@ -18,10 +18,7 @@
<script>
export default {
title: "左二右一",
props: ["res"],
mounted() {
console.log(this.res);
},
props: ["res"]
};
</script>
<style lang="scss" scoped>

View File

@@ -29,7 +29,7 @@
</template>
<script>
export default {
props: ["res"],
props: ["res"]
};
</script>
<style lang="scss" scoped>

View File

@@ -35,10 +35,7 @@
<script>
export default {
title: "文字图片模板",
props: ["res"],
mounted() {
console.log(this.res);
}
props: ["res"]
};
</script>
<style lang="scss" scoped>

View File

@@ -11,10 +11,7 @@
<script>
export default {
title: "标题栏",
props: ["res"],
mounted() {
console.log(this.res);
},
props: ["res"]
};
</script>
<style lang="scss" scoped>

View File

@@ -18,10 +18,7 @@
<script>
export default {
title: "上一下二",
props: ["res"],
mounted() {
console.log(this.res);
}
props: ["res"]
};
</script>
<style lang="scss" scoped>

View File

@@ -18,9 +18,6 @@
export default {
title: "上二下一",
props: ["res"],
mounted() {
console.log(this.res);
}
};
</script>
<style lang="scss" scoped>

View File

@@ -3,9 +3,6 @@
</template>
<script>
export default {
destroyed(){
}
}
</script>
<style scoped lang="scss">

View File

@@ -96,11 +96,13 @@ export default {
this.init();
},
methods: {
// 切换tab
clickType(val,index) {
this.params.pageNumber = 1
this.selectedIndex = index
this.params.pageType = val;
},
// 是否发布
changeSwitch(item) {
this.loading = true;
API_Other.releasePageHome(item.id).then((res) => {
@@ -115,6 +117,7 @@ export default {
this.loading = false;
});
},
// 初始化数据
init() {
this.loading = true;
API_Other.getHomeList(this.params).then((res) => {
@@ -132,20 +135,20 @@ export default {
this.total = res.result.total;
});
},
// 装修楼层
handleEdit(val) {
this.$router.push({
path: "/floorList/main",
query: { id: val.id, name: val.name, type: val.pageShow },
});
},
// 添加模板
handleAdd() {
this.$router.push({
path: "/floorList/main",
});
},
// 删除模板
handleDel(val) {
this.loading = true;
API_Other.removePageHome(val.id).then((res) => {