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
70f87732
Commit
70f87732
authored
Nov 05, 2023
by
我在何方
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
http://gitlab.jdshangmen.com/jiedao-app/jiedao-app-operator
into dev
parents
5e389c7e
a69f5aa6
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
470 additions
and
91 deletions
+470
-91
index.vue
src/components/RoutersSelector/index.vue
+9
-1
regError.vue
src/views/ecw/box/regError.vue
+10
-8
shippingAir.vue
src/views/ecw/box/shippingAir/shippingAir.vue
+5
-2
utils.js
src/views/ecw/box/shippingAir/utils.js
+304
-0
edit.vue
src/views/ecw/order/edit.vue
+42
-0
batchEdit.vue
src/views/ecw/productPrice/batchEdit.vue
+80
-79
edit.vue
src/views/ecw/productPrice/edit.vue
+20
-1
No files found.
src/components/RoutersSelector/index.vue
View file @
70f87732
...
...
@@ -233,7 +233,12 @@ export default {
},
// 显示的路线发生变化之后,清空已勾选的路线
filteredRouterList
(){
if
(
this
.
inited
)
this
.
selectedRoutes
=
[]
if
(
this
.
inited
){
this
.
selectedRoutes
=
[]
Object
.
keys
(
this
.
groupChecker
).
forEach
(
key
=>
{
this
.
groupChecker
[
key
]
=
false
})
}
}
},
async
created
(){
...
...
@@ -254,6 +259,9 @@ export default {
if
(
this
.
showAttr
){
this
.
getAttrList
()
}
await
this
.
$nextTick
()
this
.
inited
=
true
},
methods
:{
getAttrList
(){
...
...
src/views/ecw/box/regError.vue
View file @
70f87732
<
template
>
<div
class=
"shippingSea-dialog"
>
<el-form
ref=
"errorForm"
:model=
"errorObj"
label-width=
"140px"
>
<el-form-item
:label=
"$t('操作步骤')"
>
<el-form-item
:label=
"$t('操作步骤')"
:rules=
"[
{required: true,message: this.$t('操作步骤必填'),trigger: 'blur'}]" prop="opStep"
>
<el-select
v-model=
"errorObj.opStep"
:placeholder=
"$t('请选择操作步骤')"
>
<el-option
v-for=
"type in this.getDictDatas(DICT_TYPE[this.process])"
:key=
"type.value"
:label=
"$l(type, 'label')"
:value=
"type.value"
></el-option>
</el-select>
...
...
@@ -9,7 +9,7 @@
<el-option
v-for=
"type in this.getDictDatas(DICT_TYPE.BOX_SEA_AIR)"
:key=
"type.value"
:label=
"$l(type, 'label')"
:value=
"type.value"
></el-option>
</el-select>
-->
</el-form-item>
<el-form-item
:label=
"$t('票异常')"
>
<el-form-item
:label=
"$t('票异常')"
:rules=
"[
{required: true,message: this.$t('票异常必填'),trigger: 'blur'}]" prop="billAbnId"
>
<el-select
v-model=
"errorObj.billAbnId"
:placeholder=
"$t('请选择票异常')"
>
<el-option
v-for=
"type in this.getDictDatas(DICT_TYPE.BOX_SHIPPING_TICKET_EXCEPTION)"
:key=
"type.value"
:label=
"$l(type, 'label')"
:value=
"type.value"
></el-option>
</el-select>
...
...
@@ -91,12 +91,13 @@ export default {
}
},
created
()
{
const
{
currNode
}
=
this
.
$attrs
;
this
.
errorObj
=
{
opStep
:
currNode
?.
dataKey
??
undefined
};
console
.
log
(
currNode
,
this
.
errorObj
.
opStep
)
if
(
this
.
$attrs
.
shipmentObj
.
bosType
==
"
seaAir
"
)
{
this
.
flag
=
"
seaAir
"
;
}
// console.log(this.$attrs,'this.$attrs');
// const { currNode } = this.$attrs;
// this.errorObj = { opStep: currNode?.dataKey ?? undefined };
// console.log(currNode, this.errorObj.opStep)
// if (this.$attrs.shipmentObj.bosType == "seaAir") {
// this.flag = "seaAir";
// }
},
watch
:
{
// 异常开始时间
...
...
@@ -123,6 +124,7 @@ export default {
/** 提交 */
onSubmit
()
{
this
.
$refs
[
"
errorForm
"
].
validate
((
valid
)
=>
{
console
.
log
(
valid
,
'
valid
'
)
if
(
valid
)
{
abnormalCreate
({
...
this
.
errorObj
,
...
...
src/views/ecw/box/shippingAir/shippingAir.vue
View file @
70f87732
...
...
@@ -46,8 +46,7 @@ import { listUser } from "@/api/system/user";
import
{
getLadingShipperPage
}
from
"
@/api/ecw/ladingShipper
"
;
// 这里引入的数据切换语言后要刷新才生效,优化办法是label同时配备labelEn字段,然后再页面上用$l函数调用
import
{
airBaseData
}
from
"
./utils
"
;
import
{
airOneData
}
from
"
./utils
"
;
import
{
airBaseData
,
airOneData
,
airNextData
}
from
"
./utils
"
;
/**
* 海运操作主页面
*/
...
...
@@ -64,6 +63,7 @@ export default {
return
{
airBaseData
,
airOneData
,
airNextData
,
shipmentObj
:
{},
warehouseList
:
[],
// 供应商
...
...
@@ -127,6 +127,9 @@ export default {
if
(
this
.
shipmentObj
.
destinationClearance
==
3
&&
this
.
shipmentObj
.
deliveryType
==
2
){
this
.
seaBaseData
=
this
.
airOneData
()
}
if
(
this
.
shipmentObj
.
destinationClearance
==
2
){
this
.
seaBaseData
=
this
.
airNextData
()
}
this
.
flag
=
true
});
},
...
...
src/views/ecw/box/shippingAir/utils.js
View file @
70f87732
...
...
@@ -572,6 +572,309 @@ function airOneData() {
];
}
/**
* 目的港清关=我司&合作方清关流程
*
* @return {*}
*/
function
airNextData
()
{
return
[
[
{
title
:
i18n
.
$t
(
"
订舱
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/dc-start.png
"
),
end
:
require
(
"
@/assets/images/shipping/dc-end.png
"
),
},
type
:
"
booking
"
,
// 类型
dataKey
:
"
1
"
,
// 字典数据键值
/**
* 订舱状态:11、未订舱;12、已订舱
*/
voName
:
"
bookAirInfo
"
,
// 订舱对象vo
keyName
:
"
bkStatus
"
,
status
:
{
start
:
[
11
],
wait
:
[],
end
:
[
12
],
},
},
],
[
{
title
:
i18n
.
$t
(
"
分拣
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/yz-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/yz-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/yz-end.png
"
),
},
type
:
"
preinstall
"
,
dataKey
:
"
2
"
,
// 字典数据键值
/**
* 预装状态:21、未预装;22、预装中;23、预装审核中;24、预装审核失败;25、预装审核成功
*/
voName
:
"
preInstallInfo
"
,
keyName
:
"
prStatus
"
,
status
:
{
start
:
[
21
],
wait
:
[
22
,
23
,
24
],
end
:
[
25
],
},
}
],
[
{
title
:
i18n
.
$t
(
"
理货
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/lh-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/lh-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/lh-end.png
"
),
},
type
:
"
tally
"
,
dataKey
:
"
3
"
,
// 字典数据键值
/**
* 理货状态:2111、未理货;2112、已理货
*/
voName
:
"
tallyInfo
"
,
keyName
:
"
tyStatus
"
,
status
:
{
start
:
[
2111
],
wait
:
[],
end
:
[
2112
],
},
},
{
title
:
i18n
.
$t
(
"
合包
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/qg-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/qg-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/qg-end.png
"
),
},
type
:
"
mergePkg
"
,
dataKey
:
"
4
"
,
// 字典数据键值
/**
* 合包状态:161待合包 162已合包
*/
voName
:
"
boxMergePkgBackVO
"
,
keyName
:
"
mergePkgStatus
"
,
status
:
{
start
:
[
161
],
wait
:
[],
end
:
[
162
],
},
},
],
[
{
title
:
i18n
.
$t
(
"
出货
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/zg-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/zg-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/zg-end.png
"
),
},
type
:
"
shipment
"
,
dataKey
:
"
5
"
,
// 字典数据键值
/**
* 出货状态:171、待出货 172、出货审核中 173、审核失败 174、审核成功 = 175、已出货
*/
voName
:
"
boxAirShipmentBackVO
"
,
keyName
:
"
airShipmentStatus
"
,
status
:
{
start
:
[
171
],
wait
:
[
172
,
173
],
end
:
[
175
],
},
},
{
title
:
i18n
.
$t
(
"
出仓
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/zg-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/zg-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/zg-end.png
"
),
},
type
:
"
checkout
"
,
dataKey
:
"
6
"
,
// 字典数据键值
/**
* 出仓状态:221、未出仓 222、已出仓
*/
voName
:
"
boxAirCheckoutBackVO
"
,
keyName
:
"
checkoutStatus
"
,
status
:
{
start
:
[
221
],
wait
:
[],
end
:
[
222
],
},
},
],
[
{
title
:
"
AGENT
"
,
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/agent-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/agent-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/agent-end.png
"
),
},
type
:
"
agent
"
,
voName
:
"
agentInfo
"
,
currStatus
:
"
start
"
,
dataKey
:
"
7
"
},
{
title
:
i18n
.
$t
(
"
报关
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/bg-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/bg-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/bg-end.png
"
),
},
type
:
"
cusDeclaration
"
,
dataKey
:
"
8
"
,
// 字典数据键值
/**
*报关状态:51、未报关;52、报关中;53、已报关
*/
voName
:
"
customsInfo
"
,
keyName
:
"
dcStatus
"
,
status
:
{
start
:
[
51
],
wait
:
[
52
],
end
:
[
53
],
},
},
],
[
{
title
:
i18n
.
$t
(
"
起飞
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/ecqf-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/ecqf-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/ecqf-end.png
"
),
},
type
:
"
twoWayTakeoff
"
,
dataKey
:
"
10
"
,
// 字典数据键值
/**
* 起飞状态:231、未起飞;232、已起飞
*/
voName
:
"
boxAirFlyInfo
"
,
keyName
:
"
flyStatus
"
,
status
:
{
start
:
[
231
],
wait
:
[],
end
:
[
232
],
},
},
],
[
{
type
:
"
clrDocument
"
,
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/qg-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/qg-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/qg-end.png
"
),
},
title
:
i18n
.
$t
(
"
清关文件
"
),
dataKey
:
"
11
"
,
// 字典数据键值
/**
* 清关文件状态:111、未清关文件;112、已清关文件
*/
voName
:
"
clearanceDocInfo
"
,
keyName
:
"
cdStatus
"
,
status
:
{
start
:
[
111
],
wait
:
[],
end
:
[
112
],
},
},
],
[
{
title
:
i18n
.
$t
(
"
到港
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/dg-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/dg-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/dg-end.png
"
),
},
type
:
"
arrival
"
,
dataKey
:
"
12
"
,
// 字典数据键值
/**
* 到港状态:151、未到港;152、已到港
*/
voName
:
"
airArrivalInfo
"
,
keyName
:
"
sapStatus
"
,
status
:
{
start
:
[
151
],
wait
:
[],
end
:
[
152
],
},
},
],
[
{
title
:
i18n
.
$t
(
"
清关
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/qg-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/qg-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/qg-end.png
"
),
},
type
:
"
cusClearance
"
,
dataKey
:
"
13
"
,
// 字典数据键值
/**
* 清关状态:131、未清关;132、已清关
*/
voName
:
"
clearanceInfo
"
,
keyName
:
"
clStatus
"
,
status
:
{
start
:
[
131
],
wait
:
[],
end
:
[
132
],
},
},
],
[
{
title
:
i18n
.
$t
(
"
到仓
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/xg-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/xg-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/xg-end.png
"
),
},
type
:
"
unloading
"
,
dataKey
:
"
14
"
,
// 字典数据键值
/**
* 卸柜状态:181、未卸柜;182、卸柜中;183、卸柜审核中;184、卸柜审核失败;185、卸柜审核成功;186、已卸柜
*/
voName
:
"
cabinetUnloadInfo
"
,
keyName
:
"
toWarehouseStatus
"
,
status
:
{
start
:
[
181
],
wait
:
[
182
,
183
,
184
],
end
:
[
185
,
186
],
},
},
],
[
{
title
:
i18n
.
$t
(
"
结算
"
),
imgSrc
:
{
start
:
require
(
"
@/assets/images/shipping/js-start.png
"
),
wait
:
require
(
"
@/assets/images/shipping/js-wait.png
"
),
end
:
require
(
"
@/assets/images/shipping/js-end.png
"
),
},
type
:
"
settlement
"
,
dataKey
:
"
15
"
,
// 字典数据键值
/**
* 结算状态:191、未结算;192、结算中;193、已结算
*/
voName
:
"
settlementInfo
"
,
keyName
:
"
slStatus
"
,
status
:
{
start
:
[
191
],
wait
:
[
192
],
end
:
[
193
],
},
},
],
];
}
/**
* 详情显示列
*
...
...
@@ -1193,6 +1496,7 @@ export {
getSeaStatus,
airBaseData,
airOneData,
airNextData,
constantDict,
formatStringNumber,
formatDateStr,
...
...
src/views/ecw/order/edit.vue
View file @
70f87732
...
...
@@ -666,6 +666,7 @@ let makeDefaultFormData = () => {
orderItemVOList
:[],
drawee
:
2
,
harvestMethod
:
"
1
"
,
displayBillLadingPrice
:
true
}
}
window
.
Decimal
=
Decimal
...
...
@@ -1000,6 +1001,20 @@ export default {
if
(
!
this
.
initing
){
this
.
$set
(
this
.
form
,
'
drawee
'
,
isCargoControl
?
2
:
2
)
}
this
.
setBllLandingPrice
()
},
'
form.type
'
(){
this
.
setBllLandingPrice
()
},
'
form.drawee
'
(){
this
.
setBllLandingPrice
()
},
'
form.consigneeId
'
(){
this
.
setBllLandingPrice
()
},
'
form.consignorId
'
(){
this
.
setBllLandingPrice
()
},
// 目的港清关,1我司,2客户
'
form.portDestCustomsClear
'
(
portDestCustomsClear
){
...
...
@@ -1515,6 +1530,33 @@ export default {
that
.
$set
(
that
.
form
,
'
offerId
'
,
response
.
data
.
offerId
)
})
},
// 设置默认的提货单是否显示价格
setBllLandingPrice
(){
if
(
this
.
form
.
orderId
)
return
// 海外仓归属发货人
// 控货订单归属发货人
// 非控货订单 + 付款人为发货人 归属发货人, 其他归属收货人
let
customerId
=
null
if
(
this
.
form
.
type
==
2
||
this
.
form
.
isCargoControl
==
1
||
this
.
form
.
drawee
==
2
){
customerId
=
this
.
form
.
consignorId
}
else
{
customerId
=
this
.
form
.
consigneeId
}
if
(
!
customerId
)
return
console
.
log
(
'
原归属人
'
,
this
.
displayBillLadingPriceFrom
,
'
新归属人
'
,
customerId
)
// 如果当前的提单价格设置来自同一个客户则不在查询
if
(
this
.
displayBillLadingPriceFrom
==
customerId
)
return
;
this
.
displayBillLadingPriceFrom
=
customerId
// 获取客户信息
getCustomer
(
customerId
).
then
(
res
=>
{
console
.
log
(
'
isShowTidanPrice
'
,
res
)
this
.
form
.
displayBillLadingPrice
=
res
.
data
.
isShowTidanPrice
})
},
}
};
</
script
>
...
...
src/views/ecw/productPrice/batchEdit.vue
View file @
70f87732
...
...
@@ -299,34 +299,36 @@ export default {
getCurrencyList
().
then
(
res
=>
this
.
currencyList
=
res
.
data
)
getUnitList
().
then
(
res
=>
this
.
unitList
=
res
.
data
)
this
.
$nextTick
(
async
()
=>
{
// 如果是空运,阶梯价格默认为1
if
(
this
.
type
==
'
air
'
){
this
.
$set
(
this
.
form
,
'
stepPrice
'
,
1
)
}
await
this
.
$nextTick
()
// 默认单位,空运千克,海运立方米
this
.
setDefaultVolumeUnit
(
this
.
type
==
'
air
'
?
6
:
7
)
await
this
.
$nextTick
()
// 如果是空运,阶梯价格默认为1
if
(
this
.
type
==
'
air
'
){
this
.
$set
(
this
.
form
,
'
stepPrice
'
,
1
)
}
// 如果是复制,则获取数据并填充,先复制,然后填充特需,避免数据的特需不全导致部分不显示
if
(
this
.
$route
.
query
.
templateId
){
await
this
.
getTemplateDetail
(
this
.
$route
.
query
.
templateId
)
}
}
)
// 默认单位,空运千克,海运立方米
this
.
setDefaultVolumeUnit
(
this
.
type
==
'
air
'
?
6
:
7
)
// 如果是复制,则获取数据并填充,先复制,然后填充特需,避免数据的特需不全导致部分不显示
if
(
this
.
$route
.
query
.
templateId
){
await
this
.
getTemplateDetail
(
this
.
$route
.
query
.
templateId
)
}
// 从价格中获取特需的默认单位
const
obj
=
(
this
.
form
.
stepPrice
?
this
.
form
.
priceStepList
[
0
]
:
this
.
form
)
||
{
}
this
.
getDictDatas
(
this
.
DICT_TYPE
.
ECW_SPECIAL_REQ_FOR_LINE_PRODUCTS
).
forEach
(
item
=>
{
// 没有的才push,已有的可能是从复制模板携带过来的数据
if
(
!
this
.
form
.
specialList
.
find
(
special
=>
special
.
specialDictType
==
item
.
value
))
{
console
.
log
(
'
特需push
'
,
item
.
value
)
this
.
form
.
specialList
.
push
({
"
clearancePrice
"
:
null
,
"
clearancePriceUnit
"
:
null
,
"
clearanceVolumeUnit
"
:
null
,
"
clearancePriceUnit
"
:
obj
.
clearancePriceUnit
,
"
clearanceVolumeUnit
"
:
obj
.
clearanceVolumeUnit
,
"
specialDictType
"
:
item
.
value
,
"
transportPrice
"
:
null
,
"
transportPriceUnit
"
:
null
,
"
transportVolumeUnit
"
:
null
,
"
transportPriceUnit
"
:
obj
.
transportPriceUnit
,
"
transportVolumeUnit
"
:
obj
.
transportVolumeUnit
,
}
)
}
}
else
console
.
log
(
'
已存在特需
'
,
item
.
value
)
}
)
...
...
@@ -334,68 +336,67 @@ export default {
methods
:
{
// 获取模板数据(复制的源路线价格信息)
async
getTemplateDetail
(
id
){
await
getProductPrice
(
id
).
then
(
res
=>
{
// 填充商品、线路、价格信息、出货渠道(空运)
// this.form.productIdList = [res.data.productId]
this
.
selectedRoutes
=
[{
"
lineId
"
:
res
.
data
.
warehouseLineId
,
"
channelId
"
:
res
.
data
.
shippingChannelId
,
"
transportId
"
:
res
.
data
.
warehouseLineDO
.
transportType
,
"
shippingChannelId
"
:
res
.
data
.
channelId
}
]
// 要复制过来的字段
const
{
allPrice
,
allPriceUnit
,
allVolumeUnit
,
transportPrice
,
transportPriceUnit
,
transportVolumeUnit
,
clearancePrice
,
clearancePriceUnit
,
clearanceVolumeUnit
,
priceType
,
stepPrice
,
specialList
,
priceStepList
,
minWeight
,
minWeightUnit
,
needOrderInquiry
,
needBook
,
needPay
}
=
res
.
data
const
data
=
{
allPrice
,
allPriceUnit
,
allVolumeUnit
,
transportPrice
,
transportPriceUnit
,
transportVolumeUnit
,
clearancePrice
,
clearancePriceUnit
,
clearanceVolumeUnit
,
priceType
,
stepPrice
,
specialList
,
priceStepList
,
minWeight
,
minWeightUnit
,
needOrderInquiry
,
needBook
,
needPay
}
// 海运需要填充货柜位置和订单方数上限
if
(
this
.
type
==
'
sea
'
){
data
.
containerLocation
=
res
.
data
.
containerLocation
data
.
square
=
res
.
data
.
square
}
this
.
$set
(
this
,
'
form
'
,
Object
.
assign
({
}
,
this
.
form
,
data
))
const
res
=
await
getProductPrice
(
id
)
// 填充商品、线路、价格信息、出货渠道(空运)
// this.form.productIdList = [res.data.productId]
this
.
selectedRoutes
=
[{
"
lineId
"
:
res
.
data
.
warehouseLineId
,
"
channelId
"
:
res
.
data
.
shippingChannelId
,
"
transportId
"
:
res
.
data
.
warehouseLineDO
.
transportType
,
"
shippingChannelId
"
:
res
.
data
.
channelId
}
]
// 要复制过来的字段
const
{
allPrice
,
allPriceUnit
,
allVolumeUnit
,
transportPrice
,
transportPriceUnit
,
transportVolumeUnit
,
clearancePrice
,
clearancePriceUnit
,
clearanceVolumeUnit
,
priceType
,
stepPrice
,
specialList
,
priceStepList
,
minWeight
,
minWeightUnit
,
needOrderInquiry
,
needBook
,
needPay
}
=
res
.
data
const
data
=
{
allPrice
,
allPriceUnit
,
allVolumeUnit
,
transportPrice
,
transportPriceUnit
,
transportVolumeUnit
,
clearancePrice
,
clearancePriceUnit
,
clearanceVolumeUnit
,
priceType
,
stepPrice
,
specialList
,
priceStepList
,
minWeight
,
minWeightUnit
,
needOrderInquiry
,
needBook
,
needPay
}
// 海运需要填充货柜位置和订单方数上限
if
(
this
.
type
==
'
sea
'
){
data
.
containerLocation
=
res
.
data
.
containerLocation
data
.
square
=
res
.
data
.
square
}
this
.
$set
(
this
,
'
form
'
,
Object
.
assign
({
}
,
this
.
form
,
data
))
// 产品选择器默认选择的商品
getProduct
(
res
.
data
.
productId
).
then
(
res
=>
{
this
.
$refs
.
productSelector
.
choose
(
res
.
data
)
}
)
// 产品选择器默认选择的商品
getProduct
(
res
.
data
.
productId
).
then
(
res
=>
{
this
.
$refs
.
productSelector
.
choose
(
res
.
data
)
}
)
}
,
// 同步全部单位
...
...
src/views/ecw/productPrice/edit.vue
View file @
70f87732
...
...
@@ -101,7 +101,7 @@
<div
style=
"font-size:14px; margin:10px 0"
>
{{
$t
(
'
第{index
}
阶梯定价方案
'
,
{
index
:
index
+
1
}
)
}}
:
<
template
v
-
if
=
"
index == form.priceStepList.length - 1 && !readonly
"
>
<
el
-
link
type
=
"
primary
"
@
click
.
native
=
"
form.priceStepList.push({
}
)
"
>
{{
$t
(
'
添加区间
'
)
}}
<
/el-link
>
<
el
-
link
type
=
"
primary
"
@
click
.
native
=
"
addStepPrice
"
>
{{
$t
(
'
添加区间
'
)
}}
<
/el-link
>
<
el
-
divider
direction
=
"
vertical
"
><
/el-divider
>
<
el
-
link
type
=
"
danger
"
@
click
.
native
=
"
form.priceStepList.splice(index, 1)
"
>
{{
$t
(
'
删除
'
)
}}
<
/el-link
>
<
/template
>
...
...
@@ -956,6 +956,25 @@ export default {
// 加上对应的价格,但是不能小于0
this
.
$set
(
item
,
field
,
Math
.
max
(
0
,
Decimal
(
item
[
field
]
||
0
).
plus
(
amount
).
toNumber
()))
}
)
}
,
// 添加区间价
addStepPrice
(){
let
fields
=
{
}
const
obj
=
this
.
form
.
priceStepList
[
0
]
||
{
}
if
(
this
.
form
.
priceType
==
1
){
fields
=
{
allPriceUnit
:
obj
[
'
allPriceUnit
'
],
allVolumeUnit
:
obj
[
'
allVolumeUnit
'
]
}
}
else
{
fields
=
{
transportPriceUnit
:
obj
.
transportPriceUnit
,
transportVolumeUnit
:
obj
.
transportVolumeUnit
,
clearancePriceUnit
:
obj
.
clearancePriceUnit
,
clearanceVolumeUnit
:
obj
.
transportVolumeUnit
,
}
}
this
.
form
.
priceStepList
.
push
(
fields
)
}
}
}
...
...
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