|
|
@@ -154,11 +154,12 @@ class Controller extends BaseController |
|
|
|
$staff = Staff::with('staffdetail')->where('email', 'dealer@test.my')->first(); |
|
|
|
$company = Company::where('name', 'TNBX Sdn Bhd')->first(); |
|
|
|
$staff->company_id = $company->_id; |
|
|
|
$staff->staffdetail->company_id = $company->_id; |
|
|
|
$staff->staffdetail()->save(); |
|
|
|
$staff->save(); |
|
|
|
|
|
|
|
return $company . $staff; |
|
|
|
$staffD = StaffDetail::where('_id',$staff->_id)->first(); |
|
|
|
$staffD->company_id = $company->_id; |
|
|
|
$staffD->save(); |
|
|
|
|
|
|
|
return $company . $staff . $staffD; |
|
|
|
} |
|
|
|
|
|
|
|
public function adjustInstaller(Request $request){ |