| @@ -17,15 +17,16 @@ class Controller extends BaseController | |||
| { | |||
| $result = array(); | |||
| $work_order = WorkOrder::all(); | |||
| $untaggedform = Form::where('customer_category', null)->get(); | |||
| foreach ($work_order as $key => $a) { | |||
| $untaggedform = Form::where('_id',$a->_id)->where('customer_category',null)->get(); | |||
| dd($untaggedform); | |||
| foreach ($untaggedform as $key => $a) { | |||
| $work_order = WorkOrder::where('_id', $a->_id)->get(); | |||
| if(!emptyArray($work_order)){ | |||
| array_push($result, array( | |||
| '_id' => $untaggedform->_id, | |||
| 'wo' => $work_order->wo, | |||
| )); | |||
| } | |||
| } | |||
| return json_encode($result); | |||