当前位置: 首页 > wzjs >正文

甘肃省城乡建设厅网站智能工程学院

甘肃省城乡建设厅网站,智能工程学院,使用rem布局的网站,it运维工资多少Harmony系统开发使用eTs开发过程中对于样式相同且重复使用的样式可以抽取成公共样式循环利用,类似于android的style样式。 import router from ohos.router import cryptoFramework from ohos.security.cryptoFramework; import prompt from system.prompt class L…

  Harmony系统开发使用eTs开发过程中对于样式相同且重复使用的样式可以抽取成公共样式循环利用,类似于android的style样式。

import router from '@ohos.router'
import cryptoFramework from '@ohos.security.cryptoFramework';
import prompt from '@system.prompt'
class LoginBean {phone: string;pwd: string;name: string;
}
//标题
@Extend(Text) function extendTitle() {.fontSize(22).fontColor($r('app.color.primary_orange')).maxLines(1).fontWeight(FontWeight.Bold).margin({ top: 10, bottom: 40 })
}
//底部文字
@Extend(Text) function extendRight() {.fontSize(20).fontColor($r('app.color.white')).maxLines(1).fontWeight(FontWeight.Bold).margin({ bottom: 40 })
}
//item布局
@Extend(Row) function extendItemLayout() {.margin({ top: 4, bottom: 4 }).padding({ top: 4, bottom: 10 }).border({width: { bottom: 1 },color: { bottom: $r('app.color.primary_line') },// radius: { bottomRight: 80 },style: {bottom: BorderStyle.Solid} })
}@Extend(Image) function extendItemImg() {.objectFit(ImageFit.Contain).width(30).height(30)
}@Extend(TextInput) function extendItemInput(type) {.width('80%').fontSize(15).type(type).placeholderFont({ size: 15 }).placeholderColor($r('app.color.primary_gray')).caretColor($r('app.color.primary_green')).backgroundColor(Color.White)
}
// 字节流以16进制输出
function uint8ArrayToShowStr(uint8Array) {return Array.prototype.map.call(uint8Array, (x) => ('00' + x.toString(16)).slice(-2)).join('');
}function testGenerateAesKey() {// 创建对称密钥生成器let symKeyGenerator = cryptoFramework.createSymKeyGenerator('AES256');// 通过密钥生成器随机生成对称密钥let promiseSymKey = symKeyGenerator.generateSymKey();promiseSymKey.then(key => {// 获取对称密钥的二进制数据,输出长度为256bit的字节流let encodedKey = key.getEncoded();console.log("213==uint8ArrayToShowStr:"+ uint8ArrayToShowStr(encodedKey.data));})
}@Entry
@Component
struct Login {@State loginBean: LoginBean = new LoginBean();private loginClick() {console.log("213==phone:" + this.loginBean.phone)console.log("213==pwd:" + this.loginBean.pwd)testGenerateAesKey()if (!this.loginBean.phone) {prompt.showToast({message: '请输入手机号'})return} else if (!this.loginBean.pwd) {prompt.showToast({message: '请输入密码'})return}// router.pushUrl({//   url: 'pages/Main'// }, router.RouterMode.Standard,//   (err) => {//   });}build() {Column() {Column() {Image($r('app.media.icon_app_label')).objectFit(ImageFit.Contain).width(60).height(60)Text($r('app.string.app_name')).extendTitle()}.width('100%').height(0).layoutWeight(1).alignItems(HorizontalAlign.Center).justifyContent(FlexAlign.End)Column() {//手机号Row() {Image($r('app.media.icon_login_phone')).objectFit(ImageFit.Contain).width(30).height(30)TextInput({ placeholder: '请输入手机号', text: 'xcxxcc1' }).extendItemInput(InputType.Normal).onChange((value: string) => {this.loginBean.phone = value})}.extendItemLayout()//密码Row() {Image($r('app.media.icon_login_pwd')).extendItemImg()TextInput({ placeholder: '请输入密码', text: ';lywg@2023' }).extendItemInput(InputType.Password).placeholderFont({ size: 14, weight: 400 }).onChange((value: string) => {this.loginBean.pwd = value})}.extendItemLayout()Row() {//登陆按钮Text('登录').backgroundColor($r("app.color.primary_green")).fontSize(18).fontColor($r("app.color.white")).borderRadius(8).margin({ top: 30 }).padding({ top: 5, bottom: 5, left: 40, right: 40 }).onClick(this.loginClick.bind(this))// .onClick(() => {})}}.borderRadius(10).margin({ left: 20, right: 20 }).padding({ top: 20, bottom: 20, left: 20, right: 20 }).backgroundColor($r('app.color.white'))Column() {Text('深化治理建设  打造数字山东').extendRight()}.width('100%').height(0).layoutWeight(1).alignItems(HorizontalAlign.Center).justifyContent(FlexAlign.End)}.width('100%').height('100%').backgroundImage($r('app.media.login_bg')).backgroundImageSize({ width: '100%', height: '100%' })}
}

在这里插入图片描述
在这里插入图片描述


文章转载自:

http://XugCroUQ.nsncq.cn
http://V2D04pxi.nsncq.cn
http://qFpZAfEx.nsncq.cn
http://Lbyn9Fir.nsncq.cn
http://d755SiQz.nsncq.cn
http://REQmON4k.nsncq.cn
http://YibNMWVm.nsncq.cn
http://lQ01mkrQ.nsncq.cn
http://ZI5mbIl4.nsncq.cn
http://bZaJG9Sy.nsncq.cn
http://jAU3T3mc.nsncq.cn
http://wF3qxQuZ.nsncq.cn
http://GeqX1p8h.nsncq.cn
http://RTF2I0JT.nsncq.cn
http://9Z2ovg9H.nsncq.cn
http://bV8ooDkP.nsncq.cn
http://djKdbAov.nsncq.cn
http://XguwYzR5.nsncq.cn
http://6eVMYDEa.nsncq.cn
http://zaiGBmBn.nsncq.cn
http://dazc7URU.nsncq.cn
http://SQj8eYTU.nsncq.cn
http://0EL181Ef.nsncq.cn
http://lmgbqXvF.nsncq.cn
http://lmVZZwDb.nsncq.cn
http://iOixsRwc.nsncq.cn
http://TbG5ftQz.nsncq.cn
http://sXqKkHeT.nsncq.cn
http://8z6Sg1Gz.nsncq.cn
http://wRudI5aM.nsncq.cn
http://www.dtcms.com/wzjs/666629.html

相关文章:

  • 大型网站 cms做语文综合题的网站
  • 个人网站策划书怎么做网站的优点
  • 培训机构网站源码iis添加网站ip地址
  • 网站集群 建设方案wordpress首页标题副标题
  • 射阳建设网站维护网站费用怎么做会计凭证
  • 合肥浦发建设集团网站网站页脚有什么作用
  • 百度统计网站速度诊断多少关键词排名优化软件
  • 模板建网站价格网页开发的公司
  • 保定网站制作网站wordpress最新版本下载
  • 哪些网站做婚纱摄影成都小程序定制开发
  • 福建省网站建设公司个人免费开店的网站
  • 站群网站推广工具费用荥阳在线
  • 重庆专业网站推广流程电子商务网站建设题
  • 创业做网站失败个人养老保险计算器
  • 长沙 直播网站建设手表商城
  • 基于网站开发小程序怎么做地区网站
  • 北京网站优化排名推广wordpress 精美主题
  • 青浦网站建设推广php做网站需要后台吗
  • 自助建站原理如何在公司网站上添加内容
  • 网站建设模板是什么意思线上销售培训机构
  • 电商门户网站室内设计联盟论坛官网
  • 网站设计任务网站多国语言设计
  • 高级设计网站网络营销是什么研究
  • 做夏促的网站有哪些网站开发软件英文版
  • 单位 内网网站建设手机软件界面设计
  • 滁州建设网站中山网站建设方案托管
  • wordpress悬浮广告北京网站怎么优化
  • 中英文的网站设计农村建水上乐园赚钱吗
  • 长沙专业网站设计服务安平百度做网站
  • python 网站开发 视频网站信息设计