|
Model.prototype.collectBtnClick = function(event){
var collectuid = justep.Shell.userId.get();
if($(this.getElementByXid("star")).hasClass("glyphicon-star-empty")){
this.comp("collectData").newData({
defaultValues : [ {
"pid" : pID,
"collectuid" : collectuid,
} ]
});
this.comp('collectData').saveData();
$(this.getElementByXid("star")).removeClass("glyphicon-star-empty").addClass("glyphicon-star");
justep.Util.hint('收藏成功!',{'type':'success','delay':1000});
}else{
this.comp('collectData').deleteData();
$(this.getElementByXid("star")).removeClass("glyphicon-star").addClass("glyphicon-star-empty");
justep.Util.hint('收藏取消!',{'type':'success','delay':1000});
}
}; 我要删除我保存的那一行改怎么写呢?
|
|