1. #1
    Sencha User
    Join Date
    Sep 2011
    Location
    Sallanches, France
    Posts
    371
    Answers
    16
    Vote Rating
    1
    myput is on a distinguished road

      0  

    Default Unanswered: get value from store

    Unanswered: get value from store


    hey,
    i have a list, and in itemTap, i get values of the store item in my detailCard. In this detailCard, i have a view with some button. i would like to get the data of item tap in the handler of the button for sending after to the action button.
    Is it possible ?

    thanks

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,672
    Answers
    3354
    Vote Rating
    747
    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


    So you have a list and you select one row and you want to get the values of that row via a button?
    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.

  3. #3
    Sencha User
    Join Date
    Sep 2011
    Location
    Sallanches, France
    Posts
    371
    Answers
    16
    Vote Rating
    1
    myput is on a distinguished road

      0  

    Default


    hum, i have a list, when i click on an item, i have a detailcard with some information from the store. in the same panel, i have 3 buttons with differents views. one is a panel where i want to display a map with the longitude and latitude of the item, then of the store.

    Can i pass the record from itemtap of the list to the handler of the button. itemtap and handler are in a controller ?

    thanks

  4. #4
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,672
    Answers
    3354
    Vote Rating
    747
    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


    Why not just get the selection on the list when you press the button
    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.

  5. #5
    Sencha User
    Join Date
    Sep 2011
    Location
    Sallanches, France
    Posts
    371
    Answers
    16
    Vote Rating
    1
    myput is on a distinguished road

      0  

    Default


    i can get the data of the good item from the list since the button ?
    can i acces to the store since the handler button? but o need the good item taped ...

  6. #6
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,672
    Answers
    3354
    Vote Rating
    747
    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


    You don't need itemtap listener at all.

    If you have a Panel with the List and let's say a bottom docked toolbar with your buttons... in the button handler you can do this:

    Code:
    var panel = button.up('panel'),
        list  = panel.down('list'),
        recs = list.getSelectedRecords();
    recs will be an Array of records.
    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.

  7. #7
    Sencha User
    Join Date
    Sep 2011
    Location
    Sallanches, France
    Posts
    371
    Answers
    16
    Vote Rating
    1
    myput is on a distinguished road

      0  

    Default


    I need the intermediate panel between the list and the map panel, i display some information from the store in the panel additional the button, and i have already a bottom tabPanel, the button are in the view, with a Vbox.

  8. #8
    Sencha User
    Join Date
    Sep 2011
    Location
    Sallanches, France
    Posts
    371
    Answers
    16
    Vote Rating
    1
    myput is on a distinguished road

      0  

    Default


    okey, i post some code for understand:
    i have in my controller the list item tap:
    Code:
    App.views.DirectoryListContainer.setActiveItem(App.views.DirectoryDetailContainer, {animation: {type:'flip'}});
    i open the DirectoryListContainer:
    Code:
    App.views.DirectoryDetailPanel = new Ext.Panel({
    ........
    		},
    			items: [App.views.DirectoryDetailPanelInformations]
    		},
    		{
    			defaults: {
    				xtype: 'button',
    				margin: 5,
    				flex: 1
    			},
    			items: [
    				{
    					text: 'Map',
    					handler: function() {
    						Ext.dispatch({
    							controller: App.controllers.Directory,
    							action: 'buttonViewMap',
    						});
    					}
    ........
    and in the handler of buttonViewMap, setActiveItem a view with my Map.
    Code:
    var map = new Ext.Map ({
    	mapOptions : {
    		center: new google.maps.LatLng(App.config._BaseLatitude, App.config._BaseLongitude),
    		zoom : App.config._BaseMapZoom,
    		mapTypeId: google.maps.MapTypeId.HYBRID,
    		navigationControlOptions: {
    			style: google.maps.NavigationControlStyle.DEFAULT
    		}
    	},
    	listeners: {
    		beforerender: function() {
    			var latitude = "45.8667";
    			var longitude = "6.6167"; 
    			image = App.config._BaseIconMarker;
    
    
    App.views.DirectoryDetailPanelMap = new Ext.Panel ({
    	fullscreen: true,
    	dockedItems: [App.views.DirectoryDetailPanelMapToolbar],
    	items: [map],
    });
    and here ... in longitude and latitude, i would like to get the good longitude - and latitude from the itemTap of the list ...

    Complicated but .. i need this configuration i don't know how to do simplest...

    Do you have a solution ?

    thanks

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