mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-28 16:24:54 +02:00
wip alert correlation
This commit is contained in:
parent
17e7710f45
commit
0f2b8a55a5
@ -67,7 +67,7 @@ function setBlockState(st) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function getBlockOrder() {
|
function getBlockOrder() {
|
||||||
return $("#block-order").val();
|
return parseInt($("#block-order").val());
|
||||||
}
|
}
|
||||||
|
|
||||||
function increaseBlockOrder(order) {
|
function increaseBlockOrder(order) {
|
||||||
@ -130,7 +130,6 @@ function gramaticRules(content) {
|
|||||||
// Can add a block start after a nexus.
|
// Can add a block start after a nexus.
|
||||||
addStack(stack, item);
|
addStack(stack, item);
|
||||||
setBlockState("0");
|
setBlockState("0");
|
||||||
increaseBlockOrder();
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -183,15 +182,17 @@ function gramaticRules(content) {
|
|||||||
if (latest.type == "variables" && getBlockState() == "0") {
|
if (latest.type == "variables" && getBlockState() == "0") {
|
||||||
// After a variable and at the end of a block (rule).
|
// After a variable and at the end of a block (rule).
|
||||||
// Could be anything.
|
// Could be anything.
|
||||||
addStack(stack, item);
|
|
||||||
increaseBlockOrder();
|
increaseBlockOrder();
|
||||||
|
item.order = item.order + 1;
|
||||||
|
addStack(stack, item);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (latest.id == "block-end" && getBlockState() == "0") {
|
if (latest.id == "block-end" && getBlockState() == "0") {
|
||||||
// After a block-end could be anything.
|
// After a block-end could be anything.
|
||||||
addStack(stack, item);
|
|
||||||
increaseBlockOrder();
|
increaseBlockOrder();
|
||||||
|
item.order += 1;
|
||||||
|
addStack(stack, item);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user