Subversion Repositories SmartDukaan

Rev

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

Rev 32283 Rev 32295
Line 42... Line 42...
42
								console.log(response);
42
								console.log(response);
43
								var documentId = response.response.document_id;
43
								var documentId = response.response.document_id;
44
								console.log("documentId : "
44
								console.log("documentId : "
45
									+ documentId);
45
									+ documentId);
46
								$("#invoicehidden").val(documentId);
46
								$("#invoicehidden").val(documentId);
-
 
47
								var invoiceDoc = $("#invoicehidden").val();
-
 
48
 
-
 
49
 
-
 
50
								console.log(invoiceDoc)
-
 
51
 
47
							});
52
							});
48
 
53
 
49
					}
54
					}
50
				} else {
55
				} else {
51
					// Do nothing!
56
					// Do nothing!
Line 130... Line 135...
130
		newReceiveInvoice['supplierId'] = supplierId
135
		newReceiveInvoice['supplierId'] = supplierId
131
		newReceiveInvoice['totalValue'] = totalValue
136
		newReceiveInvoice['totalValue'] = totalValue
132
		newReceiveInvoice['invoiceNumber'] = invoiceNumber
137
		newReceiveInvoice['invoiceNumber'] = invoiceNumber
133
		newReceiveInvoice['invoiceDoc'] = invoiceDoc
138
		newReceiveInvoice['invoiceDoc'] = invoiceDoc
134
 
139
 
-
 
140
		console.log()
-
 
141
 
135
		if (confirm("Are you sure you want to add new Invoice") == true) {
142
		if (confirm("Are you sure you want to add new Invoice") == true) {
136
 
143
 
137
			doPostAjaxRequestWithJsonHandler(context
144
			doPostAjaxRequestWithJsonHandler(context
138
				+ "/newReceiveInvoice", JSON
145
				+ "/newReceiveInvoice", JSON
139
					.stringify(newReceiveInvoice), function(response) {
146
					.stringify(newReceiveInvoice), function(response) {
Line 895... Line 902...
895
		doPostAjaxRequestWithJsonHandler(context
902
		doPostAjaxRequestWithJsonHandler(context
896
			+ "/editPurchaseOrder", JSON
903
			+ "/editPurchaseOrder", JSON
897
				.stringify(editpurchaseOrder), function(response) {
904
				.stringify(editpurchaseOrder), function(response) {
898
					if (response == 'true') {
905
					if (response == 'true') {
899
						alert("successfully created");
906
						alert("successfully created");
-
 
907
						$('#warehouseEditPurchaseContainer').modal('hide');
-
 
908
						$('.modal-backdrop').remove();
-
 
909
 
900
						loadOpenPurchase("main-content")
910
						loadOpenPurchase("main-content")
901
					}
911
					}
902
				});
912
				});
903
	}
913
	}
904
 
914