| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.police.controller; |
| | | |
| | | import io.swagger.annotations.Api; |
| | |
| | | import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
| | | import lombok.AllArgsConstructor; |
| | | import javax.validation.Valid; |
| | | |
| | | import org.springblade.core.excel.util.ExcelUtil; |
| | | import org.springblade.core.secure.BladeUser; |
| | | import org.springblade.core.log.logger.BladeLogger; |
| | | import org.springblade.core.mp.support.Condition; |
| | | import org.springblade.core.mp.support.Query; |
| | | import org.springblade.core.tool.api.R; |
| | | import org.springblade.core.tool.jackson.JsonUtil; |
| | | import org.springblade.core.tool.utils.Func; |
| | | import org.springblade.modules.police.excel.PoliceAffairsGridExcel; |
| | | import org.springblade.modules.police.excel.PoliceAffairsGridImporter; |
| | | import org.springblade.modules.police.excel.PoliceStationExcel; |
| | | import org.springblade.modules.police.excel.PoliceStationImporter; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.modules.police.entity.PoliceAffairsGridEntity; |
| | | import org.springblade.modules.police.vo.PoliceAffairsGridVO; |
| | | import org.springblade.modules.police.wrapper.PoliceAffairsGridWrapper; |
| | | import org.springblade.modules.police.service.IPoliceAffairsGridService; |
| | | import org.springblade.core.boot.ctrl.BladeController; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | /** |
| | |
| | | public class PoliceAffairsGridController { |
| | | |
| | | private final IPoliceAffairsGridService policeAffairsGridService; |
| | | private final BladeLogger bladeLogger; |
| | | |
| | | /** |
| | | * 警务网格(辖区)表 详情 |
| | |
| | | } |
| | | |
| | | /** |
| | | * 警务网格(辖区)表 自定义新增或修改 |
| | | */ |
| | | @PostMapping("/saveOrUpdate") |
| | | @ApiOperationSupport(order = 8) |
| | | @ApiOperation(value = "自定义新增或修改", notes = "传入policeAffairsGrid") |
| | | public R saveOrUpdate(@Valid @RequestBody PoliceAffairsGridEntity policeAffairsGrid) { |
| | | bladeLogger.info("警务网格(辖区)表 自定义新增或修改",JsonUtil.toJson(policeAffairsGrid)); |
| | | return R.status(policeAffairsGridService.saveOrUpdatePoliceAffairsGrid(policeAffairsGrid)); |
| | | } |
| | | |
| | | /** |
| | | * 警务网格(辖区)表 新增或修改 |
| | | */ |
| | | @PostMapping("/submit") |