var exist=false; var self=this; var s; $("[id*='B']").each(function(){ if($(this).text()==self.getValue()){ exist=true; } }); if(exist){ alert("此数据已存在"); this.setValue(''); this.setText(''); return false; } 点击增加按钮过后这个JS好像不起作用
|
立即参与
