Added Ajax loading icon for submit buttons

This commit is contained in:
Frederic Guillot 2016-03-05 07:56:58 -05:00
parent 9b68c3bc77
commit 0bd5328c19
79 changed files with 87 additions and 81 deletions

View File

@ -3,6 +3,7 @@ Version 1.0.27 (unreleased)
Improvements:
* Added Ajax loading icon for submit buttons
* Added support for HTTP header "X-Forwarded-Proto: https"
Security issues:

View File

@ -18,7 +18,7 @@
</div>
<div class="form-actions">
<input type="submit" value="<?= t('Next step') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Next step') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'action', 'index', array('project_id' => $project['id'])) ?>
</div>

View File

@ -70,6 +70,6 @@
<?= $this->form->select('action_name', $available_actions, $values) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Next step') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Next step') ?></button>
</div>
</form>

View File

@ -42,7 +42,7 @@
<?php endforeach ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save this action') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'action', 'index', array('project_id' => $project['id'])) ?>
</div>

View File

@ -27,7 +27,7 @@
</div>
<div class="form-inline-group">
<input type="submit" value="<?= t('Execute') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Execute') ?></button>
</div>
</form>

View File

@ -27,6 +27,6 @@
</div>
<div class="form-inline-group">
<input type="submit" value="<?= t('Execute') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Execute') ?></button>
</div>
</form>

View File

@ -31,7 +31,7 @@
</div>
<div class="form-inline-group">
<input type="submit" value="<?= t('Execute') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Execute') ?></button>
</div>
</form>

View File

@ -28,7 +28,7 @@
<?php endif ?>
<div class="form-actions">
<input type="submit" value="<?= t('Sign in') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Sign in') ?></button>
</div>
<?php if ($this->app->config('password_reset') == 1): ?>
<div class="reset-password">

View File

@ -12,7 +12,7 @@
<?= $this->task->selectAssignee($users_list, $values, array(), array('autofocus')) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'board', 'show', array('project_id' => $project['id']), false, 'close-popover') ?>
</div>

View File

@ -12,7 +12,7 @@
<?= $this->task->selectCategory($categories_list, $values, array(), array('autofocus'), true) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'board', 'show', array('project_id' => $project['id']), false, 'close-popover') ?>
</div>

View File

@ -10,7 +10,7 @@
<p class="alert"><?= t('%d task(s) in the column "%s" and the swimlane "%s" will be closed.', $nb_tasks, $column, $swimlane) ?></p>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-red">
<button type="submit" class="btn btn-red"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'board', 'show', array('project_id' => $project['id']), false, 'close-popover') ?>
</div>

View File

@ -33,7 +33,7 @@
<div class="form-help"><?= $this->url->doc(t('Write your text in Markdown'), 'syntax-guide') ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'category', 'index', array('project_id' => $project['id']), false, 'close-popover') ?>
</div>

View File

@ -40,6 +40,6 @@
<?= $this->form->text('name', $values, $errors, array('autofocus', 'required', 'maxlength="50"')) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -34,7 +34,7 @@
<div class="form-help"><?= $this->url->doc(t('Write your text in Markdown'), 'syntax-guide') ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Add this column') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'column', 'index', array('project_id' => $project['id']), false, 'close-popover') ?>
</div>

View File

@ -37,7 +37,7 @@
<div class="form-help"><?= $this->url->doc(t('Write your text in Markdown'), 'syntax-guide') ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'column', 'index', array('project_id' => $project['id']), false, 'close-popover') ?>
</div>

View File

@ -37,7 +37,7 @@
<div class="form-help"><?= $this->url->doc(t('Write your text in Markdown'), 'syntax-guide') ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?php if (! isset($skip_cancel)): ?>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>

View File

@ -29,7 +29,7 @@
<div class="form-help"><?= $this->url->doc(t('Write your text in Markdown'), 'syntax-guide') ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Update') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -33,6 +33,6 @@
<?= $this->hook->render('template:config:application', array('values' => $values, 'errors' => $errors)) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -18,6 +18,6 @@
<p class="form-help"><?= t('Frequency in second (0 to disable this feature, 10 seconds by default)') ?></p>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -28,7 +28,7 @@
</div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>
</section>

View File

@ -12,6 +12,6 @@
</div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -22,6 +22,6 @@
<?= $this->form->checkbox('cfd_include_closed_tasks', t('Include closed tasks in the cumulative flow diagram'), 1, $values['cfd_include_closed_tasks'] == 1) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -10,7 +10,7 @@
<?= $this->form->text('webhook_url', $values, $errors) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>
</section>

View File

@ -32,7 +32,7 @@
<?= $this->form->select('application_currency', $currencies, $config_values, $errors) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>
@ -49,6 +49,6 @@
<?= $this->form->text('rate', $values, $errors, array(), 'form-numeric') ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -19,6 +19,6 @@
<?= $this->form->checkbox('append', t('Append filter (instead of replacement)'), 1) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -25,7 +25,7 @@
<?= $this->form->checkbox('append', t('Append filter (instead of replacement)'), 1, $values['append'] == 1) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'customfilter', 'index', array('project_id' => $project['id']), false, 'close-popover') ?>
</div>

View File

@ -19,6 +19,6 @@
<div class="form-help"><?= t('Others formats accepted: %s and %s', date('Y-m-d'), date('Y_m_d')) ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Execute') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Execute') ?></button>
</div>
</form>

View File

@ -19,6 +19,6 @@
<div class="form-help"><?= t('Others formats accepted: %s and %s', date('Y-m-d'), date('Y_m_d')) ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Execute') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Execute') ?></button>
</div>
</form>

View File

@ -19,6 +19,6 @@
<div class="form-help"><?= t('Others formats accepted: %s and %s', date('Y-m-d'), date('Y_m_d')) ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Execute') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Execute') ?></button>
</div>
</form>

View File

@ -19,6 +19,6 @@
<div class="form-help"><?= t('Others formats accepted: %s and %s', date('Y-m-d'), date('Y_m_d')) ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Execute') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Execute') ?></button>
</div>
</form>

View File

@ -43,7 +43,7 @@
</div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue" tabindex="11"/>
<button type="submit" class="btn btn-blue" tabindex="15"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'board', 'show', array('project_id' => $values['project_id']), false, 'close-popover') ?>
</div>

View File

@ -16,7 +16,7 @@
<?= $this->form->select('user_id', $users, $values, $errors, array('required'), 'chosen-select') ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'group', 'index') ?>
</div>

View File

@ -11,7 +11,7 @@
<?= $this->form->text('name', $values, $errors, array('autofocus', 'required', 'maxlength="100"')) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'group', 'index') ?>
</div>

View File

@ -14,7 +14,7 @@
<?= $this->form->text('name', $values, $errors, array('autofocus', 'required', 'maxlength="100"')) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'group', 'index') ?>
</div>

View File

@ -13,6 +13,6 @@
<?= $this->form->text('opposite_label', $values, $errors) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -14,7 +14,7 @@
<?= $this->form->select('opposite_id', $labels, $values, $errors) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'link', 'index') ?>
</div>

View File

@ -10,7 +10,7 @@
<?= $this->form->password('confirmation', $values, $errors) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Change Password') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Change Password') ?></button>
</div>
</form>
</div>

View File

@ -11,7 +11,7 @@
<?= $this->form->text('captcha', array(), $errors, array('required')) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Change Password') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Change Password') ?></button>
</div>
</form>
</div>

View File

@ -20,7 +20,7 @@
<?= $this->form->checkbox('task', t('Tasks'), 1, false) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Duplicate') ?>" class="btn btn-red">
<button type="submit" class="btn btn-red"><?= t('Duplicate') ?></button>
<?= t('or') ?> <?= $this->url->link(t('cancel'), 'project', 'show', array('project_id' => $project['id'])) ?>
</div>
</form>

View File

@ -12,7 +12,7 @@
<?= $this->form->checkboxes('notification_types', $types, $notifications) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'project', 'show', array('project_id' => $project['id'])) ?>
</div>

View File

@ -29,7 +29,7 @@
</div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'project', 'index', array(), false, 'close-popover') ?>
</div>

View File

@ -19,7 +19,7 @@
<?= $this->form->text('end_date', $values, $errors, array('maxlength="10"'), 'form-date') ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -32,6 +32,6 @@
<div class="form-help"><?= $this->url->doc(t('Write your text in Markdown'), 'syntax-guide') ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -31,6 +31,6 @@
<?php endif ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -22,7 +22,7 @@
<?= $this->form->number('priority_end', $values, $errors) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>

View File

@ -57,7 +57,7 @@
<?= $this->form->select('role', $roles, $values, $errors) ?>
<input type="submit" value="<?= t('Add') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Add') ?></button>
</form>
</div>
<?php endif ?>
@ -119,7 +119,7 @@
<?= $this->form->select('role', $roles, $values, $errors) ?>
<input type="submit" value="<?= t('Add') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Add') ?></button>
</form>
</div>
<?php endif ?>
@ -135,7 +135,7 @@
<?= $this->form->checkbox('is_everybody_allowed', t('Allow everybody to access to this project'), 1, $project['is_everybody_allowed']) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>
<?php endif ?>

View File

@ -13,7 +13,7 @@
<?= $this->form->checkbox('another_subtask', t('Create another sub-task'), 1, isset($values['another_subtask']) && $values['another_subtask'] == 1) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -13,7 +13,7 @@
<?= $this->subtask->selectTimeSpent($values, $errors) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -13,7 +13,7 @@
<?= $this->form->text('title', array(), array(), array('required', 'placeholder="'.t('Type here to create a new sub-task').'"')) ?>
<?= $this->form->numeric('time_estimated', array(), array(), array('placeholder="'.t('Original estimate').'"')) ?>
<?= $this->form->select('user_id', $users_list, array(), array(), array('placeholder="'.t('Assignee').'"')) ?>
<input type="submit" value="<?= t('Add') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Add') ?></button>
</form>
<?php endif ?>

View File

@ -10,7 +10,7 @@
<?= $this->form->hidden('id', $subtask_inprogress) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-red">
<button type="submit" class="btn btn-red"><?= t('Save') ?></button>
<?= t('or') ?>
<a href="#" class="close-popover"><?= t('cancel') ?></a>
</div>

View File

@ -30,7 +30,7 @@
<div class="form-help"><?= $this->url->doc(t('Write your text in Markdown'), 'syntax-guide') ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'Swimlane', 'index', array('project_id' => $project['id']), false, 'close-popover') ?>
</div>

View File

@ -34,7 +34,7 @@
<div class="form-help"><?= $this->url->doc(t('Write your text in Markdown'), 'syntax-guide') ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'swimlane', 'index', array('project_id' => $project['id']), false, 'close-popover') ?>
</div>

View File

@ -11,7 +11,7 @@
<?= $this->form->checkbox('show_default_swimlane', t('Show default swimlane'), 1, $values['show_default_swimlane'] == 1) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'Swimlane', 'index', array('project_id' => $project['id']), false, 'close-popover') ?>
</div>

View File

@ -60,7 +60,7 @@
</div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue" tabindex="12"/>
<button type="submit" class="btn btn-blue" tabindex="15"><?= t('Save') ?></button>
<?= t('or') ?> <?= $this->url->link(t('cancel'), 'board', 'show', array('project_id' => $values['project_id']), false, 'close-popover') ?>
</div>
</form>

View File

@ -39,7 +39,7 @@
<p class="form-help"><?= t('Current assignee: %s', ($task['assignee_name'] ?: $task['assignee_username']) ?: e('not assigned')) ?></p>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -39,7 +39,7 @@
<p class="form-help"><?= t('Current assignee: %s', ($task['assignee_name'] ?: $task['assignee_username']) ?: e('not assigned')) ?></p>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -6,7 +6,7 @@
<?= $this->render('task_external_link/form', array('task' => $task, 'dependencies' => $dependencies, 'values' => $values, 'errors' => $errors)) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'TaskExternalLink', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -6,7 +6,7 @@
<?= $this->render('task_external_link/form', array('task' => $task, 'dependencies' => $dependencies, 'values' => $values, 'errors' => $errors)) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'TaskExternalLink', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -21,7 +21,7 @@
<?= $this->form->select('type', $types, $values) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Next') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Next') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -10,7 +10,7 @@
<input type="hidden" name="screenshot"/>
<?= $this->form->csrf() ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -16,7 +16,7 @@
<p class="form-help"><?= t('Maximum size: ') ?><?= is_integer($max_size) ? $this->text->bytes($max_size) : $max_size ?></p>
<div class="form-actions">
<input type="submit" value="<?= t('Import') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Import') ?></button>
</div>
</form>
<div class="page-header">

View File

@ -37,7 +37,7 @@
<div class="form-help"><?= $this->url->doc(t('Write your text in Markdown'), 'syntax-guide') ?></div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -28,7 +28,7 @@
</div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue" tabindex="10">
<button type="submit" class="btn btn-blue" tabindex="15"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -38,7 +38,7 @@
<?= $this->form->select('recurrence_basedate', $recurrence_basedate_list, $values, $errors) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -26,7 +26,7 @@
'autocomplete') ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?>
</div>

View File

@ -27,7 +27,7 @@
'autocomplete') ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
</div>

View File

@ -104,7 +104,7 @@
),
'autocomplete') ?>
<input type="submit" value="<?= t('Add') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Add') ?></button>
</form>
<?php endif ?>

View File

@ -5,6 +5,6 @@
<?= $this->form->text('code', array(), array(), array('placeholder="123456"', 'autofocus'), 'form-numeric') ?>
<div class="form-actions">
<input type="submit" value="<?= t('Check my code') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Check my code') ?></button>
</div>
</form>

View File

@ -7,9 +7,9 @@
<p><?= t('Two-Factor Provider: ') ?><strong><?= $this->text->e($provider) ?></strong></p>
<div class="form-actions">
<?php if ($user['twofactor_activated'] == 1): ?>
<input type="submit" value="<?= t('Disable two-factor authentication') ?>" class="btn btn-red"/>
<button type="submit" class="btn btn-red"><?= t('Disable two-factor authentication') ?></button>
<?php else: ?>
<input type="submit" value="<?= t('Enable two-factor authentication') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Enable two-factor authentication') ?></button>
<?php endif ?>
</div>
</form>

View File

@ -26,6 +26,6 @@
<?= $this->form->text('code', array(), array(), array('placeholder="123456"', 'autofocus'), 'form-numeric') ?>
<div class="form-actions">
<input type="submit" value="<?= t('Check my code') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Check my code') ?></button>
</div>
</form>

View File

@ -14,7 +14,7 @@
<?= $this->form->checkbox('disable_login_form', t('Disallow login form'), 1, isset($values['disable_login_form']) && $values['disable_login_form'] == 1) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'user', 'show', array('user_id' => $user['id'])) ?>
</div>

View File

@ -44,7 +44,7 @@
</div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'user', 'index') ?>
</div>

View File

@ -41,7 +41,7 @@
</div>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'user', 'index') ?>
</div>

View File

@ -28,7 +28,7 @@
<?php endif ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'user', 'show', array('user_id' => $user['id'])) ?>
</div>

View File

@ -22,7 +22,7 @@
<?php endif ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'user', 'show', array('user_id' => $user['id'])) ?>
</div>

View File

@ -19,7 +19,7 @@
<?= $this->form->password('confirmation', $values, $errors) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
<?= t('or') ?>
<?= $this->url->link(t('cancel'), 'user', 'show', array('user_id' => $user['id'])) ?>
</div>

View File

@ -26,7 +26,7 @@
<p class="form-help"><?= t('Maximum size: ') ?><?= is_integer($max_size) ? $this->text->bytes($max_size) : $max_size ?></p>
<div class="form-actions">
<input type="submit" value="<?= t('Import') ?>" class="btn btn-blue">
<button type="submit" class="btn btn-blue"><?= t('Import') ?></button>
</div>
</form>
<div class="page-header">

File diff suppressed because one or more lines are too long

View File

@ -69,6 +69,11 @@ Popover.prototype.afterOpen = function() {
data: popoverForm.serialize(),
success: function(data, textStatus, request) {
self.afterSubmit(data, request, self);
},
beforeSend: function() {
var button = $('.popover-form button[type="submit"]');
button.html('<i class="fa fa-spinner fa-pulse"></i> ' + button.html());
button.attr("disabled", true);
}
});
});