Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
dj-car-boutique-work-wechat
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
1
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 1e28171d
authored
Oct 02, 2025
by
张立顺
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix bug
1 parent
904090b3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
45 additions
and
32 deletions
tabRepairOrder/components/relateGoodsPop/index.js
tabRepairOrder/pages/repairOrderDetail/repairOrderDetail.js
tabWorkOrder/components/relateGoodsPop/index.js
tabRepairOrder/components/relateGoodsPop/index.js
View file @
1e28171
// tabRepairOrder/components/relateGoodsPop/index.js
// tabRepairOrder/components/relateGoodsPop/index.js
Component
({
Component
({
/**
/**
* 组件的属性列表
* 组件的属性列表
*/
*/
...
@@ -10,15 +9,18 @@ Component({
...
@@ -10,15 +9,18 @@ Component({
baseConfigData
:
Object
,
baseConfigData
:
Object
,
show
:
{
show
:
{
type
:
Boolean
,
type
:
Boolean
,
observer
:
function
(
n
)
{
observer
:
function
(
n
)
{
if
(
n
)
{
if
(
n
)
{
let
{
goodsList
,
selected
}
=
this
.
data
let
{
goodsList
,
selected
}
=
this
.
data
goodsList
?.
map
(
val
=>
{
goodsList
?.
map
(
val
=>
{
val
.
active
=
false
val
.
active
=
false
if
(
selected
?.
findIndex
(
v
=>
v
.
upgradeGoodsId
==
val
.
upgradeGoodsId
)
>
-
1
)
val
.
active
=
true
if
(
selected
?.
findIndex
(
v
=>
v
.
subOrderCode
==
val
.
subOrderCode
)
>
-
1
)
val
.
active
=
true
return
val
return
val
})
})
this
.
setData
({
goodsList
})
this
.
setData
({
goodsList
})
}
}
}
}
}
}
...
@@ -27,9 +29,7 @@ Component({
...
@@ -27,9 +29,7 @@ Component({
/**
/**
* 组件的初始数据
* 组件的初始数据
*/
*/
data
:
{
data
:
{},
},
/**
/**
* 组件的方法列表
* 组件的方法列表
...
@@ -39,7 +39,7 @@ Component({
...
@@ -39,7 +39,7 @@ Component({
let
{
item
}
=
e
.
currentTarget
.
dataset
let
{
item
}
=
e
.
currentTarget
.
dataset
let
{
goodsList
}
=
this
.
data
let
{
goodsList
}
=
this
.
data
goodsList
?.
forEach
(
val
=>
{
goodsList
?.
forEach
(
val
=>
{
if
(
val
.
upgradeGoodsId
==
item
.
upgradeGoodsId
)
val
.
active
=
!
val
.
active
if
(
val
.
subOrderCode
==
item
.
subOrderCode
)
val
.
active
=
!
val
.
active
})
})
this
.
setData
({
this
.
setData
({
goodsList
goodsList
...
...
tabRepairOrder/pages/repairOrderDetail/repairOrderDetail.js
View file @
1e28171
...
@@ -236,11 +236,15 @@ Page({
...
@@ -236,11 +236,15 @@ Page({
this
.
setTime
()
this
.
setTime
()
if
(
code
==
0
)
{
if
(
code
==
0
)
{
if
(
data
.
startTime
)
{
if
(
data
.
startTime
)
{
data
.
startTime
=
new
Date
(
data
.
startTime
).
format
(
'yyyy-MM-dd hh:mm:ss'
)
data
.
startTime
=
new
Date
(
data
.
startTime
).
format
(
'yyyy-MM-dd hh:mm:ss'
)
}
}
_this
.
setData
({
_this
.
setData
({
'detailInfo.outboundStatus'
:
data
?.
outboundStatus
,
'detailInfo.outboundStatus'
:
data
?.
outboundStatus
,
'detailInfo.startTime'
:
detailInfo
.
startTime
?
detailInfo
.
startTime
:
data
.
startTime
// 页面操作选了开始施工时间不做更新,未选择取更新后的时间(出库时间)
'detailInfo.startTime'
:
detailInfo
.
startTime
?
detailInfo
.
startTime
:
data
.
startTime
// 页面操作选了开始施工时间不做更新,未选择取更新后的时间(出库时间)
})
})
}
else
{
}
else
{
wx
.
$util
.
showToast
(
message
)
wx
.
$util
.
showToast
(
message
)
...
@@ -254,7 +258,7 @@ Page({
...
@@ -254,7 +258,7 @@ Page({
let
{
queryOptions
}
=
this
.
data
let
{
queryOptions
}
=
this
.
data
if
(
!
queryOptions
.
id
||
!
queryOptions
.
constructionCode
)
return
if
(
!
queryOptions
.
id
||
!
queryOptions
.
constructionCode
)
return
wx
.
showLoading
({
wx
.
showLoading
({
title
:
'加载中'
,
title
:
'加载中'
})
})
api
api
.
getConstructionDetail
({
.
getConstructionDetail
({
...
@@ -298,7 +302,9 @@ Page({
...
@@ -298,7 +302,9 @@ Page({
'detailInfo.pictureList'
:
data
?.
pictureList
?.
map
(
val
=>
{
'detailInfo.pictureList'
:
data
?.
pictureList
?.
map
(
val
=>
{
return
val
.
pictureUrl
return
val
.
pictureUrl
}),
}),
'detailInfo.startTime'
:
detailInfo
.
startTime
?
detailInfo
.
startTime
:
data
.
startTime
// 页面操作选了开始施工时间不做更新,未选择取更新后的时间(出库时间)
'detailInfo.startTime'
:
detailInfo
.
startTime
?
detailInfo
.
startTime
:
data
.
startTime
// 页面操作选了开始施工时间不做更新,未选择取更新后的时间(出库时间)
},
},
()
=>
{
()
=>
{
if
(
data
?.
startTime
&&
data
?.
endTime
)
{
if
(
data
?.
startTime
&&
data
?.
endTime
)
{
...
@@ -662,13 +668,17 @@ Page({
...
@@ -662,13 +668,17 @@ Page({
if
(
!
detailInfo
?.
pictureList
?.
length
)
if
(
!
detailInfo
?.
pictureList
?.
length
)
return
wx
.
$util
.
showToast
(
'请在页面中提交上传施工图片'
)
return
wx
.
$util
.
showToast
(
'请在页面中提交上传施工图片'
)
if
(
!
detailInfo
.
endTime
)
{
// 未选择施工结束时间取当前时间
if
(
!
detailInfo
.
endTime
)
{
// 未选择施工结束时间取当前时间
this
.
setData
({
this
.
setData
(
{
'detailInfo.endTime'
:
new
Date
().
format
(
'yyyy-MM-dd hh:mm:ss'
)
'detailInfo.endTime'
:
new
Date
().
format
(
'yyyy-MM-dd hh:mm:ss'
)
},
()
=>
{
},
()
=>
{
this
.
calculateTimeDifference
()
// 自动计算施工时长
this
.
calculateTimeDifference
()
// 自动计算施工时长
})
}
)
}
}
const
pictureList
=
detailInfo
?.
pictureList
?.
map
(
val
=>
{
const
pictureList
=
detailInfo
?.
pictureList
?.
map
(
val
=>
{
return
{
return
{
...
@@ -676,7 +686,7 @@ Page({
...
@@ -676,7 +686,7 @@ Page({
}
}
})
})
if
(
this
.
data
.
submitFlag
)
return
if
(
this
.
data
.
submitFlag
)
return
this
.
setData
({
submitFlag
:
true
})
this
.
setData
({
submitFlag
:
true
})
this
.
setData
({
submitFlag
:
true
})
let
params
=
{
let
params
=
{
id
:
detailInfo
.
id
,
id
:
detailInfo
.
id
,
constructionCode
:
detailInfo
.
constructionCode
,
constructionCode
:
detailInfo
.
constructionCode
,
...
@@ -688,7 +698,7 @@ Page({
...
@@ -688,7 +698,7 @@ Page({
pictureList
:
pictureList
pictureList
:
pictureList
}
}
wx
.
showLoading
({
wx
.
showLoading
({
title
:
'加载中'
,
title
:
'加载中'
})
})
api
api
.
completeConstructionOrder
(
params
)
.
completeConstructionOrder
(
params
)
...
@@ -734,13 +744,15 @@ Page({
...
@@ -734,13 +744,15 @@ Page({
reviewFlag
:
true
reviewFlag
:
true
})
})
wx
.
showLoading
({
wx
.
showLoading
({
title
:
'加载中'
,
title
:
'加载中'
})
})
api
.
approvalRepairOrder
({
api
.
approvalRepairOrder
({
id
:
detailInfo
.
id
,
id
:
detailInfo
.
id
,
constructionCode
:
detailInfo
.
constructionCode
,
constructionCode
:
detailInfo
.
constructionCode
,
approvalStatus
:
type
approvalStatus
:
type
}).
then
(
result
=>
{
})
.
then
(
result
=>
{
wx
.
hideLoading
()
wx
.
hideLoading
()
this
.
reviewClose
()
this
.
reviewClose
()
let
{
code
,
message
}
=
result
let
{
code
,
message
}
=
result
...
@@ -761,7 +773,8 @@ Page({
...
@@ -761,7 +773,8 @@ Page({
}
else
{
}
else
{
wx
.
$util
.
showToast
(
message
)
wx
.
$util
.
showToast
(
message
)
}
}
}).
catch
(()
=>
{
})
.
catch
(()
=>
{
wx
.
hideLoading
()
wx
.
hideLoading
()
setTimeout
(()
=>
{
setTimeout
(()
=>
{
this
.
setData
({
this
.
setData
({
...
...
tabWorkOrder/components/relateGoodsPop/index.js
View file @
1e28171
// tabRepairOrder/components/relateGoodsPop/index.js
// tabRepairOrder/components/relateGoodsPop/index.js
Component
({
Component
({
/**
/**
* 组件的属性列表
* 组件的属性列表
*/
*/
...
@@ -10,15 +9,18 @@ Component({
...
@@ -10,15 +9,18 @@ Component({
baseConfigData
:
Object
,
baseConfigData
:
Object
,
show
:
{
show
:
{
type
:
Boolean
,
type
:
Boolean
,
observer
:
function
(
n
)
{
observer
:
function
(
n
)
{
if
(
n
)
{
if
(
n
)
{
let
{
goodsList
,
selected
}
=
this
.
data
let
{
goodsList
,
selected
}
=
this
.
data
goodsList
?.
map
(
val
=>
{
goodsList
?.
map
(
val
=>
{
val
.
active
=
false
val
.
active
=
false
if
(
selected
?.
findIndex
(
v
=>
v
.
upgradeGoodsId
==
val
.
upgradeGoodsId
)
>
-
1
)
val
.
active
=
true
if
(
selected
?.
findIndex
(
v
=>
v
.
subOrderCode
==
val
.
subOrderCode
)
>
-
1
)
val
.
active
=
true
return
val
return
val
})
})
this
.
setData
({
goodsList
})
this
.
setData
({
goodsList
})
}
}
}
}
}
}
...
@@ -27,9 +29,7 @@ Component({
...
@@ -27,9 +29,7 @@ Component({
/**
/**
* 组件的初始数据
* 组件的初始数据
*/
*/
data
:
{
data
:
{},
},
/**
/**
* 组件的方法列表
* 组件的方法列表
...
@@ -39,7 +39,7 @@ Component({
...
@@ -39,7 +39,7 @@ Component({
let
{
item
}
=
e
.
currentTarget
.
dataset
let
{
item
}
=
e
.
currentTarget
.
dataset
let
{
goodsList
}
=
this
.
data
let
{
goodsList
}
=
this
.
data
goodsList
?.
forEach
(
val
=>
{
goodsList
?.
forEach
(
val
=>
{
if
(
val
.
upgradeGoodsId
==
item
.
upgradeGoodsId
)
val
.
active
=
!
val
.
active
if
(
val
.
subOrderCode
==
item
.
subOrderCode
)
val
.
active
=
!
val
.
active
})
})
this
.
setData
({
this
.
setData
({
goodsList
goodsList
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment