综合查询

This commit is contained in:
cwchen 2025-04-03 11:55:56 +08:00
parent e81ea39913
commit c8d7a9c2c8
4 changed files with 52 additions and 9 deletions

View File

@ -104,6 +104,12 @@
<if test="title!=null and title!=''">
AND INSTR(tcq.title,#{title}) > 0 AND tcq.upload_type = '5'
</if>
<if test="photoType != null and photoType.size() > 0">
AND sfr.source_type IN
<foreach collection="photoType" item="item" open="(" separator="," close=")">
#{item}
</foreach>
</if>
</if>
<if test="roleLevel = 0 and proIds != null and proIds.size() > 0">
AND tcq.pro_id IN

View File

@ -155,13 +155,32 @@ function initImgData(list) {
/**收藏*/
function collectImg(that, item, type) {
if (type === 0) { // 收藏
$(that).next().removeAttr("style");
$(that).css({'display': 'none'})
$(that).parent().parent().prev().find('img').eq(0).removeAttr('style')
let flag = collectData({
collectType: 1,
id: item.id
});
if (flag) {
$(that).next().removeAttr("style");
$(that).css({'display': 'none'})
$(that).parent().parent().prev().find('img').eq(0).removeAttr('style')
layer.msg("收藏成功",{icon:1})
}else{
layer.msg("收藏失败",{icon:2})
}
} else if (type === 1) { // 取消收藏
$(that).prev().removeAttr("style");
$(that).css({'display': 'none'});
$(that).parent().parent().prev().find('img').eq(0).css({'display': 'none'})
let flag = collectData({
collectType: 2,
id: item.id
});
if (flag) {
$(that).prev().removeAttr("style");
$(that).css({'display': 'none'});
$(that).parent().parent().prev().find('img').eq(0).css({'display': 'none'})
layer.msg("取消收藏成功",{icon:1})
}else{
layer.msg("取消收藏失败",{icon:2})
}
}
}
@ -217,7 +236,7 @@ function searchData(queryParams) {
}
/**重置基本数据*/
function resetData(){
function resetData() {
pageNum = 1;
$('.type-num').each(function () {
$(this).removeClass('type-num-check');

View File

@ -16,7 +16,7 @@ function initImgNum() {
error(xhr)
});
function setImgNum(obj){
function setImgNum(obj) {
$('#totalNum').html(obj.totalNum);
$('#safetyVioNum').html(obj.safetyVioNum);
$('#qualityInsNum').html(obj.qualityInsNum);
@ -24,4 +24,22 @@ function initImgNum() {
$('#coordinatedPhotoNum').html(obj.coordinatedPhotoNum);
$('#importIssuesAndPublicityNum').html(obj.importIssuesAndPublicityNum);
}
}
/**收藏/取消收藏图片*/
function collectData(objParams) {
let flag = false;
let url = dataUrl + "/backstage/synthesisQuery/collectData"
let params = {
encryptedData: encryptCBC(JSON.stringify(objParams))
}
ajaxRequest(url, "POST", params, false, function () {
}, function (result) {
if (result.status === 200) {
flag = true;
}
}, function (xhr) {
error(xhr)
});
return flag;
}

View File

@ -32,7 +32,7 @@
<div class="layui-inline">
<label class="layui-form-label">日期范围</label>
<div class="layui-input-inline">
<input type="text" class="layui-input" id="dateRange"
<input type="text" class="layui-input" id="dateRange" name="dateRange"
placeholder="开始结束 - 结束日期 ">
</div>
</div>