diff --git a/jsowell-admin/src/main/java/com/jsowell/web/controller/pile/PileStationInfoController.java b/jsowell-admin/src/main/java/com/jsowell/web/controller/pile/PileStationInfoController.java index 8a3f58ea2..b52e54d4e 100644 --- a/jsowell-admin/src/main/java/com/jsowell/web/controller/pile/PileStationInfoController.java +++ b/jsowell-admin/src/main/java/com/jsowell/web/controller/pile/PileStationInfoController.java @@ -189,6 +189,17 @@ public class PileStationInfoController extends BaseController { return AjaxResult.success(thirdPartySettingInfoService.getInfoByStationId(id)); } + /** + * 查询第三方平台配置信息 + * @param info + * @return + */ + @PreAuthorize("@ss.hasPermi('pile:station:query')") + @PostMapping("/getSettingInfo") + public AjaxResult getSettingInfo(@RequestBody ThirdPartySettingInfo info) { + return AjaxResult.success(thirdPartySettingInfoService.selectSettingInfo(info)); + } + /** * 修改站点互联互通配置信息 * @param info diff --git a/jsowell-pile/src/main/java/com/jsowell/pile/mapper/ThirdPartySettingInfoMapper.java b/jsowell-pile/src/main/java/com/jsowell/pile/mapper/ThirdPartySettingInfoMapper.java index 4d0d9e6fa..8476e4366 100644 --- a/jsowell-pile/src/main/java/com/jsowell/pile/mapper/ThirdPartySettingInfoMapper.java +++ b/jsowell-pile/src/main/java/com/jsowell/pile/mapper/ThirdPartySettingInfoMapper.java @@ -29,6 +29,13 @@ public interface ThirdPartySettingInfoMapper { */ public List selectThirdPartySettingInfoList(ThirdPartySettingInfo thirdPartySettingInfo); + /** + * 查询第三方平台配置信息 + * @param info + * @return + */ + ThirdPartySettingInfo selectThirdInfo(ThirdPartySettingInfo info); + /** * 新增第三方平台配置 * diff --git a/jsowell-pile/src/main/java/com/jsowell/pile/service/IThirdPartySettingInfoService.java b/jsowell-pile/src/main/java/com/jsowell/pile/service/IThirdPartySettingInfoService.java index 904d5db1e..faaa4aa71 100644 --- a/jsowell-pile/src/main/java/com/jsowell/pile/service/IThirdPartySettingInfoService.java +++ b/jsowell-pile/src/main/java/com/jsowell/pile/service/IThirdPartySettingInfoService.java @@ -27,6 +27,14 @@ public interface IThirdPartySettingInfoService { */ public List selectThirdPartySettingInfoList(ThirdPartySettingInfo thirdPartySettingInfo); + + /** + * 查询第三方平台配置信息 + * @param thirdPartySettingInfo + * @return + */ + ThirdPartySettingInfo selectSettingInfo(ThirdPartySettingInfo thirdPartySettingInfo); + /** * 新增第三方平台配置 * diff --git a/jsowell-pile/src/main/java/com/jsowell/pile/service/impl/ThirdPartySettingInfoServiceImpl.java b/jsowell-pile/src/main/java/com/jsowell/pile/service/impl/ThirdPartySettingInfoServiceImpl.java index cba54ed94..61de78b8c 100644 --- a/jsowell-pile/src/main/java/com/jsowell/pile/service/impl/ThirdPartySettingInfoServiceImpl.java +++ b/jsowell-pile/src/main/java/com/jsowell/pile/service/impl/ThirdPartySettingInfoServiceImpl.java @@ -42,6 +42,16 @@ public class ThirdPartySettingInfoServiceImpl implements IThirdPartySettingInfoS return thirdPartySettingInfoMapper.selectThirdPartySettingInfoList(thirdPartySettingInfo); } + /** + * 查询第三方平台配置信息 + * @param thirdPartySettingInfo + * @return + */ + @Override + public ThirdPartySettingInfo selectSettingInfo(ThirdPartySettingInfo thirdPartySettingInfo) { + return thirdPartySettingInfoMapper.selectThirdInfo(thirdPartySettingInfo); + } + /** * 新增第三方平台配置 * diff --git a/jsowell-pile/src/main/resources/mapper/pile/ThirdPartySettingInfoMapper.xml b/jsowell-pile/src/main/resources/mapper/pile/ThirdPartySettingInfoMapper.xml index 312eca9e2..fd1c3ad85 100644 --- a/jsowell-pile/src/main/resources/mapper/pile/ThirdPartySettingInfoMapper.xml +++ b/jsowell-pile/src/main/resources/mapper/pile/ThirdPartySettingInfoMapper.xml @@ -119,4 +119,18 @@ from thirdparty_setting_info where station_id = #{stationId,jdbcType=BIGINT} + + \ No newline at end of file diff --git a/jsowell-ui/src/api/pile/station.js b/jsowell-ui/src/api/pile/station.js index a49890aa2..11fddf89e 100644 --- a/jsowell-ui/src/api/pile/station.js +++ b/jsowell-ui/src/api/pile/station.js @@ -94,6 +94,15 @@ export function getSettingByStationId(id) { }); } +// 查询站点互联互通配置 +export function getSettingInfo(data) { + return request({ + url: "/pile/station/getSettingInfo", + method: "post", + data: data, + }); +} + // 修改站点互联互通配置 export function updateSettingByStationId(data) { return request({ diff --git a/jsowell-ui/src/views/pile/station/detail.vue b/jsowell-ui/src/views/pile/station/detail.vue index 7db262e9c..af96cbe6b 100644 --- a/jsowell-ui/src/views/pile/station/detail.vue +++ b/jsowell-ui/src/views/pile/station/detail.vue @@ -64,41 +64,59 @@ style="margin-top:10px"> - - + + + + + + + - + - + - + - + - + - + @@ -146,11 +164,13 @@ import { updateStationQRCodePrefix, getSettingByStationId, updateSettingByStationId, - pushStationInfo + pushStationInfo, + getSettingInfo } from "@/api/pile/station"; import Whitelist from "@/views/pile/station/stationWhiteList"; export default { + dicts: ["third_party_type"], components: { Whitelist, SiteInfo, @@ -232,10 +252,26 @@ export default { this.stationSettingInfo = res.data; }) }, + // 根据站点id赫对接平台名称查询配置信息 + getSettingParams() { + const param = { + stationId: this.stationId, + type: this.stationSettingInfo.type, + } + console.log("param", param); + getSettingInfo(param).then((res) => { + console.log("getSettingInfo", res) + if (res.data === null) { + this.stationSettingInfo = null; + }else { + this.stationSettingInfo = res.data; + } + }) + }, // 开放编辑按钮 openEdit() { - this.disableFlag = false; + this.disableFlag = this.disableFlag === false; }, // 提交配置设置