|
@@ -469,7 +469,7 @@ class Purchase extends Controller
|
|
|
->findOrFail($data['id']);
|
|
|
foreach ($model['items'] as &$v){
|
|
|
foreach ($v['offers'] as $aa=>&$a){
|
|
|
- if($a['id']!=$v['offer_id']){
|
|
|
+ if($a['id']!=$v['offer_id'] && $v['offer_id']!=''){
|
|
|
unset($v['offers'][$aa]);
|
|
|
}
|
|
|
$a['amounts'] = ShopPurchaseOfferAmount::mk()
|