diff --git a/application/views/newresinbatchcard.php b/application/views/newresinbatchcard.php
index 0b054c94..be4bfa01 100644
--- a/application/views/newresinbatchcard.php
+++ b/application/views/newresinbatchcard.php
@@ -1064,1373 +1064,6 @@ function masterCalculationCheck(id,val)
- //FOr total Hexamine Calculaiton
-
- if(ide == 'resin')
- {
- for(i=1;i<=overallrows;i++)
- {
- var tid = i+''+ide;
- if(document.getElementById(tid))
- {
- var currentvalue = document.getElementById(tid).textContent;
- if(isNaN(currentvalue) || currentvalue == '')
- {
- currentvalue = 0.00;
- }
- totalresinqty +=parseFloat(currentvalue);
- }
- }
- if(document.getElementById('resintotal'))
- {
- document.getElementById('resintotal').textContent = parseFloat(totalresinqty).toFixed(2);
- }
- }
- else if(ide2 == 'resin')
- {
- for(i=1;i<=overallrows;i++)
- {
- var tid = i+''+ide2;
- if(document.getElementById(tid))
- {
- var currentvalue = document.getElementById(tid).textContent;
- if(isNaN(currentvalue) || currentvalue == '')
- {
- currentvalue = 0.00;
- }
- totalresinqty +=parseFloat(currentvalue);
- }
- }
- if(document.getElementById('resintotal'))
- {
- document.getElementById('resintotal').textContent = parseFloat(totalresinqty).toFixed(2);
- }
- }
-
-
- //FOr total Hexamine Calculaiton
-
- if(ide == 'cs')
- {
- for(i=1;i<=overallrows;i++)
- {
- var tid = i+''+ide;
- if(document.getElementById(tid))
- {
- var currentvalue = document.getElementById(tid).textContent;
- if(isNaN(currentvalue) || currentvalue == '')
- {
- currentvalue = 0.00;
- }
- totalcsqty +=parseFloat(currentvalue);
- }
- }
- if(document.getElementById('cstotal'))
- {
- document.getElementById('cstotal').textContent = parseFloat(totalcsqty).toFixed(2);
- }
- }
- else if(ide2 == 'cs')
- {
- for(i=1;i<=overallrows;i++)
- {
- var tid = i+''+ide2;
- if(document.getElementById(tid))
- {
- var currentvalue = document.getElementById(tid).textContent;
- if(isNaN(currentvalue) || currentvalue == '')
- {
- currentvalue = 0.00;
- }
- totalcsqty +=parseFloat(currentvalue);
- }
- }
- if(document.getElementById('cstotal'))
- {
- document.getElementById('cstotal').textContent = parseFloat(totalcsqty).toFixed(2);
- }
- }
-
- if(val == '')
- {
- //alert('Please Enter Time..!');
- document.getElementById(id).textContent='0.00';
- return false;
- }
-
-
-}
-
-
-
- function getAllData()
- {
- //alert("inside function");
-
- if(flag != 1)
- {
- alert('Cannot Save');
- return false;
- }
-
- var testreportdata = $("#testreport").tableToJSON();
- var finaltable = $("#finaltable").tableToJSON();
- testreportdata=JSON.stringify(testreportdata);
- // alert(testreportdata);
- finaltable=JSON.stringify(finaltable);
- //alert(finaltable);
- var productid = $('#product').val();
- var customerid = $('#customer').val();
- var batchdate = $('#batchdate').val();
- var plantname = $('#plantname').val();
- var resinname = $('#resinname').val();
- var macinecode = $('#machines').val();
- var trpbatchcard = $('#trpbatchnos').val();
- var igrnos = $('#igrnos').val();
- var igrlinenos = $('#igrlinenos').val();
- var Resinigrnos = $('#Resinigrnos').val();
- var Resinigrlinenos = $('#Resinigrlinenos').val();
- var Hexamineigrnos = $('#Hexamineigrnos').val();
- var Hexamineigrlinenos = $('#Hexamineigrlinenos').val();
- var CSigrnos = $('#CSigrnos').val();
- var CSigrlinenos = $('#CSigrlinenos').val();
- var Catalystigrnos = $('#Catalystigrnos').val();
- var Catalystigrlinenos = $('#Catalystigrlinenos').val();
- var bagsigrnos = $('#bagsigrnos').val();
- var bagsigrlinenos = $('#bagsigrlinenos').val();
- var tonigrnos = $('#tonigrnos').val();
- var tonigrlinenos = $('#tonigrlinenos').val();
- var remarks = $('#remarks').val();
- var approvedby = $('#approvedby').val();
- var operatorby = $('#newoperator').val();
-
- if(productid == -1 || customerid == -1 || batchdate == '' || plantname == '' || macinecode == -1 || approvedby == -1 || listopsforstore.length == 0 || resinname == '' || operatorby == -1 )
- {
- alert('Please Enter All Master Details..!');
- return false;
- }
-
- if(( igrnos == -1 || igrlinenos == -1) && trpbatchcard == -1 )
- {
- alert('Please Enter All Master Details...!');
- return false;
- }
- var f = 0;
- for(i=1;i<=overallrows;i++)
- {
- if(document.getElementById('time'+i).textContent == '')
- {
-
- f++;
-
- }
-
- }
- // console.log('F value'+f);
- if(f != 0)
- {
- alert('Please Enter Time for All Entry..! ');
- return false;
- }
-
-
-
-
-
-
- listopsforstore = JSON.stringify(listopsforstore);
- if(trpbatchcard == -1 )
- {
- trpbatchcard ="";
- }
- if(igrnos == -1 )
- {
- igrnos = "";
- }
- if(igrlinenos == -1 )
- {
- igrlinenos = "";
- }
- var formData = new FormData();
- var reportfile = $("#reportfile").prop('files')[0];
- formData.append('rfile',reportfile);
-
- var param1 = productid;
- var param2 = customerid;
- var param3 = batchdate;
- var param4 = plantname;
- var param5 = macinecode;
- var param6 = trpbatchcard;
- var param7 = igrnos;
- var param8 = igrlinenos;
- var param9 = remarks;
- var param10 = approvedby;
- var param11 = testreportdata;
- var param12 = finaltable;
- var param13 = resinname;
- var param14 = listopsforstore;
- var param15 = operatorby;
- var param16 = igrnos+'-'+igrlinenos;
- var param17 = Resinigrnos+'-'+Resinigrlinenos;
- var param18 = Hexamineigrnos+'-'+Hexamineigrlinenos
- var param19 = CSigrnos+'-'+CSigrlinenos ;
- var param20 = Catalystigrnos+'-'+Catalystigrlinenos;
- var param21 = bagsigrnos+'-'+bagsigrlinenos;
- var param22 = tonigrnos+'-'+tonigrlinenos;
-
-
- formData.append('param1',param1);
- formData.append('param2',param2);
- formData.append('param3',param3);
- formData.append('param4',param4);
- formData.append('param5',param5);
- formData.append('param6',param6);
- formData.append('param7',param7);
- formData.append('param8',param8);
- formData.append('param9',param9);
- formData.append('param10',param10);
- formData.append('param11',param11);
- formData.append('param12',param12);
- formData.append('param13',param13);
- formData.append('param14',param14);
- formData.append('param15',param15);
- formData.append('param16',param16);
- formData.append('param17',param17);
- formData.append('param18',param18);
- formData.append('param19',param19);
- formData.append('param20',param20);
- formData.append('param21',param21);
- formData.append('param22',param22);
-
-
- $('.content').loader('show');
- $.ajax({
- data:formData,
- type:"POST",
- url:"resinbatchcard/saveTestReportData",
- //async : false,
- cache : false,
- contentType : false,
- processData : false,
- success:function(data) {
- if(data){
- alert(data);
- $('.content').loader('hide');
-
- window.location = "";
- }
-
- }
-
- });
-
- }
-
-
- $('#operators').change(function(){
-
- var val = $('#operators').val();
- var text = $("#operators option:selected").text();
- //alert(val);
- //alert(text);
- var totalelements = listopsforstore.length
-
- if(totalelements != 0)
- {
- $.each(listopsforstore,function(key,value){
- //alert(value);
- if(value == val)
- {
- alert('Helper Already Added..!Choose Another One.!');
- brea();
- }
-
-
- });
- }
- listopsforstore.push(val);
- //console.log(listopsforstore);
- $("#listops").append('');
-
- });
-
- $("#listops").dblclick(function(){
- var text = $("#listops option:selected").text();
- var val = $('#listops').val();
-
- //alert(text+'-'+val);
- $('option:selected', this).remove();
- listopsforstore = listopsforstore.filter(item => item != val);
- //console.log(listopsforstore);
-
- });
-
-
-'Select Employee');
-$newoperator = array(-1=>'Select Operator');
-foreach($operatorslist as $re)
-{
-
- $operators[$re->EmpID] = $re->EmpID.'-'.$re->FirstName.'-'.$re->LastName;
- $newoperator[$re->EmpID] = $re->EmpID.'-'.$re->FirstName.'-'.$re->LastName;
-}
-
-$products = array(-1=>'Select Product');
-foreach($productsoutward as $rec)
-{
- $products[$rec->product_id] = $rec->product_name.'-'.$rec->product_description;
-}
-
-$customers = array(-1=>'Select Customer');
-foreach($customersoutward as $rec)
-{
- $customers[$rec->client_id] = $rec->client_name;
-}
-
-//print_r($emplist);
-$approvedby = array(-1=>'Select Approver Name');
-foreach($emplist as $r)
-{
- $approvedby[$r->FirstName.' '.$r->LastName] = $r->FirstName.' '.$r->LastName.'-'.$r->shortName;
-}
-
-$machines = array(-1=>'Select Machine Name');
-$trpbatchnos = array(-1=>'Select TRP Batch Card No');
-$igrnos = array(-1=>'Select IGRNO');
-$igrlinenos = array(-1=>'Select IGR Line Item');
-foreach($igrno as $r)
-{
- $igrnos[$r->IGRNO] = $r->IGRNO;
-}
-foreach($machinelist as $r)
-{
- $machines[$r->Machine_Code] = $r->Machine_Code.'-'.$r->Machine_Name;
-}
-foreach($trpbatchcardnos as $r)
-{
- $trpbatchnos[$r->dailyid] = $r->dailyid;
-}
-
-?>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- | Particulars | Time |
- | SNO | Unit |
- | Spec |
-
-
-
-
-
-
-
-
-
-
-
Raw/Packing Material Consumption
-
-
- | Particulars | Sand | Resin | Hexamine | CS | Catalyst | 50 Bags | 1 ton Bag | Production Loss Lump | Finished Prodcut PCS |
- | Unit | Kgs | Kgs | Kgs | Kgs | Kgs | Kgs | Nos | Kgs | Kgs |
-
-
-
- | Qty | 0.00 | 0.00 | 0.00 | 0.00 | 0.00 | 0.00 | 0.00 | 0.00 | 0.00 |
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-