|
@@ -1,6 +1,9 @@
|
|
|
package com.zhongzheng.controller.system;
|
|
|
|
|
|
import java.util.List;
|
|
|
+
|
|
|
+import io.swagger.annotations.Api;
|
|
|
+import io.swagger.annotations.ApiOperation;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.security.access.prepost.PreAuthorize;
|
|
|
import org.springframework.validation.annotation.Validated;
|
|
@@ -29,6 +32,7 @@ import com.zhongzheng.modules.system.service.ISysConfigService;
|
|
|
*
|
|
|
* @author zhongzheng
|
|
|
*/
|
|
|
+@Api(tags ="系统配置")
|
|
|
@RestController
|
|
|
@RequestMapping("/system/config")
|
|
|
public class SysConfigController extends BaseController
|
|
@@ -39,6 +43,7 @@ public class SysConfigController extends BaseController
|
|
|
/**
|
|
|
* 获取参数配置列表
|
|
|
*/
|
|
|
+ @ApiOperation("配置列表")
|
|
|
@PreAuthorize("@ss.hasPermi('system:config:list')")
|
|
|
@GetMapping("/list")
|
|
|
public TableDataInfo list(SysConfig config)
|
|
@@ -48,7 +53,7 @@ public class SysConfigController extends BaseController
|
|
|
return getDataTable(list);
|
|
|
}
|
|
|
|
|
|
- @Log(title = "参数管理", businessType = BusinessType.EXPORT)
|
|
|
+ /*@Log(title = "参数管理", businessType = BusinessType.EXPORT)
|
|
|
@PreAuthorize("@ss.hasPermi('system:config:export')")
|
|
|
@GetMapping("/export")
|
|
|
public AjaxResult export(SysConfig config)
|
|
@@ -56,11 +61,12 @@ public class SysConfigController extends BaseController
|
|
|
List<SysConfig> list = configService.selectConfigList(config);
|
|
|
ExcelUtil<SysConfig> util = new ExcelUtil<SysConfig>(SysConfig.class);
|
|
|
return util.exportExcel(list, "参数数据");
|
|
|
- }
|
|
|
+ }*/
|
|
|
|
|
|
/**
|
|
|
* 根据参数编号获取详细信息
|
|
|
*/
|
|
|
+ @ApiOperation("通过ID配置详情")
|
|
|
@PreAuthorize("@ss.hasPermi('system:config:query')")
|
|
|
@GetMapping(value = "/{configId}")
|
|
|
public AjaxResult getInfo(@PathVariable Long configId)
|
|
@@ -71,6 +77,7 @@ public class SysConfigController extends BaseController
|
|
|
/**
|
|
|
* 根据参数键名查询参数值
|
|
|
*/
|
|
|
+ @ApiOperation("通过KEY获取配置详情")
|
|
|
@GetMapping(value = "/configKey/{configKey}")
|
|
|
public AjaxResult getConfigKey(@PathVariable String configKey)
|
|
|
{
|
|
@@ -80,6 +87,7 @@ public class SysConfigController extends BaseController
|
|
|
/**
|
|
|
* 新增参数配置
|
|
|
*/
|
|
|
+ @ApiOperation("新增配置")
|
|
|
@PreAuthorize("@ss.hasPermi('system:config:add')")
|
|
|
@Log(title = "参数管理", businessType = BusinessType.INSERT)
|
|
|
@PostMapping
|
|
@@ -97,6 +105,7 @@ public class SysConfigController extends BaseController
|
|
|
/**
|
|
|
* 修改参数配置
|
|
|
*/
|
|
|
+ @ApiOperation("修改配置")
|
|
|
@PreAuthorize("@ss.hasPermi('system:config:edit')")
|
|
|
@Log(title = "参数管理", businessType = BusinessType.UPDATE)
|
|
|
@PutMapping
|
|
@@ -113,6 +122,7 @@ public class SysConfigController extends BaseController
|
|
|
/**
|
|
|
* 删除参数配置
|
|
|
*/
|
|
|
+ @ApiOperation("删除配置")
|
|
|
@PreAuthorize("@ss.hasPermi('system:config:remove')")
|
|
|
@Log(title = "参数管理", businessType = BusinessType.DELETE)
|
|
|
@DeleteMapping("/{configIds}")
|
|
@@ -124,6 +134,7 @@ public class SysConfigController extends BaseController
|
|
|
/**
|
|
|
* 清空缓存
|
|
|
*/
|
|
|
+ @ApiOperation("刷新配置缓存")
|
|
|
@PreAuthorize("@ss.hasPermi('system:config:remove')")
|
|
|
@Log(title = "参数管理", businessType = BusinessType.CLEAN)
|
|
|
@DeleteMapping("/clearCache")
|