Foren
Related To Delete Functionality
deepthi narendula, geändert vor 11 Jahren.
Related To Delete Functionality
Junior Member Beiträge: 39 Beitrittsdatum: 26.04.12 Neueste Beiträge
Hi Friends,
I am using jquery and ajax call for deleting record in database,I am able to delete the record from database it is deleting at backend but at front end my searches were not deleting,how to do it please help me out.
Thanks&Regards,
N.Deepthi.
I am using jquery and ajax call for deleting record in database,I am able to delete the record from database it is deleting at backend but at front end my searches were not deleting,how to do it please help me out.
Thanks&Regards,
N.Deepthi.
Juhi Kumari, geändert vor 11 Jahren.
RE: Related To Delete Functionality
Expert Beiträge: 347 Beitrittsdatum: 12.12.11 Neueste Beiträge
Hi,
You can do it using jQuery.
and js method
This is the same functionality that are used in user portlet to remove Community,Roles etc..
Regards
Juhi
You can do it using jQuery.
<a class="modify-link" href="javascript: ;" onclick="jQuery(this).trigger('change'); Liferay.SearchContainer.get('<portlet:namespace />dalagateTable').deleteRow(this, <%= holiday.getHolidayId() %>);
<portlet:namespace />removeDelegate(<%= holiday.getHolidayId() %>)">
<%= removeRoleIcon %></a>
and js method
var <portlet:namespace />holidayIds = ['<%= ListUtil.toString(holidayList, "holidayId", "', '") %>'];
function <portlet:namespace />removeDelegate(id){
for (var i = 0; i < <portlet:namespace />holidayIds.length; i++) {
if(<portlet:namespace />holidayIds[i] == id){
<portlet:namespace />holidayIds.splice(i, 1);
break;
}
}
document.<portlet:namespace />fm.<portlet:namespace />holidayIds.value = <portlet:namespace />holidayIds.join(',');
}
This is the same functionality that are used in user portlet to remove Community,Roles etc..
Regards
Juhi