~eventum-developers/eventum/trunk

« back to all changes in this revision

Viewing changes to templates/add_phone_entry.tpl.html

  • Committer: Elan Ruusamäe
  • Date: 2015-04-03 17:16:08 UTC
  • Revision ID: glen@delfi.ee-20150403171608-u41tcmt49uayv0g4
discard {literal} from templates

it is rarely needed in Smarty3

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
    </center>
30
30
    {/if}
31
31
{else}
32
 
{literal}
33
32
<script type="text/javascript">
34
33
<!--
35
34
function validatePhoneSupportForm(f)
36
35
{
37
36
    if (!Validation.isValidDate('date')) {
38
 
        alert('{/literal}{t escape=js}Please select a valid date for when the phone call took place.{/t}{literal}');
 
37
        alert('{t escape=js}Please select a valid date for when the phone call took place.{/t}');
39
38
        return false;
40
39
    }
41
40
    if ((Validation.isFieldWhitespace('call_length')) || (!Validation.isNumberOnly(Eventum.getField('call_length').val()))) {
42
41
        Validation.selectField('call_length');
43
 
        alert('{/literal}{t escape=js}Please enter integers (or floating point numbers) on the time spent field.{/t}{literal}');
 
42
        alert('{t escape=js}Please enter integers (or floating point numbers) on the time spent field.{/t}');
44
43
        return false;
45
44
    }
46
45
    if (Validation.isFieldWhitespace('description')) {
47
46
        Validation.selectField('description');
48
 
        alert('{/literal}{t escape=js}Please enter the description for this new phone support entry.{/t}{literal}');
 
47
        alert('{t escape=js}Please enter the description for this new phone support entry.{/t}');
49
48
        return false;
50
49
    }
51
50
    if (Eventum.getField('phone_category').val() == -1) {
52
51
        Validation.selectField('phone_category');
53
 
        alert('{/literal}{t escape=js}Please choose the category for this new phone support entry.{/t}{literal}');
 
52
        alert('{t escape=js}Please choose the category for this new phone support entry.{/t}');
54
53
        return false;
55
54
    }
56
55
    return true;
60
59
});
61
60
//-->
62
61
</script>
63
 
{/literal}
 
62
 
64
63
      <form name="add_phone_form" onSubmit="return validatePhoneSupportForm(this);" method="post">
65
64
          <input type="hidden" name="cat" value="add_phone">
66
65
          <input type="hidden" name="issue_id" value="{$issue_id}">