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
5901682e
Commit
5901682e
authored
Jun 25, 2021
by
Facius
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
配件申请悬浮按钮
parent
68271509
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
79 additions
and
125 deletions
+79
-125
applyButton.vue
src/components/parts/applyButton.vue
+54
-0
mine.vue
src/pages/index/mine.vue
+2
-2
index.vue
src/pages/mine/warehouse/index.vue
+23
-123
No files found.
src/components/parts/applyButton.vue
0 → 100644
View file @
5901682e
<
template
>
<!-- 申请配件按钮 -->
<view
class=
"apply-button"
@
click=
"handleClick"
>
<u-button
:custom-style=
"customStyle"
shape=
"circle"
@
click
.
stop=
"handleOperate"
type=
"primary"
>
<u-icon
class=
"apply-icon"
name=
"plus"
></u-icon>
<text
class=
"apply-text"
v-if=
"showText"
>
申请配件
</text>
</u-button>
</view>
</
template
>
<
script
>
export
default
{
props
:
{
type
:
{
// 按钮宽'collapse': '80rpx', 'expand': '220rpx'
type
:
String
,
default
:
'expand'
}
},
computed
:
{
typeWidth
()
{
return
{
'collapse'
:
'80rpx'
,
'expand'
:
'220rpx'
}
},
showText
()
{
return
this
.
type
==
'expand'
},
customStyle
()
{
return
{
'height'
:
'80rpx'
,
'width'
:
this
.
typeWidth
[
this
.
type
],
}
}
},
methods
:
{
handleClick
()
{
this
.
$emit
(
'click'
)
},
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
.apply-button
{
.apply-icon
{
font-size
:
36rpx
;
}
.apply-text
{
font-size
:
32rpx
;
padding-left
:
10rpx
;
}
}
</
style
>
src/pages/index/mine.vue
View file @
5901682e
...
@@ -283,7 +283,7 @@
...
@@ -283,7 +283,7 @@
width
:
120rpx
;
width
:
120rpx
;
height
:
120rpx
;
height
:
120rpx
;
background-color
:
#FFFFFF
;
background-color
:
#FFFFFF
;
border-radius
:
56
rpx
;
border-radius
:
60
rpx
;
display
:
flex
;
display
:
flex
;
align-items
:
center
;
align-items
:
center
;
justify-content
:
center
;
justify-content
:
center
;
...
@@ -335,7 +335,7 @@
...
@@ -335,7 +335,7 @@
color
:
#FFFFFF
;
color
:
#FFFFFF
;
margin-right
:
4rpx
;
margin-right
:
4rpx
;
font-size
:
26rpx
;
font-size
:
26rpx
;
margin-top
:
-2
6
rpx
;
margin-top
:
-2
4
rpx
;
.right-image-view
{
.right-image-view
{
width
:
34rpx
;
width
:
34rpx
;
height
:
32rpx
;
height
:
32rpx
;
...
...
src/pages/mine/warehouse/index.vue
View file @
5901682e
...
@@ -2,17 +2,7 @@
...
@@ -2,17 +2,7 @@
<!-- 我的配件 -->
<!-- 我的配件 -->
<view
class=
"ware-house"
>
<view
class=
"ware-house"
>
<u-navbar
back-icon-color=
"#333333"
background=
"#FFFFFF"
title=
"我的配件"
titleColor=
"#333333"
<u-navbar
back-icon-color=
"#333333"
background=
"#FFFFFF"
title=
"我的配件"
titleColor=
"#333333"
:border-bottom=
"false"
title-bold
></u-navbar>
:border-bottom=
"false"
title-bold
></u-navbar>
<!--
<view
class=
"tools-box"
>
<view
class=
"search-sub"
>
<u-subsection
:current=
"curNow"
:list=
"subList"
active-color=
"white"
bg-color=
"white"
inactive-color=
"#666"
button-color=
"#2272FF"
bparts-radius=
"36"
@
change=
"sectionChange"
height=
"72"
bold
>
</u-subsection>
</view>
<u-button
class=
"right-btn"
@
click=
"handleClickRecords"
:custom-style=
"buttonStyle"
type=
"primary"
shape=
"circle"
>
操作记录
</u-button>
</view>
-->
<view
class=
"search-view"
>
<view
class=
"search-view"
>
<view
class=
"search-btn"
@
click=
"handleClickSearch"
>
<view
class=
"search-btn"
@
click=
"handleClickSearch"
>
<image
class=
"search-image"
mode=
"widthFix"
:src=
"sousuoImage"
></image>
<image
class=
"search-image"
mode=
"widthFix"
:src=
"sousuoImage"
></image>
...
@@ -27,7 +17,7 @@
...
@@ -27,7 +17,7 @@
</view>
</view>
<view
class=
"tab-view"
>
<view
class=
"tab-view"
>
<scroll-view
scroll-y
style=
"height: 100%;width: 100%;"
@
scrolltolower=
"reachBottom"
scroll-anchoring
<scroll-view
scroll-y
style=
"height: 100%;width: 100%;"
@
scrolltolower=
"reachBottom"
scroll-anchoring
refresher-enabled=
"true"
:refresher-triggered=
"triggered"
:refresher-threshold=
"100"
refresher-enabled=
"true"
:refresher-triggered=
"triggered"
:refresher-threshold=
"100"
@
scroll=
"scroll"
:scroll-top=
"scrollTop"
refresher-background=
"#F4F5F7"
@
refresherpulling=
"triggered = true"
:scroll-top=
"scrollTop"
refresher-background=
"#F4F5F7"
@
refresherpulling=
"triggered = true"
@
refresherrefresh=
"onRefresh"
@
refresherrestore=
"onRestore"
enable-back-to-top
>
@
refresherrefresh=
"onRefresh"
@
refresherrestore=
"onRestore"
enable-back-to-top
>
<view
class=
"loading-view"
v-if=
"!loaded"
>
<view
class=
"loading-view"
v-if=
"!loaded"
>
...
@@ -45,28 +35,21 @@
...
@@ -45,28 +35,21 @@
</
template
>
</
template
>
</scroll-view>
</scroll-view>
</view>
</view>
<!-- <view class="bottom-view" v-if="isReserve">
<view
class=
"fixed-button"
>
<view class="selected-all-view" @click="radioChange">
<ApplyButton
:type=
"buttonType"
@
click=
"handleClickApply"
/>
<u-icon class="selected-all-icon" name="checkbox-mark" :color="radioColor"></u-icon>
</view>
<text>全选</text>
</view>
<view class="right-view">
<u-button class="scd-btn" @click="handleClickRecords" :custom-style="buttonStyle" type="primary"
shape="circle">{{buttonText}}</u-button>
</view>
</view> -->
</view>
</view>
</template>
</template>
<
script
>
<
script
>
import
AppliedCell
from
"@/components/parts/appliedPartsCell.vue"
import
AppliedCell
from
"@/components/parts/appliedPartsCell.vue"
import
NoOrder
from
"@/components/order/noOrder.vue"
import
NoOrder
from
"@/components/order/noOrder.vue"
import
ApplyButton
from
"@/components/parts/applyButton.vue"
export
default
{
export
default
{
components
:
{
components
:
{
AppliedCell
,
AppliedCell
,
NoOrder
NoOrder
,
ApplyButton
},
},
data
()
{
data
()
{
return
{
return
{
...
@@ -79,6 +62,7 @@
...
@@ -79,6 +62,7 @@
triggered
:
false
,
triggered
:
false
,
_freshing
:
false
,
_freshing
:
false
,
selectedAll
:
false
,
selectedAll
:
false
,
buttonType
:
'expand'
// 申请按钮宽 collapse': '80rpx', 'expand': '220rpx''
};
};
},
},
computed
:
{
computed
:
{
...
@@ -126,19 +110,7 @@
...
@@ -126,19 +110,7 @@
'height'
:
'80rpx'
,
'height'
:
'80rpx'
,
'width'
:
'200rpx'
'width'
:
'200rpx'
}
}
},
},
// radioColor() {
// return this.selectedAll ? '#2272FF' : 'transparent'
// },
// buttonTexts() {
// return [['签收', '', '取消申请', '', ''], ['退件', '']]
// },
// buttonText() {
// return this.buttonTexts[this.curNow][this.currentIndex]
// },
// isReserve() { // 选中备件仓
// return this.curNow == 1 && this.currentIndex == 0
// }
},
},
onLoad
(
e
)
{
onLoad
(
e
)
{
getApp
().
trackPage
(
'我的配件页'
)
getApp
().
trackPage
(
'我的配件页'
)
...
@@ -146,10 +118,6 @@
...
@@ -146,10 +118,6 @@
this
.
_freshing
=
false
;
this
.
_freshing
=
false
;
},
},
methods
:
{
methods
:
{
// sectionChange(index) {
// this.curNow = index;
// this.reloadPartsList()
// },
// tab栏切换
// tab栏切换
change
(
index
)
{
change
(
index
)
{
this
.
currentIndex
=
index
;
this
.
currentIndex
=
index
;
...
@@ -186,51 +154,6 @@
...
@@ -186,51 +154,6 @@
this
.
loaded
=
true
this
.
loaded
=
true
});
});
},
},
// getReturnedParts(status) { // 返件列表
// this.pageNumber += 1
// this.loaded = false
// var param = {
// 'pageSize': 20,
// 'pageNumbr': 1,
// 'items': true,
// 'type': 'new'
// }
// this.$u.api.returnedParts(param).then((res) => {
// if (res.code == 200) {
// if (res.data.type != this.partsType) return
// this.triggered = false;
// this._freshing = false;
// if (this.pageNumber == 1) {
// this.partsList = []
// }
// if (res.data) {
// this.partsList.push(...res.data)
// this.loadStatus = res.data.length
<
this
.
pageSize
?
'nomore'
:
'loadmore'
// }
// } else {
// console.log(res.message)
// }
// this.loaded = true
// });
// },
// getReserveList() { // 备件列表
// this.pageNumber += 1
// this.loaded = false
// this.$u.api.reserveList().then((res) => {
// if (res.code == 200) {
// if (res.data.type != this.partsType) return
// this.triggered = false
// this._freshing = false
// this.partsList = res.data || []
// this.loadStatus = 'nomore'
// } else {
// console.log(res.message);
// }
// this.loaded = true
// });
// },
handleOperate
(
info
)
{
handleOperate
(
info
)
{
// 调接口
// 调接口
// 修改info的status
// 修改info的status
...
@@ -246,11 +169,11 @@
...
@@ -246,11 +169,11 @@
url
:
'pages/mine/warehouse/partsDetail'
url
:
'pages/mine/warehouse/partsDetail'
})
})
},
},
// handleClickRecords() {
handleClickApply
()
{
// uni.navigateTo({
uni
.
navigateTo
({
// url: 'pages/mine/warehouse/records'
url
:
'pages/parts/application'
// })
})
//
},
},
handleClickSearch
()
{
handleClickSearch
()
{
uni
.
navigateTo
({
uni
.
navigateTo
({
url
:
'pages/mine/warehouse/searchParts'
url
:
'pages/mine/warehouse/searchParts'
...
@@ -276,6 +199,9 @@
...
@@ -276,6 +199,9 @@
if
(
this
.
loadStatus
!=
'loadmore'
)
return
if
(
this
.
loadStatus
!=
'loadmore'
)
return
this
.
loadStatus
==
'loading'
this
.
loadStatus
==
'loading'
this
.
getUnstockedList
(
this
.
currentTab
.
status
)
this
.
getUnstockedList
(
this
.
currentTab
.
status
)
},
scroll
()
{
this
.
buttonType
=
'collapse'
},
},
}
}
};
};
...
@@ -342,37 +268,11 @@
...
@@ -342,37 +268,11 @@
position
:
absolute
;
position
:
absolute
;
}
}
}
}
// .tools-box {
.fixed-button
{
// display: flex;
position
:
fixed
;
// flex-direction: row;
right
:
20rpx
;
// justify-content: space-between;
bottom
:
140rpx
;
// padding-bottom: 20rpx;
// .search-sub {
// height: 72rpx;
// width: 320rpx;
// }
// }
.bottom-view
{
display
:
flex
;
justify-content
:
space-around
;
align-items
:
center
;
.selected-all-view
{
.selected-all-icon
{
border
:
2rpx
solid
#666666
;
}
}
.right-view
{
display
:
flex
;
align-items
:
center
;
.fst-btn
{
}
.scd-btn
{
}
}
}
}
}
}
...
...
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