...
|
...
|
@@ -15,18 +15,18 @@ |
|
|
</div>
|
|
|
|
|
|
<div class="panel-body">
|
|
|
<div class="showCategory">
|
|
|
<div v-show="shopId > 0" class="showCategory">
|
|
|
<div class="addCategory">
|
|
|
<a class="btn btn-success addBtn"><i class="fa fa-plus"></i> 新增销售类目</a>
|
|
|
<span class="addTips">
|
|
|
当前店铺共有:<b>{{grid.url}}</b>条销售类目,<em>最多可以添加20条</em>
|
|
|
当前店铺共有:<b>{{categoryNum}}</b>条销售类目,<em>最多可以添加20条</em>
|
|
|
</span>
|
|
|
</div>
|
|
|
<div class="categoryList">
|
|
|
<com-grid :columns="grid.columns" :url="grid.url"></com-grid>
|
|
|
<com-grid :columns="grid.columns" :url="grid.url" :pageAble="false"></com-grid>
|
|
|
</div>
|
|
|
</div>
|
|
|
<h1 class="initCategory">请先选择相关店铺!</h1>
|
|
|
<h1 v-show="shopId < 0" class="initCategory">请先选择相关店铺!</h1>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
...
|
...
|
@@ -48,8 +48,9 @@ |
|
|
shopId: -1,
|
|
|
shopName: '--',
|
|
|
selectUrl: '/ShopsRest/selectCheckPassShopsByName',
|
|
|
categoryNum: 0,
|
|
|
grid: {
|
|
|
url: '2',
|
|
|
url: '/shops/shopsCategoryList',
|
|
|
columns: [
|
|
|
{display: '类目ID', name: 'id'},
|
|
|
{display: '类目名称', name: 'name'},
|
...
|
...
|
@@ -75,12 +76,19 @@ |
|
|
ready(){
|
|
|
|
|
|
},
|
|
|
watch: {},
|
|
|
methods: {},
|
|
|
methods: {
|
|
|
getCategoryList(){
|
|
|
this.$broadcast('grid-reload',{shop_id:this.shopId});
|
|
|
}
|
|
|
},
|
|
|
events: {
|
|
|
completeSelect(data){
|
|
|
this.shopId = data.id;
|
|
|
this.shopName = data.text;
|
|
|
this.getCategoryList();
|
|
|
},
|
|
|
completeGrid(data){
|
|
|
this.categoryNum = data.length;
|
|
|
}
|
|
|
}
|
|
|
}
|
...
|
...
|
@@ -113,10 +121,6 @@ |
|
|
margin-top: 20px
|
|
|
}
|
|
|
|
|
|
.showCategory {
|
|
|
display1: none
|
|
|
}
|
|
|
|
|
|
.addCategory {
|
|
|
margin-bottom: 20px;
|
|
|
}
|
...
|
...
|
|