angular.router.js 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356
  1. 'use strict';
  2. angular.module('app').config([ '$stateProvider', '$urlRouterProvider', function($stateProvider, $urlRouterProvider) {
  3. $urlRouterProvider.otherwise('/app/main');
  4. $stateProvider.state('app', {
  5. abstract : true,
  6. url : '/app',
  7. template : '<div ui-view class="fade-in-up"></div>'
  8. }).state('app.main', {
  9. url : '/main',
  10. templateUrl : 'routes/main/main.html?v=' + new Date().getTime(),
  11. resolve : {
  12. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  13. return $ocLazyLoad.load(['routes/main/main.js?v=' + new Date().getTime() ]);
  14. } ]
  15. }
  16. })
  17. .state('app.std', {
  18. abstract : true,
  19. url : '/std',
  20. template : '<div ui-view class="fade-in-up"></div>'
  21. }).state('app.std.reg', {
  22. url : '/reg',
  23. templateUrl : 'routes/std/reg/std_reg.html?v=' + new Date().getTime(),
  24. resolve : {
  25. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  26. return $ocLazyLoad.load(['routes/std/reg/std_reg.js?v=' + new Date().getTime() ]);
  27. } ]
  28. }
  29. }).state('app.std.cert', {
  30. url : '/cert',
  31. templateUrl : 'routes/std/cert/std_cert.html?v=' + new Date().getTime(),
  32. resolve : {
  33. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  34. return $ocLazyLoad.load(['routes/std/cert/std_cert.js?v=' + new Date().getTime() ]);
  35. } ]
  36. }
  37. }).state('app.std.info', {
  38. url : '/info',
  39. templateUrl : 'routes/std/info/std_info.html?v=' + new Date().getTime(),
  40. resolve : {
  41. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  42. return $ocLazyLoad.load(['routes/std/info/std_info.js?v=' + new Date().getTime() ]);
  43. } ]
  44. }
  45. }).state('app.std.material', {
  46. url : '/material',
  47. templateUrl : 'routes/std/material/std_material.html?v=' + new Date().getTime(),
  48. resolve : {
  49. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  50. return $ocLazyLoad.load(['routes/std/material/std_material.js?v=' + new Date().getTime() ]);
  51. } ]
  52. }
  53. }).state('app.std.material_info', {
  54. url : '/material_info/:material_id',
  55. templateUrl : 'routes/std/material/std_material_info.html?v=' + new Date().getTime(),
  56. resolve : {
  57. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  58. return $ocLazyLoad.load(['routes/std/material/std_material_info.js?v=' + new Date().getTime() ]);
  59. } ]
  60. }
  61. }).state('app.std.binding', {
  62. url : '/binding',
  63. templateUrl : 'routes/std/binding/std_binding.html?v=' + new Date().getTime(),
  64. resolve : {
  65. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  66. return $ocLazyLoad.load(['routes/std/binding/std_binding.js?v=' + new Date().getTime() ]);
  67. } ]
  68. }
  69. }).state('app.std.unbinding', {
  70. url : '/unbinding',
  71. templateUrl : 'routes/std/unbinding/std_unbinding.html?v=' + new Date().getTime(),
  72. resolve : {
  73. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  74. return $ocLazyLoad.load(['routes/std/unbinding/std_unbinding.js?v=' + new Date().getTime() ]);
  75. } ]
  76. }
  77. }).state('app.std.admit', {
  78. url : '/admit',
  79. templateUrl : 'routes/std/admit/std_admit.html?v=' + new Date().getTime(),
  80. resolve : {
  81. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  82. return $ocLazyLoad.load(['routes/std/admit/std_admit.js?v=' + new Date().getTime() ]);
  83. } ]
  84. }
  85. })
  86. .state('app.enrol', {
  87. abstract : true,
  88. url : '/enrol',
  89. template : '<div ui-view class="fade-in-up"></div>'
  90. }).state('app.enrol.guide', {
  91. url : '/guide',
  92. templateUrl : 'routes/enrol/guide/enrol_guide.html?v=' + new Date().getTime(),
  93. resolve : {
  94. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  95. return $ocLazyLoad.load(['routes/enrol/guide/enrol_guide.js?v=' + new Date().getTime() ]);
  96. } ]
  97. }
  98. }).state('app.enrol.list', {
  99. url : '/list',
  100. templateUrl : 'routes/enrol/list/enrol_list.html?v=' + new Date().getTime(),
  101. resolve : {
  102. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  103. return $ocLazyLoad.load(['routes/enrol/list/enrol_list.js?v=' + new Date().getTime() ]);
  104. } ]
  105. }
  106. }).state('app.enrol.info', {
  107. url : '/info/:enrol_id/:autopay',
  108. templateUrl : 'routes/enrol/info/enrol_info.html?v=' + new Date().getTime(),
  109. resolve : {
  110. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  111. return $ocLazyLoad.load(['routes/enrol/info/enrol_info.js?v=' + new Date().getTime() ]);
  112. } ]
  113. }
  114. }).state('app.enrol.doc', {
  115. url : '/doc/:enrol_id',
  116. templateUrl : 'routes/enrol/doc/enrol_doc.html?v=' + new Date().getTime(),
  117. resolve : {
  118. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  119. return $ocLazyLoad.load(['routes/enrol/doc/enrol_doc.js?v=' + new Date().getTime() ]);
  120. } ]
  121. }
  122. })
  123. .state('app.score', {
  124. abstract : true,
  125. url : '/score',
  126. template : '<div ui-view class="fade-in-up"></div>'
  127. }).state('app.score.info', {
  128. url : '/info/:std_id/:aspect_id',
  129. templateUrl : 'routes/score/info/score_info.html?v=' + new Date().getTime(),
  130. resolve : {
  131. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  132. return $ocLazyLoad.load(['routes/score/info/score_info.js?v=' + new Date().getTime() ]);
  133. } ]
  134. }
  135. })
  136. .state('app.appointment', {
  137. abstract : true,
  138. url : '/appointment',
  139. template : '<div ui-view class="fade-in-up"></div>'
  140. }).state('app.appointment.list', {
  141. url : '/list',
  142. templateUrl : 'routes/appointment/list/appointment_list.html?v=' + new Date().getTime(),
  143. resolve : {
  144. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  145. return $ocLazyLoad.load(['routes/appointment/list/appointment_list.js?v=' + new Date().getTime() ]);
  146. } ]
  147. }
  148. }).state('app.appointment.info', {
  149. url : '/info/:agent_id',
  150. templateUrl : 'routes/appointment/info/appointment_info.html?v=' + new Date().getTime(),
  151. resolve : {
  152. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  153. return $ocLazyLoad.load(['routes/appointment/info/appointment_info.js?v=' + new Date().getTime() ]);
  154. } ]
  155. }
  156. })
  157. .state('app.ticket', {
  158. abstract : true,
  159. url : '/ticket',
  160. template : '<div ui-view class="fade-in-up"></div>'
  161. }).state('app.ticket.list', {
  162. url : '/list',
  163. templateUrl : 'routes/ticket/list/ticket_list.html?v=' + new Date().getTime(),
  164. resolve : {
  165. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  166. return $ocLazyLoad.load(['routes/ticket/list/ticket_list.js?v=' + new Date().getTime() ]);
  167. } ]
  168. }
  169. }).state('app.ticket.info', {
  170. url : '/info/:ly_ticket_id',
  171. templateUrl : 'routes/ticket/info/ticket_info.html?v=' + new Date().getTime(),
  172. resolve : {
  173. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  174. return $ocLazyLoad.load(['routes/ticket/info/ticket_info.js?v=' + new Date().getTime() ]);
  175. } ]
  176. }
  177. })
  178. .state('app.exam', {
  179. abstract : true,
  180. url : '/exam',
  181. template : '<div ui-view class="fade-in-up"></div>'
  182. })
  183. .state('app.exam.voide', {
  184. url : '/voide/:enrol_id/:read',
  185. templateUrl : 'routes/voide/exam/exam.html?v=' + new Date().getTime(),
  186. resolve : {
  187. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  188. return $ocLazyLoad.load(['routes/voide/exam/exam.js?v=' + new Date().getTime() ]);
  189. } ]
  190. }
  191. })
  192. .state('app.exam.result', {
  193. url : '/result/:enrol_id',
  194. templateUrl : 'routes/voide/result/result.html?v=' + new Date().getTime(),
  195. resolve : {
  196. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  197. return $ocLazyLoad.load(['routes/voide/result/result.js?v=' + new Date().getTime() ]);
  198. } ]
  199. }
  200. })
  201. .state('app.exam.upload', {
  202. url : '/upload/:enrol_id',
  203. templateUrl : 'routes/voide/upload/upload.html?v=' + new Date().getTime(),
  204. resolve : {
  205. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  206. return $ocLazyLoad.load(['routes/voide/upload/upload.js?v=' + new Date().getTime() ]);
  207. } ]
  208. }
  209. })
  210. .state('app.exam.list', {
  211. url : '/list',
  212. templateUrl : 'routes/exam/list/list.html?v=' + new Date().getTime(),
  213. resolve : {
  214. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  215. return $ocLazyLoad.load(['routes/exam/list/list.js?v=' + new Date().getTime() ]);
  216. } ]
  217. }
  218. })
  219. .state('app.exam.checkin', {
  220. url : '/checkin/:agent_id/:aspect_id',
  221. templateUrl : 'routes/exam/checkin/checkin.html?v=' + new Date().getTime(),
  222. resolve : {
  223. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  224. return $ocLazyLoad.load(['routes/exam/checkin/checkin.js?v=' + new Date().getTime() ]);
  225. } ]
  226. }
  227. })
  228. .state('app.judge', {
  229. url : '/judge',
  230. templateUrl : 'routes/judge/judge.html?v=' + new Date().getTime(),
  231. resolve : {
  232. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  233. return $ocLazyLoad.load(['routes/judge/judge.js?v=' + new Date().getTime() ]);
  234. } ]
  235. }
  236. })
  237. .state('app.exam.wait', {
  238. url : '/wait/:agent_id/:aspect_id',
  239. templateUrl : 'routes/exam/wait/wait.html?v=' + new Date().getTime(),
  240. resolve : {
  241. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  242. return $ocLazyLoad.load(['routes/exam/wait/wait.js?v=' + new Date().getTime() ]);
  243. } ]
  244. }
  245. })
  246. .state('app.ym', {
  247. abstract : true,
  248. url : '/ym',
  249. template : '<div ui-view class="fade-in-up"></div>'
  250. }).state('app.ym.addr', {
  251. url : '/addr',
  252. templateUrl : 'routes/ym/addr/ym_addr.html?v=' + new Date().getTime(),
  253. resolve : {
  254. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  255. return $ocLazyLoad.load(['routes/ym/addr/ym_addr.js?v=' + new Date().getTime() ]);
  256. } ]
  257. }
  258. }).state('app.ym.mobile', {
  259. url : '/mobile',
  260. templateUrl : 'routes/ym/mobile/ym_mobile.html?v=' + new Date().getTime(),
  261. resolve : {
  262. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  263. return $ocLazyLoad.load(['routes/ym/mobile/ym_mobile.js?v=' + new Date().getTime() ]);
  264. } ]
  265. }
  266. }).state('app.ym.aspect_list', {
  267. url : '/aspect_list',
  268. templateUrl : 'routes/ym/list/ym_aspect_list.html?v=' + new Date().getTime(),
  269. resolve : {
  270. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  271. return $ocLazyLoad.load(['routes/ym/list/ym_aspect_list.js?v=' + new Date().getTime() ]);
  272. } ]
  273. }
  274. }).state('app.ym.std_admis', {
  275. url : '/std_admis',
  276. templateUrl : 'routes/ym/admis/std_admis.html?v=' + new Date().getTime(),
  277. resolve : {
  278. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  279. return $ocLazyLoad.load(['routes/ym/admis/std_admis.js?v=' + new Date().getTime() ]);
  280. } ]
  281. }
  282. }).state('app.ym.aspect_info', {
  283. url : '/aspect_info/:enrol_id',
  284. templateUrl : 'routes/ym/info/ym_aspect_info.html?v=' + new Date().getTime(),
  285. resolve : {
  286. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  287. return $ocLazyLoad.load(['routes/ym/info/ym_aspect_info.js?v=' + new Date().getTime() ]);
  288. } ]
  289. }
  290. }).state('app.ym.score', {
  291. url : '/score/:aspect_name/:batch',
  292. templateUrl : 'routes/ym/score/ym_score.html?v=' + new Date().getTime(),
  293. resolve : {
  294. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  295. return $ocLazyLoad.load(['routes/ym/score/ym_score.js?v=' + new Date().getTime() ]);
  296. } ]
  297. }
  298. }).state('app.ym.image', {
  299. url : '/image/:aspect_name',
  300. templateUrl : 'routes/ym/image/ym_image.html?v=' + new Date().getTime(),
  301. resolve : {
  302. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  303. return $ocLazyLoad.load(['routes/ym/image/ym_image.js?v=' + new Date().getTime() ]);
  304. } ]
  305. }
  306. }).state('app.ym.batch', {
  307. url : '/batch',
  308. templateUrl : 'routes/score/ym/score_ym.html?v=' + new Date().getTime(),
  309. resolve : {
  310. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  311. return $ocLazyLoad.load(['routes/score/ym/score_ym.js?v=' + new Date().getTime() ]);
  312. } ]
  313. }
  314. })
  315. .state('app.reexam', {
  316. abstract : true,
  317. url : '/reexam',
  318. template : '<div ui-view class="fade-in-up"></div>'
  319. }).state('app.reexam.list', {
  320. url : '/list',
  321. templateUrl : 'routes/reexam/list/reexam_list.html?v=' + new Date().getTime(),
  322. resolve : {
  323. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  324. return $ocLazyLoad.load(['routes/reexam/list/reexam_list.js?v=' + new Date().getTime() ]);
  325. } ]
  326. }
  327. }).state('app.reexam.info', {
  328. url : '/info/:enrol_id',
  329. templateUrl : 'routes/reexam/info/reexam_info.html?v=' + new Date().getTime(),
  330. resolve : {
  331. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  332. return $ocLazyLoad.load(['routes/reexam/info/reexam_info.js?v=' + new Date().getTime() ]);
  333. } ]
  334. }
  335. }).state('app.std.notice', {
  336. url : '/notice',
  337. templateUrl : 'routes/std/notice/std_notice.html?v=' + new Date().getTime(),
  338. resolve : {
  339. deps : [ '$ocLazyLoad', function($ocLazyLoad) {
  340. return $ocLazyLoad.load(['routes/std/notice/std_notice.js?v=' + new Date().getTime() ]);
  341. } ]
  342. }
  343. })
  344. } ]);