From 48ddfebdf714efc12f7158630517212ad64ccd16 Mon Sep 17 00:00:00 2001 From: "382696293@qq.com" <382696293@qq.com> Date: Fri, 1 Mar 2024 18:12:56 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=AA=E5=99=A8=E6=96=B0=E5=A2=9E=20we200?= =?UTF-8?q?=E8=93=9D=E7=89=99=E8=BF=9E=E6=8E=A5=20=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../core/domain/entity/WxInstrument.java | 39 ++++++ .../core/domain/req/WxInstrumentSaveReq.java | 39 ++++++ .../resources/mapper/WxInstrumentMapper.xml | 17 ++- .../src/views/system/instrument/index.vue | 112 ++++++++++++++++-- 4 files changed, 195 insertions(+), 12 deletions(-) diff --git a/flossom-common/flossom-common-core/src/main/java/com/flossom/common/core/domain/entity/WxInstrument.java b/flossom-common/flossom-common-core/src/main/java/com/flossom/common/core/domain/entity/WxInstrument.java index 2e5b874..63e1531 100644 --- a/flossom-common/flossom-common-core/src/main/java/com/flossom/common/core/domain/entity/WxInstrument.java +++ b/flossom-common/flossom-common-core/src/main/java/com/flossom/common/core/domain/entity/WxInstrument.java @@ -232,6 +232,21 @@ public class WxInstrument extends BaseEntity { */ private String we200IotVersionUpgrade; + /** + * 蓝牙连接中标题 + */ + private String we200BluetoothConnectingTitle; + + /** + * 蓝牙连接中图片 + */ + private String we200BluetoothConnecting; + + /** + * 蓝牙连接中文案 + */ + private String we200BluetoothConnectingContent; + public void setId(Long id) { this.id = id; } @@ -575,4 +590,28 @@ public class WxInstrument extends BaseEntity { public String getNursingTimeStr() { return nursingTimeStr; } + + public String getWe200BluetoothConnectingTitle() { + return we200BluetoothConnectingTitle; + } + + public void setWe200BluetoothConnectingTitle(String we200BluetoothConnectingTitle) { + this.we200BluetoothConnectingTitle = we200BluetoothConnectingTitle; + } + + public String getWe200BluetoothConnecting() { + return we200BluetoothConnecting; + } + + public void setWe200BluetoothConnecting(String we200BluetoothConnecting) { + this.we200BluetoothConnecting = we200BluetoothConnecting; + } + + public String getWe200BluetoothConnectingContent() { + return we200BluetoothConnectingContent; + } + + public void setWe200BluetoothConnectingContent(String we200BluetoothConnectingContent) { + this.we200BluetoothConnectingContent = we200BluetoothConnectingContent; + } } diff --git a/flossom-common/flossom-common-core/src/main/java/com/flossom/common/core/domain/req/WxInstrumentSaveReq.java b/flossom-common/flossom-common-core/src/main/java/com/flossom/common/core/domain/req/WxInstrumentSaveReq.java index efb29a3..32da9f2 100644 --- a/flossom-common/flossom-common-core/src/main/java/com/flossom/common/core/domain/req/WxInstrumentSaveReq.java +++ b/flossom-common/flossom-common-core/src/main/java/com/flossom/common/core/domain/req/WxInstrumentSaveReq.java @@ -245,6 +245,21 @@ public class WxInstrumentSaveReq { */ private List newModeIdList; + /** + * 蓝牙连接中标题 + */ + private String we200BluetoothConnectingTitle; + + /** + * 蓝牙连接中图片 + */ + private String we200BluetoothConnecting; + + /** + * 蓝牙连接中文案 + */ + private String we200BluetoothConnectingContent; + public Long getId() { return id; } @@ -580,4 +595,28 @@ public class WxInstrumentSaveReq { public void setWe200IotVersionUpgrade(String we200IotVersionUpgrade) { this.we200IotVersionUpgrade = we200IotVersionUpgrade; } + + public String getWe200BluetoothConnectingTitle() { + return we200BluetoothConnectingTitle; + } + + public void setWe200BluetoothConnectingTitle(String we200BluetoothConnectingTitle) { + this.we200BluetoothConnectingTitle = we200BluetoothConnectingTitle; + } + + public String getWe200BluetoothConnecting() { + return we200BluetoothConnecting; + } + + public void setWe200BluetoothConnecting(String we200BluetoothConnecting) { + this.we200BluetoothConnecting = we200BluetoothConnecting; + } + + public String getWe200BluetoothConnectingContent() { + return we200BluetoothConnectingContent; + } + + public void setWe200BluetoothConnectingContent(String we200BluetoothConnectingContent) { + this.we200BluetoothConnectingContent = we200BluetoothConnectingContent; + } } diff --git a/flossom-common/flossom-common-core/src/main/resources/mapper/WxInstrumentMapper.xml b/flossom-common/flossom-common-core/src/main/resources/mapper/WxInstrumentMapper.xml index 9b86309..b1917bb 100644 --- a/flossom-common/flossom-common-core/src/main/resources/mapper/WxInstrumentMapper.xml +++ b/flossom-common/flossom-common-core/src/main/resources/mapper/WxInstrumentMapper.xml @@ -52,10 +52,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + + + - select id, name, type, model, banner, logo, serial, guarantee, daily_clock_credit, is_extra_clock, binding_credit, extra_clock_credit, start_time, end_time, mini_tag_ids, mini_tag_names, wecom_tag_ids, wecom_tag_names, nursing_time, iot_version, iot_upgrade_data, is_scan_code, is_purchase, shopping_appid, shopping_path, bluetooth_connecting_title, bluetooth_connecting_content,bluetooth_connecting, bluetooth_closed_title, bluetooth_closed_content, bluetooth_closed, bluetooth_connect_fail_title, bluetooth_connect_fail_content, bluetooth_connect_fail, iot_version_upgrade, sort_no, status, manual_code_binding, scan_code_binding, create_by, create_time, update_by, update_time, remark, we200_iot_version, we200_iot_upgrade_data, we200_iot_version_upgrade from wx_instrument + select id, name, type, model, banner, logo, serial, guarantee, daily_clock_credit, is_extra_clock, binding_credit, extra_clock_credit, start_time, end_time, mini_tag_ids, mini_tag_names, wecom_tag_ids, wecom_tag_names, nursing_time, iot_version, iot_upgrade_data, is_scan_code, is_purchase, shopping_appid, shopping_path, bluetooth_connecting_title, bluetooth_connecting_content,bluetooth_connecting, bluetooth_closed_title, bluetooth_closed_content, bluetooth_closed, bluetooth_connect_fail_title, bluetooth_connect_fail_content, bluetooth_connect_fail, iot_version_upgrade, sort_no, status, manual_code_binding, scan_code_binding, create_by, create_time, update_by, update_time, remark, we200_iot_version, we200_iot_upgrade_data, we200_iot_version_upgrade, we200_bluetooth_connecting_title, we200_bluetooth_connecting_content, we200_bluetooth_connecting from wx_instrument @@ -207,6 +213,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" we200_iot_version, we200_iot_upgrade_data, we200_iot_version_upgrade, + we200_bluetooth_connecting_title, + we200_bluetooth_connecting_Content, + we200_bluetooth_connecting, #{name}, @@ -255,6 +264,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" #{we200IotVersion}, #{we200IotUpgradeData}, #{we200IotVersionUpgrade}, + #{we200BluetoothConnectingTitle}, + #{we200BluetoothConnectingContent}, + #{we200BluetoothConnecting}, @@ -307,6 +319,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" we200_iot_version = #{we200IotVersion}, we200_iot_upgrade_data = #{we200IotUpgradeData}, we200_iot_version_upgrade = #{we200IotVersionUpgrade}, + we200_bluetooth_connecting_title = #{we200BluetoothConnectingTitle}, + we200_bluetooth_connecting_content = #{we200BluetoothConnectingContent}, + we200_bluetooth_connecting = #{we200BluetoothConnecting}, where id = #{id} diff --git a/flossom-ui/src/views/system/instrument/index.vue b/flossom-ui/src/views/system/instrument/index.vue index d544547..a59e31c 100644 --- a/flossom-ui/src/views/system/instrument/index.vue +++ b/flossom-ui/src/views/system/instrument/index.vue @@ -895,6 +895,47 @@ placeholder="请输入蓝牙断开连接文案" /> + + + + 点击上传 +
只能上传一个文件
+
+
+ + + + + +
@@ -982,7 +1023,7 @@ /> @@ -1011,7 +1052,7 @@ @@ -1429,6 +1470,11 @@ export default { uploadHide: false, fileList: [], }, + /* 蓝牙连接文件 */ + we200BluetoothConnectFile: { + uploadHide: false, + fileList: [], + }, /* 小程序可见标签 */ miniProgramTag: { instrumentId: null, @@ -1652,6 +1698,9 @@ export default { we200IotVersion: null, we200IotUpgradeData: null, we200IotVersionUpgrade: null, + we200BluetoothConnecting: null, + we200BluetoothConnectingTitle: null, + we200BluetoothConnectingContent: null, } /* 仪器封面 */ this.bannerFile = { @@ -1844,6 +1893,15 @@ export default { ], } } + /* we200蓝牙连接文件 */ + if (this.form.we200BluetoothConnecting != null) { + this.we200BluetoothConnectFile = { + uploadHide: true, + fileList: [ + { name: 'we200蓝牙连接文件', url: this.form.we200BluetoothConnecting }, + ], + } + } // 额外打卡时间 if (this.form.isExtraClock == 1) { this.form.extraClockTimeRange = response.data.extraClockTimeRange @@ -2031,7 +2089,7 @@ export default { if (response.code == 200) { this.form.serial = response.data.url } else { - this.$message.error('图片插入失败') + this.$message.error('文件上传失败') } }, /** 手写绑定介绍视频/图片 操作 */ @@ -2042,7 +2100,7 @@ export default { if (response.code == 200) { this.form.manualCodeBinding = response.data.url } else { - this.$message.error('图片插入失败') + this.$message.error('文件上传失败') } }, /** 扫码绑定介绍视频/图片 操作 */ @@ -2053,7 +2111,7 @@ export default { if (response.code == 200) { this.form.scanCodeBinding = response.data.url } else { - this.$message.error('图片插入失败') + this.$message.error('文件上传失败') } }, /* iot升级数据文件 */ @@ -2064,7 +2122,7 @@ export default { if (response.code == 200) { this.form.iotUpgradeData = response.data.url } else { - this.$message.error('图片插入失败') + this.$message.error('文件上传失败') } }, /* iot升级数据文件 */ @@ -2075,7 +2133,7 @@ export default { if (response.code == 200) { this.form.we200IotUpgradeData = response.data.url } else { - this.$message.error('图片插入失败') + this.$message.error('文件上传失败') } }, /* 蓝牙连接图片 */ @@ -2086,7 +2144,7 @@ export default { if (response.code == 200) { this.form.bluetoothConnecting = response.data.url } else { - this.$message.error('图片插入失败') + this.$message.error('文件上传失败') } }, /* 蓝牙断开连接图片 */ @@ -2097,7 +2155,7 @@ export default { if (response.code == 200) { this.form.bluetoothConnectFail = response.data.url } else { - this.$message.error('图片插入失败') + this.$message.error('文件上传失败') } }, /* 蓝牙断开连接图片 */ @@ -2108,9 +2166,20 @@ export default { if (response.code == 200) { this.form.bluetoothClosed = response.data.url } else { - this.$message.error('图片插入失败') + this.$message.error('文件上传失败') } }, + /* we200蓝牙连接图片 */ + we200BluetoothConnectUploadExceed(files, fileList) { + this.$message.warning(`您已上传了文件,如需更换,请先删除原上传的文件`) + }, + we200BluetoothConnectUploadSuccess(response, file) { + if (response.code == 200) { + this.form.we200BluetoothConnecting = response.data.url + } else { + this.$message.error('文件上传失败') + } + }, /* 是否开启额外打卡奖励 */ isExtraClockChange() { if (this.form.isExtraClock == 0) { @@ -2152,6 +2221,16 @@ export default { } this.mode.modeIdsOptions = response.data }) + this.form.we200IotVersion = null; + this.form.we200IotUpgradeData = null; + this.form.we200IotVersionUpgrade = null; + this.we200BluetoothConnectFile = { + uploadHide: false, + fileList: [], + }, + this.form.we200BluetoothConnecting = null; + this.form.we200BluetoothConnectingTitle = null; + this.form.we200BluetoothConnectingContent = null; }, modelChange() { /* 模式选项 */ @@ -2165,6 +2244,17 @@ export default { } this.mode.modeIdsOptions = response.data }) + + this.form.we200IotVersion = null; + this.form.we200IotUpgradeData = null; + this.form.we200IotVersionUpgrade = null; + this.we200BluetoothConnectFile= { + uploadHide: false, + fileList: [], + }, + this.form.we200BluetoothConnecting = null; + this.form.we200BluetoothConnectingTitle = null; + this.form.we200BluetoothConnectingContent = null; }, /* 是否购买切换 */ isPurchaseChang() {