Compare commits
No commits in common. "71ec511819f778f4ad1ed6fcbfe40a0cdeb3f6b2" and "3ee97a885a2271afbd22f07bb057ea233f88b025" have entirely different histories.
71ec511819
...
3ee97a885a
@ -172,13 +172,10 @@ public class WebController extends BaseController {
|
||||
* @date 10:04 2025/7/8
|
||||
**/
|
||||
@ApiOperation("热门产品-前10")
|
||||
@ApiImplicitParams(value = {
|
||||
@ApiImplicitParam(name = "tenantId", value = "站点唯一码", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "showPlat", value = "平台标识(网站|App)", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
})
|
||||
@ApiImplicitParam(name = "tenantId", value = "站点唯一码", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
@GetMapping("/hotProduct")
|
||||
public R<List<BusiProdNew>> hotProduct(@RequestParam(required = true) String tenantId,@RequestParam(required = true) String showPlat) {
|
||||
return R.ok(prodNewService.hotProdOrNews(tenantId, DATA_TYPE_PRODUCT, true,showPlat));
|
||||
public R<List<BusiProdNew>> hotProduct(@RequestParam(required = true) String tenantId) {
|
||||
return R.ok(prodNewService.hotProdOrNews(tenantId, DATA_TYPE_PRODUCT, true));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -189,13 +186,10 @@ public class WebController extends BaseController {
|
||||
* @date 10:04 2025/7/8
|
||||
**/
|
||||
@ApiOperation("普通产品-前10")
|
||||
@ApiImplicitParams(value = {
|
||||
@ApiImplicitParam(name = "tenantId", value = "站点唯一码", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "showPlat", value = "平台标识(网站|App)", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
})
|
||||
@ApiImplicitParam(name = "tenantId", value = "站点唯一码", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
@GetMapping("/product")
|
||||
public R<List<BusiProdNew>> product(@RequestParam(required = true) String tenantId,@RequestParam(required = true) String showPlat) {
|
||||
return R.ok(prodNewService.hotProdOrNews(tenantId, DATA_TYPE_PRODUCT, false,showPlat));
|
||||
public R<List<BusiProdNew>> product(@RequestParam(required = true) String tenantId) {
|
||||
return R.ok(prodNewService.hotProdOrNews(tenantId, DATA_TYPE_PRODUCT, false));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -206,13 +200,10 @@ public class WebController extends BaseController {
|
||||
* @date 10:04 2025/7/8
|
||||
**/
|
||||
@ApiOperation("热门新闻-前10")
|
||||
@ApiImplicitParams(value = {
|
||||
@ApiImplicitParam(name = "tenantId", value = "站点唯一码", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "showPlat", value = "平台标识(网站|App)", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
})
|
||||
@ApiImplicitParam(name = "tenantId", value = "站点唯一码", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
@GetMapping("/hotNews")
|
||||
public R<List<BusiProdNew>> hotNews(@RequestParam(required = true) String tenantId,@RequestParam(required = true) String showPlat) {
|
||||
return R.ok(prodNewService.hotProdOrNews(tenantId, DATA_TYPE_NEWS, true,showPlat));
|
||||
public R<List<BusiProdNew>> hotNews(@RequestParam(required = true) String tenantId) {
|
||||
return R.ok(prodNewService.hotProdOrNews(tenantId, DATA_TYPE_NEWS, true));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -246,18 +237,16 @@ public class WebController extends BaseController {
|
||||
@ApiImplicitParam(name = "pageNum", value = "页码(1开始)", required = true, dataType = "int", paramType = "query", dataTypeClass = Integer.class),
|
||||
@ApiImplicitParam(name = "pageSize", value = "每页显示数量", required = true, dataType = "int", paramType = "query", dataTypeClass = Integer.class),
|
||||
@ApiImplicitParam(name = "catgId", value = "分类id", required = false, dataType = "string", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "text", value = "搜索内容", required = false, dataType = "string", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "showPlat", value = "平台标识(网站|App)", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
@ApiImplicitParam(name = "text", value = "搜索内容", required = false, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
})
|
||||
@GetMapping("/prodPageList")
|
||||
public R<IPage<BusiProdNew>> prodPageList(String tenantId, @RequestParam(required = false) String catgId, @RequestParam(required = false) String text,String showPlat,
|
||||
public R<IPage<BusiProdNew>> prodPageList(String tenantId, String catgId, String text,
|
||||
@RequestParam(name = "pageNum", defaultValue = "1") Integer pageNum,
|
||||
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize) {
|
||||
Page<BusiProdNew> page = new Page<>(pageNum, pageSize);
|
||||
LambdaQueryWrapper<BusiProdNew> queryWrapper = new LambdaQueryWrapper<BusiProdNew>()
|
||||
.eq(BusiProdNew::getDataType, DATA_TYPE_PRODUCT)
|
||||
.eq(BusiProdNew::getIfPublic, true)
|
||||
.like(BusiProdNew::getShowPlat,showPlat)
|
||||
.eq(BusiProdNew::getTenantId, tenantId);
|
||||
if (StringUtils.isNotEmpty(text)) {
|
||||
queryWrapper.and(wq -> wq
|
||||
@ -302,18 +291,16 @@ public class WebController extends BaseController {
|
||||
@ApiImplicitParam(name = "pageNum", value = "页码(1开始)", required = true, dataType = "int", paramType = "query", dataTypeClass = Integer.class),
|
||||
@ApiImplicitParam(name = "pageSize", value = "每页显示数量", required = true, dataType = "int", paramType = "query", dataTypeClass = Integer.class),
|
||||
@ApiImplicitParam(name = "catgId", value = "分类id", required = false, dataType = "string", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "text", value = "搜索内容", required = false, dataType = "string", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "showPlat", value = "平台标识(网站|App)", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
@ApiImplicitParam(name = "text", value = "搜索内容", required = false, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
})
|
||||
@GetMapping("/newsPageList")
|
||||
public R<IPage<BusiProdNew>> newsPageList(String tenantId, @RequestParam(required = false) String catgId, @RequestParam(required = false) String text,String showPlat,
|
||||
public R<IPage<BusiProdNew>> newsPageList(String tenantId, String catgId, String text,
|
||||
@RequestParam(name = "pageNum", defaultValue = "1") Integer pageNum,
|
||||
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize) {
|
||||
Page<BusiProdNew> page = new Page<>(pageNum, pageSize);
|
||||
LambdaQueryWrapper<BusiProdNew> queryWrapper = new LambdaQueryWrapper<BusiProdNew>()
|
||||
.eq(BusiProdNew::getDataType, DATA_TYPE_NEWS)
|
||||
.eq(BusiProdNew::getIfPublic, true)
|
||||
.like(BusiProdNew::getShowPlat,showPlat)
|
||||
.eq(BusiProdNew::getTenantId, tenantId);
|
||||
if (StringUtils.isNotEmpty(text)) {
|
||||
queryWrapper.and(wq -> wq
|
||||
@ -367,15 +354,14 @@ public class WebController extends BaseController {
|
||||
@ApiImplicitParam(name = "tenantId", value = "站点唯一码", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "pageNum", value = "页码(1开始)", required = true, dataType = "int", paramType = "query", dataTypeClass = Integer.class),
|
||||
@ApiImplicitParam(name = "pageSize", value = "每页显示数量", required = true, dataType = "int", paramType = "query", dataTypeClass = Integer.class),
|
||||
@ApiImplicitParam(name = "text", value = "搜索内容", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "showPlat", value = "平台标识(网站|App)", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
@ApiImplicitParam(name = "text", value = "搜索内容", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class)
|
||||
})
|
||||
@GetMapping("/searchText")
|
||||
public R<IPage<BusiProdNew>> searchText(String tenantId, String text,String showPlat,
|
||||
public R<IPage<BusiProdNew>> searchText(String tenantId, String text,
|
||||
@RequestParam(name = "pageNum", defaultValue = "1") Integer pageNum,
|
||||
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize) {
|
||||
Page<BusiProdNew> page = new Page<>(pageNum, pageSize);
|
||||
return R.ok(prodNewService.searchTextAll(tenantId, text, page,showPlat));
|
||||
return R.ok(prodNewService.searchTextAll(tenantId, text, page));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -5,10 +5,8 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.ruoyi.base.service.IBasePicsService;
|
||||
import com.ruoyi.busi.domain.BusiProdNew;
|
||||
import com.ruoyi.busi.domain.BusiProdRandom;
|
||||
import com.ruoyi.busi.domain.BusiRelation;
|
||||
import com.ruoyi.busi.service.IBusiProdNewService;
|
||||
import com.ruoyi.busi.service.IBusiProdRandomService;
|
||||
import com.ruoyi.busi.service.IBusiRelationService;
|
||||
import com.ruoyi.busi.utils.SimHash;
|
||||
import com.ruoyi.busi.utils.TextPreprocessor;
|
||||
import com.ruoyi.busi.vo.ProdNewVO;
|
||||
@ -17,7 +15,6 @@ import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
@ -46,8 +43,6 @@ public class BusiNewController extends BaseController
|
||||
private IBasePicsService basePicsService;
|
||||
@Autowired
|
||||
private IBusiProdRandomService prodRandomService;
|
||||
@Autowired
|
||||
private IBusiRelationService relationService;
|
||||
|
||||
/**
|
||||
* 查询新闻列表
|
||||
@ -126,13 +121,6 @@ public class BusiNewController extends BaseController
|
||||
});
|
||||
basePicsService.saveBatch(prodNewVO.getFileList());
|
||||
}
|
||||
//默认负责人就是当前用户
|
||||
BusiRelation relation = new BusiRelation();
|
||||
relation.setUserId(SecurityUtils.getUserId());
|
||||
relation.setProdId(prodNewVO.getId());
|
||||
relation.setTenantId(prodNewVO.getTenantId());
|
||||
relationService.save(relation);
|
||||
|
||||
busiProdNewService.setAmount(prodNewVO.getTenantId());
|
||||
return success();
|
||||
}
|
||||
|
@ -10,14 +10,11 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.ruoyi.base.service.IBasePicsService;
|
||||
import com.ruoyi.busi.domain.BusiProdRandom;
|
||||
import com.ruoyi.busi.domain.BusiRelation;
|
||||
import com.ruoyi.busi.service.IBusiProdRandomService;
|
||||
import com.ruoyi.busi.service.IBusiRelationService;
|
||||
import com.ruoyi.busi.utils.SimHash;
|
||||
import com.ruoyi.busi.utils.TextPreprocessor;
|
||||
import com.ruoyi.busi.vo.ProdNewVO;
|
||||
import com.ruoyi.busi.vo.ProdRandomVO;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@ -57,8 +54,6 @@ public class BusiProdController extends BaseController
|
||||
private IBasePicsService basePicsService;
|
||||
@Autowired
|
||||
private IBusiProdRandomService prodRandomService;
|
||||
@Autowired
|
||||
private IBusiRelationService relationService;
|
||||
|
||||
/**
|
||||
* 查询产品列表
|
||||
@ -137,13 +132,6 @@ public class BusiProdController extends BaseController
|
||||
});
|
||||
basePicsService.saveBatch(prodNewVO.getFileList());
|
||||
}
|
||||
//默认负责人就是当前用户
|
||||
BusiRelation relation = new BusiRelation();
|
||||
relation.setUserId(SecurityUtils.getUserId());
|
||||
relation.setProdId(prodNewVO.getId());
|
||||
relation.setTenantId(prodNewVO.getTenantId());
|
||||
relationService.save(relation);
|
||||
|
||||
busiProdNewService.setAmount(prodNewVO.getTenantId());
|
||||
return success();
|
||||
}
|
||||
|
@ -89,7 +89,7 @@ public class BusiRelationController extends BaseController
|
||||
List<BusiRelation> busiRelationList = new ArrayList<>();
|
||||
userIdList.forEach(item->{
|
||||
BusiRelation relation = new BusiRelation();
|
||||
relation.setUserId(Long.valueOf(item));
|
||||
relation.setUserId(item);
|
||||
relation.setProdId(busiRelation.getProdId());
|
||||
relation.setTenantId(busiRelation.getTenantId());
|
||||
busiRelationList.add(relation);
|
||||
|
@ -30,7 +30,7 @@ public class BusiRelation extends DlBaseEntity
|
||||
|
||||
/** 用户id */
|
||||
@Excel(name = "用户id")
|
||||
private Long userId;
|
||||
private String userId;
|
||||
|
||||
/** 产品、新闻id */
|
||||
@Excel(name = "产品、新闻id")
|
||||
|
@ -54,7 +54,7 @@ public interface IBusiProdNewService extends IService<BusiProdNew>
|
||||
* @param tenantId 租户id
|
||||
* @return java.util.List<com.ruoyi.busi.domain.BusiProdNew>
|
||||
**/
|
||||
List<BusiProdNew> hotProdOrNews(String tenantId,String dateType,Boolean ifHot,String showPlat);
|
||||
List<BusiProdNew> hotProdOrNews(String tenantId,String dateType,Boolean ifHot);
|
||||
|
||||
/**
|
||||
* web站点查看详情
|
||||
@ -74,7 +74,7 @@ public interface IBusiProdNewService extends IService<BusiProdNew>
|
||||
* @param page 分页对象
|
||||
* @return com.baomidou.mybatisplus.core.metadata.IPage<com.ruoyi.busi.vo.ProdNewVO>
|
||||
**/
|
||||
IPage<BusiProdNew> searchTextAll(String tenantId, String text,Page<BusiProdNew> page,String showPlat);
|
||||
IPage<BusiProdNew> searchTextAll(String tenantId, String text,Page<BusiProdNew> page);
|
||||
|
||||
/**
|
||||
* 相似度检测
|
||||
|
@ -146,14 +146,13 @@ public class BusiProdNewServiceImpl extends ServiceImpl<BusiProdNewMapper,BusiPr
|
||||
* @date 11:33 2025/7/8
|
||||
**/
|
||||
@Override
|
||||
public List<BusiProdNew> hotProdOrNews(String tenantId,String dateType,Boolean ifHot,String showPlat) {
|
||||
public List<BusiProdNew> hotProdOrNews(String tenantId,String dateType,Boolean ifHot) {
|
||||
Page<BusiProdNew> page = new Page<>(1, 10);
|
||||
LambdaQueryWrapper<BusiProdNew> queryWrapper = new LambdaQueryWrapper<BusiProdNew>()
|
||||
.eq(BusiProdNew::getTenantId,tenantId)
|
||||
.eq(BusiProdNew::getDataType,dateType)
|
||||
.eq(BusiProdNew::getIfPublic,true)
|
||||
.eq(BusiProdNew::getIfReco,ifHot)
|
||||
.like(BusiProdNew::getShowPlat,showPlat)
|
||||
.orderByDesc(BusiProdNew::getSort);
|
||||
//查所有栏目
|
||||
BusiCategory category = new BusiCategory();
|
||||
@ -203,11 +202,10 @@ public class BusiProdNewServiceImpl extends ServiceImpl<BusiProdNewMapper,BusiPr
|
||||
* @date 13:55 2025/7/9
|
||||
**/
|
||||
@Override
|
||||
public IPage<BusiProdNew> searchTextAll(String tenantId, String text, Page<BusiProdNew> page,String showPlat) {
|
||||
public IPage<BusiProdNew> searchTextAll(String tenantId, String text, Page<BusiProdNew> page) {
|
||||
LambdaQueryWrapper<BusiProdNew> queryWrapper = new LambdaQueryWrapper<BusiProdNew>()
|
||||
.eq(BusiProdNew::getTenantId,tenantId)
|
||||
.eq(BusiProdNew::getIfPublic,true)
|
||||
.like(BusiProdNew::getShowPlat,showPlat)
|
||||
.and(wq->wq
|
||||
.like(BusiProdNew::getTitle,text)
|
||||
.or().like(BusiProdNew::getDescription,text)
|
||||
|
@ -4,16 +4,6 @@
|
||||
<el-form-item label="分类" prop="catgId">
|
||||
<treeselect style="width: 200px" v-model="queryParams.catgId" :options="catgOptions" :normalizer="normalizer" :noResultsText="'暂无数据'" placeholder="选择分类" />
|
||||
</el-form-item>
|
||||
<el-form-item label="展示平台" prop="showPlat">
|
||||
<el-select v-model="queryParams.showPlat" placeholder="请选择展示平台" clearable>
|
||||
<el-option
|
||||
v-for="dict in dict.type.show_plateform"
|
||||
:key="dict.value"
|
||||
:label="dict.label"
|
||||
:value="dict.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="新闻标题" prop="title">
|
||||
<el-input
|
||||
v-model="queryParams.title"
|
||||
@ -85,7 +75,6 @@
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="新闻负责人" align="center" prop="leaderName" />
|
||||
<el-table-column label="展示平台" align="center" prop="showPlat" />
|
||||
<!-- <el-table-column label="产品简介" align="center" prop="description" />-->
|
||||
<el-table-column width="100" label="排序" align="center" prop="sort">
|
||||
<template slot="header" slot-scope="scope">
|
||||
@ -201,7 +190,7 @@ import "@riophae/vue-treeselect/dist/vue-treeselect.css";
|
||||
|
||||
export default {
|
||||
name: "New",
|
||||
dicts: ['sys_yes_no','show_plateform'],
|
||||
dicts: ['sys_yes_no'],
|
||||
components: { selectAllUser,selectProduct,randomProduct ,Treeselect},
|
||||
data() {
|
||||
return {
|
||||
|
@ -202,21 +202,10 @@
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="展示平台" prop="showPlat">
|
||||
<el-checkbox-group v-model="showPlatList" @change="changeCheckBox">
|
||||
<el-checkbox v-for="dict in dict.type.show_plateform" :label="dict.label" :value="dict.value"></el-checkbox>
|
||||
</el-checkbox-group>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="新闻内容">
|
||||
<editor :key="showKeywords" v-model="form.content" :min-height="192"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-form-item label="新闻内容">
|
||||
<editor :key="showKeywords" v-model="form.content" :min-height="192"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-col>
|
||||
</el-row>
|
||||
@ -259,7 +248,6 @@ import SimilarityNew from './similarityNew'
|
||||
export default {
|
||||
name: 'newForm',
|
||||
components: { SimilarityNew, Treeselect, selectPic , Hamburger , countTo},
|
||||
dicts: ['show_plateform'],
|
||||
data() {
|
||||
return {
|
||||
//光标位置--简介
|
||||
@ -281,7 +269,6 @@ export default {
|
||||
prodTitle: null,
|
||||
prodKeyword: null,
|
||||
prodDescription: null,
|
||||
showPlat: '网站,App',
|
||||
newsFrom: null,
|
||||
publicDate: null,
|
||||
mainPic: null,
|
||||
@ -300,8 +287,6 @@ export default {
|
||||
//当前上传的所有图片
|
||||
fileList: []
|
||||
},
|
||||
//选中的展示平台
|
||||
showPlatList:['网站','App'],
|
||||
formSeo: {
|
||||
title: '',
|
||||
needUrl: true,
|
||||
@ -342,9 +327,6 @@ export default {
|
||||
],
|
||||
description: [
|
||||
{ required: true, message: '请输入新闻简介', trigger: 'blur' }
|
||||
],
|
||||
showPlat: [
|
||||
{ required: true, message: '请选择展示平台', trigger: 'blur' }
|
||||
]
|
||||
},
|
||||
rulesSeo:{
|
||||
@ -376,12 +358,6 @@ export default {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* 选中展示平台
|
||||
*/
|
||||
changeCheckBox(value){
|
||||
this.form.showPlat = value.join(",")
|
||||
},
|
||||
useProdName(){
|
||||
this.formSeo.title = this.form.title
|
||||
},
|
||||
@ -495,7 +471,6 @@ export default {
|
||||
getProdInfo(id, type) {
|
||||
getProdNew(id).then(response => {
|
||||
this.form = response.data
|
||||
this.showPlatList = this.form.showPlat.split(',')
|
||||
if (this.form.pics && this.form.pics.length > 0) {
|
||||
this.canPicsNum = this.picsNum - this.form.pics.split(',').length
|
||||
}
|
||||
|
@ -4,16 +4,6 @@
|
||||
<el-form-item label="分类" prop="catgId">
|
||||
<treeselect style="width: 200px" v-model="queryParams.catgId" :options="catgOptions" :normalizer="normalizer" :noResultsText="'暂无数据'" placeholder="选择分类" />
|
||||
</el-form-item>
|
||||
<el-form-item label="展示平台" prop="showPlat">
|
||||
<el-select v-model="queryParams.showPlat" placeholder="请选择展示平台" clearable>
|
||||
<el-option
|
||||
v-for="dict in dict.type.show_plateform"
|
||||
:key="dict.value"
|
||||
:label="dict.label"
|
||||
:value="dict.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="产品名称" prop="title">
|
||||
<el-input
|
||||
v-model="queryParams.title"
|
||||
@ -84,8 +74,7 @@
|
||||
<image-preview :src="scope.row.mainPic" :width="50" :height="50"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="产品负责人" align="center" prop="leaderName" :min-width="100" />
|
||||
<el-table-column label="展示平台" align="center" prop="showPlat" />
|
||||
<el-table-column label="产品负责人" align="center" prop="leaderName" :min-width="200" />
|
||||
<!-- <el-table-column label="产品简介" align="center" prop="description" />-->
|
||||
<el-table-column width="100" label="排序" align="center" prop="sort">
|
||||
<template slot="header" slot-scope="scope">
|
||||
@ -201,7 +190,7 @@ import "@riophae/vue-treeselect/dist/vue-treeselect.css";
|
||||
|
||||
export default {
|
||||
name: "Prod",
|
||||
dicts: ['sys_yes_no','show_plateform'],
|
||||
dicts: ['sys_yes_no'],
|
||||
components: { selectAllUser ,selectProduct,randomProduct,Treeselect},
|
||||
data() {
|
||||
return {
|
||||
|
@ -172,20 +172,11 @@
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="展示平台" prop="showPlat">
|
||||
<el-checkbox-group v-model="showPlatList" @change="changeCheckBox">
|
||||
<el-checkbox v-for="dict in dict.type.show_plateform" :label="dict.label" :value="dict.value"></el-checkbox>
|
||||
</el-checkbox-group>
|
||||
</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="开启后将在网站首页优先显示"
|
||||
<span>首页显示</span>
|
||||
<el-tooltip class="item" effect="dark" content="开启后将在首页优先显示"
|
||||
placement="bottom"
|
||||
>
|
||||
<i class="el-icon-question"></i>
|
||||
@ -198,13 +189,9 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="产品内容">
|
||||
<editor :key="showKeywords" v-model="form.content" :min-height="192"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-form-item label="产品内容">
|
||||
<editor :key="showKeywords" v-model="form.content" :min-height="192"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-col>
|
||||
</el-row>
|
||||
@ -247,7 +234,6 @@ import SimilarityProduct from './similarityProduct'
|
||||
export default {
|
||||
name: 'prodForm',
|
||||
components: { SimilarityProduct, Treeselect, selectPic, Hamburger , countTo},
|
||||
dicts: ['show_plateform'],
|
||||
data() {
|
||||
return {
|
||||
//光标位置--简介
|
||||
@ -269,7 +255,6 @@ export default {
|
||||
prodTitle: null,
|
||||
prodKeyword: null,
|
||||
prodDescription: null,
|
||||
showPlat: '网站,App',
|
||||
newsFrom: null,
|
||||
mainPic: null,
|
||||
pics: null,
|
||||
@ -287,8 +272,6 @@ export default {
|
||||
//当前上传的所有图片
|
||||
fileList: []
|
||||
},
|
||||
//选中的展示平台
|
||||
showPlatList:['网站','App'],
|
||||
formSeo: {
|
||||
title: '',
|
||||
needUrl: true,
|
||||
@ -323,9 +306,6 @@ export default {
|
||||
],
|
||||
description: [
|
||||
{ required: true, message: '请输入产品简介', trigger: 'blur' }
|
||||
],
|
||||
showPlat: [
|
||||
{ required: true, message: '请选择展示平台', trigger: 'blur' }
|
||||
]
|
||||
},
|
||||
rulesSeo:{
|
||||
@ -357,12 +337,6 @@ export default {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* 选中展示平台
|
||||
*/
|
||||
changeCheckBox(value){
|
||||
this.form.showPlat = value.join(",")
|
||||
},
|
||||
useProdName(){
|
||||
this.formSeo.title = this.form.title
|
||||
},
|
||||
@ -476,7 +450,6 @@ export default {
|
||||
getProdInfo(id, type) {
|
||||
getProdNew(id).then(response => {
|
||||
this.form = response.data
|
||||
this.showPlatList = this.form.showPlat.split(',')
|
||||
if (this.form.pics && this.form.pics.length > 0) {
|
||||
this.canPicsNum = this.picsNum - this.form.pics.split(',').length
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user