$.post().success();的success自定义函数怎么传参数?
原来功能是,圈出来的是参数,
想改成下面的这样
这个参数不知道怎么传进去了...
应该怎么写呀
dellaa=function(thisItem){
alert(data.check);
if(data.check==1){
//alert("删除成功");
$(thisItem).parent().parent().parent().remove(); //删除item
showmsg(id+"删除成功");
}else{
//alert("删除失败");
}
}
Items.prototype.ajaxComm=function (obj,traget,query) {
$(obj).each(function(){
$(this).click(function(){
var id=$(this).parent().parent().parent().attr("id"); //获取ID
//console.log(id);
target=window.HOST_URL+traget;//"/Home/items/"+actionname
console.log(obj,target);
//alert(window.HOST_URL);
//var query={}; //定义键值对(数组)
query["id"]=id; //定义键值对
var thisItem=this;
$.post(target,query).success(dellaa);
});
});
}
相关阅读:
Docker Compose的yml文件中privileged参数的作用是什么?
JAVA改写成用constructor方法
在node.js 绝对路径和相对路径混用的问题?
怎么突破javapns推送256个字节的限制?
有良好的把Django+pymysql+gevent跑起来的吗?
Notification 修改icon
《CSS权威指南》中关于表格的描述
android QQ v6右上角的弹出菜单是怎么实现的?
echarts的bar支持color透明麽?
python上有没有比较好的验证码生成的包
php 页面输出为什么换行符丢失了?
除某元素之外怎么写?
Install and enable the intl extension (used for validators)
Yii2-elasticsearch 怎么用啊?
js验证是否为特选手机号码
ANSI编码和American National Standards Institute有什么关系?
python导入scimath失败提示:cannot import name scimath
如何通过npm管理不同版本的包?
iOS中点击推送的通知栏,通知栏为什么不会消失
端口被占用,如何取消?