mirror of
https://github.com/Karaka-Management/oms-Admin.git
synced 2026-01-30 05:28:39 +00:00
Move response feedback to backend
This commit is contained in:
parent
14bb7e8d1c
commit
8626411e4b
|
|
@ -514,7 +514,12 @@ class Controller extends ModuleAbstract implements WebInterface
|
|||
|
||||
GroupMapper::update($group);
|
||||
|
||||
$response->set($request->__toString(), $group->jsonSerialize());
|
||||
$response->set($request->__toString(), [
|
||||
'status' => 'ok',
|
||||
'title' => 'Group',
|
||||
'message' => 'Group successfully updated.',
|
||||
'request' => $group->jsonSerialize()
|
||||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -572,7 +577,12 @@ class Controller extends ModuleAbstract implements WebInterface
|
|||
$group = $this->createGroupFromRequest($request);
|
||||
|
||||
GroupMapper::create($group);
|
||||
$response->set($request->__toString(), $group->jsonSerialize());
|
||||
$response->set($request->__toString(), [
|
||||
'status' => 'ok',
|
||||
'title' => 'Group',
|
||||
'message' => 'Group successfully created.',
|
||||
'request' => $group->jsonSerialize()
|
||||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ echo $this->getData('nav')->render(); ?>
|
|||
<section class="box wf-100">
|
||||
<header><h1><?= $this->getHtml('Account'); ?></h1></header>
|
||||
<div class="inner">
|
||||
<form id="fAccount" action="<?= \phpOMS\Uri\UriFactory::build('/{/lang}/api/admin/account'); ?>" method="put" data-msg='{"title": "Some Title", "message": "My Message"}'>
|
||||
<form id="fAccount" action="<?= \phpOMS\Uri\UriFactory::build('/{/lang}/api/admin/account'); ?>" method="put">
|
||||
<table class="layout wf-100">
|
||||
<tbody>
|
||||
<tr><td><label for="iType"><?= $this->getHtml('Type'); ?></label>
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ echo $this->getData('nav')->render(); ?>
|
|||
<section class="box wf-100">
|
||||
<header><h1><?= $this->getHtml('Group'); ?></h1></header>
|
||||
<div class="inner">
|
||||
<form id="group-create" action="<?= \phpOMS\Uri\UriFactory::build('/{/lang}/api/admin/group'); ?>" method="put" data-msg='{"title": "Some Title", "message": "My Message"}'>
|
||||
<form id="group-create" action="<?= \phpOMS\Uri\UriFactory::build('/{/lang}/api/admin/group'); ?>" method="put">
|
||||
<table class="layout wf-100">
|
||||
<tbody>
|
||||
<tr><td><label for="iStatus"><?= $this->getHtml('Status'); ?></label>
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ echo $this->getData('nav')->render(); ?>
|
|||
<section class="box wf-100">
|
||||
<header><h1><?= $this->getHtml('Group'); ?></h1></header>
|
||||
<div class="inner">
|
||||
<form id="fGroupEdit" action="<?= \phpOMS\Uri\UriFactory::build('/{/lang}/api/admin/group'); ?>" method="post" data-msg='{"title": "Some Title", "message": "My Message"}'>
|
||||
<form id="fGroupEdit" action="<?= \phpOMS\Uri\UriFactory::build('/{/lang}/api/admin/group'); ?>" method="post">
|
||||
<table class="layout wf-100">
|
||||
<tbody>
|
||||
<tr><td><label for="iGid"><?= $this->getHtml('ID', 0, 0); ?></label>
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user