Hello!
Here is my xml:
<form script="next-prev-btn.js">
<label>Test Next-Prev btn onclick</label>
...
...
<row>
<panel>
<title>Title1</title>
...
...
<html>
<div>
<button id="pr_button" class="btn btn-primary" onclick="prevpage()">Назад</button>
<button id="nxt_button" class="btn btn-primary" style="float: right;">Далее</button>
</div>
</html>
</panel>
</row>
</form>
and this is my js:
require([
"jquery",
"splunkjs/mvc/searchmanager",
"splunkjs/mvc/simplexml/ready!"
], function(
$,
SearchManager
) {
var mysearch = new SearchManager({
id: "mysearch",
autostart: "false",
search: "| gentimes start=-1| eval time=\"06.06.2017 10:00\" | eval field4=\"$field4$\" | eval field5=\"$field5$\" | outputlookup $field1$$field2$$field3$.csv"
}, {tokens: true, tokenNamespace: "submitted"});
$("#nxt_button").on("click", function (){
mysearch.startSearch();
window.open ('localhost:8000/en-US/app/testform/test-form-next-button2','_self',false);
});
});
It works good when I use Splunk 6.3.3 but it does not work on Splunk 6.6.2
I'm get an error:
Uncaught TypeError: startSearch() is not a function
... View more