update lay vecto 512 ngam

This commit is contained in:
2021-01-06 17:38:50 +07:00
parent 3b247f9f25
commit aa811a40dd
5 changed files with 162 additions and 35 deletions

View File

@@ -16,10 +16,10 @@ $(function () {
});
btnImage();
$("#Code").select2();
getTotalFeature();
});
function _search(e) {
var location = $(e).attr("data-href");// + "?from=" + $("input[name='From']").val() + "&to=" + $("input[name='To']").val();
var location = $(e).attr("data-href"); // + "?from=" + $("input[name='From']").val() + "&to=" + $("input[name='To']").val();
location = location + "?id=" + $("input[name='IDSearch']").val();
location = location + "&name=" + $("input[name='NameSearch']").val();
location = location + "&type=" + $("select[name='TypeSearch']").val();
@@ -555,10 +555,11 @@ function syncFeatureToServer(id, fullData) {
id: id
},
success: function (data) {
if (data.status != 10000) {
error++;
console.log(error);
}
console.log(data);
// if (data.status != 10000) {
// error++;
// console.log(error);
// }
progressToServer++;
$("#progress-current").html(parseInt($("#progress-current").html()) + 1);
var percent = parseInt(progressToServer / totalsToServer * 100);
@@ -600,4 +601,19 @@ function removeFilters() {
$(".btn-select").removeClass("hidden");
$("#filter-from-server").val('').trigger('change');
checkAllSync(false);
}
function getTotalFeature() {
$.ajax({
url: $("input[name='get_total_feature_url']").val(),
type: 'POST',
success: function (data) {
console.log(data);
$("#totalPeople").html(`<b class="text-red">` + data.statistics.totalImg + `</b>/<b>` + data.statistics.total + `</b>`);
$("#total128").html(`<b class="text-red">` + data.statistics["128"] + `</b>/<b>` + data.statistics.img + `</b>`);
$("#total512").html(`<b class="text-red">` + data.statistics["512"] + `</b>/<b>` + data.statistics.img + `</b>`);
},
error: function (jqXHR, textStatus, errorThrown) {
}
});
}