Browse Source

预告和计划的短信 . 还有计划的筛选

dev-V1.2
蟑螂恶霸 5 days ago
parent
commit
2218072cf7
  1. 47
      zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/controller/app/enforcement/AppEnfCpPlanController.java
  2. 5
      zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/domain/bo/EfcodeCpPlanBo.java
  3. 8
      zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/service/impl/EfcodeCpNoticeServiceImpl.java
  4. 48
      zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/service/impl/EfcodeCpPlanServiceImpl.java
  5. 48
      zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/service/impl/OutEfcodeCpPlanServiceImpl.java
  6. 39
      zdxt-modules/zdxt-enforcement-code/src/main/resources/mapper/enforcementcode/EfcodeCpPlanMapper.xml
  7. 3
      zdxt-web-client/zdxt-efcode-enforcement-app/src/api/enforcement/plan.js
  8. 7
      zdxt-web-client/zdxt-efcode-enforcement-app/src/components/common/SearchFilterBar.vue
  9. 9
      zdxt-web-client/zdxt-efcode-enforcement-app/src/views/enforcement/my/plan/cp_plan_mine.vue
  10. 5
      zdxt-web-client/zdxt-efcode-enforcement-app/src/views/enforcement/my/plan/cp_plan_other.vue
  11. 16
      zdxt-web-client/zdxt-efcode-enterprise-app/src/views/enterprise/plan/planNoticeList.vue

47
zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/controller/app/enforcement/AppEnfCpPlanController.java

@ -5,7 +5,9 @@ import com.zdxt.enforcementcode.domain.bo.EfcodeCpPlanBo;
import com.zdxt.enforcementcode.domain.vo.EfcodeCpPlanVo; import com.zdxt.enforcementcode.domain.vo.EfcodeCpPlanVo;
import com.zdxt.enforcementcode.service.IEfcodeCpPlanService; import com.zdxt.enforcementcode.service.IEfcodeCpPlanService;
import com.zdxt.enforcementcode.service.IEfcodeCpReserveService; import com.zdxt.enforcementcode.service.IEfcodeCpReserveService;
import lombok.extern.slf4j.Slf4j;
import org.dromara.common.core.domain.R; import org.dromara.common.core.domain.R;
import org.dromara.common.core.utils.StringUtils;
import org.dromara.common.mybatis.core.page.PageQuery; import org.dromara.common.mybatis.core.page.PageQuery;
import org.dromara.common.mybatis.core.page.TableDataInfo; import org.dromara.common.mybatis.core.page.TableDataInfo;
import org.dromara.common.satoken.utils.LoginHelper; import org.dromara.common.satoken.utils.LoginHelper;
@ -21,6 +23,7 @@ import org.springframework.web.bind.annotation.*;
* @author Lion Li * @author Lion Li
* @date 2026-05-16 * @date 2026-05-16
*/ */
@Slf4j
@Validated @Validated
@RestController @RestController
@RequestMapping("/app-enf/cpPlan") @RequestMapping("/app-enf/cpPlan")
@ -53,11 +56,53 @@ public class AppEnfCpPlanController extends EfcodeCpPlanController {
return cpPlanService.queryPageList(bo, pageQuery); return cpPlanService.queryPageList(bo, pageQuery);
} }
/**
* 执法端-我的计划分页(独立接口,显式接收筛选参数,供 plan/mine 使用)
*/
@GetMapping("/myPageList")
public TableDataInfo<EfcodeCpPlanVo> myPageList(
EfcodeCpPlanBo bo,
PageQuery pageQuery,
@RequestParam(required = false) Integer dateType,
@RequestParam(required = false) String dateSearch,
@RequestParam(required = false) String searchValue) {
if (dateType != null) {
bo.setDateType(dateType);
}
if (StringUtils.isNotBlank(dateSearch)) {
bo.setDateSearch(dateSearch);
}
if (StringUtils.isNotBlank(searchValue)) {
bo.setSearchValue(searchValue);
}
bo.setCreateBy(LoginHelper.getUserId());
if (bo.getIsDelete() == null) {
bo.setIsDelete(0L);
}
log.info("[myPageList] userId={}, dateType={}, dateSearch={}, searchValue={}",
LoginHelper.getUserId(), bo.getDateType(), bo.getDateSearch(), bo.getSearchValue());
return cpPlanService.queryPageList(bo, pageQuery);
}
/** /**
* 查询其他计划列表(与当前用户计划同一时间段、同一企业的其他用户的计划) * 查询其他计划列表(与当前用户计划同一时间段、同一企业的其他用户的计划)
*/ */
@GetMapping("/otherList") @GetMapping("/otherList")
public TableDataInfo<EfcodeCpPlanVo> otherList(EfcodeCpPlanBo bo, PageQuery pageQuery) { public TableDataInfo<EfcodeCpPlanVo> otherList(
EfcodeCpPlanBo bo,
PageQuery pageQuery,
@RequestParam(required = false) Integer dateType,
@RequestParam(required = false) String dateSearch,
@RequestParam(required = false) String searchValue) {
if (dateType != null) {
bo.setDateType(dateType);
}
if (StringUtils.isNotBlank(dateSearch)) {
bo.setDateSearch(dateSearch);
}
if (StringUtils.isNotBlank(searchValue)) {
bo.setSearchValue(searchValue);
}
// 获取当前用户所属执法单位 // 获取当前用户所属执法单位
String bureauDeptId = resolveCurrentBureauDeptId(); String bureauDeptId = resolveCurrentBureauDeptId();
return cpPlanService.queryOverlapPageList(bo, pageQuery, bureauDeptId); return cpPlanService.queryOverlapPageList(bo, pageQuery, bureauDeptId);

5
zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/domain/bo/EfcodeCpPlanBo.java

@ -217,6 +217,11 @@ public class EfcodeCpPlanBo extends BaseEntity {
*/ */
private String outSerialNo; private String outSerialNo;
/**
* 关键字(覆盖基类带 @JsonIgnore 的 searchValue,保证 GET 参数可绑定)
*/
private String searchValue;
/** /**
* 日期类型筛选: 1=本月, 2=本季, 3=本年, 9=自定义月份 * 日期类型筛选: 1=本月, 2=本季, 3=本年, 9=自定义月份
*/ */

8
zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/service/impl/EfcodeCpNoticeServiceImpl.java

@ -109,14 +109,14 @@ public class EfcodeCpNoticeServiceImpl implements IEfcodeCpNoticeService {
/** /**
* 查询当前用户的预告列表(分页) * 查询当前企业的预告列表(分页)
* 过滤条件:create_by = 当前用户ID,is_delete = 0 * 企业端查询已发布待执法(1) + 历史已执行(3);草稿不返回
*/ */
@Override @Override
public TableDataInfo<EfcodeCpNoticeVo> entQueryMyPageList(EfcodeCpNoticeBo bo, PageQuery pageQuery) { public TableDataInfo<EfcodeCpNoticeVo> entQueryMyPageList(EfcodeCpNoticeBo bo, PageQuery pageQuery) {
LambdaQueryWrapper<EfcodeCpNotice> lqw = buildQueryWrapper(bo); LambdaQueryWrapper<EfcodeCpNotice> lqw = buildQueryWrapper(bo);
// 企业端只查询已发布(待执法)的预告 // 企业端:待执法 + 历史已执行
lqw.eq(EfcodeCpNotice::getStatus, 1L); lqw.in(EfcodeCpNotice::getStatus, 1L, 3L);
// 按创建时间倒序 // 按创建时间倒序
lqw.orderByDesc(EfcodeCpNotice::getCreateTime); lqw.orderByDesc(EfcodeCpNotice::getCreateTime);
Page<EfcodeCpNoticeVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw); Page<EfcodeCpNoticeVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);

48
zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/service/impl/EfcodeCpPlanServiceImpl.java

@ -336,6 +336,16 @@ public class EfcodeCpPlanServiceImpl implements IEfcodeCpPlanService {
lqw.eq(StringUtils.isNotBlank(bo.getMyRemark()), EfcodeCpPlan::getMyRemark, bo.getMyRemark()); lqw.eq(StringUtils.isNotBlank(bo.getMyRemark()), EfcodeCpPlan::getMyRemark, bo.getMyRemark());
lqw.eq(StringUtils.isNotBlank(bo.getChannelNo()), EfcodeCpPlan::getChannelNo, bo.getChannelNo()); lqw.eq(StringUtils.isNotBlank(bo.getChannelNo()), EfcodeCpPlan::getChannelNo, bo.getChannelNo());
lqw.eq(StringUtils.isNotBlank(bo.getOutSerialNo()), EfcodeCpPlan::getOutSerialNo, bo.getOutSerialNo()); lqw.eq(StringUtils.isNotBlank(bo.getOutSerialNo()), EfcodeCpPlan::getOutSerialNo, bo.getOutSerialNo());
// 关键字:企业名称 / 执法事项 / 执法单位 / 执法人员
if (StringUtils.isNotBlank(bo.getSearchValue())) {
String sv = bo.getSearchValue();
lqw.and(w -> w
.like(EfcodeCpPlan::getEnterpriseName, sv)
.or().like(EfcodeCpPlan::getEnforceContent, sv)
.or().like(EfcodeCpPlan::getBureauDeptName, sv)
.or().like(EfcodeCpPlan::getEnforceUserNames, sv)
);
}
// 本月/本季/本年/自定义月份(按 plan_date) // 本月/本季/本年/自定义月份(按 plan_date)
applyPlanDateFilter(lqw, bo.getDateType(), bo.getDateSearch()); applyPlanDateFilter(lqw, bo.getDateType(), bo.getDateSearch());
return lqw; return lqw;
@ -343,30 +353,36 @@ public class EfcodeCpPlanServiceImpl implements IEfcodeCpPlanService {
/** /**
* 计划日期筛选:1=本月 2=本季 3=本年;dateSearch=YYYY-MM 为自定义月份 * 计划日期筛选:1=本月 2=本季 3=本年;dateSearch=YYYY-MM 为自定义月份
* <p>用 Java 算区间再 ge/le,避免 apply+DATE_FORMAT 在部分环境下不生效。</p>
*/ */
private void applyPlanDateFilter(LambdaQueryWrapper<EfcodeCpPlan> lqw, Integer dateType, String dateSearch) { private void applyPlanDateFilter(LambdaQueryWrapper<EfcodeCpPlan> lqw, Integer dateType, String dateSearch) {
LocalDate today = LocalDate.now();
LocalDate start = null;
LocalDate end = null;
if (dateType != null) { if (dateType != null) {
if (dateType == 1) { if (dateType == 1) {
lqw.apply("DATE_FORMAT(plan_date, '%Y-%m') = DATE_FORMAT(CURDATE(), '%Y-%m')"); start = today.withDayOfMonth(1);
end = today.withDayOfMonth(today.lengthOfMonth());
} else if (dateType == 2) { } else if (dateType == 2) {
lqw.apply("DATE_FORMAT(plan_date, '%Y-%m') >= CONCAT(YEAR(CURDATE()), '-', " + int firstMonth = ((today.getMonthValue() - 1) / 3) * 3 + 1;
"CASE WHEN QUARTER(CURDATE()) IN (1) THEN '01' " + start = LocalDate.of(today.getYear(), firstMonth, 1);
"WHEN QUARTER(CURDATE()) IN (2) THEN '04' " + end = start.plusMonths(3).minusDays(1);
"WHEN QUARTER(CURDATE()) IN (3) THEN '07' " +
"ELSE '10' END) " +
"and DATE_FORMAT(plan_date, '%Y-%m') <= CONCAT(YEAR(CURDATE()), '-', " +
"CASE " +
"WHEN QUARTER(CURDATE()) IN (1) THEN '03' " +
"WHEN QUARTER(CURDATE()) IN (2) THEN '06' " +
"WHEN QUARTER(CURDATE()) IN (3) THEN '09' " +
"ELSE '12' " +
"END)");
} else if (dateType == 3) { } else if (dateType == 3) {
lqw.apply("DATE_FORMAT(plan_date, '%Y') = DATE_FORMAT(CURDATE(), '%Y')"); start = LocalDate.of(today.getYear(), 1, 1);
end = LocalDate.of(today.getYear(), 12, 31);
} }
} }
if (StringUtils.isNotBlank(dateSearch)) { if (StringUtils.isNotBlank(dateSearch) && dateSearch.matches("\\d{4}-\\d{2}")) {
lqw.apply("DATE_FORMAT(plan_date, '%Y-%m') = {0}", dateSearch); String[] parts = dateSearch.split("-");
int year = Integer.parseInt(parts[0]);
int month = Integer.parseInt(parts[1]);
start = LocalDate.of(year, month, 1);
end = start.withDayOfMonth(start.lengthOfMonth());
}
if (start != null && end != null) {
lqw.ge(EfcodeCpPlan::getPlanDate, java.sql.Date.valueOf(start));
lqw.le(EfcodeCpPlan::getPlanDate, java.sql.Date.valueOf(end));
log.info("[计划筛选] dateType={}, dateSearch={}, range={} ~ {}", dateType, dateSearch, start, end);
} }
} }

48
zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/service/impl/OutEfcodeCpPlanServiceImpl.java

@ -324,6 +324,16 @@ public class OutEfcodeCpPlanServiceImpl implements IOutEfcodeCpPlanService {
lqw.eq(StringUtils.isNotBlank(bo.getChannelNo()), EfcodeCpPlan::getChannelNo, bo.getChannelNo()); lqw.eq(StringUtils.isNotBlank(bo.getChannelNo()), EfcodeCpPlan::getChannelNo, bo.getChannelNo());
lqw.eq(StringUtils.isNotBlank(bo.getOutSerialNo()), EfcodeCpPlan::getOutSerialNo, bo.getOutSerialNo()); lqw.eq(StringUtils.isNotBlank(bo.getOutSerialNo()), EfcodeCpPlan::getOutSerialNo, bo.getOutSerialNo());
lqw.eq(StringUtils.isNotBlank(bo.getTaskId()), EfcodeCpPlan::getTaskId, bo.getTaskId()); lqw.eq(StringUtils.isNotBlank(bo.getTaskId()), EfcodeCpPlan::getTaskId, bo.getTaskId());
// 关键字:企业名称 / 执法事项 / 执法单位 / 执法人员
if (StringUtils.isNotBlank(bo.getSearchValue())) {
String sv = bo.getSearchValue();
lqw.and(w -> w
.like(EfcodeCpPlan::getEnterpriseName, sv)
.or().like(EfcodeCpPlan::getEnforceContent, sv)
.or().like(EfcodeCpPlan::getBureauDeptName, sv)
.or().like(EfcodeCpPlan::getEnforceUserNames, sv)
);
}
// 本月/本季/本年/自定义月份(按 plan_date) // 本月/本季/本年/自定义月份(按 plan_date)
applyPlanDateFilter(lqw, bo.getDateType(), bo.getDateSearch()); applyPlanDateFilter(lqw, bo.getDateType(), bo.getDateSearch());
return lqw; return lqw;
@ -331,30 +341,36 @@ public class OutEfcodeCpPlanServiceImpl implements IOutEfcodeCpPlanService {
/** /**
* 计划日期筛选:1=本月 2=本季 3=本年;dateSearch=YYYY-MM 为自定义月份 * 计划日期筛选:1=本月 2=本季 3=本年;dateSearch=YYYY-MM 为自定义月份
* <p>用 Java 算区间再 ge/le,避免 apply+DATE_FORMAT 在部分环境下不生效。</p>
*/ */
private void applyPlanDateFilter(LambdaQueryWrapper<EfcodeCpPlan> lqw, Integer dateType, String dateSearch) { private void applyPlanDateFilter(LambdaQueryWrapper<EfcodeCpPlan> lqw, Integer dateType, String dateSearch) {
LocalDate today = LocalDate.now();
LocalDate start = null;
LocalDate end = null;
if (dateType != null) { if (dateType != null) {
if (dateType == 1) { if (dateType == 1) {
lqw.apply("DATE_FORMAT(plan_date, '%Y-%m') = DATE_FORMAT(CURDATE(), '%Y-%m')"); start = today.withDayOfMonth(1);
end = today.withDayOfMonth(today.lengthOfMonth());
} else if (dateType == 2) { } else if (dateType == 2) {
lqw.apply("DATE_FORMAT(plan_date, '%Y-%m') >= CONCAT(YEAR(CURDATE()), '-', " + int firstMonth = ((today.getMonthValue() - 1) / 3) * 3 + 1;
"CASE WHEN QUARTER(CURDATE()) IN (1) THEN '01' " + start = LocalDate.of(today.getYear(), firstMonth, 1);
"WHEN QUARTER(CURDATE()) IN (2) THEN '04' " + end = start.plusMonths(3).minusDays(1);
"WHEN QUARTER(CURDATE()) IN (3) THEN '07' " +
"ELSE '10' END) " +
"and DATE_FORMAT(plan_date, '%Y-%m') <= CONCAT(YEAR(CURDATE()), '-', " +
"CASE " +
"WHEN QUARTER(CURDATE()) IN (1) THEN '03' " +
"WHEN QUARTER(CURDATE()) IN (2) THEN '06' " +
"WHEN QUARTER(CURDATE()) IN (3) THEN '09' " +
"ELSE '12' " +
"END)");
} else if (dateType == 3) { } else if (dateType == 3) {
lqw.apply("DATE_FORMAT(plan_date, '%Y') = DATE_FORMAT(CURDATE(), '%Y')"); start = LocalDate.of(today.getYear(), 1, 1);
end = LocalDate.of(today.getYear(), 12, 31);
} }
} }
if (StringUtils.isNotBlank(dateSearch)) { if (StringUtils.isNotBlank(dateSearch) && dateSearch.matches("\\d{4}-\\d{2}")) {
lqw.apply("DATE_FORMAT(plan_date, '%Y-%m') = {0}", dateSearch); String[] parts = dateSearch.split("-");
int year = Integer.parseInt(parts[0]);
int month = Integer.parseInt(parts[1]);
start = LocalDate.of(year, month, 1);
end = start.withDayOfMonth(start.lengthOfMonth());
}
if (start != null && end != null) {
lqw.ge(EfcodeCpPlan::getPlanDate, java.sql.Date.valueOf(start));
lqw.le(EfcodeCpPlan::getPlanDate, java.sql.Date.valueOf(end));
log.info("[计划筛选] dateType={}, dateSearch={}, range={} ~ {}", dateType, dateSearch, start, end);
} }
} }

39
zdxt-modules/zdxt-enforcement-code/src/main/resources/mapper/enforcementcode/EfcodeCpPlanMapper.xml

@ -71,6 +71,14 @@
<if test="bo.dateSearch != null and bo.dateSearch != ''"> <if test="bo.dateSearch != null and bo.dateSearch != ''">
AND DATE_FORMAT(plan_date, '%Y-%m') = #{bo.dateSearch} AND DATE_FORMAT(plan_date, '%Y-%m') = #{bo.dateSearch}
</if> </if>
<if test="bo.searchValue != null and bo.searchValue != ''">
AND (
enterprise_name LIKE CONCAT('%', #{bo.searchValue}, '%')
OR enforce_content LIKE CONCAT('%', #{bo.searchValue}, '%')
OR bureau_dept_name LIKE CONCAT('%', #{bo.searchValue}, '%')
OR enforce_user_names LIKE CONCAT('%', #{bo.searchValue}, '%')
)
</if>
<if test="bo.enterpriseName != null and bo.enterpriseName != ''"> <if test="bo.enterpriseName != null and bo.enterpriseName != ''">
AND enterprise_name LIKE CONCAT('%', #{bo.enterpriseName}, '%') AND enterprise_name LIKE CONCAT('%', #{bo.enterpriseName}, '%')
</if> </if>
@ -129,6 +137,37 @@
<if test="bo.planDate != null"> <if test="bo.planDate != null">
AND cp.plan_date = #{bo.planDate} AND cp.plan_date = #{bo.planDate}
</if> </if>
<!-- 本月/本季/本年 -->
<if test="bo.dateType != null and bo.dateType == 1">
AND DATE_FORMAT(cp.plan_date, '%Y-%m') = DATE_FORMAT(CURDATE(), '%Y-%m')
</if>
<if test="bo.dateType != null and bo.dateType == 2">
AND DATE_FORMAT(cp.plan_date, '%Y-%m') &gt;= CONCAT(YEAR(CURDATE()), '-',
CASE WHEN QUARTER(CURDATE()) IN (1) THEN '01'
WHEN QUARTER(CURDATE()) IN (2) THEN '04'
WHEN QUARTER(CURDATE()) IN (3) THEN '07'
ELSE '10' END)
AND DATE_FORMAT(cp.plan_date, '%Y-%m') &lt;= CONCAT(YEAR(CURDATE()), '-',
CASE WHEN QUARTER(CURDATE()) IN (1) THEN '03'
WHEN QUARTER(CURDATE()) IN (2) THEN '06'
WHEN QUARTER(CURDATE()) IN (3) THEN '09'
ELSE '12' END)
</if>
<if test="bo.dateType != null and bo.dateType == 3">
AND DATE_FORMAT(cp.plan_date, '%Y') = DATE_FORMAT(CURDATE(), '%Y')
</if>
<!-- 自定义月份 YYYY-MM -->
<if test="bo.dateSearch != null and bo.dateSearch != ''">
AND DATE_FORMAT(cp.plan_date, '%Y-%m') = #{bo.dateSearch}
</if>
<if test="bo.searchValue != null and bo.searchValue != ''">
AND (
cp.enterprise_name LIKE CONCAT('%', #{bo.searchValue}, '%')
OR cp.enforce_content LIKE CONCAT('%', #{bo.searchValue}, '%')
OR cp.bureau_dept_name LIKE CONCAT('%', #{bo.searchValue}, '%')
OR cp.enforce_user_names LIKE CONCAT('%', #{bo.searchValue}, '%')
)
</if>
<if test="bo.enterpriseId != null and bo.enterpriseId != ''"> <if test="bo.enterpriseId != null and bo.enterpriseId != ''">
AND cp.enterprise_id = #{bo.enterpriseId} AND cp.enterprise_id = #{bo.enterpriseId}
</if> </if>

3
zdxt-web-client/zdxt-efcode-enforcement-app/src/api/enforcement/plan.js

@ -7,6 +7,9 @@ const planBaseUrl = "/app-enf/cpPlan";
// 计划列表(分页) // 计划列表(分页)
export const getPlanList = (params, success, error) => _get(planBaseUrl + "/list", params, success, error); export const getPlanList = (params, success, error) => _get(planBaseUrl + "/list", params, success, error);
// 我的计划列表(分页,带日期/关键字筛选;plan/mine 专用)
export const getMyPlanList = (params, success, error) => _get(planBaseUrl + "/myPageList", params, success, error);
// 其他计划列表(分页,本单位+其他单位公开,仅待预约) // 其他计划列表(分页,本单位+其他单位公开,仅待预约)
export const getOtherPlanList = (params, success, error) => _get(planBaseUrl + "/otherList", params, success, error); export const getOtherPlanList = (params, success, error) => _get(planBaseUrl + "/otherList", params, success, error);

7
zdxt-web-client/zdxt-efcode-enforcement-app/src/components/common/SearchFilterBar.vue

@ -101,10 +101,12 @@ const onClear = () => {
}; };
const searchDateType = (val) => { const searchDateType = (val) => {
// 切换日期时一并带上当前输入框关键字,避免只改筛选项时父组件 searchText 仍是空
emit('dateChange', { emit('dateChange', {
dateType: val, dateType: val,
dateSearch: null, dateSearch: null,
dateShow: false dateShow: false,
searchValue: searchText.value
}); });
}; };
@ -120,7 +122,8 @@ const onDateConfirm = (value) => {
emit('dateChange', { emit('dateChange', {
dateType: 9, dateType: 9,
dateSearch: year + '-' + month, dateSearch: year + '-' + month,
dateShow: true dateShow: true,
searchValue: searchText.value
}); });
}; };
</script> </script>

9
zdxt-web-client/zdxt-efcode-enforcement-app/src/views/enforcement/my/plan/cp_plan_mine.vue

@ -158,7 +158,7 @@
import { ref, onMounted } from 'vue'; import { ref, onMounted } from 'vue';
import { showConfirmDialog, showToast } from 'vant'; import { showConfirmDialog, showToast } from 'vant';
import { useRouter } from 'vue-router'; import { useRouter } from 'vue-router';
import { getPlanList, deletePlan } from '@/api/enforcement/plan'; import { getMyPlanList, deletePlan } from '@/api/enforcement/plan';
import SearchFilterBar from '@/components/common/SearchFilterBar.vue'; import SearchFilterBar from '@/components/common/SearchFilterBar.vue';
const router = useRouter(); const router = useRouter();
@ -196,9 +196,12 @@ const onClear = () => {
doSearch(); doSearch();
}; };
const onDateChange = ({ dateType: dt, dateSearch: ds }) => { const onDateChange = ({ dateType: dt, dateSearch: ds, searchValue } = {}) => {
dateType.value = dt; dateType.value = dt;
dateSearch.value = ds; dateSearch.value = ds;
if (searchValue !== undefined) {
searchText.value = searchValue;
}
doSearch(); doSearch();
}; };
@ -304,7 +307,7 @@ const fetchList = () => {
if (filterStatus.value) { if (filterStatus.value) {
params['params[reserveStatusList]'] = filterStatus.value; params['params[reserveStatusList]'] = filterStatus.value;
} }
getPlanList( getMyPlanList(
params, params,
(res) => { (res) => {
refreshing.value = false; refreshing.value = false;

5
zdxt-web-client/zdxt-efcode-enforcement-app/src/views/enforcement/my/plan/cp_plan_other.vue

@ -121,9 +121,12 @@ const onClear = () => {
doSearch(); doSearch();
}; };
const onDateChange = (params) => { const onDateChange = (params = {}) => {
dateType.value = params.dateType; dateType.value = params.dateType;
dateSearch.value = params.dateSearch; dateSearch.value = params.dateSearch;
if (params.searchValue !== undefined) {
searchText.value = params.searchValue;
}
doSearch(); doSearch();
}; };

16
zdxt-web-client/zdxt-efcode-enterprise-app/src/views/enterprise/plan/planNoticeList.vue

@ -37,6 +37,7 @@
<div class="card-row time-row"> <div class="card-row time-row">
<span class="label">执法时间:</span> <span class="label">执法时间:</span>
<span class="value">{{ item.enforceDate }}</span> <span class="value">{{ item.enforceDate }}</span>
<span v-if="Number(item.status) === 3" class="history-tag">历史</span>
</div> </div>
<div class="card-row"> <div class="card-row">
<span class="label">执法单位:</span> <span class="label">执法单位:</span>
@ -238,9 +239,24 @@ const toDetail = (item) => {
} }
.time-row { .time-row {
display: flex;
align-items: center;
flex-wrap: wrap;
gap: 0.12rem;
margin-bottom: 0.15rem; margin-bottom: 0.15rem;
} }
.history-tag {
flex-shrink: 0;
font-size: 0.24rem;
color: #8c8c8c;
background: #f5f5f5;
border: 1px solid #d9d9d9;
border-radius: 0.06rem;
padding: 0.02rem 0.1rem;
line-height: 1.2;
}
.card-title { .card-title {
font-size: 0.42rem; font-size: 0.42rem;
font-weight: bold; font-weight: bold;

Loading…
Cancel
Save