Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
W
wiki-java
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Operations
    • Operations
    • Incidents
  • Analytics
    • Analytics
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • 老徐
  • wiki-java
  • Wiki
  • shuidi js develope

shuidi js develope · Changes

Page history
meijh created page: shuidi js develope authored Jul 08, 2016 by 梅俊辉's avatar 梅俊辉
Hide whitespace changes
Inline Side-by-side
Showing with 7 additions and 6 deletions
+7 -6
  • shuidi-js-develope.md shuidi-js-develope.md +7 -6
  • No files found.
shuidi-js-develope.md
View page @ 06b77943
......@@ -8,15 +8,16 @@ temp.js文件
![1](http://tech.pingansec.com/ulindows/tech_java/uploads/baa203c7e6536be9b2046e14ceed7f63/1.png)
<br />
![3](http://tech.pingansec.com/ulindows/tech_java/uploads/01ad68fd28a38d1fa4f85c52cf89cd77/3.png)
<br />
<br />
一个js会有一个对象,如上图中的Temp,Temp中会有Ajax和 Event两个对象,
Ajax对象中包含了所有调用ajax的方法
所有需要在页面初始化时候调用的ajax方法,都写在ajaxInitExecute方法中
注意Ajax中的return{} 只有写在return中的方法才会被其它地方调用到
所有需要在页面初始化时候调用的ajax方法,都写在ajaxInitExecute方法中
<br />
Event对象中包含了所有事件绑定有关的方法
写法如上图,
eventBind方法会在页面初始化后执行
所有需要在页面初始化时候调用的事件方法,都写在eventBind方法中,比如事件绑定,某个方法的执行
<br />
注意:ajaxInitExecute,eventBind中的方法,需写成方法调用的方法,
如有一个function showTest(){},eventBind中 写成 showTest(); 而不是 showTest
\ No newline at end of file
如有一个function showTest(){},eventBind中 写成 showTest(); 而不是 showTest
Ajax,Event对象中的方法只有写在return{} 中才会被其它地方调用到,若不需要暴露就不需要写在return{}中,
Clone repository
  • git configuration and simple use
  • Home
  • java code specification
  • maven environment configuration
  • shuidi js develope
  • ucs_project environment configuration