新增协议代码修改,代码风格规范
This commit is contained in:
parent
c6f803b098
commit
ffe2d1b3bb
|
@ -7,7 +7,7 @@ import lombok.Data;
|
|||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class AdQuery extends Ad{
|
||||
public class AdQuery extends AdVO{
|
||||
|
||||
@ApiModelProperty("广告ID列表")
|
||||
private List<Long> adIds;
|
||||
|
|
|
@ -9,7 +9,10 @@ public class AdVO extends Ad{
|
|||
@ApiModelProperty("所属运营区")
|
||||
private String areaName;
|
||||
|
||||
@ApiModelProperty("所属运营区")
|
||||
@ApiModelProperty("广告审核状态")
|
||||
private String auditStatus;
|
||||
|
||||
@ApiModelProperty("审核人")
|
||||
private String verifyName;
|
||||
|
||||
}
|
||||
|
|
|
@ -185,7 +185,6 @@ public class AdServiceImpl implements AdService
|
|||
data.setVerifyBy(SecurityUtils.getUserId());
|
||||
data.setVerifyEndTime(LocalDateTime.now());
|
||||
data.setVerifyRemark(dto.getVerifyRemark());
|
||||
data.setVerifyBy(SecurityUtils.getUserId());
|
||||
AdQuery query = new AdQuery();
|
||||
query.setAdId(dto.getId());
|
||||
query.setStatusList(AdVerifyStatus.canVerify());
|
||||
|
|
|
@ -12,7 +12,6 @@ public class AgreementQuery extends AgreementVO {
|
|||
@ApiModelProperty("用户ID")
|
||||
private Long userId;
|
||||
|
||||
|
||||
@ApiModelProperty("协议ID列表")
|
||||
private List<Long> ids;
|
||||
|
||||
|
|
|
@ -35,7 +35,7 @@ public interface AgreementService
|
|||
* @param agreement 协议
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertAgreement(AgreementQuery agreement);
|
||||
public int insertAgreement(Agreement agreement);
|
||||
|
||||
/**
|
||||
* 修改协议
|
||||
|
|
|
@ -64,16 +64,9 @@ public class AgreementServiceImpl implements AgreementService
|
|||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertAgreement(AgreementQuery agreement)
|
||||
public int insertAgreement(Agreement agreement)
|
||||
{
|
||||
agreement.setCreateTime(DateUtils.getNowDate());
|
||||
UserVO user = userService.selectUserById(agreement.getUserId());
|
||||
if (user != null){
|
||||
if (user.getAreaId() != null){
|
||||
agreement.setAreaId(user.getAreaId());
|
||||
}
|
||||
agreement.setStoreId(agreement.getUserId());
|
||||
}
|
||||
distinct(agreement);
|
||||
return agreementMapper.insertAgreement(agreement);
|
||||
}
|
||||
|
@ -93,12 +86,7 @@ public class AgreementServiceImpl implements AgreementService
|
|||
}
|
||||
|
||||
private void distinct(Agreement agreement) {
|
||||
if (agreement.getAreaId() != null){
|
||||
AreaVO area = areaService.selectAreaById(agreement.getAreaId());
|
||||
ServiceUtil.assertion(area == null,"当前区域不存在");
|
||||
agreement.setStoreId(area.getUserId());
|
||||
ServiceUtil.assertion(agreementMapper.selectDistinct(agreement)!= null,"当前运营区已存在同类协议");
|
||||
}
|
||||
ServiceUtil.assertion(agreementMapper.selectDistinct(agreement)!= null,"当前运营区已存在同类协议");
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -3,7 +3,7 @@ package com.ruoyi.bst.article.domain;
|
|||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class ArticleQuery extends Article{
|
||||
public class ArticleQuery extends ArticleVO{
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@ import io.swagger.annotations.ApiModelProperty;
|
|||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class ArticleCategoryQuery extends ArticleCategory {
|
||||
public class ArticleCategoryQuery extends ArticleCategoryVO {
|
||||
|
||||
@ApiModelProperty("指南编号")
|
||||
private String code;
|
||||
|
|
|
@ -4,7 +4,7 @@ import io.swagger.annotations.ApiModelProperty;
|
|||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class ComplaintQuery extends Complaint{
|
||||
public class ComplaintQuery extends ComplaintVO{
|
||||
|
||||
@ApiModelProperty("用户名称")
|
||||
private String userName;
|
||||
|
|
|
@ -6,7 +6,7 @@ import lombok.Data;
|
|||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class CustomerServiceQuery extends CustomerService{
|
||||
public class CustomerServiceQuery extends CustomerServiceVO{
|
||||
|
||||
@ApiModelProperty("客服ID列表")
|
||||
private List<Long> ids;
|
||||
|
|
|
@ -6,7 +6,7 @@ import lombok.Data;
|
|||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class HardwareVersionQuery extends HardwareVersion{
|
||||
public class HardwareVersionQuery extends HardwareVersionVO{
|
||||
|
||||
@ApiModelProperty("硬件版本列表")
|
||||
private List<Long> hardwareVersionIds;
|
||||
|
|
|
@ -9,7 +9,7 @@ import io.swagger.annotations.ApiModelProperty;
|
|||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class MchApplyQuery extends MchApply{
|
||||
public class MchApplyQuery extends MchApplyVO{
|
||||
|
||||
@ApiModelProperty("创建时间范围")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package com.ruoyi.bst.realName.domain;
|
||||
|
||||
public class RealNameQuery extends RealName{
|
||||
public class RealNameQuery extends RealNameVO{
|
||||
}
|
||||
|
|
|
@ -76,9 +76,8 @@ public class AgreementController extends BaseController
|
|||
@PreAuthorize("@ss.hasPermi('bst:agreement:add')")
|
||||
@Log(title = "协议", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody AgreementQuery agreement)
|
||||
public AjaxResult add(@RequestBody Agreement agreement)
|
||||
{
|
||||
agreement.setUserId(getUserId());
|
||||
return toAjax(agreementService.insertAgreement(agreement));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user