Skip to content

CSV ExtJS Locale #217

@KaiVolland

Description

@KaiVolland

We should change the key in the CSV from the view name to the viewmodel name and adapt the logic.

This has one simple reason:

If you use the viewmodel with the corresponding value in another view the translated string cannot be found as the view has another xtype. e.g:

Ext.define('MyApp.SuperWindow', {
    extend: 'Ext.window.Window',
    viewModel: 'superwindow',

    bind: {
        title: '{superwindowtitle}'
    },

    initComponent: function(){
        Ext.create('Ext.window.Window', {
            viewModel: this.getViewModel(),
            bind: {
                 title: '{superwindowtitle}'
            }
        })
    }
});

If there is the following value in our CSV MyApp.SuperWindow, config.data.superwindowtitle, "peter", "paul" we get an error with the Ext.window.Window as it doesn't appear in the CSV.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions