浏览代码

Merge branch 'develop' of http://git.wdklian.com/allen/ncs_ui into develop

wuyunfeng 10 月之前
父节点
当前提交
1cf425030d

文件差异内容过多而无法显示
+ 1 - 1
dist/index.html


+ 33 - 28
languages/en.js

@@ -5,7 +5,7 @@ module.exports = {
     home: 'Home',
     home: 'Home',
     add: 'Add',
     add: 'Add',
     edit: 'Edit',
     edit: 'Edit',
-    more: 'More',
+    more: 'Saber mais',
     view: 'View',
     view: 'View',
     delete: 'Delete',
     delete: 'Delete',
     enabled: 'Enable',
     enabled: 'Enable',
@@ -66,7 +66,7 @@ module.exports = {
     FontSize: 'Font size',
     FontSize: 'Font size',
     chooseLang: 'Choose language',
     chooseLang: 'Choose language',
     SynchronizeHISInformation: 'Synchronize HIS information',
     SynchronizeHISInformation: 'Synchronize HIS information',
-    perpetualLicence: 'Perpetual License',
+    perpetualLicence: 'Licença Perpétua',
     licenseValidity: 'The license is valid until: ',
     licenseValidity: 'The license is valid until: ',
     licenseRemainsValid: 'The remaining validity period of the license:',
     licenseRemainsValid: 'The remaining validity period of the license:',
     getLicense: 'days, please contact after-sales to obtain authorization',
     getLicense: 'days, please contact after-sales to obtain authorization',
@@ -280,10 +280,10 @@ module.exports = {
     passNo: 'Employee No'
     passNo: 'Employee No'
   },
   },
   home: {
   home: {
-    todayTask: "Today's task",
-    recentNote: 'Recent Notes',
-    recentInteract: 'Recent Interact',
-    recentRemarks: 'Recent user notes'
+    todayTask: 'A tarefa de hoje',
+    recentNote: 'Notas recentes',
+    recentInteract: 'Interação recente',
+    recentRemarks: 'Notas de utilizador recentes'
   },
   },
   frameManage: {
   frameManage: {
     frameManage: 'Space position',
     frameManage: 'Space position',
@@ -658,8 +658,8 @@ module.exports = {
   remark: {
   remark: {
     remarkAdd: 'New note',
     remarkAdd: 'New note',
     remarkContent: 'Note content:',
     remarkContent: 'Note content:',
-    remarkCreateTime: 'Create time:',
-    remarkCreateName: 'Created by:'
+    remarkCreateTime: 'Tempo de criação:',
+    remarkCreateName: 'Criado por:'
   },
   },
   task: {
   task: {
     all: 'All',
     all: 'All',
@@ -683,10 +683,10 @@ module.exports = {
   },
   },
   interaction: {
   interaction: {
     interactionKeywords: 'Please enter the initiator or receiver',
     interactionKeywords: 'Please enter the initiator or receiver',
-    fromMemberName: 'Originator',
-    toMemberName: 'Receiver',
-    actionType: 'Interaction type',
-    actionEnd: 'Interaction result',
+    fromMemberName: 'Originador',
+    toMemberName: 'Recetor',
+    actionType: 'Tipo de interação',
+    actionEnd: 'Resultado da interação',
     actionTime: 'Number of interactions',
     actionTime: 'Number of interactions',
     actionTime2: 'Number of calls',
     actionTime2: 'Number of calls',
     success: 'Success',
     success: 'Success',
@@ -699,9 +699,9 @@ module.exports = {
     unSuccessTime2: 'Unconnected times',
     unSuccessTime2: 'Unconnected times',
     failedInteraction: 'Failed to hang up the interaction normally',
     failedInteraction: 'Failed to hang up the interaction normally',
     failedInteraction2: 'The call did not hang up normally',
     failedInteraction2: 'The call did not hang up normally',
-    notOperated: 'Not responding',
+    notOperated: 'Não está respondendo',
     data: 'Interaction data',
     data: 'Interaction data',
-    createDate: 'Interaction time',
+    createDate: 'Tempo de interação',
     responseTime: 'Response time',
     responseTime: 'Response time',
     fromDevice: 'Initiating device',
     fromDevice: 'Initiating device',
     toDevice: 'Receive device',
     toDevice: 'Receive device',
@@ -1076,12 +1076,12 @@ module.exports = {
     hisNurseOptionsKeyval: 'Nursing item classification his PK'
     hisNurseOptionsKeyval: 'Nursing item classification his PK'
   },
   },
   tab: {
   tab: {
-    home: 'Home',
-    frameManage: 'Space position',
-    deviceManage: 'All devices',
-    clerkManage: 'Employee management',
+    home: 'Casa',
+    frameManage: 'Localização espacial',
+    deviceManage: 'Todos os dispositivos',
+    clerkManage: 'Gestão de colaboradores',
     clerkCalendar: 'Employee clock in calendar',
     clerkCalendar: 'Employee clock in calendar',
-    patientManage: 'Patient management',
+    patientManage: 'Gestão de doentes',
     customerManage: 'User Management',
     customerManage: 'User Management',
     customerQrCode: 'User QR code',
     customerQrCode: 'User QR code',
     customerAdvice: 'Doctor\'s advice',
     customerAdvice: 'Doctor\'s advice',
@@ -1090,21 +1090,21 @@ module.exports = {
     sosDeviceSettingManage: 'Alarm device',
     sosDeviceSettingManage: 'Alarm device',
     channelManage: 'Intercom channel',
     channelManage: 'Intercom channel',
     channelImHistory: 'Channel message history',
     channelImHistory: 'Channel message history',
-    remarkManage: 'Note management',
-    taskManage: 'Task management',
-    interaction: 'Interaction',
+    remarkManage: 'Gestão de notas',
+    taskManage: 'Gestão de tarefas',
+    interaction: 'Interação',
     interactionHistory: 'Interaction History',
     interactionHistory: 'Interaction History',
     frameGroupManage: 'Region management',
     frameGroupManage: 'Region management',
     frameGroupEdit: 'Edit area information',
     frameGroupEdit: 'Edit area information',
     watchFrameManage: 'Mobile device space',
     watchFrameManage: 'Mobile device space',
-    broadcastManage: 'Broadcast settings',
+    broadcastManage: 'Configurações de transmissão',
     broadcastEdit: 'Edit broadcast information',
     broadcastEdit: 'Edit broadcast information',
     nurseConfig: 'Nursing parameters',
     nurseConfig: 'Nursing parameters',
     boardManage: 'Information board settings',
     boardManage: 'Information board settings',
     eventManage: 'Button event management',
     eventManage: 'Button event management',
     hisManage: 'His query',
     hisManage: 'His query',
     interactionChars: 'Interaction statistics',
     interactionChars: 'Interaction statistics',
-    settings: 'settings',
+    settings: 'Configurações',
     partSettings: 'Organization settings',
     partSettings: 'Organization settings',
     functionRoleMapping: 'Component Permissions',
     functionRoleMapping: 'Component Permissions',
     countdownConfig: 'Countdown Component Configuration',
     countdownConfig: 'Countdown Component Configuration',
@@ -1125,7 +1125,7 @@ module.exports = {
     deviceFrame: 'Device space',
     deviceFrame: 'Device space',
     ledDeviceManager: 'LED dot matrix screen management',
     ledDeviceManager: 'LED dot matrix screen management',
     ledDevice: 'LED dot matrix screen control',
     ledDevice: 'LED dot matrix screen control',
-    entraceguardUser: 'Passage setting',
+    entraceguardUser: 'Configurações de acesso',
     customBoardManage: 'Custom Board Screen',
     customBoardManage: 'Custom Board Screen',
     customBoardDesigner: 'Designer Board Screen',
     customBoardDesigner: 'Designer Board Screen',
     staffManageFrames: 'Staff Serve Structure',
     staffManageFrames: 'Staff Serve Structure',
@@ -1208,7 +1208,7 @@ module.exports = {
     CALLBACK: 'TCP Feedback',
     CALLBACK: 'TCP Feedback',
     VOICE: 'Voice',
     VOICE: 'Voice',
     VIDEO: 'Video',
     VIDEO: 'Video',
-    SOS: 'Emergency Call',
+    SOS: 'Chamadas de emergência',
     REINFORCE: 'Reinforcements',
     REINFORCE: 'Reinforcements',
     IM: 'Message',
     IM: 'Message',
     DEVICE: 'Device',
     DEVICE: 'Device',
@@ -1641,7 +1641,7 @@ module.exports = {
 
 
   },
   },
   wu20240322: {
   wu20240322: {
-    fileManager: 'File Manager'
+    fileManager: 'Gestor de ficheiros'
   },
   },
   zy20240530: {
   zy20240530: {
     customerAffair: 'user event',
     customerAffair: 'user event',
@@ -1670,6 +1670,11 @@ module.exports = {
     PTT: 'ptt'
     PTT: 'ptt'
   },
   },
   zy20240611: {
   zy20240611: {
-    boolTransfer: 'Enable managed interface'
+    boolTransfer: 'Enable managed interface',
+    hostDeviceLock: 'Enable card swiping privileges for the nurse\'s console',
+    broadcastEnable: 'Activate the broadcasting function',
+    learn: 'Learn',
+    learnAll: 'Learn All',
+    deleteAll: 'Delete All'
   }
   }
 }
 }

+ 6 - 1
languages/es.js

@@ -1670,6 +1670,11 @@ module.exports = {
     PTT: 'ptt'
     PTT: 'ptt'
   },
   },
   zy20240611: {
   zy20240611: {
-    boolTransfer: 'Habilitar interfaz gestionada'
+    boolTransfer: 'Habilitar interfaz gestionada',
+    hostDeviceLock: 'Habilitar privilegios de tarjeta para la consola de enfermería',
+    broadcastEnable: 'Activar la función de transmisión',
+    learn: 'Aprender',
+    learnAll: 'Aprender Todo',
+    deleteAll: 'Borrar Todo'
   }
   }
 }
 }

+ 1 - 1
languages/message-center/en.js

@@ -1,7 +1,7 @@
 module.exports = {
 module.exports = {
 
 
   mc: {
   mc: {
-    messageCenter: 'Message Center',
+    messageCenter: 'Centro de Mensagens',
     messages: 'Message List',
     messages: 'Message List',
     messageType: 'Message Type',
     messageType: 'Message Type',
     messageTemplate: 'Message Template',
     messageTemplate: 'Message Template',

+ 6 - 1
languages/ru-RU.js

@@ -1669,6 +1669,11 @@ module.exports = {
     PTT: 'ptt'
     PTT: 'ptt'
   },
   },
   zy20240611: {
   zy20240611: {
-    boolTransfer: 'Включить управляемый интерфейс'
+    boolTransfer: 'Включить управляемый интерфейс',
+    hostDeviceLock: 'Включить права использования карты для стационарного монитора медсестры',
+    broadcastEnable: 'Активировать функцию трансляции',
+    learn: 'Изучать',
+    learnAll: 'Изучать все',
+    deleteAll: 'Удалить все'
   }
   }
 }
 }

+ 6 - 1
languages/zh-CN.js

@@ -1673,6 +1673,11 @@ module.exports = {
     PTT: '一键通'
     PTT: '一键通'
   },
   },
   zy20240611: {
   zy20240611: {
-    boolTransfer: '开启托管界面'
+    boolTransfer: '开启托管界面',
+    hostDeviceLock: '开启护士主机刷卡权限',
+    broadcastEnable: '开启广播功能',
+    learn: '学习',
+    learnAll: '全部学习',
+    deleteAll: '全部删除'
   }
   }
 }
 }

+ 6 - 6
public/domain.js

@@ -9,11 +9,11 @@ const domain = {
   uiVersion: 1, // 1 医院版,2 月子中心版,3养老院版
   uiVersion: 1, // 1 医院版,2 月子中心版,3养老院版
   enableBroadcast: true, //广播使能
   enableBroadcast: true, //广播使能
   enableMobile: true,  //手机使能
   enableMobile: true,  //手机使能
-  enableEntraceguard: false,  //门禁使能
-  enableNBiot: false,  //NB设备
-  enableCustomerDevice: false,  //用户设备
-  enableSosDevice: false, //报警设备
-  enable485: false,
-  enableLinux: false
+  enableEntraceguard: true,  //门禁使能
+  enableNBiot: true,  //true
+  enableCustomerDevice: true,  //用户设备
+  enableSosDevice: true, //报警设备
+  enable485: true,
+  enableLinux: true
 }
 }
 
 

+ 1 - 1
set-envs.sh

@@ -14,4 +14,4 @@ echo "const domain = {
   enableSosDevice: ${enableSosDevice}, //报警设备
   enableSosDevice: ${enableSosDevice}, //报警设备
   enable485:${enable485},
   enable485:${enable485},
   enableLinux:${enableLinux}
   enableLinux:${enableLinux}
-}"  > /app/domain.js
+}"  > /app/domain.js

+ 42 - 1
src/api/ncs_device.js

@@ -284,7 +284,7 @@ export function getLocationDeviceList(partid) {
     loading: false
     loading: false
   })
   })
 }
 }
-/** 查询定位设备 */
+
 export function getDeviceList(frameId, type) {
 export function getDeviceList(frameId, type) {
   return request({
   return request({
     url: `/ncs/device/getDeviceList/${frameId}/${type}`,
     url: `/ncs/device/getDeviceList/${frameId}/${type}`,
@@ -293,3 +293,44 @@ export function getDeviceList(frameId, type) {
   })
   })
 }
 }
 
 
+/** 获取转换盒存储的按钮 */
+export function getLoraButtons(mac) {
+  return request({
+    url: `/ncs/device/get_lora_buttons/${mac}`,
+    method: 'get',
+    loading: false
+  })
+}
+/** 刷新转换盒存储的按钮 */
+export function refreshLoraButtons(mac) {
+  return request({
+    url: `/ncs/device/refresh_lora_buttons/${mac}`,
+    method: 'get',
+    loading: false
+  })
+}
+/** 转换盒添加按钮 */
+export function addLoraButtons(mac, lora_list) {
+  return request({
+    url: `/ncs/device/add_lora_buttons/${mac}/${lora_list}`,
+    method: 'get',
+    loading: false
+  })
+}
+/** 转换盒删除按钮 */
+export function delLoraButtons(mac, lora_mac) {
+  return request({
+    url: `/ncs/device/del_lora_buttons/${mac}/${lora_mac}`,
+    method: 'get',
+    loading: false
+  })
+}
+/** 转换盒清空存储的按钮 */
+export function delAllLoraButtons(mac) {
+  return request({
+    url: `/ncs/device/del_all_lora_buttons/${mac}`,
+    method: 'get',
+    loading: false
+  })
+}
+

文件差异内容过多而无法显示
+ 7 - 7
src/utils/domain.js


+ 132 - 5
src/views/ncs-device/components/deviceManager.vue

@@ -341,8 +341,7 @@
                 </el-row>
                 </el-row>
             </el-form>
             </el-form>
             <div slot="footer" class="dialog-footer">
             <div slot="footer" class="dialog-footer">
-                <el-button type="primary" @click="handlerFormSubmit('deviceEditForm')">{{ this.$t('action.yes') }}
-                </el-button>
+                <el-button type="primary" @click="handlerFormSubmit('deviceEditForm')">{{ this.$t('action.yes') }}</el-button>
             </div>
             </div>
         </el-dialog>
         </el-dialog>
         <!-- 设备编辑弹窗 -->
         <!-- 设备编辑弹窗 -->
@@ -368,6 +367,47 @@
                 <el-button type="primary" @click="updateDevicesServerIp()">{{ this.$t('action.yes') }}</el-button>
                 <el-button type="primary" @click="updateDevicesServerIp()">{{ this.$t('action.yes') }}</el-button>
             </div>
             </div>
         </el-dialog>
         </el-dialog>
+
+        <el-drawer
+            :title="s433TransferBox.name"
+            :visible.sync="s433TransferBoxDialogVisible"
+            direction="rtl"
+            :before-close="s433TransferBoxHandleClose"
+            size="40%"
+            v-loading="s433TransferBoxLoading"
+        >
+          <div class="drawer-content" style="margin: auto">
+            <div slot="toolbar" class="drawer-toolbar" style="margin: 20px 20px 20px 20px; text-align: right;">
+              <el-button type="primary" @click="addAllLoraButton()" :loading="s433TransferBoxHandleLoading">{{ this.$t('zy20240611.learnAll') }}</el-button>
+              <el-button type="danger" @click="delAllLoraButton()" :loading="s433TransferBoxHandleLoading">{{ this.$t('zy20240611.deleteAll') }}</el-button>
+            </div>
+
+            <el-table
+                :data="emergencyButtons"
+                border
+                style="width: 80%; margin: auto">
+              <el-table-column sortable fixed prop="id" label="ID" width="120" align="center"></el-table-column>
+              <el-table-column fixed prop="name" :label="this.$t('action.name')" width="150" align="center"></el-table-column>
+              <el-table-column fixed prop="eth_mac" :label="this.$t('board.ethMac')" width="150" align="center"></el-table-column>
+              <el-table-column fixed="right" :label="this.$t('action.handle')" width="180" align="center">
+                <template slot-scope="scope">
+                  <el-button
+                      :disabled="isLearn(scope.row)"
+                      size="mini"
+                      type="primary"
+                      :loading="s433TransferBoxHandleLoading"
+                      @click="addLoraButton(scope.$index, scope.row)">{{ $t('zy20240611.learn') }}</el-button>
+                  <el-button
+                      :disabled="!isLearn(scope.row)"
+                      size="mini"
+                      type="danger"
+                      :loading="s433TransferBoxHandleLoading"
+                      @click="delLoraButton(scope.$index, scope.row)">{{ $t('action.delete') }}</el-button>
+                </template>
+              </el-table-column>
+            </el-table>
+          </div>
+        </el-drawer>
     </div>
     </div>
 </template>
 </template>
 
 
@@ -528,7 +568,13 @@
                     ]
                     ]
                 },
                 },
               startTime: "06:00",
               startTime: "06:00",
-              endTime: "18:00"
+              endTime: "18:00",
+              s433TransferBoxDialogVisible: false,
+              s433TransferBoxLoading: false,
+              s433TransferBoxHandleLoading: false,
+              s433TransferBox: {},
+              emergencyButtons: [],
+              s433LearnEmergencyButtons: []
             }
             }
         },
         },
         computed: {
         computed: {
@@ -723,7 +769,7 @@
                                     disabled: param.data['member_name'] === 'superadmin'
                                     disabled: param.data['member_name'] === 'superadmin'
                                 },
                                 },
                                 {
                                 {
-                                    onClick: this.openDebug,
+                                    onClick: param.data.device_type === DEVICE_TYPE.S433_TRANSFER_BOX ? this.s433TransferBoxHandleOpen : this.openDebug,
                                     label: this.$t('action.opendebug'),
                                     label: this.$t('action.opendebug'),
                                     buttonType: 'success',
                                     buttonType: 'success',
                                     buttonSize: 'mini',
                                     buttonSize: 'mini',
@@ -1089,7 +1135,8 @@
                     val === DEVICE_TYPE.DOCTOR_HOST ||
                     val === DEVICE_TYPE.DOCTOR_HOST ||
                     val === DEVICE_TYPE.TRANSFER_DEVICE ||
                     val === DEVICE_TYPE.TRANSFER_DEVICE ||
                     val === DEVICE_TYPE.DOOR_DEVICE ||
                     val === DEVICE_TYPE.DOOR_DEVICE ||
-                    val === DEVICE_TYPE.DIGIT_BED_DEVICE
+                    val === DEVICE_TYPE.DIGIT_BED_DEVICE ||
+                    val === DEVICE_TYPE.S433_TRANSFER_BOX
 
 
             },
             },
             s485Device(param){
             s485Device(param){
@@ -1378,7 +1425,87 @@
             },
             },
           getDeviceType() {
           getDeviceType() {
               return DEVICE_TYPE;
               return DEVICE_TYPE;
+          },
+          s433TransferBoxHandleOpen(param) {
+            this.s433TransferBoxLoading = true
+            this.s433TransferBoxDialogVisible = true
+            this.s433TransferBox = param
+
+            this.getEmergencyButtons()
+            this.getLoraButtons(param)
+            this.s433TransferBoxLoading = false
+
+          },
+          s433TransferBoxHandleClose(done) {
+            this.s433TransferBoxDialogVisible = false
+            done();
+          },
+          getEmergencyButtons() {
+            API_Device.getDeviceByType(this.$store.getters.partId, DEVICE_TYPE.EMERGENCY_BUTTON).then(r => {
+              this.emergencyButtons = r;
+              console.log(this.emergencyButtons)
+            })
+          },
+          getLoraButtons(param) {
+            API_Device.getLoraButtons(param.eth_mac).then(r => {
+              this.s433LearnEmergencyButtons = r;
+              console.log('this.s433LearnEmergencyButtons:' + this.s433LearnEmergencyButtons)
+            })
+          },
+          delAllLoraButton() {
+            this.s433TransferBoxHandleLoading = true
+            API_Device.delAllLoraButtons(this.s433TransferBox.eth_mac).then(r => {
+              setTimeout(() => {
+                this.getLoraButtons(this.s433TransferBox)
+                this.s433TransferBoxHandleLoading = false
+              }, 3 * 1000)
+            })
+          },
+          delLoraButton(index, row) {
+            this.s433TransferBoxHandleLoading = true
+            API_Device.delLoraButtons(this.s433TransferBox.eth_mac, row.eth_mac).then(r => {
+              setTimeout(() => {
+                this.getLoraButtons(this.s433TransferBox)
+                this.s433TransferBoxHandleLoading = false
+              }, 3 * 1000)
+            })
+          },
+          addAllLoraButton() {
+            this.s433TransferBoxHandleLoading = true
+            let notLearnMac = "";
+            this.emergencyButtons.forEach(p => {
+              if (!this.isLearn(p)) {
+                notLearnMac += p.eth_mac
+              }
+            })
+
+            console.log("notLearnMac: " + notLearnMac)
+            if (notLearnMac !== "") {
+              API_Device.addLoraButtons(this.s433TransferBox.eth_mac, notLearnMac).then(r => {
+                setTimeout(() => {
+                  this.getLoraButtons(this.s433TransferBox)
+                  this.s433TransferBoxHandleLoading = false
+                }, 3 * 1000)
+              })
+            }
+            else {
+              this.s433TransferBoxHandleLoading = false
+            }
+          },
+          addLoraButton(index, row) {
+            this.s433TransferBoxHandleLoading = true
+            API_Device.addLoraButtons(this.s433TransferBox.eth_mac, row.eth_mac).then(r => {
+              setTimeout(() => {
+                this.getLoraButtons(this.s433TransferBox)
+                this.s433TransferBoxHandleLoading = false
+              }, 3 * 1000)
+            })
+          },
+          isLearn(row) {
+            const mac = row.eth_mac;
+            return this.s433LearnEmergencyButtons.includes(mac.toLowerCase());
           }
           }
+
         }
         }
     }
     }
 </script>
 </script>

+ 12 - 0
src/views/ncs-orginazition/components/partInfoEdit.vue

@@ -513,6 +513,18 @@
                 <el-checkbox v-model="formmodel.bool_transfer" :true-label="1" :false-label="0">{{ this.$t('action.enabled') }}</el-checkbox>
                 <el-checkbox v-model="formmodel.bool_transfer" :true-label="1" :false-label="0">{{ this.$t('action.enabled') }}</el-checkbox>
               </el-form-item>
               </el-form-item>
             </el-col>
             </el-col>
+
+            <el-col :span="8">
+              <el-form-item :label="this.$t('zy20240611.hostDeviceLock')" prop="host_device_lock">
+                <el-checkbox v-model="formmodel.host_device_lock" :true-label="1" :false-label="0">{{ this.$t('action.enabled') }}</el-checkbox>
+              </el-form-item>
+            </el-col>
+
+            <el-col :span="8">
+              <el-form-item :label="this.$t('zy20240611.broadcastEnable')" prop="broadcast_enable">
+                <el-checkbox v-model="formmodel.broadcast_enable" :true-label="1" :false-label="0">{{ this.$t('action.enabled') }}</el-checkbox>
+              </el-form-item>
+            </el-col>
           </el-row>
           </el-row>
 
 
           <el-row>
           <el-row>