budget type added in po screen
This commit is contained in:
parent
4c49fe4f2e
commit
06c58fa2ee
@ -1114,8 +1114,7 @@ class purchaseorder extends BaseController
|
|||||||
$Qualitycheck=1;
|
$Qualitycheck=1;
|
||||||
|
|
||||||
// PO Master
|
// PO Master
|
||||||
$POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrderValueSummary,'PODate'=>$PODate,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'Status'=>$POStatus,'PORange'=>$Local_Interstate,'ServiceDescription'=>$SpcialInstruction,'UpdateBY'=>$updatedBy,'DeliveryAddress'=>$DeliveryAddr,'DeliveryDate'=>$Deliverydt,'UpdatedOn'=>$updateddt,'PaymentTerms'=>$PaymentTerms,'POType'=>$POType,'CapitalRange'=>$Local_Interstate,'PaymentOtherDescription'=>$OtherPayment,'Supplier_Reference'=>$supplierreference,'Mode_Of_Shipment'=>$Modeofshipment,'Supplier_Offer_No'=>$supplieroffno,'Other_Reference'=>$otherreference,'Fincap'=>$fincap,'InsuranceStatus'=>$insurancestatus,'POSubType'=>$revenuetype,'InsuranceNumber'=>$insuranceno,'
|
$POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrderValueSummary,'PODate'=>$PODate,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'Status'=>$POStatus,'PORange'=>$Local_Interstate,'ServiceDescription'=>$SpcialInstruction,'UpdateBY'=>$updatedBy,'DeliveryAddress'=>$DeliveryAddr,'DeliveryDate'=>$Deliverydt,'UpdatedOn'=>$updateddt,'PaymentTerms'=>$PaymentTerms,'POType'=>$POType,'CapitalRange'=>$Local_Interstate,'PaymentOtherDescription'=>$OtherPayment,'Supplier_Reference'=>$supplierreference,'Mode_Of_Shipment'=>$Modeofshipment,'Supplier_Offer_No'=>$supplieroffno,'Other_Reference'=>$otherreference,'Fincap'=>$fincap,'InsuranceStatus'=>$insurancestatus,'POSubType'=>$revenuetype,'InsuranceNumber'=>$insuranceno,'IsQualityChkReqired'=>$Qualitycheck,'BudgetType'=>$BudgetType);
|
||||||
IsQualityChkReqired'=>$Qualitycheck,'BudgetType'=>$BudgetType);
|
|
||||||
$POMaster = $this->purchaseorder_model->updatePOMaster($PONO,$POList);
|
$POMaster = $this->purchaseorder_model->updatePOMaster($PONO,$POList);
|
||||||
|
|
||||||
$LineItemStatus = REQITEM_NEW;
|
$LineItemStatus = REQITEM_NEW;
|
||||||
|
|||||||
@ -36,6 +36,7 @@ array("name"=>"NO","value"=>"0"),array("name"=>"YES","value"=>"1")
|
|||||||
$InsuranceNo='';
|
$InsuranceNo='';
|
||||||
$ServiceTypeOptions='';
|
$ServiceTypeOptions='';
|
||||||
$DescriptionOfPo = '';
|
$DescriptionOfPo = '';
|
||||||
|
$BudgetType = '';
|
||||||
|
|
||||||
|
|
||||||
if(!empty($INRSYMBOL))
|
if(!empty($INRSYMBOL))
|
||||||
@ -88,6 +89,7 @@ if(!empty($POMaster))
|
|||||||
$InsuranceNo=$Req->InsuranceNumber;
|
$InsuranceNo=$Req->InsuranceNumber;
|
||||||
$ServiceTypeOptions=$Req->POSubType;
|
$ServiceTypeOptions=$Req->POSubType;
|
||||||
$DescriptionOfPo = $Req->Description_Of_Service;
|
$DescriptionOfPo = $Req->Description_Of_Service;
|
||||||
|
$BudgetType = $Req->BudgetType;
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -529,15 +531,15 @@ function ExceedQuantityCheck()
|
|||||||
var ReqAmount = parseFloat(ValuetoCheck);
|
var ReqAmount = parseFloat(ValuetoCheck);
|
||||||
var BudAmount = parseFloat(budgetAmount);
|
var BudAmount = parseFloat(budgetAmount);
|
||||||
|
|
||||||
if(ReqAmount > BudAmount )
|
// if(ReqAmount > BudAmount )
|
||||||
{
|
// {
|
||||||
swal('Your exceeding the Avaiable Budget :'+ AvilBudAmt +'.Please adjust the Product to proceed further.');
|
// swal('Your exceeding the Avaiable Budget :'+ AvilBudAmt +'.Please adjust the Product to proceed further.');
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
return true;
|
return true;
|
||||||
}
|
//}
|
||||||
}
|
}
|
||||||
function calculateServiceTax(varBasicValue)
|
function calculateServiceTax(varBasicValue)
|
||||||
{
|
{
|
||||||
@ -1074,6 +1076,27 @@ $(document).ready(function () {
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="col-md-2" style="padding-right: 0px;">
|
||||||
|
<label for="BudgetType">Budget Type</label>
|
||||||
|
<select id='BudgetType' name='BudgetType'>
|
||||||
|
<?php if($BudgetType== 'CAPITAL')
|
||||||
|
{
|
||||||
|
$opt1='CAPITAL';
|
||||||
|
$opt2='REVENUE';
|
||||||
|
}
|
||||||
|
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$opt1='REVENUE';
|
||||||
|
$opt2='CAPITAL';
|
||||||
|
} ?>
|
||||||
|
|
||||||
|
|
||||||
|
<option value=<?php echo $opt1;?>><?php echo $opt1;?></option>
|
||||||
|
<option value=<?php echo $opt2;?>><?php echo $opt2;?></option>
|
||||||
|
</select>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div><!--End new fields 1 sep-->
|
</div><!--End new fields 1 sep-->
|
||||||
@ -1473,11 +1496,10 @@ $(document).ready(function () {
|
|||||||
$data = array('name' => 'EditOtheritemDescription','value' => set_value('EditOtheritemDescription'),'id'=>'EditOtheritemDescription', 'class' => 'form-control' ,'readonly' => 'true');
|
$data = array('name' => 'EditOtheritemDescription','value' => set_value('EditOtheritemDescription'),'id'=>'EditOtheritemDescription', 'class' => 'form-control' ,'readonly' => 'true');
|
||||||
echo form_input($data);
|
echo form_input($data);
|
||||||
?>
|
?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
<div class="col-md-3">
|
||||||
|
|
||||||
</div>
|
|
||||||
<div class="col-md-3">
|
|
||||||
<label>UOM</label>
|
<label>UOM</label>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<?php
|
<?php
|
||||||
@ -2239,6 +2261,8 @@ $(document).ready(function () {
|
|||||||
<input type="hidden" name="txtStatus" id="txtStatus" />
|
<input type="hidden" name="txtStatus" id="txtStatus" />
|
||||||
<input type="hidden" name="txtRowCount" id="txtRowCount" value="<?php echo $index;?>">
|
<input type="hidden" name="txtRowCount" id="txtRowCount" value="<?php echo $index;?>">
|
||||||
<input type="hidden" name="txtDeletedRow" id="txtDeletedRow" />
|
<input type="hidden" name="txtDeletedRow" id="txtDeletedRow" />
|
||||||
|
<input type="hidden" name="Budget" id="Budget" value="<?php echo $BudgetType; ?>" />
|
||||||
|
|
||||||
<?php if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED || $PONOStatus == REQITEM_Emergency_PO_CREATED ) {
|
<?php if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED || $PONOStatus == REQITEM_Emergency_PO_CREATED ) {
|
||||||
if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED){?>
|
if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED){?>
|
||||||
<a class="btn btn-primary Save" ID="Save" onclick="Save(0)" > <span class="bold">Save</span></a> <?php }?>
|
<a class="btn btn-primary Save" ID="Save" onclick="Save(0)" > <span class="bold">Save</span></a> <?php }?>
|
||||||
@ -2301,6 +2325,14 @@ var userid = '';
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
$("#BudgetType").change(function(){
|
||||||
|
|
||||||
|
var aa = $("#BudgetType option:selected").text();
|
||||||
|
|
||||||
|
$('#Budget').val(aa);
|
||||||
|
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
$('#EditotherDescription').hide();
|
$('#EditotherDescription').hide();
|
||||||
$('#otherdescription').hide();
|
$('#otherdescription').hide();
|
||||||
@ -2933,11 +2965,11 @@ var txtTotalOrderValueSummary = $('#txtTotBasicAmount').val();
|
|||||||
$('#Deliverydt').focus();
|
$('#Deliverydt').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if(parseInt(AvlBudAmt) < parseInt(txtTotalOrderValueSummary)) {
|
// else if(parseInt(AvlBudAmt) < parseInt(txtTotalOrderValueSummary)) {
|
||||||
swal('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.');
|
// swal('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
|
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else if($('#Otherpayment').val()=='' && $('#PaymentTerms').val()=='PT08'){
|
else if($('#Otherpayment').val()=='' && $('#PaymentTerms').val()=='PT08'){
|
||||||
swal('Please Enter Other Payment Details');
|
swal('Please Enter Other Payment Details');
|
||||||
$('#Otherpayment').focus();
|
$('#Otherpayment').focus();
|
||||||
|
|||||||
178
application/views/alterpurchaseorder.php
Executable file → Normal file
178
application/views/alterpurchaseorder.php
Executable file → Normal file
@ -1,5 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
//r
|
|
||||||
$insuranceStatus = array(
|
$insuranceStatus = array(
|
||||||
array("name"=>"NO","value"=>"0"),array("name"=>"YES","value"=>"1")
|
array("name"=>"NO","value"=>"0"),array("name"=>"YES","value"=>"1")
|
||||||
);
|
);
|
||||||
@ -1728,13 +1727,38 @@ function calculatePackaging(isEdit)
|
|||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
function rfilealert()
|
||||||
|
{
|
||||||
|
var file = $('#imag').val();
|
||||||
|
|
||||||
|
if (file=='')
|
||||||
|
{
|
||||||
|
swal('File not found');
|
||||||
|
SpecialPOcheck();
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
SpecialPOcheck();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function sfilealert()
|
||||||
|
{
|
||||||
|
|
||||||
|
var file1 = $('#images1').val();
|
||||||
|
if (file1=='')
|
||||||
|
{
|
||||||
|
swal('File not found');
|
||||||
|
SpecialPOcheck();
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
SpecialPOcheck();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
function SpecialPOcheck()
|
function SpecialPOcheck()
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// swal('splpo')
|
// swal('splpo')
|
||||||
//$('#content').loader('show');
|
//$('#content').loader('show');
|
||||||
POcheck=$("input:radio[name='Quality']:checked").val();
|
POcheck=$("input:radio[name='Quality']:checked").val();
|
||||||
@ -2225,6 +2249,14 @@ Editchange();
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
else if($('#BudgetType').val()=="0")
|
||||||
|
{
|
||||||
|
swal('Please Select Budget Type');
|
||||||
|
$('#BudgetType').focus();
|
||||||
|
return false;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
else if(input=='REVENUE' && $('#Deliverydate').val()=='' && radioValue==0){
|
else if(input=='REVENUE' && $('#Deliverydate').val()=='' && radioValue==0){
|
||||||
@ -2803,7 +2835,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
<div class="col-md-6" style="padding: 0px;">
|
<div class="col-md-6" style="padding: 0px;">
|
||||||
|
|
||||||
|
|
||||||
<label id="typeOptions">Service Type Options<span class="badge" style="color:red;text-align:right;background-color: #ecf0f5;">*</span></label>
|
<label id="typeOptions">Service Type Options</label>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
@ -2898,6 +2930,21 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-2" style="padding-right: 0px;">
|
||||||
|
<label for="BudgetType">Budget Type</label>
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
$optionsnew=array('0'=>'Select','1'=>'REVENUE','2'=>'CAPITAL');
|
||||||
|
echo form_dropdown('BudgetType', $optionsnew,set_value('BudgetType'),'id="BudgetType"' ,'required="true"' ,'class="form-control select2');
|
||||||
|
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div><!--End new fields 1 sep-->
|
</div><!--End new fields 1 sep-->
|
||||||
|
|
||||||
@ -3063,21 +3110,15 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
|
|
||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
<div class="col-md-5">
|
<div class="col-md-5">
|
||||||
<input type = "file" size = "20" input accept=".docx,.pdf,.doc.JPG,.PNG" id="images" name="images"/>
|
<input type = "file" size = "20" input accept=".docx,.pdf,.doc.JPG,.PNG" id="imag" name="images" onChange="filecheck();"/>
|
||||||
<label for="images">Select Company file<br/><small>(only .pdf,.excel,.doc,.png,.jpg)</small></label>
|
<label for="images">Select file<br/><small>(only .pdf,.excel,.doc,.png,.jpg)</small></label>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<!--<div class="col-md-12 text-right" style="padding-bottom:1%;">
|
|
||||||
<div class="col-md-4" style="margin-left: 64%;">
|
|
||||||
<a class="btn btn-primary Add" onclick="addtable();"><span class="bold">Add LineItem</span></a>
|
|
||||||
</div>
|
|
||||||
</div>-->
|
|
||||||
</div>
|
</div>
|
||||||
<!-- <div class="col-md-12 text-right">
|
|
||||||
// <a class="btn btn-primary font Add" id="addtable"><span class="bold">Add table</span></a>
|
|
||||||
// </div>-->
|
|
||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
|
|
||||||
<table id="specialtable" class="table table-hover table-bordered" style="background-color:#fff;font-size:12px;" >
|
<table id="specialtable" class="table table-hover table-bordered" style="background-color:#fff;font-size:12px;" >
|
||||||
@ -3107,7 +3148,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
<a class="btn btn-primary Add" onclick="addtable();"><span class="bold">Add table</span></a>
|
<a class="btn btn-primary Add" onclick="addtable();"><span class="bold">Add table</span></a>
|
||||||
</div> -->
|
</div> -->
|
||||||
<div class="col-md-4 col-md-offset-8">
|
<div class="col-md-4 col-md-offset-8">
|
||||||
<a class="btn btn-primary ok" ID="ExciseOption12" onclick="SpecialPOcheck();" > <span class="bold">Submit</span></a>
|
<a class="btn btn-primary ok" ID="ExciseOption12" onclick="rfilealert();" > <span class="bold">Submit</span></a>
|
||||||
|
|
||||||
<a class="btn btn-primary" data-dismiss="modal" onclick="SetExciseCalculationCancel();" value="Cancel">Cancel</a>
|
<a class="btn btn-primary" data-dismiss="modal" onclick="SetExciseCalculationCancel();" value="Cancel">Cancel</a>
|
||||||
</div>
|
</div>
|
||||||
@ -3134,7 +3175,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
|
|
||||||
|
|
||||||
<div class="col-md-4">
|
<div class="col-md-4">
|
||||||
<input type = "file" size = "20" input accept=".docx,.pdx,.doc.JPG,.PNG" id="images1" name="images1"/>
|
<input type = "file" size = "20" input accept=".docx,.pdx,.doc.JPG,.PNG" id="images1" name="images1" onChange="sfilecheck();"/>
|
||||||
<label for="images">Select Company file<br/><small>(only .pdf,.excel,.doc,.png,.jpg)</small></label>
|
<label for="images">Select Company file<br/><small>(only .pdf,.excel,.doc,.png,.jpg)</small></label>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -3150,7 +3191,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
<div class="col-md-12 text-right">
|
<div class="col-md-12 text-right">
|
||||||
|
|
||||||
<div class="col-md-4 col-md-offset-8">
|
<div class="col-md-4 col-md-offset-8">
|
||||||
<a class="btn btn-primary ok" ID="ExciseOption12" onclick="SpecialPOcheck();" > <span class="bold">Submit</span></a>
|
<a class="btn btn-primary ok" ID="ExciseOption12" onclick="sfilealert();" > <span class="bold">Submit</span></a>
|
||||||
|
|
||||||
<a class="btn btn-primary" data-dismiss="modal" onclick="SetExciseCalculationCancel();" value="Cancel">Cancel</a>
|
<a class="btn btn-primary" data-dismiss="modal" onclick="SetExciseCalculationCancel();" value="Cancel">Cancel</a>
|
||||||
</div>
|
</div>
|
||||||
@ -3297,7 +3338,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:1000px;">
|
<div class="modal-content" style="width:1000px;">
|
||||||
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
<div class="modal-header" style="background-color: #3c;color:#fff;">
|
||||||
|
|
||||||
<center><h4>Edit Service Purchase Order Item </h4></center>
|
<center><h4>Edit Service Purchase Order Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
@ -3620,7 +3661,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:1150px;">
|
<div class="modal-content" style="width:1150px;">
|
||||||
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
<div class="modal-header" style="background-color: #3c;color:#fff;">
|
||||||
<center><h4>Edit Revenue Purchase Order Line Item </h4></center>
|
<center><h4>Edit Revenue Purchase Order Line Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
<div align="left">
|
<div align="left">
|
||||||
@ -4329,7 +4370,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:1000px;">
|
<div class="modal-content" style="width:1000px;">
|
||||||
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
||||||
<center><h4>Add Service Purchase Order Item </h4></center>
|
<center><h4>Add Service Purchase Order Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
<div align="left">
|
<div align="left">
|
||||||
@ -4631,7 +4672,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:900px;">
|
<div class="modal-content" style="width:900px;">
|
||||||
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
||||||
|
|
||||||
<center><h4>Add Import Purchase Order Item </h4></center>
|
<center><h4>Add Import Purchase Order Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
@ -5132,7 +5173,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:900px;">
|
<div class="modal-content" style="width:900px;">
|
||||||
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
||||||
|
|
||||||
<center><h4>Add Capital Purchase Order Item </h4></center>
|
<center><h4>Add Capital Purchase Order Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
@ -5726,6 +5767,8 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
<input type="hidden" name="txtDeletedRow1" id="txtDeletedRow1" />
|
<input type="hidden" name="txtDeletedRow1" id="txtDeletedRow1" />
|
||||||
<input type="hidden" name="CheckLocalInter" id="CheckLocalInter" />
|
<input type="hidden" name="CheckLocalInter" id="CheckLocalInter" />
|
||||||
|
|
||||||
|
<input type="hidden" name="Budget" id="Budget" />
|
||||||
|
|
||||||
|
|
||||||
<input type="hidden" name="txtSpecial" id="txtSpecial" />
|
<input type="hidden" name="txtSpecial" id="txtSpecial" />
|
||||||
|
|
||||||
@ -5868,6 +5911,25 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
<script>
|
<script>
|
||||||
var index = '1';
|
var index = '1';
|
||||||
var userid = '';
|
var userid = '';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$("#BudgetType").change(function(){
|
||||||
|
|
||||||
|
var aa = $("#BudgetType option:selected").text();
|
||||||
|
|
||||||
|
$('#Budget').val(aa);
|
||||||
|
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$('.AddRevenue').click(function(){
|
$('.AddRevenue').click(function(){
|
||||||
|
|
||||||
tinyMCE.triggerSave();
|
tinyMCE.triggerSave();
|
||||||
@ -6096,7 +6158,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
if(data)
|
if(data)
|
||||||
{
|
{
|
||||||
$('#content').loader('hide');
|
$('#content').loader('hide');
|
||||||
alert(data);
|
swal(data);
|
||||||
//$('#txtRowCount').val('');
|
//$('#txtRowCount').val('');
|
||||||
//$('#txtDeletedRow').val('');
|
//$('#txtDeletedRow').val('');
|
||||||
|
|
||||||
@ -6105,7 +6167,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
alert("Error");
|
swal("Error");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -6406,7 +6468,7 @@ $('#PoTypeOptions').change(function()
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
alert("Error");
|
swal("Error");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -6460,7 +6522,7 @@ $('#PoTypeOptions').change(function()
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
$('#content').loader('hide');
|
$('#content').loader('hide');
|
||||||
alert("Error");
|
swal("Error");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -6510,7 +6572,7 @@ $('#PoTypeOptions').change(function()
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
$('#content').loader('hide');
|
$('#content').loader('hide');
|
||||||
alert("Error");
|
swal("Error");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -6656,7 +6718,7 @@ $('#PoTypeOptions').change(function()
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
$('#content').loader('hide');
|
$('#content').loader('hide');
|
||||||
alert("Error");
|
swal("Error");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -6790,15 +6852,15 @@ $('#PoTypeOptions').change(function()
|
|||||||
var ReqAmount = parseFloat(ValuetoCheck);
|
var ReqAmount = parseFloat(ValuetoCheck);
|
||||||
var BudAmount = parseFloat(budgetAmount);
|
var BudAmount = parseFloat(budgetAmount);
|
||||||
|
|
||||||
if(ReqAmount > BudAmount )
|
// if(ReqAmount > BudAmount )
|
||||||
{
|
// {
|
||||||
swal('Your exceeding the Avaiable Budget :'+ budgetAmount +'.Please adjust the Product to proceed further.');
|
// swal('Your exceeding the Avaiable Budget :'+ budgetAmount +'.Please adjust the Product to proceed further.');
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
return true;
|
return true;
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* This function is used when clicking add service button that time store the info for submit
|
* This function is used when clicking add service button that time store the info for submit
|
||||||
@ -7467,11 +7529,11 @@ $('#content').loader('hide');
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
else if(parseInt($('#AvalBuget').val()) < parseInt(TextTotalOrderValueSummaryService)) {
|
// else if(parseInt($('#AvalBuget').val()) < parseInt(TextTotalOrderValueSummaryService)) {
|
||||||
swal('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.');
|
// swal('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
|
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else if($('#Otherpayment').val()=='' && $('#PaymentMethod').val()=='PT08'){
|
else if($('#Otherpayment').val()=='' && $('#PaymentMethod').val()=='PT08'){
|
||||||
swal('Please Enter Other Payable Terms Description');
|
swal('Please Enter Other Payable Terms Description');
|
||||||
$('#Otherpayment').focus();
|
$('#Otherpayment').focus();
|
||||||
@ -7563,8 +7625,8 @@ $('#content').loader('hide');
|
|||||||
|
|
||||||
|
|
||||||
tinyMCE.triggerSave();
|
tinyMCE.triggerSave();
|
||||||
var splinstr = $('#txtSpcialInstruction').val();
|
var splinstr = $('#txtSpcialInstruction').val();
|
||||||
$('#SpcialInstruction').val(splinstr);
|
$('#SpcialInstruction').val(splinstr);
|
||||||
var deladd = $('#DeliveryAddr').val();
|
var deladd = $('#DeliveryAddr').val();
|
||||||
|
|
||||||
$('#txtDeliveryAddress').val(deladd);
|
$('#txtDeliveryAddress').val(deladd);
|
||||||
@ -7587,11 +7649,11 @@ $('#SpcialInstruction').val(splinstr);
|
|||||||
$('#Deliverydt').focus();
|
$('#Deliverydt').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if(parseInt($('#AvalBuget').val()) < parseInt(finalbasicamtrate)) {
|
// else if(parseInt($('#AvalBuget').val()) < parseInt(finalbasicamtrate)) {
|
||||||
swal('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.');
|
// swal('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
|
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else if($('#insuranceStatus').val() == 'YES' && $('#insuranceNo').val() == '' ) {
|
else if($('#insuranceStatus').val() == 'YES' && $('#insuranceNo').val() == '' ) {
|
||||||
swal('Please Enter Insurance Number..!');
|
swal('Please Enter Insurance Number..!');
|
||||||
|
|
||||||
@ -8624,6 +8686,30 @@ var specialservicerow=0;
|
|||||||
|
|
||||||
|
|
||||||
}//add click function closed
|
}//add click function closed
|
||||||
|
function filecheck()
|
||||||
|
{
|
||||||
|
|
||||||
|
//$('#content').loader('show');
|
||||||
|
var file = $('#imag').val();
|
||||||
|
swal(file);
|
||||||
|
if(file!='')
|
||||||
|
{
|
||||||
|
|
||||||
|
swal('Your file added successfully');
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
function sfilecheck()
|
||||||
|
{
|
||||||
|
//$('#content').loader('show');
|
||||||
|
var file1 = $('#images1').val();
|
||||||
|
if(file1!='')
|
||||||
|
{
|
||||||
|
|
||||||
|
swal('Your file added successfully');
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -1,14 +1,14 @@
|
|||||||
<?php
|
<?php
|
||||||
$insuranceStatus = array(
|
$insuranceStatus = array(
|
||||||
array("name"=>"NO","value"=>"0"),array("name"=>"YES","value"=>"1")
|
array("name"=>"NO","value"=>"0"),array("name"=>"YES","value"=>"1")
|
||||||
);
|
);
|
||||||
$requestedBy=$RequistionDetails[0]->FirstName;
|
$requestedBy=$RequistionDetails[0]->FirstName;
|
||||||
$Updateddt = new DateTime($RequistionDetails[0]->ReqDate);
|
$Updateddt = new DateTime($RequistionDetails[0]->ReqDate);
|
||||||
$UpdatedOn=$Updateddt->format('d-m-Y');
|
$UpdatedOn=$Updateddt->format('d-m-Y');
|
||||||
$dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
|
$dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
|
||||||
$CurrentDate = $dt->format('d-m-Y');
|
$CurrentDate = $dt->format('d-m-Y');
|
||||||
$res_arr_values = array();
|
$res_arr_values = array();
|
||||||
$DeliverOption='';
|
$DeliverOption='';
|
||||||
$SupId = '';
|
$SupId = '';
|
||||||
$SupName = '';
|
$SupName = '';
|
||||||
$Address = '';
|
$Address = '';
|
||||||
@ -23,13 +23,12 @@
|
|||||||
$TotalSgst = 0.0;
|
$TotalSgst = 0.0;
|
||||||
$TotalIgst = 0.0;
|
$TotalIgst = 0.0;
|
||||||
$OtherAmt = 0.0;
|
$OtherAmt = 0.0;
|
||||||
$TotalFreightvalue=0.0;
|
$TotalFreightvalue=0.0;
|
||||||
|
|
||||||
|
|
||||||
|
$totassesable=0;
|
||||||
$totassesable=0;
|
$totSubtotal=0;
|
||||||
$totSubtotal=0;
|
$totigst=0;
|
||||||
$totigst=0;
|
|
||||||
|
|
||||||
$TotalSummary = 0.0;
|
$TotalSummary = 0.0;
|
||||||
$TotalBasicAmount = 0.0;
|
$TotalBasicAmount = 0.0;
|
||||||
@ -70,9 +69,9 @@
|
|||||||
$PaymentDays='';
|
$PaymentDays='';
|
||||||
$PayableAT='';
|
$PayableAT='';
|
||||||
$ExchangeDate='';
|
$ExchangeDate='';
|
||||||
$ExchangeRateOn='';
|
$ExchangeRateOn='';
|
||||||
|
|
||||||
$CapitalRange='';
|
$CapitalRange='';
|
||||||
$PoStatusName='';
|
$PoStatusName='';
|
||||||
$otherPayment='';
|
$otherPayment='';
|
||||||
$INR='';
|
$INR='';
|
||||||
@ -82,7 +81,7 @@
|
|||||||
|
|
||||||
$ExitExchangeRate='';
|
$ExitExchangeRate='';
|
||||||
|
|
||||||
$ModeOfShipment='';
|
$ModeOfShipment='';
|
||||||
$SupplierReference='';
|
$SupplierReference='';
|
||||||
$SuppliersOfferNo='';
|
$SuppliersOfferNo='';
|
||||||
$OtherReferences='';
|
$OtherReferences='';
|
||||||
@ -90,6 +89,8 @@
|
|||||||
$InsuranceOptions='';
|
$InsuranceOptions='';
|
||||||
$InsuranceNo='';
|
$InsuranceNo='';
|
||||||
$ServiceTypeOptions='';
|
$ServiceTypeOptions='';
|
||||||
|
$BudgetType = '';
|
||||||
|
|
||||||
if(!empty($INRSYMBOL))
|
if(!empty($INRSYMBOL))
|
||||||
{
|
{
|
||||||
foreach ($INRSYMBOL as $INR)
|
foreach ($INRSYMBOL as $INR)
|
||||||
@ -119,7 +120,7 @@ if(!empty($POMaster))
|
|||||||
|
|
||||||
$SupId = $Req->SupplierID;
|
$SupId = $Req->SupplierID;
|
||||||
|
|
||||||
$SupName = $Req->SupplierName;
|
$SupName = $Req->SupplierName;
|
||||||
$Address = $Req->Address;
|
$Address = $Req->Address;
|
||||||
$pdt = new DateTime($Req->PODate);
|
$pdt = new DateTime($Req->PODate);
|
||||||
$PODate = $pdt->format('d-m-Y');
|
$PODate = $pdt->format('d-m-Y');
|
||||||
@ -165,6 +166,7 @@ if(!empty($POMaster))
|
|||||||
$InsuranceOptions=$Req->InsuranceStatus;
|
$InsuranceOptions=$Req->InsuranceStatus;
|
||||||
$InsuranceNo=$Req->InsuranceNumber;
|
$InsuranceNo=$Req->InsuranceNumber;
|
||||||
$ServiceTypeOptions=$Req->POSubType;
|
$ServiceTypeOptions=$Req->POSubType;
|
||||||
|
$BudgetType = $Req->BudgetType;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -377,6 +379,7 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
|
if($("#EditCgst").val() != '' ){$("#EditIgst").prop("readonly", true);}
|
||||||
$("#PaymentMethod").select2();
|
$("#PaymentMethod").select2();
|
||||||
//Initialize Select2 Elements
|
//Initialize Select2 Elements
|
||||||
$("#drpSupplier").select2();
|
$("#drpSupplier").select2();
|
||||||
@ -884,6 +887,29 @@ $("#PaymentMethod").select2();
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
<div class="col-md-2" style="padding-right: 0px;">
|
||||||
|
<label for="BudgetType">Budget Type</label>
|
||||||
|
<select id='BudgetType' name='BudgetType'>
|
||||||
|
<?php if($BudgetType== 'CAPITAL')
|
||||||
|
{
|
||||||
|
$opt1='CAPITAL';
|
||||||
|
$opt2='REVENUE';
|
||||||
|
}
|
||||||
|
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$opt1='REVENUE';
|
||||||
|
$opt2='CAPITAL';
|
||||||
|
} ?>
|
||||||
|
|
||||||
|
|
||||||
|
<option value=<?php echo $opt1;?>><?php echo $opt1;?></option>
|
||||||
|
<option value=<?php echo $opt2;?>><?php echo $opt2;?></option>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
</div><!--End new fields 1 sep-->
|
</div><!--End new fields 1 sep-->
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@ -1323,7 +1349,7 @@ $("#PaymentMethod").select2();
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:1160px;">
|
<div class="modal-content" style="width:1160px;">
|
||||||
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
||||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||||
<center><h4>Add Capital Purchase Order Item </h4></center>
|
<center><h4>Add Capital Purchase Order Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
@ -1639,9 +1665,9 @@ $("#PaymentMethod").select2();
|
|||||||
<div class="col-md-3">
|
<div class="col-md-3">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
$data = array('name' => 'Igst','value' => set_value('Igst',0),'id'=>'Igst', 'class' => 'form-control num' ,'placeholder' => 'IGST TAX PERCENTAGE','onchange'=>'Ratechange()','onkeypress'=>'return isNumberKey(event);');
|
$data = array('name' => 'Igst','value' => set_value('Igst',0),'id'=>'Igst', 'class' => 'form-control num' ,'placeholder' => 'IGST TAX PERCENTAGE','onchange'=>'Ratechange()','onkeypress'=>'return isNumberKey(event);');
|
||||||
echo form_input($data);
|
echo form_input($data);
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -2068,7 +2094,7 @@ $("#PaymentMethod").select2();
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:1160px;">
|
<div class="modal-content" style="width:1160px;">
|
||||||
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
||||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||||
<center><h4>Edit Capital Purchase Order Item </h4></center>
|
<center><h4>Edit Capital Purchase Order Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
@ -2810,7 +2836,7 @@ $("#PaymentMethod").select2();
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:1160px;">
|
<div class="modal-content" style="width:1160px;">
|
||||||
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
||||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||||
<center><h4>View Capital Purchase Order Item </h4></center>
|
<center><h4>View Capital Purchase Order Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
@ -3143,8 +3169,7 @@ $("#PaymentMethod").select2();
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
<div class="col-md-12" id="" style="padding: 0px;">
|
||||||
<div class="col-md-12" id="" style="padding: 0px;">
|
|
||||||
<div class="col-md-5 col-md-offset-4" align="right">
|
<div class="col-md-5 col-md-offset-4" align="right">
|
||||||
<label>Total Amount <?php echo "($INR)"?></label>
|
<label>Total Amount <?php echo "($INR)"?></label>
|
||||||
</div>
|
</div>
|
||||||
@ -3157,6 +3182,7 @@ $("#PaymentMethod").select2();
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div class="col-md-12" style="padding:1%;" ></div>
|
<div class="col-md-12" style="padding:1%;" ></div>
|
||||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;" id="ViewModalImportTaxHide" style="display:none;">
|
<div class="col-md-12" style="border:1px solid #000;padding:0px;" id="ViewModalImportTaxHide" style="display:none;">
|
||||||
<br/>
|
<br/>
|
||||||
@ -3756,6 +3782,8 @@ $("#PaymentMethod").select2();
|
|||||||
<input type="hidden" name="txtStatus" id="txtStatus" />
|
<input type="hidden" name="txtStatus" id="txtStatus" />
|
||||||
<input type="hidden" name="txtDeletedRow" id="txtDeletedRow" />
|
<input type="hidden" name="txtDeletedRow" id="txtDeletedRow" />
|
||||||
|
|
||||||
|
<input type="hidden" name="Budget" id="Budget" value="<?php echo $BudgetType; ?>" />
|
||||||
|
|
||||||
|
|
||||||
<?php if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED )
|
<?php if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED )
|
||||||
{
|
{
|
||||||
@ -3867,6 +3895,17 @@ var myArray = <?php echo json_encode($res_arr_values); ?>;
|
|||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$("#BudgetType").change(function(){
|
||||||
|
|
||||||
|
var aa = $("#BudgetType option:selected").text();
|
||||||
|
|
||||||
|
$('#Budget').val(aa);
|
||||||
|
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
$(function() {
|
$(function() {
|
||||||
|
|
||||||
$("#PODate").datepicker({
|
$("#PODate").datepicker({
|
||||||
@ -3965,7 +4004,7 @@ var PaymentOtherData = '<?php echo $otherPayment; ?>';
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please select the SupplierID');
|
alert('Please select the SupplierID');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4051,7 +4090,7 @@ var PaymentOtherData = '<?php echo $otherPayment; ?>';
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please select the Requisition Number');
|
alert('Please select the Requisition Number');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
id = '';
|
id = '';
|
||||||
@ -4094,7 +4133,7 @@ var PaymentOtherData = '<?php echo $otherPayment; ?>';
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please select the MaterialCode');
|
alert('Please select the MaterialCode');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4136,7 +4175,7 @@ var PaymentOtherData = '<?php echo $otherPayment; ?>';
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please select the MaterialCode');
|
alert('Please select the MaterialCode');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4186,10 +4225,12 @@ var PaymentOtherData = '<?php echo $otherPayment; ?>';
|
|||||||
}
|
}
|
||||||
function ChangeSgst(){
|
function ChangeSgst(){
|
||||||
$('#Sgst').val($('#Cgst').val());
|
$('#Sgst').val($('#Cgst').val());
|
||||||
|
$("#Igst").prop("readonly", true);
|
||||||
Ratechange();
|
Ratechange();
|
||||||
}
|
}
|
||||||
function ChangeEditSgst(){
|
function ChangeEditSgst(){
|
||||||
$('#EditSgst').val($('#EditCgst').val());
|
$('#EditSgst').val($('#EditCgst').val());
|
||||||
|
$("#EditIgst").prop("readonly", true);
|
||||||
EditRatechange();
|
EditRatechange();
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
@ -4202,19 +4243,19 @@ EditRatechange();
|
|||||||
|
|
||||||
if($('#Reqnumber').val() == "0")
|
if($('#Reqnumber').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Requisition Number');
|
alert('Please select the Requisition Number');
|
||||||
$('#Reqnumber').focus();
|
$('#Reqnumber').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#MaterialCode').val() == "0")
|
else if($('#MaterialCode').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Material Code');
|
alert('Please select the Material Code');
|
||||||
$('#MaterialCode').focus();
|
$('#MaterialCode').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#CostCenter').val() == "0")
|
else if($('#CostCenter').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the CostCenterCode');
|
alert('Please select the CostCenterCode');
|
||||||
$('#CostCenter').focus();
|
$('#CostCenter').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -4267,8 +4308,8 @@ EditRatechange();
|
|||||||
|
|
||||||
|
|
||||||
$('#AfterCgst').val(calculateCgstTax(CPtotal,$("#Cgst").val()== '' ? "0.00" : $('#Cgst').val()));
|
$('#AfterCgst').val(calculateCgstTax(CPtotal,$("#Cgst").val()== '' ? "0.00" : $('#Cgst').val()));
|
||||||
$('#AfterSgst').val(calculateSgstTax(CPtotal,$("#Sgst").val()== '' ? "0.00" : $('#Sgst').val()));
|
$('#AfterSgst').val(calculateSgstTax(CPtotal,$("#Sgst").val()== '' ? "0.00" : $('#Sgst').val()));
|
||||||
$('#AfterIgst').val(calculateIgstTax(CPtotal,$("#Igst").val()== '' ? "0.00" : $('#Igst').val()));
|
$('#AfterIgst').val(calculateIgstTax(CPtotal,$("#Igst").val()== '' ? "0.00" : $('#Igst').val()));
|
||||||
|
|
||||||
|
|
||||||
Calculateloadingcharge();
|
Calculateloadingcharge();
|
||||||
@ -4399,7 +4440,7 @@ Calculateloadingcharge();
|
|||||||
//alert(ReqQuantity);
|
//alert(ReqQuantity);
|
||||||
if(EnterQuantity > ReqQuantity)
|
if(EnterQuantity > ReqQuantity)
|
||||||
{
|
{
|
||||||
swal('Your exceeding the Quantity from the Requisition Quantity:'+ RequistQuantity +'.Please adjust the Quantity to proceed further.');
|
alert('Your exceeding the Quantity from the Requisition Quantity:'+ RequistQuantity +'.Please adjust the Quantity to proceed further.');
|
||||||
|
|
||||||
$('#CPQuantity').focus();
|
$('#CPQuantity').focus();
|
||||||
return false;
|
return false;
|
||||||
@ -4747,16 +4788,16 @@ if(isNaN(CustomDutyExpenses))
|
|||||||
var ReqAmount = parseFloat(ValuetoCheck);
|
var ReqAmount = parseFloat(ValuetoCheck);
|
||||||
var BudAmount = parseFloat(budgetAmount);
|
var BudAmount = parseFloat(budgetAmount);
|
||||||
|
|
||||||
if(ReqAmount > BudAmount )
|
// if(ReqAmount > BudAmount )
|
||||||
{
|
// {
|
||||||
swal('Your exceeding the Avaiable Budget :'+ BudAmount +'.Please adjust the Product to proceed further.');
|
// alert('Your exceeding the Avaiable Budget :'+ BudAmount +'.Please adjust the Product to proceed further.');
|
||||||
|
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
return true;
|
return true;
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -4994,59 +5035,59 @@ if(isNaN(CustomDutyExpenses))
|
|||||||
else{
|
else{
|
||||||
basicAmountRate=parseFloat(basicAmountRate) - parseFloat(discountRate);
|
basicAmountRate=parseFloat(basicAmountRate) - parseFloat(discountRate);
|
||||||
}
|
}
|
||||||
if(basicAmountRate > avalbudAmt)
|
// if(basicAmountRate > avalbudAmt)
|
||||||
{
|
// {
|
||||||
swal('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
// alert('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
$('#CPRate').focus();
|
// $('#CPRate').focus();
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
return true;
|
return true;
|
||||||
}
|
// }
|
||||||
|
|
||||||
}
|
}
|
||||||
function validateCapitalTax()
|
function validateCapitalTax()
|
||||||
{
|
{
|
||||||
if($('#Reqnumber').val() == "0")
|
if($('#Reqnumber').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Requisition Number');
|
alert('Please select the Requisition Number');
|
||||||
$('#Reqnumber').focus();
|
$('#Reqnumber').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#CostCenter').val() == "0")
|
else if($('#CostCenter').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Cost center');
|
alert('Please select the Cost center');
|
||||||
$('#CostCenter').focus();
|
$('#CostCenter').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#MaterialCode').val() == "0")
|
else if($('#MaterialCode').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Material Code');
|
alert('Please select the Material Code');
|
||||||
$('#MaterialCode').focus();
|
$('#MaterialCode').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#CPQuantity').val() == '')
|
else if($('#CPQuantity').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Quantity value');
|
alert('Please Enter the Quantity value');
|
||||||
$('#CPQuantity').focus();
|
$('#CPQuantity').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#CPQuantity').val() == "0")
|
else if($('#CPQuantity').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please Enter the Valid Quantity value');
|
alert('Please Enter the Valid Quantity value');
|
||||||
$('#CPQuantity').focus();
|
$('#CPQuantity').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#CPRate').val() == '')
|
else if($('#CPRate').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate of the Item');
|
alert('Please Enter the Rate of the Item');
|
||||||
$('#CPRate').focus();
|
$('#CPRate').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#CPRate').val() == "0")
|
else if($('#CPRate').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please Enter the Valid Rate of the Item');
|
alert('Please Enter the Valid Rate of the Item');
|
||||||
$('#CPRate').focus();
|
$('#CPRate').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -5472,11 +5513,11 @@ function DeleteRow(rowid)
|
|||||||
if(data)
|
if(data)
|
||||||
{
|
{
|
||||||
$('#content').loader('hide');
|
$('#content').loader('hide');
|
||||||
swal(data);
|
alert(data);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal("Error");
|
alert("Error");
|
||||||
}
|
}
|
||||||
|
|
||||||
}});
|
}});
|
||||||
@ -5743,6 +5784,7 @@ function DeleteRow(rowid)
|
|||||||
$('#EditCgst').val($('#Cgst'+userid).val());
|
$('#EditCgst').val($('#Cgst'+userid).val());
|
||||||
$('#EditSgst').val($('#Sgst'+userid).val());
|
$('#EditSgst').val($('#Sgst'+userid).val());
|
||||||
$('#EditIgst').val($('#Igst'+userid).val());
|
$('#EditIgst').val($('#Igst'+userid).val());
|
||||||
|
if($('#Cgst'+userid).val() != '0.00'){$("#EditIgst").prop("readonly", true);}
|
||||||
$('#EditAfterCgst').val($('#AfterCgst'+userid).val());
|
$('#EditAfterCgst').val($('#AfterCgst'+userid).val());
|
||||||
$('#EditAfterSgst').val($('#AfterSgst'+userid).val());
|
$('#EditAfterSgst').val($('#AfterSgst'+userid).val());
|
||||||
$('#EditAfterIgst').val($('#AfterIgst'+userid).val());
|
$('#EditAfterIgst').val($('#AfterIgst'+userid).val());
|
||||||
@ -5898,7 +5940,8 @@ function DeleteRow(rowid)
|
|||||||
$('#ViewAfterSgst').val($('#AfterSgst'+userid).val());
|
$('#ViewAfterSgst').val($('#AfterSgst'+userid).val());
|
||||||
$('#ViewAfterIgst').val($('#AfterIgst'+userid).val());
|
$('#ViewAfterIgst').val($('#AfterIgst'+userid).val());
|
||||||
$('#ViewOtherAllowances').val($('#OtherAmt'+userid).val());
|
$('#ViewOtherAllowances').val($('#OtherAmt'+userid).val());
|
||||||
$('#ViewTotalAmountlocal').val(cellval[9].innerHTML);
|
$('#ViewTotalAmountlocal').val(cellval[9].innerHTML);
|
||||||
|
|
||||||
|
|
||||||
$('#drpFreightviewloc').val($("#Ftype"+userid).val());
|
$('#drpFreightviewloc').val($("#Ftype"+userid).val());
|
||||||
$('#NOOfTripslocview').val($("#NoTrip"+userid).val());
|
$('#NOOfTripslocview').val($("#NoTrip"+userid).val());
|
||||||
@ -6032,7 +6075,7 @@ function DeleteRow(rowid)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please select the MaterialCode');
|
alert('Please select the MaterialCode');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -6122,20 +6165,20 @@ var basicAmountRate = parseFloat($('#CapitalToatlOrder').val());
|
|||||||
{
|
{
|
||||||
if(document.getElementById('serviceTax').rows.length < 2)
|
if(document.getElementById('serviceTax').rows.length < 2)
|
||||||
{
|
{
|
||||||
swal('Please Select Line item to Create PO');
|
alert('Please Select Line item to Create PO');
|
||||||
$('#Deliverydt').focus();
|
$('#Deliverydt').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#Otherpayment').val()=='' && $('#PaymentMethod').val()=='PT08'){
|
else if($('#Otherpayment').val()=='' && $('#PaymentMethod').val()=='PT08'){
|
||||||
swal('Please Enter Other Payable Terms Description');
|
alert('Please Enter Other Payable Terms Description');
|
||||||
$('#Otherpayment').focus();
|
$('#Otherpayment').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if(parseInt(AvlBudAmt) < parseInt(basicAmountRate)) {
|
// else if(parseInt(AvlBudAmt) < parseInt(basicAmountRate)) {
|
||||||
swal('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.');
|
// alert('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
|
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
||||||
@ -6153,7 +6196,7 @@ var basicAmountRate = parseFloat($('#CapitalToatlOrder').val());
|
|||||||
success:function(data) {
|
success:function(data) {
|
||||||
if(data)
|
if(data)
|
||||||
{
|
{
|
||||||
swal(data);
|
alert(data);
|
||||||
$('#content').loader('hide');
|
$('#content').loader('hide');
|
||||||
|
|
||||||
$('#txtRowCount').val('');
|
$('#txtRowCount').val('');
|
||||||
@ -6168,7 +6211,7 @@ var basicAmountRate = parseFloat($('#CapitalToatlOrder').val());
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
$('#content').loader('hide');
|
$('#content').loader('hide');
|
||||||
swal("Error");
|
alert("Error");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -6216,19 +6259,19 @@ function clearAfterAddLineItemAdd(){
|
|||||||
|
|
||||||
if($('#EditReqnumber').val() == "0")
|
if($('#EditReqnumber').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Requisition Number');
|
alert('Please select the Requisition Number');
|
||||||
$('#EditReqnumber').focus();
|
$('#EditReqnumber').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#EditMaterialCode').val() == "0")
|
else if($('#EditMaterialCode').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Material Code');
|
alert('Please select the Material Code');
|
||||||
$('#EditMaterialCode').focus();
|
$('#EditMaterialCode').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#EditCostCenter').val() == "0")
|
else if($('#EditCostCenter').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the CostCenterCode');
|
alert('Please select the CostCenterCode');
|
||||||
$('#EditCostCenter').focus();
|
$('#EditCostCenter').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -6454,7 +6497,7 @@ var Freight=parseFloat($('#txtAfterFreightlocview').val() == '' ? '0.00' : $('#t
|
|||||||
//alert(ReqQuantity);
|
//alert(ReqQuantity);
|
||||||
if(EnterQuantity > ReqQuantity)
|
if(EnterQuantity > ReqQuantity)
|
||||||
{
|
{
|
||||||
swal('Your exceeding the Quantity from the Requisition Quantity:'+ RequistQuantity +'.Please adjust the Quantity to proceed further.');
|
alert('Your exceeding the Quantity from the Requisition Quantity:'+ RequistQuantity +'.Please adjust the Quantity to proceed further.');
|
||||||
|
|
||||||
$('#EditCPQuantity').focus();
|
$('#EditCPQuantity').focus();
|
||||||
return false;
|
return false;
|
||||||
@ -6744,43 +6787,43 @@ function validateEditCapitalTax()
|
|||||||
|
|
||||||
if($('#EditReqnumber').val() == "0")
|
if($('#EditReqnumber').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Requisition Number');
|
alert('Please select the Requisition Number');
|
||||||
$('#EditReqnumber').focus();
|
$('#EditReqnumber').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#EditCostCenter').val() == "0")
|
else if($('#EditCostCenter').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Cost center');
|
alert('Please select the Cost center');
|
||||||
$('#EditCostCenter').focus();
|
$('#EditCostCenter').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#EditMaterialCode').val() == "0")
|
else if($('#EditMaterialCode').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Material Code');
|
alert('Please select the Material Code');
|
||||||
$('#EditMaterialCode').focus();
|
$('#EditMaterialCode').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#EditCPQuantity').val() == '')
|
else if($('#EditCPQuantity').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Quantity value');
|
alert('Please Enter the Quantity value');
|
||||||
$('#EditCPQuantity').focus();
|
$('#EditCPQuantity').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#EditCPQuantity').val() == "0")
|
else if($('#EditCPQuantity').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please Enter the Valid Quantity value');
|
alert('Please Enter the Valid Quantity value');
|
||||||
$('#EditCPQuantity').focus();
|
$('#EditCPQuantity').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#EditCPRate').val() == '')
|
else if($('#EditCPRate').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate of the Item');
|
alert('Please Enter the Rate of the Item');
|
||||||
$('#EditCPRate').focus();
|
$('#EditCPRate').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#EditCPRate').val() == "0")
|
else if($('#EditCPRate').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please Enter the Valid Rate of the Item');
|
alert('Please Enter the Valid Rate of the Item');
|
||||||
$('#EditCPRate').focus();
|
$('#EditCPRate').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -6883,16 +6926,16 @@ var Freight=parseFloat($('#txtAfterFreightlocedit').val() == '' ? '0.00' : $('#t
|
|||||||
else{
|
else{
|
||||||
basicAmountRate=parseFloat(basicAmountRate)- parseFloat(discountRate);
|
basicAmountRate=parseFloat(basicAmountRate)- parseFloat(discountRate);
|
||||||
}
|
}
|
||||||
if(basicAmountRate > avalbudAmt)
|
// if(basicAmountRate > avalbudAmt)
|
||||||
{
|
// {
|
||||||
swal('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
// alert('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
$('#EditCPRate').focus();
|
// $('#EditCPRate').focus();
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
return true;
|
return true;
|
||||||
}
|
//}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -7305,7 +7348,7 @@ $('#drpFreight').change(function() {
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate value');
|
alert('Please Enter the Rate value');
|
||||||
$('#drpFreight').val("0");
|
$('#drpFreight').val("0");
|
||||||
$('#CPRate').focus();
|
$('#CPRate').focus();
|
||||||
}
|
}
|
||||||
@ -7346,7 +7389,7 @@ $('#drpEditFreight').change(function() {
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate value');
|
alert('Please Enter the Rate value');
|
||||||
$('#drpEditFreight').val("0");
|
$('#drpEditFreight').val("0");
|
||||||
$('#EditCPRate').focus();
|
$('#EditCPRate').focus();
|
||||||
}
|
}
|
||||||
@ -7387,7 +7430,7 @@ $('#drpViewFreight').change(function() {
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate value');
|
alert('Please Enter the Rate value');
|
||||||
$('#drpViewFreight').val("0");
|
$('#drpViewFreight').val("0");
|
||||||
$('#ViewCPRate').focus();
|
$('#ViewCPRate').focus();
|
||||||
}
|
}
|
||||||
@ -7402,7 +7445,7 @@ function calculateFreight(isEdit)
|
|||||||
|
|
||||||
if($('#AfterBasicPriceTax').val() == '')
|
if($('#AfterBasicPriceTax').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate value');
|
alert('Please Enter the Rate value');
|
||||||
$('#CPRate').focus();
|
$('#CPRate').focus();
|
||||||
$('#txtFreight').val('') ;
|
$('#txtFreight').val('') ;
|
||||||
return false;
|
return false;
|
||||||
@ -7414,7 +7457,7 @@ function calculateFreight(isEdit)
|
|||||||
var FreightType =$("#drpFreight").val();
|
var FreightType =$("#drpFreight").val();
|
||||||
if(FreightType == "0")
|
if(FreightType == "0")
|
||||||
{
|
{
|
||||||
swal('Please select Freight Type');
|
alert('Please select Freight Type');
|
||||||
$('#txtFreight').val('');
|
$('#txtFreight').val('');
|
||||||
$("#drpFreight").focus();
|
$("#drpFreight").focus();
|
||||||
}
|
}
|
||||||
@ -7447,7 +7490,7 @@ function calculateFreight(isEdit)
|
|||||||
else if(FreightType == '<?php echo PERTRIP;?>')
|
else if(FreightType == '<?php echo PERTRIP;?>')
|
||||||
{
|
{
|
||||||
if($('#NOOfTrips').val()==''){
|
if($('#NOOfTrips').val()==''){
|
||||||
swal('Please Enter No of Trip');
|
alert('Please Enter No of Trip');
|
||||||
|
|
||||||
$("#NOOfTrips").focus();
|
$("#NOOfTrips").focus();
|
||||||
$('#txtFreight').val(0)
|
$('#txtFreight').val(0)
|
||||||
@ -7482,7 +7525,7 @@ function calculateFreight(isEdit)
|
|||||||
|
|
||||||
if($('#ViewAfterBasicPriceTax').val() == '')
|
if($('#ViewAfterBasicPriceTax').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate value');
|
alert('Please Enter the Rate value');
|
||||||
$('#ViewCPRate').focus();
|
$('#ViewCPRate').focus();
|
||||||
$('#txtViewFreight').val('') ;
|
$('#txtViewFreight').val('') ;
|
||||||
return false;
|
return false;
|
||||||
@ -7494,7 +7537,7 @@ function calculateFreight(isEdit)
|
|||||||
var FreightType =$("#drpViewFreight").val();
|
var FreightType =$("#drpViewFreight").val();
|
||||||
if(FreightType == "0")
|
if(FreightType == "0")
|
||||||
{
|
{
|
||||||
swal('Please select Freight Type');
|
alert('Please select Freight Type');
|
||||||
$('#txtViewFreight').val('');
|
$('#txtViewFreight').val('');
|
||||||
$("#drpViewFreight").focus();
|
$("#drpViewFreight").focus();
|
||||||
}
|
}
|
||||||
@ -7524,7 +7567,7 @@ function calculateFreight(isEdit)
|
|||||||
else if(FreightType == '<?php echo PERTRIP;?>')
|
else if(FreightType == '<?php echo PERTRIP;?>')
|
||||||
{
|
{
|
||||||
if($('#ViewNOOfTrips').val()==''){
|
if($('#ViewNOOfTrips').val()==''){
|
||||||
swal('Please Enter No of Trip');
|
alert('Please Enter No of Trip');
|
||||||
|
|
||||||
$("#ViewNOOfTrips").focus();
|
$("#ViewNOOfTrips").focus();
|
||||||
$('#txtViewFreight').val(0)
|
$('#txtViewFreight').val(0)
|
||||||
@ -7593,7 +7636,7 @@ function calculateFreight(isEdit)
|
|||||||
else if(FreightType == '<?php echo PERTRIP;?>')
|
else if(FreightType == '<?php echo PERTRIP;?>')
|
||||||
{
|
{
|
||||||
if($('#NOOfTrips').val()==''){
|
if($('#NOOfTrips').val()==''){
|
||||||
swal('Please Enter No of Trip');
|
alert('Please Enter No of Trip');
|
||||||
|
|
||||||
$("#NOOfTrips").focus();
|
$("#NOOfTrips").focus();
|
||||||
$('#txtFreight').val(0)
|
$('#txtFreight').val(0)
|
||||||
@ -7658,7 +7701,7 @@ function calculateFreight(isEdit)
|
|||||||
else if(FreightType == '<?php echo PERTRIP;?>')
|
else if(FreightType == '<?php echo PERTRIP;?>')
|
||||||
{
|
{
|
||||||
if($('#EditNOOfTrips').val()==''){
|
if($('#EditNOOfTrips').val()==''){
|
||||||
swal('Please Enter No of Trip');
|
alert('Please Enter No of Trip');
|
||||||
|
|
||||||
$("#EditNOOfTrips").focus();
|
$("#EditNOOfTrips").focus();
|
||||||
$('#txtEditFreight').val(0)
|
$('#txtEditFreight').val(0)
|
||||||
@ -7691,7 +7734,7 @@ function calculateFreight(isEdit)
|
|||||||
{
|
{
|
||||||
if($('#EditAfterBasicPriceTax').val() == '')
|
if($('#EditAfterBasicPriceTax').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate value');
|
alert('Please Enter the Rate value');
|
||||||
$('#EditCPRate').focus();
|
$('#EditCPRate').focus();
|
||||||
$('#txtEditFreight').val('') ;
|
$('#txtEditFreight').val('') ;
|
||||||
return false;
|
return false;
|
||||||
@ -7703,7 +7746,7 @@ function calculateFreight(isEdit)
|
|||||||
var FreightType =$("#drpEditFreight").val();
|
var FreightType =$("#drpEditFreight").val();
|
||||||
if(FreightType == "0")
|
if(FreightType == "0")
|
||||||
{
|
{
|
||||||
swal('Please select Freight Type');
|
alert('Please select Freight Type');
|
||||||
$('#txtEditFreight').val('');
|
$('#txtEditFreight').val('');
|
||||||
$("#drpEditFreight").focus();
|
$("#drpEditFreight").focus();
|
||||||
}
|
}
|
||||||
@ -7733,7 +7776,7 @@ function calculateFreight(isEdit)
|
|||||||
else if(FreightType == '<?php echo PERTRIP;?>')
|
else if(FreightType == '<?php echo PERTRIP;?>')
|
||||||
{
|
{
|
||||||
if($('#EditNOOfTrips').val()==''){
|
if($('#EditNOOfTrips').val()==''){
|
||||||
swal('Please Enter No of Trip');
|
alert('Please Enter No of Trip');
|
||||||
|
|
||||||
$("#EditNOOfTrips").focus();
|
$("#EditNOOfTrips").focus();
|
||||||
$('#txtEditFreight').val(0)
|
$('#txtEditFreight').val(0)
|
||||||
@ -7790,7 +7833,7 @@ function calculateFreight(isEdit)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please Rate Field Value');
|
alert('Please Rate Field Value');
|
||||||
|
|
||||||
$('#CPRate').focus();
|
$('#CPRate').focus();
|
||||||
}
|
}
|
||||||
@ -7820,7 +7863,7 @@ $('#EditDiscountType').change(function() {
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please Select MaterialCode and Rate Field Value');
|
alert('Please Select MaterialCode and Rate Field Value');
|
||||||
$('#EditDiscountType').val("0");
|
$('#EditDiscountType').val("0");
|
||||||
$('#EditCPRate').focus();
|
$('#EditCPRate').focus();
|
||||||
}
|
}
|
||||||
@ -7837,7 +7880,7 @@ function calculateDiscount(isEdit)
|
|||||||
|
|
||||||
if($('#CPRate').val() == '')
|
if($('#CPRate').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate value');
|
alert('Please Enter the Rate value');
|
||||||
$('#CPRate').focus();
|
$('#CPRate').focus();
|
||||||
$('#txtDiscount').val('');
|
$('#txtDiscount').val('');
|
||||||
return false;
|
return false;
|
||||||
@ -7850,7 +7893,7 @@ function calculateDiscount(isEdit)
|
|||||||
|
|
||||||
if(DiscountType == "0")
|
if(DiscountType == "0")
|
||||||
{
|
{
|
||||||
swal('Please Select the discount Type');
|
alert('Please Select the discount Type');
|
||||||
$('#txtDiscount').val('');
|
$('#txtDiscount').val('');
|
||||||
$("#DiscountType").focus();
|
$("#DiscountType").focus();
|
||||||
}
|
}
|
||||||
@ -7896,7 +7939,7 @@ function calculateDiscount(isEdit)
|
|||||||
|
|
||||||
if(DiscountType == "0")
|
if(DiscountType == "0")
|
||||||
{
|
{
|
||||||
swal('Please Select the discount Type');
|
alert('Please Select the discount Type');
|
||||||
$('#txtEditDiscount').val('');
|
$('#txtEditDiscount').val('');
|
||||||
$("#EditDiscountType").focus();
|
$("#EditDiscountType").focus();
|
||||||
}
|
}
|
||||||
@ -8021,7 +8064,7 @@ $('#drpFreightloc').change(function()
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please Select MaterialCode and Rate Field Value');
|
alert('Please Select MaterialCode and Rate Field Value');
|
||||||
$('#drpFreightloc').val("0");
|
$('#drpFreightloc').val("0");
|
||||||
$('#Rate').focus();
|
$('#Rate').focus();
|
||||||
}
|
}
|
||||||
@ -8192,7 +8235,7 @@ $('#drpFreighteditloc').change(function()
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please Select MaterialCode and Rate Field Value');
|
alert('Please Select MaterialCode and Rate Field Value');
|
||||||
$('#drpFreighteditloc').val("0");
|
$('#drpFreighteditloc').val("0");
|
||||||
$('#Rate').focus();
|
$('#Rate').focus();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -73,6 +73,7 @@ foreach ($PaymentTerms as $TER)
|
|||||||
$ServiceDescription = '';
|
$ServiceDescription = '';
|
||||||
$CapitalRange = '';
|
$CapitalRange = '';
|
||||||
$otherPayment='';
|
$otherPayment='';
|
||||||
|
$BudgetType = '';
|
||||||
if(!empty($POMaster))
|
if(!empty($POMaster))
|
||||||
{
|
{
|
||||||
//print_r($POMaster);
|
//print_r($POMaster);
|
||||||
@ -106,6 +107,7 @@ if(!empty($POMaster))
|
|||||||
$revenuesubtype = $Req->POSubType;
|
$revenuesubtype = $Req->POSubType;
|
||||||
$insurencestatus = $Req->InsuranceStatus;
|
$insurencestatus = $Req->InsuranceStatus;
|
||||||
$insurenceno = $Req->InsuranceNumber;
|
$insurenceno = $Req->InsuranceNumber;
|
||||||
|
$BudgetType = $Req->BudgetType;
|
||||||
// echo $insurenceno;
|
// echo $insurenceno;
|
||||||
// echo $otherPayment;
|
// echo $otherPayment;
|
||||||
}
|
}
|
||||||
@ -204,6 +206,7 @@ if(!empty($RequistionDetails))
|
|||||||
var SchName = <?php echo json_encode($DeliverSchedule); ?>;
|
var SchName = <?php echo json_encode($DeliverSchedule); ?>;
|
||||||
var DelDt = '<?php echo $Deliverydt; ?>';
|
var DelDt = '<?php echo $Deliverydt; ?>';
|
||||||
var insurancestatus = '<?php echo $insurencestatus;?>';
|
var insurancestatus = '<?php echo $insurencestatus;?>';
|
||||||
|
var budgettype='<?php echo $BudgetType;?>';
|
||||||
var insuranceno = '<?php echo $insurenceno;?>';
|
var insuranceno = '<?php echo $insurenceno;?>';
|
||||||
var statuscheck='<?php echo $PONOStatus;?>';
|
var statuscheck='<?php echo $PONOStatus;?>';
|
||||||
|
|
||||||
@ -1928,10 +1931,16 @@ function calculatePackaging(isEdit)
|
|||||||
|
|
||||||
$('#IGSTAddModel').attr("style","display:none;");
|
$('#IGSTAddModel').attr("style","display:none;");
|
||||||
$('#SGSTAddModel').removeAttr("style");
|
$('#SGSTAddModel').removeAttr("style");
|
||||||
|
$('#RevenueIgst').val(0);
|
||||||
|
$('#RevenueAfterIgst').val(0);
|
||||||
|
$('#txttaxcheck').val(0);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
$('#EditSgst').val(0);
|
||||||
|
$('#EditAfterSgst').val(0);
|
||||||
|
$('#EditCgst').val(0);
|
||||||
|
$('#EditAfterCgst').val(0);
|
||||||
$('#CST').removeAttr("style");
|
$('#CST').removeAttr("style");
|
||||||
$('#TotICST').removeAttr("style");
|
$('#TotICST').removeAttr("style");
|
||||||
$('#Vat').attr("style","display:none;");
|
$('#Vat').attr("style","display:none;");
|
||||||
@ -1942,6 +1951,11 @@ function calculatePackaging(isEdit)
|
|||||||
$('#SGSTViewModel').attr("style","display:none;");
|
$('#SGSTViewModel').attr("style","display:none;");
|
||||||
$('#IGSTAddModel').removeAttr("style");
|
$('#IGSTAddModel').removeAttr("style");
|
||||||
$('#SGSTAddModel').attr("style","display:none;");
|
$('#SGSTAddModel').attr("style","display:none;");
|
||||||
|
$('#RevenueCgst').val(0);
|
||||||
|
$('#RevenueAfterCgst').val(0);
|
||||||
|
$('#RevenueSgst').val(0);
|
||||||
|
$('#RevenueAfterIgst').val(0);
|
||||||
|
$('#txttaxcheck').val(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
@ -2084,16 +2098,16 @@ function validateEditExceedLimit()
|
|||||||
var basicAmountRate = parseFloat($('#txtEditBasicValue').val());
|
var basicAmountRate = parseFloat($('#txtEditBasicValue').val());
|
||||||
var totalAmount = parseFloat($('#txtEditTotalOrderValue').val());
|
var totalAmount = parseFloat($('#txtEditTotalOrderValue').val());
|
||||||
|
|
||||||
if(basicAmountRate > avalbudAmt)// || totalAmount > avalbudAmt)
|
// if(basicAmountRate > avalbudAmt)// || totalAmount > avalbudAmt)
|
||||||
{
|
// {
|
||||||
swal('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
// swal('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
$('#EditRate').focus();
|
// $('#EditRate').focus();
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
return true;
|
return true;
|
||||||
}
|
// }
|
||||||
|
|
||||||
}
|
}
|
||||||
function calculateEditTotalValue()
|
function calculateEditTotalValue()
|
||||||
@ -2518,6 +2532,29 @@ function calculateEditTaxValue()
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-2" style="padding-right: 0px;">
|
||||||
|
<label for="BudgetType">Budget Type</label>
|
||||||
|
<select id='BudgetType' name='BudgetType'>
|
||||||
|
<?php if($BudgetType== 'CAPITAL')
|
||||||
|
{
|
||||||
|
$opt1='CAPITAL';
|
||||||
|
$opt2='REVENUE';
|
||||||
|
}
|
||||||
|
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$opt1='REVENUE';
|
||||||
|
$opt2='CAPITAL';
|
||||||
|
} ?>
|
||||||
|
|
||||||
|
|
||||||
|
<option value=<?php echo $opt1;?>><?php echo $opt1;?></option>
|
||||||
|
<option value=<?php echo $opt2;?>><?php echo $opt2;?></option>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -4123,6 +4160,10 @@ function calculateEditTaxValue()
|
|||||||
<input type="hidden" name="txtRowCount" id="txtRowCount" value="<?php echo $index;?>">
|
<input type="hidden" name="txtRowCount" id="txtRowCount" value="<?php echo $index;?>">
|
||||||
<input type="hidden" name="txtDeletedRow" id="txtDeletedRow" />
|
<input type="hidden" name="txtDeletedRow" id="txtDeletedRow" />
|
||||||
<input type="hidden" name="txtPONO" id="txtPONO" value="<?php echo $PONO; ?>"/>
|
<input type="hidden" name="txtPONO" id="txtPONO" value="<?php echo $PONO; ?>"/>
|
||||||
|
<input type="hidden" name="txttaxcheck" id="txttaxcheck" value=""/>
|
||||||
|
|
||||||
|
<input type="hidden" name="Budget" id="Budget" value="<?php echo $BudgetType; ?>" />
|
||||||
|
|
||||||
<?php if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED || $PONOStatus == REQITEM_Emergency_PO_CREATED ) {
|
<?php if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED || $PONOStatus == REQITEM_Emergency_PO_CREATED ) {
|
||||||
if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED){?>
|
if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED){?>
|
||||||
<a class="btn btn-primary Save" ID="Save" onclick="Save(0)" > <span class="bold">Save</span></a> <?php }?>
|
<a class="btn btn-primary Save" ID="Save" onclick="Save(0)" > <span class="bold">Save</span></a> <?php }?>
|
||||||
@ -4178,6 +4219,17 @@ function calculateEditTaxValue()
|
|||||||
<script>
|
<script>
|
||||||
var index = <?php echo $index; ?>;
|
var index = <?php echo $index; ?>;
|
||||||
var userid = '';
|
var userid = '';
|
||||||
|
var taxcheck=0;
|
||||||
|
|
||||||
|
$("#BudgetType").change(function(){
|
||||||
|
|
||||||
|
var aa = $("#BudgetType option:selected").text();
|
||||||
|
|
||||||
|
$('#Budget').val(aa);
|
||||||
|
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
$("#REVENUE").on("shown.bs.modal", function(e) {
|
$("#REVENUE").on("shown.bs.modal", function(e) {
|
||||||
|
|
||||||
@ -4186,7 +4238,7 @@ $("#REVENUE").on("shown.bs.modal", function(e) {
|
|||||||
|
|
||||||
$('.AddRevenue').click(function(){
|
$('.AddRevenue').click(function(){
|
||||||
tinyMCE.triggerSave();
|
tinyMCE.triggerSave();
|
||||||
if(validateRevenueTax() && validateExceedLimit() && ExceedQuantityCheck())
|
if(validateRevenueTax() && ExceedQuantityCheck())
|
||||||
{
|
{
|
||||||
var temp = parseInt(index)+1;
|
var temp = parseInt(index)+1;
|
||||||
var Reqnumber = $('#ReqNo').val();
|
var Reqnumber = $('#ReqNo').val();
|
||||||
@ -4371,9 +4423,15 @@ clearRevenueModalFields();
|
|||||||
$('#PackVal'+userid).val(PackVal);
|
$('#PackVal'+userid).val(PackVal);
|
||||||
$('#AfterPackVal'+userid).val(AfterPackVal);
|
$('#AfterPackVal'+userid).val(AfterPackVal);
|
||||||
$('#RevenueCgst'+userid).val(Cgst);
|
$('#RevenueCgst'+userid).val(Cgst);
|
||||||
|
var taxvaluecheck = $('#txttaxcheck').val();
|
||||||
|
if(taxvaluecheck == 1)
|
||||||
|
{
|
||||||
|
$('#RevenueAfterSgst'+userid).val(0);
|
||||||
|
$('#RevenueSgst'+userid).val(0);
|
||||||
|
}
|
||||||
$('#RevenueAfterCgst'+userid).val(AfterCgst);
|
$('#RevenueAfterCgst'+userid).val(AfterCgst);
|
||||||
$('#RevenueAfterSgst'+userid).val(AfterSgst);
|
//$('#RevenueAfterSgst'+userid).val(AfterSgst);
|
||||||
$('#RevenueSgst'+userid).val(Sgst);
|
//$('#RevenueSgst'+userid).val(Sgst);
|
||||||
$('#RevenueIgst'+userid).val(Igst);
|
$('#RevenueIgst'+userid).val(Igst);
|
||||||
$('#RevenueAfterIgst'+userid).val(AfterIgst);
|
$('#RevenueAfterIgst'+userid).val(AfterIgst);
|
||||||
$('#FreightType'+userid).val(FreightType);
|
$('#FreightType'+userid).val(FreightType);
|
||||||
@ -4717,17 +4775,17 @@ function validateBudgetExceedLimit()
|
|||||||
{
|
{
|
||||||
//alert(data);
|
//alert(data);
|
||||||
avalbudAmt = parseFloat(data);
|
avalbudAmt = parseFloat(data);
|
||||||
if(basicAmountRate > avalbudAmt || totalAmount > avalbudAmt)
|
// if(basicAmountRate > avalbudAmt || totalAmount > avalbudAmt)
|
||||||
{
|
// {
|
||||||
swal('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
// swal('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
$('#Rate').focus();
|
// $('#Rate').focus();
|
||||||
return false;
|
// return false;
|
||||||
|
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
return true;
|
return true;
|
||||||
}
|
//}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4928,11 +4986,11 @@ var totaldiscount = $('#txtTotalDiscount').val();
|
|||||||
//{
|
//{
|
||||||
// return false;
|
// return false;
|
||||||
//}
|
//}
|
||||||
else if(parseInt(AvlBudAmt) < (parseInt(txtTotalbasicamount)- parseInt(totaldiscount))){
|
// else if(parseInt(AvlBudAmt) < (parseInt(txtTotalbasicamount)- parseInt(totaldiscount))){
|
||||||
swal('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.');
|
// swal('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
|
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
|
|
||||||
else if($('#Otherpayment').val()=='' && $('#PaymentTerms').val()=='PT08'){
|
else if($('#Otherpayment').val()=='' && $('#PaymentTerms').val()=='PT08'){
|
||||||
swal('Please Enter Payable Terms Description');
|
swal('Please Enter Payable Terms Description');
|
||||||
@ -5254,6 +5312,10 @@ $("#EDITREVENUE").on("shown.bs.modal", function(e) {
|
|||||||
$('#txtEditInsurance').val($('#Insval'+userid).val());
|
$('#txtEditInsurance').val($('#Insval'+userid).val());
|
||||||
|
|
||||||
$('#txtEditTotalOrderValue').val($('#TotalOrderValue'+userid).val());
|
$('#txtEditTotalOrderValue').val($('#TotalOrderValue'+userid).val());
|
||||||
|
|
||||||
|
var x = $("input:radio[name='Range']:checked").val();
|
||||||
|
|
||||||
|
|
||||||
$('#EditAfterCgst').val($('#RevenueAfterCgst'+userid).val());
|
$('#EditAfterCgst').val($('#RevenueAfterCgst'+userid).val());
|
||||||
$('#EditAfterSgst').val($('#RevenueAfterSgst'+userid).val());
|
$('#EditAfterSgst').val($('#RevenueAfterSgst'+userid).val());
|
||||||
$('#EditAfterIgst').val($('#RevenueAfterIgst'+userid).val());
|
$('#EditAfterIgst').val($('#RevenueAfterIgst'+userid).val());
|
||||||
|
|||||||
@ -5,14 +5,11 @@ $Value='';
|
|||||||
$EXCRATE=0;
|
$EXCRATE=0;
|
||||||
$parentPO= '';
|
$parentPO= '';
|
||||||
$ServiceDescription='';
|
$ServiceDescription='';
|
||||||
//$Value="$";
|
|
||||||
//echo $ExchangeRate;
|
|
||||||
//echo $Currency;
|
|
||||||
//echo $unicode;
|
|
||||||
$Value=$unicode;
|
$Value=$unicode;
|
||||||
//echo $Value;
|
|
||||||
$Currencycode=$currencycode;
|
$Currencycode=$currencycode;
|
||||||
//echo $Currencycode;
|
|
||||||
$Terms='';
|
$Terms='';
|
||||||
$DeliverySchedule='';
|
$DeliverySchedule='';
|
||||||
|
|
||||||
@ -20,7 +17,7 @@ foreach ($CurrencyDetail as $Detail)
|
|||||||
{
|
{
|
||||||
$Cur=$Detail->Currency_Code.' '.' - '.' '.$Detail->Country_and_Currency;
|
$Cur=$Detail->Currency_Code.' '.' - '.' '.$Detail->Country_and_Currency;
|
||||||
}
|
}
|
||||||
//echo $Cur;
|
|
||||||
|
|
||||||
|
|
||||||
foreach ($PaymentTerms as $TER)
|
foreach ($PaymentTerms as $TER)
|
||||||
@ -121,6 +118,7 @@ $SupplierRef='';
|
|||||||
$SupOfferno='';
|
$SupOfferno='';
|
||||||
$Otherref='';
|
$Otherref='';
|
||||||
$Fincap='';
|
$Fincap='';
|
||||||
|
$BudgetType = '';
|
||||||
|
|
||||||
if(!empty($POMaster))
|
if(!empty($POMaster))
|
||||||
{
|
{
|
||||||
@ -168,6 +166,7 @@ if(!empty($POMaster))
|
|||||||
$Insurance=$Req->InsuranceStatus;
|
$Insurance=$Req->InsuranceStatus;
|
||||||
$InsuranceNo=$Req->InsuranceNumber;
|
$InsuranceNo=$Req->InsuranceNumber;
|
||||||
$Importoption=$Req->POSubType;
|
$Importoption=$Req->POSubType;
|
||||||
|
$BudgetType = $Req->BudgetType;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -829,6 +828,34 @@ tinymce.init({
|
|||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-2" style="padding-right: 0px;">
|
||||||
|
<label for="BudgetType">Budget Type</label>
|
||||||
|
<select id='BudgetType' name='BudgetType'>
|
||||||
|
<?php if($BudgetType== 'CAPITAL')
|
||||||
|
{
|
||||||
|
$opt1='CAPITAL';
|
||||||
|
$opt2='REVENUE';
|
||||||
|
}
|
||||||
|
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$opt1='REVENUE';
|
||||||
|
$opt2='CAPITAL';
|
||||||
|
} ?>
|
||||||
|
|
||||||
|
|
||||||
|
<option value=<?php echo $opt1;?>><?php echo $opt1;?></option>
|
||||||
|
<option value=<?php echo $opt2;?>><?php echo $opt2;?></option>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -860,7 +887,7 @@ if($PONOStatus == PO_RELEASED)
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:1091px;font-size:12px;">
|
<div class="modal-content" style="width:1091px;font-size:12px;">
|
||||||
<div class="modal-header" style="background-color: #3c8dbc;color:#fff;">
|
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
||||||
|
|
||||||
<center><h4>Add Import Purchase Order Item </h4></center>
|
<center><h4>Add Import Purchase Order Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
@ -1473,7 +1500,7 @@ echo form_textarea($data);
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:1091px;font-size:12px;">
|
<div class="modal-content" style="width:1091px;font-size:12px;">
|
||||||
<div class="modal-header" style="background-color: #3c8dbc;color:#fff;">
|
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
||||||
|
|
||||||
<center><h4>Edit Import Purchase Order Item </h4></center>
|
<center><h4>Edit Import Purchase Order Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
@ -2069,7 +2096,7 @@ echo form_textarea($data);
|
|||||||
<!-- Modal content-->
|
<!-- Modal content-->
|
||||||
<form>
|
<form>
|
||||||
<div class="modal-content" style="width:1091px; font-size: 12px;">
|
<div class="modal-content" style="width:1091px; font-size: 12px;">
|
||||||
<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">×</button>
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||||
<center><h4>View Import Purchase Order Item </h4></center>
|
<center><h4>View Import Purchase Order Item </h4></center>
|
||||||
</div>
|
</div>
|
||||||
@ -3030,6 +3057,8 @@ echo form_textarea($data);
|
|||||||
<input type="hidden" name="txtRow" id="txtRow" value="<?php echo $index;?>"/>
|
<input type="hidden" name="txtRow" id="txtRow" value="<?php echo $index;?>"/>
|
||||||
<input type="hidden" name="txtPONO" id="txtPONO" value="<?php echo $PONO; ?>"/>
|
<input type="hidden" name="txtPONO" id="txtPONO" value="<?php echo $PONO; ?>"/>
|
||||||
|
|
||||||
|
<input type="hidden" name="Budget" id="Budget" value="<?php echo $BudgetType; ?>" />
|
||||||
|
|
||||||
|
|
||||||
<?php if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED ) {
|
<?php if($PONOStatus == PO_DRAFT || $PONOStatus == PO_CREATED ) {
|
||||||
if($PONOStatus == PO_DRAFT){?>
|
if($PONOStatus == PO_DRAFT){?>
|
||||||
@ -3138,6 +3167,18 @@ var NilType = '<?php echo NILTYPE;?>';
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$("#BudgetType").change(function(){
|
||||||
|
|
||||||
|
var aa = $("#BudgetType option:selected").text();
|
||||||
|
|
||||||
|
$('#Budget').val(aa);
|
||||||
|
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$('#Importoption').attr("style", "pointer-events: none;");
|
$('#Importoption').attr("style", "pointer-events: none;");
|
||||||
|
|
||||||
$('#Insurance').change(function() {
|
$('#Insurance').change(function() {
|
||||||
@ -3355,7 +3396,7 @@ $('#drpSupplier').change(function() {
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please select the SupplierID');
|
alert('Please select the SupplierID');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3445,7 +3486,7 @@ $("#txtBasicValue").val('');
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please select the Requisition Number');
|
alert('Please select the Requisition Number');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
id = '';
|
id = '';
|
||||||
@ -3487,7 +3528,7 @@ $("#txtBasicValue").val('');
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please select the MaterialCode');
|
alert('Please select the MaterialCode');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3528,7 +3569,7 @@ function EditQtyZerocheck()
|
|||||||
{
|
{
|
||||||
if(($('#EditRate').val()=="0")||$('#EditQuantity').val()=="0"||($('#EditRate').val()=='')||$('#EditQuantity').val()=='')
|
if(($('#EditRate').val()=="0")||$('#EditQuantity').val()=="0"||($('#EditRate').val()=='')||$('#EditQuantity').val()=='')
|
||||||
{
|
{
|
||||||
swal('Please Enter A Valid Number for Rate and Quantity');
|
alert('Please Enter A Valid Number for Rate and Quantity');
|
||||||
$('#EdittxtBasicValue').val(0);
|
$('#EdittxtBasicValue').val(0);
|
||||||
$('#EditimBasicPrice').val(0);
|
$('#EditimBasicPrice').val(0);
|
||||||
var txtexchangerate=parseFloat($('#ExchangeRate').val());
|
var txtexchangerate=parseFloat($('#ExchangeRate').val());
|
||||||
@ -3576,7 +3617,7 @@ function QtyZerocheck()
|
|||||||
{
|
{
|
||||||
if(($('#Rate').val()=="0")||$('#Quantity').val()=="0"||($('#Rate').val()=='')||$('#Quantity').val()=='')
|
if(($('#Rate').val()=="0")||$('#Quantity').val()=="0"||($('#Rate').val()=='')||$('#Quantity').val()=='')
|
||||||
{
|
{
|
||||||
swal('Please Enter A Valid Number for Rate and Quantity');
|
alert('Please Enter A Valid Number for Rate and Quantity');
|
||||||
$('#txtBasicValue').val(0);
|
$('#txtBasicValue').val(0);
|
||||||
$('#imBasicPrice').val(0);
|
$('#imBasicPrice').val(0);
|
||||||
$('#ExchangeRt').val(0);
|
$('#ExchangeRt').val(0);
|
||||||
@ -3598,19 +3639,19 @@ function Ratechange()
|
|||||||
//alert();
|
//alert();
|
||||||
if($('#ReqNo').val() == "0")
|
if($('#ReqNo').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Requisition Number');
|
alert('Please select the Requisition Number');
|
||||||
$('#ReqNo').focus();
|
$('#ReqNo').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#MaterialCode').val() == "0")
|
else if($('#MaterialCode').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Material Code');
|
alert('Please select the Material Code');
|
||||||
$('#MaterialCode').focus();
|
$('#MaterialCode').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#CostCenter').val() == "0")
|
else if($('#CostCenter').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the CostCenterCode');
|
alert('Please select the CostCenterCode');
|
||||||
$('#CostCenter').focus();
|
$('#CostCenter').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -3799,7 +3840,7 @@ function ExceedEditQuantityCheck()
|
|||||||
//var ReqQuantity=parseFloat($('#EditQuantity').val());
|
//var ReqQuantity=parseFloat($('#EditQuantity').val());
|
||||||
if(EnterQuantity > ReqQuantity)
|
if(EnterQuantity > ReqQuantity)
|
||||||
{
|
{
|
||||||
swal('Your exceeding the Quantity from the Requisition Quantity:'+ RequistQuantity +'.Please adjust the Quantity to proceed further.');
|
alert('Your exceeding the Quantity from the Requisition Quantity:'+ RequistQuantity +'.Please adjust the Quantity to proceed further.');
|
||||||
$('#EditQuantity').focus();
|
$('#EditQuantity').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -4300,7 +4341,7 @@ function ExceedQuantityCheck()
|
|||||||
var ReqQuantity = parseFloat(RequistQuantity);
|
var ReqQuantity = parseFloat(RequistQuantity);
|
||||||
if(EnterQuantity > ReqQuantity)
|
if(EnterQuantity > ReqQuantity)
|
||||||
{
|
{
|
||||||
swal('Your exceeding the Quantity from the Requisition Quantity:'+ RequistQuantity +'.Please adjust the Quantity to proceed further.');
|
alert('Your exceeding the Quantity from the Requisition Quantity:'+ RequistQuantity +'.Please adjust the Quantity to proceed further.');
|
||||||
//$('#Quantity').val(RequistQuantity);
|
//$('#Quantity').val(RequistQuantity);
|
||||||
$('#Quantity').focus();
|
$('#Quantity').focus();
|
||||||
return false;
|
return false;
|
||||||
@ -4330,16 +4371,16 @@ function validateEditExceedLimit()
|
|||||||
exp=basicAmountRate*exchangerate;
|
exp=basicAmountRate*exchangerate;
|
||||||
//console.log(exp);
|
//console.log(exp);
|
||||||
|
|
||||||
if(exp > totavlbud || totalAmount > totavlbud)
|
// if(exp > totavlbud || totalAmount > totavlbud)
|
||||||
{
|
// {
|
||||||
swal('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
// alert('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
$('#EditRate').focus();
|
// $('#EditRate').focus();
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
return true;
|
return true;
|
||||||
}
|
//}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4368,16 +4409,16 @@ var totavlbud=avalbudAmt+Sum;
|
|||||||
exp=basicAmountRate*exchangerate;
|
exp=basicAmountRate*exchangerate;
|
||||||
//console.log(exp);
|
//console.log(exp);
|
||||||
|
|
||||||
if(exp > totavlbud || totalAmount > totavlbud)
|
// if(exp > totavlbud || totalAmount > totavlbud)
|
||||||
{
|
// {
|
||||||
swal('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
// alert('Basic amount is exceeding the Budget Limit.Please adjust the product value.');
|
||||||
$('#Rate').focus();
|
// $('#Rate').focus();
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
return true;
|
return true;
|
||||||
}
|
//}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4737,37 +4778,37 @@ function validateImport()
|
|||||||
//alert();
|
//alert();
|
||||||
if($('#ReqNo').val() == "0")
|
if($('#ReqNo').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Requisition Number');
|
alert('Please select the Requisition Number');
|
||||||
$('#ReqNo').focus();
|
$('#ReqNo').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#CostCenter').val() == "0")
|
else if($('#CostCenter').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Cost center');
|
alert('Please select the Cost center');
|
||||||
$('#CostCenter').focus();
|
$('#CostCenter').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#MaterialCode').val() == "0")
|
else if($('#MaterialCode').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please select the Material Code');
|
alert('Please select the Material Code');
|
||||||
$('#MaterialCode').focus();
|
$('#MaterialCode').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#Quantity').val() == '')
|
else if($('#Quantity').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Quantity value');
|
alert('Please Enter the Quantity value');
|
||||||
$('#Quantity').focus();
|
$('#Quantity').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#Rate').val() == '')
|
else if($('#Rate').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate of the Item');
|
alert('Please Enter the Rate of the Item');
|
||||||
$('#Rate').focus();
|
$('#Rate').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#imBasicPrice').val()=='')
|
else if($('#imBasicPrice').val()=='')
|
||||||
{
|
{
|
||||||
swal('Please Enter Basic Price In Us');
|
alert('Please Enter Basic Price In Us');
|
||||||
$('#imBasicPrice').focus();
|
$('#imBasicPrice').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -5561,11 +5602,11 @@ function DeleteRow(rowid)
|
|||||||
if(data)
|
if(data)
|
||||||
{
|
{
|
||||||
$('#content').loader('hide');
|
$('#content').loader('hide');
|
||||||
swal(data);
|
alert(data);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal("Error");
|
alert("Error");
|
||||||
}
|
}
|
||||||
|
|
||||||
}});
|
}});
|
||||||
@ -5681,16 +5722,16 @@ function Budgetcheck()
|
|||||||
var totordring=totalorderedamount*Exchange;
|
var totordring=totalorderedamount*Exchange;
|
||||||
var TotalSum=totavlbud;
|
var TotalSum=totavlbud;
|
||||||
//console.log(TotalSum);
|
//console.log(TotalSum);
|
||||||
if(totordring>TotalSum)
|
// if(totordring>TotalSum)
|
||||||
{
|
// {
|
||||||
swal('You are Exceeding The Budget');
|
// alert('You are Exceeding The Budget');
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
|
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
return true;
|
return true;
|
||||||
}
|
//}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -5741,7 +5782,7 @@ if(validate()&&Budgetcheck())
|
|||||||
if(document.getElementById('ImportTax').rows.length <= 0)
|
if(document.getElementById('ImportTax').rows.length <= 0)
|
||||||
{
|
{
|
||||||
|
|
||||||
swal('Please Select Line item to Create PO');
|
alert('Please Select Line item to Create PO');
|
||||||
$('#Deliverydt').focus();
|
$('#Deliverydt').focus();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -5759,7 +5800,7 @@ if(validate()&&Budgetcheck())
|
|||||||
if(data)
|
if(data)
|
||||||
{
|
{
|
||||||
$('#content').loader('hide');
|
$('#content').loader('hide');
|
||||||
swal(data);
|
alert(data);
|
||||||
$('#txtRowCount').val('');
|
$('#txtRowCount').val('');
|
||||||
$('#txtDeletedRow').val('');
|
$('#txtDeletedRow').val('');
|
||||||
//$('#SpcialInstruction').val('');
|
//$('#SpcialInstruction').val('');
|
||||||
@ -5769,7 +5810,7 @@ if(validate()&&Budgetcheck())
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal("Error");
|
alert("Error");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -5892,7 +5933,7 @@ $('#edittxtAfterFreight').val('');
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please Select MaterialCode and Rate Field Value');
|
alert('Please Select MaterialCode and Rate Field Value');
|
||||||
$('#drpEditFreight').val("0");
|
$('#drpEditFreight').val("0");
|
||||||
$('#EditRate').focus();
|
$('#EditRate').focus();
|
||||||
}
|
}
|
||||||
@ -5940,7 +5981,7 @@ if($('#Rate').val() != '' && $('#MaterialCode').val() != "0" )
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
swal('Please Select MaterialCode and Rate Field Value');
|
alert('Please Select MaterialCode and Rate Field Value');
|
||||||
$('#drpaddFreight').val("0");
|
$('#drpaddFreight').val("0");
|
||||||
$('#Rate').focus();
|
$('#Rate').focus();
|
||||||
}
|
}
|
||||||
@ -5960,14 +6001,14 @@ function calculateFreight(isEdit)
|
|||||||
{ //alert();
|
{ //alert();
|
||||||
if($('#MaterialCode').val() == "0")
|
if($('#MaterialCode').val() == "0")
|
||||||
{
|
{
|
||||||
swal('Please Select the Material Code');
|
alert('Please Select the Material Code');
|
||||||
$('#MaterialCode').focus();
|
$('#MaterialCode').focus();
|
||||||
$('#txtFreight').val('') ;
|
$('#txtFreight').val('') ;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#Rate').val() == '')
|
else if($('#Rate').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate value');
|
alert('Please Enter the Rate value');
|
||||||
$('#Rate').focus();
|
$('#Rate').focus();
|
||||||
$('#addtxtFreight').val('') ;
|
$('#addtxtFreight').val('') ;
|
||||||
return false;
|
return false;
|
||||||
@ -5979,7 +6020,7 @@ function calculateFreight(isEdit)
|
|||||||
var FreightType =$("#drpaddFreight").val();
|
var FreightType =$("#drpaddFreight").val();
|
||||||
if(FreightType == "0")
|
if(FreightType == "0")
|
||||||
{
|
{
|
||||||
swal('Please select Freight Type');
|
alert('Please select Freight Type');
|
||||||
$('#addtxtFreight').val('');
|
$('#addtxtFreight').val('');
|
||||||
$("#drpaddFreight").focus();
|
$("#drpaddFreight").focus();
|
||||||
}
|
}
|
||||||
@ -6010,7 +6051,7 @@ function calculateFreight(isEdit)
|
|||||||
{
|
{
|
||||||
if($('#addNOOfTrips').val()=='')
|
if($('#addNOOfTrips').val()=='')
|
||||||
{
|
{
|
||||||
swal('Please Enter No of Trip');
|
alert('Please Enter No of Trip');
|
||||||
|
|
||||||
$("#addNOOfTrips").focus();
|
$("#addNOOfTrips").focus();
|
||||||
$('#addtxtFreight').val(0)
|
$('#addtxtFreight').val(0)
|
||||||
@ -6053,14 +6094,14 @@ function calculateFreight(isEdit)
|
|||||||
// alert('af');
|
// alert('af');
|
||||||
if($('#EditMaterialCode').val() == '')
|
if($('#EditMaterialCode').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Select the Material Code');
|
alert('Please Select the Material Code');
|
||||||
$('#EditMaterialCode').focus();
|
$('#EditMaterialCode').focus();
|
||||||
$('#edittxtFreight').val('');
|
$('#edittxtFreight').val('');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if($('#EditRate').val() == '')
|
else if($('#EditRate').val() == '')
|
||||||
{
|
{
|
||||||
swal('Please Enter the Rate value');
|
alert('Please Enter the Rate value');
|
||||||
$('#EditRate').focus();
|
$('#EditRate').focus();
|
||||||
$('#edittxtFreight').val('');
|
$('#edittxtFreight').val('');
|
||||||
return false;
|
return false;
|
||||||
@ -6071,7 +6112,7 @@ function calculateFreight(isEdit)
|
|||||||
var FreightType =$("#drpeditFreight").val();
|
var FreightType =$("#drpeditFreight").val();
|
||||||
if(FreightType == "0")
|
if(FreightType == "0")
|
||||||
{
|
{
|
||||||
swal('Please select Freight Type');
|
alert('Please select Freight Type');
|
||||||
$('#edittxtFreight').val('');
|
$('#edittxtFreight').val('');
|
||||||
$("#drpeditFreight").focus();
|
$("#drpeditFreight").focus();
|
||||||
}
|
}
|
||||||
@ -6101,7 +6142,7 @@ function calculateFreight(isEdit)
|
|||||||
else if(FreightType == '<?php echo PERTRIP;?>')
|
else if(FreightType == '<?php echo PERTRIP;?>')
|
||||||
{
|
{
|
||||||
if($('#editNOOfTrips').val()==''){
|
if($('#editNOOfTrips').val()==''){
|
||||||
swal('Please Enter No of Trip');
|
alert('Please Enter No of Trip');
|
||||||
|
|
||||||
$("#editNOOfTrips").focus();
|
$("#editNOOfTrips").focus();
|
||||||
$('#edittxtFreight').val(0)
|
$('#edittxtFreight').val(0)
|
||||||
@ -6142,7 +6183,7 @@ function calculateFreight(isEdit)
|
|||||||
var FreightType =$("#drpviewFreight").val();
|
var FreightType =$("#drpviewFreight").val();
|
||||||
if(FreightType == "0")
|
if(FreightType == "0")
|
||||||
{
|
{
|
||||||
swal('Please select Freight Type');
|
alert('Please select Freight Type');
|
||||||
$('#viewtxtFreight').val('');
|
$('#viewtxtFreight').val('');
|
||||||
$("#drpviewFreight").focus();
|
$("#drpviewFreight").focus();
|
||||||
}
|
}
|
||||||
@ -6172,7 +6213,7 @@ function calculateFreight(isEdit)
|
|||||||
else if(FreightType == '<?php echo PERTRIP;?>')
|
else if(FreightType == '<?php echo PERTRIP;?>')
|
||||||
{
|
{
|
||||||
if($('#viewNOOfTrips').val()==''){
|
if($('#viewNOOfTrips').val()==''){
|
||||||
swal('Please Enter No of Trip');
|
alert('Please Enter No of Trip');
|
||||||
|
|
||||||
$("#viewNOOfTrips").focus();
|
$("#viewNOOfTrips").focus();
|
||||||
$('#viewtxtFreight').val(0)
|
$('#viewtxtFreight').val(0)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user