@@ -200,7 +200,6 @@ <h3 class="box-title"> <i class="fa fa-cubes"></i> Artifacts </h3>
200
200
201
201
202
202
203
-
204
203
<!-- ===================== Records details ===================== -->
205
204
206
205
< div id ="record_details_block " class ="col-md-4 ">
@@ -282,8 +281,6 @@ <h3 class="box-title"><i class="fa fa-cubes"></i> Record Details</h3>
282
281
< script src ="../../static/dist/air-datepicker/dist/js/i18n/datepicker.en.js "> </ script >
283
282
284
283
285
-
286
-
287
284
<!-- This will take the AdminLTE input style and use it with the tags input style -->
288
285
< style type ="text/css ">
289
286
/* START ====== tagsinput */
@@ -500,7 +497,7 @@ <h3 class="box-title"><i class="fa fa-cubes"></i> Record Details</h3>
500
497
501
498
// ====================================== Variables
502
499
503
- var clicked_id_record ; // store the records clicked on the table
500
+ var clicked_id_record = 0 ; // store the records clicked on the table
504
501
505
502
var rules = ( { { rules | tojson | safe} } ) // get list of all rules
506
503
var toast = $ . toast ; // toast object
@@ -1269,6 +1266,11 @@ <h3 class="box-title"><i class="fa fa-cubes"></i> Record Details</h3>
1269
1266
1270
1267
1271
1268
1269
+ $ ( '#' + clicked_id_record ) . addClass ( 'table_events_clicked_tr disabled' ) ;
1270
+ $ ( '#' + clicked_id_record ) . css ( 'background-color' , '#636777' ) ;
1271
+
1272
+ // change records clicked status to clicked
1273
+ is_record_tr_clicked = true
1272
1274
1273
1275
}
1274
1276
@@ -1422,18 +1424,9 @@ <h3 class="box-title"><i class="fa fa-cubes"></i> Record Details</h3>
1422
1424
// build records table
1423
1425
rebuild_records ( ajax_records ) ;
1424
1426
1425
- // build data type drop-down list
1426
- //console.log(r)
1427
- /*
1428
- var list = ""
1429
- if(r['res_total'] != 0){
1430
- var aggs = r['aggs']
1431
- for(var i = 0 ; i <aggs.length ; i++)
1432
- list += '<li class="clickable"><a id="data_type:'+aggs[i]['key']+'" class="clickable add_to_search_query">'+aggs[i]['key']+' <span class="badge bg-red">'+aggs[i]['doc_count']+'</span></a></li>'
1433
- }
1434
- $('#artifacts_list').html(list);
1435
- $('.artifacts_list_button').dropdown()
1436
- */
1427
+
1428
+
1429
+
1437
1430
if ( is_record_tr_clicked ) {
1438
1431
// click the first raw in the table
1439
1432
$ ( "#table_events tr#" + wanted_record . toString ( ) ) . click ( )
@@ -2047,9 +2040,6 @@ <h3 class="box-title"><i class="fa fa-cubes"></i> Record Details</h3>
2047
2040
2048
2041
2049
2042
2050
-
2051
-
2052
-
2053
2043
// if save as rule button clicked, add the rule to dmango
2054
2044
$ ( document ) . on ( 'click' , '.sample_search_save_as_rule' , function ( ) {
2055
2045
var query_search_content = $ ( '#sample_query_search h5 #sample_query_search_content' ) . text ( ) . trim ( )
@@ -2712,6 +2702,8 @@ <h3 class="box-title"><i class="fa fa-cubes"></i> Record Details</h3>
2712
2702
$ ( '#record_details_block' ) . slideUp ( 'fast' , function ( ) {
2713
2703
$ ( '#content_table' ) . removeClass ( 'col-md-8' ) ;
2714
2704
} ) ;
2705
+
2706
+
2715
2707
} )
2716
2708
2717
2709
@@ -2888,19 +2880,8 @@ <h3 class="box-title"><i class="fa fa-cubes"></i> Record Details</h3>
2888
2880
handle_query_param ( search )
2889
2881
} )
2890
2882
2891
- $ ( document ) . click ( function ( e ) {
2892
- //For descendants of menu_content being clicked, remove this check if you do not want to put constraint on descendants.
2893
- if ( $ ( e . target ) . closest ( '#table_events' ) . length ) {
2894
- return ;
2895
- } else {
2896
- $ ( '#' + clicked_id_record ) . removeClass ( 'table_events_clicked_tr disabled' ) ;
2897
- $ ( '#' + clicked_id_record ) . css ( 'background-color' , '' ) ;
2898
2883
2899
- clicked_id_record = null
2900
- is_record_tr_clicked = false
2901
- }
2902
-
2903
- } )
2884
+
2904
2885
2905
2886
2906
2887
// enable the top-down press button
0 commit comments