Proyectos de Subversion Moodle

Rev

Autoría | Ultima modificación | Ver Log |

{{!
    This file is part of Moodle - http://moodle.org/

    Moodle is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    Moodle is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with Moodle.  If not, see <http://www.gnu.org/licenses/>.
}}
{{!
    @template mod_forum/forum_actionbar
    Simple search input.
    Context variables required for this template:
    * see mod/forum/classes/output/forum_actionbar.php
    Example context (json):
    {
        "action": "https://moodle.local/mod/forum/search.php",
        "inputname": "search",
        "searchstring": "Search settings",
        "query": "themedesigner",
        "hiddenfields": [{
            "name": "id",
            "value": "11"
         }],
         "helpicon": {
         "heading": "Search",
         "text": "<div class='no-overflow'><p>For basic searching .</p></div>",
         "alt": "Help with search",
         "icon": [{
            "attributes": [{
                "name": "alt",
                "value": "Help with Search"
                }, {
                "name": "src",
                "value": "http://localhost/theme/image.php?theme=boost&component=core&image=help"
             }]
          }]
         },
        "newdiscussionbtn": "<a class='btn btn-primary'>Add discussion topic</a>",
        "subscribetoforum": "http://localhost/moodle/mod/forum/subscribe.php?id=7&sesskey=abcd&returnurl=http//localhost/moodle/mod/forum/view.php?id=4",
        "unsubscribefromforum": "http://localhost/moodle/mod/forum/subscribe.php?id=7&sesskey=abcd&returnurl=http//localhost/moodle/mod/forum/view.php?id=4"
    }
}}

<div class="container-fluid tertiary-navigation">
    <div class="row">
        <div class="navitem">
            {{> mod_forum/quick_search_form }}
        </div>
        <div class="navitem">
            {{{newdiscussionbtn}}}
        </div>
        <div class="ml-sm-auto navitem">
            {{#subscribetoforum}}
                <a class="btn btn-secondary" href="{{ subscribetoforum }}">{{#str}}subscribe, mod_forum {{/str}}</a>
            {{/subscribetoforum}}
            {{#unsubscribefromforum}}
                <a class="btn btn-secondary" href="{{ unsubscribefromforum }}">{{#str}}unsubscribe, mod_forum {{/str}}</a>
            {{/unsubscribefromforum}}
        </div>
    </div>
</div>