|
|
@ -29,10 +29,12 @@ class ReportActivityMaterialController extends Controller |
|
|
|
$data['assign_material_id'] = $request->assign_material_id; |
|
|
|
$data['assign_material_id'] = $request->assign_material_id; |
|
|
|
$data['qty'] = $this->sanitizeDecimal($data['qty']); |
|
|
|
$data['qty'] = $this->sanitizeDecimal($data['qty']); |
|
|
|
|
|
|
|
|
|
|
|
if(!ReportActivityMaterial::create($data)) |
|
|
|
$created = ReportActivityMaterial::create($data); |
|
|
|
return response()->json(['status'=>'failed','message'=>'Input progress report activity failed created','code'=>400]); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return response()->json(['status'=>'success','message'=>'Input progress report activity created','code'=>200]); |
|
|
|
if(!$created) |
|
|
|
|
|
|
|
return response()->json(['status'=>'failed','message'=>'Input progress report activity failed created','code'=>400,'data'=>null]); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return response()->json(['status'=>'success','message'=>'Input progress report activity created','code'=>200,'data'=>array('report_id'=>$created->id)]); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public function updateStatusStartFinish(Request $request){ |
|
|
|
public function updateStatusStartFinish(Request $request){ |
|
|
|