delToCase=(dell)=>{
let k = this.state.case.find(e=>e.id===dell.id)
// console.log(k);
if(!k){
let e = Object.assign({},dell)
e.quantity=1
this.state.case.push(e);
dell.count--
if(dell.count < 1){
this.state.product = this.state.product.filter(e => e.id !== dell.id)
}
}
else{
dell.count--
k.quantity++
if(dell.count < 1){
this.state.product = this.state.product.filter(e => e.id !== dell.id)
k.quantity=k.count
}
}
this.setState({});
}