优化搜索

This commit is contained in:
mingsoft 2021-10-23 16:42:42 +08:00
parent 46b1271966
commit d5ec6b8350
4 changed files with 12 additions and 5 deletions

View File

@ -219,8 +219,13 @@
<if test="contentTitle != null and contentTitle != ''"> and content_title like CONCAT(CONCAT('%',#{contentTitle}),'%')</if> <if test="contentTitle != null and contentTitle != ''"> and content_title like CONCAT(CONCAT('%',#{contentTitle}),'%')</if>
<if test="categoryId != null and categoryId != ''"> and (ct.category_id=#{categoryId} or ct.category_id in <if test="categoryId != null and categoryId != ''"> and (ct.category_id=#{categoryId} or ct.category_id in
(select id FROM cms_category where find_in_set('${categoryId}',CATEGORY_PARENT_IDS)>0))</if> (select id FROM cms_category where find_in_set('${categoryId}',CATEGORY_PARENT_IDS)>0))</if>
<if test="categoryType != null and categoryType != ''">and cc.category_type=#{categoryType}</if> <if test="contentType != null and contentType != ''">
<if test="contentType != null and contentType != ''"> and content_type LIKE CONCAT(CONCAT('%',#{contentType}),'%')</if> and
<foreach item="item" index="index" collection="contentType.split(',')" open="(" separator="or"
close=")">
FIND_IN_SET('${item}',ct.content_type)>0
</foreach>
</if>
<if test="contentDisplay != null and contentDisplay != ''"> and content_display=#{contentDisplay}</if> <if test="contentDisplay != null and contentDisplay != ''"> and content_display=#{contentDisplay}</if>
<if test="contentAuthor != null and contentAuthor != ''"> and content_author=#{contentAuthor}</if> <if test="contentAuthor != null and contentAuthor != ''"> and content_author=#{contentAuthor}</if>
<if test="contentSource != null and contentSource != ''"> and content_source=#{contentSource}</if> <if test="contentSource != null and contentSource != ''"> and content_source=#{contentSource}</if>

View File

@ -221,7 +221,7 @@
<i class="el-icon-plus"></i> <i class="el-icon-plus"></i>
<div slot="tip" class="ms-form-tip"> <div slot="tip" class="ms-form-tip">
只能上传1张图片 只能上传1张图片
标签:<a href="http://doc.mingsoft.net/mcms/biao-qian/lan-mu-lie-biao-ms-channel.html" target="_blank">${'$'}<#noparse >{@ms:file field.typelitpic/}</#noparse></a><br/> 标签:<a href="http://doc.mingsoft.net/mcms/biao-qian/lan-mu-lie-biao-ms-channel.html" target="_blank"><#noparse>{@ms:file field.typelitpic/}</#noparse></a><br/>
</div> </div>
</el-upload> </el-upload>
</el-form-item> </el-form-item>

View File

@ -271,6 +271,7 @@
}).then(function (res) { }).then(function (res) {
if (res.result) { if (res.result) {
that.$notify({ that.$notify({
title: '成功 ',
type: 'success', type: 'success',
message: '删除成功!' message: '删除成功!'
}); //删除成功,刷新列表 }); //删除成功,刷新列表

View File

@ -33,8 +33,8 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="文章类型" prop="categoryFlag"> <el-form-item label="文章类型" prop="contentType">
<el-select v-model="form.categoryFlag" <el-select v-model="form.contentType"
:style="{width: '100%'}" :style="{width: '100%'}"
:filterable="false" :filterable="false"
:disabled="false" :disabled="false"
@ -349,6 +349,7 @@
}).then(function (res) { }).then(function (res) {
if (res.result) { if (res.result) {
that.$notify({ that.$notify({
title:'成功',
type: 'success', type: 'success',
message: '删除成功!' message: '删除成功!'
}); //删除成功,刷新列表 }); //删除成功,刷新列表