This commit is contained in:
Vinjor 2025-06-30 16:19:56 +08:00
parent ba81f4eef7
commit 02ca68142a
2 changed files with 17 additions and 3 deletions

View File

@ -156,7 +156,10 @@ public class BusiProdController extends BaseController
@DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable String[] ids){
List<String> list = new ArrayList<>(Arrays.asList(ids));
return toAjax(busiProdNewService.removeByIds(list));
BusiProdNew prodNew = busiProdNewService.getById(list.get(0));
busiProdNewService.removeByIds(list);
busiProdNewService.setAmount(prodNew.getTenantId());
return success();
}
/**

View File

@ -19,7 +19,7 @@
<el-form-item label="所属分类" prop="catgId">
<div class="dl-flex-column">
<treeselect style="width: 200px" v-model="form.catgId" :options="catgOptions" :normalizer="normalizer" :noResultsText="'暂无数据'" placeholder="请选择产品分类" />
<div class="dl-add-catg">添加产品分类</div>
<div class="dl-add-catg" @click="goCatgView">添加产品分类</div>
</div>
</el-form-item>
</el-col>
@ -64,7 +64,15 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="首页推荐" prop="ifReco">
<el-form-item label="首页显示" prop="ifReco">
<template v-slot:label>
<span>首页显示</span>
<el-tooltip class="item" effect="dark" content="开启后将在首页优先显示"
placement="bottom"
>
<i class="el-icon-question"></i>
</el-tooltip>
</template>
<el-switch
v-model="form.ifReco"
>
@ -161,6 +169,9 @@ export default {
}
},
methods: {
goCatgView(){
this.$router.push({path:'/busi/category'})
},
initCatg(){
//
listCategory({catgType:"cp"}).then(response => {