menu.tpl 8.88 KB
Newer Older
1 2
<TMPL_INCLUDE NAME="header.tpl">

3
<main id="menucontent" class="container">
4 5

  <TMPL_IF NAME="AUTH_ERROR">
6
  <div class="message message-<TMPL_VAR NAME="AUTH_ERROR_TYPE"> alert"><span trmsg="<TMPL_VAR NAME="AUTH_ERROR">"></span></div>
7 8 9 10
  </TMPL_IF>

  <div id="menu">

11
  <nav class="navbar navbar-expand-lg navbar-light bg-light">
Christophe Maudoux's avatar
Christophe Maudoux committed
12
    <a class="navbar-brand" href="/"><i class="fa fa-home"></i></a>
13 14
    <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
      <span class="navbar-toggler-icon"></span>
15
    </button>
16 17

    <TMPL_IF DISPLAY_MODULES>
18

19
    <div class="collapse navbar-collapse" id="navbarSupportedContent">
20
    <!-- Tabs list -->
21
      <ul class="navbar-nav mr-auto">
22 23 24
        <TMPL_LOOP NAME="DISPLAY_MODULES">

          <TMPL_IF NAME="Appslist">
25
            <li class="nav-item"><a class="nav-link" href="#appslist"><span>
26
              <img src="<TMPL_VAR NAME="STATIC_PREFIX">common/icons/application_cascade.png" width="16" height="16" alt="appslist" />
27
              <span trspan="yourApps">Your applications</span>
28 29 30
            </span></a></li>
          </TMPL_IF>
          <TMPL_IF NAME="ChangePassword">
31
            <li class="nav-item"><a class="nav-link" href="#password"><span>
32
              <img src="<TMPL_VAR NAME="STATIC_PREFIX">common/icons/vcard_edit.png" width="16" height="16" alt="password" />
33
              <span trspan="password">Password</span>
34 35 36
            </span></a></li>
          </TMPL_IF>
          <TMPL_IF NAME="LoginHistory">
37
            <li class="nav-item"><a class="nav-link" href="#loginHistory"><span>
38
              <img src="<TMPL_VAR NAME="STATIC_PREFIX">common/icons/calendar.png" width="16" height="16" alt="login history" />
39
              <span trspan="loginHistory">Login history</span>
40 41
            </span></a></li>
          </TMPL_IF>
42
          <TMPL_IF NAME="OidcConsents">
43
            <li class="nav-item"><a class="nav-link" href="#oidcConsents"><span>
44
              <img src="<TMPL_VAR NAME="STATIC_PREFIX">common/icons/oidc.png" width="16" height="16" alt="login history" />
45 46 47
              <span trspan="oidcConsents">OIDC Consent</span>
            </span></a></li>
          </TMPL_IF>
48
          <TMPL_IF NAME="Logout">
49
            <li class="nav-item"><a class="nav-link" href="#logout"><span>
50
              <img src="<TMPL_VAR NAME="STATIC_PREFIX">common/icons/door_out.png" width="16" height="16" alt="logout" />
51
              <span trspan="logout">Logout</span>
52 53 54 55
            </span></a></li>
          </TMPL_IF>
        </TMPL_LOOP>
      </ul>
56

57
      <ul class="user nav navbar-nav navbar-right">
58 59
        <li class="nav-item dropdown">
          <a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown">
60 61 62 63
            <span trspan="connectedAs">Connected as</span> <TMPL_VAR NAME="AUTH_USER">
            <span class="caret"></span>
          </a>
          <ul class="dropdown-menu" role="menu">
64
            <TMPL_IF NAME="sfaManager">
65
              <li class="dropdown-item"><a href="/2fregisters" class="nav-link">
66 67 68
                <img src="<TMPL_VAR NAME="STATIC_PREFIX">common/icons/sfa_manager.png" width="16" height="16" alt="refresh" />
                <span trspan="sfaManager">sfaManager</span>
              </a></li>
69
            </TMPL_IF>
70
            <li class="dropdown-item"><a href="/refresh" class="nav-link">
71 72 73
              <img src="<TMPL_VAR NAME="STATIC_PREFIX">common/icons/arrow_refresh.png" width="16" height="16" alt="refresh" />
              <span trspan="refreshrights">Refresh</span>
            </a></li>
74 75 76
          </ul>
        </li>
      </ul>
77

78
    </div>
79 80
    </TMPL_IF>

81
    </nav>
82

83 84 85 86 87 88 89 90 91 92 93 94
    <!-- Tabs content -->
    <TMPL_LOOP NAME="DISPLAY_MODULES">

      <TMPL_IF NAME="Appslist">
        <div id="appslist">

          <TMPL_LOOP NAME="APPSLIST_LOOP">
          <!-- Template loops -->

            <TMPL_IF NAME="category">
            <!-- Category -->

95
              <div class="category cat-level-<TMPL_VAR NAME="catlevel"> <TMPL_VAR NAME="catid"> card border-secondary" id="sort_<TMPL_VAR NAME="__counter__">">
96

97 98
                <div class="card-header text-white bg-secondary">
                <h4 class="catname card-title"><TMPL_VAR NAME="catname"></h4>
99
                </div>
100 101

                  <TMPL_IF applications>
102
                  <div class="card-body">
103 104
                    <!-- Applications -->

105
                    <div class="row">
106 107 108
                    <TMPL_LOOP NAME=applications>

                      <!-- Application -->
109
                      <div class="col-md-4">
110 111
                      <div class="application <TMPL_VAR NAME="appid"> card">
                        <a href="<TMPL_VAR NAME="appuri">" title="<TMPL_VAR NAME="appname">" >
112

113
                        <div class="card-body">
114
                        <div class="row">
115 116
                        <!-- Logo (optional) -->
                        <TMPL_IF NAME="applogo">
117
                          <div class="col-3">
118
                          <img src="<TMPL_VAR NAME="STATIC_PREFIX">common/apps/<TMPL_VAR NAME="applogo">"
119
                            class="applogo <TMPL_VAR NAME="appid"> img-fluid"
120
                            alt="<TMPL_VAR NAME="appname">" />
121
                          </div>
122
                          <div class="col-9">
123
                        <TMPL_ELSE>
124
                          <div class="col-12">
125
                        </TMPL_IF>
126
                        
127
                        <!-- Name and link (mandatory) -->
128
                        <h5 class="appname <TMPL_VAR NAME="appid"> card-title">
129
                          <TMPL_VAR NAME="appname">
130
                        </h5>
131

132
                        <!-- Description (optional) -->
133
                        <TMPL_IF NAME="appdesc">
134
                          <p class="appdesc <TMPL_VAR NAME="appid"> card-subtitle mb-2 text-muted">
135 136 137 138
                            <TMPL_VAR NAME="appdesc">
                          </p>
                        </TMPL_IF>

139 140
                          </div>
                        </div>
141
                        </div>
142
                        </a>
143

144
                      </div>
145 146
                      </div>

147 148 149

                    <!-- End of applications loop -->
                    </TMPL_LOOP>
150
                    </div>
151

152
                  </div>
153 154 155 156 157 158 159 160 161 162 163 164
                  </TMPL_IF>

                </div>

              <!-- End of categories loop -->
            </TMPL_IF>
          </TMPL_LOOP>

        </div>
      </TMPL_IF>

      <TMPL_IF NAME="ChangePassword">
165
        <div id="password">
166 167
            <div class="card border-secondary">
              <div class="card-header text-white bg-secondary">
168
              <h4 class="card-title" trspan="changePwd">Change your password</h4>
169
              </div>
170
              <div class="card-body">
171 172 173 174
              <TMPL_INCLUDE NAME="password.tpl">
              </div>
            </div>
        </div>
175 176 177 178 179
      </TMPL_IF>

      <TMPL_IF NAME="LoginHistory">
        <div id="loginHistory">
            <TMPL_IF NAME="SUCCESS_LOGIN">
180 181
            <div class="card border-secondary">
              <div class="card-header text-white bg-secondary">
182
              <h4 class="card-title" trspan="lastLogins">Last logins</h4>
183
              </div>
184
              <div class="card-body">
185
              <TMPL_VAR NAME="SUCCESS_LOGIN">
186 187
              </div>
            </div>
188 189
            </TMPL_IF>
            <TMPL_IF NAME="FAILED_LOGIN">
190 191
            <div class="card border-secondary">
              <div class="card-header text-white bg-secondary">
192
              <h4 class="card-title" trspan="lastFailedLogins">Last failed logins</h4>
193
              </div>
194
              <div class="card-body">
195
              <TMPL_VAR NAME="FAILED_LOGIN">
196 197
              </div>
            </div>
198 199 200 201
            </TMPL_IF>
        </div>
      </TMPL_IF>

202 203
      <TMPL_IF NAME="OidcConsents">
        <div id="oidcConsents">
204 205
            <div class="card border-secondary">
              <div class="card-header text-white bg-secondary">
206
              <h4 class="card-title" trspan="oidcConsentsFull">OpenID-Connect Consents</h4>
207
              </div>
208
              <div class="card-body">
209
              <TMPL_VAR NAME="OIDC_CONSENTS">
210 211 212 213 214
              </div>
            </div>
        </div>
      </TMPL_IF>

215 216
      <TMPL_IF NAME="Logout">
        <div id="logout">
217 218
          <div class="card border-secondary">
            <div class="card-header text-white bg-secondary">
219
              <h4 class="card-title" trspan="areYouSure">Are you sure ?</h4>
220
            </div>
221
            <div class="card-body buttons">
222
            <a href="<TMPL_VAR NAME="LOGOUT_URL">" class="btn btn-success" role="button">
223
              <span class="fa fa-check-circle"></span>
224
              <span trspan="imSure">I'm sure</span>
225
            </a>
226
            </div>
227 228 229 230 231 232 233 234
          </div>
        </div>
      </TMPL_IF>

    </TMPL_LOOP>

  </div>

235
</main>
236

237
<TMPL_IF NAME="PING">
238
<!-- Keep session alive -->
239
</TMPL_IF>
240

241
<TMPL_INCLUDE NAME="footer.tpl">