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

广州做网站发多少钱百度关键词竞价和收费的方法

广州做网站发多少钱,百度关键词竞价和收费的方法,制作网站视频,科技网站推荐在之前的章节中,我们已经介绍完了MVC的架构和实现,现在我们来讲一下,SAPUI5的结构 这一步,我们将所有的UI资产从index.html里面独立封装在一个组件里面 这样组件就变得独立,可复用了。这样,无所什么时候我…

在之前的章节中,我们已经介绍完了MVC的架构和实现,现在我们来讲一下,SAPUI5的结构

这一步,我们将所有的UI资产从index.html里面独立封装在一个组件里面

这样组件就变得独立,可复用了。这样,无所什么时候我们去访问资源的时候,我们都直接访问组件文件而不是index.html。这种方式使得我们的app变得更加灵活

文件拆分之后长这样

首先,我们先新建一个Component.js

webapp/Component.js (New)

sap.ui.define(["sap/ui/core/UIComponent"
], (UIComponent) => {"use strict";return UIComponent.extend("", {init() {// call the init function of the parentUIComponent.prototype.init.apply(this, arguments);}});
});
sap.ui.define(["sap/ui/core/UIComponent","sap/ui/model/json/JSONModel","sap/ui/model/resource/ResourceModel"
], (UIComponent, JSONModel, ResourceModel) => {"use strict";return UIComponent.extend("ui5.walkthrough.Component", {metadata : {"interfaces": ["sap.ui.core.IAsyncContentCreation"],"rootView": {"viewName": "ui5.walkthrough.view.App","type": "XML","id": "app"}},init() {// call the init function of the parentUIComponent.prototype.init.apply(this, arguments);// set data modelconst oData = {recipient : {name : "World"}};const oModel = new JSONModel(oData);this.setModel(oModel);// set i18n modelconst i18nModel = new ResourceModel({bundleName: "sap.ui.demo.walkthrough.i18n.i18n"});this.setModel(i18nModel, "i18n");}});
});

接下来,我们去修改App.controller.js

sap.ui.define(["sap/ui/core/mvc/Controller","sap/m/MessageToast"
], (Controller, MessageToast) => {"use strict";return Controller.extend("ui5.walkthrough.controller.App", {onShowHello() {// read msg from i18n modelconst oBundle = this.getView().getModel("i18n").getResourceBundle();const sRecipient = this.getView().getModel().getProperty("/recipient/name");const sMsg = oBundle.getText("helloMsg", [sRecipient]);// show messageMessageToast.show(sMsg);}});
});

修改index.js

webapp\index.js

sap.ui.define(["sap/ui/core/ComponentContainer"
], (ComponentContainer) => {"use strict";new ComponentContainer({name: "ui5.walkthrough",settings : {id : "walkthrough"},async: true}).placeAt("content");
});

Conventions

  • The component is named Component.js.

  • Together with all UI assets of the app, the component is located in the webapp folder.

  • The index.html file is located in the webapp folder if it is used productively.

最终实现效果还是和之前一样

http://www.yidumall.com/news/36734.html

相关文章:

  • 企业网站设计策划案网站搭建公司哪家好
  • 网站建设demo企业培训课程价格
  • 网站建设构成链接生成二维码
  • 2g网站空间多少钱一年免费发广告帖子的网站
  • 网站建设电话销售工作免费网络空间搜索引擎
  • wordpress建立视频网站百度招聘网最新招聘信息
  • 创造有价值的网站seo搜索引擎优化费用
  • 做爰片的网站google网址直接打开
  • 新手学做网站学要做哪些sem是什么仪器
  • 海南网站建设基本流程百度商家平台登录
  • 凤翔网站制作贵州seo学校
  • 公司移动端的网站模板下载如何在各种网站投放广告
  • 美美淘-专做女鞋拿货选款网站长沙百度快速优化
  • 建设企业网站管理的重要性百度seo排名在线点击器
  • 临城网站建设口碑营销方案
  • 做网站开发要具备什么知识百度域名注册
  • 做国际网站需要多少钱新闻稿代写平台
  • 请问婚庆网站建设该怎么做呢seo网站推广服务
  • 关于网站建设live2500成人再就业技能培训班
  • 让医院做网站的策划书北京网站开发
  • 朝阳区建设工作办公室网站外包seo公司
  • 我要建网站企业qq多少钱一年
  • 关键词加入搜索引擎网站百度关键词屏蔽
  • 电子商务网站规划的原则seo综合查询接口
  • 怎么用源码做网站视频网盟推广平台
  • 网站建设的目标是什么 提供了哪些栏目吉林网络公司
  • 新邱建设网站深圳外贸推广公司
  • 昆明做网站优化企拓客软件怎么样
  • 珠海主题网站设计模板seo 优化案例
  • 网站建设的书最近一周新闻