Make app,localization in url optional+tld+subdomain

This commit is contained in:
Dennis Eichhorn 2019-03-09 23:21:29 +01:00
parent 71f9ed9a2e
commit 63903a9d78
9 changed files with 24 additions and 24 deletions

View File

@ -1,11 +1,11 @@
[
{
"id": 1002701001,
"pid": "/backend",
"pid": "/",
"type": 2,
"subtype": 1,
"name": "Helper",
"uri": "{/lang}/backend/helper/list?{?}",
"uri": "{/prefix}helper/list?{?}",
"target": "self",
"icon": null,
"order": 60,
@ -15,11 +15,11 @@
"children": [
{
"id": 1002702001,
"pid": "/backend/helper",
"pid": "/helper",
"type": 3,
"subtype": 1,
"name": "List",
"uri": "{/lang}/backend/helper/list?{?}",
"uri": "{/prefix}helper/list?{?}",
"target": "self",
"icon": null,
"order": 1,
@ -30,11 +30,11 @@
},
{
"id": 1002703001,
"pid": "/backend/helper",
"pid": "/helper",
"type": 3,
"subtype": 5,
"name": "CreateReport",
"uri": "{/lang}/backend/helper/report/create?{?}",
"uri": "{/prefix}helper/report/create?{?}",
"target": "self",
"icon": null,
"order": 5,
@ -45,11 +45,11 @@
},
{
"id": 1002704001,
"pid": "/backend/helper",
"pid": "/helper",
"type": 3,
"subtype": 5,
"name": "CreateTemplate",
"uri": "{/lang}/backend/helper/template/create?{?}",
"uri": "{/prefix}helper/template/create?{?}",
"target": "self",
"icon": null,
"order": 10,

View File

@ -6,7 +6,7 @@ use phpOMS\Account\PermissionType;
use phpOMS\Router\RouteVerb;
return [
'^.*/api/helper/report/export.*$' => [
'^.*/helper/report/export.*$' => [
[
'dest' => '\Modules\Helper\Controller\ApiController:apiHelperExport',
'verb' => RouteVerb::GET,
@ -17,7 +17,7 @@ return [
],
],
],
'^.*/api/helper/report/template.*$' => [
'^.*/helper/report/template.*$' => [
[
'dest' => '\Modules\Helper\Controller\ApiController:apiTemplateCreate',
'verb' => RouteVerb::SET,
@ -28,7 +28,7 @@ return [
],
],
],
'^.*/api/helper/report/report.*$' => [
'^.*/helper/report/report.*$' => [
[
'dest' => '\Modules\Helper\Controller\ApiController:apiReportCreate',
'verb' => RouteVerb::SET,

View File

@ -6,7 +6,7 @@ use phpOMS\Account\PermissionType;
use phpOMS\Router\RouteVerb;
return [
'^.*/backend/helper/template/create.*$' => [
'^.*/helper/template/create.*$' => [
[
'dest' => '\Modules\Media\Controller\BackendController::setUpFileUploader',
'verb' => RouteVerb::GET,
@ -26,7 +26,7 @@ return [
],
],
],
'^.*/backend/helper/report/create.*$' => [
'^.*/helper/report/create.*$' => [
[
'dest' => '\Modules\Media\Controller\BackendController::setUpFileUploader',
'verb' => RouteVerb::GET,
@ -46,7 +46,7 @@ return [
],
],
],
'^.*/backend/helper/list.*$' => [
'^.*/helper/list.*$' => [
[
'dest' => '\Modules\Helper\Controller\BackendController:viewTemplateList',
'verb' => RouteVerb::GET,
@ -57,7 +57,7 @@ return [
],
],
],
'^.*/backend/helper/report/view.*$' => [
'^.*/helper/report/view.*$' => [
[
'dest' => '\Modules\Helper\Controller\BackendController:viewHelperReport',
'verb' => RouteVerb::GET,

View File

@ -22,7 +22,7 @@ echo $this->getData('nav')->render(); ?>
<section class="box wf-100">
<header><h1><?= $this->getHtml('Report'); ?></h1></header>
<div class="inner">
<form id="helper-report-create" action="<?= \phpOMS\Uri\UriFactory::build('{/lang}/api/helper/report/report'); ?>" method="post">
<form id="helper-report-create" action="<?= \phpOMS\Uri\UriFactory::build('{/api}helper/report/report'); ?>" method="post">
<table class="layout wf-100">
<tbody>
<tr><td><label for="iTitle"><?= $this->getHtml('Title'); ?></label>

View File

@ -24,7 +24,7 @@ echo $this->getData('nav')->render(); ?>
<div class="bc-1">
<ul class="l-1">
<li>
<a href="<?= \phpOMS\Uri\UriFactory::build('{/lang}/backend/helper/single?{?}&id=' . $this->getData('name')); ?>"
<a href="<?= \phpOMS\Uri\UriFactory::build('{/prefix}helper/single?{?}&id=' . $this->getData('name')); ?>"
class="button"><?= $this->getHtml('Report') ?></a>
</ul>
</div>

View File

@ -45,7 +45,7 @@ echo $this->getData('nav')->render(); ?>
<td colspan="4"><?= $this->getHtml('Empty', 0, 0); ?>
<?php endif; ?>
<?php foreach ($templates as $key => $template) :
$url = \phpOMS\Uri\UriFactory::build('{/lang}/backend/helper/report/view?{?}&id=' . $template->getId()); ?>
$url = \phpOMS\Uri\UriFactory::build('{/prefix}helper/report/view?{?}&id=' . $template->getId()); ?>
<tr data-href="<?= $url; ?>">
<td data-label="<?= $this->getHtml('ID', 0, 0) ?>"><a href="<?= $url; ?>"><?= $this->printHtml($template->getId()); ?></a>
<td data-label="<?= $this->getHtml('Name') ?>"><a href="<?= $url; ?>"><?= $this->printHtml($template->getName()); ?></a>

View File

@ -28,7 +28,7 @@ echo $this->getData('nav')->render(); ?>
<div class="row" style="height: calc(100% - 85px);">
<div class="col-xs-12">
<div class="box wf-100" style="height: 100%;">
<iframe src="<?= \phpOMS\Uri\UriFactory::build('{/lang}/api/helper/report/export/?id=' . $template->getId()); ?>" allowfullscreen></iframe>
<iframe src="<?= \phpOMS\Uri\UriFactory::build('{/prefix}helper/report/export/?id=' . $template->getId()); ?>" allowfullscreen></iframe>
</div>
</div>
<!--
@ -38,7 +38,7 @@ echo $this->getData('nav')->render(); ?>
<header><h1><?= $this->getHtml('Reports') ?></h1></header>
<div class="inner">
<form action="<?= \phpOMS\Uri\UriFactory::build('{/lang}/api/helper/template'); ?>" method="post">
<form action="<?= \phpOMS\Uri\UriFactory::build('{/api}helper/template'); ?>" method="post">
<table class="layout wf-100">
<tbody>
<?php if (count($reportLanguage) > 1) : ?>
@ -68,7 +68,7 @@ echo $this->getData('nav')->render(); ?>
<header><h1><?= $this->getHtml('Export') ?></h1></header>
<div class="inner">
<form action="<?= \phpOMS\Uri\UriFactory::build('{/lang}/api/helper/template'); ?>" method="post">
<form action="<?= \phpOMS\Uri\UriFactory::build('{/api}helper/template'); ?>" method="post">
<table class="layout wf-100">
<tbody>
<tr>

View File

@ -21,7 +21,7 @@ echo $this->getData('nav')->render(); ?>
<section class="box wf-100">
<header><h1><?= $this->getHtml('Template'); ?></h1></header>
<div class="inner">
<form id="helper-template-create" action="<?= \phpOMS\Uri\UriFactory::build('{/lang}/api/helper/report/template'); ?>" method="post">
<form id="helper-template-create" action="<?= \phpOMS\Uri\UriFactory::build('{/api}helper/report/template'); ?>" method="post">
<table class="layout wf-100" style="table-layout: fixed">
<tbody>
<tr><td><label for="iTitle"><?= $this->getHtml('Title'); ?></label>

View File

@ -27,7 +27,7 @@
"load": [
{
"pid": [
"/backend/helper"
"/helper"
],
"type": 4,
"for": "Content",
@ -36,7 +36,7 @@
},
{
"pid": [
"/backend"
"/"
],
"type": 5,
"from": "Helper",