|
@@ -19,7 +19,7 @@
|
|
|
<el-form-item>
|
|
|
<!-- <el-button type="primary" size="btn" @click="handleQuery"
|
|
|
>搜索</el-button
|
|
|
- > -->
|
|
|
+ >-->
|
|
|
<el-button size="btr" @click="resetQuery">重置</el-button>
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
@@ -33,8 +33,7 @@
|
|
|
size="mini"
|
|
|
@click="handleAdd"
|
|
|
v-hasPermi="['medicalhealth:bdgldurgputout:add']"
|
|
|
- >新增</el-button
|
|
|
- >
|
|
|
+ >新增</el-button>
|
|
|
</el-col>
|
|
|
<!-- <el-col :span="1.5">
|
|
|
<el-button
|
|
@@ -47,7 +46,7 @@
|
|
|
v-hasPermi="['medicalhealth:bdgldurgputout:edit']"
|
|
|
>修改</el-button
|
|
|
>
|
|
|
- </el-col> -->
|
|
|
+ </el-col>-->
|
|
|
<el-col :span="1.5">
|
|
|
<el-button
|
|
|
type="danger"
|
|
@@ -57,8 +56,7 @@
|
|
|
:disabled="multiple"
|
|
|
@click="handleDelete"
|
|
|
v-hasPermi="['medicalhealth:bdgldurgputout:remove']"
|
|
|
- >删除</el-button
|
|
|
- >
|
|
|
+ >删除</el-button>
|
|
|
</el-col>
|
|
|
<!-- <el-col :span="1.5">
|
|
|
<el-button
|
|
@@ -71,11 +69,11 @@
|
|
|
v-hasPermi="['medicalhealth:bdgldurgputout:export']"
|
|
|
>导出</el-button
|
|
|
>
|
|
|
- </el-col> -->
|
|
|
+ </el-col>-->
|
|
|
<!-- <right-toolbar
|
|
|
:showSearch.sync="showSearch"
|
|
|
@queryTable="getList"
|
|
|
- ></right-toolbar> -->
|
|
|
+ ></right-toolbar>-->
|
|
|
</el-row>
|
|
|
|
|
|
<el-table
|
|
@@ -87,9 +85,11 @@
|
|
|
<el-table-column type="selection" width="55" align="center" />
|
|
|
<el-table-column label="序号" align="center">
|
|
|
<template scope="scope">
|
|
|
- <span>{{
|
|
|
+ <span>
|
|
|
+ {{
|
|
|
(queryParams.pageNum - 1) * queryParams.pageSize + scope.$index + 1
|
|
|
- }}</span>
|
|
|
+ }}
|
|
|
+ </span>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<!-- <el-table-column label="药品ID" align="center" prop="durgArchivesId" /> -->
|
|
@@ -97,12 +97,7 @@
|
|
|
<!-- <el-table-column label="出库位置" align="center" prop="place" /> -->
|
|
|
<el-table-column label="药品用途" align="center" prop="purpose" />
|
|
|
<!-- <el-table-column label="出库说明" align="center" prop="remarks" /> -->
|
|
|
- <el-table-column
|
|
|
- label="出库时间"
|
|
|
- align="center"
|
|
|
- prop="putTime"
|
|
|
- width="180"
|
|
|
- >
|
|
|
+ <el-table-column label="出库时间" align="center" prop="putTime" width="180">
|
|
|
<template slot-scope="scope">
|
|
|
<span>{{ parseTime(scope.row.putTime, "{y}-{m}-{d}") }}</span>
|
|
|
</template>
|
|
@@ -116,14 +111,11 @@
|
|
|
label="功能主治"
|
|
|
align="center"
|
|
|
prop="productIntroduction"
|
|
|
- /> -->
|
|
|
+ />-->
|
|
|
<el-table-column label="出库编号" align="center" prop="number" />
|
|
|
<el-table-column label="库房" align="center" prop="storeHouse">
|
|
|
<template slot-scope="scope">
|
|
|
- <dict-tag
|
|
|
- :options="dict.type.storage_room"
|
|
|
- :value="scope.row.storeHouse"
|
|
|
- />
|
|
|
+ <dict-tag :options="dict.type.storage_room" :value="scope.row.storeHouse" />
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<!-- <el-table-column label="库房" align="center" prop="unitId" /> -->
|
|
@@ -151,7 +143,7 @@
|
|
|
>删除</el-button
|
|
|
>
|
|
|
</template>
|
|
|
- </el-table-column> -->
|
|
|
+ </el-table-column>-->
|
|
|
</el-table>
|
|
|
|
|
|
<pagination
|
|
@@ -170,22 +162,13 @@
|
|
|
append-to-body
|
|
|
:close-on-click-modal="false"
|
|
|
>
|
|
|
- <el-form
|
|
|
- ref="form"
|
|
|
- :model="form"
|
|
|
- :rules="rules"
|
|
|
- label-width="80px"
|
|
|
- inline
|
|
|
- >
|
|
|
+ <el-form ref="form" :model="form" :rules="rules" label-width="80px" inline>
|
|
|
<el-form-item label="出库编号" prop="number">
|
|
|
- <el-input v-model="form.number" placeholder="请输入出库编号" />
|
|
|
+ <el-input v-model="form.number" @blur="getYaoPing" placeholder="请输入出库编号" />
|
|
|
</el-form-item>
|
|
|
<el-form-item label="药品名称" prop="putOut">
|
|
|
- <el-select
|
|
|
- v-model="form.durgName"
|
|
|
- placeholder="请选择药品名称"
|
|
|
- filterable
|
|
|
- >
|
|
|
+ <el-input v-model="form.durgName" placeholder="请输入药品名称" />
|
|
|
+ <!-- <el-select v-model="form.durgName" placeholder="请选择药品名称" filterable>
|
|
|
<el-option
|
|
|
class="input_xiala"
|
|
|
v-for="(item, i) in yaoList"
|
|
@@ -193,9 +176,8 @@
|
|
|
:value="item.id"
|
|
|
:label="item.yaoPinName"
|
|
|
@click.native="yapPing(item)"
|
|
|
- >
|
|
|
- </el-option>
|
|
|
- </el-select>
|
|
|
+ ></el-option>
|
|
|
+ </el-select>-->
|
|
|
</el-form-item>
|
|
|
<el-form-item label="使用单位" prop="unitId1">
|
|
|
<!-- <el-input v-model="form.unitId1" placeholder="请输入使用单位" /> -->
|
|
@@ -208,11 +190,7 @@
|
|
|
</el-form-item>
|
|
|
<el-form-item label="使用人" prop="receiveId">
|
|
|
<!-- <el-input v-model="form.receiveId" placeholder="请输入使用人" /> -->
|
|
|
- <el-select
|
|
|
- v-model="form.receiveId"
|
|
|
- placeholder="请选择使用人"
|
|
|
- filterable
|
|
|
- >
|
|
|
+ <el-select v-model="form.receiveId" placeholder="请选择使用人" filterable>
|
|
|
<el-option
|
|
|
class="input_xiala"
|
|
|
v-for="(item, i) in renYuan"
|
|
@@ -220,16 +198,18 @@
|
|
|
:label="item.name"
|
|
|
:value="item.id"
|
|
|
@click.native="shiyongren(item.name)"
|
|
|
- >
|
|
|
- </el-option>
|
|
|
+ ></el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="出库数量" prop="putOut">
|
|
|
- <el-input
|
|
|
+ <el-input-number
|
|
|
v-model="form.putOut"
|
|
|
+ controls-position="right"
|
|
|
+ :min="0"
|
|
|
placeholder="请输入出库数量"
|
|
|
@blur="shuLiang"
|
|
|
- />
|
|
|
+ ></el-input-number>
|
|
|
+ <!-- <el-input v-model="form.putOut" placeholder="请输入出库数量" @blur="shuLiang" /> -->
|
|
|
</el-form-item>
|
|
|
<el-form-item label="出库位置" prop="place">
|
|
|
<el-input v-model="form.place" placeholder="请输入出库位置" />
|
|
@@ -242,24 +222,15 @@
|
|
|
type="date"
|
|
|
value-format="yyyy-MM-dd"
|
|
|
placeholder="选择出库时间"
|
|
|
- >
|
|
|
- </el-date-picker>
|
|
|
+ ></el-date-picker>
|
|
|
</el-form-item>
|
|
|
<div class="jiben">药品用途</div>
|
|
|
<el-form-item prop="purpose">
|
|
|
- <el-input
|
|
|
- v-model="form.purpose"
|
|
|
- type="textarea"
|
|
|
- placeholder="请输入内容"
|
|
|
- />
|
|
|
+ <el-input v-model="form.purpose" type="textarea" placeholder="请输入内容" />
|
|
|
</el-form-item>
|
|
|
<div class="jiben">出库说明</div>
|
|
|
<el-form-item prop="remarks">
|
|
|
- <el-input
|
|
|
- v-model="form.remarks"
|
|
|
- type="textarea"
|
|
|
- placeholder="请输入内容"
|
|
|
- />
|
|
|
+ <el-input v-model="form.remarks" type="textarea" placeholder="请输入内容" />
|
|
|
</el-form-item>
|
|
|
|
|
|
<!-- <el-form-item label="录入人(创建人)" prop="adminId">
|
|
@@ -286,7 +257,7 @@
|
|
|
</el-form-item>
|
|
|
<el-form-item label="库房" prop="unitId">
|
|
|
<el-input v-model="form.unitId" placeholder="请输入库房" />
|
|
|
- </el-form-item> -->
|
|
|
+ </el-form-item>-->
|
|
|
</el-form>
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
|
@@ -303,7 +274,7 @@ import {
|
|
|
delBdgldurgputout,
|
|
|
addBdgldurgputout,
|
|
|
updateBdgldurgputout,
|
|
|
- exportBdgldurgputout,
|
|
|
+ exportBdgldurgputout
|
|
|
} from "@/api/medicalhealth/bdgldurgputout";
|
|
|
import { exportChuYao } from "@/api/medicalhealth/bdgldurgputin";
|
|
|
import { getDept2 } from "@/api/medicalhealth/bdgldurgarchives";
|
|
@@ -313,10 +284,12 @@ import "@riophae/vue-treeselect/dist/vue-treeselect.css";
|
|
|
// 人员
|
|
|
import { getZhuChiRen } from "@/api/grassrootsregistration/bdglmeeting";
|
|
|
|
|
|
+import { exportYao } from "@/api/medicalhealth/bdgldurgputin";
|
|
|
+
|
|
|
export default {
|
|
|
name: "Bdgldurgputout",
|
|
|
components: {
|
|
|
- Treeselect,
|
|
|
+ Treeselect
|
|
|
},
|
|
|
dicts: ["storage_room"],
|
|
|
data() {
|
|
@@ -360,7 +333,7 @@ export default {
|
|
|
number: null,
|
|
|
storeHouse: null,
|
|
|
unitId: null,
|
|
|
- unitId1: null,
|
|
|
+ unitId1: null
|
|
|
},
|
|
|
// 表单参数
|
|
|
form: {},
|
|
@@ -373,7 +346,7 @@ export default {
|
|
|
// 人员
|
|
|
renYuan: [],
|
|
|
// 数量
|
|
|
- yaoPingShu: "",
|
|
|
+ yaoPingShu: ""
|
|
|
};
|
|
|
},
|
|
|
created() {
|
|
@@ -414,13 +387,13 @@ export default {
|
|
|
},
|
|
|
/** 查询部门下拉树结构 */
|
|
|
getTreeselect() {
|
|
|
- getDept2().then((response) => {
|
|
|
+ getDept2().then(response => {
|
|
|
this.deptOptions = response.data;
|
|
|
});
|
|
|
},
|
|
|
// 获取主持人
|
|
|
getZhuChi(id) {
|
|
|
- getZhuChiRen(id).then((res) => {
|
|
|
+ getZhuChiRen(id).then(res => {
|
|
|
this.renYuan = res.data;
|
|
|
});
|
|
|
},
|
|
@@ -439,14 +412,28 @@ export default {
|
|
|
},
|
|
|
// 查询药品名称列表
|
|
|
getYaoPing() {
|
|
|
- exportChuYao().then((response) => {
|
|
|
- this.yaoList = response.data;
|
|
|
+ exportYao({ drugNo: this.form.number }).then(response => {
|
|
|
+ if (response.code == 200) {
|
|
|
+ if (response.data) {
|
|
|
+ this.form = response.data;
|
|
|
+ this.form.putOut = null;
|
|
|
+ this.form.durgName = response.data.yaoPinName;
|
|
|
+ this.form.durgArchivesId = this.form.id;
|
|
|
+ this.form.id = null;
|
|
|
+ this.form.number = response.data.drugNo;
|
|
|
+ this.yaoPingShu = response.data.amount;
|
|
|
+ } else {
|
|
|
+ this.$modal.msgSuccess("未有该药品编码!");
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ // this.yaoPingShu = response.data.surplus;
|
|
|
});
|
|
|
},
|
|
|
/** 查询药品出库登记列表 */
|
|
|
getList() {
|
|
|
this.loading = true;
|
|
|
- listBdgldurgputout(this.queryParams).then((response) => {
|
|
|
+ listBdgldurgputout(this.queryParams).then(response => {
|
|
|
this.bdgldurgputoutList = response.rows;
|
|
|
this.total = response.total;
|
|
|
this.loading = false;
|
|
@@ -478,7 +465,7 @@ export default {
|
|
|
number: null,
|
|
|
storeHouse: null,
|
|
|
unitId: null,
|
|
|
- unitId1: null,
|
|
|
+ unitId1: null
|
|
|
};
|
|
|
this.resetForm("form");
|
|
|
},
|
|
@@ -494,7 +481,7 @@ export default {
|
|
|
},
|
|
|
// 多选框选中数据
|
|
|
handleSelectionChange(selection) {
|
|
|
- this.ids = selection.map((item) => item.id);
|
|
|
+ this.ids = selection.map(item => item.id);
|
|
|
this.single = selection.length !== 1;
|
|
|
this.multiple = !selection.length;
|
|
|
},
|
|
@@ -502,16 +489,16 @@ export default {
|
|
|
handleAdd() {
|
|
|
this.reset();
|
|
|
this.getTreeselect();
|
|
|
- this.getYaoPing();
|
|
|
+ // this.getYaoPing();
|
|
|
this.open = true;
|
|
|
this.title = "添加药品出库登记";
|
|
|
},
|
|
|
/** 修改按钮操作 */
|
|
|
handleUpdate(row) {
|
|
|
this.reset();
|
|
|
- this.getYaoPing();
|
|
|
+ // this.getYaoPing();
|
|
|
const id = row.id || this.ids;
|
|
|
- getBdgldurgputout(id).then((response) => {
|
|
|
+ getBdgldurgputout(id).then(response => {
|
|
|
this.form = response.data;
|
|
|
this.open = true;
|
|
|
this.title = "修改药品出库登记";
|
|
@@ -519,13 +506,13 @@ export default {
|
|
|
},
|
|
|
/** 提交按钮 */
|
|
|
submitForm() {
|
|
|
- this.$refs["form"].validate((valid) => {
|
|
|
+ this.$refs["form"].validate(valid => {
|
|
|
if (valid) {
|
|
|
if (this.form.id != null) {
|
|
|
if (this.form.putOut > this.yaoPingShu) {
|
|
|
return;
|
|
|
}
|
|
|
- updateBdgldurgputout(this.form).then((response) => {
|
|
|
+ updateBdgldurgputout(this.form).then(response => {
|
|
|
this.$modal.msgSuccess("修改成功");
|
|
|
this.open = false;
|
|
|
this.getList();
|
|
@@ -534,7 +521,7 @@ export default {
|
|
|
if (this.form.putOut > this.yaoPingShu) {
|
|
|
return;
|
|
|
}
|
|
|
- addBdgldurgputout(this.form).then((response) => {
|
|
|
+ addBdgldurgputout(this.form).then(response => {
|
|
|
this.$modal.msgSuccess("新增成功");
|
|
|
this.open = false;
|
|
|
this.getList();
|
|
@@ -549,9 +536,9 @@ export default {
|
|
|
this.$confirm("是否确认删除药品出库登记的数据项?", "警告", {
|
|
|
confirmButtonText: "确定",
|
|
|
cancelButtonText: "取消",
|
|
|
- type: "warning",
|
|
|
+ type: "warning"
|
|
|
})
|
|
|
- .then(function () {
|
|
|
+ .then(function() {
|
|
|
return delBdgldurgputout(ids);
|
|
|
})
|
|
|
.then(() => {
|
|
@@ -566,19 +553,19 @@ export default {
|
|
|
this.$confirm("是否确认导出所有药品出库登记数据项?", "警告", {
|
|
|
confirmButtonText: "确定",
|
|
|
cancelButtonText: "取消",
|
|
|
- type: "warning",
|
|
|
+ type: "warning"
|
|
|
})
|
|
|
.then(() => {
|
|
|
this.exportLoading = true;
|
|
|
return exportBdgldurgputout(queryParams);
|
|
|
})
|
|
|
- .then((response) => {
|
|
|
+ .then(response => {
|
|
|
this.download(response.msg);
|
|
|
this.exportLoading = false;
|
|
|
})
|
|
|
.catch(() => {});
|
|
|
- },
|
|
|
- },
|
|
|
+ }
|
|
|
+ }
|
|
|
};
|
|
|
</script>
|
|
|
<style scoped>
|
|
@@ -734,4 +721,15 @@ export default {
|
|
|
::v-deep input:-moz-placeholder {
|
|
|
color: #bdbdbd4f !important;
|
|
|
}
|
|
|
+::v-deep .el-input-number__increase {
|
|
|
+ background-color: transparent !important;
|
|
|
+ border: none;
|
|
|
+ color: #cccccc;
|
|
|
+ border-bottom: none !important;
|
|
|
+}
|
|
|
+::v-deep .el-input-number__decrease {
|
|
|
+ background-color: transparent !important;
|
|
|
+ border: none !important;
|
|
|
+ color: #cccccc;
|
|
|
+}
|
|
|
</style>
|