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
c822e2a2
Commit
c822e2a2
authored
Aug 04, 2023
by
dragondean@qq.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复偶发订单编辑路线回显失败
parent
45367f73
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
7 deletions
+14
-7
edit.vue
src/views/ecw/order/edit.vue
+14
-7
No files found.
src/views/ecw/order/edit.vue
View file @
c822e2a2
...
@@ -550,6 +550,7 @@ import SupplierSelector from '@/components/SupplierSelector'
...
@@ -550,6 +550,7 @@ import SupplierSelector from '@/components/SupplierSelector'
import
Decimal
from
'
decimal.js
'
import
Decimal
from
'
decimal.js
'
import
WorkFlow
from
'
@/components/WorkFlow
'
import
WorkFlow
from
'
@/components/WorkFlow
'
import
{
getCustomer
}
from
"
@/api/ecw/customer
"
;
import
{
getCustomer
}
from
"
@/api/ecw/customer
"
;
import
{
debounce
}
from
"
@/utils
"
;
// 缓存默认的表单数据
// 缓存默认的表单数据
let
makeDefaultFormData
=
()
=>
{
let
makeDefaultFormData
=
()
=>
{
...
@@ -783,7 +784,7 @@ export default {
...
@@ -783,7 +784,7 @@ export default {
console
.
log
(
'
departureId
'
,
departureId
)
console
.
log
(
'
departureId
'
,
departureId
)
this
.
getOpenedRouterList
()
this
.
getOpenedRouterList
()
// 修改始发地后需要重新选择路线
// 修改始发地后需要重新选择路线
if
(
oldDepartureId
&&
oldDepartureId
!=
departureId
){
if
(
oldDepartureId
&&
oldDepartureId
!=
departureId
&&
!
this
.
initing
){
console
.
log
(
'
修改始发地,重置lineId
'
,
oldDepartureId
,
departureId
)
console
.
log
(
'
修改始发地,重置lineId
'
,
oldDepartureId
,
departureId
)
this
.
$set
(
this
.
form
,
'
lineId
'
,
null
)
this
.
$set
(
this
.
form
,
'
lineId
'
,
null
)
}
}
...
@@ -792,7 +793,7 @@ export default {
...
@@ -792,7 +793,7 @@ export default {
'
form.objectiveId
'
(
objectiveId
,
oldObjectiveId
){
'
form.objectiveId
'
(
objectiveId
,
oldObjectiveId
){
this
.
getOpenedRouterList
()
this
.
getOpenedRouterList
()
// 修改目的地后需要重新选择路线
// 修改目的地后需要重新选择路线
if
(
oldObjectiveId
&&
oldObjectiveId
!=
objectiveId
){
if
(
oldObjectiveId
&&
oldObjectiveId
!=
objectiveId
&&
!
this
.
initing
){
console
.
log
(
'
修改目的地,重置lineId
'
,
oldObjectiveId
,
objectiveId
)
console
.
log
(
'
修改目的地,重置lineId
'
,
oldObjectiveId
,
objectiveId
)
this
.
$set
(
this
.
form
,
'
lineId
'
,
null
)
this
.
$set
(
this
.
form
,
'
lineId
'
,
null
)
}
}
...
@@ -810,7 +811,7 @@ export default {
...
@@ -810,7 +811,7 @@ export default {
})
})
}
}
// 更换运输方式之后,之前选择的路线会失效,需要重新选择
// 更换运输方式之后,之前选择的路线会失效,需要重新选择
if
(
oldTransportId
&&
oldTransportId
!=
transportId
&&
transportId
!=
this
.
selectedRouter
?.
transportType
){
if
(
oldTransportId
&&
oldTransportId
!=
transportId
&&
transportId
!=
this
.
selectedRouter
?.
transportType
&&
!
this
.
initing
){
console
.
log
(
'
重置路线
'
,
oldTransportId
,
transportId
,
this
.
selectedRouter
?.
transportType
)
console
.
log
(
'
重置路线
'
,
oldTransportId
,
transportId
,
this
.
selectedRouter
?.
transportType
)
this
.
$set
(
this
.
form
,
'
lineId
'
,
undefined
)
this
.
$set
(
this
.
form
,
'
lineId
'
,
undefined
)
}
}
...
@@ -922,6 +923,7 @@ export default {
...
@@ -922,6 +923,7 @@ export default {
// console.warn('onTableMounted', e)
// console.warn('onTableMounted', e)
},
},
getOrder
(){
getOrder
(){
this
.
initing
=
true
getUpdateInfo
(
this
.
$route
.
query
.
id
).
then
(
res
=>
{
getUpdateInfo
(
this
.
$route
.
query
.
id
).
then
(
res
=>
{
this
.
form
=
Object
.
assign
({},
{...
res
.
data
},
{
orderItemVOList
:
[]})
this
.
form
=
Object
.
assign
({},
{...
res
.
data
},
{
orderItemVOList
:
[]})
...
@@ -975,6 +977,7 @@ export default {
...
@@ -975,6 +977,7 @@ export default {
// 如果已完成入仓,则需要监听必填内容,发生更改后需要填写审批表单
// 如果已完成入仓,则需要监听必填内容,发生更改后需要填写审批表单
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
console
.
log
(
'
nextTick 订单渲染完成
'
)
res
.
data
.
orderItemVOList
.
forEach
(
item
=>
{
res
.
data
.
orderItemVOList
.
forEach
(
item
=>
{
item
.
prodAttrArr
=
item
.
prodAttrIds
.
split
(
'
,
'
).
filter
(
item
=>
item
!=
''
).
map
(
attrId
=>
+
attrId
)
item
.
prodAttrArr
=
item
.
prodAttrIds
.
split
(
'
,
'
).
filter
(
item
=>
item
!=
''
).
map
(
attrId
=>
+
attrId
)
this
.
form
.
orderItemVOList
.
push
({...
item
})
this
.
form
.
orderItemVOList
.
push
({...
item
})
...
@@ -990,6 +993,8 @@ export default {
...
@@ -990,6 +993,8 @@ export default {
}
}
this
.
initing
=
false
this
.
initing
=
false
})
})
console
.
log
(
'
order数据加载成功
'
)
}).
catch
(()
=>
{
}).
catch
(()
=>
{
this
.
initing
=
false
this
.
initing
=
false
})
})
...
@@ -1095,6 +1100,7 @@ export default {
...
@@ -1095,6 +1100,7 @@ export default {
},
},
// 获取路线
// 获取路线
getOpenedRouterList
(){
getOpenedRouterList
(){
debounce
(()
=>
{
let
params
=
{}
let
params
=
{}
if
(
this
.
form
.
departureId
){
if
(
this
.
form
.
departureId
){
params
.
startCityId
=
this
.
form
.
departureId
params
.
startCityId
=
this
.
form
.
departureId
...
@@ -1110,6 +1116,7 @@ export default {
...
@@ -1110,6 +1116,7 @@ export default {
getOpenedRouterList
(
params
).
then
(
res
=>
this
.
routerList
=
res
.
data
.
filter
(
item
=>
{
getOpenedRouterList
(
params
).
then
(
res
=>
this
.
routerList
=
res
.
data
.
filter
(
item
=>
{
return
this
.
exportCityIds
.
indexOf
(
item
.
startCityId
)
>
-
1
&&
this
.
importCityIds
.
indexOf
(
item
.
destCityId
)
>
-
1
return
this
.
exportCityIds
.
indexOf
(
item
.
startCityId
)
>
-
1
&&
this
.
importCityIds
.
indexOf
(
item
.
destCityId
)
>
-
1
}))
}))
},
100
,
false
)()
},
},
// 计算体积
// 计算体积
calcVolume
(
row
){
calcVolume
(
row
){
...
...
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