diff --git a/application/controllers/report.php b/application/controllers/report.php
index edbf81e8..ec2bddd7 100755
--- a/application/controllers/report.php
+++ b/application/controllers/report.php
@@ -514,7 +514,7 @@ class report extends BaseController
$data['material']=$this->dahsboard_Model->material_name();
$data['cust']=$this->dahsboard_Model->customer_name();
$data['finyear']=$this->dahsboard_Model->report_finyear();
- $data['purchase']=$this->dahsboard_Model->ireport_purchase($cname,$prod,$fa,$aa,$m,$frm,$t,$cat);
+ $data['purchase']=$this->dahsboard_Model->ireport_purchase($cname,$prod,$fa,$aa,$m,$frm,$t,$cat);
}
$data['material']=$this->dahsboard_Model->material_name();
$data['cust']=$this->dahsboard_Model->customer_name();
@@ -1198,5 +1198,19 @@ class report extends BaseController
$this->loadviews("cashbook_cumulative_month_report",$this->global,$data, NULL);
}
+
+ function Viewfiles()
+ {
+
+ $PO= $this->input->post('id');
+
+ $PONO= substr($PO,5);
+
+ $data = $this->dahsboard_Model->getfile($PONO);
+
+ echo json_encode($data);
+
+ }
+
}
?>
\ No newline at end of file
diff --git a/application/models/dahsboard_model.php b/application/models/dahsboard_model.php
index a2b8aa40..aba28fb9 100755
--- a/application/models/dahsboard_model.php
+++ b/application/models/dahsboard_model.php
@@ -9,8 +9,17 @@ class dahsboard_Model extends CI_Model
$query =$this->db->query($sql);
return $query->result();
+ }
+
+ function getfile($PONO)
+ {
+ $this->db->select('*');
+ $this->db->from('T_PurchaseOrder_BillUpload');
+ $this->db->where('PONO',$PONO);
+ $query = $this->db->get();
+ $result = $query->result_array();
+ return $result;
}
-
/* HR DASHBOART Model START*/
function totemp()
diff --git a/application/views/Report_attach_inward.php b/application/views/Report_attach_inward.php
index a47e4ae9..c3adadd0 100755
--- a/application/views/Report_attach_inward.php
+++ b/application/views/Report_attach_inward.php
@@ -1,43 +1,36 @@
-
-
-
-
-
-
-
+
+
+
@@ -179,21 +172,51 @@
-
-
-
+
+
+
+
| PO No |
- Date |
+ IGR Created Date |
Material Received Date |
Supplier Name |
Total (₹) |
Attachments |
-
@@ -201,7 +224,7 @@
$tot_tot = 0;
- foreach($purchase as $rel)
+ foreach($purchase as $rel)
{
?>
@@ -218,21 +241,18 @@
$tot_tot= $tot_tot + round($rel->total,2);
echo $rel->total;
?>
- |
+ |
file)){ ?>
-
- ifile)) { ?>
-
+
+ ifile)) { ?>
+
|
-
-
- | Total |
-   |
-   |
-   |
-
-
-
- |
-   |
-
-
-
-
-
- Total
+   |
+   |
+   |
+
+ |
+   |
+
+
+
+ ?>
@@ -276,7 +288,7 @@
-
+
@@ -294,21 +306,61 @@
// Set up your table
$(document).ready(function() {
+$('.splpofile').click(function() {
+var id = $(this).attr('id');
+$("#Fileshow").modal("show");
+ $.ajax({
+ data:{id:id},
+ type:"POST",
+ //dataType: 'json',
+ url:"report/Viewfiles",
+ success: function(data){
+ //console.log((data));
+ var trHTML = '';
+ $.each($.parseJSON(data), function (i, item) {
+
+ i=i+1;
+ trHTML += '' +
+ '| ' + i + ' | ' +
+ '' + item.BillNo+ ' | ' +
+ '' + item.PONO+ ' | ' +
+ 'uploads/BillFiles/'+item.FilePath+'>'+ item.FilePath +' | ' +
+ // '' +item.FilePath+""> +' | '
+
+ '
';
+
+
+
+ });
+
+ $("#tbleAppend1").empty();
+ $('#Inwardgateregistertable1 > tbody').append(trHTML);
+}
+ });
+
+});
+
+
+
+
$.fn.dataTable.moment( 'DD-MM-YYYY' );
table = $('#cc').DataTable( {
"language": {
"emptyTable":" Data Not Found ! "
},
+ "aaSorting": [[ 2, "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>>",
buttons: [
-
{
extend: 'excelHtml5',
footer: 'true',
- messageTop: 'Report Purchase-Inward',
+ messageTop: 'Report Attachment-Inward',
title: $('h3').text(),
exportOptions: {
columns: ':visible'
diff --git a/application/views/Report_purchase.php b/application/views/Report_purchase.php
index d0b38205..0a0c4071 100755
--- a/application/views/Report_purchase.php
+++ b/application/views/Report_purchase.php
@@ -557,7 +557,7 @@ $(document).ready(function() {
return intVal(a) + intVal(b);
}, 0 );
- $( api.column( 8 ).footer() ).html( TotalExRATE.toFixed().bold() );
+ $( api.column( 8 ).footer() ).html( TotalExRATE.toFixed(2).bold() );
TotalSGST = api
.column( 9, { search:'applied' } )
diff --git a/application/views/Report_purchase_inward.php b/application/views/Report_purchase_inward.php
index fcbe6427..d1ee3cca 100755
--- a/application/views/Report_purchase_inward.php
+++ b/application/views/Report_purchase_inward.php
@@ -46,8 +46,8 @@ table.dataTable thead > tr > td.sorting {
-
-
+
+
@@ -215,6 +215,41 @@ table.dataTable thead > tr > td.sorting {
+
+
+
+
*Insurance field not included
@@ -223,9 +258,9 @@ table.dataTable thead > tr > td.sorting {
| PO No |
- Date |
+ IGR Created Date |
Time |
- Materialrcvd Date |
+ Material Received Date |
Material Name |
Category |
Supplier Name |
@@ -233,7 +268,7 @@ table.dataTable thead > tr > td.sorting {
UOM |
Rate (₹) |
Value (₹) |
- Exchange Rate |
+ Exchange Rate |
SGST (₹) |
CGST (₹) |
IGST (₹) |
@@ -241,11 +276,12 @@ table.dataTable thead > tr > td.sorting {
Freight (₹) |
Package (₹) |
Total (₹) |
+ Attachments |
+
-
- tr > td.sorting {
$tot_pac = 0;
//$tot_inc = 0;
$tot_tot = 0;
-
- foreach($purchase as $rel)
+ if(!empty($purchase)){
+ foreach($purchase as $key => $rel)
{
?>
-
-
+
+ |
pono;?>
|
created_date;?> |
@@ -307,146 +343,63 @@ table.dataTable thead > tr > td.sorting {
total,2);
- ?>
+ echo number_format($rel->total,2,'.','');
+ ?> |
+
+
+
file)){ ?>
- total,2,'.','');?>
+
ifile)) { ?>
- total,2,'.','');?>
- total,2,'.',''); } ?>
+
+
+
+
+
|
-
-
|
- | Total |
-   |
-   |
-   |
-   |
-   |
-   |
+ Total |
+   |
+   |
+   |
+   |
+   |
+   |
+
+ |
+
+ |
-
-
-
- |
-   |
-   |
-
-
-
-
-
- |
-
-
-
-
- |
-
-
-
-
- |
-
-
-
-
- |
-
-
-
-
- |
-
-
- |
+
+ |
+
+ |
+
+ |
+
+ |
+
+ |
+
+ |
+
+ |
- }
-
- ?>
-
-
-
-
- |
-
-
-
- |
+ |
-
-
-
- |
-
-
-
-
-
+ |
+
+
-
@@ -457,8 +410,7 @@ table.dataTable thead > tr > td.sorting {
-
-
+
@@ -466,20 +418,54 @@ table.dataTable thead > tr > td.sorting {
+
-