Skip to content

Commit 45102fc

Browse files
928255095gitee-org
authored andcommitted
优化查询业主成员
Signed-off-by: java110 <928255095@qq.com>
1 parent 64e4b5b commit 45102fc

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

service-user/src/main/java/com/java110/user/cmd/owner/QueryAppOwnerMembersCmd.java

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
import com.java110.utils.util.BeanConvertUtil;
2222
import com.java110.utils.util.ListUtil;
2323
import com.java110.utils.util.StringUtil;
24+
import com.java110.vo.ResultVo;
2425
import com.java110.vo.api.ApiOwnerDataVo;
2526
import com.java110.vo.api.ApiOwnerVo;
2627
import org.springframework.beans.factory.annotation.Autowired;
@@ -112,13 +113,7 @@ public void doCmd(CmdEvent event, ICmdDataFlowContext context, JSONObject reqJso
112113
ownerDtoList = new ArrayList<>();
113114
}
114115

115-
116-
ApiOwnerVo apiOwnerVo = new ApiOwnerVo();
117-
apiOwnerVo.setOwners(BeanConvertUtil.covertBeanList(ownerDtoList, ApiOwnerDataVo.class));
118-
apiOwnerVo.setTotal(total);
119-
apiOwnerVo.setRecords((int) Math.ceil((double) total / (double) row));
120-
121-
ResponseEntity<String> responseEntity = new ResponseEntity<String>(JSONObject.toJSONString(apiOwnerVo), HttpStatus.OK);
116+
ResponseEntity<String> responseEntity = ResultVo.createResponseEntity((int) Math.ceil((double) total / (double) row), total, ownerDtoList);
122117
context.setResponseEntity(responseEntity);
123118
}
124119
}

0 commit comments

Comments
 (0)