wuxw
2025-03-26 79c59e2d22ba3765a3ab87e59cd4326345885b9e
添加 公摊抄表
3个文件已修改
11个文件已添加
1171 ■■■■■ 已修改文件
java110-bean/src/main/java/com/java110/dto/floorShareReading/FloorShareReadingDto.java 152 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
java110-bean/src/main/java/com/java110/po/floorShareReading/FloorShareReadingPo.java 124 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
java110-db/src/main/resources/mapper/fee/FloorShareMeterV1ServiceDaoImplMapper.xml 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
java110-db/src/main/resources/mapper/fee/FloorShareReadingV1ServiceDaoImplMapper.xml 167 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
java110-interface/src/main/java/com/java110/intf/fee/IFloorShareReadingV1InnerServiceSMO.java 68 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
service-api/src/main/java/com/java110/api/smo/impl/ApiServiceSMOImpl.java 28 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
service-fee/src/main/java/com/java110/fee/cmd/meter/AuditFloorShareReadingCmd.java 74 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
service-fee/src/main/java/com/java110/fee/cmd/meter/DeleteFloorShareReadingCmd.java 72 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
service-fee/src/main/java/com/java110/fee/cmd/meter/ListFloorShareReadingCmd.java 84 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
service-fee/src/main/java/com/java110/fee/cmd/meter/SaveFloorShareReadingCmd.java 122 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
service-fee/src/main/java/com/java110/fee/dao/IFloorShareReadingV1ServiceDao.java 73 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
service-fee/src/main/java/com/java110/fee/dao/impl/FloorShareReadingV1ServiceDaoImpl.java 112 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
service-fee/src/main/java/com/java110/fee/smo/impl/FloorShareReadingV1InnerServiceSMOImpl.java 89 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
service-oa/src/main/java/com/java110/oa/cmd/work/FinishWorkCopyCmd.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
java110-bean/src/main/java/com/java110/dto/floorShareReading/FloorShareReadingDto.java
New file
@@ -0,0 +1,152 @@
package com.java110.dto.floorShareReading;
import com.java110.dto.PageDto;
import java.io.Serializable;
import java.util.Date;
/**
 * @ClassName FloorDto
 * @Description 楼栋抄表数据层封装
 * @Author wuxw
 * @Date 2019/4/24 8:52
 * @Version 1.0
 * add by wuxw 2019/4/24
 **/
public class FloorShareReadingDto extends PageDto implements Serializable {
    public static final String STATE_W = "W";// 待审核
    public static final String STATE_C = "C";// 审核完成
    public static final String STATE_F = "F";// 审核失败
    private String fsmId;
    private String remark;
    private String readingId;
    private String title;
    private String curReadingTime;
    private String createStaffName;
    private String curDegrees;
    private String preDegrees;
    private String auditStaffName;
    private String preReadingTime;
    private String state;
    private String communityId;
    private Date createTime;
    private String statusCd = "0";
    public String getFsmId() {
        return fsmId;
    }
    public void setFsmId(String fsmId) {
        this.fsmId = fsmId;
    }
    public String getRemark() {
        return remark;
    }
    public void setRemark(String remark) {
        this.remark = remark;
    }
    public String getReadingId() {
        return readingId;
    }
    public void setReadingId(String readingId) {
        this.readingId = readingId;
    }
    public String getTitle() {
        return title;
    }
    public void setTitle(String title) {
        this.title = title;
    }
    public String getCurReadingTime() {
        return curReadingTime;
    }
    public void setCurReadingTime(String curReadingTime) {
        this.curReadingTime = curReadingTime;
    }
    public String getCreateStaffName() {
        return createStaffName;
    }
    public void setCreateStaffName(String createStaffName) {
        this.createStaffName = createStaffName;
    }
    public String getCurDegrees() {
        return curDegrees;
    }
    public void setCurDegrees(String curDegrees) {
        this.curDegrees = curDegrees;
    }
    public String getPreDegrees() {
        return preDegrees;
    }
    public void setPreDegrees(String preDegrees) {
        this.preDegrees = preDegrees;
    }
    public String getAuditStaffName() {
        return auditStaffName;
    }
    public void setAuditStaffName(String auditStaffName) {
        this.auditStaffName = auditStaffName;
    }
    public String getPreReadingTime() {
        return preReadingTime;
    }
    public void setPreReadingTime(String preReadingTime) {
        this.preReadingTime = preReadingTime;
    }
    public String getState() {
        return state;
    }
    public void setState(String state) {
        this.state = state;
    }
    public String getCommunityId() {
        return communityId;
    }
    public void setCommunityId(String communityId) {
        this.communityId = communityId;
    }
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    public String getStatusCd() {
        return statusCd;
    }
    public void setStatusCd(String statusCd) {
        this.statusCd = statusCd;
    }
}
java110-bean/src/main/java/com/java110/po/floorShareReading/FloorShareReadingPo.java
New file
@@ -0,0 +1,124 @@
/*
 * Copyright 2017-2020 吴学文 and java110 team.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.java110.po.floorShareReading;
import java.io.Serializable;
import java.util.Date;
/**
 * 类表述: Po 数据模型实体对象 基本保持与数据库模型一直 用于 增加修改删除 等时的数据载体
 * add by 吴学文 at 2025-03-26 09:29:54 mail: 928255095@qq.com
 * open source address: https://gitee.com/wuxw7/MicroCommunity
 * 官网:http://www.homecommunity.cn
 * 温馨提示:如果您对此文件进行修改 请不要删除原有作者及注释信息,请补充您的 修改的原因以及联系邮箱如下
 * // modify by 张三 at 2021-09-12 第10行在某种场景下存在某种bug 需要修复,注释10至20行 加入 20行至30行
 */
public class FloorShareReadingPo implements Serializable {
    private String fsmId;
private String remark;
private String statusCd = "0";
private String readingId;
private String title;
private String curReadingTime;
private String createStaffName;
private String curDegrees;
private String preDegrees;
private String auditStaffName;
private String preReadingTime;
private String state;
private String communityId;
public String getFsmId() {
        return fsmId;
    }
public void setFsmId(String fsmId) {
        this.fsmId = fsmId;
    }
public String getRemark() {
        return remark;
    }
public void setRemark(String remark) {
        this.remark = remark;
    }
public String getStatusCd() {
        return statusCd;
    }
public void setStatusCd(String statusCd) {
        this.statusCd = statusCd;
    }
public String getReadingId() {
        return readingId;
    }
public void setReadingId(String readingId) {
        this.readingId = readingId;
    }
public String getTitle() {
        return title;
    }
public void setTitle(String title) {
        this.title = title;
    }
public String getCurReadingTime() {
        return curReadingTime;
    }
public void setCurReadingTime(String curReadingTime) {
        this.curReadingTime = curReadingTime;
    }
public String getCreateStaffName() {
        return createStaffName;
    }
public void setCreateStaffName(String createStaffName) {
        this.createStaffName = createStaffName;
    }
public String getCurDegrees() {
        return curDegrees;
    }
public void setCurDegrees(String curDegrees) {
        this.curDegrees = curDegrees;
    }
public String getPreDegrees() {
        return preDegrees;
    }
public void setPreDegrees(String preDegrees) {
        this.preDegrees = preDegrees;
    }
public String getAuditStaffName() {
        return auditStaffName;
    }
public void setAuditStaffName(String auditStaffName) {
        this.auditStaffName = auditStaffName;
    }
public String getPreReadingTime() {
        return preReadingTime;
    }
public void setPreReadingTime(String preReadingTime) {
        this.preReadingTime = preReadingTime;
    }
public String getState() {
        return state;
    }
public void setState(String state) {
        this.state = state;
    }
public String getCommunityId() {
        return communityId;
    }
public void setCommunityId(String communityId) {
        this.communityId = communityId;
    }
}
java110-db/src/main/resources/mapper/fee/FloorShareMeterV1ServiceDaoImplMapper.xml
@@ -70,10 +70,6 @@
    <!-- 修改楼栋公摊表信息 add by wuxw 2018-07-03 -->
    <update id="updateFloorShareMeterInfo" parameterType="Map">
        update floor_share_meter t set t.status_cd = #{statusCd}
        <if test="newBId != null and newBId != ''">
            ,t.b_id = #{newBId}
        </if>
        <if test="meterNum !=null and meterNum != ''">
            , t.meter_num= #{meterNum}
        </if>
java110-db/src/main/resources/mapper/fee/FloorShareReadingV1ServiceDaoImplMapper.xml
New file
@@ -0,0 +1,167 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="floorShareReadingV1ServiceDaoImpl">
    <!-- 保存楼栋抄表信息 add by wuxw 2018-07-03 -->
    <insert id="saveFloorShareReadingInfo" parameterType="Map">
        insert into floor_share_reading(
        fsm_id,remark,reading_id,title,cur_reading_time,create_staff_name,cur_degrees,pre_degrees,audit_staff_name,pre_reading_time,state,community_id
        ) values (
        #{fsmId},#{remark},#{readingId},#{title},#{curReadingTime},#{createStaffName},#{curDegrees},#{preDegrees},#{auditStaffName},#{preReadingTime},#{state},#{communityId}
        )
    </insert>
    <!-- 查询楼栋抄表信息 add by wuxw 2018-07-03 -->
    <select id="getFloorShareReadingInfo" parameterType="Map" resultType="Map">
        select t.fsm_id fsmId,t.remark,t.status_cd statusCd,t.reading_id readingId,t.title,t.cur_reading_time
        curReadingTime,t.create_staff_name createStaffName,t.cur_degrees curDegrees,t.pre_degrees
        preDegrees,t.audit_staff_name auditStaffName,t.pre_reading_time preReadingTime,t.state,t.community_id
        communityId,t.create_time createTime
        from floor_share_reading t
        where 1 =1
        <if test="fsmId !=null and fsmId != ''">
            and t.fsm_id= #{fsmId}
        </if>
        <if test="remark !=null and remark != ''">
            and t.remark= #{remark}
        </if>
        <if test="statusCd !=null and statusCd != ''">
            and t.status_cd= #{statusCd}
        </if>
        <if test="readingId !=null and readingId != ''">
            and t.reading_id= #{readingId}
        </if>
        <if test="title !=null and title != ''">
            and t.title= #{title}
        </if>
        <if test="curReadingTime !=null and curReadingTime != ''">
            and t.cur_reading_time= #{curReadingTime}
        </if>
        <if test="createStaffName !=null and createStaffName != ''">
            and t.create_staff_name= #{createStaffName}
        </if>
        <if test="curDegrees !=null and curDegrees != ''">
            and t.cur_degrees= #{curDegrees}
        </if>
        <if test="preDegrees !=null and preDegrees != ''">
            and t.pre_degrees= #{preDegrees}
        </if>
        <if test="auditStaffName !=null and auditStaffName != ''">
            and t.audit_staff_name= #{auditStaffName}
        </if>
        <if test="preReadingTime !=null and preReadingTime != ''">
            and t.pre_reading_time= #{preReadingTime}
        </if>
        <if test="state !=null and state != ''">
            and t.state= #{state}
        </if>
        <if test="communityId !=null and communityId != ''">
            and t.community_id= #{communityId}
        </if>
        order by t.create_time desc
        <if test="page != -1 and page != null ">
            limit #{page}, #{row}
        </if>
    </select>
    <!-- 修改楼栋抄表信息 add by wuxw 2018-07-03 -->
    <update id="updateFloorShareReadingInfo" parameterType="Map">
        update floor_share_reading t set t.status_cd = #{statusCd}
        <if test="newBId != null and newBId != ''">
            ,t.b_id = #{newBId}
        </if>
        <if test="fsmId !=null and fsmId != ''">
            , t.fsm_id= #{fsmId}
        </if>
        <if test="remark !=null and remark != ''">
            , t.remark= #{remark}
        </if>
        <if test="title !=null and title != ''">
            , t.title= #{title}
        </if>
        <if test="curReadingTime !=null and curReadingTime != ''">
            , t.cur_reading_time= #{curReadingTime}
        </if>
        <if test="createStaffName !=null and createStaffName != ''">
            , t.create_staff_name= #{createStaffName}
        </if>
        <if test="curDegrees !=null and curDegrees != ''">
            , t.cur_degrees= #{curDegrees}
        </if>
        <if test="preDegrees !=null and preDegrees != ''">
            , t.pre_degrees= #{preDegrees}
        </if>
        <if test="auditStaffName !=null and auditStaffName != ''">
            , t.audit_staff_name= #{auditStaffName}
        </if>
        <if test="preReadingTime !=null and preReadingTime != ''">
            , t.pre_reading_time= #{preReadingTime}
        </if>
        <if test="state !=null and state != ''">
            , t.state= #{state}
        </if>
        <if test="communityId !=null and communityId != ''">
            , t.community_id= #{communityId}
        </if>
        where 1=1
        <if test="readingId !=null and readingId != ''">
            and t.reading_id= #{readingId}
        </if>
    </update>
    <!-- 查询楼栋抄表数量 add by wuxw 2018-07-03 -->
    <select id="queryFloorShareReadingsCount" parameterType="Map" resultType="Map">
        select count(1) count
        from floor_share_reading t
        where 1 =1
        <if test="fsmId !=null and fsmId != ''">
            and t.fsm_id= #{fsmId}
        </if>
        <if test="remark !=null and remark != ''">
            and t.remark= #{remark}
        </if>
        <if test="statusCd !=null and statusCd != ''">
            and t.status_cd= #{statusCd}
        </if>
        <if test="readingId !=null and readingId != ''">
            and t.reading_id= #{readingId}
        </if>
        <if test="title !=null and title != ''">
            and t.title= #{title}
        </if>
        <if test="curReadingTime !=null and curReadingTime != ''">
            and t.cur_reading_time= #{curReadingTime}
        </if>
        <if test="createStaffName !=null and createStaffName != ''">
            and t.create_staff_name= #{createStaffName}
        </if>
        <if test="curDegrees !=null and curDegrees != ''">
            and t.cur_degrees= #{curDegrees}
        </if>
        <if test="preDegrees !=null and preDegrees != ''">
            and t.pre_degrees= #{preDegrees}
        </if>
        <if test="auditStaffName !=null and auditStaffName != ''">
            and t.audit_staff_name= #{auditStaffName}
        </if>
        <if test="preReadingTime !=null and preReadingTime != ''">
            and t.pre_reading_time= #{preReadingTime}
        </if>
        <if test="state !=null and state != ''">
            and t.state= #{state}
        </if>
        <if test="communityId !=null and communityId != ''">
            and t.community_id= #{communityId}
        </if>
    </select>
</mapper>
java110-interface/src/main/java/com/java110/intf/fee/IFloorShareReadingV1InnerServiceSMO.java
New file
@@ -0,0 +1,68 @@
/*
 * Copyright 2017-2020 吴学文 and java110 team.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.java110.intf.fee;
import com.java110.config.feign.FeignConfiguration;
import com.java110.dto.floorShareReading.FloorShareReadingDto;
import com.java110.po.floorShareReading.FloorShareReadingPo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import java.util.List;
/**
 * 类表述: 服务之前调用的接口类,不对外提供接口能力 只用于接口建调用
 * add by 吴学文 at 2025-03-26 09:29:54 mail: 928255095@qq.com
 * open source address: https://gitee.com/wuxw7/MicroCommunity
 * 官网:http://www.homecommunity.cn
 * 温馨提示:如果您对此文件进行修改 请不要删除原有作者及注释信息,请补充您的 修改的原因以及联系邮箱如下
 * // modify by 张三 at 2021-09-12 第10行在某种场景下存在某种bug 需要修复,注释10至20行 加入 20行至30行
 */
@FeignClient(name = "fee-service", configuration = {FeignConfiguration.class})
@RequestMapping("/floorShareReadingV1Api")
public interface IFloorShareReadingV1InnerServiceSMO {
    @RequestMapping(value = "/saveFloorShareReading", method = RequestMethod.POST)
    public int saveFloorShareReading(@RequestBody  FloorShareReadingPo floorShareReadingPo);
    @RequestMapping(value = "/updateFloorShareReading", method = RequestMethod.POST)
    public int updateFloorShareReading(@RequestBody  FloorShareReadingPo floorShareReadingPo);
    @RequestMapping(value = "/deleteFloorShareReading", method = RequestMethod.POST)
    public int deleteFloorShareReading(@RequestBody  FloorShareReadingPo floorShareReadingPo);
    /**
     * <p>查询小区楼信息</p>
     *
     *
     * @param floorShareReadingDto 数据对象分享
     * @return FloorShareReadingDto 对象数据
     */
    @RequestMapping(value = "/queryFloorShareReadings", method = RequestMethod.POST)
    List<FloorShareReadingDto> queryFloorShareReadings(@RequestBody FloorShareReadingDto floorShareReadingDto);
    /**
     * 查询<p>小区楼</p>总记录数
     *
     * @param floorShareReadingDto 数据对象分享
     * @return 小区下的小区楼记录数
     */
    @RequestMapping(value = "/queryFloorShareReadingsCount", method = RequestMethod.POST)
    int queryFloorShareReadingsCount(@RequestBody FloorShareReadingDto floorShareReadingDto);
}
service-api/src/main/java/com/java110/api/smo/impl/ApiServiceSMOImpl.java
@@ -156,7 +156,7 @@
        String serviceCode = dataFlow.getRequestHeaders().get(CommonConstant.HTTP_SERVICE);
        String logServiceCode = MappingCache.getValue(MappingConstant.DOMAIN_SYSTEM_SWITCH,MappingCache.LOG_SERVICE_CODE);
        String logServiceCode = MappingCache.getValue(MappingConstant.DOMAIN_SYSTEM_SWITCH, MappingCache.LOG_SERVICE_CODE);
        //日志查询不记录
        if ("/transactionLog/queryTransactionLog".equals(serviceCode)
@@ -164,7 +164,7 @@
                || "file.getFile".equals(serviceCode)
                || "file.getFileByObjId".equals(serviceCode)
                || "/machine/heartbeat".equals(serviceCode) // 心跳也不记录
                ) {
        ) {
            return;
        }
@@ -426,12 +426,12 @@
        ResponseEntity responseEntity = null;
        //配置c_service 时请注意 如果是以out 开头的调用外部的地址
        RestTemplate restTemplate ;
//        if (Environment.isStartBootWay()) {
        RestTemplate restTemplate;
        if (Environment.isStartBootWay()) {
            restTemplate = ApplicationContextFactory.getBean("outRestTemplate", RestTemplate.class);
//        } else {
//            restTemplate = ApplicationContextFactory.getBean("restTemplate", RestTemplate.class);
//        }
        } else {
            restTemplate = ApplicationContextFactory.getBean("restTemplate", RestTemplate.class);
        }
        try {
            if (CommonConstant.HTTP_METHOD_GET.equals(service.getMethod())) {
@@ -444,8 +444,9 @@
                        requestUrl = service.getUrl() + "?" + param;
                    }
                }
                requestUrl = BootReplaceUtil.replaceServiceName(requestUrl);
                if (Environment.isStartBootWay()) {
                    requestUrl = BootReplaceUtil.replaceServiceName(requestUrl);
                }
                responseEntity = restTemplate.exchange(requestUrl, HttpMethod.GET, httpEntity, String.class);
            } else if (CommonConstant.HTTP_METHOD_PUT.equals(service.getMethod())) {
@@ -491,7 +492,7 @@
        //String requestUrl = "http://127.0.0.1:8008" + serviceCode;
        String requestUrl = serviceCode;
        RestTemplate restTemplate ;
        RestTemplate restTemplate;
        if (Environment.isStartBootWay()) {
            requestUrl = Environment.BOOT_PATH + requestUrl;
            restTemplate = ApplicationContextFactory.getBean("outRestTemplate", RestTemplate.class);
@@ -565,6 +566,7 @@
    /**
     * 开始调度微服务
     *
     * @param appService
     * @param dataFlow
     * @param reqJson
@@ -574,7 +576,7 @@
        HttpHeaders header = new HttpHeaders();
        //todo 对头信息重新包装
        for (String key : dataFlow.getRequestCurrentHeaders().keySet()) {
            if("userName".equals(key) || "user-name".equals(key)){
            if ("userName".equals(key) || "user-name".equals(key)) {
                header.add(key, "-");
                continue;
            }
@@ -665,7 +667,7 @@
    private void saveLogMessage(String requestJson, String responseJson) {
        try {
            if (MappingConstant.VALUE_ON.equals(MappingCache.getValue(MappingConstant.DOMAIN_SYSTEM_SWITCH,MappingConstant.KEY_LOG_ON_OFF))) {
            if (MappingConstant.VALUE_ON.equals(MappingCache.getValue(MappingConstant.DOMAIN_SYSTEM_SWITCH, MappingConstant.KEY_LOG_ON_OFF))) {
                JSONObject log = new JSONObject();
                log.put("request", requestJson);
                log.put("response", responseJson);
@@ -683,7 +685,7 @@
     */
    private void saveCostTimeLogMessage(DataFlow dataFlow) {
        try {
            if (MappingConstant.VALUE_ON.equals(MappingCache.getValue(MappingConstant.DOMAIN_SYSTEM_SWITCH,MappingConstant.KEY_COST_TIME_ON_OFF))) {
            if (MappingConstant.VALUE_ON.equals(MappingCache.getValue(MappingConstant.DOMAIN_SYSTEM_SWITCH, MappingConstant.KEY_COST_TIME_ON_OFF))) {
                List<DataFlowLinksCost> dataFlowLinksCosts = dataFlow.getLinksCostDates();
                JSONObject costDate = new JSONObject();
                JSONArray costDates = new JSONArray();
service-fee/src/main/java/com/java110/fee/cmd/meter/AuditFloorShareReadingCmd.java
New file
@@ -0,0 +1,74 @@
/*
 * Copyright 2017-2020 吴学文 and java110 team.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.java110.fee.cmd.meter;
import com.alibaba.fastjson.JSONObject;
import com.java110.core.annotation.Java110Cmd;
import com.java110.core.annotation.Java110Transactional;
import com.java110.core.context.ICmdDataFlowContext;
import com.java110.core.event.cmd.Cmd;
import com.java110.core.event.cmd.CmdEvent;
import com.java110.intf.fee.IFloorShareReadingV1InnerServiceSMO;
import com.java110.po.floorShareReading.FloorShareReadingPo;
import com.java110.utils.exception.CmdException;
import com.java110.utils.util.Assert;
import com.java110.utils.util.BeanConvertUtil;
import com.java110.vo.ResultVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
 * 类表述:更新
 * 服务编码:floorShareReading.updateFloorShareReading
 * 请求路劲:/app/floorShareReading.UpdateFloorShareReading
 * add by 吴学文 at 2025-03-26 09:29:54 mail: 928255095@qq.com
 * open source address: https://gitee.com/wuxw7/MicroCommunity
 * 官网:http://www.homecommunity.cn
 * 温馨提示:如果您对此文件进行修改 请不要删除原有作者及注释信息,请补充您的 修改的原因以及联系邮箱如下
 * // modify by 张三 at 2021-09-12 第10行在某种场景下存在某种bug 需要修复,注释10至20行 加入 20行至30行
 */
@Java110Cmd(serviceCode = "meter.auditFloorShareReading")
public class AuditFloorShareReadingCmd extends Cmd {
    private static Logger logger = LoggerFactory.getLogger(AuditFloorShareReadingCmd.class);
    @Autowired
    private IFloorShareReadingV1InnerServiceSMO floorShareReadingV1InnerServiceSMOImpl;
    @Override
    public void validate(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) {
        Assert.hasKeyAndValue(reqJson, "readingId", "readingId不能为空");
        Assert.hasKeyAndValue(reqJson, "communityId", "communityId不能为空");
        super.validateProperty(cmdDataFlowContext);
    }
    @Override
    @Java110Transactional
    public void doCmd(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) throws CmdException {
        FloorShareReadingPo floorShareReadingPo = BeanConvertUtil.covertBean(reqJson, FloorShareReadingPo.class);
        int flag = floorShareReadingV1InnerServiceSMOImpl.updateFloorShareReading(floorShareReadingPo);
        if (flag < 1) {
            throw new CmdException("更新数据失败");
        }
        cmdDataFlowContext.setResponseEntity(ResultVo.success());
    }
}
service-fee/src/main/java/com/java110/fee/cmd/meter/DeleteFloorShareReadingCmd.java
New file
@@ -0,0 +1,72 @@
/*
 * Copyright 2017-2020 吴学文 and java110 team.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.java110.fee.cmd.meter;
import com.alibaba.fastjson.JSONObject;
import com.java110.core.annotation.Java110Cmd;
import com.java110.core.annotation.Java110Transactional;
import com.java110.core.context.ICmdDataFlowContext;
import com.java110.core.event.cmd.Cmd;
import com.java110.core.event.cmd.CmdEvent;
import com.java110.intf.fee.IFloorShareReadingV1InnerServiceSMO;
import com.java110.po.floorShareReading.FloorShareReadingPo;
import com.java110.utils.exception.CmdException;
import com.java110.utils.util.Assert;
import com.java110.utils.util.BeanConvertUtil;
import com.java110.vo.ResultVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
 * 类表述:删除
 * 服务编码:floorShareReading.deleteFloorShareReading
 * 请求路劲:/app/floorShareReading.DeleteFloorShareReading
 * add by 吴学文 at 2025-03-26 09:29:54 mail: 928255095@qq.com
 * open source address: https://gitee.com/wuxw7/MicroCommunity
 * 官网:http://www.homecommunity.cn
 * 温馨提示:如果您对此文件进行修改 请不要删除原有作者及注释信息,请补充您的 修改的原因以及联系邮箱如下
 * // modify by 张三 at 2021-09-12 第10行在某种场景下存在某种bug 需要修复,注释10至20行 加入 20行至30行
 */
@Java110Cmd(serviceCode = "meter.deleteFloorShareReading")
public class DeleteFloorShareReadingCmd extends Cmd {
    private static Logger logger = LoggerFactory.getLogger(DeleteFloorShareReadingCmd.class);
    @Autowired
    private IFloorShareReadingV1InnerServiceSMO floorShareReadingV1InnerServiceSMOImpl;
    @Override
    public void validate(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) {
        Assert.hasKeyAndValue(reqJson, "readingId", "readingId不能为空");
        Assert.hasKeyAndValue(reqJson, "communityId", "communityId不能为空");
        super.validateProperty(cmdDataFlowContext);
    }
    @Override
    @Java110Transactional
    public void doCmd(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) throws CmdException {
        FloorShareReadingPo floorShareReadingPo = BeanConvertUtil.covertBean(reqJson, FloorShareReadingPo.class);
        int flag = floorShareReadingV1InnerServiceSMOImpl.deleteFloorShareReading(floorShareReadingPo);
        if (flag < 1) {
            throw new CmdException("删除数据失败");
        }
        cmdDataFlowContext.setResponseEntity(ResultVo.success());
    }
}
service-fee/src/main/java/com/java110/fee/cmd/meter/ListFloorShareReadingCmd.java
New file
@@ -0,0 +1,84 @@
/*
 * Copyright 2017-2020 吴学文 and java110 team.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.java110.fee.cmd.meter;
import com.alibaba.fastjson.JSONObject;
import com.java110.core.annotation.Java110Cmd;
import com.java110.core.context.ICmdDataFlowContext;
import com.java110.core.event.cmd.Cmd;
import com.java110.core.event.cmd.CmdEvent;
import com.java110.intf.fee.IFloorShareReadingV1InnerServiceSMO;
import com.java110.utils.exception.CmdException;
import com.java110.utils.util.Assert;
import com.java110.utils.util.BeanConvertUtil;
import com.java110.vo.ResultVo;
import org.springframework.beans.factory.annotation.Autowired;
import com.java110.dto.floorShareReading.FloorShareReadingDto;
import java.util.List;
import java.util.ArrayList;
import org.springframework.http.ResponseEntity;
import org.springframework.http.HttpStatus;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
 * 类表述:查询
 * 服务编码:floorShareReading.listFloorShareReading
 * 请求路劲:/app/floorShareReading.ListFloorShareReading
 * add by 吴学文 at 2025-03-26 09:29:54 mail: 928255095@qq.com
 * open source address: https://gitee.com/wuxw7/MicroCommunity
 * 官网:http://www.homecommunity.cn
 * 温馨提示:如果您对此文件进行修改 请不要删除原有作者及注释信息,请补充您的 修改的原因以及联系邮箱如下
 * // modify by 张三 at 2021-09-12 第10行在某种场景下存在某种bug 需要修复,注释10至20行 加入 20行至30行
 */
@Java110Cmd(serviceCode = "meter.listFloorShareReading")
public class ListFloorShareReadingCmd extends Cmd {
  private static Logger logger = LoggerFactory.getLogger(ListFloorShareReadingCmd.class);
    @Autowired
    private IFloorShareReadingV1InnerServiceSMO floorShareReadingV1InnerServiceSMOImpl;
    @Override
    public void validate(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) {
        super.validatePageInfo(reqJson);
        Assert.hasKeyAndValue(reqJson, "communityId", "communityId不能为空");
        super.validateProperty(cmdDataFlowContext);
    }
    @Override
    public void doCmd(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) throws CmdException {
           FloorShareReadingDto floorShareReadingDto = BeanConvertUtil.covertBean(reqJson, FloorShareReadingDto.class);
           int count = floorShareReadingV1InnerServiceSMOImpl.queryFloorShareReadingsCount(floorShareReadingDto);
           List<FloorShareReadingDto> floorShareReadingDtos = null;
           if (count > 0) {
               floorShareReadingDtos = floorShareReadingV1InnerServiceSMOImpl.queryFloorShareReadings(floorShareReadingDto);
           } else {
               floorShareReadingDtos = new ArrayList<>();
           }
           ResultVo resultVo = new ResultVo((int) Math.ceil((double) count / (double) reqJson.getInteger("row")), count, floorShareReadingDtos);
           ResponseEntity<String> responseEntity = new ResponseEntity<String>(resultVo.toString(), HttpStatus.OK);
           cmdDataFlowContext.setResponseEntity(responseEntity);
    }
}
service-fee/src/main/java/com/java110/fee/cmd/meter/SaveFloorShareReadingCmd.java
New file
@@ -0,0 +1,122 @@
/*
 * Copyright 2017-2020 吴学文 and java110 team.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.java110.fee.cmd.meter;
import com.alibaba.fastjson.JSONObject;
import com.java110.core.annotation.Java110Cmd;
import com.java110.core.annotation.Java110Transactional;
import com.java110.core.context.CmdContextUtils;
import com.java110.core.context.ICmdDataFlowContext;
import com.java110.core.event.cmd.Cmd;
import com.java110.core.event.cmd.CmdEvent;
import com.java110.core.factory.GenerateCodeFactory;
import com.java110.dto.floorShareMeter.FloorShareMeterDto;
import com.java110.dto.floorShareReading.FloorShareReadingDto;
import com.java110.dto.user.UserDto;
import com.java110.intf.fee.IFloorShareMeterV1InnerServiceSMO;
import com.java110.intf.fee.IFloorShareReadingV1InnerServiceSMO;
import com.java110.intf.user.IUserV1InnerServiceSMO;
import com.java110.po.floorShareMeter.FloorShareMeterPo;
import com.java110.po.floorShareReading.FloorShareReadingPo;
import com.java110.utils.exception.CmdException;
import com.java110.utils.util.Assert;
import com.java110.utils.util.BeanConvertUtil;
import com.java110.utils.util.ListUtil;
import com.java110.vo.ResultVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.util.List;
/**
 * 类表述:保存
 * 服务编码:floorShareReading.saveFloorShareReading
 * 请求路劲:/app/floorShareReading.SaveFloorShareReading
 * add by 吴学文 at 2025-03-26 09:29:54 mail: 928255095@qq.com
 * open source address: https://gitee.com/wuxw7/MicroCommunity
 * 官网:http://www.homecommunity.cn
 * 温馨提示:如果您对此文件进行修改 请不要删除原有作者及注释信息,请补充您的 修改的原因以及联系邮箱如下
 * // modify by 张三 at 2021-09-12 第10行在某种场景下存在某种bug 需要修复,注释10至20行 加入 20行至30行
 */
@Java110Cmd(serviceCode = "meter.saveFloorShareReading")
public class SaveFloorShareReadingCmd extends Cmd {
    private static Logger logger = LoggerFactory.getLogger(SaveFloorShareReadingCmd.class);
    public static final String CODE_PREFIX_ID = "10";
    @Autowired
    private IFloorShareReadingV1InnerServiceSMO floorShareReadingV1InnerServiceSMOImpl;
    @Autowired
    private IFloorShareMeterV1InnerServiceSMO floorShareMeterV1InnerServiceSMOImpl;
    @Autowired
    private IUserV1InnerServiceSMO userV1InnerServiceSMOImpl;
    @Override
    public void validate(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) {
        Assert.hasKeyAndValue(reqJson, "fsmId", "请求报文中未包含fsmId");
        Assert.hasKeyAndValue(reqJson, "preDegrees", "请求报文中未包含preDegrees");
        Assert.hasKeyAndValue(reqJson, "curDegrees", "请求报文中未包含curDegrees");
        Assert.hasKeyAndValue(reqJson, "preReadingTime", "请求报文中未包含preReadingTime");
        Assert.hasKeyAndValue(reqJson, "curReadingTime", "请求报文中未包含curReadingTime");
        Assert.hasKeyAndValue(reqJson, "communityId", "请求报文中未包含communityId");
        super.validateProperty(cmdDataFlowContext);
    }
    @Override
    @Java110Transactional
    public void doCmd(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) throws CmdException {
        String userId = CmdContextUtils.getUserId(cmdDataFlowContext);
        UserDto userDto = new UserDto();
        userDto.setUserId(userId);
        List<UserDto> userDtos = userV1InnerServiceSMOImpl.queryUsers(userDto);
        Assert.listOnlyOne(userDtos, "用户不存在");
        FloorShareMeterDto floorShareMeterDto = new FloorShareMeterDto();
        floorShareMeterDto.setFsmId(reqJson.getString("fsmId"));
        floorShareMeterDto.setCommunityId(reqJson.getString("communityId"));
        List<FloorShareMeterDto> floorShareMeterDtos = floorShareMeterV1InnerServiceSMOImpl.queryFloorShareMeters(floorShareMeterDto);
        if (ListUtil.isNull(floorShareMeterDtos)) {
            throw new CmdException("未包含公摊表");
        }
        FloorShareReadingPo floorShareReadingPo = BeanConvertUtil.covertBean(reqJson, FloorShareReadingPo.class);
        floorShareReadingPo.setReadingId(GenerateCodeFactory.getGeneratorId(CODE_PREFIX_ID));
        floorShareReadingPo.setCreateStaffName(userDtos.get(0).getName());
        floorShareReadingPo.setState(FloorShareReadingDto.STATE_W);
        floorShareReadingPo.setTitle(userDtos.get(0).getName() + "提交" + floorShareMeterDtos.get(0).getFloorNum() + "栋"+floorShareMeterDtos.get(0).getMeterTypeName()+"抄表");
        int flag = floorShareReadingV1InnerServiceSMOImpl.saveFloorShareReading(floorShareReadingPo);
        if (flag < 1) {
            throw new CmdException("保存数据失败");
        }
        // todo 修改表度数和时间
        FloorShareMeterPo floorShareMeterPo = new FloorShareMeterPo();
        floorShareMeterPo.setFsmId(floorShareMeterDtos.get(0).getFsmId());
        floorShareMeterPo.setCurDegree(reqJson.getString("curDegrees"));
        floorShareMeterPo.setCurReadingTime(reqJson.getString("curReadingTime"));
        floorShareMeterV1InnerServiceSMOImpl.updateFloorShareMeter(floorShareMeterPo);
        cmdDataFlowContext.setResponseEntity(ResultVo.success());
    }
}
service-fee/src/main/java/com/java110/fee/dao/IFloorShareReadingV1ServiceDao.java
New file
@@ -0,0 +1,73 @@
/*
 * Copyright 2017-2020 吴学文 and java110 team.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.java110.fee.dao;
import com.java110.utils.exception.DAOException;
import java.util.List;
import java.util.Map;
/**
 * 类表述:
 * add by 吴学文 at 2025-03-26 09:29:54 mail: 928255095@qq.com
 * open source address: https://gitee.com/wuxw7/MicroCommunity
 * 官网:http://www.homecommunity.cn
 * 温馨提示:如果您对此文件进行修改 请不要删除原有作者及注释信息,请补充您的 修改的原因以及联系邮箱如下
 * // modify by 张三 at 2021-09-12 第10行在某种场景下存在某种bug 需要修复,注释10至20行 加入 20行至30行
 */
public interface IFloorShareReadingV1ServiceDao {
    /**
     * 保存 楼栋抄表信息
     * @param info
     * @throws DAOException DAO异常
     */
    int saveFloorShareReadingInfo(Map info) throws DAOException;
    /**
     * 查询楼栋抄表信息(instance过程)
     * 根据bId 查询楼栋抄表信息
     * @param info bId 信息
     * @return 楼栋抄表信息
     * @throws DAOException DAO异常
     */
    List<Map> getFloorShareReadingInfo(Map info) throws DAOException;
    /**
     * 修改楼栋抄表信息
     * @param info 修改信息
     * @throws DAOException DAO异常
     */
    int updateFloorShareReadingInfo(Map info) throws DAOException;
    /**
     * 查询楼栋抄表总数
     *
     * @param info 楼栋抄表信息
     * @return 楼栋抄表数量
     */
    int queryFloorShareReadingsCount(Map info);
}
service-fee/src/main/java/com/java110/fee/dao/impl/FloorShareReadingV1ServiceDaoImpl.java
New file
@@ -0,0 +1,112 @@
/*
 * Copyright 2017-2020 吴学文 and java110 team.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.java110.fee.dao.impl;
import com.alibaba.fastjson.JSONObject;
import com.java110.utils.constant.ResponseConstant;
import com.java110.utils.exception.DAOException;
import com.java110.utils.util.DateUtil;
import com.java110.core.base.dao.BaseServiceDao;
import com.java110.fee.dao.IFloorShareReadingV1ServiceDao;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.List;
import java.util.Map;
/**
 * 类表述:
 * add by 吴学文 at 2025-03-26 09:29:54 mail: 928255095@qq.com
 * open source address: https://gitee.com/wuxw7/MicroCommunity
 * 官网:http://www.homecommunity.cn
 * 温馨提示:如果您对此文件进行修改 请不要删除原有作者及注释信息,请补充您的 修改的原因以及联系邮箱如下
 * // modify by 张三 at 2021-09-12 第10行在某种场景下存在某种bug 需要修复,注释10至20行 加入 20行至30行
 */
@Service("floorShareReadingV1ServiceDaoImpl")
public class FloorShareReadingV1ServiceDaoImpl extends BaseServiceDao implements IFloorShareReadingV1ServiceDao {
    private static Logger logger = LoggerFactory.getLogger(FloorShareReadingV1ServiceDaoImpl.class);
    /**
     * 保存楼栋抄表信息 到 instance
     * @param info   bId 信息
     * @throws DAOException DAO异常
     */
    @Override
    public int saveFloorShareReadingInfo(Map info) throws DAOException {
        logger.debug("保存 saveFloorShareReadingInfo 入参 info : {}",info);
        int saveFlag = sqlSessionTemplate.insert("floorShareReadingV1ServiceDaoImpl.saveFloorShareReadingInfo",info);
        return saveFlag;
    }
    /**
     * 查询楼栋抄表信息(instance)
     * @param info bId 信息
     * @return List<Map>
     * @throws DAOException DAO异常
     */
    @Override
    public List<Map> getFloorShareReadingInfo(Map info) throws DAOException {
        logger.debug("查询 getFloorShareReadingInfo 入参 info : {}",info);
        List<Map> infos = sqlSessionTemplate.selectList("floorShareReadingV1ServiceDaoImpl.getFloorShareReadingInfo",info);
        return infos;
    }
    /**
     * 修改楼栋抄表信息
     * @param info 修改信息
     * @throws DAOException DAO异常
     */
    @Override
    public int updateFloorShareReadingInfo(Map info) throws DAOException {
        logger.debug("修改 updateFloorShareReadingInfo 入参 info : {}",info);
        int saveFlag = sqlSessionTemplate.update("floorShareReadingV1ServiceDaoImpl.updateFloorShareReadingInfo",info);
        return saveFlag;
    }
     /**
     * 查询楼栋抄表数量
     * @param info 楼栋抄表信息
     * @return 楼栋抄表数量
     */
    @Override
    public int queryFloorShareReadingsCount(Map info) {
        logger.debug("查询 queryFloorShareReadingsCount 入参 info : {}",info);
        List<Map> infos = sqlSessionTemplate.selectList("floorShareReadingV1ServiceDaoImpl.queryFloorShareReadingsCount", info);
        if (infos.size() < 1) {
            return 0;
        }
        return Integer.parseInt(infos.get(0).get("count").toString());
    }
}
service-fee/src/main/java/com/java110/fee/smo/impl/FloorShareReadingV1InnerServiceSMOImpl.java
New file
@@ -0,0 +1,89 @@
/*
 * Copyright 2017-2020 吴学文 and java110 team.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.java110.fee.smo.impl;
import com.java110.fee.dao.IFloorShareReadingV1ServiceDao;
import com.java110.intf.fee.IFloorShareReadingV1InnerServiceSMO;
import com.java110.dto.floorShareReading.FloorShareReadingDto;
import com.java110.po.floorShareReading.FloorShareReadingPo;
import com.java110.utils.util.BeanConvertUtil;
import com.java110.core.base.smo.BaseServiceSMO;
import com.java110.dto.user.UserDto;
import com.java110.dto.PageDto;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;
import java.util.ArrayList;
import java.util.List;
/**
 * 类表述: 服务之前调用的接口实现类,不对外提供接口能力 只用于接口建调用
 * add by 吴学文 at 2025-03-26 09:29:54 mail: 928255095@qq.com
 * open source address: https://gitee.com/wuxw7/MicroCommunity
 * 官网:http://www.homecommunity.cn
 * 温馨提示:如果您对此文件进行修改 请不要删除原有作者及注释信息,请补充您的 修改的原因以及联系邮箱如下
 * // modify by 张三 at 2021-09-12 第10行在某种场景下存在某种bug 需要修复,注释10至20行 加入 20行至30行
 */
@RestController
public class FloorShareReadingV1InnerServiceSMOImpl extends BaseServiceSMO implements IFloorShareReadingV1InnerServiceSMO {
    @Autowired
    private IFloorShareReadingV1ServiceDao floorShareReadingV1ServiceDaoImpl;
    @Override
    public int saveFloorShareReading(@RequestBody  FloorShareReadingPo floorShareReadingPo) {
        int saveFlag = floorShareReadingV1ServiceDaoImpl.saveFloorShareReadingInfo(BeanConvertUtil.beanCovertMap(floorShareReadingPo));
        return saveFlag;
    }
     @Override
    public int updateFloorShareReading(@RequestBody  FloorShareReadingPo floorShareReadingPo) {
        int saveFlag = floorShareReadingV1ServiceDaoImpl.updateFloorShareReadingInfo(BeanConvertUtil.beanCovertMap(floorShareReadingPo));
        return saveFlag;
    }
     @Override
    public int deleteFloorShareReading(@RequestBody  FloorShareReadingPo floorShareReadingPo) {
       floorShareReadingPo.setStatusCd("1");
       int saveFlag = floorShareReadingV1ServiceDaoImpl.updateFloorShareReadingInfo(BeanConvertUtil.beanCovertMap(floorShareReadingPo));
       return saveFlag;
    }
    @Override
    public List<FloorShareReadingDto> queryFloorShareReadings(@RequestBody  FloorShareReadingDto floorShareReadingDto) {
        //校验是否传了 分页信息
        int page = floorShareReadingDto.getPage();
        if (page != PageDto.DEFAULT_PAGE) {
            floorShareReadingDto.setPage((page - 1) * floorShareReadingDto.getRow());
        }
        List<FloorShareReadingDto> floorShareReadings = BeanConvertUtil.covertBeanList(floorShareReadingV1ServiceDaoImpl.getFloorShareReadingInfo(BeanConvertUtil.beanCovertMap(floorShareReadingDto)), FloorShareReadingDto.class);
        return floorShareReadings;
    }
    @Override
    public int queryFloorShareReadingsCount(@RequestBody FloorShareReadingDto floorShareReadingDto) {
        return floorShareReadingV1ServiceDaoImpl.queryFloorShareReadingsCount(BeanConvertUtil.beanCovertMap(floorShareReadingDto));    }
}
service-oa/src/main/java/com/java110/oa/cmd/work/FinishWorkCopyCmd.java
@@ -123,7 +123,7 @@
        workEventV1InnerServiceSMOImpl.saveWorkEvent(workEventPo);
        workTaskItemDto = new WorkTaskItemDto();
        workTaskItemDto.setTaskId(reqJson.getString("taskId"));
        workTaskItemDto.setWorkId(workTaskItemDtos.get(0).getWorkId());
        workTaskItemDto.setStates(new String[]{WorkTaskItemDto.STATE_COMPLETE,WorkTaskItemDto.STATE_WAIT});
        int count = workTaskItemV1InnerServiceSMOImpl.queryWorkTaskItemsCount(workTaskItemDto);