{# /*************************************************************************** File name: profile.html Site: travellersoftware.com Copyright 2024 Michael J. Miller, All rights reserved Purpose: user level account management - admin has a different system Requires: user - logged in account record old_password - existing password, only present when there's an error or refresh errors - optional, errors for each field Revision History: Date Version Details -------- ------ ------------------------------------------------- 4/12/24 3.0a created 9/5/26 4.0b1 Added verify email button to profile when email hasn't been profiled ****************************************************************************/ #} {% include "password-change.html.twig" %} {#

Create Account

#}
{% set verified = user.email_verified|default(0) %} {% set readonly = DEMO_MODE ? (role == 'webmaster' ? '' : (user is defined ? 'readonly' : '')) : '' %} {% if user is defined %}

Edit Profile

{% if errors is defined %}

Changes were not saved due to invalid data. Please correct the errors and try again.

{% endif %} {% else %}

Create Account

{% if errors is defined %}

Account was not created due to invalid data. Please correct errors.

{% endif %} {% endif %} {% if user is not defined or not verified %} {% if errors is defined %} {{ errors.email ?? '' }} {% endif %} {% else %} {% if verified %}
{{ user.email|default }} {% if verified %} verified {% endif %}
{% else %} {% if errors is defined %} {{ errors.email ?? '' }} {% endif %}
Your email must be verified before you can {{ PROJECT == 'travsoft'? ' create a website' : ' book a reservation' }}. An email was sent to you with verification instructions when you registered with us. If you can't find it or it has expired, click this button and we'll send you another email. Once your email has been verified you cannot change it.
{% endif %} {% endif %} {% if user is not defined %}
{{ errors.password is defined ? errors.password|raw : '' }}
{{ errors.confirm is defined ? errors.confirm|raw : '' }}
{% endif %} {% if errors is defined %} {{ errors.name_first??'' }} {% endif %} {% if errors is defined %} {{ errors.name_last??'' }} {% endif %} {% if errors is defined %} {{ errors.phone ?? '' }} {% endif %} {% set country_code = user.country_code|default('US') %} {% include 'includes/country-menu.html.twig' %}
*required
{# {% if user is defined and not DEMO_MODE %}#} {% if user is defined %} {% if not user.email_verified %}

Your email must be verified before you can {{ PROJECT == 'travsoft' ? ' create a website' : ' book a reservation' }}. We sent you an email with instructions for verifying your email when you registered. If you need another email, click on 'Verify Email'.

{% endif %} {% endif %}