Subversion Repositories SmartDukaan

Rev

Rev 30604 | Rev 34098 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 30604 Rev 33888
Line 835... Line 835...
835
		doGetAjaxRequestHandler(url, function(response) {
835
		doGetAjaxRequestHandler(url, function(response) {
836
			$('#main-content').html(response);
836
			$('#main-content').html(response);
837
		});
837
		});
838
	}
838
	}
839
}
839
}
-
 
840
 
-
 
841
 
-
 
842
$(document).on('click', '.model-sku-update', function () {
-
 
843
	doGetAjaxRequestHandler(context + "/getCategorisedCatalog",
-
 
844
		function (response) {
-
 
845
			$('#main-content').html(response);
-
 
846
		});
-
 
847
 
-
 
848
});
-
 
849
 
-
 
850
$(document).on('click', '.fetch-cataogrised-catalog', function () {
-
 
851
	getBrnadWiseCatalogMovement();
-
 
852
});
-
 
853
 
-
 
854
$(document).on('click', '.catlalog-movement-history-mk', function () {
-
 
855
	let catalogId = $(this).data('catalogid');
-
 
856
	doGetAjaxRequestHandler(context + "/getCatalogMovementHistory?catalogId=" + catalogId,
-
 
857
		function (response) {
-
 
858
			$('#modal-movement-history').html(response);
-
 
859
		});
-
 
860
 
-
 
861
});
-
 
862
 
-
 
863
 
-
 
864
$(document).on('click', '.create-update-button', function () {
-
 
865
	let brand = $("#catalog-brand").val();
-
 
866
	let catalogId = $('#createUpdateStatus .model-id').val();
-
 
867
	let status = $('#createUpdateStatus .catalog-status').val();
-
 
868
	let startDate = $('#createUpdateStatus .start-date').val();
-
 
869
	let endDate = $('#createUpdateStatus .end-date').val();
-
 
870
	doGetAjaxRequestHandler(context + "/createUpdateCatalogMovement?catalogId=" + catalogId + "&status=" + status + "&startDate=" + startDate + "&endDate=" + endDate + "&brand=" + brand,
-
 
871
		function (response) {
-
 
872
			if (response) {
-
 
873
				alert("Successfully added catalog movement status");
-
 
874
				$('#createUpdateStatus').modal('hide');
-
 
875
				getBrnadWiseCatalogMovement();
-
 
876
			}
-
 
877
 
-
 
878
		});
-
 
879
 
-
 
880
});
-
 
881
 
-
 
882
$(document).on('click', '.update-catalog-status-mk', function () {
-
 
883
	let catalogId = $(this).data('catalogid');
-
 
884
 
-
 
885
	$('#createUpdateStatus select[name="modelNumber"]').val(catalogId);
-
 
886
 
-
 
887
	$('#createUpdateStatus').modal('show');
-
 
888
});
-
 
889
 
-
 
890
function getBrnadWiseCatalogMovement() {
-
 
891
	let brand = $("#catalog-brand").val();
-
 
892
	doGetAjaxRequestHandler(context + "/getCatalogMovementByBrand?brand=" + brand,
-
 
893
		function (response) {
-
 
894
			$('#catagorised-catalog-list-mk').html(response);
-
 
895
		});
-
 
896
}
-
 
897