Merge branch '20240912_adapter' of http://116.204.71.86:3000/UDI/udiwms-vue-frame into 20240912_adapter

20240912_adapter
qiuyt 5 days ago
commit cc29a99b71

@ -10,7 +10,7 @@
"preview": "node build/index.js --preview",
"lint": "eslint --ext .js,.vue src",
"server": "SET NODE_OPTIONS=--openssl-legacy-provider && webpack-dev-server --env.server --env.develop --inline --max-old-space-size=3000",
"dev": "vue-cli-service serve --open"
"dev": "set NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service serve --open"
},
"husky": {
"hooks": {

@ -100,8 +100,11 @@
<div style="margin-top: 1px;padding: 5px">
<el-row :gutter="0" style="margin-top: 5px">
<el-col :span="16">
<!--:label="scanTip" -->
<el-form-item prop="code" :label="scanTip" label-width="80px">
<el-input
id="inputer"
@focus="getInputFocus($event)"
@ -111,13 +114,13 @@
type="tel"
:placeholder="this.placeholder"
v-model="scanCode"
size="50"
></el-input>
<!-- :disabled="scanDisabled"-->
</el-form-item>
</el-col>
<el-col :span="8">
<el-button-group style="display: flex; margin-left: 15px">
<el-button-group style="display: flex; margin-left: 15px;height: 36px">
<el-button type="primary" @click.native="deleteCode"
v-if="labelName == 1"
:disabled="formData.billNo == null"
@ -161,85 +164,50 @@
</el-checkbox>
</el-col>
</el-row>
<el-alert
:title="scanTitle"
:type="scanResultType"
:closable="false"
:dangerouslyUseHTMLString="true"
:description="result">
</el-alert>
<el-alert
v-if="warnVisible"
title="警告信息:"
type="warning"
:closable="true"
:dangerouslyUseHTMLString="true"
:description="warnResult">
</el-alert>
<el-alert
v-if="errVisible"
title="错误信息:"
type="warning"
:closable="true"
:dangerouslyUseHTMLString="true"
:description="errResult">
</el-alert>
<!--<el-alert-->
<!-- :title="scanTitle"-->
<!-- :type="scanResultType"-->
<!-- :closable="false"-->
<!-- :dangerouslyUseHTMLString="true"-->
<!-- :description="result">-->
<!--</el-alert>-->
<!--<el-alert-->
<!-- v-if="warnVisible"-->
<!-- title="警告信息:"-->
<!-- type="warning"-->
<!-- :closable="true"-->
<!-- :dangerouslyUseHTMLString="true"-->
<!-- :description="warnResult">-->
<!--</el-alert>-->
<!--<el-alert-->
<!-- v-if="errVisible"-->
<!-- title="错误信息:"-->
<!-- type="warning"-->
<!-- :closable="true"-->
<!-- :dangerouslyUseHTMLString="true"-->
<!-- :description="errResult">-->
<!--</el-alert>-->
</div>
<!--<el-descriptions title="单据信息" :column="4" border style="margin-top: 15px" class="custom-descriptions">-->
<el-descriptions :column="7" border style="margin-top: 5px">
<!--{{ formData.billNo }}-->
<!--<el-descriptions-item label="业务单号">-->
<!--<svg ref="barcodeContainer" ></svg>-->
<!--<div class="barcode-wrapper" >-->
<!-- <svg ref="barcodeContainer" v-show="formData.billNo != null"></svg>-->
<!-- &lt;!&ndash;<span>{{ formData.billNo }}</span>&ndash;&gt;-->
<!--</div>-->
<!--</el-descriptions-item>-->
<el-descriptions-item label="业务单号">{{ formData.billNo }}</el-descriptions-item>
<el-descriptions-item label="发货方">{{ formData.shipperName }}</el-descriptions-item>
<el-descriptions-item label="收货方">{{ formData.fromCorpName }}</el-descriptions-item>
<el-descriptions-item label="单据时间">{{ formData.billTime }}</el-descriptions-item>
</el-descriptions>
<el-descriptions :column="7" border style="margin-top: 5px; font-size: 16px">
<el-descriptions-item label="业务单号"><div style="font-size: 15px">{{ formData.billNo }}</div></el-descriptions-item>
<el-descriptions-item label="发货方"><div style="font-size: 15px">{{ formData.shipperName }}</div></el-descriptions-item>
<el-descriptions-item label="收货方"><div style="font-size: 15px">{{ formData.fromCorpName }}</div></el-descriptions-item>
<el-descriptions-item label="单据时间"><div style="font-size: 15px">{{ formData.billTime }}</div></el-descriptions-item>
</el-descriptions>
<!--<div id="qrcode-container" ref="barcodeContainer" style="margin-right: 38px;padding-bottom: 30px"></div>-->
<!--<svg ref="barcodeContainer"></svg>-->
</el-card>
<el-tabs type="border-card" style="margin: 15px" v-model="editableTabsValue" v-show=" formData.billNo != null">
<el-tabs type="border-card" style="margin: 15px" v-model="editableTabsValue" >
<!--<el-tab-pane label="扫码详情" name="prescribeOriginPanel">-->
<prescribeOriginPanel
v-if="panelALive"
:prescribeData="curRow"
></prescribeOriginPanel>
<!-- 在表格下方添加说明 -->
<el-row style="text-align: right;font-size: 12px;margin-top: 10px">
<el-col span="24">
<div style="float: right">
<td>
<div style="background-color: #F56C6C;width: 10px;height: 10px;"></div>
</td>
<td><span style="color: #6d6d6d;"><pre>未赋码 </pre></span></td>
<td>
<div style="background-color: #E6A23C;width: 10px;height: 10px;"></div>
</td>
<td>
<span style="color: #6d6d6d;"><pre>预赋码 </pre></span>
</td>
<td>
<div style="background-color: #67C23A;width: 10px;height: 10px;"></div>
</td>
<td>
<span style="color: #6d6d6d;"><pre>已赋码</pre></span>
</td>
</div>
</el-col>
</el-row>
<!--</el-tab-pane>-->
<!-- <el-tab-pane label="扫码明细">-->
<!-- <PanelOrderManuTagCode-->
@ -1871,6 +1839,10 @@ export default {
}
.custom-input-height {
height: 40px !important; /* 设置高度 */
}
.barcode-wrapper {
display: flex;
flex-direction: column;

@ -112,36 +112,62 @@
<!-- </template>-->
<!--</el-table>-->
<el-table :data="preDetailList" highlight-current-row="true" border ref="multipleTable" :row-style="rowStyle">
<el-table-column label="产品通用名" prop="cpmctymc" width="240"></el-table-column>
<el-table-column label="制剂规格" prop="prepnSpec" width="280"></el-table-column>
<el-table-column label="包装规格" prop="spec" width="100"></el-table-column>
<el-table-column label="单据数量" prop="count" width="80">
<el-table :data="preDetailList" highlight-current-row="true" border ref="multipleTable" size="100"
:row-style="{ height: '60px' }"
:cell-style="{ padding: '0' }"
>
<el-table-column label="赋码状态" prop="cpmctymc" >
<template v-slot="scope">
<div style="text-align: center;">
<el-tag :type="getTagColor(scope.row)" size="26" >
{{ codingStatus }}
</el-tag>
</div>
</template>
</el-table-column>
<el-table-column label="产品通用名" prop="cpmctymc" >
<template v-slot="scope">
<div :style="{ fontSize: '16px' }">{{ scope.row.cpmctymc }}</div>
</template>
</el-table-column>
<el-table-column label="单据数量" prop="count" >
<template v-slot="scope">
<div :style="{ fontSize: '26px' }">{{ scope.row.count }}</div>
</template>
</el-table-column>
<el-table-column label="扫码数量" prop="scanActCount" width="80">
<el-table-column label="扫码数量" prop="scanActCount" >
<template v-slot="scope">
<div :style="{ fontSize: '26px', }">{{ scope.row.scanActCount }}</div>
<div :style="getCellStyle(scope.row)">{{scope.row.scanCount}}/{{ scope.row.shouldCount }}</div>
</template>
</el-table-column>
<el-table-column label="制剂规格" prop="prepnSpec" >
<template v-slot="scope">
<div :style="{ fontSize: '16px' }">{{ scope.row.prepnSpec }}</div>
</template>
</el-table-column>
<el-table-column label="包装规格" prop="spec" >
<template v-slot="scope">
<div :style="{ fontSize: '16px' }">{{ scope.row.spec }}</div>
</template>
</el-table-column>
<!--<el-table-column label="工位库存" prop="tempWorkPlaceCount" width="80">-->
<!-- <template v-slot="scope">-->
<!-- <div :style="{ fontSize: '26px' }">{{ scope.row.tempWorkPlaceCount }}</div>-->
<!-- </template>-->
<!--</el-table-column>-->
<!--<el-table-column label="拆零数量" prop="tempSplitCount" width="80">-->
<!-- <template v-slot="scope">-->
<!-- <div :style="{ fontSize: '26px' }">{{ scope.row.tempSplitCount }}</div>-->
<!-- </template>-->
<!--</el-table-column>-->
<el-table-column label="批次号" prop="batchNo" width="80"></el-table-column>
<!--<el-table-column label="产品标识" prop="nameCode" width="120"></el-table-column>-->
<el-table-column label="医保编码" prop="ybbm" width="240"></el-table-column>
<!--<el-table-column label="产品标识" prop="nameCode" width="120"></el-table-column> fixed="right"-->
<el-table-column label="医保编码" prop="ybbm" width="240">
<template v-slot="scope">
<div :style="{ fontSize: '16px' }">{{ scope.row.ybbm }}</div>
</template>
</el-table-column>
<el-table-column label="批次号" prop="batchNo" >
<template v-slot="scope">
<div :style="{ fontSize: '16px' }">{{ scope.row.batchNo }}</div>
</template>
</el-table-column>
<el-table-column label="操作" width="140" fixed="right">
>
<el-table-column
fixed="right"
label="操作"
width="120">
<template slot-scope="scope">
<el-button type="primary" @click="scanDetail(scope.row)" style="font-size: 14px" :disabled="scope.row.scanCount == null || scope.row.scanCount == 0 ">
扫码明细({{scope.row.scanCount == null ? 0 : scope.row.scanCount }})</el-button>
@ -233,6 +259,7 @@ export default {
countVisible: false,
scanDetailVisible: false,
bizId: null,
codingStatus: '已赋码',
}
},
methods: {
@ -348,6 +375,38 @@ export default {
return rowBackground;
},
getCellStyle(row){
let cellStyle = {
fontSize: '32px'
};
if (row.shouldCount == 0){
cellStyle.fontSize = '30px'
cellStyle.color = '#F56C6C'
return cellStyle;
}
if (row.scanCount < row.shouldCount) {
cellStyle.color = '#F56C6C';
} else if (row.scanCount === row.shouldCount) {
cellStyle.color = '#56a717';
}
return cellStyle;
},
// cellStyle({ row, column, rowIndex, columnIndex }) {
// return { height: '60px' };
// },
getTagColor(row) {
if (row.scanActCount < row.count) {
this.codingStatus = '未赋码'
return 'danger'; //
} else if (row.autoTagStatus == 2) {
this.codingStatus = '预赋码'
return 'warning'; //
} else if (row.scanActCount >= row.count) {
this.codingStatus = '已赋码'
return 'success'; // 绿
}
}
},
@ -379,4 +438,5 @@ export default {
<style scoped>
</style>

@ -22,6 +22,7 @@
<el-col :span="8">
<el-form-item label="往来单位:">
<el-select v-model="filterQuery.fromCorp"
:remote-method="findMethod"
filterable
remote
reserve-keyword
@ -325,6 +326,7 @@ import {
orderPDFFromTemplateFile,
} from "@/api/itextpdf/orderPrint";
import {selectCorpList} from "@/api/basic/basicUnitMaintain";
import { getBasicUnitMaintains } from '@/api/basic/basicUnitMaintain'
const formJson = {
site_id: "",
@ -773,13 +775,34 @@ export default {
this.resultQuery.page = 1;
this.getResultDetailList();
},
findFromInvList(val) {
let cQuery = {};
selectCorpList(cQuery)
// findFromInvList(val) {
// let cQuery = {
// corpType: 4,
// };
// selectCorpList(cQuery)
// .then((response) => {
// this.fromInvOptions = response.data || [];
// })
// .catch(() => {
// });
// },
//
findMethod(query) {
this.fromOptions = [];
let cQuery = {
key: query,
corpType: null,
page: 1,
limit: 20,
};
getBasicUnitMaintains(cQuery)
.then((response) => {
this.fromInvOptions = response.data || [];
this.loading = false;
this.fromInvOptions = response.data.list || [];
})
.catch(() => {
this.loading = false;
});
},
getResultDetailList() {
@ -827,7 +850,7 @@ export default {
},
created() {
this.getInvList();
this.findFromInvList();
// this.findFromInvList();
this.getBusType();
this.getList();
},

@ -12,7 +12,7 @@
<el-button-group
style="display: flex; margin: 0px 0 15px 0; height: 35px;float: right"
>
<el-button size="mini" type="primary" @click="triggerFileUpload2"
<el-button size="mini" type="primary" @click="triggerFileUpload2" icon="el-icon-upload"
>
上传阳采单据
</el-button>
@ -361,7 +361,7 @@
</el-col>
</el-row>
<el-row v-if="viewType != 1">
<el-col :span="20">
<el-col :span="18">
<el-form-item prop="code" label="扫码录入校验:">
<el-input
id="inputer"
@ -374,7 +374,7 @@
></el-input>
</el-form-item>
</el-col>
<el-col :span="2">
<el-col :span="4">
<el-button-group
style="display: flex; height: 35px">
<el-button
@ -389,11 +389,20 @@
size="mini"
@click.native="selectOrder()"
v-if="curAction.checkWebNew != 2 || viewType !=1"
icon="el-icon-document-add"
>下载码上放心追溯码
<!-- v-if="(curAction.checkWebNew !== 2 || viewType !== 1) && orderFormData.billNo"-->
</el-button
>
<el-button
<el-button size="mini" type="primary" @click="triggerFileUpload" icon="el-icon-upload2"
v-if="curAction.checkWebNew != 2 || viewType !=1"
>
导入阳采追溯码
</el-button>
<!-- 隐藏的文件输入元素 -->
<input type="file" ref="fileInput" accept=".xlsx,.xls" style="display: none;" @change="handleFileUpload"/>
<el-button
type="primary"
size="mini"
v-if="curAction.useDyCount == 2"
@ -626,6 +635,7 @@ import {filterNoPage, page, remoteFilter} from "@/api/basic/sicker/skPersonApi";
import {selectSysParamByKey} from "@/api/param/systemParamConfig";
import dialogInvProduct from "@/views/inoutDrug/DialogSelectInvProduct";
import {listPage} from "@/api/basic/workPlace/sysWorkplaceManage";
import store from "@/store";
export default {
name: "ioCreateOrder",
@ -828,9 +838,75 @@ export default {
}
this.selectOrderVisible = true
},
triggerFileUpload() {
this.$refs.fileInput.click();
},
triggerFileUpload2() {
this.$refs.fileInput2.click();
},
handleFileUpload(event) {
const file = event.target.files[0];
const billNo = this.orderFormData.billNo;
const uploadUrl = process.env.VUE_APP_BASE_API + '/udiwms/inout/order/yc/fileUpload';
if (this.$isBlank(this.orderFormData.billNo)) {
this.$message.error("单据编号不可以为空!");
return;
}
if (file) {
const formData = new FormData();
formData.append('billNo', billNo);
formData.append('file', file);
fetch(uploadUrl, {
method: 'POST',
headers: {
ADMIN_ID: store.getters.adminId,
ADMINID: store.getters.adminId,
ADMIN_TOKEN: store.getters.token,
},
body: formData,
})
.then(response => {
if (!response.ok) {
throw new Error(`HTTP error! Status: ${response.status}`);
}
return response.json();
})
.then(data => {
if (data.code === 20000) {
//
if (data.data && data.data.billNo) {
this.orderFormData.billNo = data.data.billNo;
}
//
this.isCodeAlive = false;
this.isBizDetailAlive = false;
this.isCodeDetailAlive = false;
this.$nextTick(() => {
this.isCodeAlive = true;
this.isBizDetailAlive = true;
this.isCodeDetailAlive = true;
this.$refs.inputRef.focus();
this.$refs.inputRef.select();
this.$message.success("上传成功!");
});
} else {
this.$message.error(data.message);
}
})
.catch(error => {
console.error('File upload failed:', error);
this.$message.error('文件上传失败:' + error.message);
});
}
//
event.target.value = '';
},
handleFileUpload2(event) {
const file = event.target.files[0];
const uploadUrl = process.env.VUE_APP_BASE_API + '/udiwms/inout/order/yc/orderFileUpload';
@ -844,6 +920,7 @@ export default {
fetch(uploadUrl, {
method: 'POST',
headers: {
ADMINID: store.getters.adminId,
ADMIN_ID: store.getters.adminId,
ADMIN_TOKEN: store.getters.token,
},

Loading…
Cancel
Save