Simple relation

You can get options list from other table

HIDE CODE
<?php
	$xcrud = Xcrud::get_instance();
    $xcrud->table('employees');
    $xcrud->table_name('Simple relation');
    $xcrud->relation('officeCode','offices','officeCode','city');
    $xcrud->label('officeCode','Office in');
    $xcrud->columns('firstName,lastName,officeCode');
    $xcrud->fields('firstName,lastName,officeCode');
    $xcrud->limit(10);
    echo $xcrud->render();
?>

Simple relation

#FirstnameLastnameOffice in
Actions
1JoFirrelli2London View Edit Remove
2123PattersonLondon View Edit Remove
3Gerard2BondurNYC View Edit Remove
4Anthony8BowSan Francisco View Edit Remove
5LeslieJenningsTokyo View Edit Remove
6LeslieThompsonSan Francisco View Edit Remove
7JulieFirrelliBoston View Edit Remove
8StevePattersonBoston View Edit Remove
9Foon YueTseng View Edit Remove
10George NVanaufNYC View Edit Remove
Search