|
|
|
@ -2,7 +2,7 @@
|
|
|
|
|
<div class="main-container-text">
|
|
|
|
|
<div class="title">试剂管理</div>
|
|
|
|
|
<div class="header">
|
|
|
|
|
<el-select v-model="client_id" placeholder="请选择柜体">
|
|
|
|
|
<el-select v-model="client_id" clearable placeholder="请选择柜体">
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="item in clientOptions"
|
|
|
|
|
:key="item.id"
|
|
|
|
@ -10,7 +10,7 @@
|
|
|
|
|
:value="item.client_id"
|
|
|
|
|
/>
|
|
|
|
|
</el-select>
|
|
|
|
|
<el-input v-model="name" placeholder="请输入试剂名称" />
|
|
|
|
|
<el-input v-model="name" clearable placeholder="请输入试剂名称" />
|
|
|
|
|
<el-button type="primary" icon="el-icon-search" @click="getList">搜索</el-button>
|
|
|
|
|
<el-button type="primary" plain @click="handleSetEmpty"><svg-icon icon-class="cup" /> 设为空瓶</el-button>
|
|
|
|
|
<el-button icon="el-icon-edit" @click="handleEdit">编辑试剂</el-button>
|
|
|
|
@ -24,9 +24,10 @@
|
|
|
|
|
<el-table
|
|
|
|
|
v-loading="loading"
|
|
|
|
|
:data="tableData"
|
|
|
|
|
stripe
|
|
|
|
|
element-loading-text="拼命加载中"
|
|
|
|
|
:header-cell-style="headerStyle"
|
|
|
|
|
height="71vh"
|
|
|
|
|
height="69vh"
|
|
|
|
|
@selection-change="handleSelectionChange"
|
|
|
|
|
>
|
|
|
|
|
<el-table-column
|
|
|
|
@ -39,12 +40,14 @@
|
|
|
|
|
show-overflow-tooltip
|
|
|
|
|
label="试剂名称"
|
|
|
|
|
align="center"
|
|
|
|
|
width="100"
|
|
|
|
|
/>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="english_name"
|
|
|
|
|
show-overflow-tooltip
|
|
|
|
|
label="英文名称"
|
|
|
|
|
align="center"
|
|
|
|
|
width="100"
|
|
|
|
|
/>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="bar_code"
|
|
|
|
@ -71,22 +74,26 @@
|
|
|
|
|
prop="purity"
|
|
|
|
|
label="纯度"
|
|
|
|
|
align="center"
|
|
|
|
|
width="100"
|
|
|
|
|
show-overflow-tooltip
|
|
|
|
|
/>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="production_date"
|
|
|
|
|
label="生产日期"
|
|
|
|
|
align="center"
|
|
|
|
|
width="130"
|
|
|
|
|
/>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="put_in_date"
|
|
|
|
|
label="入库时间"
|
|
|
|
|
align="center"
|
|
|
|
|
width="130"
|
|
|
|
|
/>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="is_supervise"
|
|
|
|
|
label="是否监管"
|
|
|
|
|
align="center"
|
|
|
|
|
/>
|
|
|
|
|
<!-- <el-table-column-->
|
|
|
|
|
<!-- prop="is_supervise"-->
|
|
|
|
|
<!-- label="是否监管"-->
|
|
|
|
|
<!-- align="center"-->
|
|
|
|
|
<!-- />-->
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="status"
|
|
|
|
|
label="状态"
|
|
|
|
@ -102,33 +109,37 @@
|
|
|
|
|
align="center"
|
|
|
|
|
>
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
{{ clientOptions.find(item => item.client_id === scope.row.client_id).client_name }}
|
|
|
|
|
<div v-if="clientOptions.find(item => item.client_id === scope.row.client_id)">
|
|
|
|
|
{{ clientOptions.find(item => item.client_id === scope.row.client_id).client_name }}
|
|
|
|
|
</div>
|
|
|
|
|
<div v-else>
|
|
|
|
|
{{ scope.row.client_id }}
|
|
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="inventory_warning_value"
|
|
|
|
|
label="预警量(瓶)"
|
|
|
|
|
align="center"
|
|
|
|
|
/>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="use_days_warning_value"
|
|
|
|
|
label="提前预警(天)"
|
|
|
|
|
align="center"
|
|
|
|
|
/>
|
|
|
|
|
<!-- <el-table-column-->
|
|
|
|
|
<!-- prop="inventory_warning_value"-->
|
|
|
|
|
<!-- label="预警量(瓶)"-->
|
|
|
|
|
<!-- align="center"-->
|
|
|
|
|
<!-- />-->
|
|
|
|
|
<!-- <el-table-column-->
|
|
|
|
|
<!-- prop="use_days_warning_value"-->
|
|
|
|
|
<!-- label="提前预警(天)"-->
|
|
|
|
|
<!-- align="center"-->
|
|
|
|
|
<!-- />-->
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="by_user_name"
|
|
|
|
|
label="最后使用人"
|
|
|
|
|
align="center"
|
|
|
|
|
/>
|
|
|
|
|
</el-table>
|
|
|
|
|
<div style="text-align: center">
|
|
|
|
|
<div class="my-pagination" style="text-align: center">
|
|
|
|
|
<el-pagination
|
|
|
|
|
background
|
|
|
|
|
layout="prev, pager, next"
|
|
|
|
|
:current-page.sync="page"
|
|
|
|
|
:total="total"
|
|
|
|
|
:page-size.sync="page_size"
|
|
|
|
|
hide-on-single-page
|
|
|
|
|
:disabled="loading"
|
|
|
|
|
@current-change="pageChange"
|
|
|
|
|
/>
|
|
|
|
@ -141,24 +152,30 @@
|
|
|
|
|
:data="historyData"
|
|
|
|
|
height="420"
|
|
|
|
|
>
|
|
|
|
|
<el-table-column align="center" type="index" width="50" label="序号" />
|
|
|
|
|
<el-table-column align="center" property="name" label="试剂名称" />
|
|
|
|
|
<el-table-column align="center" property="bar_code" label="试剂编码" />
|
|
|
|
|
<el-table-column align="center" property="bar_code" label="试剂编码" width="100" show-overflow-tooltip />
|
|
|
|
|
<el-table-column align="center" property="cas_number" label="CAS码" />
|
|
|
|
|
<el-table-column align="center" property="purity" label="纯度" />
|
|
|
|
|
<el-table-column align="center" property="purity" label="纯度" width="100" show-overflow-tooltip />
|
|
|
|
|
<el-table-column align="center" property="client_id" label="所属终端">
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
{{ clientOptions.find(item => item.client_id === scope.row.client_id).client_name }}
|
|
|
|
|
<div v-if="clientOptions.find(item => item.client_id === scope.row.client_id)">
|
|
|
|
|
{{ clientOptions.find(item => item.client_id === scope.row.client_id).client_name }}
|
|
|
|
|
</div>
|
|
|
|
|
<div v-else>
|
|
|
|
|
{{ scope.row.client_id }}
|
|
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column align="center" property="status" label="操作类型">
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
<el-tag :type="statusColorMap[scope.row.status-1]">{{ statusMap[scope.row.status-1] }}</el-tag>
|
|
|
|
|
<el-tag :type="statusColorMap[scope.row.status-1]">{{ recodeStatusMap[scope.row.status-1] }}</el-tag>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column align="center" property="create_date" label="操作时间" />
|
|
|
|
|
<el-table-column align="center" property="create_date" label="操作时间" width="130" />
|
|
|
|
|
<el-table-column align="center" property="create_user_name" label="操作人员" />
|
|
|
|
|
</el-table>
|
|
|
|
|
<div style="text-align: center">
|
|
|
|
|
<div class="my-pagination" style="text-align: center">
|
|
|
|
|
<el-pagination
|
|
|
|
|
background
|
|
|
|
|
layout="prev, pager, next"
|
|
|
|
@ -166,14 +183,13 @@
|
|
|
|
|
:total="history_total"
|
|
|
|
|
:page-size.sync="history_page_size"
|
|
|
|
|
:disabled="loadingHistory"
|
|
|
|
|
hide-on-single-page
|
|
|
|
|
@current-change="HistoryPageChange"
|
|
|
|
|
/>
|
|
|
|
|
</div>
|
|
|
|
|
</el-dialog>
|
|
|
|
|
<el-dialog :visible.sync="dialogUserVisible" width="60%" title="分配禁用用户">
|
|
|
|
|
<div class="user-header">
|
|
|
|
|
<el-input v-model="seach_user" placeholder="请输入内容" />
|
|
|
|
|
<el-input v-model="seach_user" clearable placeholder="请输入内容" />
|
|
|
|
|
<el-button type="primary" icon="el-icon-search" @click="getUserList">搜索</el-button>
|
|
|
|
|
<el-button plain type="danger" @click="handleDisUser"><svg-icon icon-class="确认禁用" /> 确认禁用</el-button>
|
|
|
|
|
<el-button plain type="success" @click="handleEnUser"><svg-icon icon-class="解除禁用" /> 解除禁用</el-button>
|
|
|
|
@ -184,6 +200,7 @@
|
|
|
|
|
:header-cell-style="headerStyle"
|
|
|
|
|
:data="userData"
|
|
|
|
|
height="420"
|
|
|
|
|
stripe
|
|
|
|
|
@selection-change="handleUserSelectionChange"
|
|
|
|
|
>
|
|
|
|
|
<el-table-column type="selection" width="55" align="center" />
|
|
|
|
@ -201,13 +218,12 @@
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
</el-table>
|
|
|
|
|
<div style="text-align: center">
|
|
|
|
|
<div class="my-pagination" style="text-align: center">
|
|
|
|
|
<el-pagination
|
|
|
|
|
background
|
|
|
|
|
layout="prev, pager, next"
|
|
|
|
|
:current-page.sync="user_page"
|
|
|
|
|
:total="user_total"
|
|
|
|
|
hide-on-single-page
|
|
|
|
|
:page-size.sync="user_page_size"
|
|
|
|
|
:disabled="loadingUser"
|
|
|
|
|
@current-change="userPageChange"
|
|
|
|
@ -270,31 +286,31 @@
|
|
|
|
|
/>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="出库预警天数" prop="use_days_warning_value">
|
|
|
|
|
<el-input
|
|
|
|
|
v-model="formData.use_days_warning_value"
|
|
|
|
|
placeholder="请输入出库预警天数"
|
|
|
|
|
clearable
|
|
|
|
|
:style="{width: '100%'}"
|
|
|
|
|
/>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="保质期预警天数" prop="shelf_life_warning_value">
|
|
|
|
|
<el-input
|
|
|
|
|
v-model="formData.shelf_life_warning_value"
|
|
|
|
|
placeholder="请输入保质期预警天数"
|
|
|
|
|
clearable
|
|
|
|
|
:style="{width: '100%'}"
|
|
|
|
|
/>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="预警量" prop="inventory_warning_value">
|
|
|
|
|
<el-input v-model="formData.inventory_warning_value" placeholder="请输入预警量" clearable :style="{width: '100%'}" />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<!-- <el-col :span="12">-->
|
|
|
|
|
<!-- <el-form-item label="出库预警天数" prop="use_days_warning_value">-->
|
|
|
|
|
<!-- <el-input-->
|
|
|
|
|
<!-- v-model="formData.use_days_warning_value"-->
|
|
|
|
|
<!-- placeholder="请输入出库预警天数"-->
|
|
|
|
|
<!-- clearable-->
|
|
|
|
|
<!-- :style="{width: '100%'}"-->
|
|
|
|
|
<!-- />-->
|
|
|
|
|
<!-- </el-form-item>-->
|
|
|
|
|
<!-- </el-col>-->
|
|
|
|
|
<!-- <el-col :span="12">-->
|
|
|
|
|
<!-- <el-form-item label="保质期预警天数" prop="shelf_life_warning_value">-->
|
|
|
|
|
<!-- <el-input-->
|
|
|
|
|
<!-- v-model="formData.shelf_life_warning_value"-->
|
|
|
|
|
<!-- placeholder="请输入保质期预警天数"-->
|
|
|
|
|
<!-- clearable-->
|
|
|
|
|
<!-- :style="{width: '100%'}"-->
|
|
|
|
|
<!-- />-->
|
|
|
|
|
<!-- </el-form-item>-->
|
|
|
|
|
<!-- </el-col>-->
|
|
|
|
|
<!-- <el-col :span="12">-->
|
|
|
|
|
<!-- <el-form-item label="预警量" prop="inventory_warning_value">-->
|
|
|
|
|
<!-- <el-input v-model="formData.inventory_warning_value" placeholder="请输入预警量" clearable :style="{width: '100%'}" />-->
|
|
|
|
|
<!-- </el-form-item>-->
|
|
|
|
|
<!-- </el-col>-->
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="规格" prop="speci">
|
|
|
|
|
<el-input v-model="formData.speci" placeholder="请输入规格" clearable :style="{width: '100%'}" />
|
|
|
|
@ -315,16 +331,16 @@
|
|
|
|
|
<!-- <el-input v-model="formData.field115" placeholder="请输入说明" clearable :style="{width: '100%'}" />-->
|
|
|
|
|
<!-- </el-form-item>-->
|
|
|
|
|
<!-- </el-col>-->
|
|
|
|
|
<el-col :span="6">
|
|
|
|
|
<el-form-item label="是否监管" prop="is_supervise">
|
|
|
|
|
<el-switch v-model="formData.is_supervise" />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="4">
|
|
|
|
|
<el-form-item label="是否称重" prop="is_weigh">
|
|
|
|
|
<el-switch v-model="formData.is_weigh" />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<!-- <el-col :span="6">-->
|
|
|
|
|
<!-- <el-form-item label="是否监管" prop="is_supervise">-->
|
|
|
|
|
<!-- <el-switch v-model="formData.is_supervise" />-->
|
|
|
|
|
<!-- </el-form-item>-->
|
|
|
|
|
<!-- </el-col>-->
|
|
|
|
|
<!-- <el-col :span="4">-->
|
|
|
|
|
<!-- <el-form-item label="是否称重" prop="is_weigh">-->
|
|
|
|
|
<!-- <el-switch v-model="formData.is_weigh" />-->
|
|
|
|
|
<!-- </el-form-item>-->
|
|
|
|
|
<!-- </el-col>-->
|
|
|
|
|
</el-form>
|
|
|
|
|
</el-row>
|
|
|
|
|
<div style="text-align: center">
|
|
|
|
@ -356,6 +372,7 @@ export default {
|
|
|
|
|
page: 1,
|
|
|
|
|
page_size: 15,
|
|
|
|
|
total: 0,
|
|
|
|
|
recodeStatusMap: ['入库', '领用', '归还'],
|
|
|
|
|
statusMap: ['在库', '出库', '空瓶'],
|
|
|
|
|
statusColorMap: ['success', '', 'warning'],
|
|
|
|
|
headerStyle: { 'background': '#E6E6E6' },
|
|
|
|
@ -391,15 +408,15 @@ export default {
|
|
|
|
|
shelf_life: undefined,
|
|
|
|
|
production_date: '14:09:53',
|
|
|
|
|
expiration_date: null,
|
|
|
|
|
use_days_warning_value: undefined,
|
|
|
|
|
shelf_life_warning_value: undefined,
|
|
|
|
|
inventory_warning_value: undefined,
|
|
|
|
|
// use_days_warning_value: undefined,
|
|
|
|
|
// shelf_life_warning_value: undefined,
|
|
|
|
|
// inventory_warning_value: undefined,
|
|
|
|
|
speci: undefined,
|
|
|
|
|
net_weight_unit: undefined,
|
|
|
|
|
net_weight: undefined,
|
|
|
|
|
net_weight: undefined
|
|
|
|
|
// field115: undefined,
|
|
|
|
|
is_supervise: undefined,
|
|
|
|
|
is_weigh: undefined
|
|
|
|
|
// is_supervise: undefined,
|
|
|
|
|
// is_weigh: undefined
|
|
|
|
|
},
|
|
|
|
|
rules: {
|
|
|
|
|
name: [{
|
|
|
|
@ -434,27 +451,27 @@ export default {
|
|
|
|
|
message: '请选择过期日期',
|
|
|
|
|
trigger: 'change'
|
|
|
|
|
}],
|
|
|
|
|
use_days_warning_value: [{
|
|
|
|
|
required: true,
|
|
|
|
|
message: '请输入出库预警天数',
|
|
|
|
|
trigger: 'blur'
|
|
|
|
|
}],
|
|
|
|
|
shelf_life_warning_value: [{
|
|
|
|
|
required: true,
|
|
|
|
|
message: '请输入保质期预警天数',
|
|
|
|
|
trigger: 'blur'
|
|
|
|
|
}],
|
|
|
|
|
inventory_warning_value: [{
|
|
|
|
|
required: true,
|
|
|
|
|
message: '请输入预警量',
|
|
|
|
|
trigger: 'blur'
|
|
|
|
|
}],
|
|
|
|
|
// use_days_warning_value: [{
|
|
|
|
|
// required: true,
|
|
|
|
|
// message: '请输入出库预警天数',
|
|
|
|
|
// trigger: 'blur'
|
|
|
|
|
// }],
|
|
|
|
|
// shelf_life_warning_value: [{
|
|
|
|
|
// required: true,
|
|
|
|
|
// message: '请输入保质期预警天数',
|
|
|
|
|
// trigger: 'blur'
|
|
|
|
|
// }],
|
|
|
|
|
// inventory_warning_value: [{
|
|
|
|
|
// required: true,
|
|
|
|
|
// message: '请输入预警量',
|
|
|
|
|
// trigger: 'blur'
|
|
|
|
|
// }],
|
|
|
|
|
speci: [],
|
|
|
|
|
net_weight_unit: [],
|
|
|
|
|
net_weight: [],
|
|
|
|
|
net_weight: []
|
|
|
|
|
// field115: [],
|
|
|
|
|
is_supervise: [],
|
|
|
|
|
is_weigh: []
|
|
|
|
|
// is_supervise: [],
|
|
|
|
|
// is_weigh: []
|
|
|
|
|
},
|
|
|
|
|
dialogEditVisible: false
|
|
|
|
|
}
|
|
|
|
@ -483,7 +500,8 @@ export default {
|
|
|
|
|
this.loadingHistory = true
|
|
|
|
|
const data = {
|
|
|
|
|
page: this.history_page,
|
|
|
|
|
page_size: this.history_page_size
|
|
|
|
|
page_size: this.history_page_size,
|
|
|
|
|
medicament_id: this.multipleSelection[0].medicament_id
|
|
|
|
|
}
|
|
|
|
|
get_durg_record(stringify(data)).then(res => {
|
|
|
|
|
this.historyData = res.data.data_list
|
|
|
|
@ -492,6 +510,10 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
// 查看流转记录按钮click事件处理
|
|
|
|
|
showHistory() {
|
|
|
|
|
if (this.multipleSelection.length !== 1) {
|
|
|
|
|
this.$message.warning('请选择一个试剂!')
|
|
|
|
|
return
|
|
|
|
|
}
|
|
|
|
|
this.dialogHistoryVisible = true
|
|
|
|
|
this.getHistoryList()
|
|
|
|
|
},
|
|
|
|
@ -660,7 +682,7 @@ export default {
|
|
|
|
|
.header{
|
|
|
|
|
margin: 1rem 0 1rem 0;
|
|
|
|
|
.el-input{
|
|
|
|
|
width: 9.375rem;
|
|
|
|
|
width: 12.5rem;
|
|
|
|
|
margin-right: 1rem;
|
|
|
|
|
}
|
|
|
|
|
.el-select {
|
|
|
|
|