diff --git a/src/api/reagent/management.js b/src/api/reagent/management.js
index 14b2de9..34dce6c 100644
--- a/src/api/reagent/management.js
+++ b/src/api/reagent/management.js
@@ -71,3 +71,12 @@ export function del(data) {
})
}
+// /api/drug/set_drug_empty_bottle
+export function set_drug_empty_bottle(data) {
+ return request({
+ url: '/api/drug/set_drug_empty_bottle',
+ method: 'post',
+ data
+ })
+}
+
diff --git a/src/views/reagent/management/index.vue b/src/views/reagent/management/index.vue
index 4d1268d..27725df 100644
--- a/src/views/reagent/management/index.vue
+++ b/src/views/reagent/management/index.vue
@@ -12,7 +12,7 @@
搜索
- 设为空瓶
+ 设为空瓶
编辑试剂
查看流转记录
分配禁用用户
@@ -341,7 +341,8 @@ import {
update,
user_ban_confirm,
user_ban_list,
- user_ban_relieve
+ user_ban_relieve,
+ set_drug_empty_bottle
} from '@/api/reagent/management'
import stringify from '@/utils/stringify'
export default {
@@ -514,6 +515,20 @@ export default {
this.getList()
})
},
+ // 设置空瓶
+ handleSetEmpty() {
+ if (this.multipleSelection.length !== 1) {
+ this.$message.warning('请选择一个试剂!')
+ return
+ }
+ const data = {
+ medicament_id: this.multipleSelection[0].medicament_id
+ }
+ set_drug_empty_bottle(stringify(data)).then(res => {
+ this.$message.success(res.msg)
+ this.getList()
+ })
+ },
// 刷新按钮
handleRefresh() {
this.getList()
@@ -529,7 +544,7 @@ export default {
},
// 分配禁用用户 翻页
userPageChange(page) {
-
+ this.getUserList()
},
// 用户多选
handleUserSelectionChange(val) {