Code cleanup.

This commit is contained in:
James Cole
2016-04-10 17:51:51 +02:00
parent ab523b6102
commit 32eeb3424d
99 changed files with 476 additions and 120 deletions

View File

@@ -0,0 +1,40 @@
/* global $, addNewTrigger, addNewAction, actionCount, triggerCount */
/*
* edit.js
* Copyright (C) 2016 thegrumpydictator@gmail.com
*
* This software may be modified and distributed under the terms
* of the MIT license. See the LICENSE file for details.
*/
// make a line.
$(function () {
"use strict";
console.log("create");
if (triggerCount === 0) {
addNewTrigger();
}
if (actionCount === 0) {
addNewAction();
}
$('.add_rule_trigger').click(function () {
addNewTrigger();
return false;
});
$('.add_rule_action').click(function () {
addNewAction();
return false;
});
$('.test_rule_triggers').click(function () {
testRuleTriggers();
return false;
});
});