Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
BudgetMaster
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Admin message
PlayWallDesktop wird heute 10 Jahre alt!
Show more breadcrumbs
Robert Goldmann
BudgetMaster
Commits
a03926e0
Commit
a03926e0
authored
May 4, 2019
by
Robert Goldmann
Browse files
Options
Downloads
Patches
Plain Diff
#274 - added macros
parent
0d91637c
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/main/resources/templates/search/search.ftl
+3
-55
3 additions, 55 deletions
src/main/resources/templates/search/search.ftl
src/main/resources/templates/search/searchMacros.ftl
+60
-0
60 additions, 0 deletions
src/main/resources/templates/search/searchMacros.ftl
with
63 additions
and
55 deletions
src/main/resources/templates/search/search.ftl
+
3
−
55
View file @
a03926e0
...
...
@@ -12,6 +12,7 @@
<@navbar.navbar "home" settings/>
<#import "../transactions/transactionsMacros.ftl" as transactionsMacros>
<#import "searchMacros.ftl" as searchMacros>
<main>
<div class="card main-card background-color">
...
...
@@ -22,62 +23,9 @@
</div>
<form name="NewSearch" action="<@s.url '/search'/>" method="post">
<input type="hidden" name="$
{
_
csrf
.parameterName
}
" value="$
{
_
csrf
.token
}
"/>
<div class="row no-margin-bottom valign-wrapper">
<div class="col s10 m7 offset-m1 l6 offset-l2">
<div class="input-field">
<input id="searchText" type="text" name="searchText" value="$
{
search
.getSearchText
()}
">
<label for="searchText">$
{
locale
.getString
(
"search"
)}
</label>
</div>
</div>
<div class="col s2 m3 l4">
<div class="hide-on-small-only">
<button class="btn waves-effect waves-light budgetmaster-blue" type="submit" name="action">
<i class="material-icons left">search</i>$
{
locale
.getString
(
"search.submit"
)}
</button>
</div>
<div class="hide-on-med-and-up">
<button class="btn waves-effect waves-light budgetmaster-blue" type="submit" name="action">
<i class="material-icons">search</i>
</button>
</div>
</div>
</div>
<div class="row">
<div class="col s8 offset-s2 m4 offset-m2 l3 offset-l3">
<div class="search-checkbox-container">
<label>
<input type="checkbox" name="searchName" <#if search.isSearchName()>checked="checked"</#if>>
<span class="text-color">$
{
locale
.getString
(
'
search
.in.name
'
)}
</span>
</label>
</div>
</div>
<div class="col s8 offset-s2 m6 l6">
<div class="search-checkbox-container">
<label>
<input type="checkbox" name="searchDescription" <#if search.isSearchDescription()>checked="checked"</#if>>
<span class="text-color">$
{
locale
.getString
(
'
search
.in.description
'
)}
</span>
</label>
</div>
</div>
<div class="col s8 offset-s2 m4 offset-m2 l3 offset-l3">
<div class="search-checkbox-container">
<label>
<input type="checkbox" name="searchCategory" <#if search.isSearchCategory()>checked="checked"</#if>>
<span class="text-color">$
{
locale
.getString
(
'
search
.in.category
'
)}
</span>
</label>
</div>
</div>
<div class="col s8 offset-s2 m6 l6">
<div class="search-checkbox-container">
<label>
<input type="checkbox" name="searchTags" <#if search.isSearchTags()>checked="checked"</#if>>
<span class="text-color">$
{
locale
.getString
(
'
search
.in.tags
'
)}
</span>
</label>
</div>
</div>
</div>
<@searchMacros.searchTextAndButton search/>
<@searchMacros.checkboxes search/>
</form>
<div class="row search-container">
...
...
This diff is collapsed.
Click to expand it.
src/main/resources/templates/search/searchMacros.ftl
0 → 100644
+
60
−
0
View file @
a03926e0
<#
macro
searchTextAndButton search>
<div class="row no-margin-bottom valign-wrapper">
<div class="col s10 m7 offset-m1 l6 offset-l2">
<div class="input-field">
<input id="searchText" type="text" name="searchText" value="$
{
search
.getSearchText
()}
">
<label for="searchText">$
{
locale
.getString
(
"search"
)}
</label>
</div>
</div>
<div class="col s2 m3 l4">
<div class="hide-on-small-only">
<button class="btn waves-effect waves-light budgetmaster-blue" type="submit" name="action">
<i class="material-icons left">search</i>$
{
locale
.getString
(
"search.submit"
)}
</button>
</div>
<div class="hide-on-med-and-up">
<button class="btn waves-effect waves-light budgetmaster-blue" type="submit" name="action">
<i class="material-icons">search</i>
</button>
</div>
</div>
</div>
</#
macro
>
<#
macro
checkboxes search>
<div class="row">
<div class="col s8 offset-s2 m4 offset-m2 l3 offset-l3">
<div class="search-checkbox-container">
<label>
<input type="checkbox" name="searchName" <#if search.isSearchName()>checked="checked"</#if>>
<span class="text-color">$
{
locale
.getString
(
'
search
.in.name
'
)}
</span>
</label>
</div>
</div>
<div class="col s8 offset-s2 m6 l6">
<div class="search-checkbox-container">
<label>
<input type="checkbox" name="searchDescription" <#if search.isSearchDescription()>checked="checked"</#if>>
<span class="text-color">$
{
locale
.getString
(
'
search
.in.description
'
)}
</span>
</label>
</div>
</div>
<div class="col s8 offset-s2 m4 offset-m2 l3 offset-l3">
<div class="search-checkbox-container">
<label>
<input type="checkbox" name="searchCategory" <#if search.isSearchCategory()>checked="checked"</#if>>
<span class="text-color">$
{
locale
.getString
(
'
search
.in.category
'
)}
</span>
</label>
</div>
</div>
<div class="col s8 offset-s2 m6 l6">
<div class="search-checkbox-container">
<label>
<input type="checkbox" name="searchTags" <#if search.isSearchTags()>checked="checked"</#if>>
<span class="text-color">$
{
locale
.getString
(
'
search
.in.tags
'
)}
</span>
</label>
</div>
</div>
</div>
</#
macro
>
\ No newline at end of file
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