Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
mini-program
/
hmd
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 24b6e311
authored
Jul 19, 2023
by
李伟康
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
删除无用
1 parent
bbd5a1dc
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
0 additions
and
164 deletions
packageMine/pages/address/detail/components/AreaSelect/index.js
packageMine/pages/address/detail/components/AreaSelect/index.json
packageMine/pages/address/detail/components/AreaSelect/index.scss
packageMine/pages/address/detail/components/AreaSelect/index.wxml
packageMine/pages/address/detail/detail.json
packageMine/pages/coupon/recommend/recommend.json
packageMine/pages/address/detail/components/AreaSelect/index.js
deleted
100644 → 0
View file @
bbd5a1d
// packageEquity/pages/serviceApply/util/components/areaSelect.js
Component
({
/**
* 组件的属性列表
*/
properties
:
{
provinceShow
:
Boolean
,
provinceList
:{
type
:
Array
,
observer
:
function
(
val
)
{
this
.
setData
({
provinceList
:
val
})
}
}
},
/**
* 组件的初始数据
*/
data
:
{
region
:
[
0
,
0
,
0
],
//地址每列的index
regionCode
:
[],
provinceList
:
[]
},
/**
* 组件的方法列表
*/
methods
:
{
emitHideRegion
(){},
// 省市切换
bindChange
(
e
)
{
// 用于对比滑动的是哪一列数据
const
val
=
e
.
detail
.
value
if
(
this
.
data
.
region
[
0
]
!==
val
[
0
])
{
// 如果滑动的是第一列数据,让二三列恢复到0
this
.
setData
({
region
:
[
val
[
0
],
0
,
0
]
})
}
else
if
(
this
.
data
.
region
[
1
]
!==
val
[
1
])
{
// 滑动的是第二列数据
this
.
setData
({
region
:
[
val
[
0
],
val
[
1
],
0
]
})
}
else
{
this
.
setData
({
region
:
e
.
detail
.
value
})
}
},
// 确定提交
comfirm
()
{
const
{
provinceList
,
region
}
=
this
.
data
// 省市code
const
provinceCode
=
provinceList
[
region
[
0
]].
addressCode
const
cityCode
=
provinceList
[
region
[
0
]].
children
[
region
[
1
]].
addressCode
const
townCode
=
provinceList
[
region
[
0
]].
children
[
region
[
1
]].
children
[
region
[
2
]].
addressCode
const
codeData
=
[
provinceCode
,
cityCode
,
townCode
]
// 省市名称
const
provinceName
=
provinceList
[
region
[
0
]].
addressName
const
cityName
=
provinceList
[
region
[
0
]].
children
[
region
[
1
]].
addressName
const
townName
=
provinceList
[
region
[
0
]].
children
[
region
[
1
]].
children
[
region
[
2
]].
addressName
const
provinceNameData
=
[
provinceName
,
cityName
,
townName
]
this
.
triggerEvent
(
'getProvinceCode'
,{
codeData
,
provinceNameData
})
this
.
triggerEvent
(
'cancelProvince'
)
},
// 取消
cancel
()
{
this
.
triggerEvent
(
'cancelProvince'
)
}
}
})
packageMine/pages/address/detail/components/AreaSelect/index.json
deleted
100644 → 0
View file @
bbd5a1d
{
"component"
:
true
,
"usingComponents"
:
{}
}
\ No newline at end of file
packageMine/pages/address/detail/components/AreaSelect/index.scss
deleted
100644 → 0
View file @
bbd5a1d
.dialog_mask
{
position
:
fixed
;
top
:
0
;
left
:
0
;
right
:
0
;
bottom
:
0
;
z-index
:
10
;
background
:
rgba
(
0
,
0
,
0
,
0
.5
);
}
.dialog_container
{
position
:
absolute
;
left
:
0
;
right
:
0
;
bottom
:
0
;
width
:
100%
;
height
:
70%
;
background
:
white
;
border-radius
:
40rpx
40rpx
0
0
;
box-shadow
:
0px
-2rpx
4rpx
0px
rgba
(
0
,
0
,
0
,
0
.06
);
z-index
:
9999
;
}
.header
{
height
:
112rpx
;
box-sizing
:
border-box
;
padding
:
0
32rpx
;
}
.header
.cancle
{
font-size
:
28rpx
;
font-weight
:
500
;
color
:
#969799
;
}
.header
.title
{
font-size
:
32rpx
;
font-weight
:
500
;
color
:
#323233
;
}
.header
.comfirm
{
font-size
:
28rpx
;
font-weight
:
500
;
color
:
#8A303A
;
}
.main
{
height
:
calc
(
100%
-
112rpx
);
box-sizing
:
border-box
;
padding
:
0
32rpx
;
}
.flex_scb
{
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
}
\ No newline at end of file
packageMine/pages/address/detail/components/AreaSelect/index.wxml
deleted
100644 → 0
View file @
bbd5a1d
<view wx:if="{{provinceShow}}" class="dialog_mask {{provinceShow?'dialog_show':''}}">
<view class="dialog_mask" bindtap="cancel"></view>
<view class="dialog_container">
<view class="header flex_scb">
<view class="cancle" bindtap="cancel">取消</view>
<view class="title">城市地区</view>
<view class="comfirm" bindtap="comfirm">确定</view>
</view>
<view class="main">
<picker-view indicator-style="height: 50px;" style="width: 100%; height: 100%;" value="{{region}}" bindchange="bindChange">
<picker-view-column>
<view wx:for="{{provinceList}}" wx:key="{{item.addressCode}}" style="line-height: 50px; text-align: center;">
{{item.addressName}}
</view>
</picker-view-column>
<picker-view-column>
<view wx:for="{{provinceList[region[0]].children}}" wx:key="{{item.addressCode}}" style="line-height: 50px; text-align: center;">
{{item.addressName}}
</view>
</picker-view-column>
<picker-view-column>
<view wx:for="{{provinceList[region[0]].children[region[1]].children}}" wx:key="{{item.addressCode}}" style="line-height: 50px; text-align: center;">
{{item.addressName}}
</view>
</picker-view-column>
</picker-view>
</view>
</view>
</view>
\ No newline at end of file
packageMine/pages/address/detail/detail.json
View file @
24b6e31
{
"navigationBarTitleText"
:
"新建收货地址"
,
"usingComponents"
:{
"area-select"
:
"./components/AreaSelect/index"
,
"gl-textarea"
:
"/components/GlTextarea/GlTextarea"
}
}
\ No newline at end of file
packageMine/pages/coupon/recommend/recommend.json
View file @
24b6e31
{
"navigationBarTitleText"
:
"卡券详情"
,
"usingComponents"
:
{
"coupon-item"
:
"../components/CouponsItem/element"
}
}
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