qiaowei | f044a74 | 2019-07-10 16:04:20 +0800 | [diff] [blame^] | 1 | var db = null; |
| 2 | var app = { |
| 3 | |
| 4 | // Application Constructor |
| 5 | initialize: function() { |
| 6 | document.addEventListener('deviceready', this.onDeviceReady.bind(this), false); |
| 7 | }, |
| 8 | |
| 9 | onDeviceReady: function() { |
| 10 | //$.showLoading("加载中"); |
| 11 | IGetPage(function(ok, ret, err) { |
| 12 | if (ok) { |
| 13 | $.hideLoading(); |
| 14 | if(ret.code==200){ |
| 15 | $("#content").html(ret.page) |
| 16 | }else{ |
| 17 | /*$.alert(ret.msg, "错误", function() { |
| 18 | window.location = "register.html"; |
| 19 | });*/ |
| 20 | } |
| 21 | } else { |
| 22 | //$.hideLoading(); |
| 23 | /*$.alert("加载失败了:" + ret.status, "错误", function() { |
| 24 | window.location = "register.html"; |
| 25 | });*/ |
| 26 | } |
| 27 | }) |
| 28 | } |
| 29 | }; |
| 30 | app.initialize(); |