Merge branch 'fronkdev' into 'master'
Everyone can create Workorders for Preorders now See merge request fronk/thetool!1001
This commit is contained in:
@@ -423,9 +423,7 @@ $pagination_entity_name = "Vorbestellungen";
|
||||
<th>Partner</th>
|
||||
<th>Attribute</th>
|
||||
<th>Erstellt<br />Bearbeitet</th>
|
||||
<?php if($me->is(["Admin","netowner"])): ?>
|
||||
<th></th>
|
||||
<?php endif; ?>
|
||||
<th></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
<?php foreach($preorders as $preorder): ?>
|
||||
|
||||
@@ -1345,12 +1345,14 @@ class PreorderController extends mfBaseController {
|
||||
/*if($preorder->type != "legacytransfer") {
|
||||
return false;
|
||||
}*/
|
||||
if(!$this->me->is("Admin")) {
|
||||
if(!$this->me->is("Admin") && !$this->me->can("preorder")) {
|
||||
$this->log->debug(__METHOD__.": no permission");
|
||||
return false;
|
||||
}
|
||||
|
||||
$workorder = $preorder->createRimoWorkorder();
|
||||
if(!$workorder) {
|
||||
$this->log->debug(__METHOD__.": error creating workorder");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user