|
@@ -76,7 +76,7 @@
|
|
|
</div>
|
|
|
<div class="card-panel-description">
|
|
|
<div class="card-panel-text">
|
|
|
- 病房数
|
|
|
+ {{ this.$t('frameManage.numberOfRooms') }}
|
|
|
</div>
|
|
|
<count-to :start-val="0" :end-val="bfCount" :duration="2600" class="card-panel-num" />
|
|
|
</div>
|
|
@@ -89,7 +89,7 @@
|
|
|
</div>
|
|
|
<div class="card-panel-description">
|
|
|
<div class="card-panel-text">
|
|
|
- 病床数
|
|
|
+ {{ this.$t('frameManage.numberOfBeds') }}
|
|
|
</div>
|
|
|
<count-to :start-val="0" :end-val="bcCount" :duration="2000" class="card-panel-num" />
|
|
|
</div>
|
|
@@ -102,7 +102,7 @@
|
|
|
</div>
|
|
|
<div class="card-panel-description">
|
|
|
<div class="card-panel-text">
|
|
|
- 在床数
|
|
|
+ {{ this.$t('frameManage.occupiedBeds') }}
|
|
|
</div>
|
|
|
<count-to :start-val="0" :end-val="zcCount" :duration="1900" class="card-panel-num" />
|
|
|
</div>
|
|
@@ -115,7 +115,7 @@
|
|
|
</div>
|
|
|
<div class="card-panel-description primary-care">
|
|
|
<div class="card-panel-text primary-care">
|
|
|
- 空床数
|
|
|
+ {{ this.$t('frameManage.emptyBeds') }}
|
|
|
</div>
|
|
|
<count-to :start-val="0" :end-val="kcCount" :duration="1500" class="card-panel-num" />
|
|
|
</div>
|
|
@@ -123,17 +123,17 @@
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
<el-tabs v-model="activeName" style="margin:0;" type="border-card">
|
|
|
- <el-tab-pane label="用户列表" name="frameInfo">
|
|
|
+ <el-tab-pane :label="this.$t('frameManage.memberList')" name="frameInfo">
|
|
|
<keep-alive>
|
|
|
<customer-manager :frame="selectedNode" @saved="handleCustomerChange" />
|
|
|
</keep-alive>
|
|
|
</el-tab-pane>
|
|
|
- <el-tab-pane label="设备列表" name="deviceList">
|
|
|
+ <el-tab-pane :label="this.$t('frameManage.deviceList')" name="deviceList">
|
|
|
<keep-alive>
|
|
|
<device-manager :frame="selectedNode" />
|
|
|
</keep-alive>
|
|
|
</el-tab-pane>
|
|
|
- <el-tab-pane label="机构成员" name="clerkManager">
|
|
|
+ <el-tab-pane :label="this.$t('frameManage.clerkList')" name="clerkManager">
|
|
|
<keep-alive>
|
|
|
<clerk-manager :part-id="selectedNode.part_id" />
|
|
|
</keep-alive>
|
|
@@ -144,13 +144,13 @@
|
|
|
|
|
|
<!---添加空间结构弹窗 -->
|
|
|
<el-dialog :title="frameEditTitle" :visible.sync="frameDialogVisible" width="500px">
|
|
|
- <el-form ref="editForm" :model="frameInfo" :rules="rules" label-width="110px">
|
|
|
+ <el-form ref="editForm" :model="frameInfo" :rules="rules" label-width="130px">
|
|
|
<el-row>
|
|
|
<el-col :span="24">
|
|
|
<!--医院结构名称-->
|
|
|
- <el-form-item label="名称" prop="name">
|
|
|
+ <el-form-item :label="this.$t('action.name')" prop="name">
|
|
|
<el-input v-model="frameInfo.name" :maxlength="20" @change="frameChange">
|
|
|
- <template slot="append">{{ frameInfo.type === 4?"房":"床" }}</template>
|
|
|
+ <template slot="append">{{ frameInfo.type === 4? this.$t('frameManage.room') : this.$t('frameManage.bed') }}</template>
|
|
|
</el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
@@ -158,7 +158,7 @@
|
|
|
<el-row>
|
|
|
<el-col :span="24">
|
|
|
<!--医院结构别名-->
|
|
|
- <el-form-item label="全称" prop="full_name">
|
|
|
+ <el-form-item :label="this.$t('action.fullName')" prop="full_name">
|
|
|
<el-input v-model="frameInfo.full_name" :maxlength="20" />
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
@@ -166,34 +166,34 @@
|
|
|
<el-row>
|
|
|
<el-col :span="24">
|
|
|
<!--医院结构别名-->
|
|
|
- <el-form-item label="别名" prop="alias">
|
|
|
+ <el-form-item :label="this.$t('action.alias')" prop="alias">
|
|
|
<el-input v-model="frameInfo.alias" :maxlength="20" />
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
<el-row hidden>
|
|
|
<el-col :span="12">
|
|
|
- <el-form-item label="类型">
|
|
|
- <el-radio v-model="frameInfo.type" :label="1">病房</el-radio>
|
|
|
- <el-radio v-model="frameInfo.type" :label="2">床位</el-radio>
|
|
|
+ <el-form-item :label="this.$t('action.type')">
|
|
|
+ <el-radio v-model="frameInfo.type" :label="1">{{ this.$t('frameManage.room') }}</el-radio>
|
|
|
+ <el-radio v-model="frameInfo.type" :label="2">{{ this.$t('frameManage.bed') }}</el-radio>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
|
|
|
<el-form-item>
|
|
|
- <el-button type="primary" class="save" @click="handleFrameSubmit('editForm')">确定</el-button>
|
|
|
+ <el-button type="primary" class="save" @click="handleFrameSubmit('editForm')">{{ this.$t('action.yes') }}</el-button>
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
</el-dialog>
|
|
|
<!---添加空间结构弹窗 -->
|
|
|
|
|
|
<!---快速创建结构弹窗 -->
|
|
|
- <el-dialog title="快速构建结构" :visible.sync="frameQuickCreateVisible" width="500px">
|
|
|
- <el-form ref="createFrameForm" :model="createFrameModel" :rules="createFrameRules" label-width="110px">
|
|
|
+ <el-dialog :title="this.$t('frameManage.quickCreateFrame')" :visible.sync="frameQuickCreateVisible" width="600px">
|
|
|
+ <el-form ref="createFrameForm" :model="createFrameModel" :rules="createFrameRules" label-width="200px">
|
|
|
<el-row>
|
|
|
<el-col :span="24">
|
|
|
<!--开始房间号-->
|
|
|
- <el-form-item label="开始房间号" prop="start_no">
|
|
|
+ <el-form-item :label="this.$t('frameManage.startRoom')" prop="start_no">
|
|
|
<el-input-number
|
|
|
v-model="createFrameModel.room_start_no"
|
|
|
:min="1"
|
|
@@ -205,7 +205,7 @@
|
|
|
<el-row>
|
|
|
<el-col :span="24">
|
|
|
<!--结束房间号-->
|
|
|
- <el-form-item label="结束房间号" prop="end_no">
|
|
|
+ <el-form-item :label="this.$t('frameManage.endRoom')" prop="end_no">
|
|
|
<el-input-number
|
|
|
v-model="createFrameModel.room_end_no"
|
|
|
:min="createFrameModel.room_start_no"
|
|
@@ -216,7 +216,7 @@
|
|
|
<el-row>
|
|
|
<el-col :span="24">
|
|
|
<!--每房床位数-->
|
|
|
- <el-form-item label="每房床位数" prop="beds_per_room">
|
|
|
+ <el-form-item :label="this.$t('frameManage.bedQuantity')" prop="beds_per_room">
|
|
|
<el-input-number v-model="createFrameModel.beds_per_room" :min="1" :max="20" />
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
@@ -225,7 +225,7 @@
|
|
|
<el-row>
|
|
|
<el-col :span="18">
|
|
|
<!--每房床位数-->
|
|
|
- <el-form-item label="房号显示位数" prop="room_num_bits">
|
|
|
+ <el-form-item :label="this.$t('frameManage.showRoomDigit')" prop="room_num_bits">
|
|
|
<el-input-number
|
|
|
v-model="createFrameModel.room_num_bits"
|
|
|
:min="1"
|
|
@@ -236,7 +236,7 @@
|
|
|
</el-col>
|
|
|
<el-col :span="6">
|
|
|
<div class="el-form-item__label">
|
|
|
- 示例:{{ room_num_demo }}
|
|
|
+ {{ this.$t('frameManage.example') }}:{{ room_num_demo }}
|
|
|
</div>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
@@ -244,7 +244,7 @@
|
|
|
<el-row>
|
|
|
<el-col :span="18">
|
|
|
<!--每房床位数-->
|
|
|
- <el-form-item label="床号显示位数" prop="bed_num_bits">
|
|
|
+ <el-form-item :label="this.$t('frameManage.showBedDigit')" prop="bed_num_bits">
|
|
|
<el-input-number
|
|
|
v-model="createFrameModel.bed_num_bits"
|
|
|
:min="1"
|
|
@@ -255,13 +255,13 @@
|
|
|
</el-col>
|
|
|
<el-col :span="6">
|
|
|
<div class="el-form-item__label">
|
|
|
- 示例:{{ bed_num_demo }}
|
|
|
+ {{ this.$t('frameManage.example') }}:{{ bed_num_demo }}
|
|
|
</div>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
|
|
|
<el-form-item>
|
|
|
- <el-button type="primary" class="save" @click="quickCreateSubmit()">确定</el-button>
|
|
|
+ <el-button type="primary" class="save" @click="quickCreateSubmit()">{{ this.$t('action.yes') }}</el-button>
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
</el-dialog>
|
|
@@ -270,21 +270,21 @@
|
|
|
<!-- 新建科室弹窗 -->
|
|
|
<el-dialog :title.sync="formtitle" :visible.sync="formshow" width="50%">
|
|
|
<div>
|
|
|
- <el-form ref="editform" :rules="rules" label-width="120px" :model="formmodel">
|
|
|
- <el-form-item label="科室名称" prop="shop_name">
|
|
|
- <el-input v-model="formmodel.shop_name" clearable :maxlength="100" placeholder="请输入科室名称" />
|
|
|
+ <el-form ref="editform" :rules="rules" label-width="200px" :model="formmodel">
|
|
|
+ <el-form-item :label="this.$t('frameManage.partName')" prop="shop_name">
|
|
|
+ <el-input v-model="formmodel.shop_name" clearable :maxlength="100" :placeholder="this.$t('frameManage.inputPartName')" />
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="管理员账号" prop="member_name">
|
|
|
- <el-input v-model="formmodel.member_name" clearable :maxlength="100" placeholder="请输入管理员账号" />
|
|
|
+ <el-form-item :label="this.$t('frameManage.adminMember')" prop="member_name">
|
|
|
+ <el-input v-model="formmodel.member_name" clearable :maxlength="100" :placeholder="this.$t('frameManage.inputAdminMember')" />
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="管理员密码" prop="member_password">
|
|
|
- <el-input v-model="formmodel.member_password" type="password" clearable :maxlength="100" placeholder="请输入管理员密码" />
|
|
|
+ <el-form-item :label="this.$t('frameManage.adminPassword')" prop="member_password">
|
|
|
+ <el-input v-model="formmodel.member_password" type="password" clearable :maxlength="100" :placeholder="this.$t('frameManage.inputAdminPassword')" />
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
</div>
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
- <el-button @click="formshow = false">取 消</el-button>
|
|
|
- <el-button type="primary" @click="handlerFormSubmit('editform')">确 定</el-button>
|
|
|
+ <el-button @click="formshow = false">{{ this.$t('action.cancel') }}</el-button>
|
|
|
+ <el-button type="primary" @click="handlerFormSubmit('editform')">{{ this.$t('action.yes') }}</el-button>
|
|
|
</div>
|
|
|
</el-dialog>
|
|
|
<!-- 新建科室弹窗结束 -->
|
|
@@ -317,20 +317,20 @@ export default {
|
|
|
/** 上级机构数组 **/
|
|
|
parents: [],
|
|
|
/** frame 编辑弹窗 **/
|
|
|
- frameEditTitle: '添加',
|
|
|
+ frameEditTitle: this.$t('action.add'),
|
|
|
frameDialogVisible: false,
|
|
|
frameInfo: {},
|
|
|
rules: {
|
|
|
name: [
|
|
|
- this.MixinRequired('请输入结构名称!'),
|
|
|
- { min: 2, max: 10, message: '长度在 2 到 10 个字符', trigger: 'blur' }
|
|
|
+ this.MixinRequired(this.$t('frameManage.inputFrameName')),
|
|
|
+ { min: 2, max: 10, message: this.$t('frameManage.inputLong'), trigger: 'blur' }
|
|
|
],
|
|
|
alias: [
|
|
|
- { min: 2, max: 10, message: '长度在 2 到 10 个字符', trigger: 'blur' }
|
|
|
+ { min: 2, max: 10, message: this.$t('frameManage.inputLong'), trigger: 'blur' }
|
|
|
],
|
|
|
full_name: [
|
|
|
- this.MixinRequired('请输入全称!'),
|
|
|
- { min: 2, max: 10, message: '长度在 2 到 10 个字符', trigger: 'blur' }
|
|
|
+ this.MixinRequired(this.$t('frameManage.inputFrameFullName')),
|
|
|
+ { min: 2, max: 10, message: this.$t('frameManage.inputLong'), trigger: 'blur' }
|
|
|
],
|
|
|
shop_name: [
|
|
|
{ required: true, message: '组织名称必须选择', trigger: 'blur' }
|
|
@@ -359,7 +359,7 @@ export default {
|
|
|
kcCount: 82,
|
|
|
bcCount: 56,
|
|
|
/** 新建组织弹出参数 **/
|
|
|
- formtitle: '新建组织',
|
|
|
+ formtitle: this.$t('frameManage.nowOrganization'),
|
|
|
formshow: false,
|
|
|
formmodel: {},
|
|
|
isShop: true
|
|
@@ -420,9 +420,9 @@ export default {
|
|
|
this.formshow = true
|
|
|
} else {
|
|
|
if (data.type === FRAME_TYPE.ROOM) {
|
|
|
- this.frameEditTitle = '【' + data.full_name + '】添加床位'
|
|
|
+ this.frameEditTitle = '【' + data.full_name + '】' + this.$t('frameManage.addBed')
|
|
|
} else {
|
|
|
- this.frameEditTitle = '【' + data.full_name + '】添加房间'
|
|
|
+ this.frameEditTitle = '【' + data.full_name + '】' + this.$t('frameManage.addRoom')
|
|
|
}
|
|
|
this.frameInfo = {
|
|
|
part_id: data.part_id,
|
|
@@ -439,7 +439,7 @@ export default {
|
|
|
},
|
|
|
edit(data, e) {
|
|
|
if (data.type === FRAME_TYPE.PART || data.type === FRAME_TYPE.HOSPITAL) {
|
|
|
- console.log('暂未开发')
|
|
|
+ this.$message.info(this.$t('action.notDevelopedYet') + '')
|
|
|
return
|
|
|
}
|
|
|
const parentNode = this.findNodeById(this.treeData, data.parent_id)
|
|
@@ -447,25 +447,25 @@ export default {
|
|
|
...data,
|
|
|
parent_name: parentNode === null ? '' : parentNode.name
|
|
|
}
|
|
|
- this.frameEditTitle = '编辑节点'
|
|
|
+ this.frameEditTitle = this.$t('frameManage.editFrame')
|
|
|
this.frameDialogVisible = true
|
|
|
},
|
|
|
remove(data) {
|
|
|
let warning = ''
|
|
|
if (data.type === FRAME_TYPE.ROOM) {
|
|
|
- warning = '确定要删除【' + data.full_name + '】及其中的所有床位吗?'
|
|
|
+ warning = this.$t('frameManage.sureDelete') + '【' + data.full_name + '】' + this.$t('frameManage.allBad')
|
|
|
} else {
|
|
|
- warning = '确定删除床位【' + data.full_name + '】吗?'
|
|
|
+ warning = this.$t('frameManage.sureDeleteBed') + '【' + data.full_name + '】?'
|
|
|
}
|
|
|
- this.$confirm(warning, '警告', {
|
|
|
- confirmButtonText: '确定',
|
|
|
- cancelButtonText: '取消',
|
|
|
+ this.$confirm(warning, this.$t('action.waring' + ''), {
|
|
|
+ confirmButtonText: this.$t('action.yes'),
|
|
|
+ cancelButtonText: this.$t('action.cancel'),
|
|
|
type: 'warning'
|
|
|
}).then(() => {
|
|
|
HospitalFrame_API.deleteHospitalFrame(data.id).then(response => {
|
|
|
this.$message({
|
|
|
type: 'success',
|
|
|
- message: '已删除!'
|
|
|
+ message: this.$t('action.deleted')
|
|
|
})
|
|
|
this.getFrameTree().then(() => {
|
|
|
// 判断选中节点是否被删除,如果被删除需要重新选择根节点
|
|
@@ -497,7 +497,7 @@ export default {
|
|
|
// params.full_name = params.parent_name + '-' + params.name + '床'
|
|
|
// }
|
|
|
HospitalFrame_API.updateHospitalFrame(params.id, params).then(response => {
|
|
|
- this.$message.success('修改成功!')
|
|
|
+ this.$message.success(this.$t('action.editSuccess') + '')
|
|
|
this.frameDialogVisible = false
|
|
|
this.getFrameTree().then(() => {
|
|
|
this.selectedNodeId = response.id
|
|
@@ -515,13 +515,13 @@ export default {
|
|
|
// }
|
|
|
|
|
|
HospitalFrame_API.addHospitalFrame(params).then(response => {
|
|
|
- this.$message.success('添加成功!')
|
|
|
+ this.$message.success(this.$t('action.addSuccess') + '')
|
|
|
this.frameDialogVisible = false
|
|
|
this.getFrameTree()
|
|
|
})
|
|
|
}
|
|
|
} else {
|
|
|
- this.$message.error('表单填写有误,请检查!')
|
|
|
+ this.$message.error(this.$t('action.editSuccess') + '')
|
|
|
return false
|
|
|
}
|
|
|
})
|
|
@@ -599,7 +599,7 @@ export default {
|
|
|
const params = this.createFrameModel
|
|
|
params.part_frame_id = this.treeData[0].id
|
|
|
HospitalFrame_API.quickCreate(params).then(res => {
|
|
|
- this.$message.success('创建成功!')
|
|
|
+ this.$message.success(this.$t('action.createSuccess') + '')
|
|
|
this.frameQuickCreateVisible = false
|
|
|
this.getFrameTree().then(() => {
|
|
|
this.$refs.frameTree.setCurrentKey(this.selectedNodeId)
|
|
@@ -633,9 +633,9 @@ export default {
|
|
|
console.log('s', this.frameInfo)
|
|
|
if (!this.frameInfo.full_name) {
|
|
|
if (this.frameInfo.type === FRAME_TYPE.ROOM) {
|
|
|
- this.$set(this.frameInfo, 'full_name', val + '房')
|
|
|
+ this.$set(this.frameInfo, 'full_name', val + this.$t('frameManage.room'))
|
|
|
} else {
|
|
|
- this.$set(this.frameInfo, 'full_name', this.frameInfo.parent_name + '-' + val + '床')
|
|
|
+ this.$set(this.frameInfo, 'full_name', this.frameInfo.parent_name + '-' + val + this.$t('frameManage.bed'))
|
|
|
}
|
|
|
}
|
|
|
},
|
|
@@ -653,12 +653,12 @@ export default {
|
|
|
const _this = this
|
|
|
API_PartInfo.add(this.formmodel).then(() => {
|
|
|
_this.formshow = false
|
|
|
- _this.$message.success('保存成功!')
|
|
|
+ _this.$message.success(this.$t('action.saveSuccess') + '')
|
|
|
_this.getFrameTree()
|
|
|
}).catch(err => {
|
|
|
_this.formshow = false
|
|
|
_this.formmodel.member_password = ''
|
|
|
- _this.$message.error(err)
|
|
|
+ _this.$message.error(err.message)
|
|
|
})
|
|
|
}
|
|
|
})
|