changes for sweetalert

This commit is contained in:
gandhimathi 2017-12-18 10:38:38 +05:30
parent 4465382a54
commit 02e4637ab6
11 changed files with 147 additions and 143 deletions

View File

@ -282,26 +282,26 @@ function Validate()
{
if($("#MaterialName").val().length < 1)
{
alert('Please Enter MaterialName');
swal('Please Enter MaterialName');
$("#MaterialName").focus();
return false;
}
if($("option:selected", $("#UOM")).val() == "")
{
alert('Please Select UOM ');
swal('Please Select UOM ');
$("#UOM").focus();
return false;
}
if($("option:selected", $("#MaterialCategory")).val() == "")
{
alert('Please Select Material Category');
swal('Please Select Material Category');
$("#MaterialCategory").focus();
return false;
}
if($("option:selected", $("#MaterialType")).val() == "")
{
alert('Please Select Material Type');
swal('Please Select Material Type');
$("#MaterialType").focus();
return false;
}

View File

@ -373,7 +373,7 @@ $("#Edit").on("shown.bs.modal", function(e) {
}
else
{
alert('Please enter all the values');
swal('Please enter all the values');
}
@ -426,7 +426,7 @@ $('.tempClickEdit').click(function(){
}
else
{
alert('Please enter all the values');
swal('Please enter all the values');
}
@ -541,7 +541,7 @@ function CountRows() {
tempText = '';
Selectedval = '';
} else {
alert("Before add please select any position.");
swal("Before add please select any position.");
}
});
@ -559,7 +559,7 @@ function CountRows() {
$("#distriList").val(tempSelect);
tempSelect = '';
} else {
alert("Before remove please select any position.");
swal("Before remove please select any position.");
}
});
@ -578,7 +578,7 @@ function CountRows() {
if(data)
{
$('#content').loader('hide');
alert(data);
swal(data);
$('#txtSelectedDepartment').val('');
$('#txtRowCount').val('');
@ -587,7 +587,7 @@ function CountRows() {
}
else
{
alert("Error");
swal("Error");
}
}
@ -603,17 +603,17 @@ function validate()
if($("#txtSelectedDepartment").val().length < 1)
{
alert('Please Select Department');
swal('Please Select Department');
return false;
}
else if($("#txtRowCount").val().length < 1)
{
alert('Please Add Budget');
swal('Please Add Budget');
return false;
}
else if($("option:selected", $("#ApprovedBy")).val() == '-1')
{
alert('Please Select Approver Names');
swal('Please Select Approver Names');
return false;
}
else

View File

@ -65,7 +65,7 @@ $(function(){
function blockKeyPress(evt)
{
var charCode = (evt.which) ? evt.which : evt.keyCode;
alert(charCode);
swal(charCode);
if(charCode == 8 || charCode == 46 )
{
@ -103,7 +103,7 @@ var PAN = $('#panno').val();
{
if (regpan.test(PAN) == false)
{
alert('Please Enter Valid PAN Number');
swal('Please Enter Valid PAN Number');
return (false);
}
else
@ -133,7 +133,7 @@ function ValidateAadhar(){
if(reg.test(aadhar)== false)
{
//alert('alskdjsakjf');
alert('Please Enter Valid Aadhar Number');
swal('Please Enter Valid Aadhar Number');
return (false);
}
else
@ -156,7 +156,7 @@ function getMobileValidation() {
var contactNumber = $('#ContactNumber').val().length;
if(contactNumber < 10)
{
alert('Please Enter valid Contact Number');
swal('Please Enter valid Contact Number');
return false;
}
else
@ -168,7 +168,7 @@ function getValidEmergencyNumber() {
var contactNumber = $('#emergencycontactnumber').val().length;
if(contactNumber < 10)
{
alert('Please Enter valid Emergency Contact Number');
swal('Please Enter valid Emergency Contact Number');
return false;
}
else
@ -180,7 +180,7 @@ function getValidReferNumber() {
var contactNumber = $('#referrercontno').val().length;
if(contactNumber > 0 && contactNumber < 10)
{
alert('Please Enter valid Refernce Contact Number');
swal('Please Enter valid Refernce Contact Number');
return false;
}
else
@ -197,7 +197,7 @@ function validateEmail() {
{
if (reg.test(email) == false)
{
alert('Please Enter Valid Personal Email Address');
swal('Please Enter Valid Personal Email Address');
return (false);
}
else
@ -207,7 +207,7 @@ function validateEmail() {
}
else
{
alert('Please Enter email id');
swal('Please Enter email id');
}
}
@ -220,7 +220,7 @@ function validatecomEmail() {
{
if (reg.test(email) == false)
{
alert('Please Enter Valid Company Email Address');
swal('Please Enter Valid Company Email Address');
return (false);
}
else
@ -230,7 +230,7 @@ function validatecomEmail() {
}
else
{
alert('Please Enter email id');
swal('Please Enter email id');
}
}
@ -244,7 +244,7 @@ function validateDriverLicense() {
{
if (reg.test(VehicleNo) == false)
{
alert('Please Enter Valid Driver License Number');
swal('Please Enter Valid Driver License Number');
return (false);
}
else
@ -339,7 +339,7 @@ function ValidatePassport()
//alert(passport);
if(regsaid.test(passport) == false)
{
alert('You have entered invalid Passport.');
swal('You have entered invalid Passport.');
return (false);
}
else
@ -377,7 +377,7 @@ function validatePF() {
{
if (regpf.test(PF) == false)
{
alert('Please Enter Valid PF Number');
swal('Please Enter Valid PF Number');
return (false);
}
else
@ -397,7 +397,7 @@ function validateESI() {
{
if (reg.test(ESI) == false)
{
alert('Please Enter Valid ESI Number');
swal('Please Enter Valid ESI Number');
return (false);
}
else
@ -846,28 +846,28 @@ function Validate()
{
if($("#FirstName").val().length < 1)
{
alert('Please Enter FirstName');
swal('Please Enter FirstName');
$("#FirstName").focus();
return false;
}
if($("#LastName").val().length < 1)
{
alert('Please Enter LastName');
swal('Please Enter LastName');
return false;
}
if($("#FatherName").val().length < 1)
{
alert('Please Enter FatherName');
swal('Please Enter FatherName');
return false;
}
if($("#DateofBirth").val().length < 1)
{
alert('Please Enter Date of Birth');
swal('Please Enter Date of Birth');
return false;
}
if ( $('#ContactNumber').val().length < 1 )
{
alert('Please Enter Contact Number');
swal('Please Enter Contact Number');
return false;
}
else if(!getMobileValidation())
@ -878,7 +878,7 @@ function Validate()
if($("#emailid").val().length < 1)
{
alert('Please Enter Personal Email ID');
swal('Please Enter Personal Email ID');
return false;
}
else if(!validateEmail())
@ -888,7 +888,7 @@ function Validate()
if($("#mail").val().length < 1)
{
alert('Please Enter Company Email ID');
swal('Please Enter Company Email ID');
return false;
}
else if(!validatecomEmail())
@ -898,42 +898,42 @@ function Validate()
if($("option:selected", $("#gender")).val() == '-1')
{
alert('Please Select Gender');
swal('Please Select Gender');
$('#gender').focus();
return false;
}
if($("option:selected", $("#MartialStatus")).val() == "-1")
{
alert('Please Select Martial Status');
swal('Please Select Martial Status');
$('#MartialStatus').focus();
return false;
}
if($("option:selected", $("#bloodgroup")).val() == "-1")
{
alert('Please Select Blood group ');
swal('Please Select Blood group ');
$("#bloodgroup").focus();
return false;
}
if($("#currentaddress").val().length < 1)
{
alert('Please Enter Current Address');
swal('Please Enter Current Address');
return false;
}
if($("#permanentaddress").val().length < 1)
{
alert('Please Enter Permanent Address');
swal('Please Enter Permanent Address');
return false;
}
if($("#emergencycontactname").val().length < 1)
{
alert('Please Enter Emergency Contact Name');
swal('Please Enter Emergency Contact Name');
return false;
}
if($("#emergencycontactnumber").val().length < 1)
{
alert('Please Enter Emergency Contact Number');
swal('Please Enter Emergency Contact Number');
return false;
}
else if(!getValidEmergencyNumber())
@ -942,19 +942,19 @@ function Validate()
if($("option:selected", $("#desigination")).val() == "-1")
{
alert('Please Select Desigination ');
swal('Please Select Desigination ');
$("#desigination").focus();
return false;
}
if($("option:selected", $("#departmentname")).val() == "-1")
{
alert('Please Select Department name');
swal('Please Select Department name');
$("#departmentname").focus();
return false;
}
if($("option:selected", $("#eduqualifaction")).val() == "-1")
{
alert('Please Select Qualification');
swal('Please Select Qualification');
$("#eduqualifaction").focus();
return false;
}
@ -996,7 +996,7 @@ function Validate()
}
else
{
alert('please edit the emailid in the edit employee screen');
swal('please edit the emailid in the edit employee screen');
window.location = 'employeedetails/employeeListing';
}
@ -1035,7 +1035,7 @@ function Validate()
}
else
{
alert('please edit the PAN number in the Edit employee screen');
swal('please edit the PAN number in the Edit employee screen');
window.location = 'employeedetails/employeeListing';
}
@ -1047,7 +1047,7 @@ function Validate()
else
{
//alert();
alert('Please enter the PAN Number');
swal('Please enter the PAN Number');
$('#panno').focus();
return false;
}
@ -1080,7 +1080,7 @@ function Validate()
}
else
{
alert('please edit the aadhar number in the edit employee screen');
swal('please edit the aadhar number in the edit employee screen');
window.location = 'employeedetails/employeeListing';
}
@ -1092,7 +1092,7 @@ function Validate()
else
{
//alert();
alert('Please enter the Aadhar Number');
swal('Please enter the Aadhar Number');
$('#aadharno').focus();
return false;
}

View File

@ -437,14 +437,14 @@ function openmodal()
{
if($("option:selected", $("#CostCenter")).val() == '-1')
{
alert('Please select the CostCenter ');
swal('Please select the CostCenter ');
$("#CostCenter").focus();
return false;
}
else if($('#Date').val() == '')
{
alert('Please Enter the Requested Date ');
swal('Please Enter the Requested Date ');
$("#Date").focus();
return false;
}
@ -462,13 +462,13 @@ function openmodal()
if ($("#MaterialCode option:selected").val() =='-1' )
{
alert('Please Select the MaterialCode ');
swal('Please Select the MaterialCode ');
return false;
}
if(document.getElementById('Quantity').value == '' )
{
alert('Please Enter the Quantity');
swal('Please Enter the Quantity');
return false;
}
@ -613,7 +613,7 @@ function validateBeforeAdd()
if ($("#CostCenter option:selected").val() =='-1' )
{
alert('Please Select the CostCenterCode ');
swal('Please Select the CostCenterCode ');
$("#CostCenter").focus();
return false;
}
@ -622,7 +622,7 @@ function validateBeforeAdd()
else if( isExceed == '1')
{
alert('You dont have available Budget Amount. You cant raise new StoreRequisition');
swal('You dont have available Budget Amount. You cant raise new StoreRequisition');
return false;
}
else
@ -665,7 +665,7 @@ else
{
if(document.getElementById('mytable').rows.length < 0)
{
alert('Please Select Line item to Store Requisition');
swal('Please Select Line item to Store Requisition');
$('#Deliverydt').focus();
return false;
}
@ -684,7 +684,7 @@ else
if(data)
{
$('#content').loader('hide');
alert(data);
swal(data);
$('#txtRowCount').val('');
$('#txtDeletedRow').val('');
@ -693,7 +693,7 @@ else
}
else
{
alert("Error");
swal("Error");
}
}
@ -708,7 +708,7 @@ function validate()
if($("option:selected", $("#CostCenter")).val() == '-1')
{
alert('Please Select CostCenter');
swal('Please Select CostCenter');
return false;
}
@ -716,12 +716,12 @@ function validate()
else if($("#txtRowCount").val().length < 1)
{
alert('Please Add Line Item');
swal('Please Add Line Item');
return false;
}
else if(isExceed == 1)
{
alert('You dont have Budget and You cant Raise New StoreRequisition');
swal('You dont have Budget and You cant Raise New StoreRequisition');
return false;
}
else

View File

@ -10,7 +10,7 @@ function validateEmail() {
{
if (reg.test(email) == false)
{
alert('Please Enter Valid Email Address');
swal('Please Enter Valid Email Address');
return (false);
}
else
@ -29,7 +29,7 @@ function alpha(e) {
function blockKeyPress(evt)
{
var charCode = (evt.which) ? evt.which : evt.keyCode;
alert(charCode);
swal(charCode);
if(charCode == 8 || charCode == 46 )
{
@ -61,7 +61,7 @@ var reg = /^([a-zA-Z]){5}([0-9]){4}([a-zA-Z]){1}?$/;
{
if (reg.test(PAN) == false)
{
alert('Please Enter Valid PAN Number');
swal('Please Enter Valid PAN Number');
return (false);
}
else
@ -71,7 +71,7 @@ var reg = /^([a-zA-Z]){5}([0-9]){4}([a-zA-Z]){1}?$/;
}
else
{
alert('Please Enter PAN Number');
swal('Please Enter PAN Number');
return (false);
}
@ -86,7 +86,7 @@ function validateUA() {
{
if (reguano.test(UA) == false)
{
alert('Please Enter Valid UA Number');
swal('Please Enter Valid UA Number');
return (false);
}
else
@ -108,7 +108,7 @@ function validateGST() {
{
if (reg.test(GST) == false)
{
alert('Please Enter Valid GST Number Format should be 12ABCDE1234A1Z1 or 12ABCDE1234A1ZA');
swal('Please Enter Valid GST Number Format should be 12ABCDE1234A1Z1 or 12ABCDE1234A1ZA');
return (false);
}
else
@ -118,7 +118,7 @@ function validateGST() {
}
else
{
alert('Please Enter GST Number');
swal('Please Enter GST Number');
return (false);
}
@ -135,7 +135,7 @@ function validateECCNumber() {
{
if (reg.test(ECC) == false)
{
alert('Please Enter Valid Excise Control Code Number');
swal('Please Enter Valid Excise Control Code Number');
return (false);
}
else
@ -175,13 +175,13 @@ function getContactNumberValidation(){
}
else{
alert('Please Enter valid Contact Number ex: 044 12345678 , 0444 1234567,04444 123456 and 9876543210');//alert('need to change:'+contactNumber);
swal('Please Enter valid Contact Number ex: 044 12345678 , 0444 1234567,04444 123456 and 9876543210');//alert('need to change:'+contactNumber);
return false;
}
}
else{
alert('please correct format of contact number');
swal('please correct format of contact number');
//alert('invalid'+contactNumber);
return false;
}
@ -214,13 +214,13 @@ function getValidAlternateNumber() {
}
else{
alert('Please Enter valid Contact Number ex: 044 12345678 , 0444 1234567,04444 123456 and 9876543210');//alert('need to change:'+contactNumber);
swal('Please Enter valid Contact Number ex: 044 12345678 , 0444 1234567,04444 123456 and 9876543210');//alert('need to change:'+contactNumber);
return false;
}
}
else{
alert('please correct format of contact number');
swal('please correct format of contact number');
//alert('invalid'+contactNumber);
return false;
}
@ -235,7 +235,7 @@ function validateEmail() {
{
if (reg.test(email) == false)
{
alert('Please Enter Valid Email Address');
swal('Please Enter Valid Email Address');
return (false);
}
else
@ -245,7 +245,7 @@ function validateEmail() {
}
else
{
alert('Please Enter email id');
swal('Please Enter email id');
}
}
@ -581,7 +581,7 @@ function Validate()
if($("#supplierName").val().length < 1)
{
alert('Please Enter Supplier Name');
swal('Please Enter Supplier Name');
$("#supplierName").focus();
return false;
}
@ -598,14 +598,14 @@ if(!getContactNumberValidation)
if($("#Address").val().length < 1)
{
alert('Please Enter Address');
swal('Please Enter Address');
$("#Address").focus();
return false;
}
if($("#TIN").val().length < 1)
{
alert('Please Enter TIN number');
swal('Please Enter TIN number');
$("#TIN").focus();
return false;
}
@ -646,7 +646,7 @@ if(!validateEmail())
}
else
{
alert('Please edit the supplier details in the Edit screen and change the supplier status to Active');
swal('Please edit the supplier details in the Edit screen and change the supplier status to Active');
window.location = 'supplier/supplierListing';
}
@ -657,7 +657,7 @@ if(!validateEmail())
}
else
{
alert('Please enter the PAN Number');
swal('Please enter the PAN Number');
$('#panno').focus();
return false;
}
@ -686,7 +686,7 @@ if(!validateEmail())
}
else
{
alert('Please edit the supplier details in the Edit screen and change the supplier status to Active');
swal('Please edit the supplier details in the Edit screen and change the supplier status to Active');
window.location = 'supplier/supplierListing';
}
@ -697,7 +697,7 @@ if(!validateEmail())
}
else
{
alert('Please enter the GST Number');
swal('Please enter the GST Number');
$('#GSTNo').focus();
return false;
}

View File

@ -25,7 +25,7 @@
<!-- Modal -->
<form>
<div class="modal-content">
<div class="modal-header" style="background-color: #3c8dbc;color:#fff;">
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
<button type="button" class="close" data-dismiss="modal">&times;</button>
<center><h4> Store Requisition Details - <span id="StReqno"></span></h4></center>
</div>

View File

@ -207,7 +207,7 @@ function validateEmail() {
{
if (reg.test(email) == false)
{
alert('Please Enter Valid Email Address');
swal('Please Enter Valid Email Address');
return (false);
}
else
@ -226,7 +226,7 @@ function validatePAN() {
{
if (regpan.test(PAN) == false)
{
alert('Please Enter Valid PAN Number');
swal('Please Enter Valid PAN Number');
return (false);
}
else
@ -245,7 +245,7 @@ var reg = /^([0-9]){2}([A-Za-z]){5}([0-9]){4}([A-Za-z]){1}([0-9]){1}([Zz]){1}([A
{
if (reg.test(GST) == false)
{
alert('Please Enter Valid GST Number Format should be 22AAAAA1111S1Z1 or 22AAAAA1111S1ZA ');
swal('Please Enter Valid GST Number Format should be 22AAAAA1111S1Z1 or 22AAAAA1111S1ZA ');
return (false);
}
else
@ -255,7 +255,7 @@ var reg = /^([0-9]){2}([A-Za-z]){5}([0-9]){4}([A-Za-z]){1}([0-9]){1}([Zz]){1}([A
}
else
{
alert('Please Enter GST Number');
swal('Please Enter GST Number');
return (false);
}
@ -301,13 +301,13 @@ function getMobileValidation(){
}
else{
alert('Please Enter valid Contact Number ex: 044 12345678 , 0444 1234567,04444 123456 and 9876543210');//alert('need to change:'+contactNumber);
swal('Please Enter valid Contact Number ex: 044 12345678 , 0444 1234567,04444 123456 and 9876543210');//alert('need to change:'+contactNumber);
return false;
}
}
else{
alert(' Please enter correct format of contact number');
swal(' Please enter correct format of contact number');
//alert('invalid'+contactNumber);
return false;
}
@ -321,7 +321,7 @@ function ValidateExno() {
{
if (regexno.test(ECC) == false)
{
alert('Please Enter Valid Excise Control Code Number');
swal('Please Enter Valid Excise Control Code Number');
return (false);
}
else
@ -355,13 +355,13 @@ function ValidateAlternateContact(){
return true;
}
else{
alert('Please Enter valid Contact Number ex: 044 12345678 , 0444 1234567,04444 123456 and 9876543210');//alert('need to change:'+contactNumber);
swal('Please Enter valid Contact Number ex: 044 12345678 , 0444 1234567,04444 123456 and 9876543210');//alert('need to change:'+contactNumber);
return false;
}
}
else{
alert('Please enter correct format of contact number');
swal('Please enter correct format of contact number');
//alert('invalid'+AlternateContactNumber);
return false;
}
@ -378,7 +378,7 @@ function ValidateUA() {
{
if (reguano.test(UA) == false)
{
alert('Please Enter Valid UA Number');
swal('Please Enter Valid UA Number');
return (false);
}
else
@ -870,7 +870,7 @@ function deletefile(filename)
if(data)
{
$('#content').loader('hide');
alert(data);
swal(data);
location.reload();
@ -878,7 +878,7 @@ function deletefile(filename)
}
else
{
alert("Error");
swal("Error");
}
}});
@ -890,13 +890,13 @@ function valid(){
if ( $("#CompanyName").val().length < 1)
{
alert('Please Enter Company Name');
swal('Please Enter Company Name');
$('#CompanyName').focus();
return false;
}
if ( $('#ContactNumber').val().length < 1 )
{
alert('Please Enter Contact Number');
swal('Please Enter Contact Number');
return false;
}
else if(!getMobileValidation())
@ -905,7 +905,7 @@ if ( $("#CompanyName").val().length < 1)
}
if ( $('#AlternateContactNumber').val().length < 1 )
{
alert('Please Enter Alternate Contact Number');
swal('Please Enter Alternate Contact Number');
return false;
}
else if(!ValidateAlternateContact())
@ -924,7 +924,7 @@ if ( $("#CompanyName").val().length < 1)
// }
if ( $('#ExiseRegistration1').val().length < 1 )
{
alert('Please Enter Excise Registration Number');
swal('Please Enter Excise Registration Number');
$('#ExiseRegistration1').focus();
return false;
}
@ -936,19 +936,19 @@ if ( $("#CompanyName").val().length < 1)
if ( $('#companywebsite').val().length < 1 )
{
alert('please Enter Company Website');
swal('please Enter Company Website');
$('#companywebsite').focus();
return false;
}
if ( $('#Address').val().length < 1 )
{
alert('please Enter Address');
swal('please Enter Address');
$('#Address').focus();
return false;
}
if($("#PAN").val().length < 1)
{
alert('Please Enter PAN ID');
swal('Please Enter PAN ID');
$("#PAN").focus();
return false;
}
@ -967,7 +967,7 @@ if ( $('#companywebsite').val().length < 1 )
}
if( $('#CollectrateAddress').val().length < 1 )
{
alert('please Enter Collectrate Address');
swal('please Enter Collectrate Address');
$('#CollectrateAddress').focus();
return false;
}
@ -1065,7 +1065,7 @@ $('.Add').click(function(){
success:function(data){
$('#content').loader('hide');
alert(data);
swal(data);
}//success function closed

View File

@ -547,7 +547,7 @@ $(function() {
else
{
$('#content').loader('hide');
alert("Error");
swal("Error");
}
}
@ -594,7 +594,7 @@ $('#CostCenter').change(function() {
else
{
$('#content').loader('hide');
alert("Error");
swal("Error");
}
}
@ -603,7 +603,7 @@ $('#CostCenter').change(function() {
}
else
{
alert('Please select the Employee details');
swal('Please select the Employee details');
return false;
}
@ -637,7 +637,7 @@ $("#UOM").val('');
}
else
{
alert('Please select the RequestType');
swal('Please select the RequestType');
return false;
}
@ -701,7 +701,7 @@ else
{
if(document.getElementById('Items').rows.length < 2)
{
alert('Please Select Line item to update the Requisition');
swal('Please Select Line item to update the Requisition');
$('#Deliverydt').focus();
return false;
}
@ -740,7 +740,7 @@ else
if(data)
{
$('#content').loader('hide');
alert(data);
swal(data);
$('#txtRowCount').val('');
$('#txtDeletedRow').val('');
@ -749,7 +749,7 @@ else
}
else
{
alert("Error");
swal("Error");
}
}
@ -763,17 +763,17 @@ function validate()
if($("option:selected", $("#RequestType")).val() == '-1')
{
alert('Please Select ReqType Names');
swal('Please Select ReqType Names');
return false;
}
else if($("option:selected", $("#EmpID")).val() == '-1')
{
alert('Please Select Reqby');
swal('Please Select Reqby');
return false;
}
else if(index < 1)
{
alert('Please Add Line Item');
swal('Please Add Line Item');
return false;
}
else
@ -851,14 +851,14 @@ function DeleteRow(rowid)
if(data)
{
$('#content').loader('hide');
alert(data);
swal(data);
}
else
{
alert("Error");
swal("Error");
}
}});
@ -872,12 +872,12 @@ $('.addClick').click(function(){
if ($("#drpMaterial option:selected").val() =='-1' )
{
alert('Please Select the MaterialCode ');
swal('Please Select the MaterialCode ');
}
if(document.getElementById('Quantity').value == '' )
{
alert('Please Enter the Quantity');
swal('Please Enter the Quantity');
}
@ -955,7 +955,7 @@ $('.addClick').click(function(){
$("#myModal1").on("shown.bs.modal", function(e) {
if($("option:selected", $("#RequestType")).val() == '-1')
{
alert('Please select the Request Type ');
swal('Please select the Request Type ');
e.close();
}
});
@ -976,7 +976,7 @@ $('.EditClick').click(function(){
if(document.getElementById('EditQuantity').value == '' )
{
alert('Please Enter the Quantity' );
swal('Please Enter the Quantity' );
}
if ( $('#EditQuantity').val() != '' )

View File

@ -51,6 +51,8 @@
<script src="<?php echo base_url();?>assets/plugins/daterangepicker/daterangepicker.js"></script>
<script type="text/javascript" src="<?php echo base_url();?>assets/js/meter.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/sweetalert/1.1.3/sweetalert.min.js"></script>
<link href="<?php echo base_url();?>assets/css/default.css" rel="stylesheet" type="text/css" />
<link href="<?php echo base_url();?>assets/css/style.css" rel="stylesheet" type="text/css" />
@ -84,7 +86,9 @@
<!-- fullCalendar 2.2.5-->
<link rel="stylesheet" href="<?php echo base_url(); ?>assets/plugins/fullcalendar/fullcalendar.min.css">
<link rel="stylesheet" href="<?php echo base_url(); ?>assets/plugins/fullcalendar/fullcalendar.print.css" media="print">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/sweetalert/1.1.3/sweetalert.min.css">
<!-- <script type="text/javascript">
$(function() {
$(this).bind("contextmenu", function(e) {

View File

@ -429,7 +429,7 @@ $('#CostCenter').change(function() {
else
{
$('#content').loader('hide');
alert("Error");
swal("Error");
}
}
@ -438,7 +438,7 @@ $('#CostCenter').change(function() {
}
else
{
alert('Please select the Requistion Type');
swal('Please select the Requistion Type');
$('#CostCenter').val("-1");
return false;
}
@ -493,7 +493,7 @@ $('#CostCenter').change(function() {
}
else
{
alert('Please select the RequestType');
swal('Please select the RequestType');
return false;
}
@ -525,7 +525,7 @@ $("#UOM").val('');
}
else
{
alert('Please select the RequestType');
swal('Please select the RequestType');
return false;
}
@ -580,7 +580,7 @@ function Save()
{
if(document.getElementById('Items').rows.length < 0)
{
alert('Please Select Line item to Create Requisition');
swal('Please Select Line item to Create Requisition');
$('#Deliverydt').focus();
return false;
}
@ -617,7 +617,7 @@ function Save()
if(data)
{
$('#content').loader('hide');
alert(data);
swal(data);
$('#txtRowCount').val('');
$('#txtDeletedRow').val('');
@ -626,7 +626,7 @@ function Save()
}
else
{
alert("Error");
swal("Error");
}
}
@ -640,22 +640,22 @@ function validate()
{
if($("option:selected", $("#RequestType")).val() == '-1')
{
alert('Please Select ReqType Names');
swal('Please Select ReqType Names');
return false;
}
else if($("option:selected", $("#EmpID")).val() == '-1')
{
alert('Please Select Reqby');
swal('Please Select Reqby');
return false;
}
else if($("#txtRowCount").val().length < 1)
{
alert('Please Add Line Item');
swal('Please Add Line Item');
return false;
}
else if(isExceed == 1)
{
alert('You dont have Budget and You cant Raise New Requisition');
swal('You dont have Budget and You cant Raise New Requisition');
return false;
}
else
@ -690,19 +690,19 @@ function validateBeforeAdd()
{
if($("option:selected", $("#RequestType")).val() == '-1')
{
alert('Please select the Request Type ');
swal('Please select the Request Type ');
$("#RequestType").focus();
return false;
}
else if($("#CostCenter").val() == '-1')
{
alert('Please select the Cost center to check the Budget Availablity ');
swal('Please select the Cost center to check the Budget Availablity ');
$("#CostCenter").focus();
return false;
}
else if( isExceed == '1')
{
alert('You dont have available Budget Amount. You cant raise new Requisition');
swal('You dont have available Budget Amount. You cant raise new Requisition');
return false;
}
else
@ -715,13 +715,13 @@ $('.addClick').click(function(){
if ($("#MaterialCode option:selected").val() =='-1' )
{
alert('Please Select the MaterialCode ');
swal('Please Select the MaterialCode ');
return false;
}
if(document.getElementById('Quantity').value == '' )
{
alert('Please Enter the Quantity');
swal('Please Enter the Quantity');
return false;
}
@ -772,7 +772,7 @@ $('.addClick').click(function(){
$("#myModal1").on("shown.bs.modal", function(e) {
if($("option:selected", $("#RequestType")).val() == '-1')
{
alert('Please select the Request Type ');
swal('Please select the Request Type ');
e.close();
}
});
@ -793,7 +793,7 @@ $('.EditClick').click(function(){
if(document.getElementById('EditQuantity').value == '' )
{
alert('Please Enter the Quantity' );
swal('Please Enter the Quantity' );
}
if ( $('#EditQuantity').val() != '' )
@ -828,7 +828,7 @@ $('.EditClick').click(function(){
{
if(document.getElementById('Items').rows.length < 0)
{
alert('Please Select Line item to Create Requisition');
swal('Please Select Line item to Create Requisition');
$('#Deliverydt').focus();
return false;
}
@ -864,7 +864,7 @@ $('.EditClick').click(function(){
if(data)
{
$('#content').loader('hide');
alert(data);
swal(data);
$('#txtRowCount').val('');
$('#txtDeletedRow').val('');
@ -873,7 +873,7 @@ $('.EditClick').click(function(){
}
else
{
alert("Error");
swal("Error");
}
}

File diff suppressed because one or more lines are too long