Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
wxh-order-h5
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
李俊赕
wxh-order-h5
Commits
609fd59b
Commit
609fd59b
authored
Mar 11, 2021
by
李超鹏
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev-shzhida'
parents
c4020e32
555328c0
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
28 deletions
+32
-28
XhFiles.vue
web/src/views/h5/shzhida/components/XhFiles.vue
+1
-1
service.vue
web/src/views/h5/shzhida/order/service.vue
+31
-27
No files found.
web/src/views/h5/shzhida/components/XhFiles.vue
View file @
609fd59b
...
@@ -70,7 +70,6 @@ export default {
...
@@ -70,7 +70,6 @@ export default {
},
},
methods
:
{
methods
:
{
async
uploadFile
(
item
)
{
async
uploadFile
(
item
)
{
console
.
log
(
item
)
const
fromData
=
new
FormData
()
const
fromData
=
new
FormData
()
fromData
.
append
(
'file'
,
item
.
file
)
fromData
.
append
(
'file'
,
item
.
file
)
const
result
=
await
uploadFile
(
this
.
orderId
,
fromData
)
const
result
=
await
uploadFile
(
this
.
orderId
,
fromData
)
...
@@ -94,6 +93,7 @@ export default {
...
@@ -94,6 +93,7 @@ export default {
this
.
uploadFile
(
item
)
this
.
uploadFile
(
item
)
},
},
deleteImg
(
index
)
{
deleteImg
(
index
)
{
this
.
item
.
value
.
splice
(
index
,
1
)
this
.
imgList
.
splice
(
index
,
1
)
this
.
imgList
.
splice
(
index
,
1
)
}
}
}
}
...
...
web/src/views/h5/shzhida/order/service.vue
View file @
609fd59b
...
@@ -173,17 +173,15 @@ export default {
...
@@ -173,17 +173,15 @@ export default {
if
(
!
data
||
data
.
length
<=
0
)
{
if
(
!
data
||
data
.
length
<=
0
)
{
return
return
}
}
const
materialList
=
[];
const
materialOtherList
=
[];
const
craftList
=
[];
cons
t
craftOtherList
=
[]
let
materialList
=
[];
let
materialOtherList
=
[];
let
craftList
=
[];
le
t
craftOtherList
=
[]
if
(
!
data
.
materialEntityList
||
data
.
materialEntityList
.
length
<=
0
)
{
if
(
!
data
.
materialEntityList
||
data
.
materialEntityList
.
length
<=
0
)
{
this
.
getMaterialData
()
this
.
getMaterialData
()
}
else
{
// 将 materialEntityList 分成两个 在分成两个 一共四个 priceType 01 02 matType 04
}
else
{
// 将 materialEntityList 分成两个 在分成两个 一共四个 priceType 01 02 matType 04
data
.
materialEntityList
.
map
(
item
=>
{
const
formatData
=
this
.
formatServiceMoreList
(
data
.
materialEntityList
)
if
(
item
.
priceType
===
'01'
)
{
materialList
=
formatData
.
materialList
item
.
matType
===
'04'
?
materialOtherList
.
push
({
freeMount
:
item
.
extraAmt
,
name
:
item
.
otherExplain
})
:
materialList
.
push
(
item
)
materialOtherList
=
formatData
.
materialOtherList
}
else
{
craftList
=
formatData
.
craftList
item
.
matType
===
'04'
?
craftOtherList
.
push
({
freeMount
:
item
.
extraAmt
,
name
:
item
.
otherExplain
})
:
craftList
.
push
(
item
)
craftOtherList
=
formatData
.
craftOtherList
}
})
}
}
// 初始化数据
// 初始化数据
let
allFormList
=
[]
let
allFormList
=
[]
...
@@ -220,29 +218,29 @@ export default {
...
@@ -220,29 +218,29 @@ export default {
}
}
})
})
},
},
setServiceMoreList
(
materialCraftsData
)
{
formatServiceMoreList
(
materialCraftsData
)
{
if
(
!
materialCraftsData
||
materialCraftsData
.
le
<=
0
)
{
return
}
const
materialList
=
[{
matName
:
'材料名称'
,
matUnit
:
'单位'
,
freeLength
:
'免费量'
,
unitAmt
:
'单价/元'
,
useLength
:
'实际使用量'
}]
const
materialList
=
[{
matName
:
'材料名称'
,
matUnit
:
'单位'
,
freeLength
:
'免费量'
,
unitAmt
:
'单价/元'
,
useLength
:
'实际使用量'
}]
const
materialOtherList
=
[]
const
craftList
=
[{
matName
:
'工艺名称'
,
matUnit
:
'单位'
,
freeLength
:
'免费量'
,
unitAmt
:
'单价/元'
,
useLength
:
'实际使用量'
}]
const
craftList
=
[{
matName
:
'工艺名称'
,
matUnit
:
'单位'
,
freeLength
:
'免费量'
,
unitAmt
:
'单价/元'
,
useLength
:
'实际使用量'
}]
const
craftOtherList
=
[]
if
(
materialCraftsData
&&
materialCraftsData
.
le
>
0
)
{
materialCraftsData
.
map
(
item
=>
{
materialCraftsData
.
map
(
item
=>
{
if
(
item
.
priceType
===
'01'
)
{
if
(
item
.
priceType
===
'01'
)
{
materialList
.
push
(
item
)
item
.
matType
===
'04'
?
materialOtherList
.
push
({
freeMount
:
item
.
extraAmt
,
name
:
item
.
otherExplain
})
:
materialList
.
push
(
item
)
}
else
{
}
else
{
craftList
.
push
(
item
)
item
.
matType
===
'04'
?
craftOtherList
.
push
({
freeMount
:
item
.
extraAmt
,
name
:
item
.
otherExplain
})
:
craftList
.
push
(
item
)
}
}
})
})
this
.
formList
.
map
(
item
=>
{
if
(
item
.
title
===
'材料及工艺'
)
{
item
.
content
[
0
].
list
=
materialList
item
.
content
[
1
].
list
=
craftList
}
}
})
return
{
materialList
:
materialList
,
materialOtherList
:
materialOtherList
,
craftList
:
craftList
,
craftOtherList
:
craftOtherList
}
},
},
getList
()
{
getList
()
{
// 获取之前保存的信息 显示
// 获取之前保存的信息 显示
// this.formatlist({ imageUrl: { '07': ['http://localhost:8182/wxh-cloud-rest/rest/file/image/common/6099514/invoice_1615028604596613.png', 'http://localhost:8182/wxh-cloud-rest/rest/file/image/common/6099514/invoice_1615028617807600.png'], '01': ['http://localhost:8182/wxh-cloud-rest/rest/file/image/common/6099514/invoice_1615028606706945.png'] }, powerType: '01', highPowerFlg: 'N', reportInstallFlg: 'Y', elecGroundType: '01', circuitBreakerWireSize: '10', circuitBreakerCapacity: '10', powerPointWireSize: '10', installableBreaker: '10', installableWireSize: '01', actualVoltage: '10', actualCurrent: '10', resistanceGround: '10', cableLen: '10', powerRoomPropertyRightType: '03', powerRoomChargingType: '01', propertyAgreementFlg: 'Y', grassRoadLen: '111', cementRoadLen: '222', pitchRoadLen: '333', otherRoadLen: '555', openPoreLen: '20', openPoreNum: '4', openSlotLen: '10', highLen: '5', highWorkLen: '666', botenL: '11', botenW: '12', botenH: '13', otherWorkRemark: '777', installType: '01', portType: '01', fireEnvFlg: 'Y', elecRequireFlg: 'Y', signalType: ['03', '02', '01'], inspectConclusionType: '01' })
getOrderCustomizeInfo
(
this
.
orderId
,
this
.
type
).
then
((
result
)
=>
{
getOrderCustomizeInfo
(
this
.
orderId
,
this
.
type
).
then
((
result
)
=>
{
Indicator
.
close
()
Indicator
.
close
()
if
(
result
.
data
.
code
!==
200
)
{
if
(
result
.
data
.
code
!==
200
)
{
...
@@ -270,7 +268,13 @@ export default {
...
@@ -270,7 +268,13 @@ export default {
})
})
return
[]
return
[]
}
}
this
.
setServiceMoreList
(
result
.
data
.
data
)
const
formatData
=
this
.
formatServiceMoreList
(
result
.
data
.
data
)
this
.
formList
.
map
(
item
=>
{
if
(
item
.
title
===
'材料及工艺'
)
{
item
.
content
[
0
].
list
=
formatData
.
materialList
item
.
content
[
1
].
list
=
formatData
.
craftList
}
})
}).
catch
((
error
)
=>
{
}).
catch
((
error
)
=>
{
console
.
log
(
error
)
console
.
log
(
error
)
Toast
({
Toast
({
...
...
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