| | |
| | | import org.springblade.core.mp.support.Query; |
| | | import org.springblade.core.tool.api.R; |
| | | import org.springblade.core.tool.utils.Func; |
| | | import org.springblade.jfpt.alarm.service.IAlarmService; |
| | | import org.springblade.jfpt.feedback.entity.Feedback; |
| | | import org.springblade.jfpt.feedback.service.IFeedbackService; |
| | | import org.springblade.jfpt.feedback.vo.FeedbackVO; |
| | | import org.springblade.jfpt.feedback.wrapper.FeedbackWrapper; |
| | | import org.springblade.jfpt.operation.entity.Operation; |
| | | import org.springblade.jfpt.operation.service.IOperationService; |
| | | import org.springblade.jfpt.wj.entity.Wj; |
| | | import org.springblade.jfpt.wj.service.IWjService; |
| | | import org.springframework.web.bind.annotation.*; |
| | |
| | | import javax.validation.Valid; |
| | | import java.io.File; |
| | | import java.io.IOException; |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.*; |
| | | |
| | | /** |
| | |
| | | public class FeedbackController extends BladeController { |
| | | |
| | | private final IFeedbackService feedbackService; |
| | | private final IAlarmService alarmService; |
| | | private IWjService iWjService; |
| | | private final IOperationService operationService; |
| | | |
| | | /** |
| | | * 详情 |
| | |
| | | */ |
| | | @PostMapping("/saves") |
| | | public R saves(FeedbackVO feedback) { |
| | | |
| | | SimpleDateFormat sdf = new SimpleDateFormat();// 格式化时间 |
| | | sdf.applyPattern("yyyy-MM-dd HH:mm:ss");// a为am/pm的标记 |
| | | Date date = new Date();// 获取当前时间 |
| | | //System.out.println("现在时间:" + sdf.format(date)); // 输出已经格式化的现在时间(24小时制) |
| | | |
| | | Operation operation = new Operation(); |
| | | operation.setJid(feedback.getJid()); |
| | | operation.setSnumber(feedback.getSnumber()); |
| | | operation.setZc("任务反馈提交,警情结束"); |
| | | operation.setSname(feedback.getSname()); |
| | | |
| | | operation.setZctime(sdf.format(date)); |
| | | operationService.save(operation); |
| | | |
| | | feedbackService.save(feedback); |
| | | Wj wj = new Wj(); |
| | | //获取视频地址 |
| | |
| | | wj.setAddress(string3); |
| | | iWjService.insertfeed(wj); |
| | | } |
| | | alarmService.updateJtype(operation.getJid(),"2",null,null); |
| | | |
| | | return R.success("新增成功"); |
| | | } |
| | | } |