Commit 133d6f6e authored by 王晓倩's avatar 王晓倩

安全承诺公告新增验证,详情页布局

parent 42bf5575
package com.zehong.web.controller.safetyManagement; package com.zehong.web.controller.safetyManagement;
import java.util.List; import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.*;
import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
...@@ -45,6 +48,29 @@ public class TSafetyCommitmentAnnouncementController extends BaseController ...@@ -45,6 +48,29 @@ public class TSafetyCommitmentAnnouncementController extends BaseController
return getDataTable(list); return getDataTable(list);
} }
/**
* 新增安全承诺公告验证
*/
@GetMapping("/getCurrent")
public AjaxResult getCurrent(TSafetyCommitmentAnnouncement tSafetyCommitmentAnnouncement)
{
Calendar calender = Calendar.getInstance();
calender.setTime(new Date());
String endTime = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(calender.getTime());
calender.set(Calendar.HOUR_OF_DAY, 0);
calender.set(Calendar.MINUTE, 0);
calender.set(Calendar.SECOND, 0);
String beginTime = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(calender.getTime());
Map<String, Object> map = new HashMap<>();
map.put("beginTime", beginTime);
map.put("endTime", endTime);
tSafetyCommitmentAnnouncement.setParams(map);
List<TSafetyCommitmentAnnouncement> list = tSafetyCommitmentAnnouncementService.selectTSafetyCommitmentAnnouncementList(tSafetyCommitmentAnnouncement);
return AjaxResult.success(list);
}
/** /**
* 导出安全承诺公告列表 * 导出安全承诺公告列表
*/ */
......
...@@ -9,6 +9,15 @@ export function listAnnouncement(query) { ...@@ -9,6 +9,15 @@ export function listAnnouncement(query) {
}) })
} }
// 查询安全承诺公告详细
export function getCurrent(query) {
return request({
url: '/safetyManagement/announcement/getCurrent',
method: 'get',
params: query
})
}
// 查询安全承诺公告详细 // 查询安全承诺公告详细
export function getAnnouncement(id) { export function getAnnouncement(id) {
return request({ return request({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment