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-16 17:37:06 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
84ec864cedf0cd88ee2cfeafd11eb35b51cd4f9e
84ec864c
1 parent
ad1b5e13
feat(意见反馈):UI调整4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
41 additions
and
13 deletions
sight_harmony/features/wdComponent/src/main/ets/components/FeedBackActivity.ets
sight_harmony/features/wdComponent/src/main/ets/components/FeedBackActivity.ets
View file @
84ec864
...
...
@@ -19,6 +19,7 @@ const TAG = 'FeedBackActivity'
@Entry
@Component
export struct FeedBackActivity {
@State canSubmit: boolean = false;
@State textNumLabel: string = '0/500';
contact: string = "";
email: string = "";
...
...
@@ -59,6 +60,10 @@ export struct FeedBackActivity {
}) {
Row(){
Toggle({ type: ToggleType.Checkbox, isOn: false })
.onChange((select) => {
feedbackTypeBean.isselect = select
this.canSubmit = this.checkSubmit()
})
Text(feedbackTypeBean.classifyName)
.fontColor($r('app.color.color_222222'))
.fontSize($r('app.float.font_size_14'))
...
...
@@ -89,10 +94,12 @@ export struct FeedBackActivity {
.padding({bottom:96})
.backgroundColor($r('app.color.color_F5F5F5'))
.align(Alignment.TopStart)
.maxLength(500)
.onChange((value) => {
// Logger.debug(TAG, "onChange" + value + "/" + this.passwordContent)
this.contact = value
this.textNumLabel = value.length+"/500"
this.canSubmit = this.checkSubmit()
})
GridRow({
columns:5,
...
...
@@ -201,22 +208,43 @@ export struct FeedBackActivity {
.scrollBar(BarState.Off)
.alignSelf(ItemAlign.Start)
.padding({ bottom: 44 })
Text($r('app.string.submit'))
.height(44)
.fontColor($r('app.color.color_9E9E9E_40'))
.fontSize($r('app.float.font_size_18'))
.margin({ left: $r('app.float.vp_16'), right: $r('app.float.vp_16'), top: $r('app.float.vp_15') })
.backgroundColor($r('app.color.color_ED2800_99'))
.borderRadius(4)
.onClick(async (event: ClickEvent) => {
if(await FastClickUtil.isMinDelayTime()){
return
}
this.reportCommit()
})
Column(){
Text($r('app.string.submit'))
.align(Alignment.Center)
.height(44)
.width('90%')
.fontColor(this.canSubmit?$r('app.color.color_9E9E9E_40'):$r('app.color.color_fff'))
.fontSize($r('app.float.font_size_18'))
.backgroundColor(this.canSubmit?$r('app.color.color_ED2800_99'):$r('app.color.color_EDEDED'))
.borderRadius(4)
.onClick(async (event: ClickEvent) => {
if(await FastClickUtil.isMinDelayTime()){
return
}
this.reportCommit()
})
Blank().height(15).width('100%')
}
.height(59)
}
}
}
/**
* 校验可提交状态
* */
checkSubmit(): boolean {
if(StringUtils.isEmpty(this.contact) || this.contact.length < 10){
return false
}
if(this.feedbackTypeBeans == null || this.feedbackTypeBeans.length == 0){
return false
}
return true
}
/**
* 请求接口数据
* */
...
...
Please
register
or
login
to post a comment