1. #1
    Sencha User
    Join Date
    Feb 2012
    Posts
    253
    Vote Rating
    0
    ci11111 is on a distinguished road

      0  

    Default Answered: multiple URL entry points


  2. The TouchStyle example uses routes with navigation view

  3. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,732
    Answers
    3364
    Vote Rating
    756
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    In your controller you can use routes and that will handle the hash and hash changes.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  4. #3
    Sencha User
    Join Date
    Feb 2012
    Posts
    253
    Vote Rating
    0
    ci11111 is on a distinguished road

      0  

    Default


    Could you help make a working example of what you just said

    I would need a NavigationView , in first view a panel (url ...#view1) with a button, the button brings to second view ( ...#view2) and so on

    this may be simple but I have no idea how you make the routes work, thanks

    Code:
    Ext.define('myTemplate.controller.handler', {
      extend: 'Ext.app.Controller',
      config: {
        refs: {  
            navView: 'navigationview',
            button1 : '#button1',
            button2 : '#button2',
            panel1: '#panel1',
            panel2: '#panel2',
            panel3: '#panel3'
        },
        control: {
            button1: {
            tap: 'on1'
          },
          button2: {
            tap: 'on2'
          }
        },
        routes: {
             'view1': 'showView1',
             'view2': 'showView2',
             'view3': 'showView3',
          }
      },
      on1: function() {
        var view  = this.getNavView();
        view.push(this.getPanel2());
        },
        on2: function() {
        var view  = this.getNavView();
        view.push(this.getPanel3());
        },
        showView1: function() {
        },
    });

  5. #4
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,732
    Answers
    3364
    Vote Rating
    756
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    The TouchStyle example uses routes with navigation view
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  6. #5
    Sencha User
    Join Date
    Feb 2012
    Posts
    253
    Vote Rating
    0
    ci11111 is on a distinguished road

      0  

    Default


    thanks mitchell, do I have to extend all my panels from Ext.Data.Model, and define their toUrl methods, each time?

  7. #6
    Sencha User
    Join Date
    Feb 2012
    Posts
    253
    Vote Rating
    0
    ci11111 is on a distinguished road

      0  

    Default


    the touchstyle example is a great example but can I simply, bind some Ext.panel to data.Models, I mean how could I make each of my created panel acquire it's url

    here is the base example http://www.senchafiddle.com/#dPZn0 , but you need to download it and run it locally navViewroutes.zip to make the routes work

    I don't have a clear idea, but I need something like:
    Code:
    Ext.define('SenchaFiddle.view.View', {
        extend : 'Ext.Panel',
    
    
        config : {
            layout : 'vbox',
            scrollable : true,
            styleHtmlContent : true,
            items : [ {
                xtype : 'button',
                text : 'push'
            } ]
        },
        toUrl : function() {
            return this.get('title');
        }
    
    
    });
    but how it manage Url? I need to make my view2 directly available when I go at the url ...navViewroutes#view2

    it seems to be possible by extending dataModel like are working kitchesink and touchstyle http://dev.sencha.com/deploy/touch/e...ndex.html#hats, how could I override this from just a panel
    Attached Files

  8. #7
    Sencha User
    Join Date
    Feb 2012
    Posts
    253
    Vote Rating
    0
    ci11111 is on a distinguished road

      0  

    Default


    up

    What is the right way, declare a Page treestore in the controller, that map the different panels to urls?

Thread Participants: 1

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar