262 lines
13 KiB
Twig
262 lines
13 KiB
Twig
<div>
|
|
<h2 class="title">{% if USER.id %}{{ dt.gM("Edit user profile") }}{% else %}{{ dt.gM("Add new user") }}{% endif %}
|
|
{# TITLE INFO #}
|
|
<ul class="dx record-info">
|
|
{% if dt.chkP('SYS_SHOW_TABLE_IDS') %}<li>{{ dt.gM("ID") }}: <span>{% if USER.id %}{{USER.id}}{% else %}-{% endif %}</span></li>{% endif %}
|
|
<li>{{ dt.gM("Created") }}: <span>{% if USER.user_created %}{{USER.user_created}}{% else %}-{% endif %}</span></li>
|
|
<li>{{ dt.gM("Modified") }}: <span>{% if USER.user_modified %}{{USER.user_modified}}{% else %}-{% endif %}</span></li>
|
|
<li>{{ dt.gM("Last login") }}: <span>{% if USER.user_last_login %}{{USER.user_last_login}}{% else %}-{% endif %}</span></li>
|
|
<li>{{ dt.gM("Last IP") }}: <span>{% if USER.user_last_ip %}{{USER.user_last_ip}}{% else %}-{% endif %}</span></li>
|
|
<li>{{ dt.gM("Last location") }}: <span>{% if USER.user_last_location_url %}{{USER.user_last_location_url}}{% else %}-{% endif %}</span></li>
|
|
</ul>
|
|
<input type="hidden" value="{% if USER.id %}{{USER.id}}{% endif %}" id="id" data-validator="id" />
|
|
</h2>
|
|
|
|
{# BASE DATA #}
|
|
<ul id="pbase" class="dx col2 sbox p20">
|
|
<li>
|
|
<label for="user_name">{{ dt.gM("User name") }}:</label>
|
|
<div class="validate">
|
|
<input id="user_name" data-validator="user_name" type="text" class="normal" value="{% if USER.user_name %}{{USER.user_name}}{% endif %}"/>
|
|
</div>
|
|
</li><li>
|
|
<label for="user_surname">{{ dt.gM("User surname") }}:</label>
|
|
<div class="validate">
|
|
<input id="user_surname" data-validator="user_surname" type="text" class="normal" value="{% if USER.user_surname %}{{USER.user_surname}}{% endif %}"/>
|
|
</div>
|
|
</li><li>
|
|
<label for="user_login">{{ dt.gM("Login name") }}:</label>
|
|
<div class="validate">
|
|
<input id="user_login" data-validator="user_login" type="text" class="normal" value="{% if USER.user_login %}{{USER.user_login}}{% endif %}"/>
|
|
</div>
|
|
</li><li>
|
|
<label for="user_email">{{ dt.gM("Email") }}:</label>
|
|
<div class="validate">
|
|
<input id="user_email" data-validator="user_email" type="text" class="long" value="{% if USER.user_email %}{{USER.user_email}}{% endif %}"/>
|
|
</div>
|
|
</li><li>
|
|
<label for="user_lang">{{ dt.gM("CMS Language") }}:</label>
|
|
<div class="validate normal">
|
|
<select id="user_lang" data-validator="user_lang" class="normal chz">
|
|
{% if LANG and LANG|length > 0 %}
|
|
{% for lang in LANG %}
|
|
<option value="{{lang.id}}" {% if USER.user_lang_id and lang.id == USER.user_lang_id %} selected="" {% endif %}>{{lang.lang_title}}</option>
|
|
{% endfor %}
|
|
{% endif %}
|
|
</select>
|
|
</div>
|
|
</li>
|
|
</ul>
|
|
|
|
{# 2FA #}
|
|
<div id="p2fa" class="sbox noskip show{% if USER.user_2fa_secret_enabled %} enabled{% endif %}">
|
|
<h3><a>{{ dt.gM("2FA Security") }}</a></h3>
|
|
<div class="inner-cnt" style="display: none;">
|
|
<ul class="dx sbox block">
|
|
<li class="a2fa block" style="width: 100%;">
|
|
<p>{{ dt.gM("Install the Google Authenticator application on your device for <a target='_blank' href='https://itunes.apple.com/app/google-authenticator/id388497605'>iOS</a> or <a target='_blank' href='https://play.google.com/store/apps/details?id=com.google.android.apps.authenticator2'>Android</a>. Scan barcode with Google Authenticator, if your device has a camera. If your device has no camera, enter account and key manually.")|raw }}</p>
|
|
<p class="box">{{ dt.gM("Two Factor Authentication for Login") }}{#<a id="act_2fa" class="blue-btn">{{ dt.gM("Activate") }}</a><a id="dis_2fa" class="red-btn">{{ dt.gM("Deactivate") }}</a>#}<b class="enb">{{ dt.gM("Option Enabled") }}</b><b class="dsb">{{ dt.gM("Option Disabled") }}</b></p>
|
|
</li><li class="dummy clear"></li>
|
|
</ul>
|
|
<div class="clear"></div>
|
|
</div>
|
|
</div>
|
|
|
|
{# SETTINGS DATA CHECKBOXES #}
|
|
<div id="psettings" class="sbox noskip hide oh">
|
|
<h3><a>{{ dt.gM("User settings") }}</a></h3>
|
|
<div>
|
|
<ul class="dx pblocks">
|
|
<li>
|
|
<input id="user_blocked" data-validator="user_blocked" type="hidden" class="chk-value" value="{% if USER.user_blocked %}1{% endif %}"/>
|
|
<label>{{ dt.gM("User blocked") }}:</label>
|
|
<p>{{ dt.gM("Indicates whether user has acces to system or not") }}</p>
|
|
</li>
|
|
<li>
|
|
<input id="user_2fa_reset" name="user_2fa_reset" type="hidden" class="chk-value" value=""/>
|
|
<label>{{ dt.gM("Reset 2FA") }}:</label>
|
|
<p>{{ dt.gM("Drop user linked 2fa") }}</p>
|
|
</li>
|
|
{% if CFG and CFG|length > 0 %}
|
|
{% for k,chk in CFG %}
|
|
<li>
|
|
<input id="{{k}}" data-validator="{{k}}" type="hidden" class="chk-value" value="{% if chk %}1{% endif %}"/>
|
|
<label>{{ dt.gM(k) }}:</label>
|
|
<p>{{ dt.gM(k ~ "_description paragraph...") }}</p>
|
|
</li>
|
|
{% endfor %}
|
|
{% endif %}
|
|
{% if TPASSWD %}
|
|
<li>
|
|
<input id="user_passgen" data-validator="user_passgen" type="hidden" class="chk-value" value=""/>
|
|
<label>{{ dt.gM("Auto password gen") }}:</label>
|
|
<p>{{ dt.gM("Generates new password for change") }}</p>
|
|
</li>
|
|
{% endif %}
|
|
<li>
|
|
<input id="user_pass_change" data-validator="user_pass_change" type="hidden" class="chk-value" value="{% if USER.user_fchange %}1{% endif %}"/>
|
|
<label>{{ dt.gM("Password change") }}:</label>
|
|
<p>{{ dt.gM("Request user password change") }}</p>
|
|
</li>
|
|
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
</ul>
|
|
<div class="clear"></div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
{# PASSWORD DATA #}
|
|
<div id="ppasschange" class="sbox{% if USER.id %} show{% else %} hide{% endif %}">
|
|
<h3><a id="password">{% if USER.id %}{{ dt.gM("Change user password") }}{% else %}{{ dt.gM("User password") }}{% endif %}</a></h3>
|
|
<div {% if USER.id %}style="display:none;"{% endif %}>
|
|
<div id="auto-gen-pwd" style="display:none;">
|
|
<h4>{{ dt.gM("Auto generated user password - automatically sets password change upon first login!") }}</h4>
|
|
<b style="color: rgb(237, 123, 27);">{{ TPASSWD }}</b><div id="copy_code" class="v-text"><span><div class="errMsg black" data-base-msg="{{ dt.gM("Copy password") }}" data-ok-msg="{{ dt.gM("Copied!") }}"></div></span></div>
|
|
</div>
|
|
|
|
{#<ul class="dx col1">
|
|
<li>
|
|
<label for="user_oldpass">{{ dt.gM("Old password") }}:</label>
|
|
<div class="validate">
|
|
<input id="user_oldpass" data-validator="user_oldpass" type="password" class="normal skip" value=""/>
|
|
</div>
|
|
</li>
|
|
</ul>#}
|
|
<ul class="dx col3">
|
|
<li>
|
|
<label for="user_newpass">{{ dt.gM("New password") }}:</label>
|
|
<div class="validate">
|
|
<input id="user_newpass" data-validator="user_newpass" type="password" class="long {% if USER.id %}skip{% endif %}" value=""/>
|
|
</div>
|
|
</li>
|
|
<li>
|
|
<label for="user_newpassre">{{ dt.gM("New password again") }}:</label>
|
|
<div class="validate">
|
|
<input id="user_newpassre" data-validator="user_newpassre" type="password" class="long {% if USER.id %}skip{% endif %}" value=""/>
|
|
</div>
|
|
</li>
|
|
</ul>
|
|
<div class="clear"></div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
{# TABLE FIELD DATA #}
|
|
<div id="tablescfg" class="gbox show load">
|
|
<h3><a>{{ dt.gM("Manage table fields") }}</a></h3>
|
|
<div style="display: none;">
|
|
<div class="clearr dd-before"></div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
{# PLUGIN TABLE FIELD DATA #}
|
|
<div id="portletscfg" class="sbox show load">
|
|
<h3><a>{{ dt.gM("Manage welcome portlets") }}</a></h3>
|
|
<div style="display: none;">
|
|
<div class="clearr dd-before"></div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
{# PERMISSION VIEW DATA #}
|
|
<div id="user_groups" class="noskip sbox show oh">
|
|
<h3><a>{{ dt.gM("User permission groups") }}</a></h3>
|
|
<div style="display:none;">
|
|
<div class="pp-search">
|
|
<label for="grpp-search">{{ dt.gM("Search in groups:") }}</label>
|
|
<div>
|
|
<input type="text" data-validator="grpp-search" id="grpp-search" class="skip long" />
|
|
<a class="clf op60" style="display:none;" href="javascript:;"></a>
|
|
</div>
|
|
<span class="pp-close"></span>
|
|
</div>
|
|
<div class="ncheckbox">
|
|
{# CHECK ALL BUTTON #}
|
|
<div class="ckh_all inline">
|
|
<label>{{ dt.gM("Check all:") }}</label>
|
|
<div class="chk no-sbox-sel"><div></div></div>
|
|
</div>
|
|
<div class="only_sel inline">
|
|
<label>{{ dt.gM("Show selected:") }}</label>
|
|
<div class="chk no-sbox-sel"><div></div></div>
|
|
</div>
|
|
<br><br><br>
|
|
{% if P.groups and P.groups|length > 0 %}
|
|
<ul class="dx pblocks">
|
|
{% for pp in P.groups %}
|
|
<li>
|
|
<div id="g{{pp.id}}" data-validator="g{{pp.id}}" class="chk{% if pp.sel %} chked{% endif %}"><div></div></div>
|
|
<label for="g{{pp.id}}">{{pp.group_name}}</label>
|
|
<p>{{pp.group_description}}</p>
|
|
</li>
|
|
{% endfor %}
|
|
<li class="dummy noresults" style="display:none;">{{ dt.gM("No results found, please change the search and try again") }}</li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
</ul>
|
|
{% endif %}
|
|
<div class="clear"></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
{# PERMISSION VIEW DATA #}
|
|
<div id="user_permissions" class="noskip sbox show oh" >
|
|
<h3><a>{{ dt.gM("User permissions") }}</a></h3>
|
|
<div style="display:none;">
|
|
<div class="pp-search">
|
|
<label for="grpp-search">{{ dt.gM("Search in permissions:") }}</label>
|
|
<div>
|
|
<input type="text" data-validator="grpp-search" id="grpp-search" class="skip long" />
|
|
<a class="clf op60" style="display:none;" href="javascript:;"></a>
|
|
</div>
|
|
<span class="pp-close"></span>
|
|
</div>
|
|
<div class="ncheckbox">
|
|
{# CHECK ALL BUTTON #}
|
|
<div class="ckh_all inline">
|
|
<label>{{ dt.gM("Check all:") }}</label>
|
|
<div class="chk no-sbox-sel"><div></div></div>
|
|
</div>
|
|
<div class="only_sel inline">
|
|
<label>{{ dt.gM("Show selected:") }}</label>
|
|
<div class="chk no-sbox-sel"><div></div></div>
|
|
</div>
|
|
<br><br><br>
|
|
{% if P.permissions and P.permissions|length > 0 %}
|
|
<ul class="dx pblocks">
|
|
{% for g in P.permissions %}
|
|
{% if g and g|length > 0 %}
|
|
{% for pp in g %}
|
|
<li>
|
|
<div id="k{{pp.id}}" data-validator="k{{pp.id}}" class="chk {% if pp.sel %} chked{% endif %}"><div></div></div>
|
|
<label for="k{{pp.id}}">{{pp.p_name}}</label>
|
|
<p>{% if pp.p_description %}{{pp.p_description}}{% else %} {% endif %}</p>
|
|
</li>
|
|
{% endfor %}
|
|
{% endif %}
|
|
{% endfor %}
|
|
<li class="dummy noresults" style="display:none;">{{ dt.gM("No results found, please change the search and try again") }}</li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
<li class="dummy"></li>
|
|
</ul>
|
|
{% endif %}
|
|
</div>
|
|
<div class="clear"></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<br/> |