|
|
|
@ -72,8 +72,13 @@ class DivisiController extends Controller
|
|
|
|
|
|
|
|
|
|
public function search() |
|
|
|
|
{ |
|
|
|
|
return $this->list(); |
|
|
|
|
// cant use builder for this case |
|
|
|
|
$payload = $request->all(); |
|
|
|
|
$dataBuilder = $this->setUpPayload($payload, 'm_divisi'); |
|
|
|
|
$builder = $dataBuilder['builder']; |
|
|
|
|
$countBuilder = $dataBuilder['count']; |
|
|
|
|
$dataGet = $builder->get(); |
|
|
|
|
$totalRecord = $countBuilder->count(); |
|
|
|
|
return response()->json(['status'=>'success','code'=>200,'data'=>$dataGet, 'totalRecord'=>$totalRecord], 200); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public function list() |
|
|
|
|