Hi Marc,
On Sun, Jun 19, 2011 at 4:30 AM, Marc Delisle <marc(a)infomarc.info> wrote:
Le 2011-06-18 13:24, Thilanka Kaushalya a écrit :
Hi Marc,
I pushed my first set of changes to the repo on ajaxify the
table->multi_row->change option, please check that. For that I have used
some existing events in sql.js file.
When I submit the "*#insetForm*" I used
"*$("#pageselector").trigger('change');*" for reload the
"#*resultsForm*" table because since this is related to multiple rows
and there are many actions in "*#insertForm*" such as "*Save*" and
"*add
as a new row*", it is better to update the table.
And there are few issues with this.
1. I used
"*PMA_ajaxShowMessage(PMA_messages['strNoRowSelected']);*"
to show a message when user not selected a row and click on
change. Is this okay or should I change it.
Thilanka,
this is fine but please use the already existing 'No rows selected'
message, it's better to reuse messages to avoid too much work for our
translators.
Okay. I changed it to "*$js_messages['strNoRowSelected'] = __('No
rows
selected');*"
2. When a
row get changed I used following actions to reload the
"#*resultsForm*"
$("#pageselector").trigger('change');
$("#result_query").remove();
$("#sqlqueryresults").prepend(data.sql_query);
But since last two actions runs in the middle of first
trigger I cannot remove the *result_query * with the updated row message
after the table get reloaded. I cannot find why this happens. Please can
you help me on this.
I'm not sure I understand your question. In my test, the original
result_query div has been removed (it contained a SELECT) then with the
.prepend() it reappears with the UPDATE queries. The only problem I see
is an empty div with class notice at the beginning of the result_query div.
Maybe I did not test the same way you did.
Yes. I fixed it with by removing the .notice and replace it with success
message.
Thank you.
Regards,
Thilanka.
Also, the first time the "Change table" panel is displayed, I see many
notices of undefined variable submit_mult at the bottom of the panel.
I fixed it.
I pushed my code to the repo and please check that out. I'll update you soon
on "*ajaxify Expot*" task. Thank you.
Regards,
Thilanka.
--
L G Thilanka Kaushalya
Computer Science & Engineering,
University of Moratuwa,
Sri Lanka
Connect with me at,
Gmail : lgtkaushalya(a)gmail.com
Twitter : @thilanka_k
Facebook : Thilanka Kaushalya
Yahoo : lgtkaushalya(a)yahoo.com
Blog :
http://coders-view.blogspot.com/