Skip to content

Commit

Permalink
removed reason col
Browse files Browse the repository at this point in the history
  • Loading branch information
emshahh committed Jun 7, 2024
1 parent 60abaac commit 2485ffc
Showing 1 changed file with 29 additions and 16 deletions.
45 changes: 29 additions & 16 deletions sde_indexing_helper/static/js/candidate_url_list.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,14 @@ function modalContents(tableName) {

if (checkboxCount > 0 && tableName === uniqueId) {
$modal = $("#hideShowColumnsModal").modal({
backdrop: 'static',
backdrop: "static",
keyboard: true,
});
return;
}

$modal = $("#hideShowColumnsModal").modal({
backdrop: 'static',
backdrop: "static",
keyboard: true,
});
var table = $(tableName).DataTable();
Expand Down Expand Up @@ -101,13 +101,16 @@ function initializeDataTable() {
colReorder: true,
stateSave: true,
layout: {
bottomEnd: 'inputPaging',
bottomEnd: "inputPaging",
topEnd: null,
topStart: {
info:true,
info: true,
pageLength: {
menu: [[25, 50, 100, 500],["Show 25", "Show 50", "Show 100", "Show 500"]]
},
menu: [
[25, 50, 100, 500],
["Show 25", "Show 50", "Show 100", "Show 500"],
],
},
buttons: [
"spacer",
"csv",
Expand All @@ -120,8 +123,8 @@ function initializeDataTable() {
},
},
],
}
},
},
},
serverSide: true,
orderCellsTop: true,
pagingType: "input",
Expand Down Expand Up @@ -166,9 +169,9 @@ function initializeDataTable() {
let alteredLines = [];
lines.forEach((line) => {
let newLine = "";
newLine = line.replace("open_in_new","");
newLine = line.replace("open_in_new", "");
alteredLines.push(newLine);
})
});
return alteredLines.join("\n") + appliedFiltersInfo;
},
},
Expand Down Expand Up @@ -262,7 +265,10 @@ function initializeDataTable() {
],
createdRow: function (row, data, dataIndex) {
if (data["excluded"]) {
$(row).attr("style", "background-color: rgba(255, 61, 87, 0.36) !important");
$(row).attr(
"style",
"background-color: rgba(255, 61, 87, 0.36) !important"
);
}
},
});
Expand Down Expand Up @@ -343,12 +349,17 @@ function initializeDataTable() {
class: "text-center whiteText",
sortable: true,
},
{ data: "reason", class: "text-center whiteText", sortable: false },
{
data: "reason",
class: "text-center whiteText",
sortable: false,
visible: false,
},
{
data: "candidate_urls_count",
class: "text-center whiteText",
sortable: true,
},
},
{
data: null,
sortable: false,
Expand Down Expand Up @@ -792,7 +803,7 @@ function handleHideorShowKeypress() {
$("#hideShowColumnsModal").modal("hide");
}
//Confirm modal selections via enter
if(event.key == "Enter" && $("#hideShowColumnsModal").is(":visible")) {
if (event.key == "Enter" && $("#hideShowColumnsModal").is(":visible")) {
var table = $(uniqueId).DataTable();
$("[id^='checkbox_']").each(function () {
var checkboxValue = $(this).val();
Expand All @@ -804,7 +815,7 @@ function handleHideorShowKeypress() {
$("#hideShowColumnsModal").modal("hide");
}
});

$("body").on("click", ".modal-backdrop", function () {
$("#hideShowColumnsModal").modal("hide");
});
Expand All @@ -827,7 +838,9 @@ function handleHideorShowSubmitButton() {

function handleDocumentTypeSelect() {
$("body").on("click", ".document_type_select", function () {
$match_pattern = $(this).parents(".document_type_dropdown").data("match-pattern");
$match_pattern = $(this)
.parents(".document_type_dropdown")
.data("match-pattern");
postDocumentTypePatterns(
$match_pattern,
(match_pattern_type = 1),
Expand Down

0 comments on commit 2485ffc

Please sign in to comment.