搜索页

This commit is contained in:
xiaoxiao
2025-05-30 16:57:06 +08:00
parent e0efb15e61
commit 0c2b6c096c
8 changed files with 328 additions and 29 deletions
+3 -1
View File
@@ -52,4 +52,6 @@ export { EditUserDataItem } from './src/main/ets/Views/EditUserDataItem'
export { Huanzhelast444Model } from './src/main/ets/models/Huanzhelast444Model'
export { huanzheDb } from './src/main/ets/utils/HuanzhelasDbHelper'
export { huanzheDb } from './src/main/ets/utils/HuanzhelasDbHelper'
export { HdSearchNav } from './src/main/ets/components/HdSearchNav'
@@ -14,7 +14,7 @@ export struct HdSearchNav {
@Prop
leftIcon: ResourceStr = $r('app.media.top_back')
@Prop
showRightIcon: boolean = true
showRightIcon: boolean = false
@Prop
rightIcon: ResourceStr
@Prop
@@ -22,9 +22,11 @@ export struct HdSearchNav {
@Prop
rightText: string = ''
@Prop
rightTextColor: ResourceStr
rightTextColor: Color
@Prop
rightbackColor: ResourceStr = $r('app.color.main_color')
@Prop
isFocus:boolean = false;
@State textInputContent:string = ''
@@ -35,20 +37,25 @@ export struct HdSearchNav {
.size({ width: 24, height: 24 })
.onClick(() => router.back())
.fillColor($r('app.color.black'))
}.size({ width: 50, height: 50 })
}.size({ width: 40, height: 50 })
Row({space:10}){
Row(){
Image($r('app.media.selected_hospital_ws'))
.width(25).height(25)
.margin({left:15})
TextInput({placeholder:'搜索视频、过往会议'})
.fontSize(15)
.width(20).height(20)
.margin({left:10})
TextInput({placeholder:'搜索视频、过往会议'})
.defaultFocus(this.isFocus)
.fontSize(15)
.backgroundColor(this.bgColor)
.height('100%').width('calc(100% - 40vp)')
.padding({ left: 0 })
.margin({left:5})
.onChange((value:string)=>{
this.textInputContent = value;
})
}
.borderWidth(0.5).borderRadius(3).borderColor($r('app.color.main_color')).justifyContent(FlexAlign.Start)
.borderWidth(1).borderRadius(5).borderColor('#999999').justifyContent(FlexAlign.Start)
.width('calc(100% - 100vp)').height(40)
if (this.showRightIcon) {
Row() {
@@ -65,7 +72,7 @@ export struct HdSearchNav {
.backgroundColor(this.rightbackColor)
.borderRadius(4)
.onClick(()=>this.rightItemAction(this.textInputContent))
.width(50)
.width(50).height(40).margin({left:10})
.textAlign(TextAlign.Center)
} else {
Blank()
@@ -38,6 +38,7 @@ export class BasicConstant {
static readonly videoByKeyWordsNew = BasicConstant.urlExpertApp + "videoByKeyWordsNew";
static readonly tagList = BasicConstant.urlExpertApp + "tagList";
static readonly meetingListBySearch = BasicConstant.urlExpertAPI + "meetingListBySearch";
static readonly videoBySearchNew = BasicConstant.urlExpertApp+'videoBySearchNew'//搜索肝胆视频列表
static readonly province=['全国','北京市','天津市','河北省','山西省'
,'内蒙古自治区','辽宁省','吉林省','黑龙江省','上海市','江苏省','浙江省'