Tuesday, 15 July 2014

rally - Finding the total -



rally - Finding the total -

i built grid, , 1 of columns actual hours. wondering how tally actual hours find total actual hours worked (obviously blank actual hours input zero). have tried using ext.array.each cant figure out parameters should be. tried converting grid table , adding cells has not worked either. load function:

//this.ownercombobox = combobox; this.add({ xtype : 'rallygrid', columncfgs : ['formattedid', 'name', 'state', 'actuals', 'time spent', 'owner'], context : this.getcontext(), storeconfig : { model : 'task', context : this.context.getdatacontext(), filters : [this._getstatefilter(), this._getstatefilter2()] }, }); var config = { columns : [{ key : 'formattedid', }, { key : 'name' }, { key : 'schedulestate', }, { key : 'actuals' }] }; var table = new rally.sdk.ui.table(config); var vel = 0; alert(table.getcell(1,3)); (var = 0; < table.length; i++) { vel = vel + table.getcell(i, 3); } document.getelementbyid("total").innerhtml = "the total is: " + vel;

when run code console gives me error uncaught referenceerror: rally not defined (referencing rally.sdk.ui.table). know there improve way it, stuck. have tips table working or how can utilize ext.array.each?

the rally.sdk.ui.table appsdk 1.x. object doesn't exist in appsdk2. sdk2 equivalent rally.ui.grid.grid.

i think you'll find next example:

http://help.rallydev.com/apps/2.0rc3/doc/#!/example/custom-data-grid

helpful. _ondataloaded method shows how pre-processing on records rally.data.wsapi.store before using output in grid.

rally

No comments:

Post a Comment