function deleteListItem(id){
var clientContext = SP.ClientContext.get_current();
var oList = clientContext.get_web().get_lists().getByTitle(list_name);
this.oListItem = oList.getItemById(id);
oListItem.deleteObject();
clientContext.executeQueryAsync(
Function.createDelegate(this, this.onQuerySucceededs),
Function.createDelegate(this, this.onQueryFaileds));
}
var clientContext = SP.ClientContext.get_current();
var oList = clientContext.get_web().get_lists().getByTitle(list_name);
this.oListItem = oList.getItemById(id);
oListItem.deleteObject();
clientContext.executeQueryAsync(
Function.createDelegate(this, this.onQuerySucceededs),
Function.createDelegate(this, this.onQueryFaileds));
}
No comments:
Post a Comment