Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-app-operator-master
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lanbaoming
jiedao-app-operator-master
Commits
946b8b13
Commit
946b8b13
authored
Oct 17, 2022
by
dragondean@qq.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
http://gitlab.jdshangmen.com/jiedao-app/jiedao-app-operator
into dev
parents
56c000d1
b9cd86c2
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
50 additions
and
34 deletions
+50
-34
box.js
src/api/ecw/box.js
+5
-5
index.vue
src/views/ecw/box/ladingBill/index.vue
+17
-13
makeLadingBill.vue
src/views/ecw/box/ladingBill/makeLadingBill.vue
+6
-2
previewBill.vue
src/views/ecw/box/ladingBill/previewBill.vue
+7
-6
utils.js
src/views/ecw/box/shippingSea/utils.js
+15
-8
No files found.
src/api/ecw/box.js
View file @
946b8b13
...
@@ -154,7 +154,7 @@ export function cancelBillService(id) {
...
@@ -154,7 +154,7 @@ export function cancelBillService(id) {
export
function
downloadBillService
(
params
)
{
export
function
downloadBillService
(
params
)
{
return
request
({
return
request
({
url
:
"
/shipment/make-bill-of-lading/download
"
,
url
:
"
/shipment/make-bill-of-lading/download
"
,
responseType
:
"
arraybuffer
"
,
responseType
:
"
blob
"
,
method
:
"
get
"
,
method
:
"
get
"
,
params
,
params
,
});
});
...
@@ -190,7 +190,7 @@ export function getBillService(params) {
...
@@ -190,7 +190,7 @@ export function getBillService(params) {
export
function
zipDownload
(
params
)
{
export
function
zipDownload
(
params
)
{
return
request
({
return
request
({
url
:
"
/shipment/make-bill-of-lading/zipDownload
"
,
url
:
"
/shipment/make-bill-of-lading/zipDownload
"
,
responseType
:
"
arraybuffer
"
,
responseType
:
"
blob
"
,
method
:
"
get
"
,
method
:
"
get
"
,
params
,
params
,
});
});
...
@@ -284,7 +284,7 @@ export function downloadCustomFiles(params) {
...
@@ -284,7 +284,7 @@ export function downloadCustomFiles(params) {
export
function
downloadLoadGoodsList
(
params
)
{
export
function
downloadLoadGoodsList
(
params
)
{
return
request
({
return
request
({
url
:
"
/ecw/box-preload-goods/downloadLoadGoodsList
"
,
url
:
"
/ecw/box-preload-goods/downloadLoadGoodsList
"
,
responseType
:
"
arraybuffer
"
,
responseType
:
"
blob
"
,
method
:
"
get
"
,
method
:
"
get
"
,
params
,
params
,
});
});
...
@@ -294,7 +294,7 @@ export function downloadLoadGoodsList(params) {
...
@@ -294,7 +294,7 @@ export function downloadLoadGoodsList(params) {
export
function
downloadPreloadGoodsList
(
params
)
{
export
function
downloadPreloadGoodsList
(
params
)
{
return
request
({
return
request
({
url
:
"
/ecw/box-preload-goods/downloadPreloadGoodsList
"
,
url
:
"
/ecw/box-preload-goods/downloadPreloadGoodsList
"
,
responseType
:
"
arraybuffer
"
,
responseType
:
"
blob
"
,
method
:
"
get
"
,
method
:
"
get
"
,
params
,
params
,
});
});
...
@@ -304,7 +304,7 @@ export function downloadPreloadGoodsList(params) {
...
@@ -304,7 +304,7 @@ export function downloadPreloadGoodsList(params) {
export
function
downloadReceivableList
(
params
)
{
export
function
downloadReceivableList
(
params
)
{
return
request
({
return
request
({
url
:
"
/ecw/box-preload-goods/downloadReceivableList
"
,
url
:
"
/ecw/box-preload-goods/downloadReceivableList
"
,
responseType
:
"
arraybuffer
"
,
responseType
:
"
blob
"
,
method
:
"
get
"
,
method
:
"
get
"
,
params
,
params
,
});
});
...
...
src/views/ecw/box/ladingBill/index.vue
View file @
946b8b13
...
@@ -89,7 +89,6 @@ import {
...
@@ -89,7 +89,6 @@ import {
makeBillService
,
makeBillService
,
getBillService
,
getBillService
,
deleteBillService
,
deleteBillService
,
zipDownload
,
}
from
"
@/api/ecw/box
"
;
}
from
"
@/api/ecw/box
"
;
import
{
import
{
getTotlContent
,
getTotlContent
,
...
@@ -98,7 +97,6 @@ import {
...
@@ -98,7 +97,6 @@ import {
}
from
"
../shippingSea/utils
"
;
}
from
"
../shippingSea/utils
"
;
import
makeLadingBill
from
"
./makeLadingBill.vue
"
;
import
makeLadingBill
from
"
./makeLadingBill.vue
"
;
import
previewBill
from
"
./previewBill.vue
"
;
import
previewBill
from
"
./previewBill.vue
"
;
import
FileSaver
from
"
file-saver
"
;
export
default
{
export
default
{
name
:
"
ladingBill
"
,
name
:
"
ladingBill
"
,
...
@@ -145,11 +143,14 @@ export default {
...
@@ -145,11 +143,14 @@ export default {
/* const title = `查看提单 ${this.shipmentObj.selfNo ?? ""} 柜号:${
/* const title = `查看提单 ${this.shipmentObj.selfNo ?? ""} 柜号:${
this.shipmentObj.cubNo ?? ""
this.shipmentObj.cubNo ?? ""
} 柜型:${cabinetLabel}`; */
} 柜型:${cabinetLabel}`; */
const
title
=
this
.
$t
(
'
查看提单 {selfNo} 柜号:{cubNo} 柜型:{cabinetLabel}
'
,
{
const
title
=
this
.
$t
(
"
查看提单 {selfNo} 柜号:{cubNo} 柜型:{cabinetLabel}
"
,
{
selfNo
:
this
.
shipmentObj
.
selfNo
,
selfNo
:
this
.
shipmentObj
.
selfNo
,
cubNo
:
this
.
shipmentObj
.
cubNo
,
cubNo
:
this
.
shipmentObj
.
cubNo
,
cabinetLabel
cabinetLabel
,
})
}
);
this
.
$set
(
this
.
dialogCfg
,
"
title
"
,
title
);
this
.
$set
(
this
.
dialogCfg
,
"
title
"
,
title
);
},
},
closeDialog
(
type
)
{
closeDialog
(
type
)
{
...
@@ -182,7 +183,7 @@ export default {
...
@@ -182,7 +183,7 @@ export default {
downloadFile
(
downloadFile
(
type
,
type
,
{
shipmentId
:
this
.
shipmentObj
.
id
},
{
shipmentId
:
this
.
shipmentObj
.
id
},
this
.
$t
(
'
已装单
'
)
+
`(
${
this
.
shipmentObj
.
selfNo
}
).xlsx`
,
this
.
$t
(
"
已装单
"
)
+
`(
${
this
.
shipmentObj
.
selfNo
}
).xlsx`
,
"
xlsx
"
"
xlsx
"
);
);
return
;
return
;
...
@@ -190,7 +191,7 @@ export default {
...
@@ -190,7 +191,7 @@ export default {
downloadFile
(
downloadFile
(
type
,
type
,
{
shipmentId
:
this
.
shipmentObj
.
id
},
{
shipmentId
:
this
.
shipmentObj
.
id
},
this
.
$t
(
'
应收汇总表
'
)
+
`(
${
this
.
shipmentObj
.
selfNo
}
).xlsx`
,
this
.
$t
(
"
应收汇总表
"
)
+
`(
${
this
.
shipmentObj
.
selfNo
}
).xlsx`
,
"
xlsx
"
"
xlsx
"
);
);
return
;
return
;
...
@@ -220,14 +221,17 @@ export default {
...
@@ -220,14 +221,17 @@ export default {
this
.
currData
=
{
this
.
currData
=
{
billContent
:
data
?.
billContent
??
""
,
billContent
:
data
?.
billContent
??
""
,
orderNo
:
this
.
currRow
.
orderNo
,
orderNo
:
this
.
currRow
.
orderNo
,
bpmProcessId
:
data
.
bpmProcessId
,
};
};
});
});
},
},
clickZipDownload
()
{
clickZipDownload
()
{
zipDownload
({
shipmentId
:
this
.
shipmentObj
.
id
}).
then
((
res
)
=>
{
downloadFile
(
let
blob
=
new
Blob
([
res
],
{
type
:
"
application/zip
"
});
"
zipDownload
"
,
FileSaver
.
saveAs
(
blob
,
this
.
$t
(
'
打包文件
'
)
+
"
.zip
"
);
{
shipmentId
:
this
.
shipmentObj
.
id
},
});
this
.
$t
(
"
打包文件
"
)
+
"
.zip
"
,
"
zip
"
);
},
},
},
},
computed
:
{
computed
:
{
...
...
src/views/ecw/box/ladingBill/makeLadingBill.vue
View file @
946b8b13
...
@@ -14,7 +14,7 @@
...
@@ -14,7 +14,7 @@
<work-flow
xmlkey=
"bill_lading"
v-model=
"selectedUsers"
></work-flow>
<work-flow
xmlkey=
"bill_lading"
v-model=
"selectedUsers"
></work-flow>
</div>
</div>
<div
v-if=
"currRow.status === 1"
>
<div
v-if=
"currRow.status === 1"
>
<el-button
type=
"primary"
disabled
>
{{
$t
(
'
审核中
'
)
}}
</el-button>
<el-button
type=
"primary"
@
click=
"jumpReviewDetail"
>
{{
$t
(
'
审核中
'
)
}}
</el-button>
<el-button
plain
type=
"primary"
@
click=
"canclAudit"
>
{{
$t
(
'
取消审核
'
)
}}
</el-button>
<el-button
plain
type=
"primary"
@
click=
"canclAudit"
>
{{
$t
(
'
取消审核
'
)
}}
</el-button>
<el-button
plain
type=
"primary"
@
click=
"showLoaingTemplate"
>
{{
$t
(
'
提单预览
'
)
}}
</el-button>
<el-button
plain
type=
"primary"
@
click=
"showLoaingTemplate"
>
{{
$t
(
'
提单预览
'
)
}}
</el-button>
</div>
</div>
...
@@ -38,7 +38,7 @@ import {
...
@@ -38,7 +38,7 @@ import {
updateBillService
,
updateBillService
,
cancelBillService
,
cancelBillService
,
}
from
"
@/api/ecw/box
"
;
}
from
"
@/api/ecw/box
"
;
import
{
serviceMsg
}
from
"
../shippingSea/utils
"
;
import
{
serviceMsg
,
toReviewDetail
}
from
"
../shippingSea/utils
"
;
import
previewBill
from
"
./previewBill.vue
"
;
import
previewBill
from
"
./previewBill.vue
"
;
import
{
getToken
}
from
"
@/utils/auth
"
;
import
{
getToken
}
from
"
@/utils/auth
"
;
...
@@ -200,6 +200,10 @@ export default {
...
@@ -200,6 +200,10 @@ export default {
close
(
type
)
{
close
(
type
)
{
this
.
$emit
(
"
closeDialog
"
,
type
);
this
.
$emit
(
"
closeDialog
"
,
type
);
},
},
jumpReviewDetail
()
{
const
{
bpmProcessId
}
=
this
.
currData
;
toReviewDetail
.
apply
(
this
,
[
bpmProcessId
]);
},
},
},
watch
:
{
watch
:
{
currData
:
{
currData
:
{
...
...
src/views/ecw/box/ladingBill/previewBill.vue
View file @
946b8b13
...
@@ -9,9 +9,8 @@
...
@@ -9,9 +9,8 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
{
downloadBillService
}
from
"
@/api/ecw/box
"
;
import
lodop
from
"
@/utils/lodop
"
;
import
lodop
from
"
@/utils/lodop
"
;
import
FileSaver
from
"
file-saver
"
;
import
{
downloadFile
}
from
"
../shippingSea/utils
"
;
export
default
{
export
default
{
name
:
"
previewBill
"
,
name
:
"
previewBill
"
,
...
@@ -22,10 +21,12 @@ export default {
...
@@ -22,10 +21,12 @@ export default {
},
},
methods
:
{
methods
:
{
download
()
{
download
()
{
downloadBillService
({
id
:
this
.
currRow
.
id
}).
then
((
res
)
=>
{
downloadFile
(
let
blob
=
new
Blob
([
res
],
{
type
:
"
application/pdf
"
});
"
downloadBillService
"
,
FileSaver
.
saveAs
(
blob
,
this
.
currRow
.
orderNo
+
"
.pdf
"
);
{
id
:
this
.
currRow
.
id
},
});
this
.
currRow
.
orderNo
+
"
.pdf
"
,
"
pdf
"
);
},
},
print
()
{
print
()
{
lodop
()
lodop
()
...
...
src/views/ecw/box/shippingSea/utils.js
View file @
946b8b13
...
@@ -1510,15 +1510,22 @@ function toReviewDetail(bpmProcessId) {
...
@@ -1510,15 +1510,22 @@ function toReviewDetail(bpmProcessId) {
function downloadFile(funName, params, fileName, fileFormat) {
function downloadFile(funName, params, fileName, fileFormat) {
_BOX[funName](params).then((res) => {
_BOX[funName](params).then((res) => {
const reader = new FileReader();
reader.onload = (event) => {
try {
try {
let jsonData = JSON.parse(res);
// 将读取的string转换为json
if (jsonData.code === 0) {
// 若果能转换成功 => 接口返回的是json数据,提示报错信息
window.ElementUI.$message.success("操作成功");
const json = JSON.parse(event.target.result);
if (json.code) {
window.ElementUI.Message.error(json.msg);
}
}
} catch (erro
r) {
} catch (er
r) {
let blob = new Blob([res], { type: `
application
/
$
{
fileFormat
}
` });
let blob = new Blob([res], { type: `
application
/
$
{
fileFormat
}
` });
FileSaver.saveAs(blob, fileName);
FileSaver.saveAs(blob, fileName);
}
}
};
reader.readAsText(res);
});
});
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment