partial #2350 - Create an option to assign drivers per community
This commit is contained in:
parent
da1a87a67c
commit
aa917afeb2
@ -826,6 +826,8 @@ class Crunchbutton_Order extends Cana_Table {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// check if the restaurant is using our delivery system
|
||||||
|
if( intval( $order->restaurant()->delivery_service ) == 1 ){
|
||||||
// get the restaurant community and its drivers
|
// get the restaurant community and its drivers
|
||||||
$community = $order->restaurant()->community;
|
$community = $order->restaurant()->community;
|
||||||
if( $community ){
|
if( $community ){
|
||||||
@ -837,6 +839,7 @@ class Crunchbutton_Order extends Cana_Table {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Send notification to drivers
|
// Send notification to drivers
|
||||||
if( count( $driversToNotify ) > 0 ){
|
if( count( $driversToNotify ) > 0 ){
|
||||||
|
|||||||
@ -15,11 +15,21 @@ $groups = $this->groups;
|
|||||||
<tr>
|
<tr>
|
||||||
<td><?php echo $group->name;?> </td>
|
<td><?php echo $group->name;?> </td>
|
||||||
<td><?php echo $group->description;?> </td>
|
<td><?php echo $group->description;?> </td>
|
||||||
<td><?php echo $group->usersTotal();?> </td>
|
<td><?php echo $group->usersTotal();?>
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<?php
|
||||||
|
// verify if it is an system group
|
||||||
|
$pos = strrpos( $group->name, Crunchbutton_Group::DRIVER_GROUPS_PREFIX );
|
||||||
|
?>
|
||||||
<td style="width:280px;">
|
<td style="width:280px;">
|
||||||
|
<?php if( $pos === false ) { ?>
|
||||||
<a href="/permissions/groups/permissions/<?php echo $group->id_group; ?>" class="btn btn-blue"><i class="icon-unlock"></i> Permissions</a>
|
<a href="/permissions/groups/permissions/<?php echo $group->id_group; ?>" class="btn btn-blue"><i class="icon-unlock"></i> Permissions</a>
|
||||||
|
|
||||||
<a href="/permissions/groups/<?php echo $group->id_group; ?>" class="btn btn-green"><i class="icon-edit"></i> Edit</a>
|
<a href="/permissions/groups/<?php echo $group->id_group; ?>" class="btn btn-green"><i class="icon-edit"></i> Edit</a>
|
||||||
|
<?php } else { ?>
|
||||||
|
<i style="font-size:11px;">This group could not be modified</i>
|
||||||
|
<?php } ?>
|
||||||
|
|
||||||
<button data-id="<?php echo $group->id_group; ?>" class="btn group-remove btn-red"><i class="icon-trash"></i> Remove</button>
|
<button data-id="<?php echo $group->id_group; ?>" class="btn group-remove btn-red"><i class="icon-trash"></i> Remove</button>
|
||||||
</td>
|
</td>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user