切换分支备份

20240912_adapter_z
anthonywj 8 months ago
parent b0fd2f54c5
commit e7ad1240e8

@ -21,45 +21,53 @@
key="3"
@current-change="handleDetail"
>
<el-table-column label="药品标识" prop="nameCode" show-overflow-tooltip>
<el-table-column label="层级标识" prop="nameCode" show-overflow-tooltip width="160">
<template slot-scope="scope">
<el-input v-model="scope.row.nameCode"
:disabled="scope.row.rowDisabled"
placeholder="请输入药品标识" style="width: 100%"
<el-input v-model="productData.nameCode"
placeholder="" style="width: 100%"
></el-input>
</template>
</el-table-column>
<el-table-column label="包装级别" prop="packLevel" show-overflow-tooltip>
<el-table-column label="包装级别" prop="packLevel" show-overflow-tooltip width="160">
<template slot-scope="scope">
<el-input v-model="scope.row.packLevel"
:disabled="scope.row.rowDisabled"
type="number"
placeholder="请输入包装级别" style="width: 100%"
<el-input v-model="productData.packLevel"
placeholder="" style="width: 100%"
></el-input>
</template>
</el-table-column>
<!--<el-table-column label="包装单位" prop="packUnit" show-overflow-tooltip>-->
<!-- <template slot-scope="scope">-->
<!-- <el-input v-model="scope.row.packUnit"-->
<!-- :disabled="scope.row.rowDisabled"-->
<!-- placeholder="请输入包装单位" style="width: 100%"-->
<!-- ></el-input>-->
<!-- </template>-->
<!--</el-table-column>-->
<el-table-column label="包含下级数量" prop="bhxjsl" show-overflow-tooltip>
<el-table-column label="层级单位" prop="packUnit" show-overflow-tooltip width="100">
<template slot-scope="scope">
<el-input v-model="productData.packUnit"
placeholder="" style="width: 100%"
></el-input>
</template>
</el-table-column>
<el-table-column label="上级标识" prop="sjcpbm" show-overflow-tooltip width="160">
<template slot-scope="scope">
<el-input v-model="productData.packUnit"
placeholder="" style="width: 100%;margin: 5px"
></el-input>
</template>
</el-table-column>
<el-table-column label="下级标识" prop="bhxjcpbm" show-overflow-tooltip width="160">
<template slot-scope="scope">
<el-input v-model="productData.packUnit"
placeholder="" style="width: 100%"
></el-input>
</template>
</el-table-column>
<el-table-column label="下级数量" prop="bhxjsl" show-overflow-tooltip width="100">
<template slot-scope="scope">
<el-input v-model="scope.row.bhxjsl"
:disabled="scope.row.rowDisabled"
<el-input v-model="productData.bhxjsl"
type="number"
placeholder="请输入包含下级数量" style="width: 100%"
placeholder="" style="width: 100%"
></el-input>
</template>
</el-table-column>
<el-table-column label="操作" width="180px">
<template slot-scope="scope">
<el-button type="text" @click.native="save(scope.row)" :disabled="scope.row.isDisabled">保存</el-button>
<el-button type="text" @click.native="update(scope.row)" :disabled="scope.row.isUpDisabled">编辑</el-button>
<el-button type="text" @click.native="remove(scope.row)">删除</el-button>
<el-button type="text" @click.native="levelSave(productData)">保存</el-button>
<el-button type="text">删除</el-button>
</template>
</el-table-column>
</el-table>
@ -233,30 +241,6 @@
</el-form-item>
</el-col>
</el-row>
<el-row type="flex">
<el-col :span="11" class="el-col">
<el-form-item label="统一社会信用号:" prop="tyshxydm">
<el-input style="width: 90%" size="small" placeholder="请输入统一社会信用号"
v-model.trim="newProductData.tyshxydm"
></el-input>
</el-form-item>
</el-col>
<el-col :span="11" class="el-col">
<el-form-item label="药品状态:" prop="majorStatus">
<el-select v-model="newProductData.majorStatus" style="width: 90%" placeholder="选择药品状态" clearable>
<el-option label="停用" :value="0"></el-option>
<el-option label="在用" :value="1"></el-option>
</el-select>
</el-form-item>
</el-col>
<!--<el-col :span="11" class="el-col">-->
<!-- <el-form-item label="产品描述:" prop="cpms">-->
<!-- <el-input style="width: 90%" type="textarea" size="mini" rows="1" placeholder="请输入产品描述"-->
<!-- v-model.trim="newProductData.cpms"-->
<!-- ></el-input>-->
<!-- </el-form-item>-->
<!--</el-col>-->
</el-row>
<!-- <el-row type="flex">-->
<!-- <el-col :span="11" class="el-col">-->
<!-- <el-form-item label="产品类别:" prop="cplb">-->
@ -302,7 +286,30 @@
<!-- </el-form-item>-->
<!-- </el-col>-->
<!--</el-row>-->
<el-row type="flex">
<el-col :span="11" class="el-col">
<el-form-item label="统一社会信用号:" prop="tyshxydm">
<el-input style="width: 90%" size="small" placeholder="请输入统一社会信用号"
v-model.trim="newProductData.tyshxydm"
></el-input>
</el-form-item>
</el-col>
<el-col :span="11" class="el-col">
<el-form-item label="药品状态:" prop="majorStatus">
<el-select v-model="newProductData.majorStatus" style="width: 90%" placeholder="选择药品状态" clearable>
<el-option label="停用" :value="0"></el-option>
<el-option label="在用" :value="1"></el-option>
</el-select>
</el-form-item>
</el-col>
<!--<el-col :span="11" class="el-col">-->
<!-- <el-form-item label="产品描述:" prop="cpms">-->
<!-- <el-input style="width: 90%" type="textarea" size="mini" rows="1" placeholder="请输入产品描述"-->
<!-- v-model.trim="newProductData.cpms"-->
<!-- ></el-input>-->
<!-- </el-form-item>-->
<!--</el-col>-->
</el-row>
<el-row type="flex">
<el-col :span="23" class="el-col">
@ -359,14 +366,14 @@
</el-form>
<div style="text-align: center; margin-top: 20px;">
<el-button type="primary" @click="saveNewProduct" :loading="saveLoading">提交</el-button>
<el-button @click="closeAddDialog"></el-button>
<el-button type="primary" @click="closeAddDialog"></el-button>
</div>
</div>
</template>
<script>
import { getYbHcflDetail, addProduct, addDrug, updatetDrug } from '@/api/basic/product/udiRelevance'
import { filterClassify } from '@/api/purchase/classifyCode'
import {getYbHcflDetail, addProduct, addDrug, updatetDrug} from '@/api/basic/product/udiRelevance'
import {filterClassify} from '@/api/purchase/classifyCode'
export default {
name: 'drugAdd',
@ -387,7 +394,7 @@ export default {
data() {
return {
ybHcflDetail: {},
drugLevelList: [],
productData: {},
newProductData: {
cpmctymc: null,
bzgg: null,
@ -407,42 +414,42 @@ export default {
activeNames: ['1', '2'],
formRules: {
cpmctymc: [
{ required: true, message: '请输入药品通用名', trigger: 'blur' }
{required: true, message: '请输入药品通用名', trigger: 'blur'}
],
prepnSpec: [
{ required: true, message: '请输入制剂规格', trigger: 'blur' }
{required: true, message: '请输入制剂规格', trigger: 'blur'}
],
packUnit: [
{ required: true, message: '请输入包装单位', trigger: 'blur' }
{required: true, message: '请输入包装单位', trigger: 'blur'}
],
prepnUnit: [
{ required: true, message: '请输入制剂单位', trigger: 'blur' }
{required: true, message: '请输入制剂单位', trigger: 'blur'}
],
packRatio: [
{ required: true, message: '请输入包装比例', trigger: 'blur' }
{required: true, message: '请输入包装比例', trigger: 'blur'}
],
packMatrial: [
{ required: true, message: '请输入包装材质', trigger: 'blur' }
{required: true, message: '请输入包装材质', trigger: 'blur'}
],
registerNo: [
{ required: true, message: '请输入批准文号', trigger: 'blur' }
{required: true, message: '请输入批准文号', trigger: 'blur'}
],
manufactory: [
{ required: true, message: '生产企业不能为空', trigger: 'blur' }
{required: true, message: '生产企业不能为空', trigger: 'blur'}
],
physicType: [
{ required: true, message: '药品类型不能为空', trigger: 'blur' }
{required: true, message: '药品类型不能为空', trigger: 'blur'}
],
ybbm: [
{ required: true, message: '医保编码不能为空', trigger: 'blur' }
{required: true, message: '医保编码不能为空', trigger: 'blur'}
],
price: [
{ required: true, message: '药品价格不能为空', trigger: 'blur' }
{required: true, message: '药品价格不能为空', trigger: 'blur'}
]
},
detailList: [
//
{ nameCode: '', packLevel: null, bhxjsl: null ,isDisabled: false, isUpDisabled: true,rowDisabled: false }
{nameCode: '', packLevel: null, bhxjsl: null, isDisabled: false, isUpDisabled: true, rowDisabled: false}
],
status: false,
rowDisabled: false
@ -548,7 +555,9 @@ export default {
closeAddDialog() {
this.closeDialog()
},
save(row) {
//
levelSave(row) {
const isNotEmpty = row.nameCode || row.packLevel || row.bhxjsl;
if (!isNotEmpty) {
return this.$message.error("至少填写一个属性");
@ -570,7 +579,7 @@ export default {
// this.drugLevelList.push(data)
// }
},
update(row){
update(row) {
row.isDisabled = false
row.isUpDisabled = true
row.rowDisabled = false
@ -589,7 +598,7 @@ export default {
remove(row) {
// detailList
const index = this.detailList.indexOf(row);
if (index == 0){
if (index == 0) {
return this.$message.error("至少添加一层")
}
if (index !== -1) {

@ -91,13 +91,15 @@
<el-table v-loading="loading" :data="list" style="width: 100%" :row-style="{height: '32px' }"
>
<el-table-column type="index" label="序号"></el-table-column>
<el-table-column label="药品编码" prop="nameCode" width="90"></el-table-column>
<el-table-column label="药品通用名称" prop="cpmctymc" width="100"></el-table-column>
<el-table-column label="包装规格" prop="bzgg" width="90"></el-table-column>
<!--<el-table-column label="规格型号" prop="ggxh" width="90"></el-table-column>-->
<el-table-column label="包装单位" prop="prepnUnit" width="90"></el-table-column>
<el-table-column label="最小销售产品标识" prop="nameCode" width="160"></el-table-column>
<el-table-column label="收费项目编码" prop="payFeeCode" width="100"></el-table-column>
<el-table-column label="药品通用名称" prop="cpmctymc" width="160"></el-table-column>
<el-table-column label="制剂规格" prop="prepnSpec" width="90"></el-table-column>
<el-table-column label="制剂单位" prop="prepnUnit" width="90"></el-table-column>
<el-table-column label="包装规格" prop="ggxh" width="100"></el-table-column>
<el-table-column label="包装单位" prop="prepnUnit" width="90"></el-table-column>
<el-table-column label="包装比例" prop="packRatio" width="90"></el-table-column>
<el-table-column label="价格" prop="price" width="90"></el-table-column>
<el-table-column label="批准文号" prop="zczbhhzbapzbh" width="90"></el-table-column>
<el-table-column label="生产企业" prop="manufactory" width="90"></el-table-column>
<el-table-column label="收费项目编码" prop="remake" width="100"></el-table-column>
@ -138,14 +140,6 @@
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="filterQuery.page"
:limit.sync="filterQuery.limit"
@pagination="getList"
></pagination>
<el-dialog
:title="fromMap[fromName]"
@ -225,10 +219,11 @@ export default {
rowData: {},
type: null,
fromMap: {
'add' : '新增-药品信息',
'edit' : '编辑-药品信息',
'add': '新增-药品信息',
'edit': '编辑-药品信息',
},
total: 0,
loading: false,
}
},
methods: {
@ -303,7 +298,6 @@ export default {
},
closeDialog(){
this.addDrugVisible = false;
this.getList()
}
},
filters: {

@ -48,9 +48,8 @@
<el-date-picker
:picker-options="pickerOptions"
v-model="actDateRange"
type="daterange"
format="yyyy 年 MM 月 dd 日"
value-format="yyyy-MM-dd"
type="datetimerange"
value-format="yyyy-MM-dd HH:mm:ss"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"

Loading…
Cancel
Save