Table Join

Allows you to join other tables. Only INNER JOIN supported. Keys in all joined tables must exist and be unique.


public function table_join()
{
  $xcrud = get_xcrud();
  $xcrud->table('employees');
  $xcrud->join('officeCode','offices','officeCode'); // ... INNER JOIN offices ON employees.officeCode = offices.officeCode ...
  
  //this line loads the <script> below it from a view
  $data['script'] = view('scripts', ['code' => 'table_join']);
  
  <script>
      $(document).ready(function() {
          $(".xcrud-list").tableHeadFixer({"head" : false, "left" : 2}); 
      });
  </script>
    
  $data['content'] = $xcrud->render();
  
  return view('demos', $data);
}

Employees

#LastnameFirstnameExtensionEmailOfficecodeReportstoJobtitleCityPhoneAddressline1Addressline2StateCountryPostalcodeTerritoryOrdering 
1Chieni5Patrickfgjhjpchieni@gmail.com3VP Marketing0
2DARA2DATRATRETANTAdara@gmail.com4454GIGIONEParis+33 14 723 440443 Rue Jouffroy D'abbansFrance75017EMEA4
3aaabbb dfghjklaaa@aa999a.com3aaa0
4erytu1San Francisco+1 650 219 4782100 Market StreetSuite 300CAUSA94080NA0
5aabb30
Search