Commit 4897dc13a793eb91ec569ec6ee34da6b8848b92e
1 parent
56ffd313
数据统计
Showing
53 changed files
with
4669 additions
and
0 deletions
Too many changes to show.
To preserve performance only 53 of 57 files are displayed.
pom.xml
| @@ -217,6 +217,7 @@ | @@ -217,6 +217,7 @@ | ||
| 217 | <module>trash-common</module> | 217 | <module>trash-common</module> |
| 218 | <module>trash-activiti</module> | 218 | <module>trash-activiti</module> |
| 219 | <module>trash-workflow</module> | 219 | <module>trash-workflow</module> |
| 220 | + <module>trash-daily</module> | ||
| 220 | </modules> | 221 | </modules> |
| 221 | <packaging>pom</packaging> | 222 | <packaging>pom</packaging> |
| 222 | 223 |
trash-daily/pom.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | +<project xmlns="http://maven.apache.org/POM/4.0.0" | ||
| 3 | + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
| 4 | + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
| 5 | + <parent> | ||
| 6 | + <artifactId>trash</artifactId> | ||
| 7 | + <groupId>com.trash</groupId> | ||
| 8 | + <version>3.2.0</version> | ||
| 9 | + </parent> | ||
| 10 | + <modelVersion>4.0.0</modelVersion> | ||
| 11 | + | ||
| 12 | + <artifactId>trash-daily</artifactId> | ||
| 13 | + | ||
| 14 | + <dependencies> | ||
| 15 | + <dependency> | ||
| 16 | + <groupId>com.trash</groupId> | ||
| 17 | + <artifactId>trash-activiti</artifactId> | ||
| 18 | + </dependency> | ||
| 19 | + </dependencies> | ||
| 20 | + | ||
| 21 | +</project> | ||
| 0 | \ No newline at end of file | 22 | \ No newline at end of file |
trash-daily/src/main/java/com/trash/daily/controller/DailyController.java
0 → 100644
| 1 | +package com.trash.daily.controller; | ||
| 2 | + | ||
| 3 | +import com.trash.common.annotation.Log; | ||
| 4 | +import com.trash.common.core.controller.BaseController; | ||
| 5 | +import com.trash.common.core.domain.AjaxResult; | ||
| 6 | +import com.trash.common.core.page.TableDataInfo; | ||
| 7 | +import com.trash.common.enums.BusinessType; | ||
| 8 | +import com.trash.common.utils.poi.ExcelUtil; | ||
| 9 | +import com.trash.daily.domain.PeriodicReport; | ||
| 10 | +import com.trash.daily.service.IDailyService; | ||
| 11 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 12 | +import org.springframework.security.access.prepost.PreAuthorize; | ||
| 13 | +import org.springframework.web.bind.annotation.*; | ||
| 14 | + | ||
| 15 | +import java.util.List; | ||
| 16 | + | ||
| 17 | +/** | ||
| 18 | + * 日报Controller | ||
| 19 | + * | ||
| 20 | + * @author trash | ||
| 21 | + * @date 2023-04-21 | ||
| 22 | + */ | ||
| 23 | +@RestController | ||
| 24 | +@RequestMapping("/report/daily") | ||
| 25 | +public class DailyController extends BaseController | ||
| 26 | +{ | ||
| 27 | + @Autowired | ||
| 28 | + private IDailyService dailyService; | ||
| 29 | + | ||
| 30 | + /** | ||
| 31 | + * 查询日报列表 | ||
| 32 | + */ | ||
| 33 | + @PreAuthorize("@ss.hasPermi('report:daily:list')") | ||
| 34 | + @GetMapping("/list") | ||
| 35 | + public TableDataInfo list(PeriodicReport daily) | ||
| 36 | + { | ||
| 37 | + startPage(); | ||
| 38 | + List<PeriodicReport> list = dailyService.selectDailyList(daily); | ||
| 39 | + return getDataTable(list); | ||
| 40 | + } | ||
| 41 | + | ||
| 42 | + /** | ||
| 43 | + * 导出日报列表 | ||
| 44 | + */ | ||
| 45 | + @PreAuthorize("@ss.hasPermi('report:daily:export')") | ||
| 46 | + @Log(title = "日报", businessType = BusinessType.EXPORT) | ||
| 47 | + @GetMapping("/export") | ||
| 48 | + public AjaxResult export(PeriodicReport daily) | ||
| 49 | + { | ||
| 50 | + List<PeriodicReport> list = dailyService.selectDailyList(daily); | ||
| 51 | + ExcelUtil<PeriodicReport> util = new ExcelUtil<PeriodicReport>(PeriodicReport.class); | ||
| 52 | + return util.exportExcel(list, "daily"); | ||
| 53 | + } | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 获取日报详细信息 | ||
| 57 | + */ | ||
| 58 | + @PreAuthorize("@ss.hasPermi('report:daily:query')") | ||
| 59 | + @GetMapping(value = "/{id}") | ||
| 60 | + public AjaxResult getInfo(@PathVariable("id") Long id) | ||
| 61 | + { | ||
| 62 | + return AjaxResult.success(dailyService.selectDailyById(id)); | ||
| 63 | + } | ||
| 64 | + | ||
| 65 | + /** | ||
| 66 | + * 新增日报 | ||
| 67 | + */ | ||
| 68 | + @PreAuthorize("@ss.hasPermi('report:daily:add')") | ||
| 69 | + @Log(title = "日报", businessType = BusinessType.INSERT) | ||
| 70 | + @PostMapping | ||
| 71 | + public AjaxResult add(@RequestBody PeriodicReport daily) | ||
| 72 | + { | ||
| 73 | + return toAjax(dailyService.insertDaily(daily)); | ||
| 74 | + } | ||
| 75 | + | ||
| 76 | + /** | ||
| 77 | + * 修改日报 | ||
| 78 | + */ | ||
| 79 | + @PreAuthorize("@ss.hasPermi('report:daily:edit')") | ||
| 80 | + @Log(title = "日报", businessType = BusinessType.UPDATE) | ||
| 81 | + @PutMapping | ||
| 82 | + public AjaxResult edit(@RequestBody PeriodicReport daily) | ||
| 83 | + { | ||
| 84 | + return toAjax(dailyService.updateDaily(daily)); | ||
| 85 | + } | ||
| 86 | + | ||
| 87 | + /** | ||
| 88 | + * 删除日报 | ||
| 89 | + */ | ||
| 90 | + @PreAuthorize("@ss.hasPermi('report:daily:remove')") | ||
| 91 | + @Log(title = "日报", businessType = BusinessType.DELETE) | ||
| 92 | + @DeleteMapping("/{ids}") | ||
| 93 | + public AjaxResult remove(@PathVariable Long[] ids) | ||
| 94 | + { | ||
| 95 | + return toAjax(dailyService.deleteDailyByIds(ids)); | ||
| 96 | + } | ||
| 97 | +} |
trash-daily/src/main/java/com/trash/daily/domain/PeriodicReport.java
0 → 100644
| 1 | +package com.trash.daily.domain; | ||
| 2 | + | ||
| 3 | +import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 4 | +import com.trash.common.annotation.Excel; | ||
| 5 | +import com.trash.common.core.domain.BaseEntity; | ||
| 6 | +import org.apache.commons.lang3.builder.ToStringBuilder; | ||
| 7 | +import org.apache.commons.lang3.builder.ToStringStyle; | ||
| 8 | + | ||
| 9 | +import java.util.Date; | ||
| 10 | + | ||
| 11 | +/** | ||
| 12 | + * 周期报告 PeriodicReport | ||
| 13 | + * | ||
| 14 | + * @author trash | ||
| 15 | + * @date 2023-04-21 | ||
| 16 | + */ | ||
| 17 | +public class PeriodicReport extends BaseEntity | ||
| 18 | +{ | ||
| 19 | + private static final long serialVersionUID = 1L; | ||
| 20 | + | ||
| 21 | + /** 主键id */ | ||
| 22 | + private Long id; | ||
| 23 | + | ||
| 24 | + /** 标题 */ | ||
| 25 | + @Excel(name = "标题") | ||
| 26 | + private String headline; | ||
| 27 | + | ||
| 28 | + /** 填写人 */ | ||
| 29 | + @Excel(name = "填写人") | ||
| 30 | + private String writer; | ||
| 31 | + | ||
| 32 | + /** 填写时间 */ | ||
| 33 | + @JsonFormat(pattern = "yyyy-MM-dd") | ||
| 34 | + @Excel(name = "填写时间", width = 30, dateFormat = "yyyy-MM-dd") | ||
| 35 | + private Date writeTime; | ||
| 36 | + | ||
| 37 | + /** 内容 */ | ||
| 38 | + private String content; | ||
| 39 | + | ||
| 40 | + /** 开始时间 */ | ||
| 41 | + private Date begintime; | ||
| 42 | + | ||
| 43 | + /** 结束时间 */ | ||
| 44 | + private Date endtime; | ||
| 45 | + | ||
| 46 | + /** 周报类型(1、日报2、周报3、月报) */ | ||
| 47 | + private Long contentType; | ||
| 48 | + | ||
| 49 | + public void setId(Long id) | ||
| 50 | + { | ||
| 51 | + this.id = id; | ||
| 52 | + } | ||
| 53 | + | ||
| 54 | + public Long getId() | ||
| 55 | + { | ||
| 56 | + return id; | ||
| 57 | + } | ||
| 58 | + public void setHeadline(String headline) | ||
| 59 | + { | ||
| 60 | + this.headline = headline; | ||
| 61 | + } | ||
| 62 | + | ||
| 63 | + public String getHeadline() | ||
| 64 | + { | ||
| 65 | + return headline; | ||
| 66 | + } | ||
| 67 | + public void setWriter(String writer) | ||
| 68 | + { | ||
| 69 | + this.writer = writer; | ||
| 70 | + } | ||
| 71 | + | ||
| 72 | + public String getWriter() | ||
| 73 | + { | ||
| 74 | + return writer; | ||
| 75 | + } | ||
| 76 | + public void setWriteTime(Date writeTime) | ||
| 77 | + { | ||
| 78 | + this.writeTime = writeTime; | ||
| 79 | + } | ||
| 80 | + | ||
| 81 | + public Date getWriteTime() | ||
| 82 | + { | ||
| 83 | + return writeTime; | ||
| 84 | + } | ||
| 85 | + public void setContent(String content) | ||
| 86 | + { | ||
| 87 | + this.content = content; | ||
| 88 | + } | ||
| 89 | + | ||
| 90 | + public String getContent() | ||
| 91 | + { | ||
| 92 | + return content; | ||
| 93 | + } | ||
| 94 | + public void setBegintime(Date begintime) | ||
| 95 | + { | ||
| 96 | + this.begintime = begintime; | ||
| 97 | + } | ||
| 98 | + | ||
| 99 | + public Date getBegintime() | ||
| 100 | + { | ||
| 101 | + return begintime; | ||
| 102 | + } | ||
| 103 | + public void setEndtime(Date endtime) | ||
| 104 | + { | ||
| 105 | + this.endtime = endtime; | ||
| 106 | + } | ||
| 107 | + | ||
| 108 | + public Date getEndtime() | ||
| 109 | + { | ||
| 110 | + return endtime; | ||
| 111 | + } | ||
| 112 | + public void setContentType(Long contentType) | ||
| 113 | + { | ||
| 114 | + this.contentType = contentType; | ||
| 115 | + } | ||
| 116 | + | ||
| 117 | + public Long getContentType() | ||
| 118 | + { | ||
| 119 | + return contentType; | ||
| 120 | + } | ||
| 121 | + | ||
| 122 | + @Override | ||
| 123 | + public String toString() { | ||
| 124 | + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) | ||
| 125 | + .append("id", getId()) | ||
| 126 | + .append("headline", getHeadline()) | ||
| 127 | + .append("writer", getWriter()) | ||
| 128 | + .append("writeTime", getWriteTime()) | ||
| 129 | + .append("content", getContent()) | ||
| 130 | + .append("begintime", getBegintime()) | ||
| 131 | + .append("endtime", getEndtime()) | ||
| 132 | + .append("contentType", getContentType()) | ||
| 133 | + .toString(); | ||
| 134 | + } | ||
| 135 | +} | ||
| 0 | \ No newline at end of file | 136 | \ No newline at end of file |
trash-daily/src/main/java/com/trash/daily/mapper/DailyMapper.java
0 → 100644
| 1 | +package com.trash.daily.mapper; | ||
| 2 | + | ||
| 3 | +import com.trash.daily.domain.PeriodicReport; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 日报Mapper接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-21 | ||
| 12 | + */ | ||
| 13 | +public interface DailyMapper | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询日报 | ||
| 17 | + * | ||
| 18 | + * @param id 日报ID | ||
| 19 | + * @return 日报 | ||
| 20 | + */ | ||
| 21 | + public PeriodicReport selectDailyById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询日报列表 | ||
| 25 | + * | ||
| 26 | + * @param periodicReport 日报 | ||
| 27 | + * @return 日报集合 | ||
| 28 | + */ | ||
| 29 | + public List<PeriodicReport> selectDailyList(PeriodicReport periodicReport); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增日报 | ||
| 33 | + * | ||
| 34 | + * @param periodicReport 日报 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertDaily(PeriodicReport periodicReport); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改日报 | ||
| 41 | + * | ||
| 42 | + * @param periodicReport 日报 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateDaily(PeriodicReport periodicReport); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 删除日报 | ||
| 49 | + * | ||
| 50 | + * @param id 日报ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteDailyById(Long id); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 批量删除日报 | ||
| 57 | + * | ||
| 58 | + * @param ids 需要删除的数据ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteDailyByIds(Long[] ids); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/daily/service/IDailyService.java
0 → 100644
| 1 | +package com.trash.daily.service; | ||
| 2 | + | ||
| 3 | +import com.trash.daily.domain.PeriodicReport; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 日报Service接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-21 | ||
| 12 | + */ | ||
| 13 | +public interface IDailyService | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询日报 | ||
| 17 | + * | ||
| 18 | + * @param id 日报ID | ||
| 19 | + * @return 日报 | ||
| 20 | + */ | ||
| 21 | + public PeriodicReport selectDailyById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询日报列表 | ||
| 25 | + * | ||
| 26 | + * @param periodicReport 日报 | ||
| 27 | + * @return 日报集合 | ||
| 28 | + */ | ||
| 29 | + public List<PeriodicReport> selectDailyList(PeriodicReport periodicReport); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增日报 | ||
| 33 | + * | ||
| 34 | + * @param periodicReport 日报 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertDaily(PeriodicReport periodicReport); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改日报 | ||
| 41 | + * | ||
| 42 | + * @param periodicReport 日报 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateDaily(PeriodicReport periodicReport); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 删除日报 | ||
| 49 | + * | ||
| 50 | + * @param id 日报ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteDailyById(Long id); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 批量删除日报 | ||
| 57 | + * | ||
| 58 | + * @param ids 需要删除的数据ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteDailyByIds(Long[] ids); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/daily/service/impl/DailyServiceImpl.java
0 → 100644
| 1 | +package com.trash.daily.service.impl; | ||
| 2 | + | ||
| 3 | +import com.trash.daily.domain.PeriodicReport; | ||
| 4 | +import com.trash.daily.mapper.DailyMapper; | ||
| 5 | +import com.trash.daily.service.IDailyService; | ||
| 6 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 7 | +import org.springframework.stereotype.Service; | ||
| 8 | + | ||
| 9 | +import java.util.List; | ||
| 10 | + | ||
| 11 | +/** | ||
| 12 | + * 日报Service业务层处理 | ||
| 13 | + * | ||
| 14 | + * @author trash | ||
| 15 | + * @date 2023-04-21 | ||
| 16 | + */ | ||
| 17 | +@Service | ||
| 18 | +public class DailyServiceImpl implements IDailyService | ||
| 19 | +{ | ||
| 20 | + @Autowired | ||
| 21 | + private DailyMapper dailyMapper; | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询日报 | ||
| 25 | + * | ||
| 26 | + * @param id 日报ID | ||
| 27 | + * @return 日报 | ||
| 28 | + */ | ||
| 29 | + @Override | ||
| 30 | + public PeriodicReport selectDailyById(Long id) | ||
| 31 | + { | ||
| 32 | + return dailyMapper.selectDailyById(id); | ||
| 33 | + } | ||
| 34 | + | ||
| 35 | + /** | ||
| 36 | + * 查询日报列表 | ||
| 37 | + * | ||
| 38 | + * @param daily 日报 | ||
| 39 | + * @return 日报 | ||
| 40 | + */ | ||
| 41 | + @Override | ||
| 42 | + public List<PeriodicReport> selectDailyList(PeriodicReport daily) | ||
| 43 | + { | ||
| 44 | + return dailyMapper.selectDailyList(daily); | ||
| 45 | + } | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 新增日报 | ||
| 49 | + * | ||
| 50 | + * @param daily 日报 | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + @Override | ||
| 54 | + public int insertDaily(PeriodicReport daily) | ||
| 55 | + { | ||
| 56 | + return dailyMapper.insertDaily(daily); | ||
| 57 | + } | ||
| 58 | + | ||
| 59 | + /** | ||
| 60 | + * 修改日报 | ||
| 61 | + * | ||
| 62 | + * @param daily 日报 | ||
| 63 | + * @return 结果 | ||
| 64 | + */ | ||
| 65 | + @Override | ||
| 66 | + public int updateDaily(PeriodicReport daily) | ||
| 67 | + { | ||
| 68 | + return dailyMapper.updateDaily(daily); | ||
| 69 | + } | ||
| 70 | + | ||
| 71 | + /** | ||
| 72 | + * 批量删除日报 | ||
| 73 | + * | ||
| 74 | + * @param ids 需要删除的日报ID | ||
| 75 | + * @return 结果 | ||
| 76 | + */ | ||
| 77 | + @Override | ||
| 78 | + public int deleteDailyByIds(Long[] ids) | ||
| 79 | + { | ||
| 80 | + return dailyMapper.deleteDailyByIds(ids); | ||
| 81 | + } | ||
| 82 | + | ||
| 83 | + /** | ||
| 84 | + * 删除日报信息 | ||
| 85 | + * | ||
| 86 | + * @param id 日报ID | ||
| 87 | + * @return 结果 | ||
| 88 | + */ | ||
| 89 | + @Override | ||
| 90 | + public int deleteDailyById(Long id) | ||
| 91 | + { | ||
| 92 | + return dailyMapper.deleteDailyById(id); | ||
| 93 | + } | ||
| 94 | +} |
trash-daily/src/main/java/com/trash/information_sharing/controller/InformationSharingController.java
0 → 100644
| 1 | +package com.trash.information_sharing.controller; | ||
| 2 | + | ||
| 3 | +import com.trash.common.annotation.Log; | ||
| 4 | +import com.trash.common.core.controller.BaseController; | ||
| 5 | +import com.trash.common.core.domain.AjaxResult; | ||
| 6 | +import com.trash.common.core.page.TableDataInfo; | ||
| 7 | +import com.trash.common.enums.BusinessType; | ||
| 8 | +import com.trash.common.utils.poi.ExcelUtil; | ||
| 9 | +import com.trash.information_sharing.domain.InformationSharing; | ||
| 10 | +import com.trash.information_sharing.service.IInformationSharingService; | ||
| 11 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 12 | +import org.springframework.security.access.prepost.PreAuthorize; | ||
| 13 | +import org.springframework.web.bind.annotation.*; | ||
| 14 | + | ||
| 15 | +import java.util.List; | ||
| 16 | + | ||
| 17 | +/** | ||
| 18 | + * 信息共享Controller | ||
| 19 | + * | ||
| 20 | + * @author trash | ||
| 21 | + * @date 2023-04-20 | ||
| 22 | + */ | ||
| 23 | +@RestController | ||
| 24 | +@RequestMapping("/daily/information_sharing") | ||
| 25 | +public class InformationSharingController extends BaseController | ||
| 26 | +{ | ||
| 27 | + @Autowired | ||
| 28 | + private IInformationSharingService informationSharingService; | ||
| 29 | + | ||
| 30 | + /** | ||
| 31 | + * 查询信息共享列表 | ||
| 32 | + */ | ||
| 33 | + @PreAuthorize("@ss.hasPermi('daily:information_sharing:list')") | ||
| 34 | + @GetMapping("/list") | ||
| 35 | + public TableDataInfo list(InformationSharing informationSharing) | ||
| 36 | + { | ||
| 37 | + startPage(); | ||
| 38 | + List<InformationSharing> list = informationSharingService.selectInformationSharingList(informationSharing); | ||
| 39 | + return getDataTable(list); | ||
| 40 | + } | ||
| 41 | + | ||
| 42 | + /** | ||
| 43 | + * 导出信息共享列表 | ||
| 44 | + */ | ||
| 45 | + @PreAuthorize("@ss.hasPermi('daily:information_sharing:export')") | ||
| 46 | + @Log(title = "信息共享", businessType = BusinessType.EXPORT) | ||
| 47 | + @GetMapping("/export") | ||
| 48 | + public AjaxResult export(InformationSharing informationSharing) | ||
| 49 | + { | ||
| 50 | + List<InformationSharing> list = informationSharingService.selectInformationSharingList(informationSharing); | ||
| 51 | + ExcelUtil<InformationSharing> util = new ExcelUtil<InformationSharing>(InformationSharing.class); | ||
| 52 | + return util.exportExcel(list, "information_sharing"); | ||
| 53 | + } | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 获取信息共享详细信息 | ||
| 57 | + */ | ||
| 58 | + @PreAuthorize("@ss.hasPermi('daily:information_sharing:query')") | ||
| 59 | + @GetMapping(value = "/{id}") | ||
| 60 | + public AjaxResult getInfo(@PathVariable("id") Long id) | ||
| 61 | + { | ||
| 62 | + return AjaxResult.success(informationSharingService.selectInformationSharingById(id)); | ||
| 63 | + } | ||
| 64 | + | ||
| 65 | + /** | ||
| 66 | + * 新增信息共享 | ||
| 67 | + */ | ||
| 68 | + @PreAuthorize("@ss.hasPermi('daily:information_sharing:add')") | ||
| 69 | + @Log(title = "信息共享", businessType = BusinessType.INSERT) | ||
| 70 | + @PostMapping | ||
| 71 | + public AjaxResult add(@RequestBody InformationSharing informationSharing) | ||
| 72 | + { | ||
| 73 | + return toAjax(informationSharingService.insertInformationSharing(informationSharing)); | ||
| 74 | + } | ||
| 75 | + | ||
| 76 | + /** | ||
| 77 | + * 修改信息共享 | ||
| 78 | + */ | ||
| 79 | + @PreAuthorize("@ss.hasPermi('daily:information_sharing:edit')") | ||
| 80 | + @Log(title = "信息共享", businessType = BusinessType.UPDATE) | ||
| 81 | + @PutMapping | ||
| 82 | + public AjaxResult edit(@RequestBody InformationSharing informationSharing) | ||
| 83 | + { | ||
| 84 | + return toAjax(informationSharingService.updateInformationSharing(informationSharing)); | ||
| 85 | + } | ||
| 86 | + | ||
| 87 | + /** | ||
| 88 | + * 删除信息共享 | ||
| 89 | + */ | ||
| 90 | + @PreAuthorize("@ss.hasPermi('daily:information_sharing:remove')") | ||
| 91 | + @Log(title = "信息共享", businessType = BusinessType.DELETE) | ||
| 92 | + @DeleteMapping("/{ids}") | ||
| 93 | + public AjaxResult remove(@PathVariable Long[] ids) | ||
| 94 | + { | ||
| 95 | + return toAjax(informationSharingService.deleteInformationSharingByIds(ids)); | ||
| 96 | + } | ||
| 97 | +} |
trash-daily/src/main/java/com/trash/information_sharing/domain/InformationSharing.java
0 → 100644
| 1 | +package com.trash.information_sharing.domain; | ||
| 2 | + | ||
| 3 | +import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 4 | +import com.trash.common.annotation.Excel; | ||
| 5 | +import com.trash.common.core.domain.BaseEntity; | ||
| 6 | +import org.apache.commons.lang3.builder.ToStringBuilder; | ||
| 7 | +import org.apache.commons.lang3.builder.ToStringStyle; | ||
| 8 | + | ||
| 9 | +import java.util.Date; | ||
| 10 | + | ||
| 11 | +/** | ||
| 12 | + * 信息共享对象 information_sharing | ||
| 13 | + * | ||
| 14 | + * @author trash | ||
| 15 | + * @date 2023-04-20 | ||
| 16 | + */ | ||
| 17 | +public class InformationSharing extends BaseEntity | ||
| 18 | +{ | ||
| 19 | + private static final long serialVersionUID = 1L; | ||
| 20 | + | ||
| 21 | + /** 主键id */ | ||
| 22 | + private Long id; | ||
| 23 | + | ||
| 24 | + /** 数据标题 */ | ||
| 25 | + @Excel(name = "数据标题") | ||
| 26 | + private String dataHeader; | ||
| 27 | + | ||
| 28 | + /** 调取部门 */ | ||
| 29 | + @Excel(name = "调取部门") | ||
| 30 | + private String retrieveDepartment; | ||
| 31 | + | ||
| 32 | + /** 调取时间 */ | ||
| 33 | + @JsonFormat(pattern = "yyyy-MM-dd") | ||
| 34 | + @Excel(name = "调取时间", width = 30, dateFormat = "yyyy-MM-dd") | ||
| 35 | + private Date retrieveTime; | ||
| 36 | + | ||
| 37 | + /** 调取内容 */ | ||
| 38 | + private String retrieveContent; | ||
| 39 | + | ||
| 40 | + /** 附件 */ | ||
| 41 | + private String attachmentLink; | ||
| 42 | + | ||
| 43 | + /** 资料 */ | ||
| 44 | + private String informationLink; | ||
| 45 | + | ||
| 46 | + public void setId(Long id) | ||
| 47 | + { | ||
| 48 | + this.id = id; | ||
| 49 | + } | ||
| 50 | + | ||
| 51 | + public Long getId() | ||
| 52 | + { | ||
| 53 | + return id; | ||
| 54 | + } | ||
| 55 | + public void setDataHeader(String dataHeader) | ||
| 56 | + { | ||
| 57 | + this.dataHeader = dataHeader; | ||
| 58 | + } | ||
| 59 | + | ||
| 60 | + public String getDataHeader() | ||
| 61 | + { | ||
| 62 | + return dataHeader; | ||
| 63 | + } | ||
| 64 | + public void setRetrieveDepartment(String retrieveDepartment) | ||
| 65 | + { | ||
| 66 | + this.retrieveDepartment = retrieveDepartment; | ||
| 67 | + } | ||
| 68 | + | ||
| 69 | + public String getRetrieveDepartment() | ||
| 70 | + { | ||
| 71 | + return retrieveDepartment; | ||
| 72 | + } | ||
| 73 | + public void setRetrieveTime(Date retrieveTime) | ||
| 74 | + { | ||
| 75 | + this.retrieveTime = retrieveTime; | ||
| 76 | + } | ||
| 77 | + | ||
| 78 | + public Date getRetrieveTime() | ||
| 79 | + { | ||
| 80 | + return retrieveTime; | ||
| 81 | + } | ||
| 82 | + public void setRetrieveContent(String retrieveContent) | ||
| 83 | + { | ||
| 84 | + this.retrieveContent = retrieveContent; | ||
| 85 | + } | ||
| 86 | + | ||
| 87 | + public String getRetrieveContent() | ||
| 88 | + { | ||
| 89 | + return retrieveContent; | ||
| 90 | + } | ||
| 91 | + public void setAttachmentLink(String attachmentLink) | ||
| 92 | + { | ||
| 93 | + this.attachmentLink = attachmentLink; | ||
| 94 | + } | ||
| 95 | + | ||
| 96 | + public String getAttachmentLink() | ||
| 97 | + { | ||
| 98 | + return attachmentLink; | ||
| 99 | + } | ||
| 100 | + public void setInformationLink(String informationLink) | ||
| 101 | + { | ||
| 102 | + this.informationLink = informationLink; | ||
| 103 | + } | ||
| 104 | + | ||
| 105 | + public String getInformationLink() | ||
| 106 | + { | ||
| 107 | + return informationLink; | ||
| 108 | + } | ||
| 109 | + | ||
| 110 | + @Override | ||
| 111 | + public String toString() { | ||
| 112 | + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) | ||
| 113 | + .append("id", getId()) | ||
| 114 | + .append("dataHeader", getDataHeader()) | ||
| 115 | + .append("retrieveDepartment", getRetrieveDepartment()) | ||
| 116 | + .append("retrieveTime", getRetrieveTime()) | ||
| 117 | + .append("retrieveContent", getRetrieveContent()) | ||
| 118 | + .append("attachmentLink", getAttachmentLink()) | ||
| 119 | + .append("informationLink", getInformationLink()) | ||
| 120 | + .toString(); | ||
| 121 | + } | ||
| 122 | +} |
trash-daily/src/main/java/com/trash/information_sharing/mapper/InformationSharingMapper.java
0 → 100644
| 1 | +package com.trash.information_sharing.mapper; | ||
| 2 | + | ||
| 3 | +import com.trash.information_sharing.domain.InformationSharing; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 信息共享Mapper接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-20 | ||
| 12 | + */ | ||
| 13 | +public interface InformationSharingMapper | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询信息共享 | ||
| 17 | + * | ||
| 18 | + * @param id 信息共享ID | ||
| 19 | + * @return 信息共享 | ||
| 20 | + */ | ||
| 21 | + public InformationSharing selectInformationSharingById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询信息共享列表 | ||
| 25 | + * | ||
| 26 | + * @param informationSharing 信息共享 | ||
| 27 | + * @return 信息共享集合 | ||
| 28 | + */ | ||
| 29 | + public List<InformationSharing> selectInformationSharingList(InformationSharing informationSharing); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增信息共享 | ||
| 33 | + * | ||
| 34 | + * @param informationSharing 信息共享 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertInformationSharing(InformationSharing informationSharing); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改信息共享 | ||
| 41 | + * | ||
| 42 | + * @param informationSharing 信息共享 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateInformationSharing(InformationSharing informationSharing); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 删除信息共享 | ||
| 49 | + * | ||
| 50 | + * @param id 信息共享ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteInformationSharingById(Long id); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 批量删除信息共享 | ||
| 57 | + * | ||
| 58 | + * @param ids 需要删除的数据ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteInformationSharingByIds(Long[] ids); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/information_sharing/service/IInformationSharingService.java
0 → 100644
| 1 | +package com.trash.information_sharing.service; | ||
| 2 | + | ||
| 3 | +import com.trash.information_sharing.domain.InformationSharing; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 信息共享Service接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-20 | ||
| 12 | + */ | ||
| 13 | +public interface IInformationSharingService | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询信息共享 | ||
| 17 | + * | ||
| 18 | + * @param id 信息共享ID | ||
| 19 | + * @return 信息共享 | ||
| 20 | + */ | ||
| 21 | + public InformationSharing selectInformationSharingById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询信息共享列表 | ||
| 25 | + * | ||
| 26 | + * @param informationSharing 信息共享 | ||
| 27 | + * @return 信息共享集合 | ||
| 28 | + */ | ||
| 29 | + public List<InformationSharing> selectInformationSharingList(InformationSharing informationSharing); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增信息共享 | ||
| 33 | + * | ||
| 34 | + * @param informationSharing 信息共享 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertInformationSharing(InformationSharing informationSharing); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改信息共享 | ||
| 41 | + * | ||
| 42 | + * @param informationSharing 信息共享 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateInformationSharing(InformationSharing informationSharing); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 批量删除信息共享 | ||
| 49 | + * | ||
| 50 | + * @param ids 需要删除的信息共享ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteInformationSharingByIds(Long[] ids); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 删除信息共享信息 | ||
| 57 | + * | ||
| 58 | + * @param id 信息共享ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteInformationSharingById(Long id); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/information_sharing/service/impl/InformationSharingServiceImpl.java
0 → 100644
| 1 | +package com.trash.information_sharing.service.impl; | ||
| 2 | + | ||
| 3 | +import com.trash.information_sharing.domain.InformationSharing; | ||
| 4 | +import com.trash.information_sharing.mapper.InformationSharingMapper; | ||
| 5 | +import com.trash.information_sharing.service.IInformationSharingService; | ||
| 6 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 7 | +import org.springframework.stereotype.Service; | ||
| 8 | + | ||
| 9 | +import java.util.List; | ||
| 10 | + | ||
| 11 | +/** | ||
| 12 | + * 信息共享Service业务层处理 | ||
| 13 | + * | ||
| 14 | + * @author trash | ||
| 15 | + * @date 2023-04-20 | ||
| 16 | + */ | ||
| 17 | +@Service | ||
| 18 | +public class InformationSharingServiceImpl implements IInformationSharingService | ||
| 19 | +{ | ||
| 20 | + @Autowired | ||
| 21 | + private InformationSharingMapper informationSharingMapper; | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询信息共享 | ||
| 25 | + * | ||
| 26 | + * @param id 信息共享ID | ||
| 27 | + * @return 信息共享 | ||
| 28 | + */ | ||
| 29 | + @Override | ||
| 30 | + public InformationSharing selectInformationSharingById(Long id) | ||
| 31 | + { | ||
| 32 | + return informationSharingMapper.selectInformationSharingById(id); | ||
| 33 | + } | ||
| 34 | + | ||
| 35 | + /** | ||
| 36 | + * 查询信息共享列表 | ||
| 37 | + * | ||
| 38 | + * @param informationSharing 信息共享 | ||
| 39 | + * @return 信息共享 | ||
| 40 | + */ | ||
| 41 | + @Override | ||
| 42 | + public List<InformationSharing> selectInformationSharingList(InformationSharing informationSharing) | ||
| 43 | + { | ||
| 44 | + return informationSharingMapper.selectInformationSharingList(informationSharing); | ||
| 45 | + } | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 新增信息共享 | ||
| 49 | + * | ||
| 50 | + * @param informationSharing 信息共享 | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + @Override | ||
| 54 | + public int insertInformationSharing(InformationSharing informationSharing) | ||
| 55 | + { | ||
| 56 | + return informationSharingMapper.insertInformationSharing(informationSharing); | ||
| 57 | + } | ||
| 58 | + | ||
| 59 | + /** | ||
| 60 | + * 修改信息共享 | ||
| 61 | + * | ||
| 62 | + * @param informationSharing 信息共享 | ||
| 63 | + * @return 结果 | ||
| 64 | + */ | ||
| 65 | + @Override | ||
| 66 | + public int updateInformationSharing(InformationSharing informationSharing) | ||
| 67 | + { | ||
| 68 | + return informationSharingMapper.updateInformationSharing(informationSharing); | ||
| 69 | + } | ||
| 70 | + | ||
| 71 | + /** | ||
| 72 | + * 批量删除信息共享 | ||
| 73 | + * | ||
| 74 | + * @param ids 需要删除的信息共享ID | ||
| 75 | + * @return 结果 | ||
| 76 | + */ | ||
| 77 | + @Override | ||
| 78 | + public int deleteInformationSharingByIds(Long[] ids) | ||
| 79 | + { | ||
| 80 | + return informationSharingMapper.deleteInformationSharingByIds(ids); | ||
| 81 | + } | ||
| 82 | + | ||
| 83 | + /** | ||
| 84 | + * 删除信息共享信息 | ||
| 85 | + * | ||
| 86 | + * @param id 信息共享ID | ||
| 87 | + * @return 结果 | ||
| 88 | + */ | ||
| 89 | + @Override | ||
| 90 | + public int deleteInformationSharingById(Long id) | ||
| 91 | + { | ||
| 92 | + return informationSharingMapper.deleteInformationSharingById(id); | ||
| 93 | + } | ||
| 94 | +} |
trash-daily/src/main/java/com/trash/monthly/controller/MonthlyReportController.java
0 → 100644
| 1 | +package com.trash.monthly.controller; | ||
| 2 | + | ||
| 3 | +import com.trash.common.annotation.Log; | ||
| 4 | +import com.trash.common.core.controller.BaseController; | ||
| 5 | +import com.trash.common.core.domain.AjaxResult; | ||
| 6 | +import com.trash.common.core.page.TableDataInfo; | ||
| 7 | +import com.trash.common.enums.BusinessType; | ||
| 8 | +import com.trash.common.utils.poi.ExcelUtil; | ||
| 9 | +import com.trash.daily.domain.PeriodicReport; | ||
| 10 | +import com.trash.monthly.service.IMonthlyReportService; | ||
| 11 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 12 | +import org.springframework.security.access.prepost.PreAuthorize; | ||
| 13 | +import org.springframework.web.bind.annotation.*; | ||
| 14 | + | ||
| 15 | +import java.util.List; | ||
| 16 | + | ||
| 17 | +/** | ||
| 18 | + * 月报Controller | ||
| 19 | + * | ||
| 20 | + * @author trash | ||
| 21 | + * @date 2023-04-23 | ||
| 22 | + */ | ||
| 23 | +@RestController | ||
| 24 | +@RequestMapping("/report/monthly") | ||
| 25 | +public class MonthlyReportController extends BaseController | ||
| 26 | +{ | ||
| 27 | + @Autowired | ||
| 28 | + private IMonthlyReportService monthlyReportService; | ||
| 29 | + | ||
| 30 | + /** | ||
| 31 | + * 查询月报列表 | ||
| 32 | + */ | ||
| 33 | + @PreAuthorize("@ss.hasPermi('report:monthly:list')") | ||
| 34 | + @GetMapping("/list") | ||
| 35 | + public TableDataInfo list(PeriodicReport periodicReport) | ||
| 36 | + { | ||
| 37 | + startPage(); | ||
| 38 | + List<PeriodicReport> list = monthlyReportService.selectMonthlyReportList(periodicReport); | ||
| 39 | + return getDataTable(list); | ||
| 40 | + } | ||
| 41 | + | ||
| 42 | + /** | ||
| 43 | + * 导出月报列表 | ||
| 44 | + */ | ||
| 45 | + @PreAuthorize("@ss.hasPermi('report:monthly:export')") | ||
| 46 | + @Log(title = "月报", businessType = BusinessType.EXPORT) | ||
| 47 | + @GetMapping("/export") | ||
| 48 | + public AjaxResult export(PeriodicReport periodicReport) | ||
| 49 | + { | ||
| 50 | + List<PeriodicReport> list = monthlyReportService.selectMonthlyReportList(periodicReport); | ||
| 51 | + ExcelUtil<PeriodicReport> util = new ExcelUtil<PeriodicReport>(PeriodicReport.class); | ||
| 52 | + return util.exportExcel(list, "monthly"); | ||
| 53 | + } | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 获取月报详细信息 | ||
| 57 | + */ | ||
| 58 | + @PreAuthorize("@ss.hasPermi('report:monthly:query')") | ||
| 59 | + @GetMapping(value = "/{id}") | ||
| 60 | + public AjaxResult getInfo(@PathVariable("id") Long id) | ||
| 61 | + { | ||
| 62 | + return AjaxResult.success(monthlyReportService.selectMonthlyReportById(id)); | ||
| 63 | + } | ||
| 64 | + | ||
| 65 | + /** | ||
| 66 | + * 新增月报 | ||
| 67 | + */ | ||
| 68 | + @PreAuthorize("@ss.hasPermi('report:monthly:add')") | ||
| 69 | + @Log(title = "月报", businessType = BusinessType.INSERT) | ||
| 70 | + @PostMapping | ||
| 71 | + public AjaxResult add(@RequestBody PeriodicReport periodicReport) | ||
| 72 | + { | ||
| 73 | + return toAjax(monthlyReportService.insertMonthlyReport(periodicReport)); | ||
| 74 | + } | ||
| 75 | + | ||
| 76 | + /** | ||
| 77 | + * 修改月报 | ||
| 78 | + */ | ||
| 79 | + @PreAuthorize("@ss.hasPermi('report:monthly:edit')") | ||
| 80 | + @Log(title = "月报", businessType = BusinessType.UPDATE) | ||
| 81 | + @PutMapping | ||
| 82 | + public AjaxResult edit(@RequestBody PeriodicReport periodicReport) | ||
| 83 | + { | ||
| 84 | + return toAjax(monthlyReportService.updateMonthlyReport(periodicReport)); | ||
| 85 | + } | ||
| 86 | + | ||
| 87 | + /** | ||
| 88 | + * 删除月报 | ||
| 89 | + */ | ||
| 90 | + @PreAuthorize("@ss.hasPermi('report:monthly:remove')") | ||
| 91 | + @Log(title = "月报", businessType = BusinessType.DELETE) | ||
| 92 | + @DeleteMapping("/{ids}") | ||
| 93 | + public AjaxResult remove(@PathVariable Long[] ids) | ||
| 94 | + { | ||
| 95 | + return toAjax(monthlyReportService.deleteMonthlyReportByIds(ids)); | ||
| 96 | + } | ||
| 97 | +} | ||
| 0 | \ No newline at end of file | 98 | \ No newline at end of file |
trash-daily/src/main/java/com/trash/monthly/mapper/MonthlyReportMapper.java
0 → 100644
| 1 | +package com.trash.monthly.mapper; | ||
| 2 | + | ||
| 3 | +import com.trash.daily.domain.PeriodicReport; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 月报Mapper接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-21 | ||
| 12 | + */ | ||
| 13 | +public interface MonthlyReportMapper | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询月报 | ||
| 17 | + * | ||
| 18 | + * @param id 月报ID | ||
| 19 | + * @return 月报 | ||
| 20 | + */ | ||
| 21 | + public PeriodicReport selectMonthlyReportById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询月报列表 | ||
| 25 | + * | ||
| 26 | + * @param monthlyReport 月报 | ||
| 27 | + * @return 月报集合 | ||
| 28 | + */ | ||
| 29 | + public List<PeriodicReport> selectMonthlyReportList(PeriodicReport monthlyReport); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增月报 | ||
| 33 | + * | ||
| 34 | + * @param monthlyReport 月报 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertMonthlyReport(PeriodicReport monthlyReport); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改月报 | ||
| 41 | + * | ||
| 42 | + * @param monthlyReport 月报 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateMonthlyReport(PeriodicReport monthlyReport); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 删除月报 | ||
| 49 | + * | ||
| 50 | + * @param id 月报ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteMonthlyReportById(Long id); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 批量删除月报 | ||
| 57 | + * | ||
| 58 | + * @param ids 需要删除的数据ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteMonthlyReportByIds(Long[] ids); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/monthly/service/IMonthlyReportService.java
0 → 100644
| 1 | +package com.trash.monthly.service; | ||
| 2 | + | ||
| 3 | +import com.trash.daily.domain.PeriodicReport; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 月报Service接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-21 | ||
| 12 | + */ | ||
| 13 | +public interface IMonthlyReportService | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询月报 | ||
| 17 | + * | ||
| 18 | + * @param id 月报ID | ||
| 19 | + * @return 月报 | ||
| 20 | + */ | ||
| 21 | + public PeriodicReport selectMonthlyReportById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询月报列表 | ||
| 25 | + * | ||
| 26 | + * @param monthlyReport 月报 | ||
| 27 | + * @return 月报集合 | ||
| 28 | + */ | ||
| 29 | + public List<PeriodicReport> selectMonthlyReportList(PeriodicReport monthlyReport); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增月报 | ||
| 33 | + * | ||
| 34 | + * @param monthlyReport 月报 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertMonthlyReport(PeriodicReport monthlyReport); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改月报 | ||
| 41 | + * | ||
| 42 | + * @param monthlyReport 月报 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateMonthlyReport(PeriodicReport monthlyReport); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 删除月报 | ||
| 49 | + * | ||
| 50 | + * @param id 月报ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteMonthlyReportById(Long id); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 批量删除月报 | ||
| 57 | + * | ||
| 58 | + * @param ids 需要删除的数据ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteMonthlyReportByIds(Long[] ids); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/monthly/service/impl/MonthlyReportServiceImpl.java
0 → 100644
| 1 | +package com.trash.monthly.service.impl; | ||
| 2 | + | ||
| 3 | +import com.trash.daily.domain.PeriodicReport; | ||
| 4 | +import com.trash.monthly.mapper.MonthlyReportMapper; | ||
| 5 | +import com.trash.monthly.service.IMonthlyReportService; | ||
| 6 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 7 | +import org.springframework.stereotype.Service; | ||
| 8 | + | ||
| 9 | +import java.util.List; | ||
| 10 | + | ||
| 11 | + | ||
| 12 | +/** | ||
| 13 | + * 月报Service业务层处理 | ||
| 14 | + * | ||
| 15 | + * @author trash | ||
| 16 | + * @date 2023-04-21 | ||
| 17 | + */ | ||
| 18 | +@Service | ||
| 19 | +public class MonthlyReportServiceImpl implements IMonthlyReportService | ||
| 20 | +{ | ||
| 21 | + @Autowired | ||
| 22 | + private MonthlyReportMapper monthlyReportMapper; | ||
| 23 | + | ||
| 24 | + /** | ||
| 25 | + * 查询月报 | ||
| 26 | + * | ||
| 27 | + * @param id 月报ID | ||
| 28 | + * @return 月报 | ||
| 29 | + */ | ||
| 30 | + @Override | ||
| 31 | + public PeriodicReport selectMonthlyReportById(Long id) | ||
| 32 | + { | ||
| 33 | + return monthlyReportMapper.selectMonthlyReportById(id); | ||
| 34 | + } | ||
| 35 | + | ||
| 36 | + /** | ||
| 37 | + * 查询月报列表 | ||
| 38 | + * | ||
| 39 | + * @param monthlyReport 月报 | ||
| 40 | + * @return 月报 | ||
| 41 | + */ | ||
| 42 | + @Override | ||
| 43 | + public List<PeriodicReport> selectMonthlyReportList(PeriodicReport monthlyReport) | ||
| 44 | + { | ||
| 45 | + return monthlyReportMapper.selectMonthlyReportList(monthlyReport); | ||
| 46 | + } | ||
| 47 | + | ||
| 48 | + /** | ||
| 49 | + * 新增月报 | ||
| 50 | + * | ||
| 51 | + * @param monthlyReport 月报 | ||
| 52 | + * @return 结果 | ||
| 53 | + */ | ||
| 54 | + @Override | ||
| 55 | + public int insertMonthlyReport(PeriodicReport monthlyReport) | ||
| 56 | + { | ||
| 57 | + return monthlyReportMapper.insertMonthlyReport(monthlyReport); | ||
| 58 | + } | ||
| 59 | + | ||
| 60 | + /** | ||
| 61 | + * 修改月报 | ||
| 62 | + * | ||
| 63 | + * @param monthlyReport 月报 | ||
| 64 | + * @return 结果 | ||
| 65 | + */ | ||
| 66 | + @Override | ||
| 67 | + public int updateMonthlyReport(PeriodicReport monthlyReport) | ||
| 68 | + { | ||
| 69 | + return monthlyReportMapper.updateMonthlyReport(monthlyReport); | ||
| 70 | + } | ||
| 71 | + | ||
| 72 | + /** | ||
| 73 | + * 批量删除月报 | ||
| 74 | + * | ||
| 75 | + * @param ids 需要删除的月报ID | ||
| 76 | + * @return 结果 | ||
| 77 | + */ | ||
| 78 | + @Override | ||
| 79 | + public int deleteMonthlyReportByIds(Long[] ids) | ||
| 80 | + { | ||
| 81 | + return monthlyReportMapper.deleteMonthlyReportByIds(ids); | ||
| 82 | + } | ||
| 83 | + | ||
| 84 | + /** | ||
| 85 | + * 删除月报信息 | ||
| 86 | + * | ||
| 87 | + * @param id 月报ID | ||
| 88 | + * @return 结果 | ||
| 89 | + */ | ||
| 90 | + @Override | ||
| 91 | + public int deleteMonthlyReportById(Long id) | ||
| 92 | + { | ||
| 93 | + return monthlyReportMapper.deleteMonthlyReportById(id); | ||
| 94 | + } | ||
| 95 | +} |
trash-daily/src/main/java/com/trash/report/controller/WorkReportController.java
0 → 100644
| 1 | +package com.trash.report.controller; | ||
| 2 | + | ||
| 3 | +import com.trash.common.annotation.Log; | ||
| 4 | +import com.trash.common.core.controller.BaseController; | ||
| 5 | +import com.trash.common.core.domain.AjaxResult; | ||
| 6 | +import com.trash.common.core.page.TableDataInfo; | ||
| 7 | +import com.trash.common.enums.BusinessType; | ||
| 8 | +import com.trash.common.utils.poi.ExcelUtil; | ||
| 9 | +import com.trash.report.domain.WorkReport; | ||
| 10 | +import com.trash.report.service.IWorkReportService; | ||
| 11 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 12 | +import org.springframework.security.access.prepost.PreAuthorize; | ||
| 13 | +import org.springframework.web.bind.annotation.*; | ||
| 14 | + | ||
| 15 | +import java.util.List; | ||
| 16 | + | ||
| 17 | +/** | ||
| 18 | + * 工作日报Controller | ||
| 19 | + * | ||
| 20 | + * @author trash | ||
| 21 | + * @date 2023-04-21 | ||
| 22 | + */ | ||
| 23 | +@RestController | ||
| 24 | +@RequestMapping("/daily/report") | ||
| 25 | +public class WorkReportController extends BaseController | ||
| 26 | +{ | ||
| 27 | + @Autowired | ||
| 28 | + private IWorkReportService workReportService; | ||
| 29 | + | ||
| 30 | + /** | ||
| 31 | + * 查询工作日报列表 | ||
| 32 | + */ | ||
| 33 | + @PreAuthorize("@ss.hasPermi('daily:report:list')") | ||
| 34 | + @GetMapping("/list") | ||
| 35 | + public TableDataInfo list(WorkReport workReport) | ||
| 36 | + { | ||
| 37 | + startPage(); | ||
| 38 | + List<WorkReport> list = workReportService.selectWorkReportList(workReport); | ||
| 39 | + return getDataTable(list); | ||
| 40 | + } | ||
| 41 | + | ||
| 42 | + /** | ||
| 43 | + * 导出工作日报列表 | ||
| 44 | + */ | ||
| 45 | + @PreAuthorize("@ss.hasPermi('daily:report:export')") | ||
| 46 | + @Log(title = "工作日报", businessType = BusinessType.EXPORT) | ||
| 47 | + @GetMapping("/export") | ||
| 48 | + public AjaxResult export(WorkReport workReport) | ||
| 49 | + { | ||
| 50 | + List<WorkReport> list = workReportService.selectWorkReportList(workReport); | ||
| 51 | + ExcelUtil<WorkReport> util = new ExcelUtil<WorkReport>(WorkReport.class); | ||
| 52 | + return util.exportExcel(list, "report"); | ||
| 53 | + } | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 获取工作日报详细信息 | ||
| 57 | + */ | ||
| 58 | + @PreAuthorize("@ss.hasPermi('daily:report:query')") | ||
| 59 | + @GetMapping(value = "/{id}") | ||
| 60 | + public AjaxResult getInfo(@PathVariable("id") Long id) | ||
| 61 | + { | ||
| 62 | + return AjaxResult.success(workReportService.selectWorkReportById(id)); | ||
| 63 | + } | ||
| 64 | + | ||
| 65 | + /** | ||
| 66 | + * 新增工作日报 | ||
| 67 | + */ | ||
| 68 | + @PreAuthorize("@ss.hasPermi('daily:report:add')") | ||
| 69 | + @Log(title = "工作日报", businessType = BusinessType.INSERT) | ||
| 70 | + @PostMapping | ||
| 71 | + public AjaxResult add(@RequestBody WorkReport workReport) | ||
| 72 | + { | ||
| 73 | + return toAjax(workReportService.insertWorkReport(workReport)); | ||
| 74 | + } | ||
| 75 | + | ||
| 76 | + /** | ||
| 77 | + * 修改工作日报 | ||
| 78 | + */ | ||
| 79 | + @PreAuthorize("@ss.hasPermi('daily:report:edit')") | ||
| 80 | + @Log(title = "工作日报", businessType = BusinessType.UPDATE) | ||
| 81 | + @PutMapping | ||
| 82 | + public AjaxResult edit(@RequestBody WorkReport workReport) | ||
| 83 | + { | ||
| 84 | + return toAjax(workReportService.updateWorkReport(workReport)); | ||
| 85 | + } | ||
| 86 | + | ||
| 87 | + /** | ||
| 88 | + * 删除工作日报 | ||
| 89 | + */ | ||
| 90 | + @PreAuthorize("@ss.hasPermi('daily:report:remove')") | ||
| 91 | + @Log(title = "工作日报", businessType = BusinessType.DELETE) | ||
| 92 | + @DeleteMapping("/{ids}") | ||
| 93 | + public AjaxResult remove(@PathVariable Long[] ids) | ||
| 94 | + { | ||
| 95 | + return toAjax(workReportService.deleteWorkReportByIds(ids)); | ||
| 96 | + } | ||
| 97 | +} |
trash-daily/src/main/java/com/trash/report/domain/WorkReport.java
0 → 100644
| 1 | +package com.trash.report.domain; | ||
| 2 | + | ||
| 3 | +import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 4 | +import com.trash.common.annotation.Excel; | ||
| 5 | +import com.trash.common.core.domain.BaseEntity; | ||
| 6 | +import org.apache.commons.lang3.builder.ToStringBuilder; | ||
| 7 | +import org.apache.commons.lang3.builder.ToStringStyle; | ||
| 8 | + | ||
| 9 | +import java.util.Date; | ||
| 10 | + | ||
| 11 | +/** | ||
| 12 | + * 工作日报对象 work_report | ||
| 13 | + * | ||
| 14 | + * @author trash | ||
| 15 | + * @date 2023-04-21 | ||
| 16 | + */ | ||
| 17 | +public class WorkReport extends BaseEntity | ||
| 18 | +{ | ||
| 19 | + private static final long serialVersionUID = 1L; | ||
| 20 | + | ||
| 21 | + /** 主键id */ | ||
| 22 | + private Long id; | ||
| 23 | + | ||
| 24 | + /** 标题 */ | ||
| 25 | + @Excel(name = "标题") | ||
| 26 | + private String weeklyTitle; | ||
| 27 | + | ||
| 28 | + /** 填写人 */ | ||
| 29 | + @Excel(name = "填写人") | ||
| 30 | + private String writer; | ||
| 31 | + | ||
| 32 | + /** 填写时间 */ | ||
| 33 | + @JsonFormat(pattern = "yyyy-MM-dd") | ||
| 34 | + @Excel(name = "填写时间", width = 30, dateFormat = "yyyy-MM-dd") | ||
| 35 | + private Date writeTime; | ||
| 36 | + | ||
| 37 | + /** 报表内容 */ | ||
| 38 | + private String reportContent; | ||
| 39 | + | ||
| 40 | + public void setId(Long id) | ||
| 41 | + { | ||
| 42 | + this.id = id; | ||
| 43 | + } | ||
| 44 | + | ||
| 45 | + public Long getId() | ||
| 46 | + { | ||
| 47 | + return id; | ||
| 48 | + } | ||
| 49 | + public void setWeeklyTitle(String weeklyTitle) | ||
| 50 | + { | ||
| 51 | + this.weeklyTitle = weeklyTitle; | ||
| 52 | + } | ||
| 53 | + | ||
| 54 | + public String getWeeklyTitle() | ||
| 55 | + { | ||
| 56 | + return weeklyTitle; | ||
| 57 | + } | ||
| 58 | + public void setWriter(String writer) | ||
| 59 | + { | ||
| 60 | + this.writer = writer; | ||
| 61 | + } | ||
| 62 | + | ||
| 63 | + public String getWriter() | ||
| 64 | + { | ||
| 65 | + return writer; | ||
| 66 | + } | ||
| 67 | + public void setWriteTime(Date writeTime) | ||
| 68 | + { | ||
| 69 | + this.writeTime = writeTime; | ||
| 70 | + } | ||
| 71 | + | ||
| 72 | + public Date getWriteTime() | ||
| 73 | + { | ||
| 74 | + return writeTime; | ||
| 75 | + } | ||
| 76 | + public void setReportContent(String reportContent) | ||
| 77 | + { | ||
| 78 | + this.reportContent = reportContent; | ||
| 79 | + } | ||
| 80 | + | ||
| 81 | + public String getReportContent() | ||
| 82 | + { | ||
| 83 | + return reportContent; | ||
| 84 | + } | ||
| 85 | + | ||
| 86 | + @Override | ||
| 87 | + public String toString() { | ||
| 88 | + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) | ||
| 89 | + .append("id", getId()) | ||
| 90 | + .append("weeklyTitle", getWeeklyTitle()) | ||
| 91 | + .append("writer", getWriter()) | ||
| 92 | + .append("writeTime", getWriteTime()) | ||
| 93 | + .append("reportContent", getReportContent()) | ||
| 94 | + .toString(); | ||
| 95 | + } | ||
| 96 | +} |
trash-daily/src/main/java/com/trash/report/mapper/WorkReportMapper.java
0 → 100644
| 1 | +package com.trash.report.mapper; | ||
| 2 | + | ||
| 3 | +import com.trash.report.domain.WorkReport; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 工作日报Mapper接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-21 | ||
| 12 | + */ | ||
| 13 | +public interface WorkReportMapper | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询工作日报 | ||
| 17 | + * | ||
| 18 | + * @param id 工作日报ID | ||
| 19 | + * @return 工作日报 | ||
| 20 | + */ | ||
| 21 | + public WorkReport selectWorkReportById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询工作日报列表 | ||
| 25 | + * | ||
| 26 | + * @param workReport 工作日报 | ||
| 27 | + * @return 工作日报集合 | ||
| 28 | + */ | ||
| 29 | + public List<WorkReport> selectWorkReportList(WorkReport workReport); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增工作日报 | ||
| 33 | + * | ||
| 34 | + * @param workReport 工作日报 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertWorkReport(WorkReport workReport); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改工作日报 | ||
| 41 | + * | ||
| 42 | + * @param workReport 工作日报 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateWorkReport(WorkReport workReport); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 删除工作日报 | ||
| 49 | + * | ||
| 50 | + * @param id 工作日报ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteWorkReportById(Long id); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 批量删除工作日报 | ||
| 57 | + * | ||
| 58 | + * @param ids 需要删除的数据ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteWorkReportByIds(Long[] ids); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/report/service/IWorkReportService.java
0 → 100644
| 1 | +package com.trash.report.service; | ||
| 2 | + | ||
| 3 | +import com.trash.report.domain.WorkReport; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 工作日报Service接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-21 | ||
| 12 | + */ | ||
| 13 | +public interface IWorkReportService | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询工作日报 | ||
| 17 | + * | ||
| 18 | + * @param id 工作日报ID | ||
| 19 | + * @return 工作日报 | ||
| 20 | + */ | ||
| 21 | + public WorkReport selectWorkReportById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询工作日报列表 | ||
| 25 | + * | ||
| 26 | + * @param workReport 工作日报 | ||
| 27 | + * @return 工作日报集合 | ||
| 28 | + */ | ||
| 29 | + public List<WorkReport> selectWorkReportList(WorkReport workReport); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增工作日报 | ||
| 33 | + * | ||
| 34 | + * @param workReport 工作日报 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertWorkReport(WorkReport workReport); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改工作日报 | ||
| 41 | + * | ||
| 42 | + * @param workReport 工作日报 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateWorkReport(WorkReport workReport); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 批量删除工作日报 | ||
| 49 | + * | ||
| 50 | + * @param ids 需要删除的工作日报ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteWorkReportByIds(Long[] ids); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 删除工作日报信息 | ||
| 57 | + * | ||
| 58 | + * @param id 工作日报ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteWorkReportById(Long id); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/report/service/impl/WorkReportServiceImpl.java
0 → 100644
| 1 | +package com.trash.report.service.impl; | ||
| 2 | + | ||
| 3 | +import com.trash.report.domain.WorkReport; | ||
| 4 | +import com.trash.report.mapper.WorkReportMapper; | ||
| 5 | +import com.trash.report.service.IWorkReportService; | ||
| 6 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 7 | +import org.springframework.stereotype.Service; | ||
| 8 | + | ||
| 9 | +import java.util.List; | ||
| 10 | + | ||
| 11 | +/** | ||
| 12 | + * 工作日报Service业务层处理 | ||
| 13 | + * | ||
| 14 | + * @author trash | ||
| 15 | + * @date 2023-04-21 | ||
| 16 | + */ | ||
| 17 | +@Service | ||
| 18 | +public class WorkReportServiceImpl implements IWorkReportService | ||
| 19 | +{ | ||
| 20 | + @Autowired | ||
| 21 | + private WorkReportMapper workReportMapper; | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询工作日报 | ||
| 25 | + * | ||
| 26 | + * @param id 工作日报ID | ||
| 27 | + * @return 工作日报 | ||
| 28 | + */ | ||
| 29 | + @Override | ||
| 30 | + public WorkReport selectWorkReportById(Long id) | ||
| 31 | + { | ||
| 32 | + return workReportMapper.selectWorkReportById(id); | ||
| 33 | + } | ||
| 34 | + | ||
| 35 | + /** | ||
| 36 | + * 查询工作日报列表 | ||
| 37 | + * | ||
| 38 | + * @param workReport 工作日报 | ||
| 39 | + * @return 工作日报 | ||
| 40 | + */ | ||
| 41 | + @Override | ||
| 42 | + public List<WorkReport> selectWorkReportList(WorkReport workReport) | ||
| 43 | + { | ||
| 44 | + return workReportMapper.selectWorkReportList(workReport); | ||
| 45 | + } | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 新增工作日报 | ||
| 49 | + * | ||
| 50 | + * @param workReport 工作日报 | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + @Override | ||
| 54 | + public int insertWorkReport(WorkReport workReport) | ||
| 55 | + { | ||
| 56 | + return workReportMapper.insertWorkReport(workReport); | ||
| 57 | + } | ||
| 58 | + | ||
| 59 | + /** | ||
| 60 | + * 修改工作日报 | ||
| 61 | + * | ||
| 62 | + * @param workReport 工作日报 | ||
| 63 | + * @return 结果 | ||
| 64 | + */ | ||
| 65 | + @Override | ||
| 66 | + public int updateWorkReport(WorkReport workReport) | ||
| 67 | + { | ||
| 68 | + return workReportMapper.updateWorkReport(workReport); | ||
| 69 | + } | ||
| 70 | + | ||
| 71 | + /** | ||
| 72 | + * 批量删除工作日报 | ||
| 73 | + * | ||
| 74 | + * @param ids 需要删除的工作日报ID | ||
| 75 | + * @return 结果 | ||
| 76 | + */ | ||
| 77 | + @Override | ||
| 78 | + public int deleteWorkReportByIds(Long[] ids) | ||
| 79 | + { | ||
| 80 | + return workReportMapper.deleteWorkReportByIds(ids); | ||
| 81 | + } | ||
| 82 | + | ||
| 83 | + /** | ||
| 84 | + * 删除工作日报信息 | ||
| 85 | + * | ||
| 86 | + * @param id 工作日报ID | ||
| 87 | + * @return 结果 | ||
| 88 | + */ | ||
| 89 | + @Override | ||
| 90 | + public int deleteWorkReportById(Long id) | ||
| 91 | + { | ||
| 92 | + return workReportMapper.deleteWorkReportById(id); | ||
| 93 | + } | ||
| 94 | +} |
trash-daily/src/main/java/com/trash/situation/controller/DailySituationController.java
0 → 100644
| 1 | +package com.trash.situation.controller; | ||
| 2 | + | ||
| 3 | +import com.trash.common.annotation.Log; | ||
| 4 | +import com.trash.common.core.controller.BaseController; | ||
| 5 | +import com.trash.common.core.domain.AjaxResult; | ||
| 6 | +import com.trash.common.core.page.TableDataInfo; | ||
| 7 | +import com.trash.common.enums.BusinessType; | ||
| 8 | +import com.trash.common.utils.poi.ExcelUtil; | ||
| 9 | +import com.trash.situation.domain.DailySituation; | ||
| 10 | +import com.trash.situation.service.IDailySituationService; | ||
| 11 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 12 | +import org.springframework.security.access.prepost.PreAuthorize; | ||
| 13 | +import org.springframework.web.bind.annotation.*; | ||
| 14 | + | ||
| 15 | +import java.util.List; | ||
| 16 | + | ||
| 17 | +/** | ||
| 18 | + * 每日普查情况Controller | ||
| 19 | + * | ||
| 20 | + * @author trash | ||
| 21 | + * @date 2023-04-19 | ||
| 22 | + */ | ||
| 23 | +@RestController | ||
| 24 | +@RequestMapping("/daily/situation") | ||
| 25 | +public class DailySituationController extends BaseController | ||
| 26 | +{ | ||
| 27 | + @Autowired | ||
| 28 | + private IDailySituationService dailySituationService; | ||
| 29 | + | ||
| 30 | + /** | ||
| 31 | + * 查询每日普查情况列表 | ||
| 32 | + */ | ||
| 33 | + @PreAuthorize("@ss.hasPermi('daily:situation:list')") | ||
| 34 | + @GetMapping("/list") | ||
| 35 | + public TableDataInfo list(DailySituation dailySituation) | ||
| 36 | + { | ||
| 37 | + startPage(); | ||
| 38 | + List<DailySituation> list = dailySituationService.selectDailySituationList(dailySituation); | ||
| 39 | + return getDataTable(list); | ||
| 40 | + } | ||
| 41 | + //为什么你的controller在这里,放到trash-admin里面去 | ||
| 42 | + /** | ||
| 43 | + * 导出每日普查情况列表 | ||
| 44 | + */ | ||
| 45 | + @PreAuthorize("@ss.hasPermi('daily:situation:export')") | ||
| 46 | + @Log(title = "每日普查情况", businessType = BusinessType.EXPORT) | ||
| 47 | + @GetMapping("/export") | ||
| 48 | + public AjaxResult export(DailySituation dailySituation) | ||
| 49 | + { | ||
| 50 | + List<DailySituation> list = dailySituationService.selectDailySituationList(dailySituation); | ||
| 51 | + ExcelUtil<DailySituation> util = new ExcelUtil<DailySituation>(DailySituation.class); | ||
| 52 | + return util.exportExcel(list, "situation"); | ||
| 53 | + } | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 获取每日普查情况详细信息 | ||
| 57 | + */ | ||
| 58 | + @PreAuthorize("@ss.hasPermi('daily:situation:query')") | ||
| 59 | + @GetMapping(value = "/{id}") | ||
| 60 | + public AjaxResult getInfo(@PathVariable("id") String id) | ||
| 61 | + { | ||
| 62 | + return AjaxResult.success(dailySituationService.selectDailySituationById(id)); | ||
| 63 | + } | ||
| 64 | + | ||
| 65 | + /** | ||
| 66 | + * 新增每日普查情况 | ||
| 67 | + */ | ||
| 68 | + @PreAuthorize("@ss.hasPermi('daily:situation:add')") | ||
| 69 | + @Log(title = "每日普查情况", businessType = BusinessType.INSERT) | ||
| 70 | + @PostMapping | ||
| 71 | + public AjaxResult add(@RequestBody DailySituation dailySituation) | ||
| 72 | + { | ||
| 73 | + return toAjax(dailySituationService.insertDailySituation(dailySituation)); | ||
| 74 | + } | ||
| 75 | + | ||
| 76 | + /** | ||
| 77 | + * 修改每日普查情况 | ||
| 78 | + */ | ||
| 79 | + @PreAuthorize("@ss.hasPermi('daily:situation:edit')") | ||
| 80 | + @Log(title = "每日普查情况", businessType = BusinessType.UPDATE) | ||
| 81 | + @PutMapping | ||
| 82 | + public AjaxResult edit(@RequestBody DailySituation dailySituation) | ||
| 83 | + { | ||
| 84 | + return toAjax(dailySituationService.updateDailySituation(dailySituation)); | ||
| 85 | + } | ||
| 86 | + | ||
| 87 | + /** | ||
| 88 | + * 删除每日普查情况 | ||
| 89 | + */ | ||
| 90 | + @PreAuthorize("@ss.hasPermi('daily:situation:remove')") | ||
| 91 | + @Log(title = "每日普查情况", businessType = BusinessType.DELETE) | ||
| 92 | + @DeleteMapping("/{ids}") | ||
| 93 | + public AjaxResult remove(@PathVariable String[] ids) | ||
| 94 | + { | ||
| 95 | + return toAjax(dailySituationService.deleteDailySituationByIds(ids)); | ||
| 96 | + } | ||
| 97 | +} |
trash-daily/src/main/java/com/trash/situation/domain/DailySituation.java
0 → 100644
| 1 | +package com.trash.situation.domain; | ||
| 2 | + | ||
| 3 | +import com.trash.common.annotation.Excel; | ||
| 4 | +import com.trash.common.core.domain.BaseEntity; | ||
| 5 | +import org.apache.commons.lang3.builder.ToStringBuilder; | ||
| 6 | +import org.apache.commons.lang3.builder.ToStringStyle; | ||
| 7 | + | ||
| 8 | +import java.util.Date; | ||
| 9 | + | ||
| 10 | +/** | ||
| 11 | + * 每日普查情况对象 daily_situation | ||
| 12 | + * | ||
| 13 | + * @author trash | ||
| 14 | + * @date 2023-04-19 | ||
| 15 | + */ | ||
| 16 | +public class DailySituation extends BaseEntity | ||
| 17 | +{ | ||
| 18 | + private static final long serialVersionUID = 1L; | ||
| 19 | + | ||
| 20 | + /** 主键id */ | ||
| 21 | + private String id; | ||
| 22 | + | ||
| 23 | + /** 标题 */ | ||
| 24 | + @Excel(name = "标题") | ||
| 25 | + private String title; | ||
| 26 | + | ||
| 27 | + /** 操作人 */ | ||
| 28 | + @Excel(name = "操作人") | ||
| 29 | + private String operator; | ||
| 30 | + | ||
| 31 | + /** 日期 */ | ||
| 32 | + private Date date; | ||
| 33 | + | ||
| 34 | + /** 天气 */ | ||
| 35 | + private String weather; | ||
| 36 | + | ||
| 37 | + /** 全市工地,消纳场开停情况 */ | ||
| 38 | + private String consumptionSiteSituation; | ||
| 39 | + | ||
| 40 | + /** 车辆数 */ | ||
| 41 | + private String numberOfVehicles; | ||
| 42 | + | ||
| 43 | + public void setId(String id) | ||
| 44 | + { | ||
| 45 | + this.id = id; | ||
| 46 | + } | ||
| 47 | + | ||
| 48 | + public String getId() | ||
| 49 | + { | ||
| 50 | + return id; | ||
| 51 | + } | ||
| 52 | + public void setTitle(String title) | ||
| 53 | + { | ||
| 54 | + this.title = title; | ||
| 55 | + } | ||
| 56 | + | ||
| 57 | + public String getTitle() | ||
| 58 | + { | ||
| 59 | + return title; | ||
| 60 | + } | ||
| 61 | + public void setOperator(String operator) | ||
| 62 | + { | ||
| 63 | + this.operator = operator; | ||
| 64 | + } | ||
| 65 | + | ||
| 66 | + public String getOperator() | ||
| 67 | + { | ||
| 68 | + return operator; | ||
| 69 | + } | ||
| 70 | + public void setDate(Date date) | ||
| 71 | + { | ||
| 72 | + this.date = date; | ||
| 73 | + } | ||
| 74 | + | ||
| 75 | + public Date getDate() | ||
| 76 | + { | ||
| 77 | + return date; | ||
| 78 | + } | ||
| 79 | + public void setWeather(String weather) | ||
| 80 | + { | ||
| 81 | + this.weather = weather; | ||
| 82 | + } | ||
| 83 | + | ||
| 84 | + public String getWeather() | ||
| 85 | + { | ||
| 86 | + return weather; | ||
| 87 | + } | ||
| 88 | + public void setConsumptionSiteSituation(String consumptionSiteSituation) | ||
| 89 | + { | ||
| 90 | + this.consumptionSiteSituation = consumptionSiteSituation; | ||
| 91 | + } | ||
| 92 | + | ||
| 93 | + public String getConsumptionSiteSituation() | ||
| 94 | + { | ||
| 95 | + return consumptionSiteSituation; | ||
| 96 | + } | ||
| 97 | + public void setNumberOfVehicles(String numberOfVehicles) | ||
| 98 | + { | ||
| 99 | + this.numberOfVehicles = numberOfVehicles; | ||
| 100 | + } | ||
| 101 | + | ||
| 102 | + public String getNumberOfVehicles() | ||
| 103 | + { | ||
| 104 | + return numberOfVehicles; | ||
| 105 | + } | ||
| 106 | + | ||
| 107 | + @Override | ||
| 108 | + public String toString() { | ||
| 109 | + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) | ||
| 110 | + .append("id", getId()) | ||
| 111 | + .append("title", getTitle()) | ||
| 112 | + .append("operator", getOperator()) | ||
| 113 | + .append("date", getDate()) | ||
| 114 | + .append("weather", getWeather()) | ||
| 115 | + .append("consumptionSiteSituation", getConsumptionSiteSituation()) | ||
| 116 | + .append("numberOfVehicles", getNumberOfVehicles()) | ||
| 117 | + .append("createTime", getCreateTime()) | ||
| 118 | + .append("updateTime", getUpdateTime()) | ||
| 119 | + .toString(); | ||
| 120 | + } | ||
| 121 | +} |
trash-daily/src/main/java/com/trash/situation/mapper/DailySituationMapper.java
0 → 100644
| 1 | +package com.trash.situation.mapper; | ||
| 2 | + | ||
| 3 | +import com.trash.situation.domain.DailySituation; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 每日普查情况Mapper接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-19 | ||
| 12 | + */ | ||
| 13 | +public interface DailySituationMapper | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询每日普查情况 | ||
| 17 | + * | ||
| 18 | + * @param id 每日普查情况ID | ||
| 19 | + * @return 每日普查情况 | ||
| 20 | + */ | ||
| 21 | + public DailySituation selectDailySituationById(String id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询每日普查情况列表 | ||
| 25 | + * | ||
| 26 | + * @param dailySituation 每日普查情况 | ||
| 27 | + * @return 每日普查情况集合 | ||
| 28 | + */ | ||
| 29 | + public List<DailySituation> selectDailySituationList(DailySituation dailySituation); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增每日普查情况 | ||
| 33 | + * | ||
| 34 | + * @param dailySituation 每日普查情况 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertDailySituation(DailySituation dailySituation); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改每日普查情况 | ||
| 41 | + * | ||
| 42 | + * @param dailySituation 每日普查情况 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateDailySituation(DailySituation dailySituation); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 删除每日普查情况 | ||
| 49 | + * | ||
| 50 | + * @param id 每日普查情况ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteDailySituationById(String id); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 批量删除每日普查情况 | ||
| 57 | + * | ||
| 58 | + * @param ids 需要删除的数据ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteDailySituationByIds(String[] ids); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/situation/service/IDailySituationService.java
0 → 100644
| 1 | +package com.trash.situation.service; | ||
| 2 | + | ||
| 3 | +import com.trash.situation.domain.DailySituation; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 每日普查情况Service接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-19 | ||
| 12 | + */ | ||
| 13 | +public interface IDailySituationService | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询每日普查情况 | ||
| 17 | + * | ||
| 18 | + * @param id 每日普查情况ID | ||
| 19 | + * @return 每日普查情况 | ||
| 20 | + */ | ||
| 21 | + public DailySituation selectDailySituationById(String id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询每日普查情况列表 | ||
| 25 | + * | ||
| 26 | + * @param dailySituation 每日普查情况 | ||
| 27 | + * @return 每日普查情况集合 | ||
| 28 | + */ | ||
| 29 | + public List<DailySituation> selectDailySituationList(DailySituation dailySituation); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增每日普查情况 | ||
| 33 | + * | ||
| 34 | + * @param dailySituation 每日普查情况 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertDailySituation(DailySituation dailySituation); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改每日普查情况 | ||
| 41 | + * | ||
| 42 | + * @param dailySituation 每日普查情况 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateDailySituation(DailySituation dailySituation); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 批量删除每日普查情况 | ||
| 49 | + * | ||
| 50 | + * @param ids 需要删除的每日普查情况ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteDailySituationByIds(String[] ids); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 删除每日普查情况信息 | ||
| 57 | + * | ||
| 58 | + * @param id 每日普查情况ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteDailySituationById(String id); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/situation/service/impl/DailySituationServiceImpl.java
0 → 100644
| 1 | +package com.trash.situation.service.impl; | ||
| 2 | + | ||
| 3 | +import com.trash.common.utils.DateUtils; | ||
| 4 | +import com.trash.situation.domain.DailySituation; | ||
| 5 | +import com.trash.situation.mapper.DailySituationMapper; | ||
| 6 | +import com.trash.situation.service.IDailySituationService; | ||
| 7 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 8 | +import org.springframework.stereotype.Service; | ||
| 9 | + | ||
| 10 | +import java.util.List; | ||
| 11 | + | ||
| 12 | +/** | ||
| 13 | + * 每日普查情况Service业务层处理 | ||
| 14 | + * | ||
| 15 | + * @author trash | ||
| 16 | + * @date 2023-04-19 | ||
| 17 | + */ | ||
| 18 | +@Service | ||
| 19 | +public class DailySituationServiceImpl implements IDailySituationService | ||
| 20 | +{ | ||
| 21 | + @Autowired | ||
| 22 | + private DailySituationMapper dailySituationMapper; | ||
| 23 | + | ||
| 24 | + /** | ||
| 25 | + * 查询每日普查情况 | ||
| 26 | + * | ||
| 27 | + * @param id 每日普查情况ID | ||
| 28 | + * @return 每日普查情况 | ||
| 29 | + */ | ||
| 30 | + @Override | ||
| 31 | + public DailySituation selectDailySituationById(String id) | ||
| 32 | + { | ||
| 33 | + return dailySituationMapper.selectDailySituationById(id); | ||
| 34 | + } | ||
| 35 | + | ||
| 36 | + /** | ||
| 37 | + * 查询每日普查情况列表 | ||
| 38 | + * | ||
| 39 | + * @param dailySituation 每日普查情况 | ||
| 40 | + * @return 每日普查情况 | ||
| 41 | + */ | ||
| 42 | + @Override | ||
| 43 | + public List<DailySituation> selectDailySituationList(DailySituation dailySituation) | ||
| 44 | + { | ||
| 45 | + return dailySituationMapper.selectDailySituationList(dailySituation); | ||
| 46 | + } | ||
| 47 | + | ||
| 48 | + /** | ||
| 49 | + * 新增每日普查情况 | ||
| 50 | + * | ||
| 51 | + * @param dailySituation 每日普查情况 | ||
| 52 | + * @return 结果 | ||
| 53 | + */ | ||
| 54 | + @Override | ||
| 55 | + public int insertDailySituation(DailySituation dailySituation) | ||
| 56 | + { | ||
| 57 | + dailySituation.setCreateTime(DateUtils.getNowDate()); | ||
| 58 | + return dailySituationMapper.insertDailySituation(dailySituation); | ||
| 59 | + } | ||
| 60 | + | ||
| 61 | + /** | ||
| 62 | + * 修改每日普查情况 | ||
| 63 | + * | ||
| 64 | + * @param dailySituation 每日普查情况 | ||
| 65 | + * @return 结果 | ||
| 66 | + */ | ||
| 67 | + @Override | ||
| 68 | + public int updateDailySituation(DailySituation dailySituation) | ||
| 69 | + { | ||
| 70 | + dailySituation.setUpdateTime(DateUtils.getNowDate()); | ||
| 71 | + return dailySituationMapper.updateDailySituation(dailySituation); | ||
| 72 | + } | ||
| 73 | + | ||
| 74 | + /** | ||
| 75 | + * 批量删除每日普查情况 | ||
| 76 | + * | ||
| 77 | + * @param ids 需要删除的每日普查情况ID | ||
| 78 | + * @return 结果 | ||
| 79 | + */ | ||
| 80 | + @Override | ||
| 81 | + public int deleteDailySituationByIds(String[] ids) | ||
| 82 | + { | ||
| 83 | + return dailySituationMapper.deleteDailySituationByIds(ids); | ||
| 84 | + } | ||
| 85 | + | ||
| 86 | + /** | ||
| 87 | + * 删除每日普查情况信息 | ||
| 88 | + * | ||
| 89 | + * @param id 每日普查情况ID | ||
| 90 | + * @return 结果 | ||
| 91 | + */ | ||
| 92 | + @Override | ||
| 93 | + public int deleteDailySituationById(String id) | ||
| 94 | + { | ||
| 95 | + return dailySituationMapper.deleteDailySituationById(id); | ||
| 96 | + } | ||
| 97 | +} |
trash-daily/src/main/java/com/trash/toollist/controller/DailyToolListController.java
0 → 100644
| 1 | +package com.trash.toollist.controller; | ||
| 2 | + | ||
| 3 | +import com.trash.common.annotation.Log; | ||
| 4 | +import com.trash.common.core.controller.BaseController; | ||
| 5 | +import com.trash.common.core.domain.AjaxResult; | ||
| 6 | +import com.trash.common.core.page.TableDataInfo; | ||
| 7 | +import com.trash.common.enums.BusinessType; | ||
| 8 | +import com.trash.common.utils.poi.ExcelUtil; | ||
| 9 | +import com.trash.toollist.domain.DailyToolList; | ||
| 10 | +import com.trash.toollist.service.IDailyToolListService; | ||
| 11 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 12 | +import org.springframework.security.access.prepost.PreAuthorize; | ||
| 13 | +import org.springframework.web.bind.annotation.*; | ||
| 14 | + | ||
| 15 | +import java.util.List; | ||
| 16 | + | ||
| 17 | +/** | ||
| 18 | + * 每日工作清单Controller | ||
| 19 | + * | ||
| 20 | + * @author trash | ||
| 21 | + * @date 2023-04-20 | ||
| 22 | + */ | ||
| 23 | +@RestController | ||
| 24 | +@RequestMapping("/daily/toollist") | ||
| 25 | +public class DailyToolListController extends BaseController | ||
| 26 | +{ | ||
| 27 | + @Autowired | ||
| 28 | + private IDailyToolListService dailyToolListService; | ||
| 29 | + | ||
| 30 | + /** | ||
| 31 | + * 查询每日工作清单列表 | ||
| 32 | + */ | ||
| 33 | + @PreAuthorize("@ss.hasPermi('daily:toollist:list')") | ||
| 34 | + @GetMapping("/list") | ||
| 35 | + public TableDataInfo list(DailyToolList dailyToolList) | ||
| 36 | + { | ||
| 37 | + startPage(); | ||
| 38 | + List<DailyToolList> list = dailyToolListService.selectDailyToolListList(dailyToolList); | ||
| 39 | + return getDataTable(list); | ||
| 40 | + } | ||
| 41 | + | ||
| 42 | + /** | ||
| 43 | + * 导出每日工作清单列表 | ||
| 44 | + */ | ||
| 45 | + @PreAuthorize("@ss.hasPermi('daily:toollist:export')") | ||
| 46 | + @Log(title = "每日工作清单", businessType = BusinessType.EXPORT) | ||
| 47 | + @GetMapping("/export") | ||
| 48 | + public AjaxResult export(DailyToolList dailyToolList) | ||
| 49 | + { | ||
| 50 | + List<DailyToolList> list = dailyToolListService.selectDailyToolListList(dailyToolList); | ||
| 51 | + ExcelUtil<DailyToolList> util = new ExcelUtil<DailyToolList>(DailyToolList.class); | ||
| 52 | + return util.exportExcel(list, "toollist"); | ||
| 53 | + } | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 获取每日工作清单详细信息 | ||
| 57 | + */ | ||
| 58 | + @PreAuthorize("@ss.hasPermi('daily:toollist:query')") | ||
| 59 | + @GetMapping(value = "/{id}") | ||
| 60 | + public AjaxResult getInfo(@PathVariable("id") Long id) | ||
| 61 | + { | ||
| 62 | + return AjaxResult.success(dailyToolListService.selectDailyToolListById(id)); | ||
| 63 | + } | ||
| 64 | + | ||
| 65 | + /** | ||
| 66 | + * 新增每日工作清单 | ||
| 67 | + */ | ||
| 68 | + @PreAuthorize("@ss.hasPermi('daily:toollist:add')") | ||
| 69 | + @Log(title = "每日工作清单", businessType = BusinessType.INSERT) | ||
| 70 | + @PostMapping | ||
| 71 | + public AjaxResult add(@RequestBody DailyToolList dailyToolList) | ||
| 72 | + { | ||
| 73 | + return toAjax(dailyToolListService.insertDailyToolList(dailyToolList)); | ||
| 74 | + } | ||
| 75 | + | ||
| 76 | + /** | ||
| 77 | + * 修改每日工作清单 | ||
| 78 | + */ | ||
| 79 | + @PreAuthorize("@ss.hasPermi('daily:toollist:edit')") | ||
| 80 | + @Log(title = "每日工作清单", businessType = BusinessType.UPDATE) | ||
| 81 | + @PutMapping | ||
| 82 | + public AjaxResult edit(@RequestBody DailyToolList dailyToolList) | ||
| 83 | + { | ||
| 84 | + return toAjax(dailyToolListService.updateDailyToolList(dailyToolList)); | ||
| 85 | + } | ||
| 86 | + | ||
| 87 | + /** | ||
| 88 | + * 删除每日工作清单 | ||
| 89 | + */ | ||
| 90 | + @PreAuthorize("@ss.hasPermi('daily:toollist:remove')") | ||
| 91 | + @Log(title = "每日工作清单", businessType = BusinessType.DELETE) | ||
| 92 | + @DeleteMapping("/{ids}") | ||
| 93 | + public AjaxResult remove(@PathVariable Long[] ids) | ||
| 94 | + { | ||
| 95 | + return toAjax(dailyToolListService.deleteDailyToolListByIds(ids)); | ||
| 96 | + } | ||
| 97 | +} |
trash-daily/src/main/java/com/trash/toollist/domain/DailyToolList.java
0 → 100644
| 1 | +package com.trash.toollist.domain; | ||
| 2 | + | ||
| 3 | +import com.trash.common.annotation.Excel; | ||
| 4 | +import com.trash.common.core.domain.BaseEntity; | ||
| 5 | +import org.apache.commons.lang3.builder.ToStringBuilder; | ||
| 6 | +import org.apache.commons.lang3.builder.ToStringStyle; | ||
| 7 | + | ||
| 8 | +import java.util.Date; | ||
| 9 | + | ||
| 10 | +/** | ||
| 11 | + * 每日工作清单对象 daily_tool_list | ||
| 12 | + * | ||
| 13 | + * @author trash | ||
| 14 | + * @date 2023-04-20 | ||
| 15 | + */ | ||
| 16 | +public class DailyToolList extends BaseEntity | ||
| 17 | +{ | ||
| 18 | + private static final long serialVersionUID = 1L; | ||
| 19 | + | ||
| 20 | + /** 主键id */ | ||
| 21 | + private Long id; | ||
| 22 | + | ||
| 23 | + /** 标题 */ | ||
| 24 | + @Excel(name = "标题") | ||
| 25 | + private String title; | ||
| 26 | + | ||
| 27 | + /** 区域 */ | ||
| 28 | + @Excel(name = "区域") | ||
| 29 | + private String region; | ||
| 30 | + | ||
| 31 | + /** 操作人 */ | ||
| 32 | + @Excel(name = "操作人") | ||
| 33 | + private String operator; | ||
| 34 | + | ||
| 35 | + /** 日期 */ | ||
| 36 | + private Date date; | ||
| 37 | + | ||
| 38 | + /** 开工工地数 */ | ||
| 39 | + private String numberOfConstructionSites; | ||
| 40 | + | ||
| 41 | + /** 普查结果 */ | ||
| 42 | + private String censusStructure; | ||
| 43 | + | ||
| 44 | + /** 渣土管理值班负责人 */ | ||
| 45 | + private String managementLeader; | ||
| 46 | + | ||
| 47 | + /** 执法中队负责人 */ | ||
| 48 | + private String lawEnforcementOfficer; | ||
| 49 | + | ||
| 50 | + /** 普查具体情况 */ | ||
| 51 | + private String specificSituationOfTheCensus; | ||
| 52 | + | ||
| 53 | + public void setId(Long id) | ||
| 54 | + { | ||
| 55 | + this.id = id; | ||
| 56 | + } | ||
| 57 | + | ||
| 58 | + public Long getId() | ||
| 59 | + { | ||
| 60 | + return id; | ||
| 61 | + } | ||
| 62 | + public void setTitle(String title) | ||
| 63 | + { | ||
| 64 | + this.title = title; | ||
| 65 | + } | ||
| 66 | + | ||
| 67 | + public String getTitle() | ||
| 68 | + { | ||
| 69 | + return title; | ||
| 70 | + } | ||
| 71 | + public void setRegion(String region) | ||
| 72 | + { | ||
| 73 | + this.region = region; | ||
| 74 | + } | ||
| 75 | + | ||
| 76 | + public String getRegion() | ||
| 77 | + { | ||
| 78 | + return region; | ||
| 79 | + } | ||
| 80 | + public void setOperator(String operator) | ||
| 81 | + { | ||
| 82 | + this.operator = operator; | ||
| 83 | + } | ||
| 84 | + | ||
| 85 | + public String getOperator() | ||
| 86 | + { | ||
| 87 | + return operator; | ||
| 88 | + } | ||
| 89 | + public void setDate(Date date) | ||
| 90 | + { | ||
| 91 | + this.date = date; | ||
| 92 | + } | ||
| 93 | + | ||
| 94 | + public Date getDate() | ||
| 95 | + { | ||
| 96 | + return date; | ||
| 97 | + } | ||
| 98 | + public void setNumberOfConstructionSites(String numberOfConstructionSites) | ||
| 99 | + { | ||
| 100 | + this.numberOfConstructionSites = numberOfConstructionSites; | ||
| 101 | + } | ||
| 102 | + | ||
| 103 | + public String getNumberOfConstructionSites() | ||
| 104 | + { | ||
| 105 | + return numberOfConstructionSites; | ||
| 106 | + } | ||
| 107 | + public void setCensusStructure(String censusStructure) | ||
| 108 | + { | ||
| 109 | + this.censusStructure = censusStructure; | ||
| 110 | + } | ||
| 111 | + | ||
| 112 | + public String getCensusStructure() | ||
| 113 | + { | ||
| 114 | + return censusStructure; | ||
| 115 | + } | ||
| 116 | + public void setManagementLeader(String managementLeader) | ||
| 117 | + { | ||
| 118 | + this.managementLeader = managementLeader; | ||
| 119 | + } | ||
| 120 | + | ||
| 121 | + public String getManagementLeader() | ||
| 122 | + { | ||
| 123 | + return managementLeader; | ||
| 124 | + } | ||
| 125 | + public void setLawEnforcementOfficer(String lawEnforcementOfficer) | ||
| 126 | + { | ||
| 127 | + this.lawEnforcementOfficer = lawEnforcementOfficer; | ||
| 128 | + } | ||
| 129 | + | ||
| 130 | + public String getLawEnforcementOfficer() | ||
| 131 | + { | ||
| 132 | + return lawEnforcementOfficer; | ||
| 133 | + } | ||
| 134 | + public void setSpecificSituationOfTheCensus(String specificSituationOfTheCensus) | ||
| 135 | + { | ||
| 136 | + this.specificSituationOfTheCensus = specificSituationOfTheCensus; | ||
| 137 | + } | ||
| 138 | + | ||
| 139 | + public String getSpecificSituationOfTheCensus() | ||
| 140 | + { | ||
| 141 | + return specificSituationOfTheCensus; | ||
| 142 | + } | ||
| 143 | + | ||
| 144 | + @Override | ||
| 145 | + public String toString() { | ||
| 146 | + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) | ||
| 147 | + .append("id", getId()) | ||
| 148 | + .append("title", getTitle()) | ||
| 149 | + .append("region", getRegion()) | ||
| 150 | + .append("operator", getOperator()) | ||
| 151 | + .append("date", getDate()) | ||
| 152 | + .append("numberOfConstructionSites", getNumberOfConstructionSites()) | ||
| 153 | + .append("censusStructure", getCensusStructure()) | ||
| 154 | + .append("managementLeader", getManagementLeader()) | ||
| 155 | + .append("lawEnforcementOfficer", getLawEnforcementOfficer()) | ||
| 156 | + .append("specificSituationOfTheCensus", getSpecificSituationOfTheCensus()) | ||
| 157 | + .toString(); | ||
| 158 | + } | ||
| 159 | +} |
trash-daily/src/main/java/com/trash/toollist/mapper/DailyToolListMapper.java
0 → 100644
| 1 | +package com.trash.toollist.mapper; | ||
| 2 | + | ||
| 3 | +import com.trash.toollist.domain.DailyToolList; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 每日工作清单Mapper接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-20 | ||
| 12 | + */ | ||
| 13 | +public interface DailyToolListMapper | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询每日工作清单 | ||
| 17 | + * | ||
| 18 | + * @param id 每日工作清单ID | ||
| 19 | + * @return 每日工作清单 | ||
| 20 | + */ | ||
| 21 | + public DailyToolList selectDailyToolListById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询每日工作清单列表 | ||
| 25 | + * | ||
| 26 | + * @param dailyToolList 每日工作清单 | ||
| 27 | + * @return 每日工作清单集合 | ||
| 28 | + */ | ||
| 29 | + public List<DailyToolList> selectDailyToolListList(DailyToolList dailyToolList); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增每日工作清单 | ||
| 33 | + * | ||
| 34 | + * @param dailyToolList 每日工作清单 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertDailyToolList(DailyToolList dailyToolList); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改每日工作清单 | ||
| 41 | + * | ||
| 42 | + * @param dailyToolList 每日工作清单 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateDailyToolList(DailyToolList dailyToolList); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 删除每日工作清单 | ||
| 49 | + * | ||
| 50 | + * @param id 每日工作清单ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteDailyToolListById(Long id); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 批量删除每日工作清单 | ||
| 57 | + * | ||
| 58 | + * @param ids 需要删除的数据ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteDailyToolListByIds(Long[] ids); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/toollist/service/IDailyToolListService.java
0 → 100644
| 1 | +package com.trash.toollist.service; | ||
| 2 | + | ||
| 3 | +import com.trash.toollist.domain.DailyToolList; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 每日工作清单Service接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-20 | ||
| 12 | + */ | ||
| 13 | +public interface IDailyToolListService | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询每日工作清单 | ||
| 17 | + * | ||
| 18 | + * @param id 每日工作清单ID | ||
| 19 | + * @return 每日工作清单 | ||
| 20 | + */ | ||
| 21 | + public DailyToolList selectDailyToolListById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询每日工作清单列表 | ||
| 25 | + * | ||
| 26 | + * @param dailyToolList 每日工作清单 | ||
| 27 | + * @return 每日工作清单集合 | ||
| 28 | + */ | ||
| 29 | + public List<DailyToolList> selectDailyToolListList(DailyToolList dailyToolList); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增每日工作清单 | ||
| 33 | + * | ||
| 34 | + * @param dailyToolList 每日工作清单 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertDailyToolList(DailyToolList dailyToolList); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改每日工作清单 | ||
| 41 | + * | ||
| 42 | + * @param dailyToolList 每日工作清单 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateDailyToolList(DailyToolList dailyToolList); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 批量删除每日工作清单 | ||
| 49 | + * | ||
| 50 | + * @param ids 需要删除的每日工作清单ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteDailyToolListByIds(Long[] ids); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 删除每日工作清单信息 | ||
| 57 | + * | ||
| 58 | + * @param id 每日工作清单ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteDailyToolListById(Long id); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/toollist/service/impl/DailyToolListServiceImpl.java
0 → 100644
| 1 | +package com.trash.toollist.service.impl; | ||
| 2 | + | ||
| 3 | +import com.trash.toollist.domain.DailyToolList; | ||
| 4 | +import com.trash.toollist.mapper.DailyToolListMapper; | ||
| 5 | +import com.trash.toollist.service.IDailyToolListService; | ||
| 6 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 7 | +import org.springframework.stereotype.Service; | ||
| 8 | + | ||
| 9 | +import java.util.List; | ||
| 10 | + | ||
| 11 | +/** | ||
| 12 | + * 每日工作清单Service业务层处理 | ||
| 13 | + * | ||
| 14 | + * @author trash | ||
| 15 | + * @date 2023-04-20 | ||
| 16 | + */ | ||
| 17 | +@Service | ||
| 18 | +public class DailyToolListServiceImpl implements IDailyToolListService | ||
| 19 | +{ | ||
| 20 | + @Autowired | ||
| 21 | + private DailyToolListMapper dailyToolListMapper; | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询每日工作清单 | ||
| 25 | + * | ||
| 26 | + * @param id 每日工作清单ID | ||
| 27 | + * @return 每日工作清单 | ||
| 28 | + */ | ||
| 29 | + @Override | ||
| 30 | + public DailyToolList selectDailyToolListById(Long id) | ||
| 31 | + { | ||
| 32 | + return dailyToolListMapper.selectDailyToolListById(id); | ||
| 33 | + } | ||
| 34 | + | ||
| 35 | + /** | ||
| 36 | + * 查询每日工作清单列表 | ||
| 37 | + * | ||
| 38 | + * @param dailyToolList 每日工作清单 | ||
| 39 | + * @return 每日工作清单 | ||
| 40 | + */ | ||
| 41 | + @Override | ||
| 42 | + public List<DailyToolList> selectDailyToolListList(DailyToolList dailyToolList) | ||
| 43 | + { | ||
| 44 | + return dailyToolListMapper.selectDailyToolListList(dailyToolList); | ||
| 45 | + } | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 新增每日工作清单 | ||
| 49 | + * | ||
| 50 | + * @param dailyToolList 每日工作清单 | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + @Override | ||
| 54 | + public int insertDailyToolList(DailyToolList dailyToolList) | ||
| 55 | + { | ||
| 56 | + return dailyToolListMapper.insertDailyToolList(dailyToolList); | ||
| 57 | + } | ||
| 58 | + | ||
| 59 | + /** | ||
| 60 | + * 修改每日工作清单 | ||
| 61 | + * | ||
| 62 | + * @param dailyToolList 每日工作清单 | ||
| 63 | + * @return 结果 | ||
| 64 | + */ | ||
| 65 | + @Override | ||
| 66 | + public int updateDailyToolList(DailyToolList dailyToolList) | ||
| 67 | + { | ||
| 68 | + return dailyToolListMapper.updateDailyToolList(dailyToolList); | ||
| 69 | + } | ||
| 70 | + | ||
| 71 | + /** | ||
| 72 | + * 批量删除每日工作清单 | ||
| 73 | + * | ||
| 74 | + * @param ids 需要删除的每日工作清单ID | ||
| 75 | + * @return 结果 | ||
| 76 | + */ | ||
| 77 | + @Override | ||
| 78 | + public int deleteDailyToolListByIds(Long[] ids) | ||
| 79 | + { | ||
| 80 | + return dailyToolListMapper.deleteDailyToolListByIds(ids); | ||
| 81 | + } | ||
| 82 | + | ||
| 83 | + /** | ||
| 84 | + * 删除每日工作清单信息 | ||
| 85 | + * | ||
| 86 | + * @param id 每日工作清单ID | ||
| 87 | + * @return 结果 | ||
| 88 | + */ | ||
| 89 | + @Override | ||
| 90 | + public int deleteDailyToolListById(Long id) | ||
| 91 | + { | ||
| 92 | + return dailyToolListMapper.deleteDailyToolListById(id); | ||
| 93 | + } | ||
| 94 | +} |
trash-daily/src/main/java/com/trash/weekly/controller/WeeklyController.java
0 → 100644
| 1 | +package com.trash.weekly.controller; | ||
| 2 | + | ||
| 3 | +import com.trash.common.annotation.Log; | ||
| 4 | +import com.trash.common.core.controller.BaseController; | ||
| 5 | +import com.trash.common.core.domain.AjaxResult; | ||
| 6 | +import com.trash.common.core.page.TableDataInfo; | ||
| 7 | +import com.trash.common.enums.BusinessType; | ||
| 8 | +import com.trash.common.utils.poi.ExcelUtil; | ||
| 9 | +import com.trash.daily.domain.PeriodicReport; | ||
| 10 | +import com.trash.weekly.service.IWeeklyService; | ||
| 11 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 12 | +import org.springframework.security.access.prepost.PreAuthorize; | ||
| 13 | +import org.springframework.web.bind.annotation.*; | ||
| 14 | + | ||
| 15 | +import java.util.List; | ||
| 16 | + | ||
| 17 | +/** | ||
| 18 | + * 周报Controller | ||
| 19 | + * | ||
| 20 | + * @author trash | ||
| 21 | + * @date 2023-04-23 | ||
| 22 | + */ | ||
| 23 | +@RestController | ||
| 24 | +@RequestMapping("/report/weekly") | ||
| 25 | +public class WeeklyController extends BaseController | ||
| 26 | +{ | ||
| 27 | + @Autowired | ||
| 28 | + private IWeeklyService weeklyService; | ||
| 29 | + | ||
| 30 | + /** | ||
| 31 | + * 查询周报列表 | ||
| 32 | + */ | ||
| 33 | + @PreAuthorize("@ss.hasPermi('report:weekly:list')") | ||
| 34 | + @GetMapping("/list") | ||
| 35 | + public TableDataInfo list(PeriodicReport periodicReport) | ||
| 36 | + { | ||
| 37 | + startPage(); | ||
| 38 | + List<PeriodicReport> list = weeklyService.selectWeeklyList(periodicReport); | ||
| 39 | + return getDataTable(list); | ||
| 40 | + } | ||
| 41 | + | ||
| 42 | + /** | ||
| 43 | + * 导出周报列表 | ||
| 44 | + */ | ||
| 45 | + @PreAuthorize("@ss.hasPermi('report:weekly:export')") | ||
| 46 | + @Log(title = "周报", businessType = BusinessType.EXPORT) | ||
| 47 | + @GetMapping("/export") | ||
| 48 | + public AjaxResult export(PeriodicReport periodicReport) | ||
| 49 | + { | ||
| 50 | + List<PeriodicReport> list = weeklyService.selectWeeklyList(periodicReport); | ||
| 51 | + ExcelUtil<PeriodicReport> util = new ExcelUtil<PeriodicReport>(PeriodicReport.class); | ||
| 52 | + return util.exportExcel(list, "weekly"); | ||
| 53 | + } | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 获取周报详细信息 | ||
| 57 | + */ | ||
| 58 | + @PreAuthorize("@ss.hasPermi('report:weekly:query')") | ||
| 59 | + @GetMapping(value = "/{id}") | ||
| 60 | + public AjaxResult getInfo(@PathVariable("id") Long id) | ||
| 61 | + { | ||
| 62 | + return AjaxResult.success(weeklyService.selectWeeklyById(id)); | ||
| 63 | + } | ||
| 64 | + | ||
| 65 | + /** | ||
| 66 | + * 新增周报 | ||
| 67 | + */ | ||
| 68 | + @PreAuthorize("@ss.hasPermi('report:weekly:add')") | ||
| 69 | + @Log(title = "周报", businessType = BusinessType.INSERT) | ||
| 70 | + @PostMapping | ||
| 71 | + public AjaxResult add(@RequestBody PeriodicReport periodicReport) | ||
| 72 | + { | ||
| 73 | + return toAjax(weeklyService.insertWeekly(periodicReport)); | ||
| 74 | + } | ||
| 75 | + | ||
| 76 | + /** | ||
| 77 | + * 修改周报 | ||
| 78 | + */ | ||
| 79 | + @PreAuthorize("@ss.hasPermi('report:weekly:edit')") | ||
| 80 | + @Log(title = "周报", businessType = BusinessType.UPDATE) | ||
| 81 | + @PutMapping | ||
| 82 | + public AjaxResult edit(@RequestBody PeriodicReport periodicReport) | ||
| 83 | + { | ||
| 84 | + return toAjax(weeklyService.updateWeekly(periodicReport)); | ||
| 85 | + } | ||
| 86 | + | ||
| 87 | + /** | ||
| 88 | + * 删除周报 | ||
| 89 | + */ | ||
| 90 | + @PreAuthorize("@ss.hasPermi('report:weekly:remove')") | ||
| 91 | + @Log(title = "周报", businessType = BusinessType.DELETE) | ||
| 92 | + @DeleteMapping("/{ids}") | ||
| 93 | + public AjaxResult remove(@PathVariable Long[] ids) | ||
| 94 | + { | ||
| 95 | + return toAjax(weeklyService.deleteWeeklyByIds(ids)); | ||
| 96 | + } | ||
| 97 | +} | ||
| 0 | \ No newline at end of file | 98 | \ No newline at end of file |
trash-daily/src/main/java/com/trash/weekly/mapper/WeeklyMapper.java
0 → 100644
| 1 | +package com.trash.weekly.mapper; | ||
| 2 | + | ||
| 3 | +import com.trash.daily.domain.PeriodicReport; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 周报Mapper接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-21 | ||
| 12 | + */ | ||
| 13 | +public interface WeeklyMapper | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询周报 | ||
| 17 | + * | ||
| 18 | + * @param id 周报ID | ||
| 19 | + * @return 周报 | ||
| 20 | + */ | ||
| 21 | + public PeriodicReport selectWeeklyById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询周报列表 | ||
| 25 | + * | ||
| 26 | + * @param weekly 周报 | ||
| 27 | + * @return 周报集合 | ||
| 28 | + */ | ||
| 29 | + public List<PeriodicReport> selectWeeklyList(PeriodicReport weekly); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增周报 | ||
| 33 | + * | ||
| 34 | + * @param weekly 周报 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertWeekly(PeriodicReport weekly); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改周报 | ||
| 41 | + * | ||
| 42 | + * @param weekly 周报 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateWeekly(PeriodicReport weekly); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 删除周报 | ||
| 49 | + * | ||
| 50 | + * @param id 周报ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteWeeklyById(Long id); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 批量删除周报 | ||
| 57 | + * | ||
| 58 | + * @param ids 需要删除的数据ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteWeeklyByIds(Long[] ids); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/weekly/service/IWeeklyService.java
0 → 100644
| 1 | +package com.trash.weekly.service; | ||
| 2 | + | ||
| 3 | +import com.trash.daily.domain.PeriodicReport; | ||
| 4 | + | ||
| 5 | +import java.util.List; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * 周报Service接口 | ||
| 9 | + * | ||
| 10 | + * @author trash | ||
| 11 | + * @date 2023-04-21 | ||
| 12 | + */ | ||
| 13 | +public interface IWeeklyService | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * 查询周报 | ||
| 17 | + * | ||
| 18 | + * @param id 周报ID | ||
| 19 | + * @return 周报 | ||
| 20 | + */ | ||
| 21 | + public PeriodicReport selectWeeklyById(Long id); | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询周报列表 | ||
| 25 | + * | ||
| 26 | + * @param weekly 周报 | ||
| 27 | + * @return 周报集合 | ||
| 28 | + */ | ||
| 29 | + public List<PeriodicReport> selectWeeklyList(PeriodicReport weekly); | ||
| 30 | + | ||
| 31 | + /** | ||
| 32 | + * 新增周报 | ||
| 33 | + * | ||
| 34 | + * @param weekly 周报 | ||
| 35 | + * @return 结果 | ||
| 36 | + */ | ||
| 37 | + public int insertWeekly(PeriodicReport weekly); | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + * 修改周报 | ||
| 41 | + * | ||
| 42 | + * @param weekly 周报 | ||
| 43 | + * @return 结果 | ||
| 44 | + */ | ||
| 45 | + public int updateWeekly(PeriodicReport weekly); | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 批量删除周报 | ||
| 49 | + * | ||
| 50 | + * @param ids 需要删除的周报ID | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + public int deleteWeeklyByIds(Long[] ids); | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * 删除周报信息 | ||
| 57 | + * | ||
| 58 | + * @param id 周报ID | ||
| 59 | + * @return 结果 | ||
| 60 | + */ | ||
| 61 | + public int deleteWeeklyById(Long id); | ||
| 62 | +} |
trash-daily/src/main/java/com/trash/weekly/service/impl/WeeklyServiceImpl.java
0 → 100644
| 1 | +package com.trash.weekly.service.impl; | ||
| 2 | + | ||
| 3 | +import com.trash.daily.domain.PeriodicReport; | ||
| 4 | +import com.trash.weekly.mapper.WeeklyMapper; | ||
| 5 | +import com.trash.weekly.service.IWeeklyService; | ||
| 6 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 7 | +import org.springframework.stereotype.Service; | ||
| 8 | + | ||
| 9 | +import java.util.List; | ||
| 10 | + | ||
| 11 | +/** | ||
| 12 | + * 周报Service业务层处理 | ||
| 13 | + * | ||
| 14 | + * @author trash | ||
| 15 | + * @date 2023-04-21 | ||
| 16 | + */ | ||
| 17 | +@Service | ||
| 18 | +public class WeeklyServiceImpl implements IWeeklyService | ||
| 19 | +{ | ||
| 20 | + @Autowired | ||
| 21 | + private WeeklyMapper weeklyMapper; | ||
| 22 | + | ||
| 23 | + /** | ||
| 24 | + * 查询周报 | ||
| 25 | + * | ||
| 26 | + * @param id 周报ID | ||
| 27 | + * @return 周报 | ||
| 28 | + */ | ||
| 29 | + @Override | ||
| 30 | + public PeriodicReport selectWeeklyById(Long id) | ||
| 31 | + { | ||
| 32 | + return weeklyMapper.selectWeeklyById(id); | ||
| 33 | + } | ||
| 34 | + | ||
| 35 | + /** | ||
| 36 | + * 查询周报列表 | ||
| 37 | + * | ||
| 38 | + * @param weekly 周报 | ||
| 39 | + * @return 周报 | ||
| 40 | + */ | ||
| 41 | + @Override | ||
| 42 | + public List<PeriodicReport> selectWeeklyList(PeriodicReport weekly) | ||
| 43 | + { | ||
| 44 | + return weeklyMapper.selectWeeklyList(weekly); | ||
| 45 | + } | ||
| 46 | + | ||
| 47 | + /** | ||
| 48 | + * 新增周报 | ||
| 49 | + * | ||
| 50 | + * @param weekly 周报 | ||
| 51 | + * @return 结果 | ||
| 52 | + */ | ||
| 53 | + @Override | ||
| 54 | + public int insertWeekly(PeriodicReport weekly) | ||
| 55 | + { | ||
| 56 | + return weeklyMapper.insertWeekly(weekly); | ||
| 57 | + } | ||
| 58 | + | ||
| 59 | + /** | ||
| 60 | + * 修改周报 | ||
| 61 | + * | ||
| 62 | + * @param weekly 周报 | ||
| 63 | + * @return 结果 | ||
| 64 | + */ | ||
| 65 | + @Override | ||
| 66 | + public int updateWeekly(PeriodicReport weekly) | ||
| 67 | + { | ||
| 68 | + return weeklyMapper.updateWeekly(weekly); | ||
| 69 | + } | ||
| 70 | + | ||
| 71 | + /** | ||
| 72 | + * 批量删除周报 | ||
| 73 | + * | ||
| 74 | + * @param ids 需要删除的周报ID | ||
| 75 | + * @return 结果 | ||
| 76 | + */ | ||
| 77 | + @Override | ||
| 78 | + public int deleteWeeklyByIds(Long[] ids) | ||
| 79 | + { | ||
| 80 | + return weeklyMapper.deleteWeeklyByIds(ids); | ||
| 81 | + } | ||
| 82 | + | ||
| 83 | + /** | ||
| 84 | + * 删除周报信息 | ||
| 85 | + * | ||
| 86 | + * @param id 周报ID | ||
| 87 | + * @return 结果 | ||
| 88 | + */ | ||
| 89 | + @Override | ||
| 90 | + public int deleteWeeklyById(Long id) | ||
| 91 | + { | ||
| 92 | + return weeklyMapper.deleteWeeklyById(id); | ||
| 93 | + } | ||
| 94 | +} |
trash-daily/src/main/resources/mapper/daily/DailyMapper.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8" ?> | ||
| 2 | +<!DOCTYPE mapper | ||
| 3 | + PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
| 4 | + "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||
| 5 | +<mapper namespace="com.trash.daily.mapper.DailyMapper"> | ||
| 6 | + | ||
| 7 | + <resultMap type="PeriodicReport" id="PeriodicReportResult"> | ||
| 8 | + <result property="id" column="id" /> | ||
| 9 | + <result property="headline" column="headline" /> | ||
| 10 | + <result property="writer" column="writer" /> | ||
| 11 | + <result property="writeTime" column="write_time" /> | ||
| 12 | + <result property="content" column="content" /> | ||
| 13 | + <result property="begintime" column="beginTime" /> | ||
| 14 | + <result property="endtime" column="endTime" /> | ||
| 15 | + <result property="contentType" column="content_type" /> | ||
| 16 | + </resultMap> | ||
| 17 | + | ||
| 18 | + <sql id="selectDailyVo"> | ||
| 19 | + select id, headline, writer, write_time, content, beginTime, endTime, content_type from periodic_report | ||
| 20 | + </sql> | ||
| 21 | + | ||
| 22 | + <select id="selectDailyList" parameterType="PeriodicReport" resultMap="PeriodicReportResult"> | ||
| 23 | + <include refid="selectDailyVo"/> | ||
| 24 | + <where> | ||
| 25 | + <if test="headline != null and headline != ''"> and headline = #{headline}</if> | ||
| 26 | + and content_type = 1 | ||
| 27 | + </where> | ||
| 28 | + </select> | ||
| 29 | + | ||
| 30 | + <select id="selectDailyById" parameterType="Long" resultMap="PeriodicReportResult"> | ||
| 31 | + <include refid="selectDailyVo"/> | ||
| 32 | + where id = #{id} | ||
| 33 | + </select> | ||
| 34 | + | ||
| 35 | + <insert id="insertDaily" parameterType="PeriodicReport" useGeneratedKeys="true" keyProperty="id"> | ||
| 36 | + insert into periodic_report | ||
| 37 | + <trim prefix="(" suffix=")" suffixOverrides=","> | ||
| 38 | + <if test="headline != null">headline,</if> | ||
| 39 | + <if test="writer != null">writer,</if> | ||
| 40 | + <if test="writeTime != null">write_time,</if> | ||
| 41 | + <if test="content != null">content,</if> | ||
| 42 | + <if test="begintime != null">beginTime,</if> | ||
| 43 | + <if test="endtime != null">endTime,</if> | ||
| 44 | + content_type | ||
| 45 | + </trim> | ||
| 46 | + <trim prefix="values (" suffix=")" suffixOverrides=","> | ||
| 47 | + <if test="headline != null">#{headline},</if> | ||
| 48 | + <if test="writer != null">#{writer},</if> | ||
| 49 | + <if test="writeTime != null">#{writeTime},</if> | ||
| 50 | + <if test="content != null">#{content},</if> | ||
| 51 | + <if test="begintime != null">#{begintime},</if> | ||
| 52 | + <if test="endtime != null">#{endtime},</if> | ||
| 53 | + 1 | ||
| 54 | + </trim> | ||
| 55 | + </insert> | ||
| 56 | + | ||
| 57 | + <update id="updateDaily" parameterType="PeriodicReport"> | ||
| 58 | + update periodic_report | ||
| 59 | + <trim prefix="SET" suffixOverrides=","> | ||
| 60 | + <if test="headline != null">headline = #{headline},</if> | ||
| 61 | + <if test="writer != null">writer = #{writer},</if> | ||
| 62 | + <if test="writeTime != null">write_time = #{writeTime},</if> | ||
| 63 | + <if test="content != null">content = #{content},</if> | ||
| 64 | + <if test="begintime != null">beginTime = #{begintime},</if> | ||
| 65 | + <if test="endtime != null">endTime = #{endtime},</if> | ||
| 66 | + <if test="contentType != null">content_type = #{contentType},</if> | ||
| 67 | + </trim> | ||
| 68 | + where id = #{id} | ||
| 69 | + </update> | ||
| 70 | + | ||
| 71 | + <delete id="deleteDailyById" parameterType="Long"> | ||
| 72 | + delete from periodic_report where id = #{id} | ||
| 73 | + </delete> | ||
| 74 | + | ||
| 75 | + <delete id="deleteDailyByIds" parameterType="String"> | ||
| 76 | + delete from periodic_report where id in | ||
| 77 | + <foreach item="id" collection="array" open="(" separator="," close=")"> | ||
| 78 | + #{id} | ||
| 79 | + </foreach> | ||
| 80 | + </delete> | ||
| 81 | +</mapper> | ||
| 0 | \ No newline at end of file | 82 | \ No newline at end of file |
trash-daily/src/main/resources/mapper/information_sharing/InformationSharingMapper.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8" ?> | ||
| 2 | +<!DOCTYPE mapper | ||
| 3 | +PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
| 4 | +"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||
| 5 | +<mapper namespace="com.trash.information_sharing.mapper.InformationSharingMapper"> | ||
| 6 | + | ||
| 7 | + <resultMap type="InformationSharing" id="InformationSharingResult"> | ||
| 8 | + <result property="id" column="id" /> | ||
| 9 | + <result property="dataHeader" column="data_header" /> | ||
| 10 | + <result property="retrieveDepartment" column="retrieve_department" /> | ||
| 11 | + <result property="retrieveTime" column="retrieve_time" /> | ||
| 12 | + <result property="retrieveContent" column="retrieve_content" /> | ||
| 13 | + <result property="attachmentLink" column="attachment_link" /> | ||
| 14 | + <result property="informationLink" column="information_link" /> | ||
| 15 | + </resultMap> | ||
| 16 | + | ||
| 17 | + <sql id="selectInformationSharingVo"> | ||
| 18 | + select id, data_header, retrieve_department, retrieve_time, retrieve_content, attachment_link, information_link from information_sharing | ||
| 19 | + </sql> | ||
| 20 | + | ||
| 21 | + <select id="selectInformationSharingList" parameterType="InformationSharing" resultMap="InformationSharingResult"> | ||
| 22 | + <include refid="selectInformationSharingVo"/> | ||
| 23 | + <where> | ||
| 24 | + <if test="dataHeader != null and dataHeader != ''"> and data_header like concat('%', #{dataHeader}, '%')</if> | ||
| 25 | + <if test="retrieveDepartment != null and retrieveDepartment != ''"> and retrieve_department like concat('%', #{retrieveDepartment}, '%')</if> | ||
| 26 | + </where> | ||
| 27 | + </select> | ||
| 28 | + | ||
| 29 | + <select id="selectInformationSharingById" parameterType="Long" resultMap="InformationSharingResult"> | ||
| 30 | + <include refid="selectInformationSharingVo"/> | ||
| 31 | + where id = #{id} | ||
| 32 | + </select> | ||
| 33 | + | ||
| 34 | + <insert id="insertInformationSharing" parameterType="InformationSharing" useGeneratedKeys="true" keyProperty="id"> | ||
| 35 | + insert into information_sharing | ||
| 36 | + <trim prefix="(" suffix=")" suffixOverrides=","> | ||
| 37 | + <if test="dataHeader != null">data_header,</if> | ||
| 38 | + <if test="retrieveDepartment != null">retrieve_department,</if> | ||
| 39 | + <if test="retrieveTime != null">retrieve_time,</if> | ||
| 40 | + <if test="retrieveContent != null">retrieve_content,</if> | ||
| 41 | + <if test="attachmentLink != null">attachment_link,</if> | ||
| 42 | + <if test="informationLink != null">information_link,</if> | ||
| 43 | + </trim> | ||
| 44 | + <trim prefix="values (" suffix=")" suffixOverrides=","> | ||
| 45 | + <if test="dataHeader != null">#{dataHeader},</if> | ||
| 46 | + <if test="retrieveDepartment != null">#{retrieveDepartment},</if> | ||
| 47 | + <if test="retrieveTime != null">#{retrieveTime},</if> | ||
| 48 | + <if test="retrieveContent != null">#{retrieveContent},</if> | ||
| 49 | + <if test="attachmentLink != null">#{attachmentLink},</if> | ||
| 50 | + <if test="informationLink != null">#{informationLink},</if> | ||
| 51 | + </trim> | ||
| 52 | + </insert> | ||
| 53 | + | ||
| 54 | + <update id="updateInformationSharing" parameterType="InformationSharing"> | ||
| 55 | + update information_sharing | ||
| 56 | + <trim prefix="SET" suffixOverrides=","> | ||
| 57 | + <if test="dataHeader != null">data_header = #{dataHeader},</if> | ||
| 58 | + <if test="retrieveDepartment != null">retrieve_department = #{retrieveDepartment},</if> | ||
| 59 | + <if test="retrieveTime != null">retrieve_time = #{retrieveTime},</if> | ||
| 60 | + <if test="retrieveContent != null">retrieve_content = #{retrieveContent},</if> | ||
| 61 | + <if test="attachmentLink != null">attachment_link = #{attachmentLink},</if> | ||
| 62 | + <if test="informationLink != null">information_link = #{informationLink},</if> | ||
| 63 | + </trim> | ||
| 64 | + where id = #{id} | ||
| 65 | + </update> | ||
| 66 | + | ||
| 67 | + <delete id="deleteInformationSharingById" parameterType="Long"> | ||
| 68 | + delete from information_sharing where id = #{id} | ||
| 69 | + </delete> | ||
| 70 | + | ||
| 71 | + <delete id="deleteInformationSharingByIds" parameterType="String"> | ||
| 72 | + delete from information_sharing where id in | ||
| 73 | + <foreach item="id" collection="array" open="(" separator="," close=")"> | ||
| 74 | + #{id} | ||
| 75 | + </foreach> | ||
| 76 | + </delete> | ||
| 77 | + | ||
| 78 | +</mapper> | ||
| 0 | \ No newline at end of file | 79 | \ No newline at end of file |
trash-daily/src/main/resources/mapper/monthly/MonthlyReportMapper.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8" ?> | ||
| 2 | +<!DOCTYPE mapper | ||
| 3 | + PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
| 4 | + "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||
| 5 | +<mapper namespace="com.trash.monthly.mapper.MonthlyReportMapper"> | ||
| 6 | + | ||
| 7 | + <resultMap type="PeriodicReport" id="PeriodicReportResult"> | ||
| 8 | + <result property="id" column="id" /> | ||
| 9 | + <result property="headline" column="headline" /> | ||
| 10 | + <result property="writer" column="writer" /> | ||
| 11 | + <result property="writeTime" column="write_time" /> | ||
| 12 | + <result property="content" column="content" /> | ||
| 13 | + <result property="begintime" column="beginTime" /> | ||
| 14 | + <result property="endtime" column="endTime" /> | ||
| 15 | + <result property="contentType" column="content_type" /> | ||
| 16 | + </resultMap> | ||
| 17 | + | ||
| 18 | + <sql id="selectMonthlyReportVo"> | ||
| 19 | + select id, headline, writer, write_time, content, beginTime, endTime, content_type from periodic_report | ||
| 20 | + </sql> | ||
| 21 | + | ||
| 22 | + <select id="selectMonthlyReportList" parameterType="PeriodicReport" resultMap="PeriodicReportResult"> | ||
| 23 | + <include refid="selectMonthlyReportVo"/> | ||
| 24 | + <where> | ||
| 25 | + <if test="headline != null and headline != ''"> and headline = #{headline}</if> | ||
| 26 | + and content_type = 3 | ||
| 27 | + </where> | ||
| 28 | + </select> | ||
| 29 | + | ||
| 30 | + <select id="selectMonthlyReportById" parameterType="Long" resultMap="PeriodicReportResult"> | ||
| 31 | + <include refid="selectMonthlyReportVo"/> | ||
| 32 | + where id = #{id} | ||
| 33 | + </select> | ||
| 34 | + | ||
| 35 | + <insert id="insertMonthlyReport" parameterType="PeriodicReport" useGeneratedKeys="true" keyProperty="id"> | ||
| 36 | + insert into periodic_report | ||
| 37 | + <trim prefix="(" suffix=")" suffixOverrides=","> | ||
| 38 | + <if test="headline != null">headline,</if> | ||
| 39 | + <if test="writer != null">writer,</if> | ||
| 40 | + <if test="writeTime != null">write_time,</if> | ||
| 41 | + <if test="content != null">content,</if> | ||
| 42 | + <if test="begintime != null">beginTime,</if> | ||
| 43 | + <if test="endtime != null">endTime,</if> | ||
| 44 | + content_type | ||
| 45 | + </trim> | ||
| 46 | + <trim prefix="values (" suffix=")" suffixOverrides=","> | ||
| 47 | + <if test="headline != null">#{headline},</if> | ||
| 48 | + <if test="writer != null">#{writer},</if> | ||
| 49 | + <if test="writeTime != null">#{writeTime},</if> | ||
| 50 | + <if test="content != null">#{content},</if> | ||
| 51 | + <if test="begintime != null">#{begintime},</if> | ||
| 52 | + <if test="endtime != null">#{endtime},</if> | ||
| 53 | + 3 | ||
| 54 | + </trim> | ||
| 55 | + </insert> | ||
| 56 | + | ||
| 57 | + <update id="updateMonthlyReport" parameterType="PeriodicReport"> | ||
| 58 | + update periodic_report | ||
| 59 | + <trim prefix="SET" suffixOverrides=","> | ||
| 60 | + <if test="headline != null">headline = #{headline},</if> | ||
| 61 | + <if test="writer != null">writer = #{writer},</if> | ||
| 62 | + <if test="writeTime != null">write_time = #{writeTime},</if> | ||
| 63 | + <if test="content != null">content = #{content},</if> | ||
| 64 | + <if test="begintime != null">beginTime = #{begintime},</if> | ||
| 65 | + <if test="endtime != null">endTime = #{endtime},</if> | ||
| 66 | + <if test="contentType != null">content_type = #{contentType},</if> | ||
| 67 | + </trim> | ||
| 68 | + where id = #{id} | ||
| 69 | + </update> | ||
| 70 | + | ||
| 71 | + <delete id="deleteMonthlyReportById" parameterType="Long"> | ||
| 72 | + delete from periodic_report where id = #{id} | ||
| 73 | + </delete> | ||
| 74 | + | ||
| 75 | + <delete id="deleteMonthlyReportByIds" parameterType="String"> | ||
| 76 | + delete from periodic_report where id in | ||
| 77 | + <foreach item="id" collection="array" open="(" separator="," close=")"> | ||
| 78 | + #{id} | ||
| 79 | + </foreach> | ||
| 80 | + </delete> | ||
| 81 | + | ||
| 82 | +</mapper> | ||
| 0 | \ No newline at end of file | 83 | \ No newline at end of file |
trash-daily/src/main/resources/mapper/report/WorkReportMapper.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8" ?> | ||
| 2 | +<!DOCTYPE mapper | ||
| 3 | +PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
| 4 | +"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||
| 5 | +<mapper namespace="com.trash.report.mapper.WorkReportMapper"> | ||
| 6 | + | ||
| 7 | + <resultMap type="WorkReport" id="WorkReportResult"> | ||
| 8 | + <result property="id" column="id" /> | ||
| 9 | + <result property="weeklyTitle" column="weekly_title" /> | ||
| 10 | + <result property="writer" column="writer" /> | ||
| 11 | + <result property="writeTime" column="write_time" /> | ||
| 12 | + <result property="reportContent" column="report_content" /> | ||
| 13 | + </resultMap> | ||
| 14 | + | ||
| 15 | + <sql id="selectWorkReportVo"> | ||
| 16 | + select id, weekly_title, writer, write_time, report_content from work_report | ||
| 17 | + </sql> | ||
| 18 | + | ||
| 19 | + <select id="selectWorkReportList" parameterType="WorkReport" resultMap="WorkReportResult"> | ||
| 20 | + <include refid="selectWorkReportVo"/> | ||
| 21 | + <where> | ||
| 22 | + <if test="weeklyTitle != null and weeklyTitle != ''"> and weekly_title = #{weeklyTitle}</if> | ||
| 23 | + </where> | ||
| 24 | + </select> | ||
| 25 | + | ||
| 26 | + <select id="selectWorkReportById" parameterType="Long" resultMap="WorkReportResult"> | ||
| 27 | + <include refid="selectWorkReportVo"/> | ||
| 28 | + where id = #{id} | ||
| 29 | + </select> | ||
| 30 | + | ||
| 31 | + <insert id="insertWorkReport" parameterType="WorkReport" useGeneratedKeys="true" keyProperty="id"> | ||
| 32 | + insert into work_report | ||
| 33 | + <trim prefix="(" suffix=")" suffixOverrides=","> | ||
| 34 | + <if test="weeklyTitle != null and weeklyTitle != ''">weekly_title,</if> | ||
| 35 | + <if test="writer != null and writer != ''">writer,</if> | ||
| 36 | + <if test="writeTime != null">write_time,</if> | ||
| 37 | + <if test="reportContent != null and reportContent != ''">report_content,</if> | ||
| 38 | + </trim> | ||
| 39 | + <trim prefix="values (" suffix=")" suffixOverrides=","> | ||
| 40 | + <if test="weeklyTitle != null and weeklyTitle != ''">#{weeklyTitle},</if> | ||
| 41 | + <if test="writer != null and writer != ''">#{writer},</if> | ||
| 42 | + <if test="writeTime != null">#{writeTime},</if> | ||
| 43 | + <if test="reportContent != null and reportContent != ''">#{reportContent},</if> | ||
| 44 | + </trim> | ||
| 45 | + </insert> | ||
| 46 | + | ||
| 47 | + <update id="updateWorkReport" parameterType="WorkReport"> | ||
| 48 | + update work_report | ||
| 49 | + <trim prefix="SET" suffixOverrides=","> | ||
| 50 | + <if test="weeklyTitle != null and weeklyTitle != ''">weekly_title = #{weeklyTitle},</if> | ||
| 51 | + <if test="writer != null and writer != ''">writer = #{writer},</if> | ||
| 52 | + <if test="writeTime != null">write_time = #{writeTime},</if> | ||
| 53 | + <if test="reportContent != null and reportContent != ''">report_content = #{reportContent},</if> | ||
| 54 | + </trim> | ||
| 55 | + where id = #{id} | ||
| 56 | + </update> | ||
| 57 | + | ||
| 58 | + <delete id="deleteWorkReportById" parameterType="Long"> | ||
| 59 | + delete from work_report where id = #{id} | ||
| 60 | + </delete> | ||
| 61 | + | ||
| 62 | + <delete id="deleteWorkReportByIds" parameterType="String"> | ||
| 63 | + delete from work_report where id in | ||
| 64 | + <foreach item="id" collection="array" open="(" separator="," close=")"> | ||
| 65 | + #{id} | ||
| 66 | + </foreach> | ||
| 67 | + </delete> | ||
| 68 | + | ||
| 69 | +</mapper> | ||
| 0 | \ No newline at end of file | 70 | \ No newline at end of file |
trash-daily/src/main/resources/mapper/situation/DailySituationMapper.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8" ?> | ||
| 2 | +<!DOCTYPE mapper | ||
| 3 | +PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
| 4 | +"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||
| 5 | +<mapper namespace="com.trash.situation.mapper.DailySituationMapper"> | ||
| 6 | + | ||
| 7 | + <resultMap type="DailySituation" id="DailySituationResult"> | ||
| 8 | + <result property="id" column="id" /> | ||
| 9 | + <result property="title" column="title" /> | ||
| 10 | + <result property="operator" column="operator" /> | ||
| 11 | + <result property="date" column="date" /> | ||
| 12 | + <result property="weather" column="weather" /> | ||
| 13 | + <result property="consumptionSiteSituation" column="Consumption_site_situation" /> | ||
| 14 | + <result property="numberOfVehicles" column="Number_of_vehicles" /> | ||
| 15 | + <result property="createTime" column="create_time" /> | ||
| 16 | + <result property="updateTime" column="update_time" /> | ||
| 17 | + </resultMap> | ||
| 18 | + | ||
| 19 | + <sql id="selectDailySituationVo"> | ||
| 20 | + select id, title, operator, date, weather, Consumption_site_situation, Number_of_vehicles, create_time, update_time from daily_situation | ||
| 21 | + </sql> | ||
| 22 | + | ||
| 23 | + <select id="selectDailySituationList" parameterType="DailySituation" resultMap="DailySituationResult"> | ||
| 24 | + <include refid="selectDailySituationVo"/> | ||
| 25 | + <where> | ||
| 26 | + <if test="title != null and title != ''"> and title like concat('%', #{title}, '%')</if> | ||
| 27 | + <if test="operator != null and operator != ''"> and operator like concat('%', #{operator}, '%')</if> | ||
| 28 | + <if test="updateTime != null "> and update_time = #{updateTime}</if> | ||
| 29 | + </where> | ||
| 30 | + </select> | ||
| 31 | + | ||
| 32 | + <select id="selectDailySituationById" parameterType="String" resultMap="DailySituationResult"> | ||
| 33 | + <include refid="selectDailySituationVo"/> | ||
| 34 | + where id = #{id} | ||
| 35 | + </select> | ||
| 36 | + | ||
| 37 | + <insert id="insertDailySituation" parameterType="DailySituation"> | ||
| 38 | + insert into daily_situation | ||
| 39 | + <trim prefix="(" suffix=")" suffixOverrides=","> | ||
| 40 | + <if test="id != null and id != ''">id,</if> | ||
| 41 | + <if test="title != null">title,</if> | ||
| 42 | + <if test="operator != null">operator,</if> | ||
| 43 | + <if test="date != null">date,</if> | ||
| 44 | + <if test="weather != null">weather,</if> | ||
| 45 | + <if test="consumptionSiteSituation != null">Consumption_site_situation,</if> | ||
| 46 | + <if test="numberOfVehicles != null">Number_of_vehicles,</if> | ||
| 47 | + <if test="createTime != null">create_time,</if> | ||
| 48 | + <if test="updateTime != null">update_time,</if> | ||
| 49 | + </trim> | ||
| 50 | + <trim prefix="values (" suffix=")" suffixOverrides=","> | ||
| 51 | + <if test="id != null and id != ''">#{id},</if> | ||
| 52 | + <if test="title != null">#{title},</if> | ||
| 53 | + <if test="operator != null">#{operator},</if> | ||
| 54 | + <if test="date != null">#{date},</if> | ||
| 55 | + <if test="weather != null">#{weather},</if> | ||
| 56 | + <if test="consumptionSiteSituation != null">#{consumptionSiteSituation},</if> | ||
| 57 | + <if test="numberOfVehicles != null">#{numberOfVehicles},</if> | ||
| 58 | + <if test="createTime != null">#{createTime},</if> | ||
| 59 | + <if test="updateTime != null">#{updateTime},</if> | ||
| 60 | + </trim> | ||
| 61 | + </insert> | ||
| 62 | + | ||
| 63 | + <update id="updateDailySituation" parameterType="DailySituation"> | ||
| 64 | + update daily_situation | ||
| 65 | + <trim prefix="SET" suffixOverrides=","> | ||
| 66 | + <if test="title != null">title = #{title},</if> | ||
| 67 | + <if test="operator != null">operator = #{operator},</if> | ||
| 68 | + <if test="date != null">date = #{date},</if> | ||
| 69 | + <if test="weather != null">weather = #{weather},</if> | ||
| 70 | + <if test="consumptionSiteSituation != null">Consumption_site_situation = #{consumptionSiteSituation},</if> | ||
| 71 | + <if test="numberOfVehicles != null">Number_of_vehicles = #{numberOfVehicles},</if> | ||
| 72 | + <if test="createTime != null">create_time = #{createTime},</if> | ||
| 73 | + <if test="updateTime != null">update_time = #{updateTime},</if> | ||
| 74 | + </trim> | ||
| 75 | + where id = #{id} | ||
| 76 | + </update> | ||
| 77 | + | ||
| 78 | + <delete id="deleteDailySituationById" parameterType="String"> | ||
| 79 | + delete from daily_situation where id = #{id} | ||
| 80 | + </delete> | ||
| 81 | + | ||
| 82 | + <delete id="deleteDailySituationByIds" parameterType="String"> | ||
| 83 | + delete from daily_situation where id in | ||
| 84 | + <foreach item="id" collection="array" open="(" separator="," close=")"> | ||
| 85 | + #{id} | ||
| 86 | + </foreach> | ||
| 87 | + </delete> | ||
| 88 | + | ||
| 89 | +</mapper> | ||
| 0 | \ No newline at end of file | 90 | \ No newline at end of file |
trash-daily/src/main/resources/mapper/toollist/DailyToolListMapper.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8" ?> | ||
| 2 | +<!DOCTYPE mapper | ||
| 3 | +PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
| 4 | +"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||
| 5 | +<mapper namespace="com.trash.toollist.mapper.DailyToolListMapper"> | ||
| 6 | + | ||
| 7 | + <resultMap type="DailyToolList" id="DailyToolListResult"> | ||
| 8 | + <result property="id" column="id" /> | ||
| 9 | + <result property="title" column="title" /> | ||
| 10 | + <result property="region" column="region" /> | ||
| 11 | + <result property="operator" column="operator" /> | ||
| 12 | + <result property="date" column="date" /> | ||
| 13 | + <result property="numberOfConstructionSites" column="Number_of_construction_sites" /> | ||
| 14 | + <result property="censusStructure" column="Census_structure" /> | ||
| 15 | + <result property="managementLeader" column="Management_leader" /> | ||
| 16 | + <result property="lawEnforcementOfficer" column="Law_enforcement_officer" /> | ||
| 17 | + <result property="specificSituationOfTheCensus" column="Specific_situation_of_the_census" /> | ||
| 18 | + </resultMap> | ||
| 19 | + | ||
| 20 | + <sql id="selectDailyToolListVo"> | ||
| 21 | + select id, title, region, operator, date, Number_of_construction_sites, Census_structure, Management_leader, Law_enforcement_officer, Specific_situation_of_the_census from daily_tool_list | ||
| 22 | + </sql> | ||
| 23 | + | ||
| 24 | + <select id="selectDailyToolListList" parameterType="DailyToolList" resultMap="DailyToolListResult"> | ||
| 25 | + <include refid="selectDailyToolListVo"/> | ||
| 26 | + <where> | ||
| 27 | + <if test="title != null and title != ''"> and title like concat('%', #{title}, '%')</if> | ||
| 28 | + <if test="operator != null and operator != ''"> and operator like concat('%', #{operator}, '%')</if> | ||
| 29 | + </where> | ||
| 30 | + </select> | ||
| 31 | + | ||
| 32 | + <select id="selectDailyToolListById" parameterType="Long" resultMap="DailyToolListResult"> | ||
| 33 | + <include refid="selectDailyToolListVo"/> | ||
| 34 | + where id = #{id} | ||
| 35 | + </select> | ||
| 36 | + | ||
| 37 | + <insert id="insertDailyToolList" parameterType="DailyToolList" useGeneratedKeys="true" keyProperty="id"> | ||
| 38 | + insert into daily_tool_list | ||
| 39 | + <trim prefix="(" suffix=")" suffixOverrides=","> | ||
| 40 | + <if test="title != null">title,</if> | ||
| 41 | + <if test="region != null">region,</if> | ||
| 42 | + <if test="operator != null">operator,</if> | ||
| 43 | + <if test="date != null">date,</if> | ||
| 44 | + <if test="numberOfConstructionSites != null">Number_of_construction_sites,</if> | ||
| 45 | + <if test="censusStructure != null">Census_structure,</if> | ||
| 46 | + <if test="managementLeader != null">Management_leader,</if> | ||
| 47 | + <if test="lawEnforcementOfficer != null">Law_enforcement_officer,</if> | ||
| 48 | + <if test="specificSituationOfTheCensus != null">Specific_situation_of_the_census,</if> | ||
| 49 | + </trim> | ||
| 50 | + <trim prefix="values (" suffix=")" suffixOverrides=","> | ||
| 51 | + <if test="title != null">#{title},</if> | ||
| 52 | + <if test="region != null">#{region},</if> | ||
| 53 | + <if test="operator != null">#{operator},</if> | ||
| 54 | + <if test="date != null">#{date},</if> | ||
| 55 | + <if test="numberOfConstructionSites != null">#{numberOfConstructionSites},</if> | ||
| 56 | + <if test="censusStructure != null">#{censusStructure},</if> | ||
| 57 | + <if test="managementLeader != null">#{managementLeader},</if> | ||
| 58 | + <if test="lawEnforcementOfficer != null">#{lawEnforcementOfficer},</if> | ||
| 59 | + <if test="specificSituationOfTheCensus != null">#{specificSituationOfTheCensus},</if> | ||
| 60 | + </trim> | ||
| 61 | + </insert> | ||
| 62 | + | ||
| 63 | + <update id="updateDailyToolList" parameterType="DailyToolList"> | ||
| 64 | + update daily_tool_list | ||
| 65 | + <trim prefix="SET" suffixOverrides=","> | ||
| 66 | + <if test="title != null">title = #{title},</if> | ||
| 67 | + <if test="region != null">region = #{region},</if> | ||
| 68 | + <if test="operator != null">operator = #{operator},</if> | ||
| 69 | + <if test="date != null">date = #{date},</if> | ||
| 70 | + <if test="numberOfConstructionSites != null">Number_of_construction_sites = #{numberOfConstructionSites},</if> | ||
| 71 | + <if test="censusStructure != null">Census_structure = #{censusStructure},</if> | ||
| 72 | + <if test="managementLeader != null">Management_leader = #{managementLeader},</if> | ||
| 73 | + <if test="lawEnforcementOfficer != null">Law_enforcement_officer = #{lawEnforcementOfficer},</if> | ||
| 74 | + <if test="specificSituationOfTheCensus != null">Specific_situation_of_the_census = #{specificSituationOfTheCensus},</if> | ||
| 75 | + </trim> | ||
| 76 | + where id = #{id} | ||
| 77 | + </update> | ||
| 78 | + | ||
| 79 | + <delete id="deleteDailyToolListById" parameterType="Long"> | ||
| 80 | + delete from daily_tool_list where id = #{id} | ||
| 81 | + </delete> | ||
| 82 | + | ||
| 83 | + <delete id="deleteDailyToolListByIds" parameterType="String"> | ||
| 84 | + delete from daily_tool_list where id in | ||
| 85 | + <foreach item="id" collection="array" open="(" separator="," close=")"> | ||
| 86 | + #{id} | ||
| 87 | + </foreach> | ||
| 88 | + </delete> | ||
| 89 | + | ||
| 90 | +</mapper> | ||
| 0 | \ No newline at end of file | 91 | \ No newline at end of file |
trash-daily/src/main/resources/mapper/weekly/WeeklyMapper.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8" ?> | ||
| 2 | +<!DOCTYPE mapper | ||
| 3 | + PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
| 4 | + "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | ||
| 5 | +<mapper namespace="com.trash.weekly.mapper.WeeklyMapper"> | ||
| 6 | + | ||
| 7 | + <resultMap type="PeriodicReport" id="PeriodicReportResult"> | ||
| 8 | + <result property="id" column="id" /> | ||
| 9 | + <result property="headline" column="headline" /> | ||
| 10 | + <result property="writer" column="writer" /> | ||
| 11 | + <result property="writeTime" column="write_time" /> | ||
| 12 | + <result property="content" column="content" /> | ||
| 13 | + <result property="begintime" column="beginTime" /> | ||
| 14 | + <result property="endtime" column="endTime" /> | ||
| 15 | + <result property="contentType" column="content_type" /> | ||
| 16 | + </resultMap> | ||
| 17 | + | ||
| 18 | + <sql id="selectWeeklyVo"> | ||
| 19 | + select id, headline, writer, write_time, content, beginTime, endTime, content_type from periodic_report | ||
| 20 | + </sql> | ||
| 21 | + | ||
| 22 | + <select id="selectWeeklyList" parameterType="PeriodicReport" resultMap="PeriodicReportResult"> | ||
| 23 | + <include refid="selectWeeklyVo"/> | ||
| 24 | + <where> | ||
| 25 | + <if test="headline != null and headline != ''"> and headline = #{headline}</if> | ||
| 26 | + and content_type = 2 | ||
| 27 | + </where> | ||
| 28 | + </select> | ||
| 29 | + | ||
| 30 | + <select id="selectWeeklyById" parameterType="Long" resultMap="PeriodicReportResult"> | ||
| 31 | + <include refid="selectWeeklyVo"/> | ||
| 32 | + where id = #{id} | ||
| 33 | + </select> | ||
| 34 | + | ||
| 35 | + <insert id="insertWeekly" parameterType="PeriodicReport" useGeneratedKeys="true" keyProperty="id"> | ||
| 36 | + insert into periodic_report | ||
| 37 | + <trim prefix="(" suffix=")" suffixOverrides=","> | ||
| 38 | + <if test="headline != null">headline,</if> | ||
| 39 | + <if test="writer != null">writer,</if> | ||
| 40 | + <if test="writeTime != null">write_time,</if> | ||
| 41 | + <if test="content != null">content,</if> | ||
| 42 | + <if test="begintime != null">beginTime,</if> | ||
| 43 | + <if test="endtime != null">endTime,</if> | ||
| 44 | + content_type | ||
| 45 | + </trim> | ||
| 46 | + <trim prefix="values (" suffix=")" suffixOverrides=","> | ||
| 47 | + <if test="headline != null">#{headline},</if> | ||
| 48 | + <if test="writer != null">#{writer},</if> | ||
| 49 | + <if test="writeTime != null">#{writeTime},</if> | ||
| 50 | + <if test="content != null">#{content},</if> | ||
| 51 | + <if test="begintime != null">#{begintime},</if> | ||
| 52 | + <if test="endtime != null">#{endtime},</if> | ||
| 53 | + 2 | ||
| 54 | + </trim> | ||
| 55 | + </insert> | ||
| 56 | + | ||
| 57 | + <update id="updateWeekly" parameterType="PeriodicReport"> | ||
| 58 | + update periodic_report | ||
| 59 | + <trim prefix="SET" suffixOverrides=","> | ||
| 60 | + <if test="headline != null">headline = #{headline},</if> | ||
| 61 | + <if test="writer != null">writer = #{writer},</if> | ||
| 62 | + <if test="writeTime != null">write_time = #{writeTime},</if> | ||
| 63 | + <if test="content != null">content = #{content},</if> | ||
| 64 | + <if test="begintime != null">beginTime = #{begintime},</if> | ||
| 65 | + <if test="endtime != null">endTime = #{endtime},</if> | ||
| 66 | + <if test="contentType != null">content_type = #{contentType},</if> | ||
| 67 | + </trim> | ||
| 68 | + where id = #{id} | ||
| 69 | + </update> | ||
| 70 | + | ||
| 71 | + <delete id="deleteWeeklyById" parameterType="Long"> | ||
| 72 | + delete from periodic_report where id = #{id} | ||
| 73 | + </delete> | ||
| 74 | + | ||
| 75 | + <delete id="deleteWeeklyByIds" parameterType="String"> | ||
| 76 | + delete from periodic_report where id in | ||
| 77 | + <foreach item="id" collection="array" open="(" separator="," close=")"> | ||
| 78 | + #{id} | ||
| 79 | + </foreach> | ||
| 80 | + </delete> | ||
| 81 | + | ||
| 82 | +</mapper> | ||
| 0 | \ No newline at end of file | 83 | \ No newline at end of file |
trash-ui/src/api/daily/daily.js
0 → 100644
| 1 | +import request from '@/utils/request' | ||
| 2 | + | ||
| 3 | +// 查询日报列表 | ||
| 4 | +export function listDaily(query) { | ||
| 5 | + return request({ | ||
| 6 | + url: '/report/daily/list', | ||
| 7 | + method: 'get', | ||
| 8 | + params: query | ||
| 9 | + }) | ||
| 10 | +} | ||
| 11 | + | ||
| 12 | +// 查询日报详细 | ||
| 13 | +export function getDaily(id) { | ||
| 14 | + return request({ | ||
| 15 | + url: '/report/daily/' + id, | ||
| 16 | + method: 'get' | ||
| 17 | + }) | ||
| 18 | +} | ||
| 19 | + | ||
| 20 | +// 新增日报 | ||
| 21 | +export function addDaily(data) { | ||
| 22 | + return request({ | ||
| 23 | + url: '/report/daily', | ||
| 24 | + method: 'post', | ||
| 25 | + data: data | ||
| 26 | + }) | ||
| 27 | +} | ||
| 28 | + | ||
| 29 | +// 修改日报 | ||
| 30 | +export function updateDaily(data) { | ||
| 31 | + return request({ | ||
| 32 | + url: '/report/daily', | ||
| 33 | + method: 'put', | ||
| 34 | + data: data | ||
| 35 | + }) | ||
| 36 | +} | ||
| 37 | + | ||
| 38 | +// 删除日报 | ||
| 39 | +export function delDaily(id) { | ||
| 40 | + return request({ | ||
| 41 | + url: '/report/daily/' + id, | ||
| 42 | + method: 'delete' | ||
| 43 | + }) | ||
| 44 | +} | ||
| 45 | + | ||
| 46 | +// 导出日报 | ||
| 47 | +export function exportDaily(query) { | ||
| 48 | + return request({ | ||
| 49 | + url: '/report/daily/export', | ||
| 50 | + method: 'get', | ||
| 51 | + params: query | ||
| 52 | + }) | ||
| 53 | +} |
trash-ui/src/api/daily/information_sharing.js
0 → 100644
| 1 | +import request from '@/utils/request' | ||
| 2 | + | ||
| 3 | +// 查询信息共享列表 | ||
| 4 | +export function listInformation_sharing(query) { | ||
| 5 | + return request({ | ||
| 6 | + url: '/daily/information_sharing/list', | ||
| 7 | + method: 'get', | ||
| 8 | + params: query | ||
| 9 | + }) | ||
| 10 | +} | ||
| 11 | + | ||
| 12 | +// 查询信息共享详细 | ||
| 13 | +export function getInformation_sharing(id) { | ||
| 14 | + return request({ | ||
| 15 | + url: '/daily/information_sharing/' + id, | ||
| 16 | + method: 'get' | ||
| 17 | + }) | ||
| 18 | +} | ||
| 19 | + | ||
| 20 | +// 新增信息共享 | ||
| 21 | +export function addInformation_sharing(data) { | ||
| 22 | + return request({ | ||
| 23 | + url: '/daily/information_sharing', | ||
| 24 | + method: 'post', | ||
| 25 | + data: data | ||
| 26 | + }) | ||
| 27 | +} | ||
| 28 | + | ||
| 29 | +// 修改信息共享 | ||
| 30 | +export function updateInformation_sharing(data) { | ||
| 31 | + return request({ | ||
| 32 | + url: '/daily/information_sharing', | ||
| 33 | + method: 'put', | ||
| 34 | + data: data | ||
| 35 | + }) | ||
| 36 | +} | ||
| 37 | + | ||
| 38 | +// 删除信息共享 | ||
| 39 | +export function delInformation_sharing(id) { | ||
| 40 | + return request({ | ||
| 41 | + url: '/daily/information_sharing/' + id, | ||
| 42 | + method: 'delete' | ||
| 43 | + }) | ||
| 44 | +} | ||
| 45 | + | ||
| 46 | +// 导出信息共享 | ||
| 47 | +export function exportInformation_sharing(query) { | ||
| 48 | + return request({ | ||
| 49 | + url: '/daily/information_sharing/export', | ||
| 50 | + method: 'get', | ||
| 51 | + params: query | ||
| 52 | + }) | ||
| 53 | +} |
trash-ui/src/api/daily/monthly.js
0 → 100644
| 1 | +import request from '@/utils/request' | ||
| 2 | + | ||
| 3 | +// 查询月报列表 | ||
| 4 | +export function listMonthly(query) { | ||
| 5 | + return request({ | ||
| 6 | + url: '/report/monthly/list', | ||
| 7 | + method: 'get', | ||
| 8 | + params: query | ||
| 9 | + }) | ||
| 10 | +} | ||
| 11 | + | ||
| 12 | +// 查询月报详细 | ||
| 13 | +export function getMonthly(id) { | ||
| 14 | + return request({ | ||
| 15 | + url: '/report/monthly/' + id, | ||
| 16 | + method: 'get' | ||
| 17 | + }) | ||
| 18 | +} | ||
| 19 | + | ||
| 20 | +// 新增月报 | ||
| 21 | +export function addMonthly(data) { | ||
| 22 | + return request({ | ||
| 23 | + url: '/report/monthly', | ||
| 24 | + method: 'post', | ||
| 25 | + data: data | ||
| 26 | + }) | ||
| 27 | +} | ||
| 28 | + | ||
| 29 | +// 修改月报 | ||
| 30 | +export function updateMonthly(data) { | ||
| 31 | + return request({ | ||
| 32 | + url: '/report/monthly', | ||
| 33 | + method: 'put', | ||
| 34 | + data: data | ||
| 35 | + }) | ||
| 36 | +} | ||
| 37 | + | ||
| 38 | +// 删除月报 | ||
| 39 | +export function delMonthly(id) { | ||
| 40 | + return request({ | ||
| 41 | + url: '/report/monthly/' + id, | ||
| 42 | + method: 'delete' | ||
| 43 | + }) | ||
| 44 | +} | ||
| 45 | + | ||
| 46 | +// 导出月报 | ||
| 47 | +export function exportMonthly(query) { | ||
| 48 | + return request({ | ||
| 49 | + url: '/report/monthly/export', | ||
| 50 | + method: 'get', | ||
| 51 | + params: query | ||
| 52 | + }) | ||
| 53 | +} |
trash-ui/src/api/daily/report.js
0 → 100644
| 1 | +import request from '@/utils/request' | ||
| 2 | + | ||
| 3 | +// 查询月报列表 | ||
| 4 | +export function listReport(query) { | ||
| 5 | + return request({ | ||
| 6 | + url: '/daily/report/list', | ||
| 7 | + method: 'get', | ||
| 8 | + params: query | ||
| 9 | + }) | ||
| 10 | +} | ||
| 11 | + | ||
| 12 | +// 查询月报详细 | ||
| 13 | +export function getReport(id) { | ||
| 14 | + return request({ | ||
| 15 | + url: '/daily/report/' + id, | ||
| 16 | + method: 'get' | ||
| 17 | + }) | ||
| 18 | +} | ||
| 19 | + | ||
| 20 | +// 新增月报 | ||
| 21 | +export function addReport(data) { | ||
| 22 | + return request({ | ||
| 23 | + url: '/daily/report', | ||
| 24 | + method: 'post', | ||
| 25 | + data: data | ||
| 26 | + }) | ||
| 27 | +} | ||
| 28 | + | ||
| 29 | +// 修改月报 | ||
| 30 | +export function updateReport(data) { | ||
| 31 | + return request({ | ||
| 32 | + url: '/daily/report', | ||
| 33 | + method: 'put', | ||
| 34 | + data: data | ||
| 35 | + }) | ||
| 36 | +} | ||
| 37 | + | ||
| 38 | +// 删除月报 | ||
| 39 | +export function delReport(id) { | ||
| 40 | + return request({ | ||
| 41 | + url: '/daily/report/' + id, | ||
| 42 | + method: 'delete' | ||
| 43 | + }) | ||
| 44 | +} | ||
| 45 | + | ||
| 46 | +// 导出月报 | ||
| 47 | +export function exportReport(query) { | ||
| 48 | + return request({ | ||
| 49 | + url: '/daily/report/export', | ||
| 50 | + method: 'get', | ||
| 51 | + params: query | ||
| 52 | + }) | ||
| 53 | +} |
trash-ui/src/api/daily/situation.js
0 → 100644
| 1 | +import request from '@/utils/request' | ||
| 2 | + | ||
| 3 | +// 查询每日普查情况列表 | ||
| 4 | +export function listSituation(query) { | ||
| 5 | + return request({ | ||
| 6 | + url: '/daily/situation/list', | ||
| 7 | + method: 'get', | ||
| 8 | + params: query | ||
| 9 | + }) | ||
| 10 | +} | ||
| 11 | + | ||
| 12 | +// 查询每日普查情况详细 | ||
| 13 | +export function getSituation(id) { | ||
| 14 | + return request({ | ||
| 15 | + url: '/daily/situation/' + id, | ||
| 16 | + method: 'get' | ||
| 17 | + }) | ||
| 18 | +} | ||
| 19 | + | ||
| 20 | +// 新增每日普查情况 | ||
| 21 | +export function addSituation(data) { | ||
| 22 | + return request({ | ||
| 23 | + url: '/daily/situation', | ||
| 24 | + method: 'post', | ||
| 25 | + data: data | ||
| 26 | + }) | ||
| 27 | +} | ||
| 28 | + | ||
| 29 | +// 修改每日普查情况 | ||
| 30 | +export function updateSituation(data) { | ||
| 31 | + return request({ | ||
| 32 | + url: '/daily/situation', | ||
| 33 | + method: 'put', | ||
| 34 | + data: data | ||
| 35 | + }) | ||
| 36 | +} | ||
| 37 | + | ||
| 38 | +// 删除每日普查情况 | ||
| 39 | +export function delSituation(id) { | ||
| 40 | + return request({ | ||
| 41 | + url: '/daily/situation/' + id, | ||
| 42 | + method: 'delete' | ||
| 43 | + }) | ||
| 44 | +} | ||
| 45 | + | ||
| 46 | +// 导出每日普查情况 | ||
| 47 | +export function exportSituation(query) { | ||
| 48 | + return request({ | ||
| 49 | + url: '/daily/situation/export', | ||
| 50 | + method: 'get', | ||
| 51 | + params: query | ||
| 52 | + }) | ||
| 53 | +} |
trash-ui/src/api/daily/toollist.js
0 → 100644
| 1 | +import request from '@/utils/request' | ||
| 2 | + | ||
| 3 | +// 查询每日工作清单列表 | ||
| 4 | +export function listToollist(query) { | ||
| 5 | + return request({ | ||
| 6 | + url: '/daily/toollist/list', | ||
| 7 | + method: 'get', | ||
| 8 | + params: query | ||
| 9 | + }) | ||
| 10 | +} | ||
| 11 | + | ||
| 12 | +// 查询每日工作清单详细 | ||
| 13 | +export function getToollist(id) { | ||
| 14 | + return request({ | ||
| 15 | + url: '/daily/toollist/' + id, | ||
| 16 | + method: 'get' | ||
| 17 | + }) | ||
| 18 | +} | ||
| 19 | + | ||
| 20 | +// 新增每日工作清单 | ||
| 21 | +export function addToollist(data) { | ||
| 22 | + return request({ | ||
| 23 | + url: '/daily/toollist', | ||
| 24 | + method: 'post', | ||
| 25 | + data: data | ||
| 26 | + }) | ||
| 27 | +} | ||
| 28 | + | ||
| 29 | +// 修改每日工作清单 | ||
| 30 | +export function updateToollist(data) { | ||
| 31 | + return request({ | ||
| 32 | + url: '/daily/toollist', | ||
| 33 | + method: 'put', | ||
| 34 | + data: data | ||
| 35 | + }) | ||
| 36 | +} | ||
| 37 | + | ||
| 38 | +// 删除每日工作清单 | ||
| 39 | +export function delToollist(id) { | ||
| 40 | + return request({ | ||
| 41 | + url: '/daily/toollist/' + id, | ||
| 42 | + method: 'delete' | ||
| 43 | + }) | ||
| 44 | +} | ||
| 45 | + | ||
| 46 | +// 导出每日工作清单 | ||
| 47 | +export function exportToollist(query) { | ||
| 48 | + return request({ | ||
| 49 | + url: '/daily/toollist/export', | ||
| 50 | + method: 'get', | ||
| 51 | + params: query | ||
| 52 | + }) | ||
| 53 | +} |
trash-ui/src/api/daily/weekly.js
0 → 100644
| 1 | +import request from '@/utils/request' | ||
| 2 | + | ||
| 3 | +// 查询周报列表 | ||
| 4 | +export function listWeekly(query) { | ||
| 5 | + return request({ | ||
| 6 | + url: '/report/weekly/list', | ||
| 7 | + method: 'get', | ||
| 8 | + params: query | ||
| 9 | + }) | ||
| 10 | +} | ||
| 11 | + | ||
| 12 | +// 查询周报详细 | ||
| 13 | +export function getWeekly(id) { | ||
| 14 | + return request({ | ||
| 15 | + url: '/report/weekly/' + id, | ||
| 16 | + method: 'get' | ||
| 17 | + }) | ||
| 18 | +} | ||
| 19 | + | ||
| 20 | +// 新增周报 | ||
| 21 | +export function addWeekly(data) { | ||
| 22 | + return request({ | ||
| 23 | + url: '/report/weekly', | ||
| 24 | + method: 'post', | ||
| 25 | + data: data | ||
| 26 | + }) | ||
| 27 | +} | ||
| 28 | + | ||
| 29 | +// 修改周报 | ||
| 30 | +export function updateWeekly(data) { | ||
| 31 | + return request({ | ||
| 32 | + url: '/report/weekly', | ||
| 33 | + method: 'put', | ||
| 34 | + data: data | ||
| 35 | + }) | ||
| 36 | +} | ||
| 37 | + | ||
| 38 | +// 删除周报 | ||
| 39 | +export function delWeekly(id) { | ||
| 40 | + return request({ | ||
| 41 | + url: '/report/weekly/' + id, | ||
| 42 | + method: 'delete' | ||
| 43 | + }) | ||
| 44 | +} | ||
| 45 | + | ||
| 46 | +// 导出周报 | ||
| 47 | +export function exportWeekly(query) { | ||
| 48 | + return request({ | ||
| 49 | + url: '/report/weekly/export', | ||
| 50 | + method: 'get', | ||
| 51 | + params: query | ||
| 52 | + }) | ||
| 53 | +} |
trash-ui/src/views/daily/Weeklys/index.vue
0 → 100644
trash-ui/src/views/daily/daily/index.vue
0 → 100644
| 1 | +<template> | ||
| 2 | + <div class="app-container"> | ||
| 3 | + <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px"> | ||
| 4 | + <el-form-item label="标题" prop="headline"> | ||
| 5 | + <el-input | ||
| 6 | + v-model="queryParams.headline" | ||
| 7 | + placeholder="请输入标题" | ||
| 8 | + clearable | ||
| 9 | + size="small" | ||
| 10 | + @keyup.enter.native="handleQuery" | ||
| 11 | + /> | ||
| 12 | + </el-form-item> | ||
| 13 | + <el-form-item> | ||
| 14 | + <el-button type="cyan" size="mini" @click="handleQuery">搜索</el-button> | ||
| 15 | + </el-form-item> | ||
| 16 | + </el-form> | ||
| 17 | + | ||
| 18 | + <el-row :gutter="10" class="mb8"> | ||
| 19 | + <el-col :span="1.5"> | ||
| 20 | + <el-button | ||
| 21 | + type="primary" | ||
| 22 | + size="mini" | ||
| 23 | + @click="handleAdd" | ||
| 24 | + v-hasPermi="['report:daily:add']" | ||
| 25 | + >新增</el-button> | ||
| 26 | + </el-col> | ||
| 27 | + <el-col :span="1.5"> | ||
| 28 | + <el-button | ||
| 29 | + type="success" | ||
| 30 | + size="mini" | ||
| 31 | + :disabled="single" | ||
| 32 | + @click="handleUpdate" | ||
| 33 | + v-hasPermi="['report:daily:edit']" | ||
| 34 | + >修改</el-button> | ||
| 35 | + </el-col> | ||
| 36 | + <el-col :span="1.5"> | ||
| 37 | + <el-button | ||
| 38 | + type="danger" | ||
| 39 | + size="mini" | ||
| 40 | + :disabled="multiple" | ||
| 41 | + @click="handleDelete" | ||
| 42 | + v-hasPermi="['report:daily:remove']" | ||
| 43 | + >删除</el-button> | ||
| 44 | + </el-col> | ||
| 45 | + <el-col :span="1.5"> | ||
| 46 | + <el-button | ||
| 47 | + type="warning" | ||
| 48 | + size="mini" | ||
| 49 | + @click="handleExport" | ||
| 50 | + v-hasPermi="['report:daily:export']" | ||
| 51 | + >导出</el-button> | ||
| 52 | + </el-col> | ||
| 53 | + <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | ||
| 54 | + </el-row> | ||
| 55 | + | ||
| 56 | + <el-table v-loading="loading" :data="dailyList" @selection-change="handleSelectionChange"> | ||
| 57 | + <el-table-column type="selection" width="55" align="center" /> | ||
| 58 | + <el-table-column label="标题" align="center" prop="headline" /> | ||
| 59 | + <el-table-column label="填写人" align="center" prop="writer" /> | ||
| 60 | + <el-table-column label="填写时间" align="center" prop="writeTime" width="180"> | ||
| 61 | + <template slot-scope="scope"> | ||
| 62 | + <span>{{ parseTime(scope.row.writeTime, '{y}-{m}-{d}') }}</span> | ||
| 63 | + </template> | ||
| 64 | + </el-table-column> | ||
| 65 | + <el-table-column label="操作" align="center" class-name="small-padding fixed-width"> | ||
| 66 | + <template slot-scope="scope"> | ||
| 67 | + <el-button | ||
| 68 | + size="mini" | ||
| 69 | + type="text" | ||
| 70 | + @click="handleById(scope.row)" | ||
| 71 | + v-hasPermi="['report:daily:query']"> | ||
| 72 | + 查看 | ||
| 73 | + </el-button> | ||
| 74 | + </template> | ||
| 75 | + </el-table-column> | ||
| 76 | + </el-table> | ||
| 77 | + | ||
| 78 | + <pagination | ||
| 79 | + v-show="total>0" | ||
| 80 | + :total="total" | ||
| 81 | + :page.sync="queryParams.pageNum" | ||
| 82 | + :limit.sync="queryParams.pageSize" | ||
| 83 | + @pagination="getList" | ||
| 84 | + /> | ||
| 85 | + | ||
| 86 | + <!-- 添加或修改日报对话框 --> | ||
| 87 | + <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body> | ||
| 88 | + <el-form ref="form" :model="form" :rules="rules" label-width="80px"> | ||
| 89 | + <el-form-item label="标题" prop="headline"> | ||
| 90 | + <el-input v-model="form.headline" placeholder="请输入标题" /> | ||
| 91 | + </el-form-item> | ||
| 92 | + <el-form-item label="填写人" prop="writer"> | ||
| 93 | + <el-input v-model="form.writer" placeholder="请输入填写人" /> | ||
| 94 | + </el-form-item> | ||
| 95 | + <el-form-item label="填写时间" prop="writeTime"> | ||
| 96 | + <el-date-picker clearable size="small" style="width: 200px" | ||
| 97 | + v-model="form.writeTime" | ||
| 98 | + type="date" | ||
| 99 | + value-format="yyyy-MM-dd" | ||
| 100 | + placeholder="选择填写时间"> | ||
| 101 | + </el-date-picker> | ||
| 102 | + </el-form-item> | ||
| 103 | + <el-form-item label="内容"> | ||
| 104 | + <editor v-model="form.content" :min-height="192"/> | ||
| 105 | + </el-form-item> | ||
| 106 | + </el-form> | ||
| 107 | + <div slot="footer" class="dialog-footer"> | ||
| 108 | + <el-button type="primary" @click="submitForm">确 定</el-button> | ||
| 109 | + <el-button @click="cancel">取 消</el-button> | ||
| 110 | + </div> | ||
| 111 | + </el-dialog> | ||
| 112 | + </div> | ||
| 113 | +</template> | ||
| 114 | + | ||
| 115 | +<script> | ||
| 116 | +import { listDaily, getDaily, delDaily, addDaily, updateDaily, exportDaily } from "@/api/daily/daily"; | ||
| 117 | +import Editor from '@/components/Editor'; | ||
| 118 | + | ||
| 119 | +export default { | ||
| 120 | + name: "Daily", | ||
| 121 | + components: { Editor }, | ||
| 122 | + data() { | ||
| 123 | + return { | ||
| 124 | + // 遮罩层 | ||
| 125 | + loading: true, | ||
| 126 | + // 选中数组 | ||
| 127 | + ids: [], | ||
| 128 | + // 非单个禁用 | ||
| 129 | + single: true, | ||
| 130 | + // 非多个禁用 | ||
| 131 | + multiple: true, | ||
| 132 | + // 显示搜索条件 | ||
| 133 | + showSearch: true, | ||
| 134 | + // 总条数 | ||
| 135 | + total: 0, | ||
| 136 | + // 日报表格数据 | ||
| 137 | + dailyList: [], | ||
| 138 | + // 弹出层标题 | ||
| 139 | + title: "", | ||
| 140 | + // 是否显示弹出层 | ||
| 141 | + open: false, | ||
| 142 | + // 查询参数 | ||
| 143 | + queryParams: { | ||
| 144 | + pageNum: 1, | ||
| 145 | + pageSize: 10, | ||
| 146 | + headline: null, | ||
| 147 | + }, | ||
| 148 | + // 表单参数 | ||
| 149 | + form: {}, | ||
| 150 | + // 表单校验 | ||
| 151 | + rules: { | ||
| 152 | + } | ||
| 153 | + }; | ||
| 154 | + }, | ||
| 155 | + created() { | ||
| 156 | + this.getList(); | ||
| 157 | + }, | ||
| 158 | + methods: { | ||
| 159 | + /** 查询日报列表 */ | ||
| 160 | + getList() { | ||
| 161 | + this.loading = true; | ||
| 162 | + listDaily(this.queryParams).then(response => { | ||
| 163 | + this.dailyList = response.rows; | ||
| 164 | + this.total = response.total; | ||
| 165 | + this.loading = false; | ||
| 166 | + }); | ||
| 167 | + }, | ||
| 168 | + // 取消按钮 | ||
| 169 | + cancel() { | ||
| 170 | + this.open = false; | ||
| 171 | + this.reset(); | ||
| 172 | + }, | ||
| 173 | + // 表单重置 | ||
| 174 | + reset() { | ||
| 175 | + this.form = { | ||
| 176 | + id: null, | ||
| 177 | + headline: null, | ||
| 178 | + writer: null, | ||
| 179 | + writeTime: null, | ||
| 180 | + content: null, | ||
| 181 | + begintime: null, | ||
| 182 | + endtime: null, | ||
| 183 | + contentType: null | ||
| 184 | + }; | ||
| 185 | + this.resetForm("form"); | ||
| 186 | + }, | ||
| 187 | + /** 搜索按钮操作 */ | ||
| 188 | + handleQuery() { | ||
| 189 | + this.queryParams.pageNum = 1; | ||
| 190 | + this.getList(); | ||
| 191 | + }, | ||
| 192 | + /** 重置按钮操作 */ | ||
| 193 | + resetQuery() { | ||
| 194 | + this.resetForm("queryForm"); | ||
| 195 | + this.handleQuery(); | ||
| 196 | + }, | ||
| 197 | + // 多选框选中数据 | ||
| 198 | + handleSelectionChange(selection) { | ||
| 199 | + this.ids = selection.map(item => item.id) | ||
| 200 | + this.single = selection.length!==1 | ||
| 201 | + this.multiple = !selection.length | ||
| 202 | + }, | ||
| 203 | + /** 新增按钮操作 */ | ||
| 204 | + handleAdd() { | ||
| 205 | + this.reset(); | ||
| 206 | + this.open = true; | ||
| 207 | + this.title = "添加日报"; | ||
| 208 | + }, | ||
| 209 | + /** 修改按钮操作 */ | ||
| 210 | + handleUpdate(row) { | ||
| 211 | + this.reset(); | ||
| 212 | + const id = row.id || this.ids | ||
| 213 | + getDaily(id).then(response => { | ||
| 214 | + this.form = response.data; | ||
| 215 | + this.open = true; | ||
| 216 | + this.title = "修改日报"; | ||
| 217 | + }); | ||
| 218 | + }, | ||
| 219 | + /** 查看详情按钮操作*/ | ||
| 220 | + handleById(row){ | ||
| 221 | + this.reset(); | ||
| 222 | + const id = row.id ||this.ids | ||
| 223 | + getDaily(id).then(response => { | ||
| 224 | + this.form = response.data; | ||
| 225 | + this.open = true; | ||
| 226 | + this.title = "查看详情信息"; | ||
| 227 | + }); | ||
| 228 | + }, | ||
| 229 | + /** 提交按钮 */ | ||
| 230 | + submitForm() { | ||
| 231 | + this.$refs["form"].validate(valid => { | ||
| 232 | + if (valid) { | ||
| 233 | + if (this.form.id != null) { | ||
| 234 | + updateDaily(this.form).then(response => { | ||
| 235 | + this.msgSuccess("修改成功"); | ||
| 236 | + this.open = false; | ||
| 237 | + this.getList(); | ||
| 238 | + }); | ||
| 239 | + } else { | ||
| 240 | + addDaily(this.form).then(response => { | ||
| 241 | + this.msgSuccess("新增成功"); | ||
| 242 | + this.open = false; | ||
| 243 | + this.getList(); | ||
| 244 | + }); | ||
| 245 | + } | ||
| 246 | + } | ||
| 247 | + }); | ||
| 248 | + }, | ||
| 249 | + /** 删除按钮操作 */ | ||
| 250 | + handleDelete(row) { | ||
| 251 | + const ids = row.id || this.ids; | ||
| 252 | + this.$confirm('是否确认删除日报编号为"' + ids + '"的数据项?', "警告", { | ||
| 253 | + confirmButtonText: "确定", | ||
| 254 | + cancelButtonText: "取消", | ||
| 255 | + type: "warning" | ||
| 256 | + }).then(function() { | ||
| 257 | + return delDaily(ids); | ||
| 258 | + }).then(() => { | ||
| 259 | + this.getList(); | ||
| 260 | + this.msgSuccess("删除成功"); | ||
| 261 | + }) | ||
| 262 | + }, | ||
| 263 | + /** 导出按钮操作 */ | ||
| 264 | + handleExport() { | ||
| 265 | + const queryParams = this.queryParams; | ||
| 266 | + this.$confirm('是否确认导出所有日报数据项?', "警告", { | ||
| 267 | + confirmButtonText: "确定", | ||
| 268 | + cancelButtonText: "取消", | ||
| 269 | + type: "warning" | ||
| 270 | + }).then(function() { | ||
| 271 | + return exportDaily(queryParams); | ||
| 272 | + }).then(response => { | ||
| 273 | + this.download(response.msg); | ||
| 274 | + }) | ||
| 275 | + } | ||
| 276 | + } | ||
| 277 | +}; | ||
| 278 | +</script> |
trash-ui/src/views/daily/information_sharing/index.vue
0 → 100644
| 1 | +<template> | ||
| 2 | + <div class="app-container"> | ||
| 3 | + <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px"> | ||
| 4 | + <el-form-item label="数据标题" prop="dataHeader"> | ||
| 5 | + <el-input | ||
| 6 | + v-model="queryParams.dataHeader" | ||
| 7 | + placeholder="请输入数据标题" | ||
| 8 | + clearable | ||
| 9 | + size="small" | ||
| 10 | + @keyup.enter.native="handleQuery" | ||
| 11 | + /> | ||
| 12 | + </el-form-item> | ||
| 13 | + <el-form-item label="调取部门" prop="retrieveDepartment"> | ||
| 14 | + <el-input | ||
| 15 | + v-model="queryParams.retrieveDepartment" | ||
| 16 | + placeholder="请输入调取部门" | ||
| 17 | + clearable | ||
| 18 | + size="small" | ||
| 19 | + @keyup.enter.native="handleQuery" | ||
| 20 | + /> | ||
| 21 | + </el-form-item> | ||
| 22 | + <el-form-item> | ||
| 23 | + <el-button type="cyan" size="mini" @click="handleQuery">搜索</el-button> | ||
| 24 | + </el-form-item> | ||
| 25 | + </el-form> | ||
| 26 | + | ||
| 27 | + <el-row :gutter="10" class="mb8"> | ||
| 28 | + <el-col :span="1.5"> | ||
| 29 | + <el-button | ||
| 30 | + type="primary" | ||
| 31 | + size="mini" | ||
| 32 | + @click="handleAdd" | ||
| 33 | + v-hasPermi="['daily:information_sharing:add']" | ||
| 34 | + >新增</el-button> | ||
| 35 | + </el-col> | ||
| 36 | + <el-col :span="1.5"> | ||
| 37 | + <el-button | ||
| 38 | + type="success" | ||
| 39 | + size="mini" | ||
| 40 | + :disabled="single" | ||
| 41 | + @click="handleUpdate" | ||
| 42 | + v-hasPermi="['daily:information_sharing:edit']" | ||
| 43 | + >修改</el-button> | ||
| 44 | + </el-col> | ||
| 45 | + <el-col :span="1.5"> | ||
| 46 | + <el-button | ||
| 47 | + type="danger" | ||
| 48 | + size="mini" | ||
| 49 | + :disabled="multiple" | ||
| 50 | + @click="handleDelete" | ||
| 51 | + v-hasPermi="['daily:information_sharing:remove']" | ||
| 52 | + >删除</el-button> | ||
| 53 | + </el-col> | ||
| 54 | + <el-col :span="1.5"> | ||
| 55 | + <el-button | ||
| 56 | + type="warning" | ||
| 57 | + size="mini" | ||
| 58 | + @click="handleExport" | ||
| 59 | + v-hasPermi="['daily:information_sharing:export']" | ||
| 60 | + >导出</el-button> | ||
| 61 | + </el-col> | ||
| 62 | + <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | ||
| 63 | + </el-row> | ||
| 64 | + | ||
| 65 | + <el-table v-loading="loading" :data="information_sharingList" border @selection-change="handleSelectionChange"> | ||
| 66 | + <el-table-column type="selection" width="55" align="center" /> | ||
| 67 | + <el-table-column label="数据标题" align="center" prop="dataHeader" /> | ||
| 68 | + <el-table-column label="调取部门" align="center" prop="retrieveDepartment" /> | ||
| 69 | + <el-table-column label="调取时间" align="center" prop="retrieveTime" width="180"> | ||
| 70 | + <template slot-scope="scope"> | ||
| 71 | + <span>{{ parseTime(scope.row.retrieveTime, '{y}-{m}-{d}') }}</span> | ||
| 72 | + </template> | ||
| 73 | + </el-table-column> | ||
| 74 | + <el-table-column label="操作" align="center" class-name="small-padding fixed-width"> | ||
| 75 | + <template slot-scope="scope"> | ||
| 76 | + <el-button | ||
| 77 | + size="mini" | ||
| 78 | + type="text" | ||
| 79 | + @click="handleById(scope.row)" | ||
| 80 | + v-hasPermi="['daily:information_sharing:query']"> | ||
| 81 | + 查看 | ||
| 82 | + </el-button> | ||
| 83 | + </template> | ||
| 84 | + </el-table-column> | ||
| 85 | + </el-table> | ||
| 86 | + | ||
| 87 | + <pagination | ||
| 88 | + v-show="total>0" | ||
| 89 | + :total="total" | ||
| 90 | + :page.sync="queryParams.pageNum" | ||
| 91 | + :limit.sync="queryParams.pageSize" | ||
| 92 | + @pagination="getList" | ||
| 93 | + /> | ||
| 94 | + | ||
| 95 | + <!-- 添加或修改信息共享对话框 --> | ||
| 96 | + <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body> | ||
| 97 | + <el-form ref="form" :model="form" :rules="rules" label-width="80px"> | ||
| 98 | + <el-form-item label="数据标题" prop="dataHeader"> | ||
| 99 | + <el-input v-model="form.dataHeader" placeholder="请输入数据标题" /> | ||
| 100 | + </el-form-item> | ||
| 101 | + <el-form-item label="调取部门" prop="retrieveDepartment"> | ||
| 102 | + <el-input v-model="form.retrieveDepartment" placeholder="请输入调取部门" /> | ||
| 103 | + </el-form-item> | ||
| 104 | + <el-form-item label="调取时间" prop="retrieveTime"> | ||
| 105 | + <el-date-picker clearable size="small" style="width: 200px" | ||
| 106 | + v-model="form.retrieveTime" | ||
| 107 | + type="date" | ||
| 108 | + value-format="yyyy-MM-dd" | ||
| 109 | + placeholder="选择调取时间"> | ||
| 110 | + </el-date-picker> | ||
| 111 | + </el-form-item> | ||
| 112 | + <el-form-item label="调取内容"> | ||
| 113 | + <editor v-model="form.retrieveContent" :min-height="192"/> | ||
| 114 | + </el-form-item> | ||
| 115 | + </el-form> | ||
| 116 | + <div slot="footer" class="dialog-footer"> | ||
| 117 | + <el-button type="primary" @click="submitForm">确 定</el-button> | ||
| 118 | + <el-button @click="cancel">取 消</el-button> | ||
| 119 | + </div> | ||
| 120 | + </el-dialog> | ||
| 121 | + </div> | ||
| 122 | +</template> | ||
| 123 | + | ||
| 124 | +<script> | ||
| 125 | +import { listInformation_sharing, getInformation_sharing, delInformation_sharing, addInformation_sharing, updateInformation_sharing, exportInformation_sharing } from "@/api/daily/information_sharing"; | ||
| 126 | +import Editor from '@/components/Editor'; | ||
| 127 | +import {getToollist} from "@/api/daily/toollist"; | ||
| 128 | + | ||
| 129 | +export default { | ||
| 130 | + name: "Information_sharing", | ||
| 131 | + components: { Editor }, | ||
| 132 | + data() { | ||
| 133 | + return { | ||
| 134 | + // 遮罩层 | ||
| 135 | + loading: true, | ||
| 136 | + border:true, | ||
| 137 | + // 选中数组 | ||
| 138 | + ids: [], | ||
| 139 | + // 非单个禁用 | ||
| 140 | + single: true, | ||
| 141 | + // 非多个禁用 | ||
| 142 | + multiple: true, | ||
| 143 | + // 显示搜索条件 | ||
| 144 | + showSearch: true, | ||
| 145 | + // 总条数 | ||
| 146 | + total: 0, | ||
| 147 | + // 信息共享表格数据 | ||
| 148 | + information_sharingList: [], | ||
| 149 | + // 弹出层标题 | ||
| 150 | + title: "", | ||
| 151 | + // 是否显示弹出层 | ||
| 152 | + open: false, | ||
| 153 | + // 查询参数 | ||
| 154 | + queryParams: { | ||
| 155 | + pageNum: 1, | ||
| 156 | + pageSize: 10, | ||
| 157 | + dataHeader: null, | ||
| 158 | + retrieveDepartment: null, | ||
| 159 | + }, | ||
| 160 | + // 表单参数 | ||
| 161 | + form: {}, | ||
| 162 | + // 表单校验 | ||
| 163 | + rules: { | ||
| 164 | + } | ||
| 165 | + }; | ||
| 166 | + }, | ||
| 167 | + created() { | ||
| 168 | + this.getList(); | ||
| 169 | + }, | ||
| 170 | + methods: { | ||
| 171 | + /** 查询信息共享列表 */ | ||
| 172 | + getList() { | ||
| 173 | + this.loading = true; | ||
| 174 | + listInformation_sharing(this.queryParams).then(response => { | ||
| 175 | + this.information_sharingList = response.rows; | ||
| 176 | + this.total = response.total; | ||
| 177 | + this.loading = false; | ||
| 178 | + }); | ||
| 179 | + }, | ||
| 180 | + // 取消按钮 | ||
| 181 | + cancel() { | ||
| 182 | + this.open = false; | ||
| 183 | + this.reset(); | ||
| 184 | + }, | ||
| 185 | + // 表单重置 | ||
| 186 | + reset() { | ||
| 187 | + this.form = { | ||
| 188 | + id: null, | ||
| 189 | + dataHeader: null, | ||
| 190 | + retrieveDepartment: null, | ||
| 191 | + retrieveTime: null, | ||
| 192 | + retrieveContent: null, | ||
| 193 | + attachmentLink: null, | ||
| 194 | + informationLink: null | ||
| 195 | + }; | ||
| 196 | + this.resetForm("form"); | ||
| 197 | + }, | ||
| 198 | + /** 搜索按钮操作 */ | ||
| 199 | + handleQuery() { | ||
| 200 | + this.queryParams.pageNum = 1; | ||
| 201 | + this.getList(); | ||
| 202 | + }, | ||
| 203 | + /** 重置按钮操作 */ | ||
| 204 | + resetQuery() { | ||
| 205 | + this.resetForm("queryForm"); | ||
| 206 | + this.handleQuery(); | ||
| 207 | + }, | ||
| 208 | + // 多选框选中数据 | ||
| 209 | + handleSelectionChange(selection) { | ||
| 210 | + this.ids = selection.map(item => item.id) | ||
| 211 | + this.single = selection.length!==1 | ||
| 212 | + this.multiple = !selection.length | ||
| 213 | + }, | ||
| 214 | + /** 新增按钮操作 */ | ||
| 215 | + handleAdd() { | ||
| 216 | + this.reset(); | ||
| 217 | + this.open = true; | ||
| 218 | + this.title = "添加信息共享"; | ||
| 219 | + }, | ||
| 220 | + /** 修改按钮操作 */ | ||
| 221 | + handleUpdate(row) { | ||
| 222 | + this.reset(); | ||
| 223 | + const id = row.id || this.ids | ||
| 224 | + getInformation_sharing(id).then(response => { | ||
| 225 | + this.form = response.data; | ||
| 226 | + this.open = true; | ||
| 227 | + this.title = "修改信息共享"; | ||
| 228 | + }); | ||
| 229 | + }, | ||
| 230 | + /** 查看详情按钮操作*/ | ||
| 231 | + handleById(row){ | ||
| 232 | + this.reset(); | ||
| 233 | + const id = row.id ||this.ids | ||
| 234 | + getInformation_sharing(id).then(response => { | ||
| 235 | + this.form = response.data; | ||
| 236 | + this.open = true; | ||
| 237 | + this.title = "查看详情信息"; | ||
| 238 | + }); | ||
| 239 | + }, | ||
| 240 | + /** 提交按钮 */ | ||
| 241 | + submitForm() { | ||
| 242 | + this.$refs["form"].validate(valid => { | ||
| 243 | + if (valid) { | ||
| 244 | + if (this.form.id != null) { | ||
| 245 | + updateInformation_sharing(this.form).then(response => { | ||
| 246 | + this.msgSuccess("修改成功"); | ||
| 247 | + this.open = false; | ||
| 248 | + this.getList(); | ||
| 249 | + }); | ||
| 250 | + } else { | ||
| 251 | + addInformation_sharing(this.form).then(response => { | ||
| 252 | + this.msgSuccess("新增成功"); | ||
| 253 | + this.open = false; | ||
| 254 | + this.getList(); | ||
| 255 | + }); | ||
| 256 | + } | ||
| 257 | + } | ||
| 258 | + }); | ||
| 259 | + }, | ||
| 260 | + /** 删除按钮操作 */ | ||
| 261 | + handleDelete(row) { | ||
| 262 | + const ids = row.id || this.ids; | ||
| 263 | + this.$confirm('是否确认删除信息共享编号为"' + ids + '"的数据项?', "警告", { | ||
| 264 | + confirmButtonText: "确定", | ||
| 265 | + cancelButtonText: "取消", | ||
| 266 | + type: "warning" | ||
| 267 | + }).then(function() { | ||
| 268 | + return delInformation_sharing(ids); | ||
| 269 | + }).then(() => { | ||
| 270 | + this.getList(); | ||
| 271 | + this.msgSuccess("删除成功"); | ||
| 272 | + }) | ||
| 273 | + }, | ||
| 274 | + /** 导出按钮操作 */ | ||
| 275 | + handleExport() { | ||
| 276 | + const queryParams = this.queryParams; | ||
| 277 | + this.$confirm('是否确认导出所有信息共享数据项?', "警告", { | ||
| 278 | + confirmButtonText: "确定", | ||
| 279 | + cancelButtonText: "取消", | ||
| 280 | + type: "warning" | ||
| 281 | + }).then(function() { | ||
| 282 | + return exportInformation_sharing(queryParams); | ||
| 283 | + }).then(response => { | ||
| 284 | + this.download(response.msg); | ||
| 285 | + }) | ||
| 286 | + } | ||
| 287 | + } | ||
| 288 | +}; | ||
| 289 | +</script> |
trash-ui/src/views/daily/monthly/index.vue
0 → 100644
| 1 | +<template> | ||
| 2 | + <div class="app-container"> | ||
| 3 | + <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px"> | ||
| 4 | + <el-form-item label="标题" prop="headline"> | ||
| 5 | + <el-input | ||
| 6 | + v-model="queryParams.headline" | ||
| 7 | + placeholder="请输入标题" | ||
| 8 | + clearable | ||
| 9 | + size="small" | ||
| 10 | + @keyup.enter.native="handleQuery" | ||
| 11 | + /> | ||
| 12 | + </el-form-item> | ||
| 13 | + <el-form-item> | ||
| 14 | + <el-button type="cyan" size="mini" @click="handleQuery">搜索</el-button> | ||
| 15 | + </el-form-item> | ||
| 16 | + </el-form> | ||
| 17 | + | ||
| 18 | + <el-row :gutter="10" class="mb8"> | ||
| 19 | + <el-col :span="1.5"> | ||
| 20 | + <el-button | ||
| 21 | + type="primary" | ||
| 22 | + size="mini" | ||
| 23 | + @click="handleAdd" | ||
| 24 | + v-hasPermi="['report:monthly:add']" | ||
| 25 | + >新增</el-button> | ||
| 26 | + </el-col> | ||
| 27 | + <el-col :span="1.5"> | ||
| 28 | + <el-button | ||
| 29 | + type="success" | ||
| 30 | + size="mini" | ||
| 31 | + :disabled="single" | ||
| 32 | + @click="handleUpdate" | ||
| 33 | + v-hasPermi="['report:monthly:edit']" | ||
| 34 | + >修改</el-button> | ||
| 35 | + </el-col> | ||
| 36 | + <el-col :span="1.5"> | ||
| 37 | + <el-button | ||
| 38 | + type="danger" | ||
| 39 | + size="mini" | ||
| 40 | + :disabled="multiple" | ||
| 41 | + @click="handleDelete" | ||
| 42 | + v-hasPermi="['report:monthly:remove']" | ||
| 43 | + >删除</el-button> | ||
| 44 | + </el-col> | ||
| 45 | + <el-col :span="1.5"> | ||
| 46 | + <el-button | ||
| 47 | + type="warning" | ||
| 48 | + size="mini" | ||
| 49 | + @click="handleExport" | ||
| 50 | + v-hasPermi="['report:monthly:export']" | ||
| 51 | + >导出</el-button> | ||
| 52 | + </el-col> | ||
| 53 | + <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | ||
| 54 | + </el-row> | ||
| 55 | + | ||
| 56 | + <el-table v-loading="loading" :data="monthlyList" @selection-change="handleSelectionChange"> | ||
| 57 | + <el-table-column type="selection" width="55" align="center" /> | ||
| 58 | + <el-table-column label="标题" align="center" prop="headline" /> | ||
| 59 | + <el-table-column label="填写人" align="center" prop="writer" /> | ||
| 60 | + <el-table-column label="填写时间" align="center" prop="writeTime" width="180"> | ||
| 61 | + <template slot-scope="scope"> | ||
| 62 | + <span>{{ parseTime(scope.row.writeTime, '{y}-{m}-{d}') }}</span> | ||
| 63 | + </template> | ||
| 64 | + </el-table-column> | ||
| 65 | + <el-table-column label="操作" align="center" class-name="small-padding fixed-width"> | ||
| 66 | + <template slot-scope="scope"> | ||
| 67 | + <el-button | ||
| 68 | + size="mini" | ||
| 69 | + type="text" | ||
| 70 | + @click="handleById(scope.row)" | ||
| 71 | + v-hasPermi="['report:monthly:query']"> | ||
| 72 | + 查看 | ||
| 73 | + </el-button> | ||
| 74 | + </template> | ||
| 75 | + </el-table-column> | ||
| 76 | + </el-table> | ||
| 77 | + | ||
| 78 | + <pagination | ||
| 79 | + v-show="total>0" | ||
| 80 | + :total="total" | ||
| 81 | + :page.sync="queryParams.pageNum" | ||
| 82 | + :limit.sync="queryParams.pageSize" | ||
| 83 | + @pagination="getList" | ||
| 84 | + /> | ||
| 85 | + | ||
| 86 | + <!-- 添加或修改月报对话框 --> | ||
| 87 | + <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body> | ||
| 88 | + <el-form ref="form" :model="form" :rules="rules" label-width="80px"> | ||
| 89 | + <el-form-item label="周期" prop="begintime"> | ||
| 90 | + <el-date-picker clearable size="small" style="width: 200px" | ||
| 91 | + v-model="form.begintime" | ||
| 92 | + type="date" | ||
| 93 | + value-format="yyyy-MM-dd" | ||
| 94 | + placeholder="选择开始时间"> | ||
| 95 | + </el-date-picker> | ||
| 96 | + </el-form-item> | ||
| 97 | + <el-form-item label="至" prop="endtime"> | ||
| 98 | + <el-date-picker clearable size="small" style="width: 200px" | ||
| 99 | + v-model="form.endtime" | ||
| 100 | + type="date" | ||
| 101 | + value-format="yyyy-MM-dd" | ||
| 102 | + placeholder="选择结束时间"> | ||
| 103 | + </el-date-picker> | ||
| 104 | + </el-form-item> | ||
| 105 | + <el-form-item label="标题" prop="headline"> | ||
| 106 | + <el-input v-model="form.headline" placeholder="请输入标题" /> | ||
| 107 | + </el-form-item> | ||
| 108 | + <el-form-item label="填写人" prop="writer"> | ||
| 109 | + <el-input v-model="form.writer" placeholder="请输入填写人" /> | ||
| 110 | + </el-form-item> | ||
| 111 | + <el-form-item label="填写时间" prop="writeTime"> | ||
| 112 | + <el-date-picker clearable size="small" style="width: 200px" | ||
| 113 | + v-model="form.writeTime" | ||
| 114 | + type="date" | ||
| 115 | + value-format="yyyy-MM-dd" | ||
| 116 | + placeholder="选择填写时间"> | ||
| 117 | + </el-date-picker> | ||
| 118 | + </el-form-item> | ||
| 119 | + <el-form-item label="内容"> | ||
| 120 | + <editor v-model="form.content" :min-height="192"/> | ||
| 121 | + </el-form-item> | ||
| 122 | + </el-form> | ||
| 123 | + <div slot="footer" class="dialog-footer"> | ||
| 124 | + <el-button type="primary" @click="submitForm">确 定</el-button> | ||
| 125 | + <el-button @click="cancel">取 消</el-button> | ||
| 126 | + </div> | ||
| 127 | + </el-dialog> | ||
| 128 | + </div> | ||
| 129 | +</template> | ||
| 130 | + | ||
| 131 | +<script> | ||
| 132 | +import { listMonthly, getMonthly, delMonthly, addMonthly, updateMonthly, exportMonthly } from "@/api/daily/monthly"; | ||
| 133 | +import Editor from '@/components/Editor'; | ||
| 134 | +export default { | ||
| 135 | + name: "Monthly", | ||
| 136 | + components: { Editor }, | ||
| 137 | + data() { | ||
| 138 | + return { | ||
| 139 | + // 遮罩层 | ||
| 140 | + loading: true, | ||
| 141 | + // 选中数组 | ||
| 142 | + ids: [], | ||
| 143 | + // 非单个禁用 | ||
| 144 | + single: true, | ||
| 145 | + // 非多个禁用 | ||
| 146 | + multiple: true, | ||
| 147 | + // 显示搜索条件 | ||
| 148 | + showSearch: true, | ||
| 149 | + // 总条数 | ||
| 150 | + total: 0, | ||
| 151 | + // 月报表格数据 | ||
| 152 | + monthlyList: [], | ||
| 153 | + // 弹出层标题 | ||
| 154 | + title: "", | ||
| 155 | + // 是否显示弹出层 | ||
| 156 | + open: false, | ||
| 157 | + // 查询参数 | ||
| 158 | + queryParams: { | ||
| 159 | + pageNum: 1, | ||
| 160 | + pageSize: 10, | ||
| 161 | + headline: null, | ||
| 162 | + }, | ||
| 163 | + // 表单参数 | ||
| 164 | + form: {}, | ||
| 165 | + // 表单校验 | ||
| 166 | + rules: { | ||
| 167 | + } | ||
| 168 | + }; | ||
| 169 | + }, | ||
| 170 | + created() { | ||
| 171 | + this.getList(); | ||
| 172 | + }, | ||
| 173 | + methods: { | ||
| 174 | + /** 查询月报列表 */ | ||
| 175 | + getList() { | ||
| 176 | + this.loading = true; | ||
| 177 | + listMonthly(this.queryParams).then(response => { | ||
| 178 | + this.monthlyList = response.rows; | ||
| 179 | + this.total = response.total; | ||
| 180 | + this.loading = false; | ||
| 181 | + }); | ||
| 182 | + }, | ||
| 183 | + // 取消按钮 | ||
| 184 | + cancel() { | ||
| 185 | + this.open = false; | ||
| 186 | + this.reset(); | ||
| 187 | + }, | ||
| 188 | + // 表单重置 | ||
| 189 | + reset() { | ||
| 190 | + this.form = { | ||
| 191 | + id: null, | ||
| 192 | + headline: null, | ||
| 193 | + writer: null, | ||
| 194 | + writeTime: null, | ||
| 195 | + content: null, | ||
| 196 | + begintime: null, | ||
| 197 | + endtime: null, | ||
| 198 | + contentType: null | ||
| 199 | + }; | ||
| 200 | + this.resetForm("form"); | ||
| 201 | + }, | ||
| 202 | + /** 搜索按钮操作 */ | ||
| 203 | + handleQuery() { | ||
| 204 | + this.queryParams.pageNum = 1; | ||
| 205 | + this.getList(); | ||
| 206 | + }, | ||
| 207 | + /** 重置按钮操作 */ | ||
| 208 | + resetQuery() { | ||
| 209 | + this.resetForm("queryForm"); | ||
| 210 | + this.handleQuery(); | ||
| 211 | + }, | ||
| 212 | + // 多选框选中数据 | ||
| 213 | + handleSelectionChange(selection) { | ||
| 214 | + this.ids = selection.map(item => item.id) | ||
| 215 | + this.single = selection.length!==1 | ||
| 216 | + this.multiple = !selection.length | ||
| 217 | + }, | ||
| 218 | + /** 新增按钮操作 */ | ||
| 219 | + handleAdd() { | ||
| 220 | + this.reset(); | ||
| 221 | + this.open = true; | ||
| 222 | + this.title = "添加月报"; | ||
| 223 | + }, | ||
| 224 | + /** 修改按钮操作 */ | ||
| 225 | + handleUpdate(row) { | ||
| 226 | + this.reset(); | ||
| 227 | + const id = row.id || this.ids | ||
| 228 | + getMonthly(id).then(response => { | ||
| 229 | + this.form = response.data; | ||
| 230 | + this.open = true; | ||
| 231 | + this.title = "修改月报"; | ||
| 232 | + }); | ||
| 233 | + }, | ||
| 234 | + /** 查看详情按钮操作*/ | ||
| 235 | + handleById(row){ | ||
| 236 | + this.reset(); | ||
| 237 | + const id = row.id ||this.ids | ||
| 238 | + getMonthly(id).then(response => { | ||
| 239 | + this.form = response.data; | ||
| 240 | + this.open = true; | ||
| 241 | + this.title = "查看详情信息"; | ||
| 242 | + }); | ||
| 243 | + }, | ||
| 244 | + /** 提交按钮 */ | ||
| 245 | + submitForm() { | ||
| 246 | + this.$refs["form"].validate(valid => { | ||
| 247 | + if (valid) { | ||
| 248 | + if (this.form.id != null) { | ||
| 249 | + updateMonthly(this.form).then(response => { | ||
| 250 | + this.msgSuccess("修改成功"); | ||
| 251 | + this.open = false; | ||
| 252 | + this.getList(); | ||
| 253 | + }); | ||
| 254 | + } else { | ||
| 255 | + addMonthly(this.form).then(response => { | ||
| 256 | + this.msgSuccess("新增成功"); | ||
| 257 | + this.open = false; | ||
| 258 | + this.getList(); | ||
| 259 | + }); | ||
| 260 | + } | ||
| 261 | + } | ||
| 262 | + }); | ||
| 263 | + }, | ||
| 264 | + /** 删除按钮操作 */ | ||
| 265 | + handleDelete(row) { | ||
| 266 | + const ids = row.id || this.ids; | ||
| 267 | + this.$confirm('是否确认删除月报编号为"' + ids + '"的数据项?', "警告", { | ||
| 268 | + confirmButtonText: "确定", | ||
| 269 | + cancelButtonText: "取消", | ||
| 270 | + type: "warning" | ||
| 271 | + }).then(function() { | ||
| 272 | + return delMonthly(ids); | ||
| 273 | + }).then(() => { | ||
| 274 | + this.getList(); | ||
| 275 | + this.msgSuccess("删除成功"); | ||
| 276 | + }) | ||
| 277 | + }, | ||
| 278 | + /** 导出按钮操作 */ | ||
| 279 | + handleExport() { | ||
| 280 | + const queryParams = this.queryParams; | ||
| 281 | + this.$confirm('是否确认导出所有月报数据项?', "警告", { | ||
| 282 | + confirmButtonText: "确定", | ||
| 283 | + cancelButtonText: "取消", | ||
| 284 | + type: "warning" | ||
| 285 | + }).then(function() { | ||
| 286 | + return exportMonthly(queryParams); | ||
| 287 | + }).then(response => { | ||
| 288 | + this.download(response.msg); | ||
| 289 | + }) | ||
| 290 | + } | ||
| 291 | + } | ||
| 292 | +}; | ||
| 293 | +</script> |