igr alert show

This commit is contained in:
venbatechnologies 2018-07-05 16:42:38 +05:30
parent 231096bd85
commit d59ee2c796
4 changed files with 88 additions and 7 deletions

View File

@ -541,6 +541,26 @@ foreach ($igrvalue as $value) {
$RevenueTaxList = array('LineItemNo'=>$LineItemNo, 'DiscountType'=>$DiscountType,'DiscountValue'=>$DiscountValue,'AfterDiscount'=>$AfterDiscount,'PackagingType'=>$PackagingType,'PackagingValue'=>$PackagingValue,'PackagingCalulatedOn'=>$PackagingOption,'AfterPackagingValue'=>$AfterPackagingValue,'FreightType'=>$FreightType,'NoOfTrip'=>$NoofTrips,'FreightValue'=>$FreightValue,'AfterFreightValue'=>$AfterFreightValue,'SGST'=>$VatValue,'AfterSGST'=>$AfterVatValue,'CGST'=>$GSTValue,'AfterCGST'=>$AfterGSTValue,'IGST'=>$OtherTaxValue,'AfterIGST'=>$AfterOtherTaxValue,'Insurance'=>$InsuranceValue,'TotalValue'=>$TotalOrderValue, 'CreatedBy'=>$updatedBy,'CreatedDate'=>$updateddt);
$RevenueList = $this->purchaseorder_model->addRevenueTax($RevenueTaxList);
if($Quantity == $RecQtyvalue )
{
$Newstatus = array('Status'=>IGR_CREATED);
$this->purchaseorder_model-> POLineItemsupdatestatus($NewPO,$Newstatus);
$Newstat = array('Status'=>IGR_CREATED);
$this->purchaseorder_model->pomasterupdatestatus($NewPO,$Newstat);
}
else if($Quantity != $RecQtyvalue )
{
$Newstatus = array('Status'=>POLINEITEM_IGRPARTIAL_CREATED);
$this->purchaseorder_model->POLineItemsupdatestatus($NewPO,$Newstatus);
$Newstat = array('Status'=>PO_RELEASED);
$this->purchaseorder_model->pomasterupdatestatus($NewPO,$Newstat);
}
}
@ -777,7 +797,27 @@ foreach ($igrvalue as $value) {
$ServiceTaxList = array('LineItemNo'=>$LineItemNo,'CGST'=>$CGST,'After_CGST'=>$AfterCGST,'SGST'=>$SGST,'After_SGST'=>$AfterSGST,'IGST'=>$IGST,'After_IGST'=>$AfterIGST,'otherallowance'=>$otherallowance, 'TotalValue'=>$TotalOrderValue, 'CreatedBy'=>$updatedBy,'CreatedDate'=>$updateddt);
$ServiceList =$this->purchaseorder_model->addServiceTax($ServiceTaxList);
if($Quantity == $RecQtyvalue )
{
$Newstatus = array('Status'=>IGR_CREATED);
$this->purchaseorder_model-> POLineItemsupdatestatus($NewPO,$Newstatus);
$Newstat = array('Status'=>IGR_CREATED);
$this->purchaseorder_model->pomasterupdatestatus($NewPO,$Newstat);
}
else if($Quantity != $RecQtyvalue )
{
$Newstatus = array('Status'=>POLINEITEM_IGRPARTIAL_CREATED);
$this->purchaseorder_model->POLineItemsupdatestatus($NewPO,$Newstatus);
$Newstat = array('Status'=>PO_RELEASED);
$this->purchaseorder_model->pomasterupdatestatus($NewPO,$Newstat);
}
}
echo 'PO Number is'.$PONO . ' is Amended Successfully! - New Amended PO Number is '.$NewPO;
}

View File

@ -193,6 +193,36 @@ $this->db->where('PONO',$PONO);
}
function getpolineqty($NewPO)
{
$this->db->select('*');
$this->db->from('T_PurchaseOrder_LineItem');
$this->db->where('PONO',$NewPO);
$query = $this->db->get();
return $query->result();
}
function POLineItemsupdatestatus($POno,$Newstatus)
{
$this->db->where('PONO',$POno);
$this->db->update('T_PurchaseOrder_LineItem',$Newstatus);
$update = $this->db->affected_rows();
return $update;
}
function pomasterupdatestatus($POno,$Newstat)
{
$this->db->where('PONO',$POno);
$this->db->update('T_PurchaseOrder_Master',$Newstat);
$update = $this->db->affected_rows();
return $update;
}
/*--------------------------------------------------*/

18
application/views/Favourite.php Executable file → Normal file
View File

@ -44,7 +44,7 @@
<section class="content">
<section class="content" id="content">
<center>
<h3 class="box-title">Siddharth Industries - Add Favourite <?php ?></h3>
</center>
@ -1151,8 +1151,8 @@ var js_array = [<?php echo json_encode($fav)?>];
});
</script>
<script>
// var count = 1;
var count="<?php echo json_encode($count) ?>";
var count = 1;
var fav_count="<?php echo json_encode($count) ?>";
function save(url,name){
// alert(count);
@ -1161,10 +1161,11 @@ function save(url,name){
if(span[0].className == "star glyphicon glyphicon-star"){
// console.log(span[0].className);
// alert(count++);
count = parseInt(count)+1;
count = parseInt(fav_count)+parseInt(count)+1;
$('#content').loader('show');
//alert(count);
window.location.reload();
if(count <= 7){
if(count <= 8){
$.ajax({
type:'post',
data:{name:name,url:url,status:1},
@ -1172,6 +1173,9 @@ function save(url,name){
url:'<?php echo base_url()?>user/favouriteadd',
success:function(data){
$('#content').loader('hide');
alert(data);
}
});
@ -1184,7 +1188,8 @@ function save(url,name){
}else{
//console.log(span[0].className);
//alert("else");
count = parseInt(count)-1;
count = parseInt(fav_count)-parseInt(count)-1;
$('#content').loader('show');
window.location.reload();
// count--;
//alert("else"+count);
@ -1197,6 +1202,7 @@ function save(url,name){
dataType:'JSON',
url:'<?php echo base_url()?>user/favouriteadd',
success:function(data){
$('#content').loader('hide');
}

View File

@ -365,9 +365,14 @@
$(document).ready(function() {
$.fn.dataTable.moment( 'DD-MM-YYYY' );
table = $('#cc').DataTable( {
"language": {
"emptyTable":"<center> Data Not Found ! </center>"
},
"aaSorting": [[ 0, "desc" ]],
"autoWidth": false,
orderCellsTop: true,
"dom": "<'row'<'col-md-6'l><'col-md-6'Bf>>" +
"<'row'<'col-md-6'><'col-md-6'>>" +
"<'row'<'col-md-12't>><'row'<'col-md-4'i><'col-md-8'p>>",