Bläddra i källkod

userw修改

master
chenchaod 4 dagar sedan
förälder
incheckning
de272c447a

+ 4
- 0
zhywpt-app-userw/src/main/java/cn/com/taiji/userw/api/WxPayConfigController.java Visa fil

@@ -3,6 +3,7 @@ package cn.com.taiji.userw.api;
import cn.com.taiji.common.manager.ManagerException;
import cn.com.taiji.common.model.dao.Pagination;
import cn.com.taiji.common.web.ApiResponse;
import cn.com.taiji.core.entity.comm.CommonPayConfig;
import cn.com.taiji.userw.dto.wx.*;
import cn.com.taiji.userw.manager.wx.WxPayConfigManager;
import io.swagger.annotations.Api;
@@ -11,6 +12,8 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
* @Author:ChenChao
* @Date:2025/5/20 17:00
@@ -42,4 +45,5 @@ public class WxPayConfigController extends MyValidController{
manager.update(reqDto);
return ApiResponse.success().setMessage("修改成功");
}

}

+ 9
- 0
zhywpt-app-userw/src/main/java/cn/com/taiji/userw/dto/centerHallAndAgency/CenterHallOrAgencyPageRequestDTO.java Visa fil

@@ -1,6 +1,8 @@
package cn.com.taiji.userw.dto.centerHallAndAgency;

import cn.com.taiji.core.dto.AbstractStaffBizPageRequestDTO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
@@ -9,7 +11,14 @@ import lombok.Data;
* @Filename:CenterHallRequestDTO
* @description: 中心网点/渠道请求参数
*/
@ApiModel(value = "中心网点/渠道请求参数")
@Data
public class CenterHallOrAgencyPageRequestDTO extends AbstractStaffBizPageRequestDTO {

@ApiModelProperty(name = "中心网点/渠道ID")
private String id;

@ApiModelProperty(name = "中心网点/渠道名称")
private String name;

}

+ 5
- 3
zhywpt-app-userw/src/main/java/cn/com/taiji/userw/manager/centerHallAndAgency/CenterAgencyManagerImpl.java Visa fil

@@ -35,12 +35,12 @@ public class CenterAgencyManagerImpl extends AbstractManager implements CenterAg
if (reqDto.getOptType() == 1){
QtkAgencyMap agencyMap = qtkAgencyMapRepo.findByCenterAgencyId(reqDto.getCenterAgencyId());
if (agencyMap != null) throw new ManagerException("此中心渠道编号也存在");
agencyMap = copyProperties(reqDto, new QtkAgencyMap());
agencyMap = copyProperties(reqDto, new QtkAgencyMap(),"id");
qtkAgencyMapRepo.persist(agencyMap);
}else {
QtkAgencyMap qtkAgencyMap = qtkAgencyMapRepo.findById(reqDto.getId()).orElse(null);
if (qtkAgencyMap == null) throw new ManagerException("此中心渠道不存在");
copyProperties(reqDto,qtkAgencyMap,"id","centerAgencyName");
copyProperties(reqDto,qtkAgencyMap,"id","centerAgencyId");
qtkAgencyMapRepo.merge(qtkAgencyMap);
}
}
@@ -52,7 +52,9 @@ public class CenterAgencyManagerImpl extends AbstractManager implements CenterAg

@Override
public Pagination page(CenterHallOrAgencyPageRequestDTO reqDto) {
CenterAgencyPageRequest request = copyProperties(reqDto, new CenterAgencyPageRequest());
CenterAgencyPageRequest request = new CenterAgencyPageRequest();
request.setCenterAgencyId(reqDto.getId());
request.setCenterAgencyName(reqDto.getName());
return qtkAgencyMapRepo.page(request);
}
}

+ 4
- 2
zhywpt-app-userw/src/main/java/cn/com/taiji/userw/manager/centerHallAndAgency/CenterServiceHallManagerImpl.java Visa fil

@@ -38,7 +38,7 @@ public class CenterServiceHallManagerImpl extends AbstractManager implements Cen
if (reqDto.getOptType() == 1){
QtkServicehallMap serviceHallId = qtkServicehallMapRepo.findByCenterServiceHallId(reqDto.getCenterServiceHallId());
if (serviceHallId != null) throw new ManagerException("此中心网点已存在");
QtkServicehallMap servicehallMap = copyProperties(reqDto, new QtkServicehallMap());
QtkServicehallMap servicehallMap = copyProperties(reqDto, new QtkServicehallMap(),"id");
qtkServicehallMapRepo.persist(servicehallMap);
}else {
QtkServicehallMap servicehallMap = qtkServicehallMapRepo.findById(reqDto.getId()).orElse(null);
@@ -55,7 +55,9 @@ public class CenterServiceHallManagerImpl extends AbstractManager implements Cen

@Override
public Pagination page(CenterHallOrAgencyPageRequestDTO reqDto) {
CenterServiceHallPageRequest request = copyProperties(reqDto, new CenterServiceHallPageRequest());
CenterServiceHallPageRequest request = new CenterServiceHallPageRequest();
request.setCenterServiceHallId(reqDto.getId());
request.setCenterServicehallName(reqDto.getName());
return qtkServicehallMapRepo.page(request);
}
}

+ 11
- 9
zhywpt-app-userw/src/main/java/cn/com/taiji/userw/manager/serviceHall/ServiceHallManagerImpl.java Visa fil

@@ -99,16 +99,18 @@ public class ServiceHallManagerImpl extends AbstractManager implements ServiceHa
//递归
public List<ServiceHallSonQueryModel> querySon(List<QtkServiceHall> serviceHalls,Map<String, List<QtkServiceHall>> collect) {
ArrayList<ServiceHallSonQueryModel> returnModes = new ArrayList<>();
for (QtkServiceHall serviceHall : serviceHalls) {
ServiceHallSonQueryModel model = new ServiceHallSonQueryModel();
String serviceHallId = serviceHall.getServiceHallId();
model.setServicehallId(serviceHallId);
model.setServicehallName(serviceHall.getName());
List<QtkServiceHall> serviceHalls1 = collect.get(serviceHallId);
if (serviceHalls1 != null){
model.setChildrens(querySon(serviceHalls1, collect));
if (CollectionUtil.isNotEmpty(serviceHalls)) {
for (QtkServiceHall serviceHall : serviceHalls) {
ServiceHallSonQueryModel model = new ServiceHallSonQueryModel();
String serviceHallId = serviceHall.getServiceHallId();
model.setServicehallId(serviceHallId);
model.setServicehallName(serviceHall.getName());
List<QtkServiceHall> serviceHalls1 = collect.get(serviceHallId);
if (serviceHalls1 != null) {
model.setChildrens(querySon(serviceHalls1, collect));
}
returnModes.add(model);
}
returnModes.add(model);
}
return returnModes;
}

+ 3
- 0
zhywpt-app-userw/src/main/java/cn/com/taiji/userw/manager/wx/WxPayConfigManager.java Visa fil

@@ -6,6 +6,8 @@ import cn.com.taiji.userw.dto.wx.WxPayAddReqDTO;
import cn.com.taiji.userw.dto.wx.WxPayPageRequestDTO;
import cn.com.taiji.userw.dto.wx.WxPayUpdateReqDTO;

import java.util.List;

/**
* @Author:ChenChao
* @Date:2025/5/20 17:03
@@ -18,4 +20,5 @@ public interface WxPayConfigManager {
void add(WxPayAddReqDTO reqDto);

void update(WxPayUpdateReqDTO reqDto) throws ManagerException;

}

+ 3
- 0
zhywpt-app-userw/src/main/java/cn/com/taiji/userw/manager/wx/WxPayConfigManagerImpl.java Visa fil

@@ -12,6 +12,8 @@ import cn.com.taiji.userw.repo.jpa.request.CommonWxSignConfigPageRequest;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @Author:ChenChao
* @Date:2025/5/20 17:03
@@ -48,4 +50,5 @@ public class WxPayConfigManagerImpl extends AbstractManager implements WxPayConf
commonPayConfigRepo.merge(commonPayConfig);

}

}

+ 13
- 0
zhywpt-app-userw/src/main/java/cn/com/taiji/userw/repo/jpa/request/CenterAgencyPageRequest.java Visa fil

@@ -6,12 +6,25 @@ import cn.com.taiji.core.entity.basic.QtkAgencyMap;
import cn.com.taiji.core.entity.basic.QtkServicehallMap;
import lombok.Data;

import javax.persistence.Column;
import javax.validation.constraints.Size;

@Data
public class CenterAgencyPageRequest extends JpaPageableDataRequest<QtkAgencyMap> {

private String centerAgencyId;

private String centerAgencyName;

public CenterAgencyPageRequest() {
this.orderBy="insertTime";
this.desc=true;
}
@Override
public HqlBuilder toSelectHql() {
HqlBuilder hql = new HqlBuilder("from QtkAgencyMap where 1=1 ");
hql.append("and centerAgencyId like :centerAgencyId ", like(centerAgencyId));
hql.append("and centerAgencyName like :centerAgencyName ", like(centerAgencyName));
return hql;
}
}

+ 14
- 0
zhywpt-app-userw/src/main/java/cn/com/taiji/userw/repo/jpa/request/CenterServiceHallPageRequest.java Visa fil

@@ -6,12 +6,26 @@ import cn.com.taiji.core.entity.basic.QtkServiceHall;
import cn.com.taiji.core.entity.basic.QtkServicehallMap;
import lombok.Data;

import javax.persistence.Column;
import javax.validation.constraints.Size;

@Data
public class CenterServiceHallPageRequest extends JpaPageableDataRequest<QtkServicehallMap> {


private String centerServiceHallId;

private String centerServicehallName;

public CenterServiceHallPageRequest() {
this.orderBy="insertTime";
this.desc=true;
}
@Override
public HqlBuilder toSelectHql() {
HqlBuilder hql = new HqlBuilder("from QtkServicehallMap where 1=1 ");
hql.append("and centerServiceHallId like :centerServiceHallId ", like(centerServiceHallId));
hql.append("and centerServicehallName like :centerServicehallName ", like(centerServicehallName));
return hql;
}
}

+ 1
- 1
zhywpt-app-userw/src/main/java/cn/com/taiji/userw/repo/jpa/request/CommonPayConfigPageRequest.java Visa fil

@@ -16,7 +16,7 @@ public class CommonPayConfigPageRequest extends JpaDateTimePageableDataRequest<C
private String agencyId;//渠道编号

public CommonPayConfigPageRequest() {
this.orderBy="agencyId";
this.orderBy="insertTime";
this.desc=true;
}


Laddar…
Avbryt
Spara