Commit d3003888 authored by 赵啸非's avatar 赵啸非

添加站点业务中子业务列表

parent aa7990b0
package com.mortals.xhx.module.site.model.vo;
import com.mortals.framework.model.BaseEntityLong;
import com.mortals.xhx.module.business.model.BusinessEntity;
import com.mortals.xhx.module.site.model.SiteBusinessEntity;
import lombok.Data;
......@@ -17,6 +18,8 @@ public class SiteBusinessVo extends BaseEntityLong {
/** 子站点事项 */
private List<SiteBusinessEntity> children = new ArrayList<>();
private List<BusinessEntity> businessChildren = new ArrayList<>();
/**
* 备注
*/
......
......@@ -54,12 +54,19 @@ public class SiteBusinessServiceImpl extends AbstractCRUDCacheServiceImpl<SiteBu
if (!ObjectUtils.isEmpty(item.getBusinessId())) {
BusinessEntity businessEntity = businessService.get(item.getBusinessId());
if (!ObjectUtils.isEmpty(businessEntity)) {
BeanUtils.copyProperties(businessEntity, item, "id");
item.setFlownum(businessEntity.getFlownum());
item.setCanorder(businessEntity.getCanorder());
item.setCantake(businessEntity.getCantake());
item.setDatashow(businessEntity.getDatashow());
item.setEnglishname(businessEntity.getEnglishname());
item.setBusinessType(businessEntity.getBusinessType());
//判断业务是否含有子业务
if (businessEntity.getIsBusiness() == IsBusinessEnum.一级业务.getValue()) {
//添加二级业务列表
List<BusinessEntity> businessEntities = businessService.find(new BusinessQuery().parentId(businessEntity.getId()));
businessEntity.setChildren(businessEntities);
if(!ObjectUtils.isEmpty(businessEntities)){
item.setBusinessChildren(businessEntities);
}
}
}
}
......
{
"local1": {
"base-local": {
"baseUrl": "http://127.0.0.1:17211/zwfw"
},
"dev": {
"base-dev": {
"baseUrl": "http://192.168.0.217:17311/zwfw"
},
"test2": {
"base-test": {
"baseUrl": "http://192.168.0.98:11071/zwfw"
}
}
\ No newline at end of file
###站点业务列表
POST {{baseUrl}}/site/business/list
Authorization: {{authToken}}
Content-Type: application/json
{
......
......@@ -18,7 +18,7 @@ client.global.set("authToken", JSON.parse(response.body).data.token);
###首页
POST {{baseUrl}}/login/index
Authorization: Bearer {{authToken}}
Authorization: {{authToken}}
Content-Type: application/json
{}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment