Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
self-support
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
李俊赕
self-support
Commits
e586886f
Commit
e586886f
authored
Jun 25, 2021
by
Facius
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
我的备件页面
parent
01db4852
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
359 additions
and
247 deletions
+359
-247
spareCell.vue
src/components/parts/spareCell.vue
+99
-0
index.vue
src/components/submit-bar/index.vue
+1
-1
partsDetail.vue
src/pages/mine/warehouse/partsDetail.vue
+13
-50
spare.vue
src/pages/mine/warehouse/spare.vue
+246
-196
No files found.
src/components/parts/spareCell.vue
0 → 100644
View file @
e586886f
<
template
>
<view
class=
"spare-item"
>
<view
class=
"left-view"
>
<u-checkbox
v-if=
"showChecked"
icon-size=
"28"
size=
"40"
v-model=
"item.selected"
@
change=
"handleChange"
shape=
"circle"
/>
<image
class=
"image-view"
:src=
"imageUrl"
></image>
<view
class=
"info-view"
>
<view
class=
"name-text"
>
{{
item
.
name
}}
</view>
<view>
{{
remarkText
}}
</view>
</view>
</view>
<view
class=
"count-view"
>
x
{{
item
.
quantity
}}
</view>
</view>
</
template
>
<
script
>
export
default
{
props
:
{
showChecked
:
{
// 是否显示勾选
type
:
Boolean
,
default
()
{
return
false
}
},
item
:
{
type
:
Object
,
default
()
{
return
{}
}
},
noteText
:
{
type
:
String
,
default
:
''
}
},
data
()
{
return
{
checked
:
false
}
},
computed
:
{
remarkText
()
{
return
this
.
noteText
||
this
.
item
.
code
// return this.info.categoryName + '-' + this.info.brandName
},
imageUrl
()
{
return
this
.
item
.
images
?
process
.
uniEnv
.
systemUrl
.
apiUrl
+
this
.
item
.
images
.
split
(
','
).
shift
()
:
this
.
placeholderImage
},
placeholderImage
()
{
return
process
.
uniEnv
.
qn_base_url
+
'logo.png'
},
},
methods
:
{
handleChange
()
{
this
.
$emit
(
'change'
)
}
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
.spare-item
{
display
:
flex
;
// width: 100%;
justify-content
:
space-between
;
align-items
:
flex-end
;
// padding: 30rpx;
// background-color: #FFFFFF;
// border-radius: 12rpx;
.left-view
{
display
:
flex
;
align-items
:
center
;
.image-view
{
width
:
120rpx
;
height
:
120rpx
;
margin-right
:
20rpx
;
flex-shrink
:
0
;
}
.info-view
{
font-size
:
24rpx
;
color
:
#333333
;
.name-text
{
font-size
:
32rpx
;
font-weight
:
bold
;
color
:
#333333
;
margin-bottom
:
30rpx
;
}
}
}
.count-view
{
font-size
:
28rpx
;
color
:
#333333
;
}
}
</
style
>
src/components/submit-bar/index.vue
View file @
e586886f
...
...
@@ -2,7 +2,7 @@
<view
class=
"u-flex bottom"
:style=
"customStyle"
>
<view
class=
"select-view"
>
<view
class=
"u-flex bottom-left"
v-if=
"showChecked"
>
<view
class=
"left-list"
><u-checkbox
icon-size=
"
30
"
size=
"40"
v-model=
"checked"
@
change=
"selectAll"
shape=
"circle"
/></view>
<view
class=
"left-list"
><u-checkbox
icon-size=
"
28
"
size=
"40"
v-model=
"checked"
@
change=
"selectAll"
shape=
"circle"
/></view>
<view
class=
"left-list"
>
全选
</view>
</view>
<view
class=
"u-flex bottom-center"
>
...
...
src/pages/mine/warehouse/partsDetail.vue
View file @
e586886f
...
...
@@ -21,16 +21,9 @@
</view>
</view>
<view
class=
"detail-view"
>
<view
class=
"list-content"
>
<view
class=
"list-item"
v-for=
"(item, index) in info.items"
:key=
"index"
>
<view
class=
"left-view"
>
<image
class=
"image-view"
:src=
"imageUrl(item)"
></image>
<view
class=
"info-view"
>
<view
class=
"name-text"
>
{{
item
.
name
}}
</view>
<view>
{{
noteText
}}
</view>
</view>
</view>
<view
class=
"count-view"
>
x
{{
item
.
quantity
}}
</view>
<view
class=
"list-content"
>
<view
class=
"list-item"
v-for=
"(item, index) in info.items"
:key=
"index"
>
<SpareCell
:item=
"item"
:noteText=
"noteText"
/>
</view>
</view>
<view
class=
"line-view"
></view>
...
...
@@ -59,8 +52,12 @@
</view>
</
template
>
<
script
>
export
default
{
<
script
>
import
SpareCell
from
"@/components/parts/spareCell.vue"
export
default
{
components
:
{
SpareCell
},
data
()
{
return
{
info
:
{
...
...
@@ -163,7 +160,7 @@
})
},
imageUrl
(
item
)
{
return
item
.
images
?
item
.
images
.
split
(
','
).
shift
()
:
this
.
placeholderImage
return
item
.
images
?
process
.
uniEnv
.
systemUrl
.
apiUrl
+
item
.
images
.
split
(
','
).
shift
()
:
this
.
placeholderImage
},
handleLongpress
(
key
,
text
)
{
// 长按复制单号
if
(
key
==
'orderNumber'
)
{
...
...
@@ -267,45 +264,11 @@
}
.list-content
{
margin-top
:
4
0rpx
;
margin-bottom
:
4
0rpx
;
margin-top
:
1
0rpx
;
margin-bottom
:
1
0rpx
;
.list-item
{
display
:
flex
;
width
:
100%
;
margin-right
:
30rpx
;
justify-content
:
space-between
;
align-items
:
flex-end
;
margin-bottom
:
40rpx
;
.left-view
{
display
:
flex
;
align-items
:
flex-start
;
.image-view
{
width
:
120rpx
;
height
:
120rpx
;
margin-right
:
20rpx
;
flex-shrink
:
0
;
}
.info-view
{
font-size
:
24rpx
;
color
:
#333333
;
.name-text
{
font-size
:
32rpx
;
font-weight
:
bold
;
color
:
#333333
;
margin-bottom
:
30rpx
;
}
}
}
.count-view
{
font-size
:
28rpx
;
color
:
#333333
;
}
margin-bottom
:
30rpx
;
}
}
...
...
src/pages/mine/warehouse/spare.vue
View file @
e586886f
This diff is collapsed.
Click to expand it.
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