Monday, June 20, 2011

AJAXify phpMyAdmin Interface - GSOC 2011 - Fourth week

After ajaxifying the table-> insert in db-> structure in last week, I had to fix some bugs in the same option this week also. Then I started applying ajax dialog for muti_row->change in the table->browse option. As Marc requested I have changed the name of the form "rowsDeleteForm" in to "resultsForm". Then I went through the code to find whether there are any code segments which can be used for my developments. There were not much code on that and I just find the
$("input[name=navig].ajax").click

function which can be used for reload the "resultForm" after successfully changing the row values.

Then I started implementing the feature and first I developed the click event for "Change" option which pops up the "Change" dialog which contains the "#insertForm" form which allows to change the selected values.
$("#resultsForm.ajax .mult_submit[value=edit]").live('click')


Then I developed the two events which handles the clicks on go buttons at "InsertRowTable" and "navigationPanel". Those are
$("#insertForm .insertRowTable.ajax input[value=Go]").live('click') and
$("#buttonYes.ajax").live('click')
On those I used the "$.post()" action to submit the changed values and if it is success used to trigger the "navg" button to reload the "resutlsForm".
$("input[name=navig].ajax").trigger('click')

After instructions given by Marc, I changed the code in order it supports for the vertical table.

This feature is now works fine and merged to the master branch by Marc and I believe it really improve the usability of the PMA.

Next week I have to work with ajaxify the table->export in db->browse and the actions in multiple rows in the table->structure.


No comments:

Post a Comment