src/main/java/com/fzzy/async/fzzy35/impl/Fzzy35Sync1023.java
@@ -18,10 +18,10 @@ import com.fzzy.async.fzzy35.repository.Fzzy35SyncDrugLogDtlRep; import com.fzzy.async.fzzy35.repository.Fzzy35SyncDrugLogPeopleRep; import com.fzzy.async.fzzy35.repository.Fzzy35SyncDrugLogWayRep; import com.fzzy.otherview.gd2022.dto.GdApi1023; import com.fzzy.otherview.gd2022.dto.GdApi1023Dtl; import com.fzzy.otherview.gd2022.dto.GdApi1023People; import com.fzzy.otherview.gd2022.dto.GdApi1023Way; import com.fzzy.push.gd2022.dto.Gd2022Api1023; import com.fzzy.push.gd2022.dto.Gd2022Api1023Dtl; import com.fzzy.push.gd2022.dto.Gd2022Api1023People; import com.fzzy.push.gd2022.dto.Gd2022Api1023Way; import com.fzzy.push.gd2022.ApiCodeConstant; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.BeanUtils; @@ -80,75 +80,75 @@ return; } GdApi1023 gdApi1023; GdApi1023Way gdApi1023Way; GdApi1023People gdApi1023People; GdApi1023Dtl gdApi1023Dtl; Gd2022Api1023 GD2022Api1023; Gd2022Api1023Way gd2022Api1023Way; Gd2022Api1023People gd2022Api1023People; Gd2022Api1023Dtl gd2022Api1023Dtl; List<GdApi1023Dtl> dtlList; List<GdApi1023Way> wayList; List<GdApi1023People> peopleList; List<Gd2022Api1023Dtl> dtlList; List<Gd2022Api1023Way> wayList; List<Gd2022Api1023People> peopleList; List<ApiInfoData> apiInfoList; ApiInfoData infoData; Api1105 api1105; for (Fz35DrugLogApply data : list) { gdApi1023 = new GdApi1023(); BeanUtils.copyProperties(data, gdApi1023); gdApi1023.setXzbm(data.getXzbm().substring(7)); gdApi1023.setKqdm(kqdm); gdApi1023.setDwdm(kqdm.substring(0, 18)); gdApi1023.setYjmc(data.getDrugName()); gdApi1023.setYjlx(data.getDrugType()); gdApi1023.setZhgxsj(data.getUpdateTime()); GD2022Api1023 = new Gd2022Api1023(); BeanUtils.copyProperties(data, GD2022Api1023); GD2022Api1023.setXzbm(data.getXzbm().substring(7)); GD2022Api1023.setKqdm(kqdm); GD2022Api1023.setDwdm(kqdm.substring(0, 18)); GD2022Api1023.setYjmc(data.getDrugName()); GD2022Api1023.setYjlx(data.getDrugType()); GD2022Api1023.setZhgxsj(data.getUpdateTime()); //å¨ç²®ç²®æ æç»è¡¨ List<Fz35DrugLogDtl> dtls = drugLogDtlRep.listDrugLogDtl(data.getXzbm()); if (null != dtls && dtls.size() > 0) { dtlList = new ArrayList<>(); for (Fz35DrugLogDtl dtl : dtls) { gdApi1023Dtl = new GdApi1023Dtl(); BeanUtils.copyProperties(dtl, gdApi1023Dtl); gd2022Api1023Dtl = new Gd2022Api1023Dtl(); BeanUtils.copyProperties(dtl, gd2022Api1023Dtl); //è·åè´§ä½ä¿¡æ¯ api1105 = commonService.getApi1105Cache(dtl.getDepotId()); if (null == api1105) { continue; } gdApi1023Dtl.setCfdm(api1105.getHwdm().substring(0, 25)); gdApi1023Dtl.setLspzdm(dtl.getFoodVariety()); gdApi1023Dtl.setLsxzdm(dtl.getFoodType()); gdApi1023Dtl.setLsdjdm(dtl.getFoodLevel()); gdApi1023Dtl.setLssl(dtl.getNumber()); gdApi1023Dtl.setSf(dtl.getPerWet()); gdApi1023Dtl.setZz(dtl.getPerImpurity()); dtlList.add(gdApi1023Dtl); gd2022Api1023Dtl.setCfdm(api1105.getHwdm().substring(0, 25)); gd2022Api1023Dtl.setLspzdm(dtl.getFoodVariety()); gd2022Api1023Dtl.setLsxzdm(dtl.getFoodType()); gd2022Api1023Dtl.setLsdjdm(dtl.getFoodLevel()); gd2022Api1023Dtl.setLssl(dtl.getNumber()); gd2022Api1023Dtl.setSf(dtl.getPerWet()); gd2022Api1023Dtl.setZz(dtl.getPerImpurity()); dtlList.add(gd2022Api1023Dtl); } gdApi1023.setDtls(dtlList); GD2022Api1023.setDtls(dtlList); } List<Fz35DrugLogWay> ways = drugLogWayRep.listDrugLogWay(data.getXzbm()); if (null != ways && ways.size() > 0) { wayList = new ArrayList<>(); for (Fz35DrugLogWay way : ways) { gdApi1023Way = new GdApi1023Way(); BeanUtils.copyProperties(way, gdApi1023Way); wayList.add(gdApi1023Way); gd2022Api1023Way = new Gd2022Api1023Way(); BeanUtils.copyProperties(way, gd2022Api1023Way); wayList.add(gd2022Api1023Way); } gdApi1023.setWays(wayList); GD2022Api1023.setWays(wayList); } List<Fz35DrugLogPeople> peoples = drugLogPeopleRep.listDrugLogPeople(data.getXzbm()); if (null != peoples && peoples.size() > 0) { peopleList = new ArrayList<>(); for (Fz35DrugLogPeople people : peoples) { gdApi1023People = new GdApi1023People(); BeanUtils.copyProperties(people, gdApi1023People); peopleList.add(gdApi1023People); gd2022Api1023People = new Gd2022Api1023People(); BeanUtils.copyProperties(people, gd2022Api1023People); peopleList.add(gd2022Api1023People); } gdApi1023.setPeoples(peopleList); GD2022Api1023.setPeoples(peopleList); } //æä¹ åä¿åï¼åç¬åå ¥é彿 æ¥å£è¡¨ @@ -163,18 +163,18 @@ apiInfoList = apiInfoDataRep.getDataByInteAndData(ApiCodeConstant.API_1023, data.getXzbm(), kqdm); if (null == apiInfoList || apiInfoList.isEmpty()) { gdApi1023.setCzbz(Constant.CZBZ_I); GD2022Api1023.setCzbz(Constant.CZBZ_I); infoData.setCzbz(Constant.CZBZ_I); } else { gdApi1023.setCzbz(apiInfoList.get(0).getCzbz()); GD2022Api1023.setCzbz(apiInfoList.get(0).getCzbz()); infoData.setCzbz(apiInfoList.get(0).getCzbz()); } infoData.setData(JSON.toJSONString(gdApi1023)); infoData.setData(JSON.toJSONString(GD2022Api1023)); //ä¿åæ°æ® apiInfoDataRep.save(infoData); log.info("1023---åæ¥æ°æ®ï¼{}", gdApi1023.toString()); log.info("1023---åæ¥æ°æ®ï¼{}", GD2022Api1023.toString()); } } catch (Exception e) { src/main/java/com/fzzy/async/fzzy40/impl/Fzzy40Sync1023.java
@@ -12,10 +12,10 @@ import com.fzzy.async.fzzy40.repository.Fzzy40SyncDrugLogDtlRep; import com.fzzy.async.fzzy40.repository.Fzzy40SyncDrugLogPeopleRep; import com.fzzy.async.fzzy40.repository.Fzzy40SyncDrugLogWayRep; import com.fzzy.otherview.gd2022.dto.GdApi1023; import com.fzzy.otherview.gd2022.dto.GdApi1023Dtl; import com.fzzy.otherview.gd2022.dto.GdApi1023People; import com.fzzy.otherview.gd2022.dto.GdApi1023Way; import com.fzzy.push.gd2022.dto.Gd2022Api1023; import com.fzzy.push.gd2022.dto.Gd2022Api1023Dtl; import com.fzzy.push.gd2022.dto.Gd2022Api1023People; import com.fzzy.push.gd2022.dto.Gd2022Api1023Way; import com.fzzy.push.gd2022.ApiCodeConstant; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.BeanUtils; @@ -81,60 +81,60 @@ log.info("-------------没æè·åå°çè¸å¤æ¡ä¿¡æ¯------------------"); return; } List<GdApi1023Dtl> dtlList; List<GdApi1023Way> wayList; List<GdApi1023People> peopleList; List<Gd2022Api1023Dtl> dtlList; List<Gd2022Api1023Way> wayList; List<Gd2022Api1023People> peopleList; GdApi1023 gdApi1023; GdApi1023Dtl gdApi1023Dtl; GdApi1023Way gdApi1023Way; GdApi1023People gdApi1023People; Gd2022Api1023 GD2022Api1023; Gd2022Api1023Dtl gd2022Api1023Dtl; Gd2022Api1023Way gd2022Api1023Way; Gd2022Api1023People gd2022Api1023People; List<ApiInfoData> apiInfoList; ApiInfoData infoData; for (Fz40DrugLogApply data : list) { gdApi1023 = new GdApi1023(); BeanUtils.copyProperties(data, gdApi1023); gdApi1023.setXzbm(data.getXzbm().substring(8)); gdApi1023.setKqdm(kqdm); GD2022Api1023 = new Gd2022Api1023(); BeanUtils.copyProperties(data, GD2022Api1023); GD2022Api1023.setXzbm(data.getXzbm().substring(8)); GD2022Api1023.setKqdm(kqdm); List<Api1102> api1102List = api1102Rep.findPushData(kqdm); if (null != api1102List && api1102List.size() > 0) { gdApi1023.setKqmc(api1102List.get(0).getKqmc()); GD2022Api1023.setKqmc(api1102List.get(0).getKqmc()); } gdApi1023.setDwdm(kqdm.substring(0, 18)); GD2022Api1023.setDwdm(kqdm.substring(0, 18)); List<Api1101> api1101List = api1101Rep.findPushData(kqdm); if (null != api1101List && api1101List.size() > 0) { gdApi1023.setDwmc(api1101List.get(0).getDwmc()); GD2022Api1023.setDwmc(api1101List.get(0).getDwmc()); } gdApi1023.setYjmc(data.getDrugName()); gdApi1023.setYjlx(data.getDrugType()); gdApi1023.setLqrq(data.getLqsj()); gdApi1023.setZhgxsj(data.getUpdateTime()); GD2022Api1023.setYjmc(data.getDrugName()); GD2022Api1023.setYjlx(data.getDrugType()); GD2022Api1023.setLqrq(data.getLqsj()); GD2022Api1023.setZhgxsj(data.getUpdateTime()); //å¨ç²®ç²®æ æç»è¡¨ List<Fz40DrugLogDtl> dtls = drugLogDtlRep.listDrugLogDtl(data.getXzbm()); Api1105 api1105 = commonService.getApi1105Cache(data.getDepotId()); gdApi1023Dtl = new GdApi1023Dtl(); BeanUtils.copyProperties(data, gdApi1023Dtl); gd2022Api1023Dtl = new Gd2022Api1023Dtl(); BeanUtils.copyProperties(data, gd2022Api1023Dtl); if (null != api1105) { gdApi1023Dtl.setCfmc(api1105.getHwmc()); gdApi1023Dtl.setCfdm(api1105.getHwdm().substring(0,25)); gd2022Api1023Dtl.setCfmc(api1105.getHwmc()); gd2022Api1023Dtl.setCfdm(api1105.getHwdm().substring(0,25)); } gdApi1023Dtl.setLspzdm(data.getFoodVariety()); gdApi1023Dtl.setLsxzdm(data.getFoodType()); gdApi1023Dtl.setLsdjdm(data.getFoodLevel()); gdApi1023Dtl.setLssl(data.getNumber()); gdApi1023Dtl.setSf(data.getPerWet()); gdApi1023Dtl.setZz(data.getPerImpurity()); gd2022Api1023Dtl.setLspzdm(data.getFoodVariety()); gd2022Api1023Dtl.setLsxzdm(data.getFoodType()); gd2022Api1023Dtl.setLsdjdm(data.getFoodLevel()); gd2022Api1023Dtl.setLssl(data.getNumber()); gd2022Api1023Dtl.setSf(data.getPerWet()); gd2022Api1023Dtl.setZz(data.getPerImpurity()); dtlList = new ArrayList<>(); dtlList.add(gdApi1023Dtl); gdApi1023.setDtls(dtlList); dtlList.add(gd2022Api1023Dtl); GD2022Api1023.setDtls(dtlList); // if (null != dtls && dtls.size() > 0) { // dtlList = new ArrayList<>(); // for (Fz40DrugLogDtl dtl : dtls) { @@ -153,11 +153,11 @@ // } gdApi1023Way = new GdApi1023Way(); BeanUtils.copyProperties(data, gdApi1023Way); gd2022Api1023Way = new Gd2022Api1023Way(); BeanUtils.copyProperties(data, gd2022Api1023Way); wayList = new ArrayList<>(); wayList.add(gdApi1023Way); gdApi1023.setWays(wayList); wayList.add(gd2022Api1023Way); GD2022Api1023.setWays(wayList); // List<Fz40DrugLogWay> ways = drugLogWayRep.listDrugLogWay(data.getXzbm()); // if (null != ways && ways.size() > 0) { // wayList = new ArrayList<>(); @@ -173,12 +173,12 @@ if (null != peoples && peoples.size() > 0) { peopleList = new ArrayList<>(); for (Fz40DrugLogPeople people : peoples) { gdApi1023People = new GdApi1023People(); BeanUtils.copyProperties(people, gdApi1023People); gdApi1023People.setXm(people.getMx()); peopleList.add(gdApi1023People); gd2022Api1023People = new Gd2022Api1023People(); BeanUtils.copyProperties(people, gd2022Api1023People); gd2022Api1023People.setXm(people.getMx()); peopleList.add(gd2022Api1023People); } gdApi1023.setPeoples(peopleList); GD2022Api1023.setPeoples(peopleList); } //æä¹ åä¿åï¼åç¬åå ¥é彿 æ¥å£è¡¨ infoData = new ApiInfoData(); @@ -192,20 +192,20 @@ apiInfoList = apiInfoDataRep.getDataByInteAndData(ApiCodeConstant.API_1023, data.getXzbm(), kqdm); if (null == apiInfoList || apiInfoList.isEmpty()) { gdApi1023.setCzbz(Constant.CZBZ_I); GD2022Api1023.setCzbz(Constant.CZBZ_I); infoData.setCzbz(Constant.CZBZ_I); infoData.setId(ContextUtil.getUUID()); } else { gdApi1023.setCzbz(apiInfoList.get(0).getCzbz()); GD2022Api1023.setCzbz(apiInfoList.get(0).getCzbz()); infoData.setCzbz(apiInfoList.get(0).getCzbz()); infoData.setId(apiInfoList.get(0).getId()); } infoData.setData(JSON.toJSONString(gdApi1023)); infoData.setData(JSON.toJSONString(GD2022Api1023)); //ä¿åæ°æ® apiInfoDataRep.save(infoData); log.info("1023---åæ¥æ°æ®ï¼{}", gdApi1023.toString()); log.info("1023---åæ¥æ°æ®ï¼{}", GD2022Api1023.toString()); } } catch (Exception e) { src/main/java/com/fzzy/otherview/gd2022/GdApi1023.view.xml
@@ -4,7 +4,7 @@ <Context/> <Model> <DataType name="dtMain"> <Property name="creationType">com.fzzy.otherview.gd2022.dto.GdApi1023</Property> <Property name="creationType">com.fzzy.push.gd2022.dto.Gd2022Api1023</Property> <PropertyDef name="xzbm"> <Property></Property> <Property name="label">çè¸ç¼ç </Property> @@ -156,7 +156,7 @@ </PropertyDef> </DataType> <DataType name="dtPeople"> <Property name="creationType">com.fzzy.otherview.gd2022.dto.GdApi1023People</Property> <Property name="creationType">com.fzzy.push.gd2022.dto.Gd2022Api1023People</Property> <PropertyDef name="xm"> <Property></Property> <Property name="label">å§å</Property> @@ -183,7 +183,7 @@ </PropertyDef> </DataType> <DataType name="dtWay"> <Property name="creationType">com.fzzy.otherview.gd2022.dto.GdApi1023Way</Property> <Property name="creationType">com.fzzy.push.gd2022.dto.Gd2022Api1023Way</Property> <PropertyDef name="xznd"> <Property></Property> <Property name="label">设å®çè¸æµåº¦(ml/m3)</Property> @@ -205,7 +205,7 @@ </PropertyDef> </DataType> <DataType name="dtDtl"> <Property name="creationType">com.fzzy.otherview.gd2022.dto.GdApi1023Dtl</Property> <Property name="creationType">com.fzzy.push.gd2022.dto.Gd2022Api1023Dtl</Property> <PropertyDef name="cfdm"> <Property></Property> <Property name="label">仿¿/æ²¹ç½ä»£ç </Property> src/main/java/com/fzzy/otherview/gd2022/GdApi2001.view.xml
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,492 @@ <?xml version="1.0" encoding="UTF-8"?> <ViewConfig> <Arguments/> <Context/> <Model> <DataType name="dtMain"> <Property name="creationType">com.fzzy.push.gd2022.dto.Gd2022Api2001</Property> <PropertyDef name="fcqrdh"> <Property></Property> <Property name="label">å°ä»ç¡®è®¤åå·</Property> </PropertyDef> <PropertyDef name="cfdm"> <Property></Property> <Property name="label">仿¿ä»£ç </Property> </PropertyDef> <PropertyDef name="tycfbm"> <Property></Property> <Property name="label">ç»ä¸ä»æ¿ç¼ç </Property> </PropertyDef> <PropertyDef name="ajdm"> <Property></Property> <Property name="label">å»é´ä»£ç </Property> </PropertyDef> <PropertyDef name="tyajbm"> <Property></Property> <Property name="label">ç»ä¸å»é´ç¼ç </Property> </PropertyDef> <PropertyDef name="fcrq"> <Property name="dataType">Date</Property> <Property name="label">å°ä»æ¥æ</Property> </PropertyDef> <PropertyDef name="lspzdm"> <Property></Property> <Property name="label">ç²®é£åç§ä»£ç </Property> <Property name="mapping"> <Property name="mapValues">${dorado.getDataProvider("apiTriggerService#trigger").getResult("LSPZ")}</Property> <Property name="keyProperty">code</Property> <Property name="valueProperty">name</Property> </Property> </PropertyDef> <PropertyDef name="lsxzdm"> <Property></Property> <Property name="label">ç²®é£æ§è´¨ä»£ç </Property> <Property name="mapping"> <Property name="mapValues">${dorado.getDataProvider("apiTriggerService#trigger").getResult("LSXZ")}</Property> <Property name="keyProperty">code</Property> <Property name="valueProperty">name</Property> </Property> </PropertyDef> <PropertyDef name="lsdjdm"> <Property></Property> <Property name="label">ç²®é£ç级代ç </Property> <Property name="mapping"> <Property name="mapValues">${dorado.getDataProvider("apiTriggerService#trigger").getResult("LSDJ")}</Property> <Property name="keyProperty">code</Property> <Property name="valueProperty">name</Property> </Property> </PropertyDef> <PropertyDef name="shnd"> <Property></Property> <Property name="label">æ¶è·å¹´åº¦</Property> </PropertyDef> <PropertyDef name="gb"> <Property></Property> <Property name="label">å½å«</Property> <Property name="mapping"> <Property name="mapValues">${dorado.getDataProvider("apiTriggerService#trigger").getResult("GB")}</Property> <Property name="keyProperty">code</Property> <Property name="valueProperty">name</Property> </Property> </PropertyDef> <PropertyDef name="cd"> <Property></Property> <Property name="label">产å°</Property> </PropertyDef> <PropertyDef name="bgy"> <Property></Property> <Property name="label">ä¿ç®¡å</Property> </PropertyDef> <PropertyDef name="fcsl"> <Property></Property> <Property name="label">å°ä»æ°é(kg)</Property> </PropertyDef> <PropertyDef name="fcsrq"> <Property></Property> <Property name="label">å°ä»ç³è¯·äºº</Property> </PropertyDef> <PropertyDef name="bmshr"> <Property></Property> <Property name="label">é¨é¨å®¡æ ¸äºº</Property> </PropertyDef> <PropertyDef name="ldshr"> <Property></Property> <Property name="label">é¢å¯¼å®¡æ ¸äºº</Property> </PropertyDef> <PropertyDef name="bz"> <Property></Property> <Property name="label">夿³¨</Property> </PropertyDef> <PropertyDef name="czbz"> <Property name="label">æä½æ å¿</Property> <Property name="mapping"> <Property name="mapValues">${dorado.getDataProvider("apiTriggerService#trigger").getResult("CZBZ")}</Property> <Property name="keyProperty">code</Property> <Property name="valueProperty">name</Property> </Property> </PropertyDef> <PropertyDef name="zhgxsj"> <Property name="dataType">DateTime</Property> <Property name="label">æåæ´æ°æ¶é´</Property> </PropertyDef> </DataType> <DataType name="dtParam"> <Property name="creationType">com.fzzy.api.data.ApiParam</Property> <PropertyDef name="kqdm"> <Property></Property> <Property name="label">æå±åºåº</Property> </PropertyDef> <PropertyDef name="start"> <Property name="dataType">Date</Property> <Property name="label">å¼å§æ¶é´</Property> </PropertyDef> <PropertyDef name="end"> <Property name="dataType">Date</Property> <Property name="label">æªæ¢æ¶é´</Property> </PropertyDef> <PropertyDef name="czbz"> <Property></Property> <Property name="label">æä½æ å¿</Property> <Property name="mapping"> <Property name="mapValues">${dorado.getDataProvider("apiTriggerService#trigger").getResult("CZBZ")}</Property> <Property name="keyProperty">code</Property> <Property name="valueProperty">name</Property> </Property> </PropertyDef> </DataType> </Model> <View layout="regionPadding:10"> <Property name="packages">font-awesome,css-common</Property> <DataSet id="dsMain"> <Property name="dataType">[dtMain]</Property> <Property name="dataProvider">gDApi2001PR#listData</Property> <Property name="pageSize">15</Property> </DataSet> <DataSet id="dsQuery"> <ClientEvent name="onReady">self.insert();</ClientEvent> <Property name="dataType">dtParam</Property> </DataSet> <ToolBar> <ToolBarLabel> <Property name="text">å·¥å ·æ ï¼</Property> <Property name="style"> <Property name="font-weight">bold</Property> </Property> </ToolBarLabel> <ToolBarButton> <ClientEvent name="onClick">var query = view.get("#dsQuery").getData();
 view.get("#dsMain").set("parameter",query).flushAsync();</ClientEvent> <Property name="caption">æ¥è¯¢</Property> <Property name="iconClass">fa fa-search</Property> <Property name="width">100</Property> <Property name="exClassName">toolbar-button-push</Property> </ToolBarButton> <ToolBarButton id="btnAdd"> <ClientEvent name="onClick">view.get("#dsMain").insert();
 view.get("#dialogMain").show();</ClientEvent> <Property name="caption">æ°å¢</Property> <Property name="iconClass">fa fa-plus</Property> <Property name="width">100</Property> <Property name="exClassName">toolbar-button</Property> <Property name="hideMode">display</Property> </ToolBarButton> <ToolBarButton id="btnUpdate"> <ClientEvent name="onClick">var cur = view.get("#dgMain").getCurrentItem();
 if(cur){
 view.get("#dialogMain").show();
 }</ClientEvent> <Property name="caption">ä¿®æ¹</Property> <Property name="iconClass">fa fa-pencil</Property> <Property name="width">100</Property> <Property name="exClassName">toolbar-button-warm</Property> <Property name="hideMode">display</Property> </ToolBarButton> <ToolBarButton> <ClientEvent name="onClick">var cur = view.get("#dgMain").getCurrentItem();
 view.get("#ajaxDelUpdate").set("parameter",cur).execute(function(result){
 if(result){
 $alert(result);
 } else{
 cur.set("czbz","d")
 }
 });
 </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> <ToolBarButton id="btnDel"> <ClientEvent name="onClick">var cur = view.get("#dgMain").getCurrentItem();
 view.get("#ajaxDel").set("parameter",cur).execute(function(result){
 if(result){
 $alert(result);
 } else{
 cur.remove();
 }
 });
 </ClientEvent> <Property name="caption">ç´æ¥å é¤</Property> <Property name="iconClass">fa fa-minus</Property> <Property name="exClassName">toolbar-button-warn</Property> <Property name="width">100</Property> <Property name="hideMode">display</Property> </ToolBarButton> <ToolBarButton> <ClientEvent name="onClick">var select = view.get("#dgMain").get("selection");
 if(select && select.length > 0){
 view.get("#ajaxPush").set("parameter",select).execute(function(result){
 view.get("#dsMain").flushAsync();
 $notify(result);
 });
 }else{
 $alert("请å¾é䏿¥æ°æ®ï¼");
 }
 </ClientEvent> <Property name="caption">æå¨ä¸ä¼ </Property> <Property name="iconClass">fa fa-hand-o-up</Property> <Property name="exClassName">toolbar-button-push</Property> <Property name="width">100</Property> </ToolBarButton> <Fill/> <ToolBarButton> <Property name="caption">ä¸ä¼ è®°å½</Property> <Property name="iconClass">fa fa-bars</Property> <Property name="exClassName">toolbar-button</Property> <Property name="width">100</Property> </ToolBarButton> </ToolBar> <AutoForm> <Property name="dataSet">dsQuery</Property> <Property name="cols">*,*,*,*</Property> <Property name="labelAlign">right</Property> <Property name="labelSeparator">ï¼</Property> <Property name="labelWidth">90</Property> <AutoFormElement> <Property name="name">kqdm</Property> <Property name="property">kqdm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">start</Property> <Property name="property">start</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">end</Property> <Property name="property">end</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">czbz</Property> <Property name="property">czbz</Property> <Property name="trigger">autoMappingDropDown2</Property> <Editor/> </AutoFormElement> </AutoForm> <DataGrid id="dgMain"> <ClientEvent name="onDataRowDoubleClick">view.get("#dialogMain").show();</ClientEvent> <Property name="dataSet">dsMain</Property> <Property name="selectionMode">multiRows</Property> <Property name="readOnly">true</Property> <RowNumColumn/> <RowSelectorColumn> <Property name="caption">ä¸ä¼ </Property> </RowSelectorColumn> <DataColumn name="fcqrdh"> <Property name="property">fcqrdh</Property> <Property name="width">180</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="cfdm"> <Property name="property">cfdm</Property> <Property name="width">210</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="ajdm"> <Property name="property">ajdm</Property> <Property name="width">230</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="fcrq"> <Property name="property">fcrq</Property> <Property name="width">100</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="lspzdm"> <Property name="property">lspzdm</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="lsxzdm"> <Property name="property">lsxzdm</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="lsdjdm"> <Property name="property">lsdjdm</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="fcsl"> <Property name="property">fcsl</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="czbz"> <Property name="property">czbz</Property> <Property name="width">70</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="zhgxsj"> <Property name="property">zhgxsj</Property> <Property name="width">160</Property> <Property name="align">center</Property> </DataColumn> </DataGrid> <ToolBar layoutConstraint="bottom"> <Fill/> <DataPilot> <Property name="itemCodes">pageSize,pages</Property> <Property name="dataSet">dsMain</Property> </DataPilot> </ToolBar> <Dialog id="dialogMain" layout="regionPadding:5"> <Property name="width">80%</Property> <Property name="caption">å°ä»ç¡®è®¤åä¿¡æ¯</Property> <Property name="iconClass">fa fa-sliders</Property> <Property name="closeable">false</Property> <Buttons> <Button> <ClientEvent name="onClick">var cur = view.get("#dgMain").getCurrentItem();
 view.get("#updateSave").execute(function(){
 self.get("parent").hide();
 });</ClientEvent> <Property name="caption">ä¿åä¿®æ¹</Property> <Property name="iconClass">fa fa-check</Property> <Property name="exClassName">toolbar-button</Property> </Button> <Button> <ClientEvent name="onClick">var cur = view.get("#dgMain").getCurrentItem();
 self.get("parent").hide();
 if(cur) cur.cancel();</ClientEvent> <Property name="caption">åæ¶ä¿®æ¹</Property> <Property name="iconClass">fa fa-times</Property> <Property name="exClassName">toolbar-button-warn</Property> </Button> </Buttons> <Children> <FieldSet layout="regionPadding:5"> <Property name="caption">åºæ¬ä¿¡æ¯</Property> <Buttons/> <Children> <AutoForm> <Property name="dataSet">dsMain</Property> <Property name="cols">*,*,*</Property> <Property name="labelWidth">160</Property> <Property name="labelAlign">left</Property> <Property name="labelSeparator">ï¼</Property> <Property name="labelPosition">left</Property> <AutoFormElement> <Property name="name">fcqrdh</Property> <Property name="property">fcqrdh</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">cfdm</Property> <Property name="property">cfdm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">tycfbm</Property> <Property name="property">tycfbm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">ajdm</Property> <Property name="property">ajdm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">tyajbm</Property> <Property name="property">tyajbm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">fcrq</Property> <Property name="property">fcrq</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">lspzdm</Property> <Property name="property">lspzdm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">lsxzdm</Property> <Property name="property">lsxzdm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">lsdjdm</Property> <Property name="property">lsdjdm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">shnd</Property> <Property name="property">shnd</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">gb</Property> <Property name="property">gb</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">cd</Property> <Property name="property">cd</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">bgy</Property> <Property name="property">bgy</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">fcsl</Property> <Property name="property">fcsl</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">fcsrq</Property> <Property name="property">fcsrq</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">bmshr</Property> <Property name="property">bmshr</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">ldshr</Property> <Property name="property">ldshr</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">bz</Property> <Property name="property">bz</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">czbz</Property> <Property name="property">czbz</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">zhgxsj</Property> <Property name="property">zhgxsj</Property> <Editor/> </AutoFormElement> </AutoForm> </Children> </FieldSet> </Children> <Tools/> </Dialog> <UpdateAction id="updateSave"> <Property name="dataResolver">gDApi2001PR#saveData</Property> <UpdateItem> <Property name="dataPath">[#current]</Property> <Property name="dataSet">dsMain</Property> </UpdateItem> </UpdateAction> <AjaxAction id="ajaxPush"> <Property name="service">gDApi2001PR#pushData</Property> <Property name="confirmMessage">ç¡®å®è¦ä¸æ¥ä¹ï¼</Property> </AjaxAction> <AjaxAction id="ajaxDel"> <Property name="service">gDApi2001PR#delData</Property> <Property name="confirmMessage">å½åæ°æ®å é¤åæ æ³æ¢å¤ï¼è¯·ç¡®è®¤è¦å é¤ä¹ï¼</Property> </AjaxAction> <AjaxAction id="ajaxDelUpdate"> <Property name="service">gDApi2001PR#delUpdate</Property> <Property name="confirmMessage">ç¡®å®è¦å°æ°æ®æ 记为å é¤ä¹ï¼</Property> </AjaxAction> </View> </ViewConfig> src/main/java/com/fzzy/otherview/gd2022/GdApi2002.view.xml
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,400 @@ <?xml version="1.0" encoding="UTF-8"?> <ViewConfig> <Arguments/> <Context/> <Model> <DataType name="dtMain"> <Property name="creationType">com.fzzy.push.gd2022.dto.Gd2022Api2002</Property> <PropertyDef name="cqqrdh"> <Property></Property> <Property name="label">åºæ¸ 确认åå·</Property> </PropertyDef> <PropertyDef name="cfdm"> <Property></Property> <Property name="label">仿¿ä»£ç </Property> </PropertyDef> <PropertyDef name="tycfbm"> <Property></Property> <Property name="label">ç»ä¸ä»æ¿ç¼ç </Property> </PropertyDef> <PropertyDef name="ajdm"> <Property></Property> <Property name="label">å»é´ä»£ç </Property> </PropertyDef> <PropertyDef name="tyajbm"> <Property></Property> <Property name="label">ç»ä¸å»é´ç¼ç </Property> </PropertyDef> <PropertyDef name="cqrq"> <Property name="dataType">Date</Property> <Property name="label">åºæ¸ æ¥æ</Property> </PropertyDef> <PropertyDef name="srq"> <Property></Property> <Property name="label">ç³è¯·äºº</Property> </PropertyDef> <PropertyDef name="bmshr"> <Property></Property> <Property name="label">é¨é¨å®¡æ ¸äºº</Property> </PropertyDef> <PropertyDef name="ldshr"> <Property></Property> <Property name="label">é¢å¯¼å®¡æ ¸äºº</Property> </PropertyDef> <PropertyDef name="bz"> <Property></Property> <Property name="label">夿³¨</Property> </PropertyDef> <PropertyDef name="czbz"> <Property name="label">æä½æ å¿</Property> <Property name="mapping"> <Property name="mapValues">${dorado.getDataProvider("apiTriggerService#trigger").getResult("CZBZ")}</Property> <Property name="keyProperty">code</Property> <Property name="valueProperty">name</Property> </Property> </PropertyDef> <PropertyDef name="zhgxsj"> <Property name="dataType">DateTime</Property> <Property name="label">æåæ´æ°æ¶é´</Property> </PropertyDef> </DataType> <DataType name="dtParam"> <Property name="creationType">com.fzzy.api.data.ApiParam</Property> <PropertyDef name="kqdm"> <Property></Property> <Property name="label">æå±åºåº</Property> </PropertyDef> <PropertyDef name="start"> <Property name="dataType">Date</Property> <Property name="label">å¼å§æ¶é´</Property> </PropertyDef> <PropertyDef name="end"> <Property name="dataType">Date</Property> <Property name="label">æªæ¢æ¶é´</Property> </PropertyDef> <PropertyDef name="czbz"> <Property></Property> <Property name="label">æä½æ å¿</Property> <Property name="mapping"> <Property name="mapValues">${dorado.getDataProvider("apiTriggerService#trigger").getResult("CZBZ")}</Property> <Property name="keyProperty">code</Property> <Property name="valueProperty">name</Property> </Property> </PropertyDef> </DataType> </Model> <View layout="regionPadding:10"> <Property name="packages">font-awesome,css-common</Property> <DataSet id="dsMain"> <Property name="dataType">[dtMain]</Property> <Property name="dataProvider">gDApi2002PR#listData</Property> <Property name="pageSize">15</Property> </DataSet> <DataSet id="dsQuery"> <ClientEvent name="onReady">self.insert();</ClientEvent> <Property name="dataType">dtParam</Property> </DataSet> <ToolBar> <ToolBarLabel> <Property name="text">å·¥å ·æ ï¼</Property> <Property name="style"> <Property name="font-weight">bold</Property> </Property> </ToolBarLabel> <ToolBarButton> <ClientEvent name="onClick">var query = view.get("#dsQuery").getData();
 view.get("#dsMain").set("parameter",query).flushAsync();</ClientEvent> <Property name="caption">æ¥è¯¢</Property> <Property name="iconClass">fa fa-search</Property> <Property name="width">100</Property> <Property name="exClassName">toolbar-button-push</Property> </ToolBarButton> <ToolBarButton id="btnAdd"> <ClientEvent name="onClick">view.get("#dsMain").insert();
 view.get("#dialogMain").show();</ClientEvent> <Property name="caption">æ°å¢</Property> <Property name="iconClass">fa fa-plus</Property> <Property name="width">100</Property> <Property name="exClassName">toolbar-button</Property> <Property name="hideMode">display</Property> </ToolBarButton> <ToolBarButton id="btnUpdate"> <ClientEvent name="onClick">var cur = view.get("#dgMain").getCurrentItem();
 if(cur){
 view.get("#dialogMain").show();
 }</ClientEvent> <Property name="caption">ä¿®æ¹</Property> <Property name="iconClass">fa fa-pencil</Property> <Property name="width">100</Property> <Property name="exClassName">toolbar-button-warm</Property> <Property name="hideMode">display</Property> </ToolBarButton> <ToolBarButton> <ClientEvent name="onClick">var cur = view.get("#dgMain").getCurrentItem();
 view.get("#ajaxDelUpdate").set("parameter",cur).execute(function(result){
 if(result){
 $alert(result);
 } else{
 cur.set("czbz","d")
 }
 });
 </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> <ToolBarButton id="btnDel"> <ClientEvent name="onClick">var cur = view.get("#dgMain").getCurrentItem();
 view.get("#ajaxDel").set("parameter",cur).execute(function(result){
 if(result){
 $alert(result);
 } else{
 cur.remove();
 }
 });
 </ClientEvent> <Property name="caption">ç´æ¥å é¤</Property> <Property name="iconClass">fa fa-minus</Property> <Property name="exClassName">toolbar-button-warn</Property> <Property name="width">100</Property> <Property name="hideMode">display</Property> </ToolBarButton> <ToolBarButton> <ClientEvent name="onClick">var select = view.get("#dgMain").get("selection");
 if(select && select.length > 0){
 view.get("#ajaxPush").set("parameter",select).execute(function(result){
 view.get("#dsMain").flushAsync();
 $notify(result);
 });
 }else{
 $alert("请å¾é䏿¥æ°æ®ï¼");
 }
 </ClientEvent> <Property name="caption">æå¨ä¸ä¼ </Property> <Property name="iconClass">fa fa-hand-o-up</Property> <Property name="exClassName">toolbar-button-push</Property> <Property name="width">100</Property> </ToolBarButton> <Fill/> <ToolBarButton> <Property name="caption">ä¸ä¼ è®°å½</Property> <Property name="iconClass">fa fa-bars</Property> <Property name="exClassName">toolbar-button</Property> <Property name="width">100</Property> </ToolBarButton> </ToolBar> <AutoForm> <Property name="dataSet">dsQuery</Property> <Property name="cols">*,*,*,*</Property> <Property name="labelAlign">right</Property> <Property name="labelSeparator">ï¼</Property> <Property name="labelWidth">90</Property> <AutoFormElement> <Property name="name">kqdm</Property> <Property name="property">kqdm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">start</Property> <Property name="property">start</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">end</Property> <Property name="property">end</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">czbz</Property> <Property name="property">czbz</Property> <Property name="trigger">autoMappingDropDown2</Property> <Editor/> </AutoFormElement> </AutoForm> <DataGrid id="dgMain"> <ClientEvent name="onDataRowDoubleClick">view.get("#dialogMain").show();</ClientEvent> <Property name="dataSet">dsMain</Property> <Property name="selectionMode">multiRows</Property> <Property name="readOnly">true</Property> <RowNumColumn/> <RowSelectorColumn> <Property name="caption">ä¸ä¼ </Property> </RowSelectorColumn> <DataColumn name="cqqrdh"> <Property name="property">cqqrdh</Property> <Property name="width">180</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="cfdm"> <Property name="property">cfdm</Property> <Property name="width">210</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="ajdm"> <Property name="property">ajdm</Property> <Property name="width">230</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="cqrq"> <Property name="property">cqrq</Property> <Property name="width">150</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="srq"> <Property name="property">srq</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="bmshr"> <Property name="property">bmshr</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="ldshr"> <Property name="property">ldshr</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="bz"> <Property name="property">bz</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="czbz"> <Property name="property">czbz</Property> <Property name="width">70</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="zhgxsj"> <Property name="property">zhgxsj</Property> <Property name="width">160</Property> <Property name="align">center</Property> </DataColumn> </DataGrid> <ToolBar layoutConstraint="bottom"> <Fill/> <DataPilot> <Property name="itemCodes">pageSize,pages</Property> <Property name="dataSet">dsMain</Property> </DataPilot> </ToolBar> <Dialog id="dialogMain" layout="regionPadding:5"> <Property name="width">80%</Property> <Property name="caption">åºæ¸ 确认åä¿¡æ¯</Property> <Property name="iconClass">fa fa-sliders</Property> <Property name="closeable">false</Property> <Buttons> <Button> <ClientEvent name="onClick">var cur = view.get("#dgMain").getCurrentItem();
 view.get("#updateSave").execute(function(){
 self.get("parent").hide();
 });</ClientEvent> <Property name="caption">ä¿åä¿®æ¹</Property> <Property name="iconClass">fa fa-check</Property> <Property name="exClassName">toolbar-button</Property> </Button> <Button> <ClientEvent name="onClick">var cur = view.get("#dgMain").getCurrentItem();
 self.get("parent").hide();
 if(cur) cur.cancel();</ClientEvent> <Property name="caption">åæ¶ä¿®æ¹</Property> <Property name="iconClass">fa fa-times</Property> <Property name="exClassName">toolbar-button-warn</Property> </Button> </Buttons> <Children> <FieldSet layout="regionPadding:5"> <Property name="caption">åºæ¬ä¿¡æ¯</Property> <Buttons/> <Children> <AutoForm> <Property name="dataSet">dsMain</Property> <Property name="cols">*,*,*</Property> <Property name="labelWidth">160</Property> <Property name="labelAlign">left</Property> <Property name="labelSeparator">ï¼</Property> <Property name="labelPosition">left</Property> <AutoFormElement> <Property name="name">cqqrdh</Property> <Property name="property">cqqrdh</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">cfdm</Property> <Property name="property">cfdm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">tycfbm</Property> <Property name="property">tycfbm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">ajdm</Property> <Property name="property">ajdm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">tyajbm</Property> <Property name="property">tyajbm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">cqrq</Property> <Property name="property">cqrq</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">srq</Property> <Property name="property">srq</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">bmshr</Property> <Property name="property">bmshr</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">ldshr</Property> <Property name="property">ldshr</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">bz</Property> <Property name="property">bz</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">czbz</Property> <Property name="property">czbz</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">zhgxsj</Property> <Property name="property">zhgxsj</Property> <Editor/> </AutoFormElement> </AutoForm> </Children> </FieldSet> </Children> <Tools/> </Dialog> <UpdateAction id="updateSave"> <Property name="dataResolver">gDApi2002PR#saveData</Property> <UpdateItem> <Property name="dataPath">[#current]</Property> <Property name="dataSet">dsMain</Property> </UpdateItem> </UpdateAction> <AjaxAction id="ajaxPush"> <Property name="service">gDApi2002PR#pushData</Property> <Property name="confirmMessage">ç¡®å®è¦ä¸æ¥ä¹ï¼</Property> </AjaxAction> <AjaxAction id="ajaxDel"> <Property name="service">gDApi2002PR#delData</Property> <Property name="confirmMessage">å½åæ°æ®å é¤åæ æ³æ¢å¤ï¼è¯·ç¡®è®¤è¦å é¤ä¹ï¼</Property> </AjaxAction> <AjaxAction id="ajaxDelUpdate"> <Property name="service">gDApi2002PR#delUpdate</Property> <Property name="confirmMessage">ç¡®å®è¦å°æ°æ®æ 记为å é¤ä¹ï¼</Property> </AjaxAction> </View> </ViewConfig> src/main/java/com/fzzy/otherview/gd2022/pr/GDApi1023PR.java
@@ -16,15 +16,9 @@ import com.fzzy.api.service.ApiRemoteService; import com.fzzy.api.utils.ContextUtil; import com.fzzy.api.view.repository.ApiInfoDataRep; import com.fzzy.otherview.gd2022.dto.GdApi1023; import com.fzzy.otherview.gd2022.dto.GdApi1023Dtl; import com.fzzy.otherview.gd2022.dto.GdApi1023People; import com.fzzy.otherview.gd2022.dto.GdApi1023Way; import com.fzzy.push.gd2022.dto.Gd2022Api1023; import com.fzzy.push.gd2022.ApiCodeConstant; import com.fzzy.push.sh2023.SH2023Constant; import com.fzzy.push.sh2023.dto.SH2023Api2103; import org.apache.commons.lang.StringUtils; import org.apache.commons.lang.time.DateFormatUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.domain.PageRequest; import org.springframework.data.domain.Pageable; @@ -61,7 +55,7 @@ * @return */ @DataProvider public void listData(Page<GdApi1023> page, ApiParam param) { public void listData(Page<Gd2022Api1023> page, ApiParam param) { Pageable pageable = PageRequest.of(page.getPageNo() - 1, page.getPageSize(), Sort.Direction.DESC, "updateTime"); @@ -98,11 +92,11 @@ }; org.springframework.data.domain.Page<ApiInfoData> japPage = apiInfoDataRep.findAll(specification, pageable); page.setEntityCount((int) japPage.getTotalElements()); List<GdApi1023> list = new ArrayList<>(); GdApi1023 gdApi1023; List<Gd2022Api1023> list = new ArrayList<>(); Gd2022Api1023 GD2022Api1023; for (ApiInfoData infoData : japPage.getContent()) { gdApi1023 = JSONObject.parseObject(infoData.getData(), GdApi1023.class); list.add(gdApi1023); GD2022Api1023 = JSONObject.parseObject(infoData.getData(), Gd2022Api1023.class); list.add(GD2022Api1023); } page.setEntities(list); @@ -112,7 +106,7 @@ * gDApi1023PR#saveData */ @DataResolver public void saveData(GdApi1023 data) { public void saveData(Gd2022Api1023 data) { ApiInfoData infoData; List<ApiInfoData> apiInfoList = apiInfoDataRep.getDataByInteAndData(ApiCodeConstant.API_1023, data.getXzbm(), data.getKqdm()); if (apiInfoList.size() != 0) { @@ -136,7 +130,7 @@ * gDApi1023PR#delData */ @Expose public void delData(GdApi1023 data) { public void delData(Gd2022Api1023 data) { List<ApiInfoData> apiInfoList = apiInfoDataRep.getDataByInteAndData(ApiCodeConstant.API_1023, data.getXzbm(), data.getKqdm()); apiInfoDataRep.deleteById(apiInfoList.get(0).getId()); } @@ -145,7 +139,7 @@ * gDApi1023PR#delUpdate */ @Expose public String delUpdate(GdApi1023 data) { public String delUpdate(Gd2022Api1023 data) { if (null == data) { return "æ æ°æ®æ§è¡"; } @@ -162,7 +156,7 @@ * @return */ @Expose public String pushData(List<GdApi1023> items) { public String pushData(List<Gd2022Api1023> items) { ResponseDto responseDto; String result = ""; @@ -183,18 +177,20 @@ } ApiInfoData infoData; for (GdApi1023 data : items) { for (Gd2022Api1023 data : items) { //æ¨éï¼æ°æ®ä¸ºéåå½¢å¼ responseDto = apiService.pushData(param, apiConf, data); if (responseDto.getSuccess() == 0) { //æ¨éæåï¼æ´æ°æ°æ®ä¸ä¼ ç¶æ List<ApiInfoData> apiInfoList = apiInfoDataRep.getDataByInteAndData(ApiCodeConstant.API_1023, data.getXzbm(), data.getKqdm()); data.setCzbz(Constant.CZBZ_U); infoData = apiInfoList.get(0); infoData.setUpdateTime(new Date()); infoData.setCzbz(Constant.CZBZ_U); infoData.setData(JSON.toJSONString(data)); apiInfoDataRep.save(infoData); if (Constant.CZBZ_I.equals(data.getCzbz())) { //æ¨éæåï¼æ´æ°æ°æ®ä¸ä¼ ç¶æ List<ApiInfoData> apiInfoList = apiInfoDataRep.getDataByInteAndData(ApiCodeConstant.API_1023, data.getXzbm(), data.getKqdm()); data.setCzbz(Constant.CZBZ_U); infoData = apiInfoList.get(0); infoData.setUpdateTime(new Date()); infoData.setCzbz(Constant.CZBZ_U); infoData.setData(JSON.toJSONString(data)); apiInfoDataRep.save(infoData); } } result += responseDto.toString(); } src/main/java/com/fzzy/otherview/gd2022/pr/GDApi2001PR.java
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,192 @@ package com.fzzy.otherview.gd2022.pr; import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONObject; import com.bstek.dorado.annotation.DataProvider; import com.bstek.dorado.annotation.DataResolver; import com.bstek.dorado.annotation.Expose; import com.bstek.dorado.data.provider.Page; import com.fzzy.api.Constant; import com.fzzy.api.data.ApiParam; import com.fzzy.api.dto.ResponseDto; import com.fzzy.api.entity.ApiConfs; import com.fzzy.api.entity.ApiInfoData; import com.fzzy.api.service.ApiCommonService; import com.fzzy.api.service.ApiPushManager; import com.fzzy.api.service.ApiRemoteService; import com.fzzy.api.utils.ContextUtil; import com.fzzy.api.view.repository.ApiInfoDataRep; import com.fzzy.push.gd2022.ApiCodeConstant; import com.fzzy.push.gd2022.dto.Gd2022Api2001; import org.apache.commons.lang.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.domain.PageRequest; import org.springframework.data.domain.Pageable; import org.springframework.data.domain.Sort; import org.springframework.data.jpa.domain.Specification; import org.springframework.stereotype.Component; import javax.persistence.criteria.CriteriaBuilder; import javax.persistence.criteria.CriteriaQuery; import javax.persistence.criteria.Predicate; import javax.persistence.criteria.Root; import java.util.ArrayList; import java.util.Date; import java.util.List; /** * @Description å°ä»ç¡®è®¤é¡µé¢ç®¡ç * @Author CZT * @Date 2024/6/29 14:57 */ @Component(value = "gDApi2001PR") public class GDApi2001PR { @Autowired private ApiInfoDataRep apiInfoDataRep; @Autowired private ApiCommonService apiCommonService; @Autowired private ApiPushManager apiPushManager; /** * è·åä¿¡æ¯ * gDApi2001PR#listData * * @return */ @DataProvider public void listData(Page<Gd2022Api2001> page, ApiParam param) { Pageable pageable = PageRequest.of(page.getPageNo() - 1, page.getPageSize(), Sort.Direction.DESC, "updateTime"); Specification specification = new Specification<ApiInfoData>() { private static final long serialVersionUID = 1L; @Override public Predicate toPredicate(Root<ApiInfoData> root, CriteriaQuery<?> criteriaQuery, CriteriaBuilder criteriaBuilder) { List<Predicate> predicates = new ArrayList<>(); //ææçæè¨ Predicate predicate = criteriaBuilder.equal(root.get("inteId"), ApiCodeConstant.API_2001); predicates.add(predicate); if (null != param) { if (StringUtils.isNotBlank(param.getKqdm())) { Predicate predicate1 = criteriaBuilder.equal(root.get("kqdm"), param.getKqdm()); predicates.add(predicate1); } if (StringUtils.isNotBlank(param.getCzbz())) { Predicate predicate2 = criteriaBuilder.equal(root.get("czbz"), param.getCzbz()); predicates.add(predicate2); } if (null != param.getStart()) { Predicate predicate3 = criteriaBuilder.greaterThan(root.get("updateTime"), ContextUtil.getCurZero(param.getStart())); predicates.add(predicate3); } if (null != param.getEnd()) { Predicate predicate4 = criteriaBuilder.lessThan(root.get("updateTime"), ContextUtil.getNextZero(param.getEnd())); predicates.add(predicate4); } } return criteriaBuilder.and(predicates.toArray(new Predicate[0])); } }; org.springframework.data.domain.Page<ApiInfoData> japPage = apiInfoDataRep.findAll(specification, pageable); page.setEntityCount((int) japPage.getTotalElements()); List<Gd2022Api2001> list = new ArrayList<>(); Gd2022Api2001 Gd2022Api2001; for (ApiInfoData infoData : japPage.getContent()) { Gd2022Api2001 = JSONObject.parseObject(infoData.getData(), Gd2022Api2001.class); list.add(Gd2022Api2001); } page.setEntities(list); } /** * gDApi2001PR#saveData */ @DataResolver public void saveData(Gd2022Api2001 data) { ApiInfoData infoData = new ApiInfoData(); infoData.setId(data.getFcqrdh()); infoData.setKqdm(data.getCfdm().substring(0, 21)); infoData.setInteId(ApiCodeConstant.API_2001); infoData.setUpdateTime(new Date()); infoData.setDataId(infoData.getId()); infoData.setData(JSON.toJSONString(data)); infoData.setCzbz(data.getCzbz()); infoData.setRemarks("夿³¨ä¿¡æ¯"); apiInfoDataRep.save(infoData); } /** * gDApi2001PR#delData */ @Expose public void delData(Gd2022Api2001 data) { apiInfoDataRep.deleteById(data.getFcqrdh()); } /** * gDApi2001PR#delUpdate */ @Expose public String delUpdate(Gd2022Api2001 entity) { if (null == entity) { return "æ æ°æ®æ§è¡"; } apiInfoDataRep.updateStatus(entity.getFcqrdh(), JSON.toJSONString(entity), Constant.CZBZ_D); return null; } @Expose public String pushData(List<Gd2022Api2001> items) { String result = ""; String kqdm = items.get(0).getCfdm().substring(0, 21); ApiConfs apiConf = apiCommonService.getConf(kqdm); if (null == apiConf) { return "ç³»ç»æ²¡æè·åå°å½ååºåºé 置信æ¯ï¼æ§è¡å¤±è´¥"; } //å°è£ åæ° ApiParam param = new ApiParam(apiConf, "21", ApiCodeConstant.API_2001); //è·åå®ç°æ¥å£ ApiRemoteService apiService = apiPushManager.getApiRemoteService(param.getPushProtocol()); if (null == apiService) { return "ç³»ç»æ²¡æå½åæ¨éåè®®é ç½®ï¼æ§è¡å¤±è´¥"; } ResponseDto responseDto; ApiInfoData infoData; for (Gd2022Api2001 data : items) { responseDto = apiService.pushData(param, apiConf, data); if (responseDto.getSuccess() == 0) { if (Constant.CZBZ_I.equals(data.getCzbz())) { infoData = new ApiInfoData(); infoData.setId(data.getFcqrdh()); infoData.setKqdm(data.getCfdm().substring(0, 21)); infoData.setInteType("21"); infoData.setInteId(ApiCodeConstant.API_2001); infoData.setUpdateTime(new Date()); infoData.setDataId(infoData.getId()); infoData.setCzbz(Constant.CZBZ_U); data.setCzbz(Constant.CZBZ_U); infoData.setData(JSON.toJSONString(data)); apiInfoDataRep.save(infoData); } } result += responseDto.toString(); } return result; } } src/main/java/com/fzzy/otherview/gd2022/pr/GDApi2002PR.java
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,193 @@ package com.fzzy.otherview.gd2022.pr; import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONObject; import com.bstek.dorado.annotation.DataProvider; import com.bstek.dorado.annotation.DataResolver; import com.bstek.dorado.annotation.Expose; import com.bstek.dorado.data.provider.Page; import com.fzzy.api.Constant; import com.fzzy.api.data.ApiParam; import com.fzzy.api.dto.ResponseDto; import com.fzzy.api.entity.ApiConfs; import com.fzzy.api.entity.ApiInfoData; import com.fzzy.api.service.ApiCommonService; import com.fzzy.api.service.ApiPushManager; import com.fzzy.api.service.ApiRemoteService; import com.fzzy.api.utils.ContextUtil; import com.fzzy.api.view.repository.ApiInfoDataRep; import com.fzzy.push.gd2022.ApiCodeConstant; import com.fzzy.push.gd2022.dto.Gd2022Api2002; import org.apache.commons.lang.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.domain.PageRequest; import org.springframework.data.domain.Pageable; import org.springframework.data.domain.Sort; import org.springframework.data.jpa.domain.Specification; import org.springframework.stereotype.Component; import javax.persistence.criteria.CriteriaBuilder; import javax.persistence.criteria.CriteriaQuery; import javax.persistence.criteria.Predicate; import javax.persistence.criteria.Root; import java.util.ArrayList; import java.util.Date; import java.util.List; /** * @Description åºæ¸ 确认页é¢ç®¡ç * @Author CZT * @Date 2024/6/29 15:25 */ @Component(value = "gDApi2002PR") public class GDApi2002PR { @Autowired private ApiInfoDataRep apiInfoDataRep; @Autowired private ApiCommonService apiCommonService; @Autowired private ApiPushManager apiPushManager; /** * è·åä¿¡æ¯ * gDApi2002PR#listData * * @return */ @DataProvider public void listData(Page<Gd2022Api2002> page, ApiParam param) { Pageable pageable = PageRequest.of(page.getPageNo() - 1, page.getPageSize(), Sort.Direction.DESC, "updateTime"); Specification specification = new Specification<ApiInfoData>() { private static final long serialVersionUID = 1L; @Override public Predicate toPredicate(Root<ApiInfoData> root, CriteriaQuery<?> criteriaQuery, CriteriaBuilder criteriaBuilder) { List<Predicate> predicates = new ArrayList<>(); //ææçæè¨ Predicate predicate = criteriaBuilder.equal(root.get("inteId"), ApiCodeConstant.API_2002); predicates.add(predicate); if (null != param) { if (StringUtils.isNotBlank(param.getKqdm())) { Predicate predicate1 = criteriaBuilder.equal(root.get("kqdm"), param.getKqdm()); predicates.add(predicate1); } if (StringUtils.isNotBlank(param.getCzbz())) { Predicate predicate2 = criteriaBuilder.equal(root.get("czbz"), param.getCzbz()); predicates.add(predicate2); } if (null != param.getStart()) { Predicate predicate3 = criteriaBuilder.greaterThan(root.get("updateTime"), ContextUtil.getCurZero(param.getStart())); predicates.add(predicate3); } if (null != param.getEnd()) { Predicate predicate4 = criteriaBuilder.lessThan(root.get("updateTime"), ContextUtil.getNextZero(param.getEnd())); predicates.add(predicate4); } } return criteriaBuilder.and(predicates.toArray(new Predicate[0])); } }; org.springframework.data.domain.Page<ApiInfoData> japPage = apiInfoDataRep.findAll(specification, pageable); page.setEntityCount((int) japPage.getTotalElements()); List<Gd2022Api2002> list = new ArrayList<>(); Gd2022Api2002 Gd2022Api2002; for (ApiInfoData infoData : japPage.getContent()) { Gd2022Api2002 = JSONObject.parseObject(infoData.getData(), Gd2022Api2002.class); list.add(Gd2022Api2002); } page.setEntities(list); } /** * gDApi2002PR#saveData */ @DataResolver public void saveData(Gd2022Api2002 data) { ApiInfoData infoData = new ApiInfoData(); infoData.setId(data.getCqqrdh()); infoData.setKqdm(data.getCfdm().substring(0, 21)); infoData.setInteId(ApiCodeConstant.API_2002); infoData.setUpdateTime(new Date()); infoData.setDataId(infoData.getId()); infoData.setData(JSON.toJSONString(data)); infoData.setCzbz(data.getCzbz()); infoData.setRemarks("夿³¨ä¿¡æ¯"); apiInfoDataRep.save(infoData); } /** * gDApi2002PR#delData */ @Expose public void delData(Gd2022Api2002 data) { apiInfoDataRep.deleteById(data.getCqqrdh()); } /** * gDApi2002PR#delUpdate */ @Expose public String delUpdate(Gd2022Api2002 entity) { if (null == entity) { return "æ æ°æ®æ§è¡"; } apiInfoDataRep.updateStatus(entity.getCqqrdh(), JSON.toJSONString(entity), Constant.CZBZ_D); return null; } @Expose public String pushData(List<Gd2022Api2002> items) { String result = ""; String kqdm = items.get(0).getCfdm().substring(0, 21); ApiConfs apiConf = apiCommonService.getConf(kqdm); if (null == apiConf) { return "ç³»ç»æ²¡æè·åå°å½ååºåºé 置信æ¯ï¼æ§è¡å¤±è´¥"; } //å°è£ åæ° ApiParam param = new ApiParam(apiConf, "21", ApiCodeConstant.API_2002); //è·åå®ç°æ¥å£ ApiRemoteService apiService = apiPushManager.getApiRemoteService(param.getPushProtocol()); if (null == apiService) { return "ç³»ç»æ²¡æå½åæ¨éåè®®é ç½®ï¼æ§è¡å¤±è´¥"; } ResponseDto responseDto; ApiInfoData infoData; for (Gd2022Api2002 data : items) { responseDto = apiService.pushData(param, apiConf, data); if (responseDto.getSuccess() == 0) { if (Constant.CZBZ_I.equals(data.getCzbz())) { infoData = new ApiInfoData(); infoData.setId(data.getCqqrdh()); infoData.setKqdm(data.getCfdm().substring(0, 21)); infoData.setInteType("21"); infoData.setInteId(ApiCodeConstant.API_2002); infoData.setUpdateTime(new Date()); infoData.setDataId(infoData.getId()); infoData.setCzbz(Constant.CZBZ_U); data.setCzbz(Constant.CZBZ_U); infoData.setData(JSON.toJSONString(data)); apiInfoDataRep.save(infoData); } } result += responseDto.toString(); } return result; } } src/main/java/com/fzzy/otherview/sh2023/pr/SHApi2101PR.java
@@ -9,7 +9,6 @@ import com.fzzy.api.Constant; import com.fzzy.api.data.ApiParam; import com.fzzy.api.dto.ResponseDto; import com.fzzy.api.entity.Api1204; import com.fzzy.api.entity.ApiConfs; import com.fzzy.api.entity.ApiInfoData; import com.fzzy.api.service.ApiCommonService; @@ -17,15 +16,10 @@ import com.fzzy.api.service.ApiRemoteService; import com.fzzy.api.utils.ContextUtil; import com.fzzy.api.view.repository.ApiInfoDataRep; import com.fzzy.otherview.gd2022.dto.GdApi1023; import com.fzzy.otherview.whhpjl.WhjlConstant; import com.fzzy.otherview.whhpjl.dto.WhjlApi1101; import com.fzzy.push.gd2022.ApiCodeConstant; import com.fzzy.push.sh2023.SH2023Constant; import com.fzzy.push.sh2023.dto.SH2023Api2101; import org.apache.commons.lang.StringUtils; import org.apache.commons.lang.time.DateFormatUtils; import org.springframework.beans.BeanUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.domain.PageRequest; import org.springframework.data.domain.Pageable; @@ -40,7 +34,6 @@ import java.util.ArrayList; import java.util.Date; import java.util.List; import java.util.Map; /** * 䏿µ·å¸æ¥å£-2101 æ£æ¤å src/main/java/com/fzzy/otherview/whhpjl/pr/WhjlApi1206PR.java
@@ -16,13 +16,9 @@ import com.fzzy.api.service.ApiRemoteService; import com.fzzy.api.utils.ContextUtil; import com.fzzy.api.view.repository.ApiInfoDataRep; import com.fzzy.otherview.gd2022.dto.GdApi1023; import com.fzzy.otherview.gd2022.dto.GdApi1023Way; import com.fzzy.otherview.whhpjl.WhjlConstant; import com.fzzy.otherview.whhpjl.dto.WhjlApi1206; import com.fzzy.otherview.whhpjl.dto.WhjlApi1206; import com.fzzy.otherview.whhpjl.dto.WhjlQDItem; import com.fzzy.push.gd2022.ApiCodeConstant; import org.apache.commons.lang.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.domain.PageRequest; src/main/java/com/fzzy/push/gd2022/ApiCodeConstant.java
@@ -7,6 +7,8 @@ public static String API_1023 = "1023"; public static String API_2001 = "2001"; public static String API_2002 = "2002"; /** * æ¥å£ç¼ç -1001 èº«ä»½è®¤è¯æ¥å£ */ src/main/java/com/fzzy/push/gd2022/GD2022ApiRemoteService2022.java
@@ -789,6 +789,36 @@ apiData.setZhgxsj(DateUtils.addSeconds(new Date(), -10)); return JSON.toJSONString(apiData); } if (ApiCodeConstant.API_2001.equals(inteId)) { Gd2022Api2001 apiData = (Gd2022Api2001) data; //æ ¡éªç»ä¸ç¼ç æ¯å¦ä¸ºç©ºï¼ä¸ºç©ºåæ¥è¯¢ä¿¡æ¯è¿è¡èµå¼ if(StringUtils.isEmpty(apiData.getTycfbm())){ String tycfbm = apiCommonService.getTycfbm(apiData.getCfdm()); apiData.setTycfbm(tycfbm); } //æ ¡éªç»ä¸ç¼ç æ¯å¦ä¸ºç©ºï¼ä¸ºç©ºåæ¥è¯¢ä¿¡æ¯è¿è¡èµå¼ if(StringUtils.isEmpty(apiData.getTyajbm())){ String tyajbm = apiCommonService.getTyajbm(apiData.getAjdm()); apiData.setTyajbm(tyajbm); } apiData.setZhgxsj(DateUtils.addSeconds(new Date(), -10)); return JSON.toJSONString(apiData); } if (ApiCodeConstant.API_2002.equals(inteId)) { Gd2022Api2002 apiData = (Gd2022Api2002) data; //æ ¡éªç»ä¸ç¼ç æ¯å¦ä¸ºç©ºï¼ä¸ºç©ºåæ¥è¯¢ä¿¡æ¯è¿è¡èµå¼ if(StringUtils.isEmpty(apiData.getTycfbm())){ String tycfbm = apiCommonService.getTycfbm(apiData.getCfdm()); apiData.setTycfbm(tycfbm); } //æ ¡éªç»ä¸ç¼ç æ¯å¦ä¸ºç©ºï¼ä¸ºç©ºåæ¥è¯¢ä¿¡æ¯è¿è¡èµå¼ if(StringUtils.isEmpty(apiData.getTyajbm())){ String tyajbm = apiCommonService.getTyajbm(apiData.getAjdm()); apiData.setTyajbm(tyajbm); } apiData.setZhgxsj(DateUtils.addSeconds(new Date(), -10)); return JSON.toJSONString(apiData); } return JSON.toJSONString(data); } src/main/java/com/fzzy/push/gd2022/GD2022PushService12.java
@@ -4,6 +4,7 @@ import com.fzzy.api.data.PushProtocol; import com.fzzy.api.service.PushService12; import com.fzzy.push.impl.ComPushService12; import com.fzzy.push.impl.ComPushService99; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; @@ -21,7 +22,9 @@ private GD2022ApiRemoteService2022 apiRemoteService; @Autowired private ComPushService12 pushService; private ComPushService12 pushService12; @Autowired private ComPushService99 pushService99; @Override public String getProtocol() { @@ -33,43 +36,48 @@ log.info("------->>>>ç²®é£è´é æ¥å£æ¨¡å䏿¥å¼å§"); //客æ·ä¿¡æ¯ pushService.pushData1212(apiRemoteService, param); pushService12.pushData1212(apiRemoteService, param); //åå pushService.pushData1201(apiRemoteService, param); pushService12.pushData1201(apiRemoteService, param); //å ¥åºæ°æ® + å ¥åºè¿ç£ pushService.pushData1202(apiRemoteService, param); pushService12.pushData1202(apiRemoteService, param); //å ¥åºè´¨æ£ pushService.pushData1203(apiRemoteService, param); pushService12.pushData1203(apiRemoteService, param); //å ¥åºç»ç® pushService.pushData1204(apiRemoteService, param); pushService12.pushData1204(apiRemoteService, param); //åºåºæ°æ® + åºåºè¿ç£ pushService.pushData1205(apiRemoteService, param); pushService12.pushData1205(apiRemoteService, param); //åºåºç»ç® pushService.pushData1206(apiRemoteService, param); pushService12.pushData1206(apiRemoteService, param); //åä» pushService.pushData1207(apiRemoteService, param); pushService12.pushData1207(apiRemoteService, param); //ææº¢å pushService.pushData1209(apiRemoteService, param); pushService12.pushData1209(apiRemoteService, param); //ç²®é£åºåæ°æ® pushService.pushData1208(apiRemoteService, param); pushService12.pushData1208(apiRemoteService, param); //æ§è´¨è½¬å pushService.pushData1210(apiRemoteService, param); pushService12.pushData1210(apiRemoteService, param); //è´¦é¢åºå pushService.pushData1211(apiRemoteService, param); pushService12.pushData1211(apiRemoteService, param); //æä»¶ pushService.pushData1109(apiRemoteService, param); pushService12.pushData1109(apiRemoteService, param); //å°ä»ç¡®è®¤å pushService99.pushData2001(apiRemoteService, param); //åºæ¸ 确认å pushService99.pushData2002(apiRemoteService, param); log.info("------->>>>ç²®é£è´é æ¥å£æ¨¡å䏿¥ç»æ"); } src/main/java/com/fzzy/push/gd2022/GD2022PushService13.java
@@ -4,6 +4,7 @@ import com.fzzy.api.data.PushProtocol; import com.fzzy.api.service.PushService13; import com.fzzy.push.impl.ComPushService13; import com.fzzy.push.impl.ComPushService99; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; @@ -21,8 +22,9 @@ private GD2022ApiRemoteService2022 apiRemoteService; @Autowired private ComPushService13 pushService; private ComPushService13 pushService13; @Autowired private ComPushService99 pushService99; @Override public String getProtocol() { @@ -31,30 +33,28 @@ @Override public void pushData(ApiParam param) { pushService.pushData1301(apiRemoteService, param); pushService13.pushData1301(apiRemoteService, param); //ç²®æ pushService.pushData1302(apiRemoteService, param); pushService13.pushData1302(apiRemoteService, param); //æ°ä½ pushService.pushData1304(apiRemoteService, param); pushService13.pushData1304(apiRemoteService, param); //è«å®³ pushService.pushData1303(apiRemoteService, param); pushService13.pushData1303(apiRemoteService, param); //éé£ pushService.pushData1305(apiRemoteService, param); pushService13.pushData1305(apiRemoteService, param); //çè¸ pushService.pushData1306(apiRemoteService, param); //çè¸ pushService.pushData1307(apiRemoteService, param); pushService13.pushData1306(apiRemoteService, param); pushService.pushData1308(apiRemoteService, param); pushService13.pushData1307(apiRemoteService, param); pushService.pushData1309(apiRemoteService, param); pushService13.pushData1308(apiRemoteService, param); //è´¨æ£ pushService.pushData1310(apiRemoteService, param); pushService13.pushData1309(apiRemoteService, param); pushService13.pushData1310(apiRemoteService, param); //çè¸å¤æ¡ pushService99.pushData1023(apiRemoteService, param); } } src/main/java/com/fzzy/push/gd2022/dto/Gd2022Api1023.java
ÎļþÃû´Ó src/main/java/com/fzzy/otherview/gd2022/dto/GdApi1023.java ÐÞ¸Ä @@ -1,4 +1,4 @@ package com.fzzy.otherview.gd2022.dto; package com.fzzy.push.gd2022.dto; import com.alibaba.fastjson.annotation.JSONField; import lombok.Data; @@ -16,7 +16,7 @@ */ @Data @EqualsAndHashCode(callSuper = false) public class GdApi1023 implements Serializable { public class Gd2022Api1023 implements Serializable { /** * */ @@ -69,9 +69,9 @@ private Date zhgxsj; //æåæ´æ°æ¶é´ private List<GdApi1023Dtl> dtls; //宿½çè¸ä½ä¸çå¨ç²®ç²®æ æç» private List<GdApi1023People> peoples; //çè¸ä½ä¸äººåä¿¡æ¯ private List<GdApi1023Way> ways; //çè¸å¤æ¡æ¹å¼ private List<Gd2022Api1023Dtl> dtls; //宿½çè¸ä½ä¸çå¨ç²®ç²®æ æç» private List<Gd2022Api1023People> peoples; //çè¸ä½ä¸äººåä¿¡æ¯ private List<Gd2022Api1023Way> ways; //çè¸å¤æ¡æ¹å¼ } src/main/java/com/fzzy/push/gd2022/dto/Gd2022Api1023Dtl.java
ÎļþÃû´Ó src/main/java/com/fzzy/otherview/gd2022/dto/GdApi1023Dtl.java ÐÞ¸Ä @@ -1,4 +1,4 @@ package com.fzzy.otherview.gd2022.dto; package com.fzzy.push.gd2022.dto; import com.alibaba.fastjson.annotation.JSONField; import lombok.Data; @@ -12,7 +12,7 @@ */ @Data @EqualsAndHashCode(callSuper = false) public class GdApi1023Dtl implements Serializable { public class Gd2022Api1023Dtl implements Serializable { private static final long serialVersionUID = 1L; src/main/java/com/fzzy/push/gd2022/dto/Gd2022Api1023People.java
ÎļþÃû´Ó src/main/java/com/fzzy/otherview/gd2022/dto/GdApi1023People.java ÐÞ¸Ä @@ -1,4 +1,4 @@ package com.fzzy.otherview.gd2022.dto; package com.fzzy.push.gd2022.dto; import lombok.Data; import lombok.EqualsAndHashCode; @@ -7,7 +7,7 @@ @Data @EqualsAndHashCode(callSuper = false) public class GdApi1023People implements Serializable { public class Gd2022Api1023People implements Serializable { private static final long serialVersionUID = 1L; src/main/java/com/fzzy/push/gd2022/dto/Gd2022Api1023Way.java
ÎļþÃû´Ó src/main/java/com/fzzy/otherview/gd2022/dto/GdApi1023Way.java ÐÞ¸Ä @@ -1,4 +1,4 @@ package com.fzzy.otherview.gd2022.dto; package com.fzzy.push.gd2022.dto; import lombok.Data; import lombok.EqualsAndHashCode; @@ -7,7 +7,7 @@ @Data @EqualsAndHashCode(callSuper = false) public class GdApi1023Way implements Serializable { public class Gd2022Api1023Way implements Serializable { private static final long serialVersionUID = 1L; src/main/java/com/fzzy/push/gd2022/dto/Gd2022Api2001.java
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,83 @@ package com.fzzy.push.gd2022.dto; import com.alibaba.fastjson.annotation.JSONField; import com.bstek.dorado.annotation.PropertyDef; import com.fasterxml.jackson.annotation.JsonProperty; import lombok.Data; import java.io.Serializable; import java.util.Date; /** * @Description å°ä»ç¡®è®¤å * @Author CZT * @Date 2024/6/29 14:36 */ @Data public class Gd2022Api2001 implements Serializable { private static final long serialVersionUID = 9157617424050247565L; @PropertyDef(label = "å°ä»ç¡®è®¤åå·", description = "2ä½ä¸å¡ç¼ç (21代表å°ä»)+yyyyMMdd+4ä½é¡ºåºç ï¼21202405040001") private String fcqrdh; @PropertyDef(label = "仿¿ä»£ç " ) private String cfdm; @PropertyDef(label = "ç»ä¸ä»æ¿ç¼ç ") private String tycfbm; @PropertyDef(label = "å»é´ä»£ç ") private String ajdm; @PropertyDef(label = "ç»ä¸å»é´ç¼ç ") private String tyajbm; @PropertyDef(label = "å°ä»æ¥æ") @JSONField(format = "yyyy-MM-dd") private Date fcrq; @PropertyDef(label = "ç²®é£åç§ä»£ç ") private String lspzdm; @PropertyDef(label = "ç²®é£æ§è´¨ä»£ç ") private String lsxzdm; @PropertyDef(label = "ç²®é£ç级代ç ") private String lsdjdm; @PropertyDef(label = "æ¶è·å¹´åº¦") private String shnd; @PropertyDef(label = "å½å«") private String gb; @PropertyDef(label = "产å°") private String cd; @PropertyDef(label = "ä¿ç®¡å") private String bgy; @PropertyDef(label = "å°ä»æ°é") @JsonProperty("Fcsl") private String Fcsl; @PropertyDef(label = "å°ä»ç³è¯·äºº") private String fcsrq; @PropertyDef(label = "é¨é¨å®¡æ ¸äºº") private String bmshr; @PropertyDef(label = "é¢å¯¼å®¡æ ¸äºº") private String ldshr; @PropertyDef(label = "夿³¨") private String bz; @PropertyDef(label = "æä½æ å¿") private String czbz; @PropertyDef(label = "æåæ´æ°æ¶é´") @JSONField(format = "yyyy-MM-dd HH:mm:ss") private Date zhgxsj; } src/main/java/com/fzzy/push/gd2022/dto/Gd2022Api2002.java
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,57 @@ package com.fzzy.push.gd2022.dto; import com.alibaba.fastjson.annotation.JSONField; import com.bstek.dorado.annotation.PropertyDef; import lombok.Data; import java.io.Serializable; import java.util.Date; /** * @Description åºæ¸ 确认å * @Author CZT * @Date 2024/6/29 14:54 */ @Data public class Gd2022Api2002 implements Serializable { private static final long serialVersionUID = 9157617424050247565L; @PropertyDef(label = "åºæ¸ 确认åå·", description = "2ä½ä¸å¡ç¼ç (22ä»£è¡¨åºæ¸ )+yyyyMMdd+4ä½é¡ºåºç ï¼22202405040001") private String cqqrdh; @PropertyDef(label = "仿¿ä»£ç " ) private String cfdm; @PropertyDef(label = "ç»ä¸ä»æ¿ç¼ç ") private String tycfbm; @PropertyDef(label = "å»é´ä»£ç ") private String ajdm; @PropertyDef(label = "ç»ä¸å»é´ç¼ç ") private String tyajbm; @PropertyDef(label = "åºæ¸ æ¥æ") @JSONField(format = "yyyy-MM-dd") private Date cqrq; @PropertyDef(label = "ç³è¯·äºº") private String srq; @PropertyDef(label = "é¨é¨å®¡æ ¸äºº") private String bmshr; @PropertyDef(label = "é¢å¯¼å®¡æ ¸äºº") private String ldshr; @PropertyDef(label = "夿³¨") private String bz; @PropertyDef(label = "æä½æ å¿") private String czbz; @PropertyDef(label = "æåæ´æ°æ¶é´") @JSONField(format = "yyyy-MM-dd HH:mm:ss") private Date zhgxsj; } src/main/java/com/fzzy/push/impl/ComPushService99.java
@@ -8,6 +8,10 @@ import com.fzzy.api.entity.ApiInfoData; import com.fzzy.api.service.ApiRemoteService; import com.fzzy.api.view.repository.ApiInfoDataRep; import com.fzzy.push.gd2022.ApiCodeConstant; import com.fzzy.push.gd2022.dto.Gd2022Api1023; import com.fzzy.push.gd2022.dto.Gd2022Api2001; import com.fzzy.push.gd2022.dto.Gd2022Api2002; import com.fzzy.push.sh2023.SH2023Constant; import com.fzzy.push.sh2023.dto.SH2023Api1115; import com.fzzy.push.sh2023.dto.SH2023Api1311; @@ -31,7 +35,7 @@ /*==========䏿µ·å¸å¹³å°å®å¶æ¥å£==========*/ /** * 1311 è§é¢çæ§æ¥å£--䏿µ·å¸å¹³å° * 1115 æ°æ®ç¸ç¬¦æ§æ¥å£--䏿µ·å¸å¹³å° */ public void pushData1115(ApiRemoteService apiRemoteService, ApiParam param) { // è·å è§é¢çæ§æ¥å£æ°æ® @@ -169,4 +173,107 @@ //TODO } /*==========广ä¸çå¹³å°å®å¶æ¥å£==========*/ /** * 1023 çè¸å¤æ¡æ¥å£ */ public void pushData1023(ApiRemoteService apiRemoteService, ApiParam param) { //è·åçè¸å¤æ¡ä¿¡æ¯ List<ApiInfoData> items = apiInfoDataRep.getDataByInteId(ApiCodeConstant.API_1023); if (null == items || items.isEmpty()) { log.error("-----广ä¸çå¹³å°2022çï¼æªè·åå°çè¸å¤æ¡ä¿¡æ¯ï¼ä¸æ¨é-----"); return; } param.setInteCategory("21"); param.setInteId(ApiCodeConstant.API_1023); Gd2022Api1023 gd2022Api1023; ResponseDto responseDto; for (ApiInfoData infoData : items) { gd2022Api1023 = JSONObject.parseObject(infoData.getData(), Gd2022Api1023.class); gd2022Api1023.setZhgxsj(infoData.getUpdateTime()); param.setBizId(infoData.getDataId()); responseDto = apiRemoteService.pushData(param, gd2022Api1023); if (responseDto.getSuccess() == 0) { if (Constant.CZBZ_I.equals(infoData.getCzbz())) { infoData.setCzbz(Constant.CZBZ_U); gd2022Api1023.setCzbz(Constant.CZBZ_U); infoData.setData(JSON.toJSONString(gd2022Api1023)); apiInfoDataRep.save(infoData); } } } } /** * 2001 å°ä»ç¡®è®¤å */ public void pushData2001(ApiRemoteService apiRemoteService, ApiParam param) { // è·å è§é¢çæ§æ¥å£æ°æ® List<ApiInfoData> items = apiInfoDataRep.getDataByInteId(ApiCodeConstant.API_2001); if (null == items || items.isEmpty()) { log.error("-----广ä¸çå¹³å°2022çï¼æªè·åå°å°ä»ç¡®è®¤åï¼ä¸æ¨é-----"); return; } param.setInteCategory("21"); param.setInteId(ApiCodeConstant.API_2001); Gd2022Api2001 gd2022Api2001; ResponseDto responseDto; for (ApiInfoData infoData : items) { gd2022Api2001 = JSONObject.parseObject(infoData.getData(), Gd2022Api2001.class); gd2022Api2001.setZhgxsj(infoData.getUpdateTime()); param.setBizId(infoData.getDataId()); responseDto = apiRemoteService.pushData(param, gd2022Api2001); if (responseDto.getSuccess() == 0) { if (Constant.CZBZ_I.equals(infoData.getCzbz())) { infoData.setCzbz(Constant.CZBZ_U); gd2022Api2001.setCzbz(Constant.CZBZ_U); infoData.setData(JSON.toJSONString(gd2022Api2001)); apiInfoDataRep.save(infoData); } } } } /** * 2002 åºæ¸ 确认å */ public void pushData2002(ApiRemoteService apiRemoteService, ApiParam param) { // è·å è§é¢çæ§æ¥å£æ°æ® List<ApiInfoData> items = apiInfoDataRep.getDataByInteId(ApiCodeConstant.API_2002); if (null == items || items.isEmpty()) { log.error("-----广ä¸çå¹³å°2022çï¼æªè·åå°åºæ¸ 确认åï¼ä¸æ¨é-----"); return; } param.setInteCategory("21"); param.setInteId(ApiCodeConstant.API_2002); Gd2022Api2002 gd2022Api2002; ResponseDto responseDto; for (ApiInfoData infoData : items) { gd2022Api2002 = JSONObject.parseObject(infoData.getData(), Gd2022Api2002.class); gd2022Api2002.setZhgxsj(infoData.getUpdateTime()); param.setBizId(infoData.getDataId()); responseDto = apiRemoteService.pushData(param, gd2022Api2002); if (responseDto.getSuccess() == 0) { if (Constant.CZBZ_I.equals(infoData.getCzbz())) { infoData.setCzbz(Constant.CZBZ_U); gd2022Api2002.setCzbz(Constant.CZBZ_U); infoData.setData(JSON.toJSONString(gd2022Api2002)); apiInfoDataRep.save(infoData); } } } } } src/main/resources/application-pro.yml
@@ -1,4 +1,4 @@ ########################## å¹¿ä¸æ½®é³ ########################## ########################## å¤§æ¹¾åº ########################## server: port: 8090 jetty: @@ -51,7 +51,6 @@ timeout: 6000 igds: default: companyId: 5317 file-path: D:/IGDS-API/FILE/ companyId: 5016 file-path: C:/app/igds-api/ img-path: D:/IGDS/FILE/ src/main/resources/application.yml
@@ -1,7 +1,7 @@ ########################## Server ########################## spring: profiles: active: dev active: pro application: name: igds-api main: src/main/resources/templates/home/home.html
@@ -300,6 +300,12 @@ <a lay-href="com.fzzy.otherview.gd2022.GdApi1023.d">广ä¸-çè¸å¤æ¡</a> </dd> <dd> <a lay-href="com.fzzy.otherview.gd2022.GdApi2001.d">广ä¸-å°ä»ç¡®è®¤å</a> </dd> <dd> <a lay-href="com.fzzy.otherview.gd2022.GdApi2002.d">广ä¸-åºæ¸ 确认å</a> </dd> <dd> <a lay-href="com.fzzy.otherview.sh2023.ShApi1115.d">䏿µ·-æ°æ®ç¸ç¬¦æ§</a> </dd> <dd>