Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
MaarchCourrier
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Redmine
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Harbor Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Maarch
MaarchCourrier
Commits
4f2ceeac
Commit
4f2ceeac
authored
6 years ago
by
Florian Azizian
Browse files
Options
Downloads
Patches
Plain Diff
FEAT #7737 admin templates
parent
7d16af4b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
apps/maarch_entreprise/Views/template-administration.component.html
+4
-9
4 additions, 9 deletions
...h_entreprise/Views/template-administration.component.html
src/app/template/controllers/TemplateController.php
+3
-3
3 additions, 3 deletions
src/app/template/controllers/TemplateController.php
with
7 additions
and
12 deletions
apps/maarch_entreprise/Views/template-administration.component.html
+
4
−
9
View file @
4f2ceeac
...
...
@@ -128,10 +128,9 @@
<mat-form-field>
<mat-select
id=
"template_datasource"
name=
"template_datasource"
title=
"{{lang.templateDatasource}}"
placeholder=
"{{lang.templateDatasource}}"
[(ngModel)]=
"template.template_datasource"
>
<mat-option
value=
""
>
{{lang.noDatasource}}
</mat-option>
<mat-option
*ngFor=
"let datasource of datasourcesList"
[value]=
"
action.name
"
>
{{
action
.label}}
<mat-option
*ngFor=
"let datasource of datasourcesList"
[value]=
"
datasource.id
"
>
{{
datasource
.label}}
</mat-option>
<mat-option
value=
"letterbox_attachment"
>
[réponse] Informations du courrier entrant
</mat-option>
</mat-select>
</mat-form-field>
</div>
...
...
@@ -147,11 +146,7 @@
<div
class=
"form-group"
>
<div
class=
"col-sm-12"
style=
"text-align:center;"
>
<button
mat-raised-button
color=
"primary"
type=
"submit"
[disabled]=
"!templatesFormUp.form.valid"
>
{{lang.save}}
</button>
</div>
</div>
<div
class=
"form-group"
*ngIf=
"!creationMode"
>
<div
class=
"col-sm-12"
style=
"text-align:center;"
>
<button
mat-raised-button
color=
"primary"
type=
"button"
(click)=
"duplicateTemplate()"
>
{{lang.duplicate}}
</button>
<button
*ngIf=
"!creationMode"
mat-raised-button
color=
"primary"
type=
"button"
(click)=
"duplicateTemplate()"
>
{{lang.duplicate}}
</button>
</div>
</div>
</form>
...
...
@@ -164,4 +159,4 @@
</mat-list>
</mat-sidenav>
</mat-sidenav-container>
</div>
\ No newline at end of file
</div>
This diff is collapsed.
Click to expand it.
src/app/template/controllers/TemplateController.php
+
3
−
3
View file @
4f2ceeac
...
...
@@ -56,9 +56,9 @@ class TemplateController
}
$entities
=
EntityModel
::
getAllowedEntitiesByUserId
([
'userId'
=>
'superadmin'
]);
foreach
(
$entities
as
$key
=>
$entity
)
{
$entities
[
$key
][
'selected'
]
=
false
;
$entities
[
$key
][
'
state'
][
'
selected'
]
=
false
;
if
(
in_array
(
$entity
[
'id'
],
$linkedEntities
))
{
$entities
[
$key
][
'selected'
]
=
true
;
$entities
[
$key
][
'
state'
][
'
selected'
]
=
true
;
}
}
...
...
@@ -268,7 +268,7 @@ class TemplateController
$entities
=
EntityModel
::
getAllowedEntitiesByUserId
([
'userId'
=>
'superadmin'
]);
foreach
(
$entities
as
$key
=>
$entity
)
{
$entities
[
$key
][
'selected'
]
=
false
;
$entities
[
$key
][
'
state'
][
'
selected'
]
=
false
;
}
return
$response
->
withJson
([
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment