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:
commit
c72b0377c8
@ -479,6 +479,10 @@ export default {
|
|||||||
if (valid) {
|
if (valid) {
|
||||||
if (this.form.id != null) {
|
if (this.form.id != null) {
|
||||||
this.form.company=this.form.customerName;
|
this.form.company=this.form.customerName;
|
||||||
|
//salesSupport 数据转换
|
||||||
|
if(this.form.salesSupport==""){
|
||||||
|
this.form.salesSupport=" ";
|
||||||
|
}
|
||||||
editMonthUser(this.form).then(response => {
|
editMonthUser(this.form).then(response => {
|
||||||
this.$modal.msgSuccess("修改成功");
|
this.$modal.msgSuccess("修改成功");
|
||||||
this.$emit("on-changed");
|
this.$emit("on-changed");
|
||||||
|
|||||||
@ -78,7 +78,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
plain
|
plain
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="getList"
|
@click="handleExport"
|
||||||
>导出</el-button>
|
>导出</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</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="scanSiteName" min-width="100" />
|
||||||
<el-table-column :label="$t('扫描票数')" align="center" prop="scanCount" min-width="150" />
|
<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="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">
|
<template slot-scope="scope">
|
||||||
<span>{{ (scope.row.scanCount - scope.row.signCount) }}</span>
|
<span>{{ (scope.row.scanCount - scope.row.signCount) }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</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">
|
<template slot-scope="scope">
|
||||||
<span>{{ ((scope.row.signCount / scope.row.scanCount) * 100).toFixed(2) + '%' }}</span>
|
<span>{{ ((scope.row.signCount / scope.row.scanCount) * 100).toFixed(2) + '%' }}</span>
|
||||||
</template>
|
</template>
|
||||||
@ -216,16 +216,7 @@ export default {
|
|||||||
/** 查询统计信息 */
|
/** 查询统计信息 */
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
console.log("---->this.queryParams,", this.dateTimeRange);
|
this.tempQueryParams = this.initQueryParams(this.queryParams);
|
||||||
|
|
||||||
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};
|
|
||||||
queryStatList(this.tempQueryParams).then(response => {
|
queryStatList(this.tempQueryParams).then(response => {
|
||||||
if(!response ||response.code != 200){
|
if(!response ||response.code != 200){
|
||||||
this.$modal.msgError(response && response.msg || "未知错误")
|
this.$modal.msgError(response && response.msg || "未知错误")
|
||||||
@ -288,7 +279,18 @@ export default {
|
|||||||
this.queryParams.isAsc = column.order;
|
this.queryParams.isAsc = column.order;
|
||||||
this.getList();
|
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() {
|
handleExport() {
|
||||||
const loadingInstance = this.$loading({
|
const loadingInstance = this.$loading({
|
||||||
@ -304,7 +306,7 @@ export default {
|
|||||||
qExportParam.pageNum=1;
|
qExportParam.pageNum=1;
|
||||||
qExportParam.pageSize=5000;
|
qExportParam.pageSize=5000;
|
||||||
|
|
||||||
listEmisWaybill(qExportParam).then(response => {
|
queryStatList(qExportParam).then(response => {
|
||||||
if (response.code === 200) {
|
if (response.code === 200) {
|
||||||
this.exportData(response.rows,loadingInstance);
|
this.exportData(response.rows,loadingInstance);
|
||||||
}
|
}
|
||||||
@ -321,7 +323,7 @@ export default {
|
|||||||
excel.export_json_to_excel({
|
excel.export_json_to_excel({
|
||||||
header: tHeader,
|
header: tHeader,
|
||||||
data,
|
data,
|
||||||
filename: '统计',
|
filename: '签收异常对比统计',
|
||||||
autoWidth: true
|
autoWidth: true
|
||||||
})
|
})
|
||||||
loadingInstance.close()
|
loadingInstance.close()
|
||||||
@ -337,59 +339,11 @@ export default {
|
|||||||
if (j === 'kjlx') {
|
if (j === 'kjlx') {
|
||||||
return v['sendSiteName']+'--'+v['dispatchUnderlingSiteName'];
|
return v['sendSiteName']+'--'+v['dispatchUnderlingSiteName'];
|
||||||
}
|
}
|
||||||
if (j === 'fjr') {
|
if(j==='unSignCount'){
|
||||||
return v['sendName']+'--'+v['receiveName'];
|
return v['scanCount']-v['signCount'];
|
||||||
}
|
}
|
||||||
if (j === 'sendMobile') {
|
if(j==='signRate'){
|
||||||
return "";
|
return ((v['signCount'] / v['scanCount']) * 100).toFixed(2) + '%';
|
||||||
}
|
|
||||||
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]);
|
|
||||||
}
|
}
|
||||||
return v[j]
|
return v[j]
|
||||||
}))
|
}))
|
||||||
|
|||||||
@ -955,6 +955,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
this.queryParams.billCode = this.$route.query.billCode;
|
||||||
if(this.$route.query.action=='queryByCredit'){
|
if(this.$route.query.action=='queryByCredit'){
|
||||||
|
|
||||||
if(this.$route.query.custNo!=null){
|
if(this.$route.query.custNo!=null){
|
||||||
|
|||||||
@ -1,11 +1,21 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="app-container">
|
<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"> -->
|
<!-- <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-row :gutter="20">
|
||||||
<el-col :span="8">
|
<el-col :span="24">
|
||||||
<el-form-item label="上传图片" prop="xxx" label-width="80px">
|
<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"></i>
|
||||||
|
</el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row >
|
</el-row >
|
||||||
@ -50,7 +60,11 @@
|
|||||||
<el-table-column type="selection" width="55" align="center" />
|
<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('运单编号')" 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="createSite" min-width="100" />
|
||||||
<el-table-column :label="$t('上传人')" align="center" prop="createBy" 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">
|
<el-table-column :label="$t('大小')" align="center" prop="volumeWeight" min-width="100">
|
||||||
@ -124,24 +138,26 @@ export default {
|
|||||||
getList(){
|
getList(){
|
||||||
|
|
||||||
},
|
},
|
||||||
async handleInput(item, size){
|
async handleInput() {
|
||||||
if(item.trim() == ""){
|
if (this.form.billCode == "" || this.form.billCode == null) {
|
||||||
|
this.$modal.msgError("请先输入单号!");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
let scList = item.trim().split(/[;\;\,\,\n]/)||[];
|
let billCode = this.form.billCode + '';
|
||||||
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)
|
let response = await getWaybillDetail(billCode)
|
||||||
if (!response || response.code != 200) {
|
if (!response || response.code != 200) {
|
||||||
this.$modal.msgError(response && response.msg || "未知错误");
|
this.$modal.msgError(response && response.msg || "未知错误");
|
||||||
this.form.picUrl = [];
|
this.form.picUrl = [];
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (response.data.blFormalWaybill === "0") {
|
||||||
|
this.$modal.msgError("运单号无效");
|
||||||
|
this.form.picUrl = [];
|
||||||
|
return;
|
||||||
|
}
|
||||||
let record = {};
|
let record = {};
|
||||||
record.billCode = billCode;
|
record.billCode = billCode;
|
||||||
record.fileUrl=scList[s];
|
record.fileUrl=this.form.picUrl+'';
|
||||||
record.createSite = this.$store.getters.ownerSiteName;
|
record.createSite = this.$store.getters.ownerSiteName;
|
||||||
record.createBy = this.$store.getters.empName;
|
record.createBy = this.$store.getters.empName;
|
||||||
record.signManCode = this.$store.getters.empCode;
|
record.signManCode = this.$store.getters.empCode;
|
||||||
@ -150,19 +166,18 @@ export default {
|
|||||||
record.fileName = "签收底单";
|
record.fileName = "签收底单";
|
||||||
record.attachType = "2";
|
record.attachType = "2";
|
||||||
record.dataFrom = "pc";
|
record.dataFrom = "pc";
|
||||||
for(let name in size){
|
record.fileSiez=-1;
|
||||||
if(name.indexOf(billCode) > -1){
|
|
||||||
record.fileSiez = parseFloat((size[name]/1024).toFixed(2));
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
let indexBillCode = billCode;
|
let indexBillCode = billCode;
|
||||||
this.dataMap[indexBillCode] = record;
|
this.dataMap[indexBillCode] = record;
|
||||||
this.emisTmsScanRecordList.push(record);
|
this.emisTmsScanRecordList.push(record);
|
||||||
};
|
|
||||||
},
|
},
|
||||||
/** 上传按钮操作 */
|
/** 上传按钮操作 */
|
||||||
handleScanUpload(){
|
handleScanUpload(){
|
||||||
|
if(!this.selection){
|
||||||
|
this.$modal.msgError("请先上传图片!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
var selData = this.selection;
|
var selData = this.selection;
|
||||||
selData.forEach(item=>{
|
selData.forEach(item=>{
|
||||||
addEmisWaybillAttachment(item).then(response => {
|
addEmisWaybillAttachment(item).then(response => {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user