Merge pull request 'develop' (#230) from develop into master

Reviewed-on: http://git.xdadan.loc/tanex/emis-frontend/pulls/230
This commit is contained in:
wuteng 2026-04-10 17:36:38 +08:00
commit c72b0377c8
4 changed files with 80 additions and 106 deletions

View File

@ -479,6 +479,10 @@ export default {
if (valid) {
if (this.form.id != null) {
this.form.company=this.form.customerName;
//salesSupport 数据转换
if(this.form.salesSupport==""){
this.form.salesSupport=" ";
}
editMonthUser(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.$emit("on-changed");

View File

@ -78,7 +78,7 @@
type="primary"
plain
size="mini"
@click="getList"
@click="handleExport"
>导出</el-button>
</el-col>
</el-row>
@ -87,12 +87,12 @@
<el-table-column :label="$t('网点名称')" align="center" prop="scanSiteName" min-width="100" />
<el-table-column :label="$t('扫描票数')" align="center" prop="scanCount" min-width="150" />
<el-table-column :label="$t('已签收票数')" align="center" prop="signCount" min-width="150" />
<el-table-column :label="$t('未签收票数')" align="center" prop="destName" min-width="150">
<el-table-column :label="$t('未签收票数')" align="center" prop="unSignCount" min-width="150">
<template slot-scope="scope">
<span>{{ (scope.row.scanCount - scope.row.signCount) }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('签收率')" align="center" prop="registerSite" min-width="100">
<el-table-column :label="$t('签收率')" align="center" prop="signRate" min-width="100">
<template slot-scope="scope">
<span>{{ ((scope.row.signCount / scope.row.scanCount) * 100).toFixed(2) + '%' }}</span>
</template>
@ -216,16 +216,7 @@ export default {
/** 查询统计信息 */
getList() {
this.loading = true;
console.log("---->this.queryParams,", this.dateTimeRange);
if (null != this.dateTimeRange && '' != this.dateTimeRange) {
this.queryParams.params.beginScanDate = dateToStr(this.dateTimeRange[0]);
this.queryParams.params.endScanDate = dateToStr(this.dateTimeRange[1]);
}else{
this.queryParams.params.beginScanDate = null;
this.queryParams.params.endScanDate = null;
}
this.tempQueryParams = {...this.queryParams};
this.tempQueryParams = this.initQueryParams(this.queryParams);
queryStatList(this.tempQueryParams).then(response => {
if(!response ||response.code != 200){
this.$modal.msgError(response && response.msg || "未知错误")
@ -288,7 +279,18 @@ export default {
this.queryParams.isAsc = column.order;
this.getList();
},
initQueryParams(){
let qParam=null;
if (null != this.dateTimeRange && '' != this.dateTimeRange) {
this.queryParams.params.beginScanDate = dateToStr(this.dateTimeRange[0]);
this.queryParams.params.endScanDate = dateToStr(this.dateTimeRange[1]);
}else{
this.queryParams.params.beginScanDate = null;
this.queryParams.params.endScanDate = null;
}
qParam={...this.queryParams};
return qParam;
},
/** 导出按钮操作 */
handleExport() {
const loadingInstance = this.$loading({
@ -304,7 +306,7 @@ export default {
qExportParam.pageNum=1;
qExportParam.pageSize=5000;
listEmisWaybill(qExportParam).then(response => {
queryStatList(qExportParam).then(response => {
if (response.code === 200) {
this.exportData(response.rows,loadingInstance);
}
@ -321,7 +323,7 @@ export default {
excel.export_json_to_excel({
header: tHeader,
data,
filename: '统计',
filename: '签收异常对比统计',
autoWidth: true
})
loadingInstance.close()
@ -337,59 +339,11 @@ export default {
if (j === 'kjlx') {
return v['sendSiteName']+'--'+v['dispatchUnderlingSiteName'];
}
if (j === 'fjr') {
return v['sendName']+'--'+v['receiveName'];
if(j==='unSignCount'){
return v['scanCount']-v['signCount'];
}
if (j === 'sendMobile') {
return "";
}
if (j === 'paymentStatus') {
return this.selectDictLabel(this.dict.type.emis_payment_status,v[j]);
}
if (j === 'pickupMethod') {
return this.selectDictLabel(this.dict.type.emis_qujian_fangshi,v[j]);
}
if (j === 'customsEclaration') {
return this.selectDictLabel(this.dict.type.emis_declare_mode,v[j]);
}
if (j === 'customsClear') {
return this.selectDictLabel(this.dict.type.emis_customs_clear,v[j]);
}
if (j === 'packType') {
return this.selectDictLabels(this.dict.type.emis_tab_packing_type,v[j]);
}
if (j === 'dispatchMethod') {
if(v[j] == 1){
return '派送';
}else{
return '自提';
}
}
if (j === 'blMessage') {
if(v[j] == 1){
return '发送';
}else{
return '不发送';
}
}
if (j === 'blAcceptMessage') {
if(v[j] == 1){
return '发送';
}else{
return '不发送';
}
}
if (j === 'blSign') {
if(v[j] == 1){
return '已签收';
}else{
return '未签收';
}
}
if (j === 'paymentType') {
return this.selectDictLabel(this.dict.type.emis_payment_type,v[j]);
if(j==='signRate'){
return ((v['signCount'] / v['scanCount']) * 100).toFixed(2) + '%';
}
return v[j]
}))

View File

@ -955,6 +955,7 @@ export default {
}
},
created() {
this.queryParams.billCode = this.$route.query.billCode;
if(this.$route.query.action=='queryByCredit'){
if(this.$route.query.custNo!=null){
@ -992,7 +993,7 @@ export default {
this.queryOrderType="1";
this.queryOrderDateType="1";
// this.queryExpireNotSign="1"
this.getList();
}
},

View File

@ -1,11 +1,21 @@
<template>
<div class="app-container">
<el-form ref="form" size="mini" :model="form" label-width="80px">
<el-form ref="form" size="mini" :model="form" label-width="80px" @submit.native.prevent>
<!-- <SearchForm :ref="form" :model="picUrl" ref="queryForm" size="small" :maxShow="8" label-width="100px" v-show="showSearch" @search="getList" @reset="resetQuery"> -->
<el-row :gutter="20">
<el-col :span="8">
<el-col :span="24">
<el-form-item label="上传图片" prop="xxx" label-width="80px">
<ImageUpload ref="imageUpload" v-model="form.picUrl" :fileSize="1" :limit="80" @input="handleInput" ></ImageUpload>
<ImageUpload ref="imageUpload" v-model="form.picUrl" :fileSize="1" :limit="80"></ImageUpload>
</el-form-item>
</el-col>
<el-col :span="7">
<el-form-item label="运单号" prop="billCode" label-width="70px">
<span slot="label">
<span style="color: red">运单号</span>
</span>
<el-input v-model="form.billCode" clearable="" placeholder="单号输入后按回车" @keyup.enter.native="handleInput" >
<i slot="suffix" class="iconfont">&#xe656;</i>
</el-input>
</el-form-item>
</el-col>
</el-row >
@ -50,7 +60,11 @@
<el-table-column type="selection" width="55" align="center" />
<el-table-column :label="$t('运单编号')" align="center" prop="billCode" min-width="150" />
<el-table-column :label="$t('图片URL')" align="center" prop="fileUrl" min-width="100" />
<el-table-column :label="$t('图片URL')" align="center" prop="fileUrl" min-width="100" >
<template slot-scope="scope">
<ImagePreview height="50px" v-for="pic in (scope.row.fileUrl||'').split(',')" :key="pic" :src="pic" ></ImagePreview>
</template>
</el-table-column>
<el-table-column :label="$t('上传网点')" align="center" prop="createSite" min-width="100" />
<el-table-column :label="$t('上传人')" align="center" prop="createBy" min-width="100" />
<el-table-column :label="$t('大小')" align="center" prop="volumeWeight" min-width="100">
@ -124,45 +138,46 @@ export default {
getList(){
},
async handleInput(item, size){
if(item.trim() == ""){
async handleInput() {
if (this.form.billCode == "" || this.form.billCode == null) {
this.$modal.msgError("请先输入单号!");
return;
}
let scList = item.trim().split(/[;\;\,\,\n]/)||[];
this.form.picUrl =[];
for(let s = 0; s<scList.length; s++){
let billCode = this.extractSubstring(scList[s]);
if(this.dataMap[billCode]) return;
let response = await getWaybillDetail(billCode)
if(!response || response.code != 200){
this.$modal.msgError(response && response.msg || "未知错误");
this.form.picUrl =[];
return;
}
let record = {};
record.billCode=billCode;
record.fileUrl=scList[s];
record.createSite=this.$store.getters.ownerSiteName;
record.createBy=this.$store.getters.empName;
record.signManCode=this.$store.getters.empCode;
record.createTime=getDateTimeToString(new Date());
record.remark = "";
record.fileName="签收底单";
record.attachType="2";
record.dataFrom="pc";
for(let name in size){
if(name.indexOf(billCode) > -1){
record.fileSiez = parseFloat((size[name]/1024).toFixed(2));
break;
}
}
let indexBillCode=billCode;
this.dataMap[indexBillCode]=record;
let billCode = this.form.billCode + '';
let response = await getWaybillDetail(billCode)
if (!response || response.code != 200) {
this.$modal.msgError(response && response.msg || "未知错误");
this.form.picUrl = [];
return;
}
if (response.data.blFormalWaybill === "0") {
this.$modal.msgError("运单号无效");
this.form.picUrl = [];
return;
}
let record = {};
record.billCode = billCode;
record.fileUrl=this.form.picUrl+'';
record.createSite = this.$store.getters.ownerSiteName;
record.createBy = this.$store.getters.empName;
record.signManCode = this.$store.getters.empCode;
record.createTime = getDateTimeToString(new Date());
record.remark = "";
record.fileName = "签收底单";
record.attachType = "2";
record.dataFrom = "pc";
record.fileSiez=-1;
let indexBillCode = billCode;
this.dataMap[indexBillCode] = record;
this.emisTmsScanRecordList.push(record);
};
},
/** 上传按钮操作 */
handleScanUpload(){
if(!this.selection){
this.$modal.msgError("请先上传图片!");
return;
}
var selData = this.selection;
selData.forEach(item=>{
addEmisWaybillAttachment(item).then(response => {