PHP Classes

File: libs/Raptor/Component/systemBundle/Resources/app/router.js

Recommend this page to a friend!
  Classes of william amed   Raptor 2   libs/Raptor/Component/systemBundle/Resources/app/router.js   Download  
File: libs/Raptor/Component/systemBundle/Resources/app/router.js
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: Raptor 2
Framework that takes routes from annotations
Author: By
Last change:
Date: 7 years ago
Size: 1,101 bytes
 

Contents

Class file image Download
UIR.ns('Panel.Router') Panel.Router=Backbone.Router.extend({ routes:{ '':function(){ Panel.Ui.panelView.resetView() }, '!/*path':'bootstrapOpen', '!f/*path':'extjsOpen', '!ex/*path':'externalOpen', '*path':'NotFound' }, /** description:function(){ //Pace.restart(); Panel.model.fetch({ url:'/raptor/description' }) }, */ bootstrapOpen:function(path){ UIR.load.show('please wait...'); Panel.model.fetch({ url: path }) }, extjsOpen:function(path){ UIR.load.show('please wait...'); Panel.model.set({ extjs: true, route:path, content:'' }) }, externalOpen:function(path){ window.open('/'+path) }, NotFound:function(){ //Pace.restart(); Panel.model.set({ extjs: false, content:'<h1 style="font-size:50px;margin-top:50px;padding:30px;color: #372b53;margin-bottom: 200px"><span style="font-size:70px">): </span> 404 Not Found</h1>' }) } })