高级设置
This commit is contained in:
@@ -0,0 +1,46 @@
|
||||
package com.cool.store.controller;
|
||||
|
||||
import com.cool.store.context.CurrentUserHolder;
|
||||
import com.cool.store.dao.HyAdvancedSettingDAO;
|
||||
import com.cool.store.request.AdvancedSettingRequest;
|
||||
import com.cool.store.response.ResponseResult;
|
||||
import com.cool.store.service.AdvanceSettingService;
|
||||
import com.cool.store.vo.AdvancedSettingVO;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
/**
|
||||
* @Author suzhuhong
|
||||
* @Date 2023/6/14 20:48
|
||||
* @Version 1.0
|
||||
*/
|
||||
@RestControlle
|
||||
@Slf4j
|
||||
public class AdvanceSettingController {
|
||||
|
||||
@Resource
|
||||
AdvanceSettingService advanceSettingService;
|
||||
|
||||
@GetMapping(path = "/getAdvanceSetting")
|
||||
@ApiOperation("查询企业高级设置")
|
||||
public ResponseResult<AdvancedSettingVO> getAdvanceSetting(){
|
||||
return ResponseResult.success(advanceSettingService.getAdvancedSettingDetail());
|
||||
}
|
||||
|
||||
@GetMapping(path = "/changeAdvanceSetting")
|
||||
@ApiOperation("新增或者修改高级设置")
|
||||
public ResponseResult<Boolean> getAdvanceSetting(@RequestBody AdvancedSettingRequest advancedSettingRequest){
|
||||
return ResponseResult.success(advanceSettingService.addOrUpdateAdvanceSetting(CurrentUserHolder.getUserId(),advancedSettingRequest));
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -290,24 +290,6 @@ public class DeskController {
|
||||
|
||||
|
||||
|
||||
@GetMapping(path = "/getAdvanceSetting")
|
||||
@ApiOperation("查询企业高级设置")
|
||||
public ResponseResult<AdvancedSettingVO> getAdvanceSetting(){
|
||||
|
||||
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@GetMapping(path = "/changeAdvanceSetting")
|
||||
@ApiOperation("新增或者修改高级设置")
|
||||
public ResponseResult<AdvancedSettingVO> getAdvanceSetting(@RequestBody AdvancedSettingRequest advancedSettingRequest){
|
||||
|
||||
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
package com.cool.store.controller;
|
||||
|
||||
import com.cool.store.context.CurrentUserHolder;
|
||||
import com.cool.store.request.IntentAreaSettingRequest;
|
||||
import com.cool.store.response.ResponseResult;
|
||||
import com.cool.store.service.ZoneService;
|
||||
import com.cool.store.vo.ZoneVO;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
@@ -10,6 +12,8 @@ import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
/**
|
||||
* @Author suzhuhong
|
||||
* @Date 2023/6/14 11:40
|
||||
@@ -19,19 +23,20 @@ import org.springframework.web.bind.annotation.*;
|
||||
@Slf4j
|
||||
public class ZoneController {
|
||||
|
||||
@Resource
|
||||
ZoneService zoneService;
|
||||
|
||||
@PostMapping(path = "/addZone")
|
||||
@ApiOperation("新建意向战区/开发战区")
|
||||
public ResponseResult<Boolean> addZone(@RequestBody IntentAreaSettingRequest intentAreaSettingRequest){
|
||||
|
||||
return ResponseResult.success();
|
||||
return ResponseResult.success(zoneService.addZone( CurrentUserHolder.getUserId(),intentAreaSettingRequest));
|
||||
}
|
||||
|
||||
@PostMapping(path = "/updateZone")
|
||||
@ApiOperation("编辑意向战区/开发战区")
|
||||
public ResponseResult<Boolean> updateZone(@RequestBody IntentAreaSettingRequest intentAreaSettingRequest){
|
||||
|
||||
return ResponseResult.success();
|
||||
return ResponseResult.success(zoneService.updateZone(CurrentUserHolder.getUserId(),intentAreaSettingRequest));
|
||||
}
|
||||
|
||||
@GetMapping(path = "/getZoneList")
|
||||
@@ -42,7 +47,7 @@ public class ZoneController {
|
||||
public ResponseResult<PageInfo<ZoneVO>> getZoneList(@RequestParam(value = "type",required = false)String type,
|
||||
@RequestParam(value = "pageNumber",required = false,defaultValue = "1")Integer pageNumber,
|
||||
@RequestParam(value = "pageSize",required = false,defaultValue = "10")Integer pageSize){
|
||||
return ResponseResult.success();
|
||||
return ResponseResult.success(zoneService.getZoneList(type,pageSize,pageNumber));
|
||||
}
|
||||
|
||||
|
||||
@@ -52,6 +57,15 @@ public class ZoneController {
|
||||
@ApiImplicitParam(name = "id", value = "id", required = false),
|
||||
})
|
||||
public ResponseResult<Boolean> deletedZoneList(@RequestParam(value = "id",required = false)Long id){
|
||||
return ResponseResult.success();
|
||||
return ResponseResult.success(zoneService.deletedZone(id));
|
||||
}
|
||||
|
||||
@GetMapping(path = "/zoneDetail")
|
||||
@ApiOperation("战区详情")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "id", value = "id", required = false),
|
||||
})
|
||||
public ResponseResult<ZoneVO> zoneDetail(@RequestParam(value = "id",required = false)Long id){
|
||||
return ResponseResult.success(zoneService.zoneDetail(id));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user