|
|
@ -42,7 +42,7 @@ class AssignMaterialController extends Controller |
|
|
|
$data['budget'] = $checkStock->price; |
|
|
|
$data['budget'] = $checkStock->price; |
|
|
|
$data['qty_planning'] = $this->sanitizeDecimal($data['qty_planning']); |
|
|
|
$data['qty_planning'] = $this->sanitizeDecimal($data['qty_planning']); |
|
|
|
|
|
|
|
|
|
|
|
if ($planDate > $startDate) { |
|
|
|
if ($planDate >= $startDate) { |
|
|
|
$result = AssignMaterial::create($data); |
|
|
|
$result = AssignMaterial::create($data); |
|
|
|
return response()->json(['status'=>'success','message'=>'Data added!', 'code'=>200], 200); |
|
|
|
return response()->json(['status'=>'success','message'=>'Data added!', 'code'=>200], 200); |
|
|
|
}else{ |
|
|
|
}else{ |
|
|
|