This topic is locked

inlineAdd() question

2/11/2024 9:39:34 AM
PHPRunner General questions
N
Nikos Tsikas author

Hi all,
i am struggling to figure out how to do something that I think should be quite straightforward, yet I can't find it being a new phprunner user.
Using as inspiration the example "1. Simulate an "inline add" click:" from https://xlinesoft.com/phprunner/docs/how_to_control_inline_add_edit_functionality_from_script.htm
in the client after event of a button I have the following code, that calls the inlineadd() method. As you can see in the comments inside the code, I just can figure out how to populate certain fields in the newly added inline row. The row is in the details table on an add page of a master table.


if (pageObj.pageName=='addTVCall') {

console.log ('Dual Item List CLIENT AFTER On Editing in page '+pageObj.pageName);

console.log ('Result Array from Server part.');
console.log ('Maybe data can be used to autofill values in the following inlineadd()');
console.dir(result);

var details = pageObj.getDetailsPage( 'v_prs_TVorderitems');

// CAN I ADD SOMETHING HERE TO PREPARE THE NEW ROW TO BE ADDED WITH VALUES FROM THE RESULT OBJECT, OR ....
var newRow=details.inlineAdd.inlineAdd();
// CAN I ADD SOMETHING HERE TO FILL THE CREATED NEW ROW FIELDS WITH VALUES FROM THE RESULT OBJECT ????
console.dir('newRow');
console.dir(newRow);
};