close #1752 Fixed: Exception in documents "empty" page
This commit is contained in:
parent
61247dd5ae
commit
781ae067e9
@ -293,7 +293,13 @@ abstract class DocumentIndex extends Base
|
|||||||
return $page;
|
return $page;
|
||||||
}
|
}
|
||||||
|
|
||||||
return config('type.' . $type . '.route.prefix', 'invoices');
|
$page = config('type.' . $type . '.route.prefix', 'invoices');
|
||||||
|
|
||||||
|
if ($alias = config('type.' . $type . '.alias')) {
|
||||||
|
$page = $alias . '.' . $page;
|
||||||
|
}
|
||||||
|
|
||||||
|
return $page;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function getDocsPath($type, $docsPath)
|
protected function getDocsPath($type, $docsPath)
|
||||||
@ -309,16 +315,14 @@ abstract class DocumentIndex extends Base
|
|||||||
}
|
}
|
||||||
|
|
||||||
switch ($type) {
|
switch ($type) {
|
||||||
case 'sale':
|
|
||||||
case 'income':
|
|
||||||
case 'invoice':
|
|
||||||
$docsPath = 'sales/invoices';
|
|
||||||
break;
|
|
||||||
case 'bill':
|
case 'bill':
|
||||||
case 'expense':
|
case 'expense':
|
||||||
case 'purchase':
|
case 'purchase':
|
||||||
$docsPath = 'purchases/bills';
|
$docsPath = 'purchases/bills';
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
$docsPath = 'sales/invoices';
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
return $docsPath;
|
return $docsPath;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user