Toggle navigation
Toggle navigation
This project
Loading...
Sign in
developOne
/
harmonyPool
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
陈剑华
2024-05-08 15:30:02 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
255c552bdd5c4f465df63c55983693e41f4beb15
255c552b
1 parent
eada8111
fix: 直播预约卡预约功能debug
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
sight_harmony/features/wdComponent/src/main/ets/components/compview/ZhSingleRow03.ets
sight_harmony/features/wdComponent/src/main/ets/components/compview/ZhSingleRow03.ets
View file @
255c552
...
...
@@ -31,7 +31,7 @@ export struct ZhSingleRow03 {
@State compDTO: CompDTO = {} as CompDTO
@State isEndEdge: boolean = false;
// @State reserveStatus: reserveItem[] = []
@State reservedIds:
number
[] = [];
@State reservedIds:
string
[] = [];
scroller: Scroller = new Scroller()
aboutToAppear(): void {
...
...
@@ -51,19 +51,19 @@ export struct ZhSingleRow03 {
// this.reserveStatus = res;
res.map((item: reserveItem) => {
if (item.subscribe) {
this.reservedIds.push(item.liveId)
this.reservedIds.push(item.liveId
.toString()
)
}
})
}
// 判断是否预约
isReserved(liveId: number) {
return this.reservedIds.includes(liveId)
return this.reservedIds.includes(liveId
.toString()
)
}
// 预约/取消预约
async bookAndCancel(relationId: string, liveId: string, isSubscribe: boolean) {
const res = await LiveModel.liveAppointment(relationId
, liveId
, isSubscribe);
const res = await LiveModel.liveAppointment(relationId
.toString(), liveId.toString()
, isSubscribe);
if (res.code == 0) {
ToastUtils.shortToast(isSubscribe ? '预约成功' : '取消预约成功')
this.getReserveState();
...
...
Please
register
or
login
to post a comment