{% extends 'base.html.twig' %} {% set titleName = "Converty Configuration" %} {% block title %} POWER DATA | {{titleName}} {% endblock %} {% block page %}{{titleName}}{% endblock %} {% block breadcrumb %} {% if titleName != "Home" %} {{titleName}} {% endif %} {% endblock %} {% block content %} {% for message in app.flashes('success') %} {{ message }} × {% endfor %} {% for message in app.flashes('error') %} {{ message }} × {% endfor %} {{ form_start(form) }} Configuration for API Client Id {{ form_widget(form.clientId) }} Client Secret {{ form_widget(form.clientSecret) }} Authorization Code {{ form_widget(form.authorizationCode) }} Refresh Token {{ form_widget(form.refreshToken) }} Token {{ form_widget(form.token) }} Max Orders Per Page {{ form_widget(form.maxOrdersPerPage) }} Filter Status {{ form_widget(form.filterStatus) }} Status Out {{ form_widget(form.statusOut) }} {{ form_end(form) }} {% if converty.expiresAt is not null %} {% set issuedAt = "now"|date('U') %} {# current timestamp in seconds #} {% set expiresIn = converty.expiresAt %} {% set expiresAt = issuedAt + expiresIn %} {% set remainingDays = ((expiresAt - issuedAt) / 86400) | round(0, 'floor') %} Token expires on: {{ expiresAt|date('Y-m-d') }} You have {{ remainingDays }} day{{ remainingDays > 1 ? 's' : '' }} left. {% else %} No expiration date available. {% endif %} Update Access Tokens {% if app.request.scheme ~ '://' ~ app.request.host == 'http://walid.jumia' %} Update Local Data {% endif %} Update ALL Tokens {% endblock %} {% block script %} {% endblock %}
No expiration date available.