完善客户端异常管理
This commit is contained in:
parent
9e5c18158a
commit
d980521a0c
@ -110,4 +110,11 @@ public class ClientExceptionController extends AbstractController {
|
|||||||
return securityComponent.getCurrentUserIdInfo();
|
return securityComponent.getCurrentUserIdInfo();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation(value = "标记处理成功", notes = "标记处理成功接口")
|
||||||
|
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
||||||
|
@PutMapping("updateishandlerbyclientexceptionid/{clientExceptionId}")
|
||||||
|
public SuccessResult updateIsHandlerByClientExceptionId(@PathVariable("clientExceptionId") String clientExceptionId) {
|
||||||
|
return clientExceptionService.updateIsHandlerByClientExceptionId(clientExceptionId);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
@ -1,120 +0,0 @@
|
|||||||
package com.cm.central.control.controller.app.apis.client;
|
|
||||||
|
|
||||||
import com.cm.common.annotation.CheckRequestBodyAnnotation;
|
|
||||||
import com.cm.common.base.AbstractController;
|
|
||||||
import com.cm.common.constants.ISystemConstant;
|
|
||||||
import com.cm.common.exception.RemoveException;
|
|
||||||
import com.cm.common.exception.SearchException;
|
|
||||||
import com.cm.common.pojo.ListPage;
|
|
||||||
import com.cm.common.result.ErrorResult;
|
|
||||||
import com.cm.common.result.SuccessResult;
|
|
||||||
import com.cm.common.result.SuccessResultData;
|
|
||||||
import com.cm.common.result.SuccessResultList;
|
|
||||||
import com.cm.central.control.pojo.dtos.client.ClientDTO;
|
|
||||||
import com.cm.central.control.pojo.vos.client.ClientVO;
|
|
||||||
import com.cm.central.control.service.client.IClientService;
|
|
||||||
import io.swagger.annotations.*;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.web.bind.annotation.*;
|
|
||||||
|
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @ClassName: ClientAppController
|
|
||||||
* @Description: 客户端
|
|
||||||
* @Author: WenG
|
|
||||||
* @Date: 2020-07-30 19:12
|
|
||||||
* @Version: 1.0
|
|
||||||
**/
|
|
||||||
@Api(tags = ISystemConstant.API_TAGS_APP_PREFIX + "客户端接口")
|
|
||||||
@RestController
|
|
||||||
@RequestMapping(ISystemConstant.APP_PREFIX + "/client")
|
|
||||||
public class ClientAppController extends AbstractController {
|
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private IClientService clientService;
|
|
||||||
|
|
||||||
@ApiOperation(value = "新增客户端", notes = "新增客户端接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PostMapping("saveclient")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult saveClient(@RequestHeader("token") String token, @RequestBody ClientVO clientVO) throws Exception {
|
|
||||||
return clientService.saveClientByToken(token, clientVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "删除客户端(id列表)", notes = "删除客户端(id列表)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "ids", value = "ID列表,用下划线分隔", paramType = "path", example = "1_2_3")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@DeleteMapping("removeclient/{ids}")
|
|
||||||
public SuccessResult removeClient(@RequestHeader("token") String token, @PathVariable("ids") String ids) throws RemoveException {
|
|
||||||
return clientService.removeClientByToken(token, ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "修改客户端", notes = "修改客户端接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "clientId", value = "客户端ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PutMapping("updateclient/{clientId}")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult updateClient(@RequestHeader("token") String token, @PathVariable("clientId") String clientId, @RequestBody ClientVO clientVO) throws Exception {
|
|
||||||
return clientService.updateClientByToken(token, clientId, clientVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端详情(通过ID)", notes = "客户端详情(通过ID)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "clientId", value = "客户端ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("getclientbyid/{clientId}")
|
|
||||||
public ClientDTO getClientById(@RequestHeader("token") String token, @PathVariable("clientId") String clientId) throws SearchException {
|
|
||||||
return clientService.getClientById(clientId);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端列表", notes = "客户端列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listclient")
|
|
||||||
public List<ClientDTO> listClient(@RequestHeader("token") String token) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return clientService.listClient(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端分页列表", notes = "客户端分页列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "page", value = "当前页码", paramType = "query", dataType = "int", defaultValue = "1"),
|
|
||||||
@ApiImplicitParam(name = "rows", value = "显示数量", paramType = "query", dataType = "int", defaultValue = "20"),
|
|
||||||
@ApiImplicitParam(name = "keywords", value = "关键字", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "startTime", value = "开始时间", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "endTime", value = "结束时间", paramType = "query", dataType = "String")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listpageclient")
|
|
||||||
public SuccessResultList<List<ClientDTO>> listPageClient(@RequestHeader("token") String token, ListPage page) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
page.setParams(params);
|
|
||||||
return clientService.listPageClient(page);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端统计", notes = "客户端统计接口")
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("countclient")
|
|
||||||
SuccessResultData<Integer> countClient() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return clientService.countClient(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -1,109 +0,0 @@
|
|||||||
package com.cm.central.control.controller.app.apis.clientexception;
|
|
||||||
|
|
||||||
import com.cm.common.annotation.CheckRequestBodyAnnotation;
|
|
||||||
import com.cm.common.base.AbstractController;
|
|
||||||
import com.cm.common.constants.ISystemConstant;
|
|
||||||
import com.cm.common.exception.RemoveException;
|
|
||||||
import com.cm.common.exception.SearchException;
|
|
||||||
import com.cm.common.pojo.ListPage;
|
|
||||||
import com.cm.common.result.ErrorResult;
|
|
||||||
import com.cm.common.result.SuccessResult;
|
|
||||||
import com.cm.common.result.SuccessResultData;
|
|
||||||
import com.cm.common.result.SuccessResultList;
|
|
||||||
import com.cm.central.control.pojo.dtos.clientexception.ClientExceptionDTO;
|
|
||||||
import com.cm.central.control.pojo.vos.clientexception.ClientExceptionVO;
|
|
||||||
import com.cm.central.control.service.clientexception.IClientExceptionService;
|
|
||||||
import io.swagger.annotations.*;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.web.bind.annotation.*;
|
|
||||||
|
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @ClassName: ClientExceptionAppController
|
|
||||||
* @Description: 客户端异常
|
|
||||||
* @Author: WenG
|
|
||||||
* @Date: 2020-07-30 19:13
|
|
||||||
* @Version: 1.0
|
|
||||||
**/
|
|
||||||
@Api(tags = ISystemConstant.API_TAGS_APP_PREFIX + "客户端异常接口")
|
|
||||||
@RestController
|
|
||||||
@RequestMapping(ISystemConstant.APP_PREFIX + "/clientexception")
|
|
||||||
public class ClientExceptionAppController extends AbstractController {
|
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private IClientExceptionService clientExceptionService;
|
|
||||||
|
|
||||||
@ApiOperation(value = "删除客户端异常(id列表)", notes = "删除客户端异常(id列表)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "ids", value = "ID列表,用下划线分隔", paramType = "path", example = "1_2_3")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@DeleteMapping("removeclientexception/{ids}")
|
|
||||||
public SuccessResult removeClientException(@RequestHeader("token") String token, @PathVariable("ids") String ids) throws RemoveException {
|
|
||||||
return clientExceptionService.removeClientExceptionByToken(token, ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "修改客户端异常", notes = "修改客户端异常接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "clientExceptionId", value = "客户端异常ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PutMapping("updateclientexception/{clientExceptionId}")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult updateClientException(@RequestHeader("token") String token, @PathVariable("clientExceptionId") String clientExceptionId, @RequestBody ClientExceptionVO clientExceptionVO) throws Exception {
|
|
||||||
return clientExceptionService.updateClientExceptionByToken(token, clientExceptionId, clientExceptionVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端异常详情(通过ID)", notes = "客户端异常详情(通过ID)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "clientExceptionId", value = "客户端异常ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("getclientexceptionbyid/{clientExceptionId}")
|
|
||||||
public ClientExceptionDTO getClientExceptionById(@RequestHeader("token") String token, @PathVariable("clientExceptionId") String clientExceptionId) throws SearchException {
|
|
||||||
return clientExceptionService.getClientExceptionById(clientExceptionId);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端异常列表", notes = "客户端异常列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listclientexception")
|
|
||||||
public List<ClientExceptionDTO> listClientException(@RequestHeader("token") String token) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return clientExceptionService.listClientException(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端异常分页列表", notes = "客户端异常分页列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "page", value = "当前页码", paramType = "query", dataType = "int", defaultValue = "1"),
|
|
||||||
@ApiImplicitParam(name = "rows", value = "显示数量", paramType = "query", dataType = "int", defaultValue = "20"),
|
|
||||||
@ApiImplicitParam(name = "keywords", value = "关键字", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "startTime", value = "开始时间", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "endTime", value = "结束时间", paramType = "query", dataType = "String")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listpageclientexception")
|
|
||||||
public SuccessResultList<List<ClientExceptionDTO>> listPageClientException(@RequestHeader("token") String token, ListPage page) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
page.setParams(params);
|
|
||||||
return clientExceptionService.listPageClientException(page);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端异常统计", notes = "客户端异常统计接口")
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("countclientexception")
|
|
||||||
SuccessResultData<Integer> countClientException() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return clientExceptionService.countClientException(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -1,120 +0,0 @@
|
|||||||
package com.cm.central.control.controller.app.apis.customer;
|
|
||||||
|
|
||||||
import com.cm.common.annotation.CheckRequestBodyAnnotation;
|
|
||||||
import com.cm.common.base.AbstractController;
|
|
||||||
import com.cm.common.constants.ISystemConstant;
|
|
||||||
import com.cm.common.exception.RemoveException;
|
|
||||||
import com.cm.common.exception.SearchException;
|
|
||||||
import com.cm.common.pojo.ListPage;
|
|
||||||
import com.cm.common.result.ErrorResult;
|
|
||||||
import com.cm.common.result.SuccessResult;
|
|
||||||
import com.cm.common.result.SuccessResultData;
|
|
||||||
import com.cm.common.result.SuccessResultList;
|
|
||||||
import com.cm.central.control.pojo.dtos.customer.CustomerDTO;
|
|
||||||
import com.cm.central.control.pojo.vos.customer.CustomerVO;
|
|
||||||
import com.cm.central.control.service.customer.ICustomerService;
|
|
||||||
import io.swagger.annotations.*;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.web.bind.annotation.*;
|
|
||||||
|
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @ClassName: CustomerAppController
|
|
||||||
* @Description: 客户管理
|
|
||||||
* @Author: WenG
|
|
||||||
* @Date: 2020-07-30 19:00
|
|
||||||
* @Version: 1.0
|
|
||||||
**/
|
|
||||||
@Api(tags = ISystemConstant.API_TAGS_APP_PREFIX + "客户管理接口")
|
|
||||||
@RestController
|
|
||||||
@RequestMapping(ISystemConstant.APP_PREFIX + "/customer")
|
|
||||||
public class CustomerAppController extends AbstractController {
|
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private ICustomerService customerService;
|
|
||||||
|
|
||||||
@ApiOperation(value = "新增客户管理", notes = "新增客户管理接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PostMapping("savecustomer")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult saveCustomer(@RequestHeader("token") String token, @RequestBody CustomerVO customerVO) throws Exception {
|
|
||||||
return customerService.saveCustomerByToken(token, customerVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "删除客户管理(id列表)", notes = "删除客户管理(id列表)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "ids", value = "ID列表,用下划线分隔", paramType = "path", example = "1_2_3")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@DeleteMapping("removecustomer/{ids}")
|
|
||||||
public SuccessResult removeCustomer(@RequestHeader("token") String token, @PathVariable("ids") String ids) throws RemoveException {
|
|
||||||
return customerService.removeCustomerByToken(token, ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "修改客户管理", notes = "修改客户管理接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "customerId", value = "客户管理ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PutMapping("updatecustomer/{customerId}")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult updateCustomer(@RequestHeader("token") String token, @PathVariable("customerId") String customerId, @RequestBody CustomerVO customerVO) throws Exception {
|
|
||||||
return customerService.updateCustomerByToken(token, customerId, customerVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户管理详情(通过ID)", notes = "客户管理详情(通过ID)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "customerId", value = "客户管理ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("getcustomerbyid/{customerId}")
|
|
||||||
public CustomerDTO getCustomerById(@RequestHeader("token") String token, @PathVariable("customerId") String customerId) throws SearchException {
|
|
||||||
return customerService.getCustomerById(customerId);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户管理列表", notes = "客户管理列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listcustomer")
|
|
||||||
public List<CustomerDTO> listCustomer(@RequestHeader("token") String token) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return customerService.listCustomer(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户管理分页列表", notes = "客户管理分页列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "page", value = "当前页码", paramType = "query", dataType = "int", defaultValue = "1"),
|
|
||||||
@ApiImplicitParam(name = "rows", value = "显示数量", paramType = "query", dataType = "int", defaultValue = "20"),
|
|
||||||
@ApiImplicitParam(name = "keywords", value = "关键字", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "startTime", value = "开始时间", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "endTime", value = "结束时间", paramType = "query", dataType = "String")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listpagecustomer")
|
|
||||||
public SuccessResultList<List<CustomerDTO>> listPageCustomer(@RequestHeader("token") String token, ListPage page) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
page.setParams(params);
|
|
||||||
return customerService.listPageCustomer(page);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户管理统计", notes = "客户管理统计接口")
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("countcustomer")
|
|
||||||
SuccessResultData<Integer> countCustomer() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return customerService.countCustomer(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -1,120 +0,0 @@
|
|||||||
package com.cm.central.control.controller.app.apis.projectleader;
|
|
||||||
|
|
||||||
import com.cm.common.annotation.CheckRequestBodyAnnotation;
|
|
||||||
import com.cm.common.base.AbstractController;
|
|
||||||
import com.cm.common.constants.ISystemConstant;
|
|
||||||
import com.cm.common.exception.RemoveException;
|
|
||||||
import com.cm.common.exception.SearchException;
|
|
||||||
import com.cm.common.pojo.ListPage;
|
|
||||||
import com.cm.common.result.ErrorResult;
|
|
||||||
import com.cm.common.result.SuccessResult;
|
|
||||||
import com.cm.common.result.SuccessResultData;
|
|
||||||
import com.cm.common.result.SuccessResultList;
|
|
||||||
import com.cm.central.control.pojo.dtos.projectleader.ProjectLeaderDTO;
|
|
||||||
import com.cm.central.control.pojo.vos.projectleader.ProjectLeaderVO;
|
|
||||||
import com.cm.central.control.service.projectleader.IProjectLeaderService;
|
|
||||||
import io.swagger.annotations.*;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.web.bind.annotation.*;
|
|
||||||
|
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @ClassName: ProjectLeaderAppController
|
|
||||||
* @Description: 项目负责人
|
|
||||||
* @Author: WenG
|
|
||||||
* @Date: 2020-07-30 19:04
|
|
||||||
* @Version: 1.0
|
|
||||||
**/
|
|
||||||
@Api(tags = ISystemConstant.API_TAGS_APP_PREFIX + "项目负责人接口")
|
|
||||||
@RestController
|
|
||||||
@RequestMapping(ISystemConstant.APP_PREFIX + "/projectleader")
|
|
||||||
public class ProjectLeaderAppController extends AbstractController {
|
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private IProjectLeaderService projectLeaderService;
|
|
||||||
|
|
||||||
@ApiOperation(value = "新增项目负责人", notes = "新增项目负责人接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PostMapping("saveprojectleader")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult saveProjectLeader(@RequestHeader("token") String token, @RequestBody ProjectLeaderVO projectLeaderVO) throws Exception {
|
|
||||||
return projectLeaderService.saveProjectLeaderByToken(token, projectLeaderVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "删除项目负责人(id列表)", notes = "删除项目负责人(id列表)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "ids", value = "ID列表,用下划线分隔", paramType = "path", example = "1_2_3")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@DeleteMapping("removeprojectleader/{ids}")
|
|
||||||
public SuccessResult removeProjectLeader(@RequestHeader("token") String token, @PathVariable("ids") String ids) throws RemoveException {
|
|
||||||
return projectLeaderService.removeProjectLeaderByToken(token, ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "修改项目负责人", notes = "修改项目负责人接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "projectLeaderId", value = "项目负责人ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PutMapping("updateprojectleader/{projectLeaderId}")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult updateProjectLeader(@RequestHeader("token") String token, @PathVariable("projectLeaderId") String projectLeaderId, @RequestBody ProjectLeaderVO projectLeaderVO) throws Exception {
|
|
||||||
return projectLeaderService.updateProjectLeaderByToken(token, projectLeaderId, projectLeaderVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "项目负责人详情(通过ID)", notes = "项目负责人详情(通过ID)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "projectLeaderId", value = "项目负责人ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("getprojectleaderbyid/{projectLeaderId}")
|
|
||||||
public ProjectLeaderDTO getProjectLeaderById(@RequestHeader("token") String token, @PathVariable("projectLeaderId") String projectLeaderId) throws SearchException {
|
|
||||||
return projectLeaderService.getProjectLeaderById(projectLeaderId);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "项目负责人列表", notes = "项目负责人列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listprojectleader")
|
|
||||||
public List<ProjectLeaderDTO> listProjectLeader(@RequestHeader("token") String token) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return projectLeaderService.listProjectLeader(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "项目负责人分页列表", notes = "项目负责人分页列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "token", value = "token", paramType = "header"),
|
|
||||||
@ApiImplicitParam(name = "page", value = "当前页码", paramType = "query", dataType = "int", defaultValue = "1"),
|
|
||||||
@ApiImplicitParam(name = "rows", value = "显示数量", paramType = "query", dataType = "int", defaultValue = "20"),
|
|
||||||
@ApiImplicitParam(name = "keywords", value = "关键字", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "startTime", value = "开始时间", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "endTime", value = "结束时间", paramType = "query", dataType = "String")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listpageprojectleader")
|
|
||||||
public SuccessResultList<List<ProjectLeaderDTO>> listPageProjectLeader(@RequestHeader("token") String token, ListPage page) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
page.setParams(params);
|
|
||||||
return projectLeaderService.listPageProjectLeader(page);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "项目负责人统计", notes = "项目负责人统计接口")
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("countprojectleader")
|
|
||||||
SuccessResultData<Integer> countProjectLeader() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return projectLeaderService.countProjectLeader(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -1,120 +0,0 @@
|
|||||||
package com.cm.central.control.controller.resources.client;
|
|
||||||
|
|
||||||
import com.cm.common.annotation.CheckRequestBodyAnnotation;
|
|
||||||
import com.cm.common.base.AbstractController;
|
|
||||||
import com.cm.common.constants.ISystemConstant;
|
|
||||||
import com.cm.common.exception.RemoveException;
|
|
||||||
import com.cm.common.exception.SearchException;
|
|
||||||
import com.cm.common.pojo.ListPage;
|
|
||||||
import com.cm.common.result.ErrorResult;
|
|
||||||
import com.cm.common.result.SuccessResult;
|
|
||||||
import com.cm.common.result.SuccessResultData;
|
|
||||||
import com.cm.common.result.SuccessResultList;
|
|
||||||
import com.cm.central.control.pojo.dtos.client.ClientDTO;
|
|
||||||
import com.cm.central.control.pojo.vos.client.ClientVO;
|
|
||||||
import com.cm.central.control.service.client.IClientService;
|
|
||||||
import io.swagger.annotations.*;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.web.bind.annotation.*;
|
|
||||||
|
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @ClassName: ClientResourceController
|
|
||||||
* @Description: 客户端
|
|
||||||
* @Author: WenG
|
|
||||||
* @Date: 2020-07-30 19:12
|
|
||||||
* @Version: 1.0
|
|
||||||
**/
|
|
||||||
@Api(tags = ISystemConstant.API_TAGS_RESOURCE_PREFIX + "客户端接口")
|
|
||||||
@RestController
|
|
||||||
@RequestMapping(ISystemConstant.RESOURCE_PREFIX + "/client")
|
|
||||||
public class ClientResourceController extends AbstractController {
|
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private IClientService clientService;
|
|
||||||
|
|
||||||
@ApiOperation(value = "新增客户端", notes = "新增客户端接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PostMapping("saveclient")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult saveClient(@RequestBody ClientVO clientVO) throws Exception {
|
|
||||||
return clientService.saveClient(clientVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "删除客户端(id列表)", notes = "删除客户端(id列表)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "ids", value = "ID列表,用下划线分隔", paramType = "path", example = "1_2_3")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@DeleteMapping("removeclient/{ids}")
|
|
||||||
public SuccessResult removeClient(@PathVariable("ids") String ids) throws RemoveException {
|
|
||||||
return clientService.removeClient(ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "修改客户端", notes = "修改客户端接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "clientId", value = "客户端ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PutMapping("updateclient/{clientId}")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult updateClient(@PathVariable("clientId") String clientId, @RequestBody ClientVO clientVO) throws Exception {
|
|
||||||
return clientService.updateClient(clientId, clientVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端详情(通过ID)", notes = "客户端详情(通过ID)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "clientId", value = "客户端ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("getclientbyid/{clientId}")
|
|
||||||
public ClientDTO getClientById(@PathVariable("clientId") String clientId) throws SearchException {
|
|
||||||
return clientService.getClientById(clientId);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端列表", notes = "客户端列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listclient")
|
|
||||||
public List<ClientDTO> listClient() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return clientService.listClient(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端分页列表", notes = "客户端分页列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "page", value = "当前页码", paramType = "query", dataType = "int", defaultValue = "1"),
|
|
||||||
@ApiImplicitParam(name = "rows", value = "显示数量", paramType = "query", dataType = "int", defaultValue = "20"),
|
|
||||||
@ApiImplicitParam(name = "keywords", value = "关键字", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "startTime", value = "开始时间", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "endTime", value = "结束时间", paramType = "query", dataType = "String")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listpageclient")
|
|
||||||
public SuccessResultList<List<ClientDTO>> listPageClient(ListPage page) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
page.setParams(params);
|
|
||||||
return clientService.listPageClient(page);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端统计", notes = "客户端统计接口")
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("countclient")
|
|
||||||
SuccessResultData<Integer> countClient() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return clientService.countClient(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -1,109 +0,0 @@
|
|||||||
package com.cm.central.control.controller.resources.clientexception;
|
|
||||||
|
|
||||||
import com.cm.common.annotation.CheckRequestBodyAnnotation;
|
|
||||||
import com.cm.common.base.AbstractController;
|
|
||||||
import com.cm.common.constants.ISystemConstant;
|
|
||||||
import com.cm.common.exception.RemoveException;
|
|
||||||
import com.cm.common.exception.SearchException;
|
|
||||||
import com.cm.common.pojo.ListPage;
|
|
||||||
import com.cm.common.result.ErrorResult;
|
|
||||||
import com.cm.common.result.SuccessResult;
|
|
||||||
import com.cm.common.result.SuccessResultData;
|
|
||||||
import com.cm.common.result.SuccessResultList;
|
|
||||||
import com.cm.central.control.pojo.dtos.clientexception.ClientExceptionDTO;
|
|
||||||
import com.cm.central.control.pojo.vos.clientexception.ClientExceptionVO;
|
|
||||||
import com.cm.central.control.service.clientexception.IClientExceptionService;
|
|
||||||
import io.swagger.annotations.*;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.web.bind.annotation.*;
|
|
||||||
|
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @ClassName: ClientExceptionResourceController
|
|
||||||
* @Description: 客户端异常
|
|
||||||
* @Author: WenG
|
|
||||||
* @Date: 2020-07-30 19:13
|
|
||||||
* @Version: 1.0
|
|
||||||
**/
|
|
||||||
@Api(tags = ISystemConstant.API_TAGS_RESOURCE_PREFIX + "客户端异常接口")
|
|
||||||
@RestController
|
|
||||||
@RequestMapping(ISystemConstant.RESOURCE_PREFIX + "/clientexception")
|
|
||||||
public class ClientExceptionResourceController extends AbstractController {
|
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private IClientExceptionService clientExceptionService;
|
|
||||||
|
|
||||||
@ApiOperation(value = "删除客户端异常(id列表)", notes = "删除客户端异常(id列表)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "ids", value = "ID列表,用下划线分隔", paramType = "path", example = "1_2_3")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@DeleteMapping("removeclientexception/{ids}")
|
|
||||||
public SuccessResult removeClientException(@PathVariable("ids") String ids) throws RemoveException {
|
|
||||||
return clientExceptionService.removeClientException(ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "修改客户端异常", notes = "修改客户端异常接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "clientExceptionId", value = "客户端异常ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PutMapping("updateclientexception/{clientExceptionId}")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult updateClientException(@PathVariable("clientExceptionId") String clientExceptionId, @RequestBody ClientExceptionVO clientExceptionVO) throws Exception {
|
|
||||||
return clientExceptionService.updateClientException(clientExceptionId, clientExceptionVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端异常详情(通过ID)", notes = "客户端异常详情(通过ID)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "clientExceptionId", value = "客户端异常ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("getclientexceptionbyid/{clientExceptionId}")
|
|
||||||
public ClientExceptionDTO getClientExceptionById(@PathVariable("clientExceptionId") String clientExceptionId) throws SearchException {
|
|
||||||
return clientExceptionService.getClientExceptionById(clientExceptionId);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端异常列表", notes = "客户端异常列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listclientexception")
|
|
||||||
public List<ClientExceptionDTO> listClientException() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return clientExceptionService.listClientException(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端异常分页列表", notes = "客户端异常分页列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "page", value = "当前页码", paramType = "query", dataType = "int", defaultValue = "1"),
|
|
||||||
@ApiImplicitParam(name = "rows", value = "显示数量", paramType = "query", dataType = "int", defaultValue = "20"),
|
|
||||||
@ApiImplicitParam(name = "keywords", value = "关键字", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "startTime", value = "开始时间", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "endTime", value = "结束时间", paramType = "query", dataType = "String")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listpageclientexception")
|
|
||||||
public SuccessResultList<List<ClientExceptionDTO>> listPageClientException(ListPage page) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
page.setParams(params);
|
|
||||||
return clientExceptionService.listPageClientException(page);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端异常统计", notes = "客户端异常统计接口")
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("countclientexception")
|
|
||||||
SuccessResultData<Integer> countClientException() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return clientExceptionService.countClientException(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -1,119 +0,0 @@
|
|||||||
package com.cm.central.control.controller.resources.customer;
|
|
||||||
|
|
||||||
import com.cm.central.control.pojo.dtos.customer.CustomerDTO;
|
|
||||||
import com.cm.central.control.pojo.vos.customer.CustomerVO;
|
|
||||||
import com.cm.central.control.service.customer.ICustomerService;
|
|
||||||
import com.cm.common.annotation.CheckRequestBodyAnnotation;
|
|
||||||
import com.cm.common.base.AbstractController;
|
|
||||||
import com.cm.common.constants.ISystemConstant;
|
|
||||||
import com.cm.common.exception.RemoveException;
|
|
||||||
import com.cm.common.exception.SearchException;
|
|
||||||
import com.cm.common.pojo.ListPage;
|
|
||||||
import com.cm.common.result.ErrorResult;
|
|
||||||
import com.cm.common.result.SuccessResult;
|
|
||||||
import com.cm.common.result.SuccessResultData;
|
|
||||||
import com.cm.common.result.SuccessResultList;
|
|
||||||
import io.swagger.annotations.*;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.web.bind.annotation.*;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @ClassName: CustomerResourceController
|
|
||||||
* @Description: 客户管理
|
|
||||||
* @Author: WenG
|
|
||||||
* @Date: 2020-07-30 19:00
|
|
||||||
* @Version: 1.0
|
|
||||||
**/
|
|
||||||
@Api(tags = ISystemConstant.API_TAGS_RESOURCE_PREFIX + "客户管理接口")
|
|
||||||
@RestController
|
|
||||||
@RequestMapping(ISystemConstant.RESOURCE_PREFIX + "/customer")
|
|
||||||
public class CustomerResourceController extends AbstractController {
|
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private ICustomerService customerService;
|
|
||||||
|
|
||||||
@ApiOperation(value = "新增客户管理", notes = "新增客户管理接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PostMapping("savecustomer")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult saveCustomer(@RequestBody CustomerVO customerVO) throws Exception {
|
|
||||||
return customerService.saveCustomer(customerVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "删除客户管理(id列表)", notes = "删除客户管理(id列表)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "ids", value = "ID列表,用下划线分隔", paramType = "path", example = "1_2_3")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@DeleteMapping("removecustomer/{ids}")
|
|
||||||
public SuccessResult removeCustomer(@PathVariable("ids") String ids) throws RemoveException {
|
|
||||||
return customerService.removeCustomer(ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "修改客户管理", notes = "修改客户管理接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "customerId", value = "客户管理ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PutMapping("updatecustomer/{customerId}")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult updateCustomer(@PathVariable("customerId") String customerId, @RequestBody CustomerVO customerVO) throws Exception {
|
|
||||||
return customerService.updateCustomer(customerId, customerVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户管理详情(通过ID)", notes = "客户管理详情(通过ID)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "customerId", value = "客户管理ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("getcustomerbyid/{customerId}")
|
|
||||||
public CustomerDTO getCustomerById(@PathVariable("customerId") String customerId) throws SearchException {
|
|
||||||
return customerService.getCustomerById(customerId);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户管理列表", notes = "客户管理列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listcustomer")
|
|
||||||
public List<CustomerDTO> listCustomer() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return customerService.listCustomer(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户管理分页列表", notes = "客户管理分页列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "page", value = "当前页码", paramType = "query", dataType = "int", defaultValue = "1"),
|
|
||||||
@ApiImplicitParam(name = "rows", value = "显示数量", paramType = "query", dataType = "int", defaultValue = "20"),
|
|
||||||
@ApiImplicitParam(name = "keywords", value = "关键字", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "startTime", value = "开始时间", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "endTime", value = "结束时间", paramType = "query", dataType = "String")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listpagecustomer")
|
|
||||||
public SuccessResultList<List<CustomerDTO>> listPageCustomer(ListPage page) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
page.setParams(params);
|
|
||||||
return customerService.listPageCustomer(page);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户管理统计", notes = "客户管理统计接口")
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("countcustomer")
|
|
||||||
SuccessResultData<Integer> countCustomer() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return customerService.countCustomer(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -1,120 +0,0 @@
|
|||||||
package com.cm.central.control.controller.resources.projectleader;
|
|
||||||
|
|
||||||
import com.cm.common.annotation.CheckRequestBodyAnnotation;
|
|
||||||
import com.cm.common.base.AbstractController;
|
|
||||||
import com.cm.common.constants.ISystemConstant;
|
|
||||||
import com.cm.common.exception.RemoveException;
|
|
||||||
import com.cm.common.exception.SearchException;
|
|
||||||
import com.cm.common.pojo.ListPage;
|
|
||||||
import com.cm.common.result.ErrorResult;
|
|
||||||
import com.cm.common.result.SuccessResult;
|
|
||||||
import com.cm.common.result.SuccessResultData;
|
|
||||||
import com.cm.common.result.SuccessResultList;
|
|
||||||
import com.cm.central.control.pojo.dtos.projectleader.ProjectLeaderDTO;
|
|
||||||
import com.cm.central.control.pojo.vos.projectleader.ProjectLeaderVO;
|
|
||||||
import com.cm.central.control.service.projectleader.IProjectLeaderService;
|
|
||||||
import io.swagger.annotations.*;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.web.bind.annotation.*;
|
|
||||||
|
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @ClassName: ProjectLeaderResourceController
|
|
||||||
* @Description: 项目负责人
|
|
||||||
* @Author: WenG
|
|
||||||
* @Date: 2020-07-30 19:04
|
|
||||||
* @Version: 1.0
|
|
||||||
**/
|
|
||||||
@Api(tags = ISystemConstant.API_TAGS_RESOURCE_PREFIX + "项目负责人接口")
|
|
||||||
@RestController
|
|
||||||
@RequestMapping(ISystemConstant.RESOURCE_PREFIX + "/projectleader")
|
|
||||||
public class ProjectLeaderResourceController extends AbstractController {
|
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private IProjectLeaderService projectLeaderService;
|
|
||||||
|
|
||||||
@ApiOperation(value = "新增项目负责人", notes = "新增项目负责人接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PostMapping("saveprojectleader")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult saveProjectLeader(@RequestBody ProjectLeaderVO projectLeaderVO) throws Exception {
|
|
||||||
return projectLeaderService.saveProjectLeader(projectLeaderVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "删除项目负责人(id列表)", notes = "删除项目负责人(id列表)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "ids", value = "ID列表,用下划线分隔", paramType = "path", example = "1_2_3")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@DeleteMapping("removeprojectleader/{ids}")
|
|
||||||
public SuccessResult removeProjectLeader(@PathVariable("ids") String ids) throws RemoveException {
|
|
||||||
return projectLeaderService.removeProjectLeader(ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "修改项目负责人", notes = "修改项目负责人接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "projectLeaderId", value = "项目负责人ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@PutMapping("updateprojectleader/{projectLeaderId}")
|
|
||||||
@CheckRequestBodyAnnotation
|
|
||||||
public SuccessResult updateProjectLeader(@PathVariable("projectLeaderId") String projectLeaderId, @RequestBody ProjectLeaderVO projectLeaderVO) throws Exception {
|
|
||||||
return projectLeaderService.updateProjectLeader(projectLeaderId, projectLeaderVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "项目负责人详情(通过ID)", notes = "项目负责人详情(通过ID)接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "projectLeaderId", value = "项目负责人ID", paramType = "path")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("getprojectleaderbyid/{projectLeaderId}")
|
|
||||||
public ProjectLeaderDTO getProjectLeaderById(@PathVariable("projectLeaderId") String projectLeaderId) throws SearchException {
|
|
||||||
return projectLeaderService.getProjectLeaderById(projectLeaderId);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "项目负责人列表", notes = "项目负责人列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listprojectleader")
|
|
||||||
public List<ProjectLeaderDTO> listProjectLeader() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return projectLeaderService.listProjectLeader(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "项目负责人分页列表", notes = "项目负责人分页列表接口")
|
|
||||||
@ApiImplicitParams({
|
|
||||||
@ApiImplicitParam(name = "access_token", value = "access_token", paramType = "query"),
|
|
||||||
@ApiImplicitParam(name = "page", value = "当前页码", paramType = "query", dataType = "int", defaultValue = "1"),
|
|
||||||
@ApiImplicitParam(name = "rows", value = "显示数量", paramType = "query", dataType = "int", defaultValue = "20"),
|
|
||||||
@ApiImplicitParam(name = "keywords", value = "关键字", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "startTime", value = "开始时间", paramType = "query", dataType = "String"),
|
|
||||||
@ApiImplicitParam(name = "endTime", value = "结束时间", paramType = "query", dataType = "String")
|
|
||||||
})
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("listpageprojectleader")
|
|
||||||
public SuccessResultList<List<ProjectLeaderDTO>> listPageProjectLeader(ListPage page) throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
page.setParams(params);
|
|
||||||
return projectLeaderService.listPageProjectLeader(page);
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "项目负责人统计", notes = "项目负责人统计接口")
|
|
||||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
|
||||||
@GetMapping("countprojectleader")
|
|
||||||
SuccessResultData<Integer> countProjectLeader() throws SearchException {
|
|
||||||
Map<String, Object> params = requestParams();
|
|
||||||
return projectLeaderService.countProjectLeader(params);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -29,16 +29,10 @@ public class ClientExceptionRouteController {
|
|||||||
return new ModelAndView("clientexception/list-clientexception");
|
return new ModelAndView("clientexception/list-clientexception");
|
||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation(value = "客户端异常新增")
|
|
||||||
@GetMapping("saveclientexception")
|
|
||||||
public ModelAndView saveClientexception() {
|
|
||||||
return new ModelAndView("clientexception/save-clientexception");
|
|
||||||
}
|
|
||||||
|
|
||||||
@ApiOperation(value = "客户端异常编辑")
|
@ApiOperation(value = "客户端异常编辑")
|
||||||
@GetMapping("updateclientexception")
|
@GetMapping("getclientexception")
|
||||||
public ModelAndView updateClientexception() {
|
public ModelAndView getClientexception() {
|
||||||
return new ModelAndView("clientexception/update-clientexception");
|
return new ModelAndView("clientexception/get-clientexception");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -41,4 +41,6 @@ public class ProjectLeaderRouteController {
|
|||||||
return new ModelAndView("projectleader/update-projectleader");
|
return new ModelAndView("projectleader/update-projectleader");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -4,7 +4,6 @@ import io.swagger.annotations.ApiModel;
|
|||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @ClassName: ClientExceptionDTO
|
* @ClassName: ClientExceptionDTO
|
||||||
* @Description: 客户端异常
|
* @Description: 客户端异常
|
||||||
* @Author: WenG
|
* @Author: WenG
|
||||||
@ -20,34 +19,10 @@ public class ClientExceptionDTO {
|
|||||||
private String clientId;
|
private String clientId;
|
||||||
@ApiModelProperty(name = "clientClientName", value = "名称")
|
@ApiModelProperty(name = "clientClientName", value = "名称")
|
||||||
private String clientClientName;
|
private String clientClientName;
|
||||||
@ApiModelProperty(name = "clientClientSummary", value = "描述")
|
|
||||||
private String clientClientSummary;
|
|
||||||
@ApiModelProperty(name = "clientClientVersion", value = "客户端版本")
|
@ApiModelProperty(name = "clientClientVersion", value = "客户端版本")
|
||||||
private String clientClientVersion;
|
private String clientClientVersion;
|
||||||
@ApiModelProperty(name = "clientDatabaseType", value = "数据库类型")
|
|
||||||
private String clientDatabaseType;
|
|
||||||
@ApiModelProperty(name = "clientDatabaseVersion", value = "数据库版本")
|
|
||||||
private String clientDatabaseVersion;
|
|
||||||
@ApiModelProperty(name = "clientDatabaseName", value = "数据库名称")
|
|
||||||
private String clientDatabaseName;
|
|
||||||
@ApiModelProperty(name = "clientCustomerId", value = "客户ID")
|
|
||||||
private String clientCustomerId;
|
|
||||||
@ApiModelProperty(name = "clientServerIp", value = "服务器地址")
|
@ApiModelProperty(name = "clientServerIp", value = "服务器地址")
|
||||||
private String clientServerIp;
|
private String clientServerIp;
|
||||||
@ApiModelProperty(name = "clientIsUsercenter", value = "是否")
|
|
||||||
private String clientIsUsercenter;
|
|
||||||
@ApiModelProperty(name = "clientIsOnlyAuthorization", value = "是否在线授权")
|
|
||||||
private String clientIsOnlyAuthorization;
|
|
||||||
@ApiModelProperty(name = "clientMacAddress", value = "mac地址")
|
|
||||||
private String clientMacAddress;
|
|
||||||
@ApiModelProperty(name = "clientLicenseStartTime", value = "秘钥开始时间")
|
|
||||||
private String clientLicenseStartTime;
|
|
||||||
@ApiModelProperty(name = "clientLicenseEffectiveDays", value = "秘钥有效天数")
|
|
||||||
private String clientLicenseEffectiveDays;
|
|
||||||
@ApiModelProperty(name = "clientLicenseExpirationDate", value = "秘钥到期时间")
|
|
||||||
private String clientLicenseExpirationDate;
|
|
||||||
@ApiModelProperty(name = "clientAuthorizationCount", value = "授权次数")
|
|
||||||
private String clientAuthorizationCount;
|
|
||||||
@ApiModelProperty(name = "exceptionType", value = "异常类型")
|
@ApiModelProperty(name = "exceptionType", value = "异常类型")
|
||||||
private String exceptionType;
|
private String exceptionType;
|
||||||
@ApiModelProperty(name = "exceptionName", value = "异常名称")
|
@ApiModelProperty(name = "exceptionName", value = "异常名称")
|
||||||
@ -58,6 +33,8 @@ public class ClientExceptionDTO {
|
|||||||
private Integer isNoticeProjectLeader;
|
private Integer isNoticeProjectLeader;
|
||||||
@ApiModelProperty(name = "isHandle", value = "是否处理")
|
@ApiModelProperty(name = "isHandle", value = "是否处理")
|
||||||
private Integer isHandle;
|
private Integer isHandle;
|
||||||
|
@ApiModelProperty(name = "gmtCreate", value = "上报时间")
|
||||||
|
private String gmtCreate;
|
||||||
|
|
||||||
public String getClientExceptionId() {
|
public String getClientExceptionId() {
|
||||||
return clientExceptionId == null ? "" : clientExceptionId.trim();
|
return clientExceptionId == null ? "" : clientExceptionId.trim();
|
||||||
@ -83,14 +60,6 @@ public class ClientExceptionDTO {
|
|||||||
this.clientClientName = clientClientName;
|
this.clientClientName = clientClientName;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getClientClientSummary() {
|
|
||||||
return clientClientSummary == null ? "" : clientClientSummary.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientClientSummary(String clientClientSummary) {
|
|
||||||
this.clientClientSummary = clientClientSummary;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientClientVersion() {
|
public String getClientClientVersion() {
|
||||||
return clientClientVersion == null ? "" : clientClientVersion.trim();
|
return clientClientVersion == null ? "" : clientClientVersion.trim();
|
||||||
}
|
}
|
||||||
@ -99,38 +68,6 @@ public class ClientExceptionDTO {
|
|||||||
this.clientClientVersion = clientClientVersion;
|
this.clientClientVersion = clientClientVersion;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getClientDatabaseType() {
|
|
||||||
return clientDatabaseType == null ? "" : clientDatabaseType.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientDatabaseType(String clientDatabaseType) {
|
|
||||||
this.clientDatabaseType = clientDatabaseType;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientDatabaseVersion() {
|
|
||||||
return clientDatabaseVersion == null ? "" : clientDatabaseVersion.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientDatabaseVersion(String clientDatabaseVersion) {
|
|
||||||
this.clientDatabaseVersion = clientDatabaseVersion;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientDatabaseName() {
|
|
||||||
return clientDatabaseName == null ? "" : clientDatabaseName.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientDatabaseName(String clientDatabaseName) {
|
|
||||||
this.clientDatabaseName = clientDatabaseName;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientCustomerId() {
|
|
||||||
return clientCustomerId == null ? "" : clientCustomerId.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientCustomerId(String clientCustomerId) {
|
|
||||||
this.clientCustomerId = clientCustomerId;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientServerIp() {
|
public String getClientServerIp() {
|
||||||
return clientServerIp == null ? "" : clientServerIp.trim();
|
return clientServerIp == null ? "" : clientServerIp.trim();
|
||||||
}
|
}
|
||||||
@ -139,62 +76,6 @@ public class ClientExceptionDTO {
|
|||||||
this.clientServerIp = clientServerIp;
|
this.clientServerIp = clientServerIp;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getClientIsUsercenter() {
|
|
||||||
return clientIsUsercenter == null ? "" : clientIsUsercenter.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientIsUsercenter(String clientIsUsercenter) {
|
|
||||||
this.clientIsUsercenter = clientIsUsercenter;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientIsOnlyAuthorization() {
|
|
||||||
return clientIsOnlyAuthorization == null ? "" : clientIsOnlyAuthorization.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientIsOnlyAuthorization(String clientIsOnlyAuthorization) {
|
|
||||||
this.clientIsOnlyAuthorization = clientIsOnlyAuthorization;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientMacAddress() {
|
|
||||||
return clientMacAddress == null ? "" : clientMacAddress.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientMacAddress(String clientMacAddress) {
|
|
||||||
this.clientMacAddress = clientMacAddress;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientLicenseStartTime() {
|
|
||||||
return clientLicenseStartTime == null ? "" : clientLicenseStartTime.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientLicenseStartTime(String clientLicenseStartTime) {
|
|
||||||
this.clientLicenseStartTime = clientLicenseStartTime;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientLicenseEffectiveDays() {
|
|
||||||
return clientLicenseEffectiveDays == null ? "" : clientLicenseEffectiveDays.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientLicenseEffectiveDays(String clientLicenseEffectiveDays) {
|
|
||||||
this.clientLicenseEffectiveDays = clientLicenseEffectiveDays;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientLicenseExpirationDate() {
|
|
||||||
return clientLicenseExpirationDate == null ? "" : clientLicenseExpirationDate.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientLicenseExpirationDate(String clientLicenseExpirationDate) {
|
|
||||||
this.clientLicenseExpirationDate = clientLicenseExpirationDate;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getClientAuthorizationCount() {
|
|
||||||
return clientAuthorizationCount == null ? "" : clientAuthorizationCount.trim();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setClientAuthorizationCount(String clientAuthorizationCount) {
|
|
||||||
this.clientAuthorizationCount = clientAuthorizationCount;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getExceptionType() {
|
public String getExceptionType() {
|
||||||
return exceptionType == null ? "" : exceptionType.trim();
|
return exceptionType == null ? "" : exceptionType.trim();
|
||||||
}
|
}
|
||||||
@ -220,7 +101,7 @@ public class ClientExceptionDTO {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public Integer getIsNoticeProjectLeader() {
|
public Integer getIsNoticeProjectLeader() {
|
||||||
return isNoticeProjectLeader == null ? 0 : isNoticeProjectLeader;
|
return isNoticeProjectLeader;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setIsNoticeProjectLeader(Integer isNoticeProjectLeader) {
|
public void setIsNoticeProjectLeader(Integer isNoticeProjectLeader) {
|
||||||
@ -228,12 +109,47 @@ public class ClientExceptionDTO {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public Integer getIsHandle() {
|
public Integer getIsHandle() {
|
||||||
return isHandle == null ? 0 : isHandle;
|
return isHandle;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setIsHandle(Integer isHandle) {
|
public void setIsHandle(Integer isHandle) {
|
||||||
this.isHandle = isHandle;
|
this.isHandle = isHandle;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getGmtCreate() {
|
||||||
|
return gmtCreate == null ? "" : gmtCreate.trim();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setGmtCreate(String gmtCreate) {
|
||||||
|
this.gmtCreate = gmtCreate;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
final StringBuilder sb = new StringBuilder("{");
|
||||||
|
sb.append("\"clientExceptionId\":")
|
||||||
|
.append("\"").append(clientExceptionId).append("\"");
|
||||||
|
sb.append(",\"clientId\":")
|
||||||
|
.append("\"").append(clientId).append("\"");
|
||||||
|
sb.append(",\"clientClientName\":")
|
||||||
|
.append("\"").append(clientClientName).append("\"");
|
||||||
|
sb.append(",\"clientClientVersion\":")
|
||||||
|
.append("\"").append(clientClientVersion).append("\"");
|
||||||
|
sb.append(",\"clientServerIp\":")
|
||||||
|
.append("\"").append(clientServerIp).append("\"");
|
||||||
|
sb.append(",\"exceptionType\":")
|
||||||
|
.append("\"").append(exceptionType).append("\"");
|
||||||
|
sb.append(",\"exceptionName\":")
|
||||||
|
.append("\"").append(exceptionName).append("\"");
|
||||||
|
sb.append(",\"exceptionSummary\":")
|
||||||
|
.append("\"").append(exceptionSummary).append("\"");
|
||||||
|
sb.append(",\"isNoticeProjectLeader\":")
|
||||||
|
.append(isNoticeProjectLeader);
|
||||||
|
sb.append(",\"isHandle\":")
|
||||||
|
.append(isHandle);
|
||||||
|
sb.append(",\"gmtCreate\":")
|
||||||
|
.append("\"").append(gmtCreate).append("\"");
|
||||||
|
sb.append('}');
|
||||||
|
return sb.toString();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -18,6 +18,10 @@ public class ProjectLeaderDTO {
|
|||||||
private String projectLeaderId;
|
private String projectLeaderId;
|
||||||
@ApiModelProperty(name = "leaderName", value = "姓名")
|
@ApiModelProperty(name = "leaderName", value = "姓名")
|
||||||
private String leaderName;
|
private String leaderName;
|
||||||
|
@ApiModelProperty(name = "leaderUserId", value = "用户ID")
|
||||||
|
private String leaderUserId;
|
||||||
|
@ApiModelProperty(name = "leaderUserName", value = "用户昵称")
|
||||||
|
private String leaderUserName;
|
||||||
@ApiModelProperty(name = "leaderPhone", value = "手机")
|
@ApiModelProperty(name = "leaderPhone", value = "手机")
|
||||||
private String leaderPhone;
|
private String leaderPhone;
|
||||||
@ApiModelProperty(name = "leaderEmail", value = "邮箱")
|
@ApiModelProperty(name = "leaderEmail", value = "邮箱")
|
||||||
@ -39,6 +43,22 @@ public class ProjectLeaderDTO {
|
|||||||
this.leaderName = leaderName;
|
this.leaderName = leaderName;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getLeaderUserId() {
|
||||||
|
return leaderUserId == null ? "" : leaderUserId.trim();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setLeaderUserId(String leaderUserId) {
|
||||||
|
this.leaderUserId = leaderUserId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getLeaderUserName() {
|
||||||
|
return leaderUserName == null ? "" : leaderUserName.trim();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setLeaderUserName(String leaderUserName) {
|
||||||
|
this.leaderUserName = leaderUserName;
|
||||||
|
}
|
||||||
|
|
||||||
public String getLeaderPhone() {
|
public String getLeaderPhone() {
|
||||||
return leaderPhone == null ? "" : leaderPhone.trim();
|
return leaderPhone == null ? "" : leaderPhone.trim();
|
||||||
}
|
}
|
||||||
@ -55,5 +75,22 @@ public class ProjectLeaderDTO {
|
|||||||
this.leaderEmail = leaderEmail;
|
this.leaderEmail = leaderEmail;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
final StringBuilder sb = new StringBuilder("{");
|
||||||
|
sb.append("\"projectLeaderId\":")
|
||||||
|
.append("\"").append(projectLeaderId).append("\"");
|
||||||
|
sb.append(",\"leaderName\":")
|
||||||
|
.append("\"").append(leaderName).append("\"");
|
||||||
|
sb.append(",\"leaderUserId\":")
|
||||||
|
.append("\"").append(leaderUserId).append("\"");
|
||||||
|
sb.append(",\"leaderUserName\":")
|
||||||
|
.append("\"").append(leaderUserName).append("\"");
|
||||||
|
sb.append(",\"leaderPhone\":")
|
||||||
|
.append("\"").append(leaderPhone).append("\"");
|
||||||
|
sb.append(",\"leaderEmail\":")
|
||||||
|
.append("\"").append(leaderEmail).append("\"");
|
||||||
|
sb.append('}');
|
||||||
|
return sb.toString();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -18,6 +18,12 @@ import java.io.Serializable;
|
|||||||
@ApiModel
|
@ApiModel
|
||||||
public class ProjectLeaderVO {
|
public class ProjectLeaderVO {
|
||||||
|
|
||||||
|
@ApiModelProperty(name = "leaderUserId", value = "用户ID")
|
||||||
|
@CheckEmptyAnnotation(name = "用户ID")
|
||||||
|
private String leaderUserId;
|
||||||
|
@ApiModelProperty(name = "leaderUserName", value = "用户昵称")
|
||||||
|
@CheckEmptyAnnotation(name = "用户昵称")
|
||||||
|
private String leaderUserName;
|
||||||
@ApiModelProperty(name = "leaderName", value = "姓名")
|
@ApiModelProperty(name = "leaderName", value = "姓名")
|
||||||
@CheckEmptyAnnotation(name = "姓名")
|
@CheckEmptyAnnotation(name = "姓名")
|
||||||
private String leaderName;
|
private String leaderName;
|
||||||
@ -28,6 +34,22 @@ public class ProjectLeaderVO {
|
|||||||
@CheckEmptyAnnotation(name = "邮箱", verifyType = "email")
|
@CheckEmptyAnnotation(name = "邮箱", verifyType = "email")
|
||||||
private String leaderEmail;
|
private String leaderEmail;
|
||||||
|
|
||||||
|
public String getLeaderUserId() {
|
||||||
|
return leaderUserId == null ? "" : leaderUserId.trim();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setLeaderUserId(String leaderUserId) {
|
||||||
|
this.leaderUserId = leaderUserId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getLeaderUserName() {
|
||||||
|
return leaderUserName == null ? "" : leaderUserName.trim();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setLeaderUserName(String leaderUserName) {
|
||||||
|
this.leaderUserName = leaderUserName;
|
||||||
|
}
|
||||||
|
|
||||||
public String getLeaderName() {
|
public String getLeaderName() {
|
||||||
return leaderName == null ? "" : leaderName.trim();
|
return leaderName == null ? "" : leaderName.trim();
|
||||||
}
|
}
|
||||||
@ -52,6 +74,20 @@ public class ProjectLeaderVO {
|
|||||||
this.leaderEmail = leaderEmail;
|
this.leaderEmail = leaderEmail;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
final StringBuilder sb = new StringBuilder("{");
|
||||||
|
sb.append("\"leaderUserId\":")
|
||||||
|
.append("\"").append(leaderUserId).append("\"");
|
||||||
|
sb.append(",\"leaderUserName\":")
|
||||||
|
.append("\"").append(leaderUserName).append("\"");
|
||||||
|
sb.append(",\"leaderName\":")
|
||||||
|
.append("\"").append(leaderName).append("\"");
|
||||||
|
sb.append(",\"leaderPhone\":")
|
||||||
|
.append("\"").append(leaderPhone).append("\"");
|
||||||
|
sb.append(",\"leaderEmail\":")
|
||||||
|
.append("\"").append(leaderEmail).append("\"");
|
||||||
|
sb.append('}');
|
||||||
|
return sb.toString();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -3,6 +3,7 @@ package com.cm.central.control.service.clientexception;
|
|||||||
import com.cm.common.exception.RemoveException;
|
import com.cm.common.exception.RemoveException;
|
||||||
import com.cm.common.exception.SaveException;
|
import com.cm.common.exception.SaveException;
|
||||||
import com.cm.common.exception.SearchException;
|
import com.cm.common.exception.SearchException;
|
||||||
|
import com.cm.common.exception.UpdateException;
|
||||||
import com.cm.common.pojo.ListPage;
|
import com.cm.common.pojo.ListPage;
|
||||||
import com.cm.common.result.SuccessResult;
|
import com.cm.common.result.SuccessResult;
|
||||||
import com.cm.common.result.SuccessResultData;
|
import com.cm.common.result.SuccessResultData;
|
||||||
@ -124,4 +125,12 @@ public interface IClientExceptionService {
|
|||||||
*/
|
*/
|
||||||
SuccessResultData<Integer> countClientException(Map<String, Object> params) throws SearchException;
|
SuccessResultData<Integer> countClientException(Map<String, Object> params) throws SearchException;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 标记处理成功
|
||||||
|
*
|
||||||
|
* @param clientExceptionId
|
||||||
|
* @return
|
||||||
|
* @throws UpdateException
|
||||||
|
*/
|
||||||
|
SuccessResult updateIsHandlerByClientExceptionId(String clientExceptionId) throws UpdateException;
|
||||||
}
|
}
|
@ -4,6 +4,7 @@ import com.cm.common.base.AbstractService;
|
|||||||
import com.cm.common.exception.RemoveException;
|
import com.cm.common.exception.RemoveException;
|
||||||
import com.cm.common.exception.SaveException;
|
import com.cm.common.exception.SaveException;
|
||||||
import com.cm.common.exception.SearchException;
|
import com.cm.common.exception.SearchException;
|
||||||
|
import com.cm.common.exception.UpdateException;
|
||||||
import com.cm.common.pojo.ListPage;
|
import com.cm.common.pojo.ListPage;
|
||||||
import com.cm.common.result.SuccessResult;
|
import com.cm.common.result.SuccessResult;
|
||||||
import com.cm.common.result.SuccessResultData;
|
import com.cm.common.result.SuccessResultData;
|
||||||
@ -141,4 +142,15 @@ public class ClientExceptionServiceImpl extends AbstractService implements IClie
|
|||||||
return new SuccessResultData<>(countNumberClientException(params));
|
return new SuccessResultData<>(countNumberClientException(params));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public SuccessResult updateIsHandlerByClientExceptionId(String clientExceptionId) throws UpdateException {
|
||||||
|
Map<String, Object> params = getHashMap(2);
|
||||||
|
params.put("clientExceptionId", clientExceptionId);
|
||||||
|
params.put("isHandle", 1);
|
||||||
|
params.put("isNoticeProjectLeader", 1);
|
||||||
|
setUpdateInfo(params);
|
||||||
|
clientExceptionDao.updateClientException(params);
|
||||||
|
return new SuccessResult();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
@ -282,10 +282,7 @@
|
|||||||
t1.is_delete = 0
|
t1.is_delete = 0
|
||||||
<if test="keywords != null and keywords != ''">
|
<if test="keywords != null and keywords != ''">
|
||||||
AND (
|
AND (
|
||||||
t1.id LIKE CONCAT('%', #{keywords}, '%')
|
t1.client_name LIKE CONCAT('%', #{keywords}, '%')
|
||||||
OR
|
|
||||||
t1.client_id LIKE CONCAT('%', #{keywords}, '%')
|
|
||||||
<!-- 这里添加其他条件 -->
|
|
||||||
)
|
)
|
||||||
</if>
|
</if>
|
||||||
<if test="startTime != null and startTime != ''">
|
<if test="startTime != null and startTime != ''">
|
||||||
|
@ -6,25 +6,14 @@
|
|||||||
<id column="client_exception_id" property="clientExceptionId"/>
|
<id column="client_exception_id" property="clientExceptionId"/>
|
||||||
<result column="client_id" property="clientId"/>
|
<result column="client_id" property="clientId"/>
|
||||||
<result column="client_client_name" property="clientClientName"/>
|
<result column="client_client_name" property="clientClientName"/>
|
||||||
<result column="client_client_summary" property="clientClientSummary"/>
|
|
||||||
<result column="client_client_version" property="clientClientVersion"/>
|
<result column="client_client_version" property="clientClientVersion"/>
|
||||||
<result column="client_database_type" property="clientDatabaseType"/>
|
|
||||||
<result column="client_database_version" property="clientDatabaseVersion"/>
|
|
||||||
<result column="client_database_name" property="clientDatabaseName"/>
|
|
||||||
<result column="client_customer_id" property="clientCustomerId"/>
|
|
||||||
<result column="client_server_ip" property="clientServerIp"/>
|
<result column="client_server_ip" property="clientServerIp"/>
|
||||||
<result column="client_is_usercenter" property="clientIsUsercenter"/>
|
|
||||||
<result column="client_is_only_authorization" property="clientIsOnlyAuthorization"/>
|
|
||||||
<result column="client_mac_address" property="clientMacAddress"/>
|
|
||||||
<result column="client_license_start_time" property="clientLicenseStartTime"/>
|
|
||||||
<result column="client_license_effective_days" property="clientLicenseEffectiveDays"/>
|
|
||||||
<result column="client_license_expiration_date" property="clientLicenseExpirationDate"/>
|
|
||||||
<result column="client_authorization_count" property="clientAuthorizationCount"/>
|
|
||||||
<result column="exception_type" property="exceptionType"/>
|
<result column="exception_type" property="exceptionType"/>
|
||||||
<result column="exception_name" property="exceptionName"/>
|
<result column="exception_name" property="exceptionName"/>
|
||||||
<result column="exception_summary" property="exceptionSummary"/>
|
<result column="exception_summary" property="exceptionSummary"/>
|
||||||
<result column="is_notice_project_leader" property="isNoticeProjectLeader"/>
|
<result column="is_notice_project_leader" property="isNoticeProjectLeader"/>
|
||||||
<result column="is_handle" property="isHandle"/>
|
<result column="is_handle" property="isHandle"/>
|
||||||
|
<result column="gmt_create" property="gmtCreate"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<!-- 新增客户端异常 -->
|
<!-- 新增客户端异常 -->
|
||||||
@ -61,13 +50,13 @@
|
|||||||
<!-- 删除客户端异常 -->
|
<!-- 删除客户端异常 -->
|
||||||
<update id="removeClientException" parameterType="map">
|
<update id="removeClientException" parameterType="map">
|
||||||
UPDATE
|
UPDATE
|
||||||
central_client_exception
|
central_client_exception
|
||||||
SET
|
SET
|
||||||
is_delete = 1,
|
is_delete = 1,
|
||||||
modifier = #{modifier},
|
modifier = #{modifier},
|
||||||
gmt_modified = #{gmtModified}
|
gmt_modified = #{gmtModified}
|
||||||
WHERE
|
WHERE
|
||||||
client_exception_id IN
|
client_exception_id IN
|
||||||
<foreach collection="clientExceptionIds" index="index" open="(" separator="," close=")">
|
<foreach collection="clientExceptionIds" index="index" open="(" separator="," close=")">
|
||||||
#{clientExceptionIds[${index}]}
|
#{clientExceptionIds[${index}]}
|
||||||
</foreach>
|
</foreach>
|
||||||
@ -76,9 +65,9 @@
|
|||||||
<!-- 删除客户端异常(物理) -->
|
<!-- 删除客户端异常(物理) -->
|
||||||
<update id="deleteClientException" parameterType="map">
|
<update id="deleteClientException" parameterType="map">
|
||||||
DELETE FROM
|
DELETE FROM
|
||||||
central_client_exception
|
central_client_exception
|
||||||
WHERE
|
WHERE
|
||||||
client_exception_id IN
|
client_exception_id IN
|
||||||
<foreach collection="clientExceptionIds" index="index" open="(" separator="," close=")">
|
<foreach collection="clientExceptionIds" index="index" open="(" separator="," close=")">
|
||||||
#{clientExceptionIds[${index}]}
|
#{clientExceptionIds[${index}]}
|
||||||
</foreach>
|
</foreach>
|
||||||
@ -87,7 +76,7 @@
|
|||||||
<!-- 修改客户端异常 -->
|
<!-- 修改客户端异常 -->
|
||||||
<update id="updateClientException" parameterType="map">
|
<update id="updateClientException" parameterType="map">
|
||||||
UPDATE
|
UPDATE
|
||||||
central_client_exception
|
central_client_exception
|
||||||
SET
|
SET
|
||||||
<if test="clientId != null and clientId != ''">
|
<if test="clientId != null and clientId != ''">
|
||||||
client_id = #{clientId},
|
client_id = #{clientId},
|
||||||
@ -107,8 +96,8 @@
|
|||||||
<if test="isHandle != null">
|
<if test="isHandle != null">
|
||||||
is_handle = #{isHandle},
|
is_handle = #{isHandle},
|
||||||
</if>
|
</if>
|
||||||
modifier = #{modifier},
|
modifier = #{modifier},
|
||||||
gmt_modified = #{gmtModified}
|
gmt_modified = #{gmtModified}
|
||||||
WHERE
|
WHERE
|
||||||
client_exception_id = #{clientExceptionId}
|
client_exception_id = #{clientExceptionId}
|
||||||
</update>
|
</update>
|
||||||
@ -116,17 +105,18 @@
|
|||||||
<!-- 客户端异常详情 -->
|
<!-- 客户端异常详情 -->
|
||||||
<select id="getClientException" parameterType="map" resultMap="clientExceptionDTO">
|
<select id="getClientException" parameterType="map" resultMap="clientExceptionDTO">
|
||||||
SELECT
|
SELECT
|
||||||
t1.client_id,
|
t1.client_id,
|
||||||
t1.exception_type,
|
t1.exception_type,
|
||||||
t1.exception_name,
|
t1.exception_name,
|
||||||
t1.exception_summary,
|
t1.exception_summary,
|
||||||
t1.is_notice_project_leader,
|
t1.is_notice_project_leader,
|
||||||
t1.is_handle,
|
t1.is_handle,
|
||||||
t1.client_exception_id
|
LEFT(t1.gmt_create, 19) gmt_create,
|
||||||
|
t1.client_exception_id
|
||||||
FROM
|
FROM
|
||||||
central_client_exception t1
|
central_client_exception t1
|
||||||
WHERE
|
WHERE
|
||||||
t1.is_delete = 0
|
t1.is_delete = 0
|
||||||
<if test="clientExceptionId != null and clientExceptionId != ''">
|
<if test="clientExceptionId != null and clientExceptionId != ''">
|
||||||
AND
|
AND
|
||||||
t1.client_exception_id = #{clientExceptionId}
|
t1.client_exception_id = #{clientExceptionId}
|
||||||
@ -136,59 +126,50 @@
|
|||||||
<!-- 客户端异常列表 -->
|
<!-- 客户端异常列表 -->
|
||||||
<select id="listClientException" parameterType="map" resultMap="clientExceptionDTO">
|
<select id="listClientException" parameterType="map" resultMap="clientExceptionDTO">
|
||||||
SELECT
|
SELECT
|
||||||
jt1.client_name client_client_name,
|
jt1.client_name client_client_name,
|
||||||
jt1.client_summary client_client_summary,
|
jt1.client_version client_client_version,
|
||||||
jt1.client_version client_client_version,
|
jt1.customer_id client_customer_id,
|
||||||
jt1.database_type client_database_type,
|
jt1.server_ip client_server_ip,
|
||||||
jt1.database_version client_database_version,
|
t1.exception_type,
|
||||||
jt1.database_name client_database_name,
|
t1.exception_name,
|
||||||
jt1.customer_id client_customer_id,
|
t1.is_notice_project_leader,
|
||||||
jt1.server_ip client_server_ip,
|
t1.is_handle,
|
||||||
jt1.is_usercenter client_is_usercenter,
|
LEFT(t1.gmt_create, 19) gmt_create,
|
||||||
jt1.is_only_authorization client_is_only_authorization,
|
t1.client_exception_id
|
||||||
jt1.mac_address client_mac_address,
|
|
||||||
jt1.license_start_time client_license_start_time,
|
|
||||||
jt1.license_effective_days client_license_effective_days,
|
|
||||||
jt1.license_expiration_date client_license_expiration_date,
|
|
||||||
jt1.authorization_count client_authorization_count,
|
|
||||||
t1.exception_type,
|
|
||||||
t1.exception_name,
|
|
||||||
t1.is_notice_project_leader,
|
|
||||||
t1.is_handle,
|
|
||||||
t1.client_exception_id
|
|
||||||
FROM
|
FROM
|
||||||
central_client_exception t1
|
central_client_exception t1
|
||||||
LEFT JOIN
|
LEFT JOIN
|
||||||
central_client jt1
|
central_client jt1
|
||||||
ON
|
ON
|
||||||
t1.client_id = jt1.client_id
|
t1.client_id = jt1.client_id
|
||||||
AND
|
AND
|
||||||
jt1.is_delete = 0
|
jt1.is_delete = 0
|
||||||
WHERE
|
WHERE
|
||||||
t1.is_delete = 0
|
t1.is_delete = 0
|
||||||
<if test="keywords != null and keywords != ''">
|
<if test="keywords != null and keywords != ''">
|
||||||
AND (
|
AND (
|
||||||
t1.id LIKE CONCAT('%', #{keywords}, '%')
|
t1.client_name LIKE CONCAT('%', #{keywords}, '%')
|
||||||
OR
|
OR
|
||||||
t1.client_exception_id LIKE CONCAT('%', #{keywords}, '%')
|
t1.exception_name LIKE CONCAT('%', #{keywords}, '%')
|
||||||
<!-- 这里添加其他条件 -->
|
)
|
||||||
)
|
|
||||||
</if>
|
</if>
|
||||||
<if test="startTime != null and startTime != ''">
|
<if test="startTime != null and startTime != ''">
|
||||||
AND
|
AND
|
||||||
LEFT(t1.gmt_create, 10) <![CDATA[ >= ]]> #{startTime}
|
LEFT(t1.gmt_create, 10) <![CDATA[ >= ]]> #{startTime}
|
||||||
</if>
|
</if>
|
||||||
<if test="endTime != null and endTime != ''">
|
<if test="endTime != null and endTime != ''">
|
||||||
AND
|
AND
|
||||||
LEFT(t1.gmt_create, 10) <![CDATA[ <= ]]> #{endTime}
|
LEFT(t1.gmt_create, 10) <![CDATA[ <= ]]> #{endTime}
|
||||||
</if>
|
</if>
|
||||||
<if test="clientExceptionIds != null and clientExceptionIds.size > 0">
|
<if test="clientExceptionIds != null and clientExceptionIds.size > 0">
|
||||||
AND
|
AND
|
||||||
t1.client_exception_id IN
|
t1.client_exception_id IN
|
||||||
<foreach collection="clientExceptionIds" index="index" open="(" separator="," close=")">
|
<foreach collection="clientExceptionIds" index="index" open="(" separator="," close=")">
|
||||||
#{clientExceptionIds[${index}]}
|
#{clientExceptionIds[${index}]}
|
||||||
</foreach>
|
</foreach>
|
||||||
</if>
|
</if>
|
||||||
|
ORDER BY
|
||||||
|
t1.gmt_create DESC
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!-- 客户端异常统计 -->
|
<!-- 客户端异常统计 -->
|
||||||
|
@ -293,10 +293,7 @@
|
|||||||
t1.is_delete = 0
|
t1.is_delete = 0
|
||||||
<if test="keywords != null and keywords != ''">
|
<if test="keywords != null and keywords != ''">
|
||||||
AND (
|
AND (
|
||||||
t1.id LIKE CONCAT('%', #{keywords}, '%')
|
t1.customer_name LIKE CONCAT('%', #{keywords}, '%')
|
||||||
OR
|
|
||||||
t1.customer_id LIKE CONCAT('%', #{keywords}, '%')
|
|
||||||
<!-- 这里添加其他条件 -->
|
|
||||||
)
|
)
|
||||||
</if>
|
</if>
|
||||||
<if test="startTime != null and startTime != ''">
|
<if test="startTime != null and startTime != ''">
|
||||||
|
@ -4,6 +4,8 @@
|
|||||||
|
|
||||||
<resultMap id="projectLeaderDTO" type="com.cm.central.control.pojo.dtos.projectleader.ProjectLeaderDTO">
|
<resultMap id="projectLeaderDTO" type="com.cm.central.control.pojo.dtos.projectleader.ProjectLeaderDTO">
|
||||||
<id column="project_leader_id" property="projectLeaderId"/>
|
<id column="project_leader_id" property="projectLeaderId"/>
|
||||||
|
<result column="leader_user_id" property="leaderUserId"/>
|
||||||
|
<result column="leader_user_name" property="leaderUserName"/>
|
||||||
<result column="leader_name" property="leaderName"/>
|
<result column="leader_name" property="leaderName"/>
|
||||||
<result column="leader_phone" property="leaderPhone"/>
|
<result column="leader_phone" property="leaderPhone"/>
|
||||||
<result column="leader_email" property="leaderEmail"/>
|
<result column="leader_email" property="leaderEmail"/>
|
||||||
@ -19,6 +21,8 @@
|
|||||||
<insert id="saveProjectLeader" parameterType="map">
|
<insert id="saveProjectLeader" parameterType="map">
|
||||||
INSERT INTO central_project_leader(
|
INSERT INTO central_project_leader(
|
||||||
project_leader_id,
|
project_leader_id,
|
||||||
|
leader_user_id,
|
||||||
|
leader_user_name,
|
||||||
leader_name,
|
leader_name,
|
||||||
leader_phone,
|
leader_phone,
|
||||||
leader_email,
|
leader_email,
|
||||||
@ -29,6 +33,8 @@
|
|||||||
is_delete
|
is_delete
|
||||||
) VALUES(
|
) VALUES(
|
||||||
#{projectLeaderId},
|
#{projectLeaderId},
|
||||||
|
#{leaderUserId},
|
||||||
|
#{leaderUserName},
|
||||||
#{leaderName},
|
#{leaderName},
|
||||||
#{leaderPhone},
|
#{leaderPhone},
|
||||||
#{leaderEmail},
|
#{leaderEmail},
|
||||||
@ -71,6 +77,12 @@
|
|||||||
UPDATE
|
UPDATE
|
||||||
central_project_leader
|
central_project_leader
|
||||||
SET
|
SET
|
||||||
|
<if test="leaderUserId != null and leaderUserId != ''">
|
||||||
|
leader_user_id = #{leaderUserId},
|
||||||
|
</if>
|
||||||
|
<if test="leaderUserName != null and leaderUserName != ''">
|
||||||
|
leader_user_name = #{leaderUserName},
|
||||||
|
</if>
|
||||||
<if test="leaderName != null and leaderName != ''">
|
<if test="leaderName != null and leaderName != ''">
|
||||||
leader_name = #{leaderName},
|
leader_name = #{leaderName},
|
||||||
</if>
|
</if>
|
||||||
@ -89,6 +101,8 @@
|
|||||||
<!-- 项目负责人详情 -->
|
<!-- 项目负责人详情 -->
|
||||||
<select id="getProjectLeader" parameterType="map" resultMap="projectLeaderDTO">
|
<select id="getProjectLeader" parameterType="map" resultMap="projectLeaderDTO">
|
||||||
SELECT
|
SELECT
|
||||||
|
t1.leader_user_id,
|
||||||
|
t1.leader_user_name,
|
||||||
t1.leader_name,
|
t1.leader_name,
|
||||||
t1.leader_phone,
|
t1.leader_phone,
|
||||||
t1.leader_email,
|
t1.leader_email,
|
||||||
@ -106,6 +120,8 @@
|
|||||||
<!-- 项目负责人列表 -->
|
<!-- 项目负责人列表 -->
|
||||||
<select id="listProjectLeader" parameterType="map" resultMap="projectLeaderDTO">
|
<select id="listProjectLeader" parameterType="map" resultMap="projectLeaderDTO">
|
||||||
SELECT
|
SELECT
|
||||||
|
t1.leader_user_id,
|
||||||
|
t1.leader_user_name,
|
||||||
t1.leader_name,
|
t1.leader_name,
|
||||||
t1.leader_phone,
|
t1.leader_phone,
|
||||||
t1.leader_email,
|
t1.leader_email,
|
||||||
@ -116,10 +132,9 @@
|
|||||||
t1.is_delete = 0
|
t1.is_delete = 0
|
||||||
<if test="keywords != null and keywords != ''">
|
<if test="keywords != null and keywords != ''">
|
||||||
AND (
|
AND (
|
||||||
t1.id LIKE CONCAT('%', #{keywords}, '%')
|
t1.leader_user_name LIKE CONCAT('%', #{keywords}, '%')
|
||||||
OR
|
OR
|
||||||
t1.project_leader_id LIKE CONCAT('%', #{keywords}, '%')
|
t1.leader_name LIKE CONCAT('%', #{keywords}, '%')
|
||||||
<!-- 这里添加其他条件 -->
|
|
||||||
)
|
)
|
||||||
</if>
|
</if>
|
||||||
<if test="startTime != null and startTime != ''">
|
<if test="startTime != null and startTime != ''">
|
||||||
@ -154,6 +169,8 @@
|
|||||||
SELECT
|
SELECT
|
||||||
t1.client_name,
|
t1.client_name,
|
||||||
t1.server_ip,
|
t1.server_ip,
|
||||||
|
t2.leader_user_id,
|
||||||
|
t2.leader_user_name,
|
||||||
t2.leader_name,
|
t2.leader_name,
|
||||||
t2.leader_phone,
|
t2.leader_phone,
|
||||||
t2.leader_email,
|
t2.leader_email,
|
||||||
|
@ -0,0 +1,84 @@
|
|||||||
|
<!doctype html>
|
||||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org">
|
||||||
|
<head>
|
||||||
|
<base th:href="${#request.getContextPath() + '/'}">
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="renderer" content="webkit">
|
||||||
|
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
|
||||||
|
<link rel="stylesheet" href="assets/fonts/font-awesome/css/font-awesome.css"/>
|
||||||
|
<link rel="stylesheet" href="assets/layuiadmin/layui/css/layui.css" media="all">
|
||||||
|
<link rel="stylesheet" href="assets/layuiadmin/style/admin.css" media="all">
|
||||||
|
<link rel="stylesheet" href="assets/js/vendor/codemirror/codemirror.css" media="all">
|
||||||
|
<link rel="stylesheet" href="assets/js/vendor/codemirror/theme/blackboard.css" media="all">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div class="layui-anim layui-anim-fadein">
|
||||||
|
<div class="layui-card">
|
||||||
|
<div class="layui-card-body" style="padding: 15px;">
|
||||||
|
<form class="layui-form layui-form-pane" lay-filter="dataForm">
|
||||||
|
<textarea id="exceptionSummary" name="exceptionSummary" class="layui-textarea" placeholder="请输入异常详情" disabled style="display: none;"></textarea>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<script src="assets/js/vendor/codemirror/codemirror.js"></script>
|
||||||
|
<script src="assets/layuiadmin/layui/layui.js"></script>
|
||||||
|
<script>
|
||||||
|
layui.config({
|
||||||
|
base: 'assets/layuiadmin/' //静态资源所在路径
|
||||||
|
}).extend({
|
||||||
|
index: 'lib/index' //主入口模块
|
||||||
|
}).use(['index', 'form'], function(){
|
||||||
|
var $ = layui.$;
|
||||||
|
var form = layui.form;
|
||||||
|
var clientExceptionId = top.restAjax.params(window.location.href).clientExceptionId;
|
||||||
|
|
||||||
|
function closeBox() {
|
||||||
|
parent.layer.close(parent.layer.getFrameIndex(window.name));
|
||||||
|
}
|
||||||
|
|
||||||
|
// 初始化内容
|
||||||
|
function initData() {
|
||||||
|
var loadLayerIndex;
|
||||||
|
top.restAjax.get(top.restAjax.path('api/clientexception/getclientexceptionbyid/{clientExceptionId}', [clientExceptionId]), {}, null, function(code, data) {
|
||||||
|
var dataFormData = {};
|
||||||
|
for(var i in data) {
|
||||||
|
dataFormData[i] = data[i] +'';
|
||||||
|
}
|
||||||
|
form.val('dataForm', dataFormData);
|
||||||
|
form.render(null, 'dataForm');
|
||||||
|
|
||||||
|
var codeMirror = CodeMirror.fromTextArea(document.getElementById('exceptionSummary'), {
|
||||||
|
theme: 'blackboard',
|
||||||
|
mode : 'text/x-java',
|
||||||
|
matchBrackets: true,
|
||||||
|
indentUnit : 4,
|
||||||
|
smartIndent : true,
|
||||||
|
tabSize : 4,
|
||||||
|
readOnly : true,
|
||||||
|
showCursorWhenSelecting : true,
|
||||||
|
lineNumbers : true
|
||||||
|
});
|
||||||
|
codeMirror.setSize('auto', '426px');
|
||||||
|
}, function(code, data) {
|
||||||
|
top.dialog.msg(data.msg);
|
||||||
|
}, function() {
|
||||||
|
loadLayerIndex = top.dialog.msg(top.dataMessage.loading, {icon: 16, time: 0, shade: 0.3});
|
||||||
|
}, function() {
|
||||||
|
top.dialog.close(loadLayerIndex);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
initData();
|
||||||
|
|
||||||
|
$('.close').on('click', function() {
|
||||||
|
closeBox();
|
||||||
|
});
|
||||||
|
|
||||||
|
// 校验
|
||||||
|
form.verify({
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
@ -69,9 +69,8 @@
|
|||||||
},
|
},
|
||||||
cols: [
|
cols: [
|
||||||
[
|
[
|
||||||
{type:'checkbox', fixed: 'left'},
|
|
||||||
{field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '<span>{{d.LAY_INDEX}}</span>'},
|
{field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '<span>{{d.LAY_INDEX}}</span>'},
|
||||||
{field: 'clientClientName', width: 150, title: '名称', align:'center',
|
{field: 'gmtCreate', width: 180, title: '异常时间', align:'center',
|
||||||
templet: function(row) {
|
templet: function(row) {
|
||||||
var rowData = row[this.field];
|
var rowData = row[this.field];
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||||
@ -80,7 +79,7 @@
|
|||||||
return rowData;
|
return rowData;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{field: 'clientClientSummary', width: 150, title: '描述', align:'center',
|
{field: 'clientClientName', width: 150, title: '名称', align:'center',
|
||||||
templet: function(row) {
|
templet: function(row) {
|
||||||
var rowData = row[this.field];
|
var rowData = row[this.field];
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||||
@ -98,42 +97,6 @@
|
|||||||
return rowData;
|
return rowData;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{field: 'clientDatabaseType', width: 150, title: '数据库类型', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return rowData;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{field: 'clientDatabaseVersion', width: 150, title: '数据库版本', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return rowData;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{field: 'clientDatabaseName', width: 150, title: '数据库名称', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return rowData;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{field: 'clientCustomerId', width: 150, title: '客户ID', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return rowData;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{field: 'clientServerIp', width: 150, title: '服务器地址', align:'center',
|
{field: 'clientServerIp', width: 150, title: '服务器地址', align:'center',
|
||||||
templet: function(row) {
|
templet: function(row) {
|
||||||
var rowData = row[this.field];
|
var rowData = row[this.field];
|
||||||
@ -143,7 +106,7 @@
|
|||||||
return rowData;
|
return rowData;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{field: 'clientIsUsercenter', width: 150, title: '是否', align:'center',
|
{field: 'exceptionType', width: 250, title: '异常类型', align:'center',
|
||||||
templet: function(row) {
|
templet: function(row) {
|
||||||
var rowData = row[this.field];
|
var rowData = row[this.field];
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||||
@ -152,7 +115,7 @@
|
|||||||
return rowData;
|
return rowData;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{field: 'clientIsOnlyAuthorization', width: 150, title: '是否在线授权', align:'center',
|
{field: 'exceptionName', width: 250, title: '异常名称', align:'center',
|
||||||
templet: function(row) {
|
templet: function(row) {
|
||||||
var rowData = row[this.field];
|
var rowData = row[this.field];
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||||
@ -161,87 +124,39 @@
|
|||||||
return rowData;
|
return rowData;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{field: 'clientMacAddress', width: 150, title: 'mac地址', align:'center',
|
{field: 'isNoticeProjectLeader', width: 100, title: '通知负责人', fixed:'right', align:'center',
|
||||||
templet: function(row) {
|
templet: function(row) {
|
||||||
var rowData = row[this.field];
|
var rowData = row[this.field];
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
if(typeof(rowData) === 'undefined' || rowData == null) {
|
||||||
return '-';
|
return '-';
|
||||||
}
|
}
|
||||||
|
if(rowData == 0) {
|
||||||
|
return '<button type="button" class="layui-btn layui-btn-danger layui-btn-xs" lay-event="showExceptionEvent">未通知</button>';
|
||||||
|
} else if(rowData == 1) {
|
||||||
|
return '<span class="layui-badge layui-bg-green">已通知</span>';
|
||||||
|
}
|
||||||
|
return '错误';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{field: 'isHandle', width: 100, title: '处理状态', fixed:'right', align:'center',
|
||||||
|
templet: function(row) {
|
||||||
|
var rowData = row[this.field];
|
||||||
|
if(typeof(rowData) === 'undefined' || rowData == null) {
|
||||||
|
return '-';
|
||||||
|
}
|
||||||
|
if(rowData == 0) {
|
||||||
|
return '<button type="button" class="layui-btn layui-btn-danger layui-btn-xs" lay-event="handleEvent">未处理</button>';
|
||||||
|
} else if(rowData == 1) {
|
||||||
|
return '<span class="layui-badge layui-bg-green">已处理</span>';
|
||||||
|
}
|
||||||
return rowData;
|
return rowData;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{field: 'clientLicenseStartTime', width: 150, title: '秘钥开始时间', align:'center',
|
{field:'opition', width:100, title: '操作', fixed:'right', align:'center',
|
||||||
templet: function(row) {
|
templet: function(item) {
|
||||||
var rowData = row[this.field];
|
return '<button type="button" class="layui-btn layui-btn-normal layui-btn-xs" lay-event="showExceptionEvent">查看异常</button>';
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return common.formatDate('yyyy-MM-dd', new Date(rowData));
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{field: 'clientLicenseEffectiveDays', width: 150, title: '秘钥有效天数', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return rowData;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{field: 'clientLicenseExpirationDate', width: 150, title: '秘钥到期时间', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return common.formatDate('yyyy-MM-dd', new Date(rowData));
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{field: 'clientAuthorizationCount', width: 150, title: '授权次数', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return rowData;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{field: 'exceptionType', width: 150, title: '异常类型', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return rowData;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{field: 'exceptionName', width: 150, title: '异常名称', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return rowData;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{field: 'isNoticeProjectLeader', width: 150, title: '通知负责人', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return rowData;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{field: 'isHandle', width: 150, title: '是否处理', align:'center',
|
|
||||||
templet: function(row) {
|
|
||||||
var rowData = row[this.field];
|
|
||||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
|
||||||
return '-';
|
|
||||||
}
|
|
||||||
return rowData;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
page: true,
|
page: true,
|
||||||
@ -282,28 +197,6 @@
|
|||||||
format: 'yyyy-MM-dd'
|
format: 'yyyy-MM-dd'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
// 删除
|
|
||||||
function removeData(ids) {
|
|
||||||
top.dialog.msg(top.dataMessage.delete, {
|
|
||||||
time: 0,
|
|
||||||
btn: [top.dataMessage.button.yes, top.dataMessage.button.no],
|
|
||||||
shade: 0.3,
|
|
||||||
yes: function (index) {
|
|
||||||
top.dialog.close(index);
|
|
||||||
var layIndex;
|
|
||||||
top.restAjax.delete(top.restAjax.path('api/clientexception/removeclientexception/{ids}', [ids]), {}, null, function (code, data) {
|
|
||||||
top.dialog.msg(top.dataMessage.deleteSuccess, {time: 1000});
|
|
||||||
reloadTable();
|
|
||||||
}, function (code, data) {
|
|
||||||
top.dialog.msg(data.msg);
|
|
||||||
}, function () {
|
|
||||||
layIndex = top.dialog.msg(top.dataMessage.deleting, {icon: 16, time: 0, shade: 0.3});
|
|
||||||
}, function () {
|
|
||||||
top.dialog.close(layIndex);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
initTable();
|
initTable();
|
||||||
initDate();
|
initDate();
|
||||||
// 事件 - 页面变化
|
// 事件 - 页面变化
|
||||||
@ -317,56 +210,28 @@
|
|||||||
$(document).on('click', '#search', function() {
|
$(document).on('click', '#search', function() {
|
||||||
reloadTable(1);
|
reloadTable(1);
|
||||||
});
|
});
|
||||||
// 事件 - 增删改
|
|
||||||
table.on('toolbar(dataTable)', function(obj) {
|
table.on('tool(dataTable)', function(obj) {
|
||||||
var layEvent = obj.event;
|
var layEvent = obj.event;
|
||||||
var checkStatus = table.checkStatus('dataTable');
|
var data = obj.data;
|
||||||
var checkDatas = checkStatus.data;
|
if(layEvent === 'showExceptionEvent') {
|
||||||
if(layEvent === 'saveEvent') {
|
top.dialog.open({
|
||||||
layer.open({
|
url: top.restAjax.path('route/clientexception/getclientexception?clientExceptionId={clientExceptionId}', [data.clientExceptionId]),
|
||||||
type: 2,
|
title: '查看异常',
|
||||||
title: false,
|
width: '1000px',
|
||||||
closeBtn: 0,
|
height: '500px',
|
||||||
area: ['100%', '100%'],
|
onClose: function() {}
|
||||||
shadeClose: true,
|
|
||||||
anim: 2,
|
|
||||||
content: top.restAjax.path('route/clientexception/saveclientexception', []),
|
|
||||||
end: function() {
|
|
||||||
reloadTable();
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
} else if(layEvent === 'updateEvent') {
|
} else if(layEvent === 'handleEvent') {
|
||||||
if(checkDatas.length === 0) {
|
top.dialog.confirm('确定标记处理完成吗?', function(index) {
|
||||||
top.dialog.msg(top.dataMessage.table.selectEdit);
|
top.dialog.close(index);
|
||||||
} else if(checkDatas.length > 1) {
|
top.restAjax.put(top.restAjax.path('api/clientexception/updateishandlerbyclientexceptionid/{clientExceptionId}', [data.clientExceptionId]), {}, null, function(code, data) {
|
||||||
top.dialog.msg(top.dataMessage.table.selectOneEdit);
|
top.dialog.msg('标记成功');
|
||||||
} else {
|
reloadTable();
|
||||||
layer.open({
|
}, function(code, data) {
|
||||||
type: 2,
|
top.dialog.msg(data.msg);
|
||||||
title: false,
|
|
||||||
closeBtn: 0,
|
|
||||||
area: ['100%', '100%'],
|
|
||||||
shadeClose: true,
|
|
||||||
anim: 2,
|
|
||||||
content: top.restAjax.path('route/clientexception/updateclientexception?clientExceptionId={clientExceptionId}', [checkDatas[0].clientExceptionId]),
|
|
||||||
end: function() {
|
|
||||||
reloadTable();
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
}
|
})
|
||||||
} else if(layEvent === 'removeEvent') {
|
|
||||||
if(checkDatas.length === 0) {
|
|
||||||
top.dialog.msg(top.dataMessage.table.selectDelete);
|
|
||||||
} else {
|
|
||||||
var ids = '';
|
|
||||||
for(var i = 0, item; item = checkDatas[i++];) {
|
|
||||||
if(i > 1) {
|
|
||||||
ids += '_';
|
|
||||||
}
|
|
||||||
ids += item['clientExceptionId'];
|
|
||||||
}
|
|
||||||
removeData(ids);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -1,217 +0,0 @@
|
|||||||
<!doctype html>
|
|
||||||
<html lang="en" xmlns:th="http://www.thymeleaf.org">
|
|
||||||
<head>
|
|
||||||
<base th:href="${#request.getContextPath() + '/'}">
|
|
||||||
<meta charset="utf-8">
|
|
||||||
<meta name="renderer" content="webkit">
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
|
|
||||||
<link rel="stylesheet" href="assets/fonts/font-awesome/css/font-awesome.css"/>
|
|
||||||
<link rel="stylesheet" href="assets/layuiadmin/layui/css/layui.css" media="all">
|
|
||||||
<link rel="stylesheet" href="assets/layuiadmin/style/admin.css" media="all">
|
|
||||||
<link rel="stylesheet" type="text/css" href="assets/js/vendor/viewer/viewer.min.css">
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div class="layui-fluid layui-anim layui-anim-fadein">
|
|
||||||
<div class="layui-card">
|
|
||||||
<div class="layui-card-header">
|
|
||||||
<span class="layui-breadcrumb" lay-filter="breadcrumb" style="visibility: visible;">
|
|
||||||
<a class="close" href="javascript:void(0);">上级列表</a><span lay-separator="">/</span>
|
|
||||||
<a href="javascript:void(0);"><cite>新增内容</cite></a>
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
<div class="layui-card-body" style="padding: 15px;">
|
|
||||||
<form class="layui-form layui-form-pane" lay-filter="dataForm">
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<label class="layui-form-label">客户端ID</label>
|
|
||||||
<div class="layui-input-block layui-form" id="clientIdJoinTemplateBox" lay-filter="clientIdJoinTemplateBox"></div>
|
|
||||||
<script id="clientIdJoinTemplate" type="text/html">
|
|
||||||
<select name="clientId">
|
|
||||||
<option value="">选择客户端ID</option>
|
|
||||||
{{# for(var i = 0, item; item = d[i++];) { }}
|
|
||||||
<option value="{{item.clientId}}">{{item.clientName}}</option>
|
|
||||||
{{# } }}
|
|
||||||
</select>
|
|
||||||
</script>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<label class="layui-form-label">异常类型</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<input type="text" id="exceptionType" name="exceptionType" class="layui-input" value="" placeholder="请输入异常类型" >
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<label class="layui-form-label">异常名称</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<input type="text" id="exceptionName" name="exceptionName" class="layui-input" value="" placeholder="请输入异常名称" >
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item layui-form-text">
|
|
||||||
<label class="layui-form-label">异常详情</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<textarea id="exceptionSummary" name="exceptionSummary" class="layui-textarea" placeholder="请输入异常详情"></textarea>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<label class="layui-form-label">通知负责人</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<input type="number" id="isNoticeProjectLeader" name="isNoticeProjectLeader" class="layui-input" value="0" placeholder="请输入通知负责人" lay-verify="required">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<label class="layui-form-label">是否处理</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<input type="number" id="isHandle" name="isHandle" class="layui-input" value="0" placeholder="请输入是否处理" lay-verify="required">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item layui-layout-admin">
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<div class="layui-footer" style="left: 0;">
|
|
||||||
<button type="button" class="layui-btn" lay-submit lay-filter="submitForm">提交新增</button>
|
|
||||||
<button type="button" class="layui-btn layui-btn-primary close">返回上级</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<script src="assets/js/vendor/wangEditor/wangEditor.min.js"></script>
|
|
||||||
<script src="assets/js/vendor/ckplayer/ckplayer/ckplayer.js"></script>
|
|
||||||
<script src="assets/js/vendor/viewer/viewer.min.js"></script>
|
|
||||||
<script src="assets/layuiadmin/layui/layui.js"></script>
|
|
||||||
<script>
|
|
||||||
layui.config({
|
|
||||||
base: 'assets/layuiadmin/' //静态资源所在路径
|
|
||||||
}).extend({
|
|
||||||
index: 'lib/index' //主入口模块
|
|
||||||
}).use(['index', 'form', 'laydate', 'laytpl'], function(){
|
|
||||||
var $ = layui.$;
|
|
||||||
var form = layui.form;
|
|
||||||
var laytpl = layui.laytpl;
|
|
||||||
var laydate = layui.laydate;
|
|
||||||
var wangEditor = window.wangEditor;
|
|
||||||
var wangEditorObj = {};
|
|
||||||
var viewerObj = {};
|
|
||||||
|
|
||||||
function closeBox() {
|
|
||||||
parent.layer.close(parent.layer.getFrameIndex(window.name));
|
|
||||||
}
|
|
||||||
|
|
||||||
function refreshDownloadTemplet(fileName, file) {
|
|
||||||
var dataRander = {};
|
|
||||||
dataRander[fileName] = file;
|
|
||||||
|
|
||||||
laytpl(document.getElementById(fileName +'FileDownload').innerHTML).render(dataRander, function(html) {
|
|
||||||
document.getElementById(fileName +'FileBox').innerHTML = html;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// 初始化文件列表
|
|
||||||
function initFileList(fileName, ids, callback) {
|
|
||||||
var dataForm = {};
|
|
||||||
dataForm[fileName] = ids;
|
|
||||||
form.val('dataForm', dataForm);
|
|
||||||
|
|
||||||
if(!ids) {
|
|
||||||
refreshDownloadTemplet(fileName, []);
|
|
||||||
if(callback) {
|
|
||||||
callback(fileName, []);
|
|
||||||
}
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
top.restAjax.get(top.restAjax.path('api/file/listfilebyfileid', []), {
|
|
||||||
ids: ids
|
|
||||||
}, null, function(code, data) {
|
|
||||||
refreshDownloadTemplet(fileName, data);
|
|
||||||
if(callback) {
|
|
||||||
callback(fileName, data);
|
|
||||||
}
|
|
||||||
}, function(code, data) {
|
|
||||||
top.dialog.msg(data.msg);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// 初始化视频
|
|
||||||
function initVideo(fileName, data) {
|
|
||||||
for(var i = 0, item; item = data[i++];) {
|
|
||||||
var player = new ckplayer({
|
|
||||||
container: '#'+ fileName + i,
|
|
||||||
variable: 'player',
|
|
||||||
flashplayer: false,
|
|
||||||
video: {
|
|
||||||
file: 'route/file/downloadfile/true/'+ item.fileId,
|
|
||||||
type: 'video/mp4'
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 初始化客户端ID联表
|
|
||||||
function initClientIdJoinTable(){
|
|
||||||
top.restAjax.get(top.restAjax.path('api/client/listclient', []), {}, null, function(code, data, args) {
|
|
||||||
laytpl(document.getElementById('clientIdJoinTemplate').innerHTML).render(data, function(html) {
|
|
||||||
document.getElementById('clientIdJoinTemplateBox').innerHTML = html;
|
|
||||||
});
|
|
||||||
form.render('select', 'clientIdJoinTemplateBox');
|
|
||||||
}, function(code, data) {
|
|
||||||
top.dialog.msg(data.msg);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// 初始化内容
|
|
||||||
function initData() {
|
|
||||||
top.restAjax.get(top.restAjax.path('api/clientexception/getcurrentuseridinfo', []), {}, null, function(code, data) {
|
|
||||||
initClientIdJoinTable();
|
|
||||||
}, function(code, data) {
|
|
||||||
top.dialog.msg(data.msg);
|
|
||||||
}, function() {
|
|
||||||
loadLayerIndex = top.dialog.msg(top.dataMessage.loading, {icon: 16, time: 0, shade: 0.3});
|
|
||||||
}, function() {
|
|
||||||
top.dialog.close(loadLayerIndex);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
initData();
|
|
||||||
|
|
||||||
// 提交表单
|
|
||||||
form.on('submit(submitForm)', function(formData) {
|
|
||||||
top.dialog.confirm(top.dataMessage.commit, function(index) {
|
|
||||||
top.dialog.close(index);
|
|
||||||
var loadLayerIndex;
|
|
||||||
top.restAjax.post(top.restAjax.path('api/clientexception/saveclientexception', []), formData.field, null, function(code, data) {
|
|
||||||
var layerIndex = top.dialog.msg(top.dataMessage.commitSuccess, {
|
|
||||||
time: 0,
|
|
||||||
btn: [top.dataMessage.button.yes, top.dataMessage.button.no],
|
|
||||||
shade: 0.3,
|
|
||||||
yes: function(index) {
|
|
||||||
top.dialog.close(index);
|
|
||||||
window.location.reload();
|
|
||||||
},
|
|
||||||
btn2: function() {
|
|
||||||
closeBox();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}, function(code, data) {
|
|
||||||
top.dialog.msg(data.msg);
|
|
||||||
}, function() {
|
|
||||||
loadLayerIndex = top.dialog.msg(top.dataMessage.committing, {icon: 16, time: 0, shade: 0.3});
|
|
||||||
}, function() {
|
|
||||||
top.dialog.close(loadLayerIndex);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
return false;
|
|
||||||
});
|
|
||||||
|
|
||||||
$('.close').on('click', function() {
|
|
||||||
closeBox();
|
|
||||||
});
|
|
||||||
|
|
||||||
// 校验
|
|
||||||
form.verify({
|
|
||||||
});
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
@ -1,231 +0,0 @@
|
|||||||
<!doctype html>
|
|
||||||
<html lang="en" xmlns:th="http://www.thymeleaf.org">
|
|
||||||
<head>
|
|
||||||
<base th:href="${#request.getContextPath() + '/'}">
|
|
||||||
<meta charset="utf-8">
|
|
||||||
<meta name="renderer" content="webkit">
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
|
|
||||||
<link rel="stylesheet" href="assets/fonts/font-awesome/css/font-awesome.css"/>
|
|
||||||
<link rel="stylesheet" href="assets/layuiadmin/layui/css/layui.css" media="all">
|
|
||||||
<link rel="stylesheet" href="assets/layuiadmin/style/admin.css" media="all">
|
|
||||||
<link rel="stylesheet" type="text/css" href="assets/js/vendor/viewer/viewer.min.css">
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div class="layui-fluid layui-anim layui-anim-fadein">
|
|
||||||
<div class="layui-card">
|
|
||||||
<div class="layui-card-header">
|
|
||||||
<span class="layui-breadcrumb" lay-filter="breadcrumb" style="visibility: visible;">
|
|
||||||
<a class="close" href="javascript:void(0);">上级列表</a><span lay-separator="">/</span>
|
|
||||||
<a href="javascript:void(0);"><cite>编辑内容</cite></a>
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
<div class="layui-card-body" style="padding: 15px;">
|
|
||||||
<form class="layui-form layui-form-pane" lay-filter="dataForm">
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<label class="layui-form-label">客户端ID</label>
|
|
||||||
<div class="layui-input-block layui-form" id="clientIdJoinTemplateBox" lay-filter="clientIdJoinTemplateBox"></div>
|
|
||||||
<script id="clientIdJoinTemplate" type="text/html">
|
|
||||||
<select name="clientId">
|
|
||||||
<option value="">选择客户端ID</option>
|
|
||||||
{{# for(var i = 0, item; item = d[i++];) { }}
|
|
||||||
<option value="{{item.clientId}}">{{item.clientName}}</option>
|
|
||||||
{{# } }}
|
|
||||||
</select>
|
|
||||||
</script>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<label class="layui-form-label">异常类型</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<input type="text" id="exceptionType" name="exceptionType" class="layui-input" value="" placeholder="请输入异常类型" >
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<label class="layui-form-label">异常名称</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<input type="text" id="exceptionName" name="exceptionName" class="layui-input" value="" placeholder="请输入异常名称" >
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item layui-form-text">
|
|
||||||
<label class="layui-form-label">异常详情</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<textarea id="exceptionSummary" name="exceptionSummary" class="layui-textarea" placeholder="请输入异常详情"></textarea>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<label class="layui-form-label">通知负责人</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<input type="number" id="isNoticeProjectLeader" name="isNoticeProjectLeader" class="layui-input" value="0" placeholder="请输入通知负责人" lay-verify="required">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<label class="layui-form-label">是否处理</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<input type="number" id="isHandle" name="isHandle" class="layui-input" value="0" placeholder="请输入是否处理" lay-verify="required">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-form-item layui-layout-admin">
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<div class="layui-footer" style="left: 0;">
|
|
||||||
<button type="button" class="layui-btn" lay-submit lay-filter="submitForm">提交编辑</button>
|
|
||||||
<button type="button" class="layui-btn layui-btn-primary close">返回上级</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<script src="assets/js/vendor/wangEditor/wangEditor.min.js"></script>
|
|
||||||
<script src="assets/js/vendor/ckplayer/ckplayer/ckplayer.js"></script>
|
|
||||||
<script src="assets/js/vendor/viewer/viewer.min.js"></script>
|
|
||||||
<script src="assets/layuiadmin/layui/layui.js"></script>
|
|
||||||
<script>
|
|
||||||
layui.config({
|
|
||||||
base: 'assets/layuiadmin/' //静态资源所在路径
|
|
||||||
}).extend({
|
|
||||||
index: 'lib/index' //主入口模块
|
|
||||||
}).use(['index', 'form', 'laydate', 'laytpl'], function(){
|
|
||||||
var $ = layui.$;
|
|
||||||
var form = layui.form;
|
|
||||||
var laytpl = layui.laytpl;
|
|
||||||
var laydate = layui.laydate;
|
|
||||||
var clientExceptionId = top.restAjax.params(window.location.href).clientExceptionId;
|
|
||||||
|
|
||||||
var wangEditor = window.wangEditor;
|
|
||||||
var wangEditorObj = {};
|
|
||||||
var viewerObj = {};
|
|
||||||
|
|
||||||
function closeBox() {
|
|
||||||
parent.layer.close(parent.layer.getFrameIndex(window.name));
|
|
||||||
}
|
|
||||||
|
|
||||||
function refreshDownloadTemplet(fileName, file) {
|
|
||||||
var dataRander = {};
|
|
||||||
dataRander[fileName] = file;
|
|
||||||
|
|
||||||
laytpl(document.getElementById(fileName +'FileDownload').innerHTML).render(dataRander, function(html) {
|
|
||||||
document.getElementById(fileName +'FileBox').innerHTML = html;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// 初始化文件列表
|
|
||||||
function initFileList(fileName, ids, callback) {
|
|
||||||
var dataForm = {};
|
|
||||||
dataForm[fileName] = ids;
|
|
||||||
form.val('dataForm', dataForm);
|
|
||||||
|
|
||||||
if(!ids) {
|
|
||||||
refreshDownloadTemplet(fileName, []);
|
|
||||||
if(callback) {
|
|
||||||
callback(fileName, []);
|
|
||||||
}
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
top.restAjax.get(top.restAjax.path('api/file/listfilebyfileid', []), {
|
|
||||||
ids: ids
|
|
||||||
}, null, function(code, data) {
|
|
||||||
refreshDownloadTemplet(fileName, data);
|
|
||||||
if(callback) {
|
|
||||||
callback(fileName, data);
|
|
||||||
}
|
|
||||||
}, function(code, data) {
|
|
||||||
top.dialog.msg(data.msg);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// 初始化视频
|
|
||||||
function initVideo(fileName, data) {
|
|
||||||
for(var i = 0, item; item = data[i++];) {
|
|
||||||
var player = new ckplayer({
|
|
||||||
container: '#'+ fileName + i,
|
|
||||||
variable: 'player',
|
|
||||||
flashplayer: false,
|
|
||||||
video: {
|
|
||||||
file: 'route/file/downloadfile/true/'+ item.fileId,
|
|
||||||
type: 'video/mp4'
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 初始化客户端ID联表
|
|
||||||
function initClientIdJoinTable(joinValue){
|
|
||||||
top.restAjax.get(top.restAjax.path('api/client/listclient', []), {}, null, function(code, data) {
|
|
||||||
laytpl(document.getElementById('clientIdJoinTemplate').innerHTML).render(data, function(html) {
|
|
||||||
document.getElementById('clientIdJoinTemplateBox').innerHTML = html;
|
|
||||||
});
|
|
||||||
form.render('select', 'clientIdJoinTemplateBox');
|
|
||||||
|
|
||||||
// 初始化选择
|
|
||||||
var formSelectData = {};
|
|
||||||
formSelectData['client'] = joinValue;
|
|
||||||
form.val('dataForm', formSelectData);
|
|
||||||
}, function(code, data) {
|
|
||||||
top.dialog.msg(data.msg);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// 初始化内容
|
|
||||||
function initData() {
|
|
||||||
var loadLayerIndex;
|
|
||||||
top.restAjax.get(top.restAjax.path('api/clientexception/getclientexceptionbyid/{clientExceptionId}', [clientExceptionId]), {}, null, function(code, data) {
|
|
||||||
var dataFormData = {};
|
|
||||||
for(var i in data) {
|
|
||||||
dataFormData[i] = data[i] +'';
|
|
||||||
}
|
|
||||||
form.val('dataForm', dataFormData);
|
|
||||||
form.render(null, 'dataForm');
|
|
||||||
initClientIdJoinTable(data['clientId']);
|
|
||||||
}, function(code, data) {
|
|
||||||
top.dialog.msg(data.msg);
|
|
||||||
}, function() {
|
|
||||||
loadLayerIndex = top.dialog.msg(top.dataMessage.loading, {icon: 16, time: 0, shade: 0.3});
|
|
||||||
}, function() {
|
|
||||||
top.dialog.close(loadLayerIndex);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
initData();
|
|
||||||
|
|
||||||
// 提交表单
|
|
||||||
form.on('submit(submitForm)', function(formData) {
|
|
||||||
top.dialog.confirm(top.dataMessage.commit, function(index) {
|
|
||||||
top.dialog.close(index);
|
|
||||||
var loadLayerIndex;
|
|
||||||
top.restAjax.put(top.restAjax.path('api/clientexception/updateclientexception/{clientExceptionId}', [clientExceptionId]), formData.field, null, function(code, data) {
|
|
||||||
var layerIndex = top.dialog.msg(top.dataMessage.updateSuccess, {
|
|
||||||
time: 0,
|
|
||||||
btn: [top.dataMessage.button.yes, top.dataMessage.button.no],
|
|
||||||
shade: 0.3,
|
|
||||||
yes: function(index) {
|
|
||||||
top.dialog.close(index);
|
|
||||||
window.location.reload();
|
|
||||||
},
|
|
||||||
btn2: function() {
|
|
||||||
closeBox();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}, function(code, data) {
|
|
||||||
top.dialog.msg(data.msg);
|
|
||||||
}, function() {
|
|
||||||
loadLayerIndex = top.dialog.msg(top.dataMessage.committing, {icon: 16, time: 0, shade: 0.3});
|
|
||||||
}, function() {
|
|
||||||
top.dialog.close(loadLayerIndex);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
return false;
|
|
||||||
});
|
|
||||||
|
|
||||||
$('.close').on('click', function() {
|
|
||||||
closeBox();
|
|
||||||
});
|
|
||||||
|
|
||||||
// 校验
|
|
||||||
form.verify({
|
|
||||||
});
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
@ -51,7 +51,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<script src="assets/layuiadmin/layui/layui.js"></script>
|
<script src="assets/layuiadmin/layui/layui.js"></script>
|
||||||
<script src="assets/js/vendor/viewer/viewer.min.js"></script>
|
|
||||||
<script>
|
<script>
|
||||||
layui.config({
|
layui.config({
|
||||||
base: 'assets/layuiadmin/'
|
base: 'assets/layuiadmin/'
|
||||||
@ -95,6 +94,15 @@
|
|||||||
return rowData;
|
return rowData;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{field: 'leaderUserName', width: 150, title: '昵称', align:'center',
|
||||||
|
templet: function(row) {
|
||||||
|
var rowData = row[this.field];
|
||||||
|
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||||
|
return '-';
|
||||||
|
}
|
||||||
|
return rowData;
|
||||||
|
}
|
||||||
|
},
|
||||||
{field: 'leaderPhone', width: 150, title: '手机', align:'center',
|
{field: 'leaderPhone', width: 150, title: '手机', align:'center',
|
||||||
templet: function(row) {
|
templet: function(row) {
|
||||||
var rowData = row[this.field];
|
var rowData = row[this.field];
|
||||||
|
@ -21,22 +21,29 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="layui-card-body" style="padding: 15px;">
|
<div class="layui-card-body" style="padding: 15px;">
|
||||||
<form class="layui-form layui-form-pane" lay-filter="dataForm">
|
<form class="layui-form layui-form-pane" lay-filter="dataForm">
|
||||||
|
<input id="leaderUserId" name="leaderUserId" type="hidden">
|
||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label class="layui-form-label">姓名</label>
|
<label class="layui-form-label">姓名</label>
|
||||||
<div class="layui-input-block">
|
<div class="layui-input-block">
|
||||||
<input type="text" id="leaderName" name="leaderName" class="layui-input" value="" placeholder="请输入姓名" lay-verify="required">
|
<input type="text" id="leaderName" name="leaderName" class="layui-input" value="" placeholder="请输入姓名" lay-verify="required">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="layui-form-item">
|
||||||
|
<label class="layui-form-label">昵称</label>
|
||||||
|
<div class="layui-input-block">
|
||||||
|
<input type="text" id="leaderUserName" name="leaderUserName" class="layui-input" value="" placeholder="点击关联账号" lay-verify="required" readonly style="cursor: pointer">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label class="layui-form-label">手机</label>
|
<label class="layui-form-label">手机</label>
|
||||||
<div class="layui-input-block">
|
<div class="layui-input-block">
|
||||||
<input type="text" id="leaderPhone" name="leaderPhone" class="layui-input" value="" placeholder="请输入手机" lay-verify="phone">
|
<input type="text" id="leaderPhone" name="leaderPhone" class="layui-input" value="" placeholder="请输入手机" lay-verify="phone" readonly>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label class="layui-form-label">邮箱</label>
|
<label class="layui-form-label">邮箱</label>
|
||||||
<div class="layui-input-block">
|
<div class="layui-input-block">
|
||||||
<input type="text" id="leaderEmail" name="leaderEmail" class="layui-input" value="" placeholder="请输入邮箱" lay-verify="email">
|
<input type="text" id="leaderEmail" name="leaderEmail" class="layui-input" value="" placeholder="请输入邮箱" lay-verify="email" readonly>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-form-item layui-layout-admin">
|
<div class="layui-form-item layui-layout-admin">
|
||||||
@ -100,6 +107,34 @@
|
|||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
$('#leaderUserName').on('click', function() {
|
||||||
|
top.dialog.dialogData.oldSelectedUserList = [{
|
||||||
|
userId: $('#leaderUserId').val(),
|
||||||
|
userName: $('#leaderUserName').val(),
|
||||||
|
userPhone: $('#leaderPhone').val(),
|
||||||
|
userEmail: $('#leaderEmail').val()
|
||||||
|
}];
|
||||||
|
top.dialog.open({
|
||||||
|
url: 'route/common/listselectuser',
|
||||||
|
title: '选择用户',
|
||||||
|
width: '800px',
|
||||||
|
height: '500px',
|
||||||
|
onClose: function() {
|
||||||
|
var newSelectedUserList = top.dialog.dialogData.newSelectedUserList;
|
||||||
|
if(newSelectedUserList.length != 0) {
|
||||||
|
form.val('dataForm', {
|
||||||
|
leaderUserId: newSelectedUserList[0].userId,
|
||||||
|
leaderUserName: newSelectedUserList[0].userName,
|
||||||
|
leaderPhone: newSelectedUserList[0].userPhone,
|
||||||
|
leaderEmail: newSelectedUserList[0].userEmail
|
||||||
|
});
|
||||||
|
form.render(null, 'dataForm');
|
||||||
|
}
|
||||||
|
top.dialog.dialogData.oldSelectedUserList = [];
|
||||||
|
}
|
||||||
|
})
|
||||||
|
});
|
||||||
|
|
||||||
$('.close').on('click', function() {
|
$('.close').on('click', function() {
|
||||||
closeBox();
|
closeBox();
|
||||||
});
|
});
|
||||||
|
@ -21,22 +21,29 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="layui-card-body" style="padding: 15px;">
|
<div class="layui-card-body" style="padding: 15px;">
|
||||||
<form class="layui-form layui-form-pane" lay-filter="dataForm">
|
<form class="layui-form layui-form-pane" lay-filter="dataForm">
|
||||||
|
<input id="leaderUserId" name="leaderUserId" type="hidden">
|
||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label class="layui-form-label">姓名</label>
|
<label class="layui-form-label">姓名</label>
|
||||||
<div class="layui-input-block">
|
<div class="layui-input-block">
|
||||||
<input type="text" id="leaderName" name="leaderName" class="layui-input" value="" placeholder="请输入姓名" lay-verify="required">
|
<input type="text" id="leaderName" name="leaderName" class="layui-input" value="" placeholder="请输入姓名" lay-verify="required">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="layui-form-item">
|
||||||
|
<label class="layui-form-label">昵称</label>
|
||||||
|
<div class="layui-input-block">
|
||||||
|
<input type="text" id="leaderUserName" name="leaderUserName" class="layui-input" value="" placeholder="点击关联账号" lay-verify="required" readonly style="cursor: pointer">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label class="layui-form-label">手机</label>
|
<label class="layui-form-label">手机</label>
|
||||||
<div class="layui-input-block">
|
<div class="layui-input-block">
|
||||||
<input type="text" id="leaderPhone" name="leaderPhone" class="layui-input" value="" placeholder="请输入手机" lay-verify="phone">
|
<input type="text" id="leaderPhone" name="leaderPhone" class="layui-input" value="" placeholder="请输入手机" lay-verify="phone" readonly>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label class="layui-form-label">邮箱</label>
|
<label class="layui-form-label">邮箱</label>
|
||||||
<div class="layui-input-block">
|
<div class="layui-input-block">
|
||||||
<input type="text" id="leaderEmail" name="leaderEmail" class="layui-input" value="" placeholder="请输入邮箱" lay-verify="email">
|
<input type="text" id="leaderEmail" name="leaderEmail" class="layui-input" value="" placeholder="请输入邮箱" lay-verify="email" readonly>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-form-item layui-layout-admin">
|
<div class="layui-form-item layui-layout-admin">
|
||||||
@ -117,6 +124,34 @@
|
|||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
$('#leaderUserName').on('click', function() {
|
||||||
|
top.dialog.dialogData.oldSelectedUserList = [{
|
||||||
|
userId: $('#leaderUserId').val(),
|
||||||
|
userName: $('#leaderUserName').val(),
|
||||||
|
userPhone: $('#leaderPhone').val(),
|
||||||
|
userEmail: $('#leaderEmail').val()
|
||||||
|
}];
|
||||||
|
top.dialog.open({
|
||||||
|
url: 'route/common/listselectuser',
|
||||||
|
title: '选择用户',
|
||||||
|
width: '800px',
|
||||||
|
height: '500px',
|
||||||
|
onClose: function() {
|
||||||
|
var newSelectedUserList = top.dialog.dialogData.newSelectedUserList;
|
||||||
|
if(newSelectedUserList.length != 0) {
|
||||||
|
form.val('dataForm', {
|
||||||
|
leaderUserId: newSelectedUserList[0].userId,
|
||||||
|
leaderUserName: newSelectedUserList[0].userName,
|
||||||
|
leaderPhone: newSelectedUserList[0].userPhone,
|
||||||
|
leaderEmail: newSelectedUserList[0].userEmail
|
||||||
|
});
|
||||||
|
form.render(null, 'dataForm');
|
||||||
|
}
|
||||||
|
top.dialog.dialogData.oldSelectedUserList = [];
|
||||||
|
}
|
||||||
|
})
|
||||||
|
});
|
||||||
|
|
||||||
$('.close').on('click', function() {
|
$('.close').on('click', function() {
|
||||||
closeBox();
|
closeBox();
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user