密钥管理接口

This commit is contained in:
liulu
2024-10-29 15:56:50 +08:00
parent 74ddfcae3c
commit b6ff674d0b
23 changed files with 87 additions and 99 deletions
@@ -72,9 +72,9 @@ public class CryptoServiceController {
* @return 密码服务列表
*/
@GetMapping("/pageList")
public R<Page<CryptoServiceDTO.View>> servicePageList(CryptoServiceDTO.Query query) {
public R<Page<CryptoServiceDTO.CSView>> servicePageList(CryptoServiceDTO.Query query) {
Page<CryptoServiceDTO.View> page = cryptoServiceService.selectPageList(query);
Page<CryptoServiceDTO.CSView> page = cryptoServiceService.selectPageList(query);
return R.data(page);
}
@@ -86,7 +86,7 @@ public class CryptoServiceController {
* @return 密码服务id
*/
@PostMapping
public R<String> saveService(@Valid @RequestBody CryptoServiceDTO.Save save) {
public R<String> saveService(@Valid @RequestBody CryptoServiceDTO.CSSave save) {
Long id = cryptoServiceService.save(save);
return R.data(String.valueOf(id));
}
@@ -98,7 +98,7 @@ public class CryptoServiceController {
* @return 密码服务id
*/
@PutMapping
public R<Void> updateService(@Valid @RequestBody CryptoServiceDTO.Save update) {
public R<Void> updateService(@Valid @RequestBody CryptoServiceDTO.CSSave update) {
Assert.notNull(update.getId(), "密码服务id不能为空");
cryptoServiceService.update(update);
return R.ok();
@@ -42,9 +42,9 @@ public class DeviceController {
* @return 分页列表
*/
@GetMapping("/pageList")
public R<Page<DeviceDTO.View>> servicePageList(DeviceDTO.Query query) {
public R<Page<DeviceDTO.DeviceView>> servicePageList(DeviceDTO.Query query) {
Page<DeviceDTO.View> page = deviceService.selectPageList(query);
Page<DeviceDTO.DeviceView> page = deviceService.selectPageList(query);
return R.data(page);
}
@@ -55,9 +55,9 @@ public class DeviceController {
* @return 列表
*/
@GetMapping("/ungrouped/list")
public R<List<DeviceDTO.View>> getUngroupedList() {
public R<List<DeviceDTO.DeviceView>> getUngroupedList() {
List<DeviceDTO.View> res = deviceService.getUngroupedList();
List<DeviceDTO.DeviceView> res = deviceService.getUngroupedList();
return R.data(res);
}
@@ -111,7 +111,7 @@ public class DeviceController {
* @return id
*/
@PostMapping
public R<String> save(@Valid @RequestBody DeviceDTO.Save save) {
public R<String> save(@Valid @RequestBody DeviceDTO.DeviceSave save) {
Long id = deviceService.save(save);
return R.data(String.valueOf(id));
}
@@ -123,7 +123,7 @@ public class DeviceController {
* @return void
*/
@PutMapping
public R<Void> update(@Valid @RequestBody DeviceDTO.Save update) {
public R<Void> update(@Valid @RequestBody DeviceDTO.DeviceSave update) {
deviceService.update(update);
return R.ok();
}
@@ -35,9 +35,9 @@ public class DeviceGroupController {
* @return 分页列表
*/
@GetMapping("/pageList")
public R<Page<DeviceGroupDTO.View>> servicePageList(DeviceGroupDTO.Query query) {
public R<Page<DeviceGroupDTO.DGView>> servicePageList(DeviceGroupDTO.Query query) {
Page<DeviceGroupDTO.View> page = deviceGroupService.selectPageList(query);
Page<DeviceGroupDTO.DGView> page = deviceGroupService.selectPageList(query);
return R.data(page);
}
@@ -49,7 +49,7 @@ public class DeviceGroupController {
* @return id
*/
@PostMapping
public R<String> save(@Valid @RequestBody DeviceGroupDTO.Save save) {
public R<String> save(@Valid @RequestBody DeviceGroupDTO.DGSave save) {
Long id = deviceGroupService.save(save);
return R.data(String.valueOf(id));
}
@@ -61,7 +61,7 @@ public class DeviceGroupController {
* @return void
*/
@PutMapping
public R<Void> update(@Valid @RequestBody DeviceGroupDTO.Save update) {
public R<Void> update(@Valid @RequestBody DeviceGroupDTO.DGSave update) {
deviceGroupService.update(update);
return R.ok();
}
@@ -39,9 +39,9 @@ public class KeyInfoAsymController {
* @return 分页列表
*/
@GetMapping("/pageList")
public R<Page<KeyInfoDTO.View>> aymPageList(KeyInfoDTO.Query query) {
public R<Page<KeyInfoDTO.KeyView>> aymPageList(KeyInfoDTO.Query query) {
query.setKeyType(KeyCategory.ASYM_KEY.getCode());
Page<KeyInfoDTO.View> page = keyInfoService.selectPageList(query);
Page<KeyInfoDTO.KeyView> page = keyInfoService.selectPageList(query);
return R.data(page);
}
@@ -52,7 +52,7 @@ public class KeyInfoController {
* @return id
*/
@PostMapping("/create")
public R<String> save(@Valid @RequestBody KeyInfoDTO.Save save) {
public R<String> save(@Valid @RequestBody KeyInfoDTO.KeySave save) {
Long id = keyInfoService.save(save);
return R.data(String.valueOf(id));
}
@@ -64,7 +64,7 @@ public class KeyInfoController {
* @return id
*/
@PostMapping("/update")
public R<Void> save(@Valid @RequestBody KeyInfoDTO.Update update) {
public R<Void> save(@Valid @RequestBody KeyInfoDTO.KeyUpdate update) {
keyInfoService.update(update);
return R.ok();
}
@@ -41,9 +41,9 @@ public class KeyInfoSymController {
* @return 分页列表
*/
@GetMapping("/pageList")
public R<Page<KeyInfoDTO.View>> symPageList(KeyInfoDTO.Query query) {
public R<Page<KeyInfoDTO.KeyView>> symPageList(KeyInfoDTO.Query query) {
query.setKeyType(KeyCategory.SYM_KEY.getCode());
Page<KeyInfoDTO.View> page = keyInfoService.selectPageList(query);
Page<KeyInfoDTO.KeyView> page = keyInfoService.selectPageList(query);
return R.data(page);
}
@@ -34,9 +34,9 @@ public class KeyTemplateController {
* @return 分页列表
*/
@GetMapping("/pageList")
public R<Page<KeyTemplateDTO.View>> servicePageList(KeyTemplateDTO.Query query) {
public R<Page<KeyTemplateDTO.KTView>> servicePageList(KeyTemplateDTO.Query query) {
Page<KeyTemplateDTO.View> page = keyTemplateService.selectPageList(query);
Page<KeyTemplateDTO.KTView> page = keyTemplateService.selectPageList(query);
return R.data(page);
}
@@ -48,7 +48,7 @@ public class KeyTemplateController {
* @return id
*/
@PostMapping
public R<String> save(@Valid @RequestBody KeyTemplateDTO.Save save) {
public R<String> save(@Valid @RequestBody KeyTemplateDTO.KTSave save) {
Long id = keyTemplateService.save(save);
return R.data(String.valueOf(id));
}
@@ -60,7 +60,7 @@ public class KeyTemplateController {
* @return void
*/
@PutMapping
public R<Void> update(@Valid @RequestBody KeyTemplateDTO.Save update) {
public R<Void> update(@Valid @RequestBody KeyTemplateDTO.KTSave update) {
keyTemplateService.update(update);
return R.ok();
}