Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
杨炀
/
ztx_wx_gzt
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
daf1a72d
authored
2026-05-19 11:46:14 +0800
by
lttnew
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
考点
1 parent
0c7779fa
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
473 additions
and
109 deletions
components/dao-guan-tab-bar.vue
myCenter/chooseExaminer.vue
myCenter/examPointApply.vue
myCenter/examPointApplyList.vue
pages/index/daoGuanLevel.vue
pages/index/daoGuanMy.vue
pages/index/daoGuanPerson.vue
pages/invoice/applyFeisui.vue
personal/addVip_per.vue
components/dao-guan-tab-bar.vue
View file @
daf1a72
...
...
@@ -35,11 +35,11 @@ const emit = defineEmits(['switch'])
const
switching
=
ref
(
false
)
const
tabs
=
[
{
text
:
'人员'
,
url
:
'/pages/index/daoGuanPerson'
,
icon
:
'/static/img/tool01.png'
,
activeIcon
:
'
/static/img/tool01_dwn.png'
},
{
text
:
'订单'
,
url
:
'/pages/index/daoGuanOrder'
,
icon
:
'/static/img/tool02.png'
,
activeIcon
:
'
/static/img/tool02_dwn.png'
},
{
text
:
'通知'
,
url
:
'/pages/index/daoGuanNotice'
,
icon
:
'/static/img/tool03.png'
,
activeIcon
:
'
/static/img/tool03_dwn.png'
},
{
text
:
'级位'
,
url
:
'/pages/index/daoGuanLevel'
,
icon
:
'/static/img/tool04.png'
,
activeIcon
:
'
/static/img/tool04_dwn.png'
},
{
text
:
'我的'
,
url
:
'/pages/index/daoGuanMy'
,
icon
:
'/static/img/tool05.png'
,
activeIcon
:
'
/static/img/tool05_dwn.png'
},
{
text
:
'人员'
,
url
:
'/pages/index/daoGuanPerson'
,
icon
:
config
.
baseUrl_api
+
'/fs/static/img/tool01.png'
,
activeIcon
:
config
.
baseUrl_api
+
'/fs
/static/img/tool01_dwn.png'
},
{
text
:
'订单'
,
url
:
'/pages/index/daoGuanOrder'
,
icon
:
config
.
baseUrl_api
+
'/fs/static/img/tool02.png'
,
activeIcon
:
config
.
baseUrl_api
+
'/fs
/static/img/tool02_dwn.png'
},
{
text
:
'通知'
,
url
:
'/pages/index/daoGuanNotice'
,
icon
:
config
.
baseUrl_api
+
'/fs/static/img/tool03.png'
,
activeIcon
:
config
.
baseUrl_api
+
'/fs
/static/img/tool03_dwn.png'
},
{
text
:
'级位'
,
url
:
'/pages/index/daoGuanLevel'
,
icon
:
config
.
baseUrl_api
+
'/fs/static/img/tool04.png'
,
activeIcon
:
config
.
baseUrl_api
+
'/fs
/static/img/tool04_dwn.png'
},
{
text
:
'我的'
,
url
:
'/pages/index/daoGuanMy'
,
icon
:
config
.
baseUrl_api
+
'/fs/static/img/tool05.png'
,
activeIcon
:
config
.
baseUrl_api
+
'/fs
/static/img/tool05_dwn.png'
},
]
const
tabBgLeft
=
computed
(()
=>
{
...
...
myCenter/chooseExaminer.vue
View file @
daf1a72
...
...
@@ -5,7 +5,7 @@
<image
class=
"empty-img"
mode=
"aspectFit"
:src=
"config.baseUrl_api + '/fs/static/nodata.png'"
></image>
<text
class=
"empty-text"
>
暂无考官数据
</text>
<
button
class=
"go-lib-btn"
@
click=
"goPath('/level/chooseExaminer?pageType=0')"
>
去考官库添加考官吧
</button
>
<
!--
<button
class=
"go-lib-btn"
@
click=
"goPath('/level/chooseExaminer?pageType=0')"
>
去考官库添加考官吧
</button>
--
>
</view>
<!--
<view
class=
"empty-tip"
v-else-if=
"infoList.length === 0"
>
暂无可添加的考官
</view>
-->
...
...
myCenter/examPointApply.vue
View file @
daf1a72
...
...
@@ -4,9 +4,9 @@
<custom-modal
ref=
"customModalRef"
:cancelText=
"modalConfig.cancelText"
:confirmText=
"modalConfig.confirmText"
:content=
"modalConfig.content"
:showCancel=
"modalConfig.showCancel"
:title=
"modalConfig.title"
@
confirm=
"onModalConfirm"
/>
<!-- 考官选择类型 -->
<
!--
<
view
class=
"radio-section"
>
<view
class=
"radio-section"
>
<radio-group
class=
"radio-group"
@
change=
"onSelfSelectChange"
>
<label
class=
"radio-item"
>
<radio
:checked=
"form.selfSelect == '1'"
class=
"custom-radio"
value=
"1"
/>
...
...
@@ -17,36 +17,40 @@
<text
class=
"radio-text"
>
省跆协指派考官
</text>
</label>
</radio-group>
</view>
-->
</view>
<!-- 温馨提示 -->
<view
v-if=
"form.selfSelect == '1'"
class=
"tip-box"
>
<view
class=
"tip-box"
>
<text
class=
"tip-text"
>
温馨提示:
您可以自行录入考官信息,如果暂时没有考官,可以选择由省跆协指派进行考点申报,请尽快完成考点考官的认证。
</text>
</view>
<!-- 省跆协指派提示 -->
<view
v-if=
"form.selfSelect == '0'"
class=
"tip-box"
>
<
!--
<
view
v-if=
"form.selfSelect == '0'"
class=
"tip-box"
>
<text
class=
"tip-text"
>
温馨提示:关于考官指派,请联系
{{
shenForm
.
baseName
||
''
}}
,联系电话:
{{
shenForm
.
phone
||
''
}}
</text>
</view>
</view>
-->
<view
class=
"section"
>
<!-- 自行录入考官区域 -->
<view
v-if=
"form.selfSelect == '1'"
class=
"section examiner-section"
>
<button
class=
"add-btn"
@
click=
"handelAddExamine"
>
+ 添加考官
</button>
<button
class=
"add-btn"
@
click=
"addExaminer"
>
+ 添加考官
</button>
</view>
<view
v-else
class=
"section examiner-section"
>
<button
class=
"add-btn"
@
click=
"addExaminer"
>
+ 选择考官
</button>
</view>
<view
v-if=
"form.selfSelect == '1'"
class=
"examiner-list"
>
<view
v-for=
"
(item, index)
in list"
:key=
"item.id"
class=
"examiner-item"
>
<view
class=
"examiner-list"
>
<view
v-for=
"
item
in list"
:key=
"item.id"
class=
"examiner-item"
>
<view
class=
"info"
>
<text
class=
"name"
>
{{
item
.
perName
}}
{{
item
.
perCode
}}
</text>
<text
class=
"idc"
>
证件号码:
{{
item
.
perIdcCode
}}
</text>
<text
class=
"reg"
>
注册地:
{{
item
.
memName
}}
</text>
<text
class=
"reg"
>
注册地:
{{
JSON
.
parse
(
item
.
roleInfo
).
unit
||
''
}}
</text>
</view>
<button
class=
"del-btn"
@
click=
"handleDel(item)"
>
删除
</button>
</view>
</view>
...
...
@@ -55,6 +59,44 @@
<view
class=
"submit-area"
>
<button
class=
"submit-btn"
@
click=
"handelSubmit"
>
确定提交
</button>
</view>
<!-- 添加考官弹框 -->
<uni-popup
ref=
"addPopup"
type=
"bottom"
background-color=
"#fff"
>
<view
class=
"popBody"
style=
"background:#fff;"
>
<view
class=
"h3 text-center"
>
添加考官
</view>
<view
class=
"form-item"
>
<text
class=
"label"
>
考官姓名
</text>
<uni-easyinput
v-model=
"addForm.name"
placeholder=
"请输入考官姓名"
/>
</view>
<view
class=
"form-item"
>
<text
class=
"label"
>
考官编号
</text>
<uni-easyinput
v-model=
"addForm.certCode"
placeholder=
"请输入考官编号"
/>
</view>
<view
class=
"btn-group"
>
<button
class=
"btn-cancel"
@
click=
"closeAddPopup"
>
取消
</button>
<button
class=
"btn-confirm"
@
click=
"searchAndAdd"
>
查询
</button>
</view>
<!-- 搜索结果 -->
<view
v-if=
"searchResult"
class=
"search-result"
>
<view
class=
"result-item"
>
<view
class=
"info"
>
<view
class=
"name"
>
{{
searchResult
.
perName
}}
</view>
<view
class=
"date"
>
会员号:
{{
searchResult
.
perCode
||
'-'
}}
</view>
<view
class=
"date"
>
证件号码:
{{
searchResult
.
idcCode
||
'-'
}}
</view>
<view
class=
"date"
>
注册地:
{{
searchResult
.
memName
||
'-'
}}
</view>
</view>
<view
class=
"action"
>
<text
v-if=
"searchResult.added"
class=
"text-gray"
>
已添加
</text>
<text
v-else
class=
"text-primary"
@
click=
"doAddExaminer(searchResult)"
>
添加
</text>
</view>
</view>
</view>
<view
v-if=
"searchNoData"
class=
"no-data"
>
<text>
未查询到考官信息
</text>
</view>
</view>
</uni-popup>
</view>
</
template
>
...
...
@@ -74,6 +116,16 @@ const list = ref([])
const
memId
=
ref
(
null
)
const
shenForm
=
ref
({})
// 选择考官弹框
const
addPopup
=
ref
(
null
)
const
addForm
=
ref
({
type
:
1
,
name
:
''
,
certCode
:
''
})
const
searchResult
=
ref
(
null
)
const
searchNoData
=
ref
(
false
)
// 自定义弹窗
const
customModalRef
=
ref
(
null
)
const
modalConfig
=
ref
({
...
...
@@ -128,22 +180,75 @@ function handleDel(row) {
function
onSelfSelectChange
(
e
)
{
form
.
value
.
selfSelect
=
e
.
detail
.
value
showExamine
.
value
=
e
.
detail
.
value
==
'1'
if
(
e
.
detail
.
value
==
'0'
)
{
modalAction
=
'assign'
modalConfig
.
value
=
{
title
:
'温馨提示'
,
content
:
`关于考官指派,请联系
${
shenForm
.
value
.
baseName
||
''
}
,联系电话:
${
shenForm
.
value
.
phone
||
''
}
`
,
showCancel
:
false
,
confirmText
:
'我知道了'
}
customModalRef
.
value
.
open
()
// if (e.detail.value == '0') {
// modalAction = 'assign'
// modalConfig.value = {
// title: '温馨提示',
// content: `关于考官指派,请联系${shenForm.value.baseName || ''},联系电话:${shenForm.value.phone || ''}`,
// showCancel: false,
// confirmText: '我知道了'
// }
// customModalRef.value.open()
// }
}
// 打开添加考官弹窗
function
addExaminer
()
{
addForm
.
value
.
name
=
''
addForm
.
value
.
certCode
=
''
searchResult
.
value
=
null
searchNoData
.
value
=
false
addPopup
.
value
.
open
()
}
// 关闭添加考官弹窗
function
closeAddPopup
()
{
addPopup
.
value
.
close
()
}
// 搜索并添加考官
function
searchAndAdd
()
{
if
(
!
addForm
.
value
.
name
)
{
uni
.
showToast
({
title
:
'请输入考官姓名'
,
icon
:
'none'
})
return
}
if
(
!
addForm
.
value
.
certCode
)
{
uni
.
showToast
({
title
:
'请输入考官编号'
,
icon
:
'none'
})
return
}
uni
.
showLoading
({
title
:
'查询中'
})
api
.
getCoachList
(
addForm
.
value
).
then
(
res
=>
{
uni
.
hideLoading
()
if
(
res
.
rows
&&
res
.
rows
.
length
>
0
)
{
searchResult
.
value
=
res
.
rows
[
0
]
// 检查是否已添加
const
isAdded
=
list
.
value
.
some
(
l
=>
l
.
perId
===
searchResult
.
value
.
perId
)
if
(
isAdded
)
{
searchResult
.
value
.
added
=
true
}
searchNoData
.
value
=
false
}
else
{
searchResult
.
value
=
null
searchNoData
.
value
=
true
}
}).
catch
(()
=>
{
uni
.
hideLoading
()
searchResult
.
value
=
null
searchNoData
.
value
=
true
})
}
function
handelAddExamine
()
{
const
chosenStr
=
JSON
.
stringify
(
list
.
value
)
uni
.
navigateTo
({
url
:
`/myCenter/chooseExaminer?memId=
${
memId
.
value
}
&chosen=
${
chosenStr
}
`
// 执行添加考官
function
doAddExaminer
(
row
)
{
uni
.
showLoading
({
title
:
'添加中'
})
api
.
selfAdd
(
row
.
perId
).
then
(()
=>
{
uni
.
hideLoading
()
uni
.
showToast
({
title
:
'添加成功'
,
icon
:
'success'
})
addPopup
.
value
.
close
()
getExaminer
()
}).
catch
(()
=>
{
uni
.
hideLoading
()
uni
.
showToast
({
title
:
'添加失败'
,
icon
:
'error'
})
})
}
...
...
@@ -417,4 +522,107 @@ function confirmApply() {
.btn-cancel
::after
,
.btn-confirm
::after
{
border
:
none
;
}
/* 添加考官弹框 */
.popBody
{
width
:
100%
;
padding
:
40
rpx
30
rpx
;
padding-bottom
:
calc
(
40
rpx
+
env
(
safe-area-inset-bottom
));
background
:
#fff
;
border-radius
:
24
rpx
24
rpx
0
0
;
box-sizing
:
border-box
;
}
.popBody
.h3
{
font-size
:
32
rpx
;
font-weight
:
bold
;
margin-bottom
:
30
rpx
;
text-align
:
center
;
}
.popBody
.form-item
{
margin-bottom
:
20
rpx
;
}
.popBody
.form-item
.label
{
display
:
block
;
font-size
:
28
rpx
;
color
:
#333
;
margin-bottom
:
10
rpx
;
}
.popBody
.btn-group
{
display
:
flex
;
justify-content
:
center
;
gap
:
40
rpx
;
margin-top
:
30
rpx
;
}
.popBody
.btn-cancel
,
.popBody
.btn-confirm
{
width
:
200
rpx
;
height
:
70
rpx
;
line-height
:
70
rpx
;
font-size
:
28
rpx
;
border-radius
:
35
rpx
;
}
.popBody
.btn-cancel
{
background
:
#fff
;
color
:
#C4121B
;
border
:
1px
solid
#C4121B
;
}
.popBody
.btn-confirm
{
background
:
#C4121B
;
color
:
#fff
;
}
.search-result
{
margin-top
:
30
rpx
;
border-top
:
1px
solid
#eee
;
padding-top
:
20
rpx
;
}
.search-result
.result-item
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
padding
:
20
rpx
;
background
:
#f9f9f9
;
border-radius
:
8
rpx
;
}
.search-result
.result-item
.name
{
font-size
:
30
rpx
;
font-weight
:
bold
;
margin-bottom
:
8
rpx
;
}
.search-result
.result-item
.date
{
font-size
:
24
rpx
;
color
:
#666
;
margin-top
:
4
rpx
;
}
.search-result
.result-item
.action
{
font-size
:
28
rpx
;
color
:
#007aff
;
padding
:
10
rpx
20
rpx
;
}
.no-data
{
text-align
:
center
;
padding
:
40
rpx
;
color
:
#999
;
font-size
:
28
rpx
;
}
.text-primary
{
color
:
#007aff
;
}
.text-gray
{
color
:
#999
;
}
</
style
>
...
...
myCenter/examPointApplyList.vue
View file @
daf1a72
...
...
@@ -2,7 +2,7 @@
<view
class=
"exam-point-list"
>
<!-- 顶部申请按钮 -->
<view
v-if=
"status==0"
class=
"apply-btn-box"
>
<button
:disabled=
"memberInfo.isPoints==0
||formInfo.auditStatus==2||formInfo.auditStatus==1
"
class=
"apply-btn"
<button
:disabled=
"memberInfo.isPoints==0
&&(formInfo.auditStatus==2||formInfo.auditStatus==1)
"
class=
"apply-btn"
@
click=
"goApply"
>
申请考点
</button>
</view>
...
...
pages/index/daoGuanLevel.vue
View file @
daf1a72
<
template
>
<view
class=
"level-page"
>
<!-- 提示弹框 -->
<custom-modal
ref=
"tipModalRef"
title=
"提示"
:content=
"tipContent"
:showCancel=
"false"
confirmText=
"我知道了"
@
confirm=
"onTipConfirm"
/>
<view
class=
"hero"
>
<image
class=
"hero-bg"
:src=
"config.baseUrl_api + '/fs/static/img/top.png'"
mode=
"aspectFill"
></image>
<view
class=
"hero-brand"
>
...
...
@@ -18,7 +21,7 @@
</view>
<view
class=
"level-grid"
>
<image
class=
"level-card"
:src=
"config.baseUrl_api + '/fs/static/img/jw_btn01.png'"
mode=
"aspectFit"
@
click=
"go
Path('/level/addApply')
"
></image>
<image
class=
"level-card"
:src=
"config.baseUrl_api + '/fs/static/img/jw_btn01.png'"
mode=
"aspectFit"
@
click=
"go
ToAddApply
"
></image>
<image
class=
"level-card"
:src=
"config.baseUrl_api + '/fs/static/img/jw_btn02.png'"
mode=
"aspectFit"
@
click=
"goPath('/personalVip/addChangeLevel')"
></image>
<image
class=
"level-card"
:src=
"config.baseUrl_api + '/fs/static/img/jw_btn03.png'"
mode=
"aspectFit"
@
click=
"goPath('/level/apply')"
></image>
<image
class=
"level-card"
:src=
"config.baseUrl_api + '/fs/static/img/jw_btn04.png'"
mode=
"aspectFit"
@
click=
"goPath('/personalVip/changeLevel')"
></image>
...
...
@@ -33,6 +36,12 @@
<
script
setup
>
import
config
from
'@/config.js'
import
DaoGuanTabBar
from
'@/components/dao-guan-tab-bar.vue'
import
customModal
from
'@/components/custom-modal.vue'
import
{
ref
}
from
'vue'
const
app
=
getApp
()
const
tipModalRef
=
ref
(
null
)
const
tipContent
=
ref
(
''
)
const
onTabSwitch
=
()
=>
{
// tab switch handled by component
...
...
@@ -41,6 +50,26 @@ const onTabSwitch = () => {
const
goPath
=
(
url
)
=>
{
uni
.
navigateTo
({
url
})
}
function
onTipConfirm
()
{
// 关闭提示弹框
}
function
goToAddApply
()
{
const
deptType
=
app
.
globalData
.
deptType
const
isPoints
=
app
.
globalData
.
memberInfo
?.
isPoints
console
.
log
(
'isPoints:'
,
isPoints
)
// 如果 deptType == 1 且 isPoints != 1,弹出提示
if
(
isPoints
==
1
)
{
tipContent
.
value
=
'当前暂未完成考点认证,如需开设级位考试,请先提交考点申请。'
tipModalRef
.
value
.
open
()
return
}
// 否则正常跳转
goPath
(
'/level/addApply'
)
}
</
script
>
<
style
lang=
"scss"
scoped
>
...
...
pages/index/daoGuanMy.vue
View file @
daf1a72
...
...
@@ -45,6 +45,14 @@
<text
class=
"arrow"
>
>
</text>
</view>
<view
class=
"menu-item"
@
click=
"goPath('/myCenter/examPointApplyList')"
>
<view
class=
"menu-left"
>
<image
class=
"menu-icon"
:src=
"config.baseUrl_api + '/fs/static/img/user02.png'"
mode=
"aspectFit"
></image>
<text>
考点认证
</text>
</view>
<text
class=
"arrow"
>
>
</text>
</view>
<view
class=
"menu-item"
@
click=
"goPath('/myCenter/safe')"
>
<view
class=
"menu-left"
>
<image
class=
"menu-icon"
:src=
"config.baseUrl_api + '/fs/static/img/user03.png'"
mode=
"aspectFit"
></image>
...
...
pages/index/daoGuanPerson.vue
View file @
daf1a72
...
...
@@ -68,8 +68,7 @@
<view
class=
"dialog-title"
>
申请成为考点
</view>
<view
class=
"dialog-message"
>
<text>
恭喜您成为中国跆拳道协会单位会员!
</text>
<text>
根据协会考点管理办法,需成为考点单位才能进行考级业务的办理。
</text>
<text>
是否现在申请成为考点。
</text>
<text>
根据协会考点管理办法,需成为考点单位才能进行考级业务的办理。是否现在申请成为考点?
</text>
</view>
<view
class=
"dialog-footer"
>
<button
class=
"dialog-btn cancel"
@
click=
"closeExamPointDialog"
>
取消
</button>
...
...
@@ -566,7 +565,7 @@ const onTabSwitch = () => {
color
:
#555
;
font-size
:
28
rpx
;
line-height
:
1.6
;
text-align
:
center
;
//
text-align
:
center
;
}
.dialog-footer
{
...
...
@@ -597,6 +596,6 @@ const onTabSwitch = () => {
margin-top
:
24
rpx
;
color
:
#999
;
font-size
:
24
rpx
;
text-align
:
center
;
text-align
:
right
;
}
</
style
>
...
...
pages/invoice/applyFeisui.vue
View file @
daf1a72
...
...
@@ -11,30 +11,31 @@
<view
class=
"form-item"
>
<text
class=
"label"
>
发票类型
</text>
<view
class=
"type-select"
>
<view
:class=
"
{ active: form.type === '
1
' }"
<view
:class=
"
{ active: form.type === '
0
' }"
class="type-option"
@click="form.type = '
1
'"
@click="form.type = '
0
'"
>
<view
class=
"type-icon"
>
<text
class=
"icon-text"
>
个
</text>
<view
class=
"type-icon
enterprise
"
>
<text
class=
"icon-text"
>
企
</text>
</view>
<view
class=
"type-info"
>
<text
class=
"type-name"
>
个人
</text>
<text
class=
"type-name"
>
企业单位
</text>
</view>
</view>
<view
:class=
"
{ active: form.type === '
0
' }"
:class=
"
{ active: form.type === '
1
' }"
class="type-option"
@click="form.type = '
0
'"
@click="form.type = '
1
'"
>
<view
class=
"type-icon
enterprise
"
>
<text
class=
"icon-text"
>
企
</text>
<view
class=
"type-icon"
>
<text
class=
"icon-text"
>
个
</text>
</view>
<view
class=
"type-info"
>
<text
class=
"type-name"
>
企业
</text>
<text
class=
"type-name"
>
个人/非
企业
</text>
</view>
</view>
</view>
</view>
...
...
@@ -44,7 +45,7 @@
<input
v-model=
"form.name"
class=
"input"
placeholder=
"请输入公司全称或个人姓名
"
:placeholder=
"form.type === '0' ? '请输入公司全称' : '请输入发票抬头'
"
/>
<text
class=
"hint"
>
请确保发票抬头与公司营业执照或个人身份证上的名称一致
</text>
</view>
...
...
@@ -89,7 +90,7 @@ const form = reactive({
id
:
''
,
// 订单ID
name
:
''
,
// 发票抬头
taxno
:
''
,
// 纳税人识别号
type
:
'
1
'
,
// 发票类型:1=个人 0=企业
type
:
'
0
'
,
// 发票类型:1=个人 0=企业
amount
:
0
// 金额
});
...
...
personal/addVip_per.vue
View file @
daf1a72
...
...
@@ -92,6 +92,26 @@
</view>
<view
class=
"fixedBottom"
><button
class=
"btn-red"
@
click=
"goSubmit"
>
确 定
</button></view>
<!-- 个人中心浮动按钮 -->
<view
class=
"float-btn"
@
click=
"goHome"
>
<uni-icons
type=
"person-filled"
size=
"32"
color=
"#fff"
></uni-icons>
</view>
<!-- 有效期提示弹框 -->
<view
class=
"validity-modal"
v-if=
"showValidityModal"
>
<view
class=
"validity-modal-mask"
@
click=
"closeValidityModal"
></view>
<view
class=
"validity-modal-content"
>
<view
class=
"validity-modal-title"
>
提示
</view>
<view
class=
"validity-modal-body"
>
当前会员有效期为
{{
validityDateText
}}
,是否继续缴费?
</view>
<view
class=
"validity-modal-footer"
>
<button
class=
"btn-modal-cancel"
@
click=
"goHomeFromModal"
>
个人中心
</button>
<button
class=
"btn-modal-confirm"
@
click=
"goPayFromModal"
>
继续缴费
</button>
</view>
</view>
</view>
</view>
</
template
>
...
...
@@ -179,6 +199,9 @@ const imageStylesZJ = ref({
height
:
'316rpx'
});
const
showValidityModal
=
ref
(
false
)
const
validityDateText
=
ref
(
''
)
onLoad
(
async
(
option
)
=>
{
if
(
option
.
name
&&
option
.
idcCode
)
{
baseFormData
.
value
.
name
=
option
.
name
...
...
@@ -303,6 +326,8 @@ function upIdCardImgFront(e) {
baseFormData
.
value
.
uuid
=
res
.
data
.
uuid
baseFormData
.
value
.
perCode
=
res
.
data
.
perCode
||
''
baseFormData
.
value
.
validityDate
=
res
.
data
.
validityDate
?.
slice
(
0
,
10
)
//去掉时分秒
// 检查有效期,未过期则弹出提示
checkAndShowValidityModal
()
// baseFormData.value.cityId = res.data.cityId
// baseFormData.value.address = res.data.address
}
else
{
...
...
@@ -391,6 +416,7 @@ function getExtractInfo(obj) {
baseFormData
.
value
.
phone
=
res
.
data
.
phone
baseFormData
.
value
.
perCode
=
res
.
data
.
perCode
||
''
baseFormData
.
value
.
validityDate
=
res
.
data
.
validityDate
?.
slice
(
0
,
10
)
//去掉时分秒
checkAndShowValidityModal
()
// baseFormData.value.cityId = res.data.cityId
// baseFormData.value.address = res.data.address
if
(
res
.
data
.
photo
)
{
...
...
@@ -547,72 +573,59 @@ function goSubmit() {
content
:
'请确认信息正确'
,
success
:
function
(
res
)
{
if
(
res
.
confirm
)
{
if
(
baseFormData
.
value
.
idcType
==
'4'
)
{
baseFormData
.
value
.
idcType
=
'0'
}
delete
baseFormData
.
value
.
card
const
time
=
new
Date
().
valueOf
()
+
''
baseFormData
.
value
.
t
=
time
+
Math
.
floor
(
Math
.
random
()
*
10
)
baseFormData
.
value
.
signT
=
aes2
.
AESEncrypt
(
baseFormData
.
value
.
idcType
+
time
)
const
baseFormDataJson
=
encodeURIComponent
(
JSON
.
stringify
(
baseFormData
.
value
))
api
.
insertSinglePay
({
...
baseFormData
.
value
,
payYear
:
1
,
payType
:
1
,
validityDate
:
undefined
}).
then
(
res
=>
{
if
(
res
.
code
==
200
)
{
uni
.
navigateTo
({
url
:
`/personal/goPay_per?baseFormData=
${
baseFormDataJson
}
`
})
}
})
// uni.showModal({
// content: '保存成功',
// title: '提示',
// confirmText:'去支付',
// cancelColor:'个人中心',
// success: function(res) {
// },
// fail:function(){
// uni.reLaunch({
// url:`/personal/home`
// })
// }
// })
// api.addPersonToMyDept(baseFormData.value).then(Response => {
// if (Response.data == 0) {
// let msg = '该成员,实名认证未通过,注册失败!'
// uni.showModal({
// content: msg,
// title: '提示',
// success: function() {}
// })
// return
// }
// if (Response.data * 1 < 0) {
// // 会员调入弹出
// uni.showModal({
// content: '该会员已存在其他道馆,如需添加,请发起会员调动',
// title: '提示',
// success: function() {}
// })
// return
// }
// // let msg = '保存成功'
// })
goPay
()
}
}
});
}
function
goPay
()
{
if
(
baseFormData
.
value
.
idcType
==
'4'
)
{
baseFormData
.
value
.
idcType
=
'0'
}
delete
baseFormData
.
value
.
card
const
time
=
new
Date
().
valueOf
()
+
''
baseFormData
.
value
.
t
=
time
+
Math
.
floor
(
Math
.
random
()
*
10
)
baseFormData
.
value
.
signT
=
aes2
.
AESEncrypt
(
baseFormData
.
value
.
idcType
+
time
)
const
baseFormDataJson
=
encodeURIComponent
(
JSON
.
stringify
(
baseFormData
.
value
))
// 直接跳转到支付页,由 goPay_per 调用 insertSinglePay 创建订单
uni
.
navigateTo
({
url
:
`/personal/goPay_per?baseFormData=
${
baseFormDataJson
}
`
})
}
function
checkAndShowValidityModal
()
{
const
validityDateStr
=
baseFormData
.
value
.
validityDate
if
(
validityDateStr
&&
validityDateStr
.
trim
&&
validityDateStr
.
trim
())
{
const
now
=
new
Date
()
const
validityDate
=
new
Date
(
validityDateStr
)
if
(
!
isNaN
(
validityDate
.
getTime
())
&&
validityDate
>
now
)
{
validityDateText
.
value
=
validityDateStr
showValidityModal
.
value
=
true
return
true
}
}
return
false
}
function
closeValidityModal
()
{
showValidityModal
.
value
=
false
}
function
goHomeFromModal
()
{
closeValidityModal
()
uni
.
reLaunch
({
url
:
'/personal/home'
})
}
function
goPayFromModal
()
{
closeValidityModal
()
goPay
()
}
function
getUserInfo
()
{
api
.
getInfo
(
perId
.
value
).
then
(
res
=>
{
baseFormData
.
value
=
res
.
data
...
...
@@ -620,6 +633,12 @@ function getUserInfo() {
','
).
replaceAll
(
','
,
'/'
)
})
}
function
goHome
()
{
uni
.
reLaunch
({
url
:
'/personal/home'
})
}
</
script
>
<
style
lang=
"scss"
>
...
...
@@ -772,5 +791,105 @@ function getUserInfo() {
:deep
(
.fixUniFormItemStyle
.uni-data-picker__text
)
{
text-align
:
left
!important
;
}
/* 个人中心浮动按钮 */
.float-btn
{
position
:
fixed
;
right
:
5
rpx
;
bottom
:
240
rpx
;
width
:
100
rpx
;
height
:
100
rpx
;
border-radius
:
50%
;
background
:
#C40F18
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
box-shadow
:
0
4
rpx
16
rpx
rgba
(
196
,
15
,
24
,
0.4
);
z-index
:
99
;
}
.float-btn-text
{
color
:
#fff
;
font-size
:
24
rpx
;
font-weight
:
bold
;
}
/* 有效期提示弹框 */
.validity-modal
{
position
:
fixed
;
top
:
0
;
left
:
0
;
right
:
0
;
bottom
:
0
;
z-index
:
1000
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
}
.validity-modal-mask
{
position
:
absolute
;
top
:
0
;
left
:
0
;
right
:
0
;
bottom
:
0
;
background
:
rgba
(
0
,
0
,
0
,
0.5
);
}
.validity-modal-content
{
position
:
relative
;
width
:
560
rpx
;
background
:
#fff
;
border-radius
:
16
rpx
;
overflow
:
hidden
;
z-index
:
1001
;
}
.validity-modal-title
{
text-align
:
center
;
font-size
:
34
rpx
;
font-weight
:
bold
;
padding
:
30
rpx
0
20
rpx
;
color
:
#333
;
}
.validity-modal-body
{
padding
:
20
rpx
40
rpx
40
rpx
;
font-size
:
30
rpx
;
color
:
#666
;
line-height
:
1.6
;
text-align
:
center
;
}
.validity-modal-footer
{
display
:
flex
;
justify-content
:
space-between
;
padding
:
0
40
rpx
40
rpx
;
gap
:
24
rpx
;
}
.validity-modal-footer
button
{
flex
:
1
;
height
:
80
rpx
;
line-height
:
80
rpx
;
font-size
:
28
rpx
;
border-radius
:
40
rpx
;
border
:
none
;
}
.validity-modal-footer
button
::after
{
border
:
none
;
}
.btn-modal-cancel
{
color
:
#666
;
background
:
#f5f5f5
;
}
.btn-modal-confirm
{
color
:
#fff
;
background
:
#C40F18
;
font-weight
:
bold
;
}
</
style
>
...
...
Write
Preview
Styling with
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