Hi guys,
I have created a CMP that shows the user a MODx.grid.
To this graid I have added a right-click action to update, createing a MODx.window for editing.
Problem: Window and form open fine first time and will allow update. However any subsequent update on the same record or a different record will populate the update form with the values of the first!! So I can't update any other record.
Code below: I assume that when I refresh the grid, the this.menu.records should get refreshed, this however does not seem to happen.
Any help much appreciated
/* Run this after the user update a game category page */
,update:
function(btn,e) {
if (!this.CreateGameCategory) {
this.CreateGameCategory = MODx.load({
xtype: 'modx-window-game-category-update'
,record: this.menu.record
,listeners: {
'success': {fn:this.refresh,scope:this}
}
});
}
this.CreateGameCategory.setValues(this.menu.record);
this.CreateGameCategory.show(e.target);
}