Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User
    Join Date
    Apr 2010
    Posts
    7
    Vote Rating
    0
    techillin is on a distinguished road

      0  

    Default Unanswered: Dynamic json chart

    Unanswered: Dynamic json chart


    I'm trying to use Sencha Touch Charts with a JSONStore to dynamically display a chart from information provided by JSON, series and data. This was possible with ExtJS 3 with the metaData property.


    How can I accomplish the same with Sencha Touch Charts?

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


    Load the store outside the chart and when the store loads, create the chart.
    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
    Apr 2010
    Posts
    7
    Vote Rating
    0
    techillin is on a distinguished road

      0  

    Default


    I'm sorry but I can't get it to work. A simple example would be nice.

    I wan't someting like this to produce a chart, none of the fields (except timestamp) can be hardcoded because it needs to be fullt dynamic.

    Code:
    {    "metaData": {
            "root": "series",
            "fields": [{
                "name": "timestamp"
            }, {
                "name": "Unit 1",
                "mapping": 2345
            }, {
                "name": "Unit 2",
                "mapping": 5647
            }, {
                "name": "Unit 3",
                "mapping": 1436
            }]
        },
        "series": [{
            "timestamp": "Jan",
            "1436": 10,
            "5647": 6,
            "2345": 4
        }, {
            "timestamp": "Feb",
            "2345": 10,
            "1436": 9,
            "5647": 7
        }, {
            "timestamp": "Mar",
            "2345": 10,
            "5647": 7,
            "1436": 4
        }]
    }

  4. #4
    Sencha User
    Join Date
    Nov 2011
    Location
    India
    Posts
    25
    Answers
    1
    Vote Rating
    0
    m4manas is on a distinguished road

      0  

    Default


    What if i want the labels also to be dynamic not hard coded?

    How do i refresh and reload the data. Say i reload the store with new data. How do i rerender the chart.

  5. #5
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,677
    Answers
    3355
    Vote Rating
    749
    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


    Quote Originally Posted by m4manas View Post
    What if i want the labels also to be dynamic not hard coded?

    How do i refresh and reload the data. Say i reload the store with new data. How do i rerender the chart.
    The chart should hear when the store loads. The examples have a refresh button that simulates this.
    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. #6
    Sencha User
    Join Date
    Jul 2009
    Posts
    15
    Answers
    1
    Vote Rating
    1
    shydreamz is on a distinguished road

      0  

    Default


    Quote Originally Posted by mitchellsimoens View Post
    The chart should hear when the store loads. The examples have a refresh button that simulates this.
    @simon i am afraid then when a store calls a loadData the chart is refreshed but it does not update the series in the charts and so if we have added a new data or field in the store then the chart does not reflect this change is only redraws or refreshes the chart with same old store data..

    i tries this with sencha 4.0.1 charts and also on touch chars

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