Merge pull request #1344 from agilmore/incident-template-fix

Ensure incident field names are the same everywhere
This commit is contained in:
James Brooks
2016-01-18 14:47:54 +00:00

View File

@@ -252,8 +252,8 @@ $(function() {
url: '/dashboard/api/incidents/templates',
success: function(tpl) {
var $form = $('form[role=form]');
$form.find('input[name=incident\\[name\\]]').val(tpl.name);
$form.find('textarea[name=incident\\[message\\]]').val(tpl.template);
$form.find('input[name=name]').val(tpl.name);
$form.find('textarea[name=message]').val(tpl.template);
},
error: function() {
(new Cachet.Notifier()).notify('There was an error finding that template.');