ws
2023-09-25 89cb4ea9adbf4578cceb379b58f36d0ac2d05095
优化上海数据上报
已修改14个文件
已添加4个文件
462 ■■■■ 文件已修改
src/main/java/com/fzzy/api/view/Api1306.view.xml 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/api/view/repository/Api1102Rep.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/async/fzzy40/impl/Fzzy40Sync2104.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/otherview/sh2023/ShApi2104.view.xml 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/SH2023ApiRemoteService.java 173 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/SH2023PushService12.java 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1102.java 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1211.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1308.java 68 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1309.java 73 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1401.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1403.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1404.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api2103.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api2104.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/test/ApiTest.view.xml 27 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/test/ApiTestPR.java 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/resources/templates/home/home.html 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/fzzy/api/view/Api1306.view.xml
@@ -183,6 +183,10 @@
        <Property></Property>
        <Property name="label">补药方法</Property>
      </PropertyDef>
      <PropertyDef name="nlhqnddw">
        <Property></Property>
        <Property name="label">磷化氢浓度单位</Property>
      </PropertyDef>
      <PropertyDef name="zyrs">
        <Property></Property>
        <Property name="label">作业人数</Property>
@@ -487,6 +491,10 @@
        <Property name="name">xzzydh</Property>
      </DataColumn>
      <DataColumn>
        <Property name="property">nlhqnddw</Property>
        <Property name="name">nlhqnddw</Property>
      </DataColumn>
      <DataColumn>
        <Property name="property">cfdm</Property>
        <Property name="name">cfdm</Property>
      </DataColumn>
@@ -718,6 +726,11 @@
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">nlhqnddw</Property>
            <Property name="property">nlhqnddw</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">byff</Property>
            <Property name="property">byff</Property>
            <Editor/>
src/main/java/com/fzzy/api/view/repository/Api1102Rep.java
@@ -21,7 +21,7 @@
    /**
     * æŸ¥è¯¢æ‰€æœ‰çš„监控点位信息
     * æŸ¥è¯¢åº“区
     * @param kqdm
     * @return
     */
src/main/java/com/fzzy/async/fzzy40/impl/Fzzy40Sync2104.java
@@ -102,7 +102,7 @@
                sh2023Api2104.setLldm(kqdm);
                sh2023Api2104.setJz(sysData.getNetWeight());
                sh2023Api2104.setZhgxsh(sysData.getUpdateTime());
                sh2023Api2104.setZhgxsj(sysData.getUpdateTime());
                //获取货位信息
                api1105 = commonService.getApi1105Cache(sysData.getDepotId());
src/main/java/com/fzzy/otherview/sh2023/ShApi2104.view.xml
@@ -68,7 +68,7 @@
          <Property name="valueProperty">name</Property>
        </Property>
      </PropertyDef>
      <PropertyDef name="zhgxsh">
      <PropertyDef name="zhgxsj">
        <Property name="dataType">Date</Property>
        <Property name="label">最后更新时间</Property>
      </PropertyDef>
@@ -317,8 +317,8 @@
        <Property name="property">czbz</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="zhgxsh">
        <Property name="property">zhgxsh</Property>
      <DataColumn name="zhgxsj">
        <Property name="property">zhgxsj</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="bjw">
@@ -425,8 +425,8 @@
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">zhgxsh</Property>
            <Property name="property">zhgxsh</Property>
            <Property name="name">zhgxsj</Property>
            <Property name="property">zhgxsj</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
src/main/java/com/fzzy/push/sh2023/SH2023ApiRemoteService.java
@@ -297,6 +297,8 @@
                api1102.setBjw(ShAreaBjw.getBjw(code));
                api1102.setKqsx("2");
                api1102.setCbcr(count);
                //TODO åº“区状态
                api1102.setKqzt("1");
                list.add(api1102);
            }
            return JSON.toJSONString(list);
@@ -444,6 +446,9 @@
                api1111 = new SH2023Api1111();
                BeanUtils.copyProperties(apiData, api1111);
                api1111.setBjw(ShAreaBjw.getBjw(code));
                if (StringUtils.isEmpty(api1111.getBz())) {
                    api1111.setBz("无");
                }
                list.add(api1111);
            }
            return JSON.toJSONString(list);
@@ -588,7 +593,8 @@
                api1207.setDcrq(apiData.getDcrq());
                api1207.setBjw(ShAreaBjw.getBjw(code));
                //TODO åº“调单号
                api1207.setPch(apiData.getDchwdm() +  DateFormatUtils.format(apiData.getDcrq(), "yyyy"));
                api1207.setKddh(apiData.getDcdh().substring(21,33));
                list.add(api1207);
            }
            return JSON.toJSONString(list);
@@ -660,6 +666,11 @@
                BeanUtils.copyProperties(apiData, api1211);
                api1211.setZglkdm(api1211.getKqdm());
                //TODO è´§ä½ä»£ç  ç²®é£Ÿæ€§è´¨ä»£ç  æ¥ç²®ä»£ç 
//                api1211.setHwdm("91310114703439394M001000100101");
//                api1211.setLsxzdm("001");
//                api1211.setLldm("91310114703439394M001000100101");
                api1211.setBjw(ShAreaBjw.getBjw(code));
                api1211.setPch(apiData.getHwdm() + DateFormatUtils.format(apiData.getYwrq(), "yyyyMM"));
                if(StringUtils.isEmpty(api1211.getLldm())){
@@ -796,6 +807,43 @@
            }
            return JSON.toJSONString(list);
        }
        if (SH2023Constant.SH_2023_API_CODE_1308.equals(inteId)) {
            SH2023Api1308 api1308;
            //最后转换为json
            List<SH2023Api1308> list = new ArrayList<>();
            //把data转化成list集合
            List<Api1308> api1308List = castList(data, Api1308.class);
            for (Api1308 apiData : api1308List) {
                api1308 = new SH2023Api1308();
                BeanUtils.copyProperties(apiData, api1308);
                //TODO è´§ä½ä»£ç  å›¾åƒç¼–号 è§†é¢‘编号
                api1308.setHwdm("无");
                api1308.setBjw(ShAreaBjw.getBjw(code));
                List<Api1109> api1109List = api1109Rep.getDataByFileId(apiData.getFileStorageId());
                api1308.setTxbh(api1109List.get(0).getWjmc());
                api1308.setSpbh(api1109List.get(0).getWjmc());
                list.add(api1308);
            }
            return JSON.toJSONString(list);
        }
        if (SH2023Constant.SH_2023_API_CODE_1309.equals(inteId)) {
            SH2023Api1309 api1309;
            //最后转换为json
            List<SH2023Api1309> list = new ArrayList<>();
            //把data转化成list集合
            List<Api1309> api1308List = castList(data, Api1309.class);
            for (Api1309 apiData : api1308List) {
                api1309 = new SH2023Api1309();
                BeanUtils.copyProperties(apiData, api1309);
                api1309.setBjw(ShAreaBjw.getBjw(code));
                list.add(api1309);
            }
            return JSON.toJSONString(list);
        }
        if (SH2023Constant.SH_2023_API_CODE_1310.equals(inteId)) {
            SH2023Api1310 api1310;
            //最后转换为json
@@ -810,6 +858,7 @@
                api1310.setPch(apiData.getHwdm() + DateFormatUtils.format(apiData.getJysj(), "yyyy"));
                List<Api1202> api1202List = api1202Rep.getDataByHwdm(apiData.getHwdm());
                api1310.setLspzdm(api1202List.get(0).getLspzdm());
                api1310.setLsxzdm("002");
                list.add(api1310);
            }
            return JSON.toJSONString(list);
@@ -823,6 +872,7 @@
            for (Api1401 apiData : api1401List) {
                api1401 = new SH2023Api1401();
                BeanUtils.copyProperties(apiData, api1401);
                api1401.setBjw(ShAreaBjw.getBjw(code));
                list.add(api1401);
            }
            return JSON.toJSONString(list);
@@ -852,6 +902,7 @@
                BeanUtils.copyProperties(apiData, api1403);
                api1403.setJhzxdw(apiData.getJhxddw());
                api1403.setJhzxdwmc(apiData.getJhxddwmc());
                api1403.setBjw(ShAreaBjw.getBjw(code));
                list.add(api1403);
            }
            return JSON.toJSONString(list);
@@ -866,70 +917,102 @@
                api1404 = new SH2023Api1404();
                BeanUtils.copyProperties(apiData, api1404);
                //TODO æ˜Žç»†çŠ¶æ€
                api1404.setMxzt("1");
                api1404.setBjw(ShAreaBjw.getBjw(code));
                list.add(api1404);
            }
            return JSON.toJSONString(list);
        }
        if (SH2023Constant.SH_2023_API_CODE_2102.equals(inteId)) {
            SH2023Api2102 api2102;
        if (SH2023Constant.SH_2023_API_CODE_2101.equals(inteId)) {
            SH2023Api2101 api2101;
            //最后转换为json
            List<SH2023Api2102> list = new ArrayList<>();
            //把data转化成list集合
            List<Api1207> api1207List = castList(data, Api1207.class);
            for (Api1207 apiData : api1207List) {
                api2102 = new SH2023Api2102();
                BeanUtils.copyProperties(apiData, api2102);
                api2102.setDrdh(apiData.getDcdh());
                api2102.setDcrq(apiData.getDcrq());
                api2102.setPch(api2102.getDrhwdm() + DateFormatUtils.format(apiData.getDcrq(), "yyyy"));
                api2102.setBjw(ShAreaBjw.getBjw(code));
                //TODO åº“调单号
            List<SH2023Api2101> list = castList(data, SH2023Api2101.class);
                list.add(api2102);
            }
            return JSON.toJSONString(list);
        }
        if (SH2023Constant.SH_2023_API_CODE_2102.equals(inteId)) {
//            SH2023Api2102 api2102;
//            //最后转换为json
//            List<SH2023Api2102> list = new ArrayList<>();
//            //把data转化成list集合
//            List<Api1207> api1207List = castList(data, Api1207.class);
//            for (Api1207 apiData : api1207List) {
//                api2102 = new SH2023Api2102();
//                BeanUtils.copyProperties(apiData, api2102);
//                api2102.setDrdh(apiData.getDcdh());
//                api2102.setDcrq(apiData.getDcrq());
//                api2102.setPch(api2102.getDrhwdm() + DateFormatUtils.format(apiData.getDcrq(), "yyyy"));
//                api2102.setBjw(ShAreaBjw.getBjw(code));
//                //TODO åº“调单号
//
//                list.add(api2102);
//            }
            List<SH2023Api2102> list = castList(data, SH2023Api2102.class);
            return JSON.toJSONString(list);
        }
        if (SH2023Constant.SH_2023_API_CODE_2103.equals(inteId)) {
            SH2023Api2103 api2103;
            //最后转换为json
            //把data转化成list集合
            List<SH2023Api2103> list = castList(data, SH2023Api2103.class);
            List<SH2023Api2103Item> listItems = castList(list.get(0).getDlqplxq(), SH2023Api2103Item.class);
            list.get(0).setCzbz("i");
            list.get(0).setSh2023Api2103Items(listItems);
            return JSON.toJSONString(list);
        }
        if (SH2023Constant.SH_2023_API_CODE_2104.equals(inteId)) {
            SH2023Api2104 api2104;
            //最后转换为json
            //把data转化成list集合
            List<SH2023Api2104> list = castList(data, SH2023Api2104.class);
            return JSON.toJSONString(list);
        }
        if (SH2023Constant.SH_2023_API_CODE_2203.equals(inteId)) {
            SH2023Api2203 api2203;
            //最后转换为json
            List<SH2023Api2203> list = new ArrayList<>();
//            List<SH2023Api2203> list = new ArrayList<>();
            //把data转化成list集合
            List<Api1201> api1201List = castList(data, Api1201.class);
            for (Api1201 apiData : api1201List) {
                api2203 = new SH2023Api2203();
                BeanUtils.copyProperties(apiData, api2203);
                api2203.setHtbh(apiData.getHth());
//                api2203.setBdh();
                api2203.setCjrq(apiData.getQdrq());
//                api2203.setJyzt();
//                api2203.setLsxz();
//                api2203.setLspzmx();
//                api2203.setScnf();
//                api2203.setKd();
            List<SH2023Api2203> list = castList(data, SH2023Api2203.class);
//            for (Api1201 apiData : api1201List) {
//                api2203 = new SH2023Api2203();
//                BeanUtils.copyProperties(apiData, api2203);
//                api2203.setHtbh(apiData.getHth());
                //
                list.add(api2203);
            }
////                api2203.setBdh();
//                api2203.setCjrq(apiData.getQdrq());
////                api2203.setJyzt();
////                api2203.setLsxz();
////                api2203.setLspzmx();
////                api2203.setScnf();
////                api2203.setKd();
//                //
//                list.add(api2203);
//            }
            return JSON.toJSONString(list);
        }
        if (SH2023Constant.SH_2023_API_CODE_2204.equals(inteId)) {
            SH2023Api2204 api2204;
            //最后转换为json
            List<SH2023Api2204> list = new ArrayList<>();
//            List<SH2023Api2204> list = new ArrayList<>();
            //把data转化成list集合
            List<Api1310> api1310List = castList(data, Api1310.class);
            for (Api1310 apiData : api1310List) {
                api2204 = new SH2023Api2204();
                BeanUtils.copyProperties(apiData, api2204);
//                api2204.setSf();
//                api2204.setRksf();
//                api2204.setlldm();
                api2204.setBjw(ShAreaBjw.getBjw(code));
                api2204.setPch(apiData.getHwdm() + DateFormatUtils.format(apiData.getJysj(), "yyyy"));
                list.add(api2204);
            }
            List<SH2023Api2204> list = castList(data, SH2023Api2204.class);
//            for (Api1310 apiData : api1310List) {
//                api2204 = new SH2023Api2204();
//                BeanUtils.copyProperties(apiData, api2204);
////                api2204.setSf();
////                api2204.setRksf();
////                api2204.setlldm();
//                api2204.setBjw(ShAreaBjw.getBjw(code));
//                api2204.setPch(apiData.getHwdm() + DateFormatUtils.format(apiData.getJysj(), "yyyy"));
//                list.add(api2204);
//            }
            return JSON.toJSONString(list);
        }
        //财务报表数据封装
src/main/java/com/fzzy/push/sh2023/SH2023PushService12.java
@@ -378,6 +378,27 @@
     */
    public void pushData1211(ApiRemoteService apiRemoteService, ApiParam param) {
        //TODO
        //粮食性质转变单
        List<Api1211> list = api1211Rep.findPushDataByTime(param.getKqdm(), param.getStart(), param.getEnd());
        if (null == list || list.isEmpty()) {
            log.error("-----上海市平台2023版:未获取到粮食库存信息,不推送-----");
            return;
        }
        param.setInteId(SH2023Constant.SH_2023_API_CODE_1210);
        //推送,数据为集合形式
        ResponseDto responseDto = apiRemoteService.pushData(param, list);
        if (responseDto.getSuccess() == 0) {
            //推送成功,更新数据上传状态
            for (Api1211 data : list) {
                if (Constant.CZBZ_I.equals(data.getCzbz())) {
                    data.setCzbz(Constant.CZBZ_U);
                    //更新状态
                    api1211Rep.save(data);
                }
            }
        }
    }
@@ -462,7 +483,7 @@
        for (ApiInfoData infoData : items) {
            shApi2104 = JSONObject.parseObject(infoData.getData(), SH2023Api2104.class);
            shApi2104.setCzbz(infoData.getCzbz());
            shApi2104.setZhgxsh(infoData.getUpdateTime());
            shApi2104.setZhgxsj(infoData.getUpdateTime());
            list.add(shApi2104);
        }
        ResponseDto responseDto = apiRemoteService.pushData(param, list);
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1102.java
@@ -76,6 +76,9 @@
    @PropertyDef(label = "库区属性", description = "1:市级直属,2:区级直属,3:社会仓容,4:其他")
    private String kqsx;
    @PropertyDef(label = "标记位")
    @PropertyDef(label = "库区状态")
    private String kqzt;
    @PropertyDef(label = "标记位", description = "1:正常(默认), 2:退出储备粮承储")
    private String bjw;
}
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1211.java
@@ -52,8 +52,8 @@
    @PropertyDef(label = "月结标志")
    private Integer yjbz;
    @JSONField(format = "yyyy-MM-dd")
    @PropertyDef(label = "业务日期")
    @JSONField(format = "yyyy-MM-dd")
    private Date ywrq;
    @PropertyDef(label = "操作标志")
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1308.java
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,68 @@
package com.fzzy.push.sh2023.dto;
import com.alibaba.fastjson.annotation.JSONField;
import com.bstek.dorado.annotation.PropertyDef;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.io.Serializable;
import java.util.Date;
/**
 * æŽ¥å£è¡¨-视频监控异常事件告警基本信息接口
 *
 * @author ws
 * @date 2022-09-22 15:57
 */
@Data
@EqualsAndHashCode(callSuper = false)
public class SH2023Api1308 implements Serializable {
    /**
     *
     */
    private static final long serialVersionUID = 1L;
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private Date gjsj;
    @PropertyDef(label = "库区名称")
    private String kqmc;
    @PropertyDef(label = "库区代码")
    private String kqdm;
    @PropertyDef(label = "货位代码")
    private String hwdm;
    @PropertyDef(label = "库区地址")
    private String kqdz;
    @PropertyDef(label = "视频监控设备id")
    private String spjksbid;
    @PropertyDef(label = "安装位置类型")
    private String azwzlx;
    @PropertyDef(label = "监视区域说明")
    private String jsqysm;
    @PropertyDef(label = "异常告警说明")
    private String ycgjsm;
    @PropertyDef(label = "图像编号")
    private String txbh;
    @PropertyDef(label = "视频编号")
    private String spbh;
    @PropertyDef(label = "操作标志")
    private String czbz;
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private Date zhgxsj;
    @PropertyDef(label = "标记位")
    private String bjw;
}
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1309.java
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,73 @@
package com.fzzy.push.sh2023.dto;
import com.alibaba.fastjson.annotation.JSONField;
import com.bstek.dorado.annotation.PropertyDef;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.io.Serializable;
import java.util.Date;
/**
 * æŽ¥å£è¡¨-视频监控异常事件告警基本信息接口
 *
 * @author ws
 * @date 2022-09-22 15:57
 */
@Data
@EqualsAndHashCode(callSuper = false)
public class SH2023Api1309 implements Serializable {
    /**
     *
     */
    private static final long serialVersionUID = 1L;
    @PropertyDef(label = "预警信息代码")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private Date fbsj;
    @PropertyDef(label = "预警信息代码")
    private String yjxxdm;
    @PropertyDef(label = "违规主体类型")
    private String wgztlx;
    @PropertyDef(label = "违规单位代码")
    private String qydm;
    @PropertyDef(label = "违规行为人")
    private String wgxwr;
    @PropertyDef(label = "涉及库点")
    private String sjkd;
    @PropertyDef(label = "违规类型")
    private String wglx;
    @PropertyDef(label = "违规详情")
    private String wgqk;
    @PropertyDef(label = "当前处置状态")
    private String czzt;
    @PropertyDef(label = "处置内容")
    private String hxczqk;
    @PropertyDef(label = "处置人")
    private String hxczr;
    @PropertyDef(label = "处置时间")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private Date hxczsj;
    @PropertyDef(label = "操作标志")
    private String czbz;
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private Date zhgxsj;
    @PropertyDef(label = "标记位")
    private String bjw;
}
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1401.java
@@ -56,5 +56,9 @@
    @PropertyDef(label = "最后更新时间")
    private Date zhgxsj;
    @PropertyDef(label = "标记位")
    private String bjw;
}
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1403.java
@@ -59,5 +59,11 @@
    @PropertyDef(label = "最后更新时间")
    private Date zhgxsj;
    @PropertyDef(label = "操作标志")
    private String czbz;
    @PropertyDef(label = "标记位")
    private String bjw;
}
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api1404.java
@@ -59,4 +59,10 @@
    @PropertyDef(label = "最后更新时间")
    private Date zhgxsj;
    @PropertyDef(label = "操作标志")
    private String czbz;
    @PropertyDef(label = "标记位")
    private String bjw;
}
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api2103.java
@@ -2,6 +2,7 @@
import com.alibaba.fastjson.annotation.JSONField;
import com.bstek.dorado.annotation.PropertyDef;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fzzy.api.entity.ApiParent;
import lombok.Data;
@@ -74,6 +75,7 @@
    private Date zhgxsj;
    @Transient
    @JsonIgnore
    private List<SH2023Api2103Item> sh2023Api2103Items;
}
src/main/java/com/fzzy/push/sh2023/dto/SH2023Api2104.java
@@ -56,7 +56,7 @@
    @PropertyDef(label = "最后更新时间")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private Date zhgxsh;
    private Date zhgxsj;
    @PropertyDef(label = "批次号")
    private String pch;
src/main/java/com/fzzy/test/ApiTest.view.xml
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<ViewConfig>
  <Arguments/>
  <Context/>
  <Model/>
  <View layout="regionPadding:10">
    <Property name="packages">font-awesome,css-common</Property>
    <ToolBar>
      <ToolBarButton>
        <ClientEvent name="onClick">&#xD;
view.get(&quot;#ajaxDel&quot;).execute(function(result){&#xD;
        if(result){&#xD;
            $alert(result);&#xD;
        }&#xD;
});&#xD;
</ClientEvent>
        <Property name="caption">测试</Property>
        <Property name="iconClass">fa fa-minus</Property>
        <Property name="exClassName">toolbar-button-warn</Property>
        <Property name="width">100</Property>
      </ToolBarButton>
    </ToolBar>
    <AjaxAction id="ajaxDel">
      <Property name="service">apiTestPR#push1311</Property>
    </AjaxAction>
  </View>
</ViewConfig>
src/main/java/com/fzzy/test/ApiTestPR.java
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,41 @@
package com.fzzy.test;
import com.bstek.dorado.annotation.Expose;
import com.fzzy.api.data.ApiParam;
import com.fzzy.api.entity.ApiConfs;
import com.fzzy.api.service.ApiCommonService;
import com.fzzy.push.sh2023.SH2023ApiRemoteService;
import com.fzzy.push.sh2023.SH2023PushService13;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
@Component
@Slf4j
public class ApiTestPR {
    @Autowired
    private SH2023ApiRemoteService apiRemoteService;
    @Autowired
    private SH2023PushService13 pushService13;
    @Autowired
    private ApiCommonService apiCommonService;
    @Expose
    public String push1311(){
        String kqdm = "91310114703439394M001";
        ApiConfs apiConf = apiCommonService.getConf(kqdm);
        ApiParam param =new ApiParam();
        param.setInteId("1311");
        param.setKqdm(kqdm);
        param.setInteCategory("13");
        param.setPushProtocol("SB_SH_2023");
        param.setDeptId("5303_001");
//        String jsonString = "{\"spjksbid\":\"61020201401327020104\",\"sblxbm\":\"1\",\"spjklx\":\"1\",\"jkxlh\":\"123456789\",\"jkxh\":\"132456789\",\"jkcs\":\"1\",\"kqdm\":\"91310114703439394M001\",\"jksbmc\":\"测试名称\",\"jksbbm\":\"123456789\",\"tdbh\":\"1\",\"ajdm\":\"91310114703439394M0010001001\",\"sfazbgd\":\"Y\",\"zsqy\":\"测试数据\",\"azwzlx\":\"01\",\"azwz\":\"大门口\",\"jkjlxbm\":\"1\",\"hwdm\":\"91310114703439394M001000100101\",\"jktyzw\":\"1\",\"sbdlmm\":\"123\",\"sbdlmc\":\"测试\",\"sbdkh\":\"1\",\"sbipdz\":\"132.220.220\",\"zhgxsj\":\"2023-09-20 11:11:11\",\"czbz\":\"i\",\"bjw\":\"91310114703439394M001000100101\",\"bz\":\"备注\"}";
//        apiRemoteService.pushData(param,apiConf, jsonString);
        pushService13.pushData1311(apiRemoteService, param);
        return "success";
    }
}
src/main/resources/templates/home/home.html
@@ -311,6 +311,9 @@
                            <dd>
                                <a lay-href="com.fzzy.otherview.sh2023.ShApi2204.d">上海-定化水检验</a>
                            </dd>
                            <dd>
                                <a lay-href="com.fzzy.test.ApiTest.d">视频接口测试</a>
                            </dd>
                        </dl>
                    </li>