Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8817593
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T04:53:12+00:00 2026-06-14T04:53:12+00:00

I have store which is used for grid and column chart but the values

  • 0

I have store which is used for grid and column chart but the values are in form of string (server side formatted amounts which cant be done at client side).due to which grid is not being rendered due to amount in string format.the solution might be make separate store with required data types for grid and chart.but this is inefficient way because same data is coming from server.

here is what i am doing

if (!window.GridModel) {
            if (!Ext.ModelManager.isRegistered('GridModel')) {
                Ext.define('GridModel', {
                    extend: 'Ext.data.Model',
                    fields: [{
                        name: 'LocCode',
                        type: 'string'
                    }, {
                        name: 'LocLvl',
                        type: 'string'
                    }, {
                        name: 'LocName',
                        type: 'string'
                    },

                    {
                        name: 'cost1',
                        type: 'string'
                    }, {
                        name: 'Cost2',
                        type: 'string'
                    }, {
                        name: 'cost3',
                        type: 'string'
                    }


    ]
            });
        }
    }

for chart (not deficient)

if (!window.chartModel) {
            if (!Ext.ModelManager.isRegistered('chartModel')) {
                Ext.define('chartModel', {
                    extend: 'Ext.data.Model',
                    fields: [{
                        name: 'LocCode',
                        type: 'string'
                    }, {
                        name: 'LocLvl',
                        type: 'string'
                    }, {
                        name: 'LocName',
                        type: 'string'
                    },

                    {
                        name: 'cost1',
                        type: 'float'
                    }, {
                        name: 'Cost2',
                        type: 'float'
                    }, {
                        name: 'cost3',
                        type: 'float'
                    }


    ]
            });
        }
    }

one way might be copy one store into another with changed data type of fields but i don’t know how to copy one store into another with changed data type of fields.

I am using ExtJS 4.0.7

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T04:53:13+00:00Added an answer on June 14, 2026 at 4:53 am

    You can have different types in the same store, but you have to load them manually, or use some trickery when loading.

    Not sure if you can have totally different types, but you can use different subtypes.

    Here is an example of changing store type on the fly based on the response:

    http://extjs-tutorials.blogspot.ca/2012/06/polymorphic-json-change-model-subclass.html

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this 4 Dimensional array to store String values which are used to
I have a char pointer which would be used to store a string. It
I have an int(11) column which is used to store money. I read some
I have two tables which are used to store details of different types of
I currently have 4 textboxes which will be used to store an ip address.
I have a JSON data store used for a combobox selection which is working
I have this much: A table which used to store the Folders. Each folder
I have two strings which are used to store time in the format hh:mm
I have this Oracle table which is used to store application settings. This is
I have a record store which holds a list of shopping items i am

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.