$this->db->where('product_id',$product_id);
$this->db->where('seller_id',$loginSession[0]->seller_id);
$res1=$this->db->delete('crm_seller_cart');
//$this->db->where('product_id',$product_id);
//$this->db->where('seller_id',$loginSession[0]->seller_id);
$res2=$this->db->delete('crm_customer_recently_viewed');
此处$res1
和$res2
都返回1但物理行不会删除$res
,序列中是否有任何问题
答案 0 :(得分:0)
试试这个
<script>
$(function(){
$("#datepicker" ).datepicker({
changeMonth: true,
changeYear: true,
showAnim: 'clip',
dateFormat: "yy-mm-dd"
}).val();
});
$("#datepicker").click(function() {
if (confirm("If you change the Date the Fare fields data will be deleted !!")) {
$('#fare').val('');
} else {
return false;
$("#datepicker").datepicker('destroy');
}
});
<script>
OR
$condition=array('product_id' => $product_id,'seller_id'=>$loginSession[0]->seller_id);
$this->db->delete('crm_seller_cart', $condition);
$this->db->delete('crm_customer_recently_viewed',$condition);