FIX_IGR issues and PO alignment
This commit is contained in:
parent
84cf062161
commit
7bf4e6488c
@ -335,25 +335,20 @@ class Inwardgateregister extends BaseController
|
||||
|
||||
#Step 2 Master File and Its Details Gathering
|
||||
$MasterFile = $this->request->getFile('MasterFile');
|
||||
$requestMasterFileName = $MasterFile->getName();
|
||||
|
||||
if (!empty($requestMasterFileName)) {
|
||||
$requestMasterFileName = NULL;
|
||||
if (!empty($MasterFile)) {
|
||||
$requestMasterFileName = $MasterFile->getName();
|
||||
if ($MasterFile && $MasterFile->isValid() && !$MasterFile->hasMoved()) {
|
||||
if (!empty($this->inwardgateregister_model->isFileExistsInIGRmaster($requestMasterFileName))) {
|
||||
log_message('error', 'File already exists in the database'.$requestMasterFileName);
|
||||
$requestMasterFileName = NULL;
|
||||
}
|
||||
else{
|
||||
$MasterFile->move($path, $requestMasterFileName);
|
||||
$fileupdated_count++;
|
||||
$fileupdated_name[] = $requestMasterFileName;
|
||||
}
|
||||
}else{
|
||||
$requestMasterFileName = NULL;
|
||||
}
|
||||
}else{
|
||||
$requestMasterFileName = NULL;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#Step 3 Master Details Gathering to Save In DB
|
||||
$igr = array('PONO' => $PONO, 'VehicleNo' => $VehicleNo, 'DeliveryChellanOrInvoiceNo' => $DeliveryChellanOrInvoiceNo, 'DeliveryChellanDate' => $DeliveryChellanDate, 'MaterialRcvdDate' => $MaterialRcvdDt, 'DriverName' => $DriverName, 'DriverMobileNumber' => $DriverMobileNumber,'IGRStatus' => $IGRStatus, 'CreatedBy' => $CreatedBy, 'CreatedDate' => $createddt, 'PaymentStatus' => $paymentstatus);
|
||||
@ -595,10 +590,11 @@ function viewIGRDetails()
|
||||
$IGRNo = $this->request->getPost('igr');
|
||||
|
||||
$DeliveryChellan = $this->request->getPost('invdate');
|
||||
$DeliveryChellanDate = get_date_time_format($DeliveryChellan);
|
||||
$DeliveryChellanDate = !$DeliveryChellan || $DeliveryChellan === null ? NULL : get_date_time_format($DeliveryChellan);
|
||||
|
||||
$Mat_Rcvd_Dt = $this->request->getPost('mrc');
|
||||
$MaterialRcvdDt = get_date_time_format($Mat_Rcvd_Dt);
|
||||
$MaterialRcvdDt = !$Mat_Rcvd_Dt || $Mat_Rcvd_Dt === null ? NULL : get_date_time_format($Mat_Rcvd_Dt);
|
||||
|
||||
|
||||
$VehicleNo = $this->request->getPost('vehicle_no');
|
||||
$DriverName = $this->request->getPost('driver');
|
||||
@ -618,9 +614,9 @@ function viewIGRDetails()
|
||||
$igrarr = array('DeliveryChellanDate' => $DeliveryChellanDate, 'MaterialRcvdDate' => $MaterialRcvdDt,'VehicleNo'=>$VehicleNo,'DriverMobileNumber'=>$DriverMobileNumber,'DriverName'=>$DriverName, 'IGRStatus' => $IGRStatus,'UpdateBY' => $updateby);
|
||||
|
||||
$MasterFile = $this->request->getfile('MasterFile');
|
||||
$requestMasterFileName = $MasterFile->getName();
|
||||
|
||||
if (!empty($requestMasterFileName)) {
|
||||
if ($MasterFile) {
|
||||
$requestMasterFileName = $MasterFile->getName();
|
||||
if ($MasterFile && $MasterFile->isValid() && !$MasterFile->hasMoved()) {
|
||||
if (!empty($this->inwardgateregister_model->isFileExistsInIGRmaster($requestMasterFileName))) {
|
||||
log_message('error', 'File already exists in the database'.$requestMasterFileName);
|
||||
@ -700,9 +696,9 @@ function viewIGRDetails()
|
||||
$tareWeightDate = $row['TareWeightDate'];
|
||||
$netWeight = $row['NetWeight'];
|
||||
$igrItemNo = $row['IGRItemNo'];
|
||||
$GrossWtDt = get_date_time_format($grossWeightDate);
|
||||
$TareWtDt = get_date_time_format($tareWeightDate);
|
||||
|
||||
$GrossWtDt = !empty($grossWeightDate) && strtolower($grossWeightDate) !== 'null' ? get_date_time_format($grossWeightDate) : NULL;
|
||||
$TareWtDt = !empty($tareWeightDate) && strtolower($tareWeightDate) !== 'null' ? get_date_time_format($tareWeightDate) : NULL;
|
||||
|
||||
$igrline = array(
|
||||
'QuantityAsPerInvoice' => $quantityAsPerInvoice,
|
||||
'Remarks' => $remarks,
|
||||
@ -901,9 +897,11 @@ function viewIGRDetails()
|
||||
$requestdata = $this->request->getPost('data');
|
||||
$updateby = $this->session->get('userId');
|
||||
$GrossWeightDate = (string)$this->request->getPost('GrossWeightDate');
|
||||
$GrossWtDt = get_date_time_format($GrossWeightDate);
|
||||
$GrossWtDt = !empty($GrossWeightDate) ? get_date_time_format($GrossWeightDate) : NULL;
|
||||
|
||||
$TareWeightDate = (string)$this->request->getPost('TareWeightDate');
|
||||
$TareWtDt = get_date_time_format($TareWeightDate);
|
||||
$TareWtDt = !empty($TareWeightDate) ? get_date_time_format($TareWeightDate) : NULL;
|
||||
|
||||
|
||||
|
||||
// Check if request data is not null and is a string
|
||||
@ -1168,7 +1166,10 @@ function updateIGRWeight(){
|
||||
$IGRItemNo = $this->request->getPost('IGRlineitem');
|
||||
$updateby = $this->session->get('userId');
|
||||
$WeightFile = $this->request->getfile('WeightFile');
|
||||
$requestWeightFileName = $WeightFile->getName();
|
||||
$GrossWtDt = !empty($GrossWeightDate) ? get_date_time_format($GrossWeightDate) : null;
|
||||
$TareWtDt = !empty($TareWeightDate) ? get_date_time_format($TareWeightDate) : null;
|
||||
|
||||
|
||||
$path = ROOTPATH.'public/uploads/Igrfiles/';
|
||||
if(!is_dir($path)) { mkdir($path, 0777, true); }
|
||||
|
||||
@ -1230,7 +1231,7 @@ function updateIGRWeight(){
|
||||
log_message('error', "History updated successfully. History id: " . $history_id);
|
||||
}
|
||||
}
|
||||
if($GrossWeightDate){
|
||||
if($GrossWtDt){
|
||||
$grossdate = $this->inwardgateregister_model->get_igr_history('GrossWeightDate',$IGRNO, $IGRItemNo);
|
||||
if(!empty($grossdate)){
|
||||
$old_data = NULL;
|
||||
@ -1239,17 +1240,17 @@ function updateIGRWeight(){
|
||||
$old_data = $row->new_data;
|
||||
}
|
||||
}
|
||||
$igr_history = array('field' => 'GrossWeightDate','new_data' => $GrossWeightDate,'old_data' => $old_data,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
|
||||
$igr_history = array('field' => 'GrossWeightDate','new_data' => $GrossWtDt,'old_data' => $old_data,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
|
||||
($old_data != NULL) ? $igr_history['is_edit'] = 1 : $igr_history['is_add'] = 1 ;
|
||||
$history_id = $this->inwardgateregister_model->igr_history($igr_history);
|
||||
log_message('error', "History updated successfully. History id: " . $history_id);
|
||||
} else{
|
||||
$igr_history = array('field' => 'GrossWeightDate','is_edit' => 1,'new_data' => $GrossWeightDate,'old_data' => NULL,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
|
||||
$igr_history = array('field' => 'GrossWeightDate','is_edit' => 1,'new_data' => $GrossWtDt,'old_data' => NULL,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
|
||||
$history_id = $this->inwardgateregister_model->igr_history($igr_history);
|
||||
log_message('error', "History updated successfully. History id: " . $history_id);
|
||||
}
|
||||
}
|
||||
if($TareWeightDate){
|
||||
if($TareWtDt){
|
||||
$taredate = $this->inwardgateregister_model->get_igr_history('TareWeightDate',$IGRNO, $IGRItemNo);
|
||||
|
||||
if(!empty($taredate)){
|
||||
@ -1259,12 +1260,12 @@ function updateIGRWeight(){
|
||||
$old_data = $row->new_data;
|
||||
}
|
||||
}
|
||||
$igr_history = array('field' => 'TareWeightDate','new_data' => $TareWeightDate,'old_data' => $old_data,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
|
||||
$igr_history = array('field' => 'TareWeightDate','new_data' => $TareWtDt,'old_data' => $old_data,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
|
||||
($old_data != NULL) ? $igr_history['is_edit'] = 1 : $igr_history['is_add'] = 1 ;
|
||||
$history_id = $this->inwardgateregister_model->igr_history($igr_history);
|
||||
log_message('error', "History updated successfully. History id: " . $history_id);
|
||||
} else{
|
||||
$igr_history = array('field' => 'TareWeightDate','is_edit' => 1,'new_data' => $TareWeightDate,'old_data' => NULL,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
|
||||
$igr_history = array('field' => 'TareWeightDate','is_edit' => 1,'new_data' => $TareWtDt,'old_data' => NULL,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
|
||||
$history_id = $this->inwardgateregister_model->igr_history($igr_history);
|
||||
log_message('error', "History updated successfully. History id: " . $history_id);
|
||||
}
|
||||
@ -1272,19 +1273,22 @@ function updateIGRWeight(){
|
||||
|
||||
|
||||
$IGRItemNo = $this->request->getPost('IGRlineitem');
|
||||
$igr_lineitem = array('GrossWeight' => $GrossWeight,'GrossWeightDate' => $GrossWeightDate,'TareWeightDate' => $TareWeightDate,'TareWeight' => $TareWeight,'NetWeight' => $NetWeight,'UpdateBY' => $updateby);
|
||||
|
||||
if (!empty($requestWeightFileName)) {
|
||||
if ($WeightFile && $WeightFile->isValid() && !$WeightFile->hasMoved()) {
|
||||
if (!empty($this->inwardgateregister_model->isFileExistsInIGRdetails($requestWeightFileName))) {
|
||||
log_message('error', 'File already exists in the database'.$requestWeightFileName);
|
||||
}
|
||||
else{
|
||||
$WeightFile->move($path, $requestWeightFileName);
|
||||
$igr_lineitem['WeightFile'] = $requestWeightFileName;
|
||||
$igr_lineitem = array('GrossWeight' => $GrossWeight,'GrossWeightDate' => $GrossWtDt,'TareWeightDate' => $TareWtDt,'TareWeight' => $TareWeight,'NetWeight' => $NetWeight,'UpdateBY' => $updateby);
|
||||
$requestWeightFileName =null ;
|
||||
if($WeightFile){
|
||||
if (!empty($requestWeightFileName)) {
|
||||
if ($WeightFile && $WeightFile->isValid() && !$WeightFile->hasMoved()) {
|
||||
if (!empty($this->inwardgateregister_model->isFileExistsInIGRdetails($requestWeightFileName))) {
|
||||
log_message('error', 'File already exists in the database'.$requestWeightFileName);
|
||||
}
|
||||
else{
|
||||
$WeightFile->move($path, $requestWeightFileName);
|
||||
$igr_lineitem['WeightFile'] = $requestWeightFileName;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$update = $this->inwardgateregister_model->updateIGRLineItem($igr_lineitem, $IGRItemNo);
|
||||
|
||||
if ($update) {
|
||||
|
||||
@ -1102,10 +1102,10 @@ $mpdf->use_kwt = true;
|
||||
|
||||
|
||||
$file = $this->request->getFile('POFile');
|
||||
$requestfilename = $file->getName();
|
||||
if (!empty($requestfilename)) {
|
||||
|
||||
$requestfilename = NULL;
|
||||
if (!empty($file)) {
|
||||
if ($file->isValid() && !$file->hasMoved()) {
|
||||
$requestfilename = $file->getName();
|
||||
$path = ROOTPATH.'public/uploads/POfiles/';
|
||||
if(!is_dir($path)) { mkdir($path, 0777, true); }
|
||||
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
|
||||
@ -1284,9 +1284,11 @@ $mpdf->use_kwt = true;
|
||||
$POList['ReleasedBy'] = $this->session->get('userId');
|
||||
}
|
||||
$file = $this->request->getFile('POFile');
|
||||
$requestfilename = $file->getName();
|
||||
if (!empty($requestfilename)) {
|
||||
$requestfilename = NULL;
|
||||
if (!empty($file)) {
|
||||
if ($file && $file->isValid() && !$file->hasMoved()) {
|
||||
$requestfilename = $file->getName();
|
||||
|
||||
$path = ROOTPATH.'public/uploads/POfiles/';
|
||||
if(!is_dir($path)) { mkdir($path, 0777, true); }
|
||||
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
|
||||
@ -1905,10 +1907,11 @@ $mpdf->use_kwt = true;
|
||||
$lastPONO = $this->purchaseorder_model->lastPONO();
|
||||
$newPONO = generate_po_number($lastPONO);
|
||||
$file = $this->request->getFile('POFile');
|
||||
$requestfilename = $file->getName();
|
||||
if (!empty($requestfilename)) {
|
||||
$requestfilename = NULL;
|
||||
if (!empty($file)) {
|
||||
|
||||
if ($file->isValid() && !$file->hasMoved()) {
|
||||
$requestfilename = $file->getName();
|
||||
$path = ROOTPATH.'public/uploads/POfiles/';
|
||||
if(!is_dir($path)) { mkdir($path, 0777, true); }
|
||||
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
|
||||
@ -2131,9 +2134,11 @@ $mpdf->use_kwt = true;
|
||||
$POList['ReleasedBy'] = $this->session->get('userId');
|
||||
}
|
||||
$file = $this->request->getFile('POFile');
|
||||
$requestfilename = $file->getName();
|
||||
if (!empty($requestfilename)) {
|
||||
$requestfilename = NULL;
|
||||
|
||||
if (!empty($file)) {
|
||||
if ($file && $file->isValid() && !$file->hasMoved()) {
|
||||
$requestfilename = $file->getName();
|
||||
$path = ROOTPATH.'public/uploads/POfiles/';
|
||||
if(!is_dir($path)) { mkdir($path, 0777, true); }
|
||||
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
|
||||
@ -2564,10 +2569,11 @@ try{
|
||||
$lastPONO = $this->purchaseorder_model->lastPONO();
|
||||
$newPONO = generate_po_number($lastPONO);
|
||||
$file = $this->request->getFile('POFile');
|
||||
$requestfilename = $file->getName();
|
||||
if (!empty($requestfilename)) {
|
||||
$requestfilename = NULL;
|
||||
if (!empty($file)) {
|
||||
|
||||
if ($file->isValid() && !$file->hasMoved()) {
|
||||
$requestfilename = $file->getName();
|
||||
$path = ROOTPATH.'public/uploads/POfiles/';
|
||||
if(!is_dir($path)) { mkdir($path, 0777, true); }
|
||||
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
|
||||
@ -2851,9 +2857,10 @@ try{
|
||||
$POList['ReleasedBy'] = $this->session->get('userId');
|
||||
}
|
||||
$file = $this->request->getFile('POFile');
|
||||
$requestfilename = $file->getName();
|
||||
if (!empty($requestfilename)) {
|
||||
$requestfilename = NULL;
|
||||
if (!empty($file)) {
|
||||
if ($file && $file->isValid() && !$file->hasMoved()) {
|
||||
$requestfilename = $file->getName();
|
||||
$path = ROOTPATH.'public/uploads/POfiles/';
|
||||
if(!is_dir($path)) { mkdir($path, 0777, true); }
|
||||
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -938,14 +938,14 @@ if (!empty($INRSYMBOL)) {
|
||||
echo form_open(base_url() . '/purchaseorder/addPO/', $attributes); ?>
|
||||
|
||||
<section class="content">
|
||||
<div style="border:2px solid #333">
|
||||
<div class="box">
|
||||
<div>
|
||||
<center><b>
|
||||
</b></center>
|
||||
</div>
|
||||
<div class="header-container">
|
||||
<h2>Amendment Revenue Purchase Order- <?php echo $PONO; ?></h2>
|
||||
<a href="<?php echo base_url() ?>amendmentpurchaseorder" class="btn btn-cancel" id="back" value="Back">Back</a>
|
||||
<!-- <a href="<?php echo base_url() ?>amendmentpurchaseorder" class="btn btn-cancel" id="back" value="Back">Back</a> -->
|
||||
</div>
|
||||
|
||||
<div class="container-fluid">
|
||||
@ -1281,9 +1281,9 @@ if (!empty($INRSYMBOL)) {
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<a class="btn btn-cancel" data-dismiss="modal" style="margin-top: -24px;" value="Cancel">Cancel</a>
|
||||
|
||||
<a class="btn btn-success" ID="PackagingOption" onclick="SetFreightOption();" style="margin-top: -24px;"> <span class="bold">Ok</span></a>
|
||||
<a class="btn btn-success" data-dismiss="modal" style="margin-top: -24px;" value="Cancel">Cancel</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -1318,8 +1318,8 @@ if (!empty($INRSYMBOL)) {
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<a class="btn btn-cancel" data-dismiss="modal" style="margin-top: -24px;" value="Cancel">Cancel</a>
|
||||
<a class="btn btn-success" ID="ExciseOption" onclick="SetExciseCalculation();" style="margin-top: -24px;"> <span class="bold">Ok</span></a>
|
||||
<a class="btn btn-success" data-dismiss="modal" style="margin-top: -24px;" value="Cancel">Cancel</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -1349,8 +1349,8 @@ if (!empty($INRSYMBOL)) {
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<a class="btn btn-cancel" data-dismiss="modal" style="margin-top: -24px;" value="Cancel">Cancel</a>
|
||||
<a class="btn btn-success" ID="VatOption" onclick="SetVatCalculation();" style="margin-top: -24px;"> <span class="bold">Ok</span></a>
|
||||
<a class="btn btn-success" data-dismiss="modal" style="margin-top: -24px;" value="Cancel">Cancel</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -1378,8 +1378,8 @@ if (!empty($INRSYMBOL)) {
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<a class="btn btn-cancel" data-dismiss="modal" style="margin-top: -24px;" value="Cancel">Cancel</a>
|
||||
<a class="btn btn-success" ID="CSTOption" onclick="SetCSTCalculation();" style="margin-top: -24px;"> <span class="bold">Ok</span></a>
|
||||
<a class="btn btn-success" data-dismiss="modal" style="margin-top: -24px;" value="Cancel">Cancel</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -1757,8 +1757,8 @@ if (!empty($INRSYMBOL)) {
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3 col-md-offset-9">
|
||||
<a class="btn btn-cancel" data-dismiss="modal" value="Cancel">Cancel</a>
|
||||
<a class="btn btn-success EditRevenue" ID="EditRevenue"> <span class="bold">Edit Revenue</span></a>
|
||||
<a class="btn btn-success" data-dismiss="modal" value="Cancel">Cancel</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -2012,6 +2012,7 @@ if (!empty($INRSYMBOL)) {
|
||||
<?php } ?>
|
||||
<input type="hidden" id="PrePOFile" name="PrePOFile" value="<?php echo $PrePOFile; ?>" /><br>
|
||||
</div>
|
||||
<input type="button" class="btn btn-cancel" value="Cancel" onClick="window.location ='amendmentpurchaseorder';">
|
||||
<input type="hidden" name="txtPoRange" id="txtPoRange" />
|
||||
<input type="hidden" name="isEdit" id="isEdit" value="0" />
|
||||
<input type="hidden" name="txtStatus" id="txtStatus" />
|
||||
@ -2021,7 +2022,6 @@ if (!empty($INRSYMBOL)) {
|
||||
|
||||
<!-- <a class="btn btn-success Save" ID="Save" onclick="Save(0)" > <span class="bold">Save</span></a> -->
|
||||
<a class="btn btn-success Save" ID="Submit" onclick="Save(1)"> <span class="bold">Submit</span></a>
|
||||
<input type="button" class="btn btn-success" value="Cancel" onClick="window.location ='amendmentpurchaseorder';">
|
||||
|
||||
<!-- <input type="reset" class="btn btn-success" value = "OK"> -->
|
||||
|
||||
@ -2567,7 +2567,7 @@ if (!empty($INRSYMBOL)) {
|
||||
|
||||
$('#Scheduleby').val('');
|
||||
|
||||
}); <!-- script
|
||||
}); < !--script
|
||||
for table, It works uned the datatable plugin-- >
|
||||
$(function() {
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -58,7 +58,7 @@ if (!empty($POMaster)) {
|
||||
|
||||
$SupId = $Req->SupplierID;
|
||||
$SupName = $Req->SupplierName;
|
||||
$Address = $Req->MSME ? "MSME : ".$Req->MSME."\n".$Req->Address :$Req->Address ;
|
||||
$Address = $Req->MSME ? "MSME : " . $Req->MSME . "\n" . $Req->Address : $Req->Address;
|
||||
$pdt = new DateTime($Req->PODate);
|
||||
$PODate = $pdt->format('d-m-Y');
|
||||
$DeliverOption = $Req->DeliveryOption;
|
||||
@ -86,7 +86,6 @@ if (!empty($POMaster)) {
|
||||
$DescriptionOfPo = $Req->Description_Of_Service;
|
||||
$BudgetType = $Req->BudgetType;
|
||||
$PrePOFile = $Req->POFile;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -253,11 +252,12 @@ foreach ($PaymentTerms as $TER) {
|
||||
|
||||
$.each(y, function(idx, obj) {
|
||||
if (obj.SupplierID === id) {
|
||||
if (obj.MSME) {
|
||||
$("#SupAddress").val("MSME :" + obj.MSME + "\n" + obj.Address);
|
||||
} else {
|
||||
$("#SupAddress").val(obj.Address);
|
||||
} $("#PaymentTerms").val(obj.PaymentID);
|
||||
if (obj.MSME) {
|
||||
$("#SupAddress").val("MSME :" + obj.MSME + "\n" + obj.Address);
|
||||
} else {
|
||||
$("#SupAddress").val(obj.Address);
|
||||
}
|
||||
$("#PaymentTerms").val(obj.PaymentID);
|
||||
|
||||
|
||||
|
||||
@ -405,13 +405,16 @@ foreach ($PaymentTerms as $TER) {
|
||||
}
|
||||
var d = $('#drpSupplier').val();
|
||||
$.ajax({
|
||||
url:"<?php echo base_url() ?>VerifyWithSupplierForPendingPO",
|
||||
type: 'POST',
|
||||
data: {supplierid : drpSupplier, materialcode: id },
|
||||
success: function(response) {
|
||||
if(response) alert(response);
|
||||
}
|
||||
});
|
||||
url: "<?php echo base_url() ?>VerifyWithSupplierForPendingPO",
|
||||
type: 'POST',
|
||||
data: {
|
||||
supplierid: drpSupplier,
|
||||
materialcode: id
|
||||
},
|
||||
success: function(response) {
|
||||
if (response) alert(response);
|
||||
}
|
||||
});
|
||||
} else {
|
||||
alert('Please select the MaterialCode');
|
||||
return false;
|
||||
@ -442,16 +445,19 @@ foreach ($PaymentTerms as $TER) {
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
var d = $('#drpSupplier').val();
|
||||
$.ajax({
|
||||
url:"<?php echo base_url() ?>VerifyWithSupplierForPendingPO",
|
||||
type: 'POST',
|
||||
data: {supplierid : d, materialcode: id },
|
||||
success: function(response) {
|
||||
if(response) alert(response);
|
||||
}
|
||||
});
|
||||
url: "<?php echo base_url() ?>VerifyWithSupplierForPendingPO",
|
||||
type: 'POST',
|
||||
data: {
|
||||
supplierid: d,
|
||||
materialcode: id
|
||||
},
|
||||
success: function(response) {
|
||||
if (response) alert(response);
|
||||
}
|
||||
});
|
||||
} else {
|
||||
alert('Please select the MaterialCode');
|
||||
return false;
|
||||
@ -644,6 +650,7 @@ foreach ($PaymentTerms as $TER) {
|
||||
.num {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.header-container {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
@ -656,325 +663,331 @@ foreach ($PaymentTerms as $TER) {
|
||||
text-align: center;
|
||||
margin: 0;
|
||||
}
|
||||
.centered {
|
||||
display: flex;
|
||||
/* justify-content: center; */
|
||||
align-items: center;
|
||||
height: 10vh;
|
||||
}
|
||||
.centered label, .centered input {
|
||||
margin: 0 5px;
|
||||
}
|
||||
.mandatory { color:red;text-align:right;background-color: white;}
|
||||
|
||||
.centered {
|
||||
display: flex;
|
||||
/* justify-content: center; */
|
||||
align-items: center;
|
||||
height: 10vh;
|
||||
}
|
||||
|
||||
.centered label,
|
||||
.centered input {
|
||||
margin: 0 5px;
|
||||
}
|
||||
|
||||
.mandatory {
|
||||
color: red;
|
||||
text-align: right;
|
||||
background-color: white;
|
||||
}
|
||||
</style>
|
||||
<div class="content-wrapper">
|
||||
<?php
|
||||
$attributes = array('class' => 'form-label-left ServicePO ', 'name' => 'ServicePO', 'id' => 'ServicePO','enctype' => 'multipart/form-data');
|
||||
$attributes = array('class' => 'form-label-left ServicePO ', 'name' => 'ServicePO', 'id' => 'ServicePO', 'enctype' => 'multipart/form-data');
|
||||
|
||||
echo form_open(base_url() . '/purchaseorder/addPO/', $attributes); ?>
|
||||
|
||||
<section class="content">
|
||||
<div style="border:2px solid #333">
|
||||
<div class="box">
|
||||
<div id="content"></div>
|
||||
<div class="header-container">
|
||||
<?php if ($parentPO == '') { ?>
|
||||
<h2> Edit Service Purchase Order-<?php echo "$PONO"?></h2>
|
||||
<?php } else {?>
|
||||
<h2> Amended Service Purchase Order-<?php echo "$PONO"?></h2>
|
||||
<?php } ?>
|
||||
|
||||
<h2> Amended Service Purchase Order-<?php echo "$PONO" ?></h2>
|
||||
|
||||
<a href="<?php echo base_url() ?>amendmentpurchaseorder" class="btn btn-cancel" id="back" value="Back">Back</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Requistion No</label>
|
||||
<div class="col-md-3">
|
||||
<label>Requistion No</label>
|
||||
<?php
|
||||
$options = array("0" => 'Selected Requisition Numbers');
|
||||
if (!empty($ReqList)) {
|
||||
foreach ($ReqList as $SID) :
|
||||
$options[$SID->ReqNo] = $SID->ReqNo;
|
||||
endforeach;
|
||||
}
|
||||
echo form_multiselect('RequistionNo', $options, set_value('RequistionNo', array()), 'id="RequistionNo"', 'required="true"');
|
||||
?>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Purchase Order Type</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$options = array("0" => 'Selected Requisition Numbers');
|
||||
if (!empty($ReqList)) {
|
||||
foreach ($ReqList as $SID) :
|
||||
$options[$SID->ReqNo] = $SID->ReqNo;
|
||||
$data = array('name' => 'POType', 'value' => set_value('POType', SERVICE), 'id' => 'POType', 'class' => 'form-control', 'readonly' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Supplier<span class="badge mandatory">*</span></label>
|
||||
<?php
|
||||
$options = array("0" => 'Select Supplier');
|
||||
//print_r( $options);
|
||||
|
||||
if (!empty($Suplist)) {
|
||||
foreach ($Suplist as $SID) :
|
||||
$options[$SID->SupplierID] = $SID->SupplierID . ' - ' . $SID->SupplierName;
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('drpSupplier', $options, set_value('drpSupplier', $SupId), 'id="drpSupplier"', 'required="true"', 'class="form-control select2');
|
||||
|
||||
?>
|
||||
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Address</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'SupAddress', 'value' => set_value('SupAddress', $Address), 'id' => 'SupAddress', 'class' => 'form-control', 'readonly' => 'true', 'rows' => '3', 'cols' => '40');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Work Status<span class="badge mandatory">*</span></label>
|
||||
<?php
|
||||
if (!empty($WorkStatus)) {
|
||||
//print_r($WorkStatus);
|
||||
foreach ($WorkStatus as $WorkSID) :
|
||||
if ($WrkStatus == $WorkSID->StatusCode) {
|
||||
|
||||
$optionsWork[$WorkSID->StatusCode] = $WorkSID->StatusName;
|
||||
}
|
||||
endforeach;
|
||||
foreach ($WorkStatus as $SID) :
|
||||
if ($WrkStatus != $SID->StatusName) {
|
||||
$optionsWork[$SID->StatusCode] = $SID->StatusName;
|
||||
}
|
||||
endforeach;
|
||||
}
|
||||
echo form_dropdown('workstatus', $optionsWork, set_value('workstatus'), 'id="workstatus"', 'required="true"', 'class="form-control select2');
|
||||
?>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<b><u>Select Delivery By<span class="badge mandatory">*</span></u></b><br />
|
||||
<div class="centered">
|
||||
<?php echo form_label('Date', 'Date') . " " . form_radio(array('name' => 'DateRange', 'value' => '0', 'checked' => ('0' == $DeliverOption) ? TRUE : FALSE, 'id' => 'Date')); ?>
|
||||
<?php echo form_label('Schedule', 'Schedule') . " " . form_radio(array('name' => 'DateRange', 'value' => '1', 'checked' => ('1' == $DeliverOption) ? TRUE : FALSE, 'id' => 'Schedule')); ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="Deliverydtdiv">
|
||||
<label>Delivery Date<span class="badge mandatory">*</span></label>
|
||||
<?php if ($DeliverOption == 1) {
|
||||
$Deliverydt = null;
|
||||
} ?>
|
||||
<input type="hidden" name="beforeDeliverydt" value="<?php echo $Deliverydt ?>">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Deliverydt', 'value' => set_value('Deliverydt', $Deliverydt), 'id' => 'Deliverydt', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="Schedulediv" style="display:none;">
|
||||
<label>Schedule By<span class="badge mandatory">*</span></label>
|
||||
<input type="hidden" name="beforeScheduleby" value="<?php echo $DeliverSchedule ?>">
|
||||
<?php
|
||||
$data = array('name' => 'Scheduleby', 'value' => set_value('Scheduleby', $DeliverSchedule), 'id' => 'Scheduleby', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40', 'maxlength' => '110');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Delivery Address</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'DeliveryAddr', 'value' => set_value('DeliveryAddr', $DeliveryAddress), 'id' => 'DeliveryAddr', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40');
|
||||
echo Form_textarea($data);
|
||||
?><input type="hidden" name="txtDeliveryAddress" id="txtDeliveryAddress" value="<?php echo $DeliveryAddress; ?>">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Purchase Order Date</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'PODate', 'value' => set_value('PODate', $PODate), 'id' => 'PODate', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Mode Of Shipment</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'addmodeofshipment', 'value' => set_value('addmodeofshipment', $ModeOfShipment), 'id' => 'addmodeofshipment', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Contact Reference</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'amendsupplierreference', 'value' => set_value('amendsupplierreference', $SupplierReference), 'id' => 'amendsupplierreference', 'class' => 'form-control', 'maxlength' => '40');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Supplier's Offer No</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'amendsupplierofferno', 'value' => set_value('amendsupplierofferno', $SuppliersOfferNo), 'id' => 'amendsupplierofferno', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Our Reference(S)</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'amendotherreference', 'value' => set_value('amendotherreference', $OtherReferences), 'id' => 'amendotherreference', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Service Type Options</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
|
||||
if (!empty($PoTypeOptions)) {
|
||||
foreach ($PoTypeOptions as $POpt) :
|
||||
|
||||
if ($ServiceTypeOptions == $POpt->ConfigValue) {
|
||||
$optionsPO[$POpt->ConfigValue] = $POpt->ConfigValue;
|
||||
}
|
||||
endforeach;
|
||||
foreach ($PoTypeOptions as $POpt1) :
|
||||
|
||||
if ($ServiceTypeOptions != $POpt1->ConfigValue) {
|
||||
$optionsPO[$POpt1->ConfigValue] = $POpt1->ConfigValue;
|
||||
}
|
||||
endforeach;
|
||||
}
|
||||
echo form_multiselect('RequistionNo', $options, set_value('RequistionNo', array()), 'id="RequistionNo"', 'required="true"');
|
||||
|
||||
echo form_dropdown('PoTypeOptions', $optionsPO, set_value('PoTypeOptions'), 'id="PoTypeOptions"', 'required="true"', 'class="form-control select2');
|
||||
|
||||
|
||||
?>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Purchase Order Type</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'POType', 'value' => set_value('POType', SERVICE), 'id' => 'POType', 'class' => 'form-control', 'readonly' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Supplier<span class="badge mandatory">*</span></label>
|
||||
<?php
|
||||
$options = array("0" => 'Select Supplier');
|
||||
//print_r( $options);
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Payment Terms</label>
|
||||
<input type="hidden" name="beforePaymentTerms" value="<?php echo $Terms ?>">
|
||||
<?php
|
||||
if (!empty($Payment)) {
|
||||
//print_r($Payment);
|
||||
foreach ($Payment as $pay2)
|
||||
|
||||
if (!empty($Suplist)) {
|
||||
foreach ($Suplist as $SID) :
|
||||
$options[$SID->SupplierID] = $SID->SupplierID . ' - ' . $SID->SupplierName ;
|
||||
endforeach;
|
||||
if ($Terms == $pay2->PaymentID) {
|
||||
?>
|
||||
<input type="hidden" id="beforePaymentTermsText" name="beforePaymentTermsText" value="<?php echo $pay2->PaymentTerms ?>">
|
||||
<?php
|
||||
$optionsPay[$pay2->PaymentID] = $pay2->PaymentTerms;
|
||||
}
|
||||
|
||||
echo form_dropdown('drpSupplier', $options, set_value('drpSupplier', $SupId), 'id="drpSupplier"', 'required="true"', 'class="form-control select2');
|
||||
foreach ($Payment as $pay1) :
|
||||
|
||||
?>
|
||||
if ($Terms != $pay1->PaymentID) {
|
||||
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Address</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'SupAddress', 'value' => set_value('SupAddress', $Address), 'id' => 'SupAddress', 'class' => 'form-control', 'readonly' => 'true', 'rows' => '3', 'cols' => '40');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Work Status<span class="badge mandatory" >*</span></label>
|
||||
<?php
|
||||
if (!empty($WorkStatus)) {
|
||||
//print_r($WorkStatus);
|
||||
foreach ($WorkStatus as $WorkSID) :
|
||||
if ($WrkStatus == $WorkSID->StatusCode) {
|
||||
|
||||
$optionsWork[$WorkSID->StatusCode] = $WorkSID->StatusName;
|
||||
}
|
||||
endforeach;
|
||||
foreach ($WorkStatus as $SID) :
|
||||
if ($WrkStatus != $SID->StatusName) {
|
||||
$optionsWork[$SID->StatusCode] = $SID->StatusName;
|
||||
}
|
||||
endforeach;
|
||||
$optionsPay[$pay1->PaymentID] = $pay1->PaymentTerms;
|
||||
}
|
||||
echo form_dropdown('workstatus', $optionsWork, set_value('workstatus'), 'id="workstatus"', 'required="true"', 'class="form-control select2');
|
||||
?>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<b><u>Select Delivery By<span class="badge mandatory">*</span></u></b><br />
|
||||
<div class="centered">
|
||||
<?php echo form_label('Date', 'Date') . " " . form_radio(array('name' => 'DateRange', 'value' => '0', 'checked' => ('0' == $DeliverOption) ? TRUE : FALSE, 'id' => 'Date')); ?>
|
||||
<?php echo form_label('Schedule', 'Schedule') . " " . form_radio(array('name' => 'DateRange', 'value' => '1', 'checked' => ('1' == $DeliverOption) ? TRUE : FALSE, 'id' => 'Schedule')); ?>
|
||||
endforeach;
|
||||
}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="Deliverydtdiv">
|
||||
<label>Delivery Date<span class="badge mandatory" >*</span></label>
|
||||
<?php if ($DeliverOption == 1) {
|
||||
$Deliverydt = null;
|
||||
} ?>
|
||||
<input type="hidden" name="beforeDeliverydt" value="<?php echo $Deliverydt ?>">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Deliverydt', 'value' => set_value('Deliverydt', $Deliverydt), 'id' => 'Deliverydt', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="Schedulediv" style="display:none;">
|
||||
<label>Schedule By<span class="badge mandatory" >*</span></label>
|
||||
<input type="hidden" name="beforeScheduleby" value="<?php echo $DeliverSchedule ?>">
|
||||
<?php
|
||||
$data = array('name' => 'Scheduleby', 'value' => set_value('Scheduleby', $DeliverSchedule), 'id' => 'Scheduleby', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40', 'maxlength' => '110');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Delivery Address</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'DeliveryAddr', 'value' => set_value('DeliveryAddr', $DeliveryAddress), 'id' => 'DeliveryAddr', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40');
|
||||
echo Form_textarea($data);
|
||||
?><input type="hidden" name="txtDeliveryAddress" id="txtDeliveryAddress" value="<?php echo $DeliveryAddress; ?>">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Purchase Order Date</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'PODate', 'value' => set_value('PODate', $PODate), 'id' => 'PODate', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Mode Of Shipment</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'addmodeofshipment', 'value' => set_value('addmodeofshipment', $ModeOfShipment), 'id' => 'addmodeofshipment', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Contact Reference</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'amendsupplierreference', 'value' => set_value('amendsupplierreference', $SupplierReference), 'id' => 'amendsupplierreference', 'class' => 'form-control', 'maxlength' => '40');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Supplier's Offer No</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'amendsupplierofferno', 'value' => set_value('amendsupplierofferno', $SuppliersOfferNo), 'id' => 'amendsupplierofferno', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Our Reference(S)</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'amendotherreference', 'value' => set_value('amendotherreference', $OtherReferences), 'id' => 'amendotherreference', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Service Type Options</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
|
||||
if (!empty($PoTypeOptions)) {
|
||||
foreach ($PoTypeOptions as $POpt) :
|
||||
|
||||
if ($ServiceTypeOptions == $POpt->ConfigValue) {
|
||||
$optionsPO[$POpt->ConfigValue] = $POpt->ConfigValue;
|
||||
}
|
||||
endforeach;
|
||||
foreach ($PoTypeOptions as $POpt1) :
|
||||
|
||||
if ($ServiceTypeOptions != $POpt1->ConfigValue) {
|
||||
$optionsPO[$POpt1->ConfigValue] = $POpt1->ConfigValue;
|
||||
}
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('PoTypeOptions', $optionsPO, set_value('PoTypeOptions'), 'id="PoTypeOptions"', 'required="true"', 'class="form-control select2');
|
||||
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Payment Terms</label>
|
||||
<input type="hidden" name="beforePaymentTerms" value="<?php echo $Terms ?>">
|
||||
<?php
|
||||
if (!empty($Payment)) {
|
||||
//print_r($Payment);
|
||||
foreach ($Payment as $pay2)
|
||||
|
||||
if ($Terms == $pay2->PaymentID) {
|
||||
?>
|
||||
<input type="hidden" id="beforePaymentTermsText" name="beforePaymentTermsText" value="<?php echo $pay2->PaymentTerms ?>">
|
||||
<?php
|
||||
$optionsPay[$pay2->PaymentID] = $pay2->PaymentTerms;
|
||||
}
|
||||
|
||||
foreach ($Payment as $pay1) :
|
||||
|
||||
if ($Terms != $pay1->PaymentID) {
|
||||
|
||||
$optionsPay[$pay1->PaymentID] = $pay1->PaymentTerms;
|
||||
}
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('PaymentTerms', $optionsPay, set_value('PaymentTerms'), 'id="PaymentTerms"', 'required="true"', 'class="form-control select2');
|
||||
?>
|
||||
echo form_dropdown('PaymentTerms', $optionsPay, set_value('PaymentTerms'), 'id="PaymentTerms"', 'required="true"', 'class="form-control select2');
|
||||
?>
|
||||
</div>
|
||||
<div class="col-md-3" id="otheroptiondiv" style="display:none;">
|
||||
<label>Description of Payable Terms<span class="badge mandatory" >*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Otherpayment', 'Otherpayment' => set_value('Otherpayment'), 'id' => 'Otherpayment', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
<label>Description of Payable Terms<span class="badge mandatory">*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Otherpayment', 'Otherpayment' => set_value('Otherpayment'), 'id' => 'Otherpayment', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Insurance Options</label>
|
||||
<div class="form-group">
|
||||
<label>Insurance Options</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
<?php
|
||||
|
||||
if (!empty($insuranceStatus)) {
|
||||
foreach ($insuranceStatus as $INS) :
|
||||
if ($InsuranceOptions == $INS['value']) {
|
||||
$optionsInsurance[$INS['value']] = $INS['name'];
|
||||
}
|
||||
if (!empty($insuranceStatus)) {
|
||||
foreach ($insuranceStatus as $INS) :
|
||||
if ($InsuranceOptions == $INS['value']) {
|
||||
$optionsInsurance[$INS['value']] = $INS['name'];
|
||||
}
|
||||
|
||||
|
||||
|
||||
endforeach;
|
||||
foreach ($insuranceStatus as $INS1) :
|
||||
if ($InsuranceOptions != $INS1['value']) {
|
||||
$optionsInsurance[$INS1['value']] = $INS1['name'];
|
||||
}
|
||||
endforeach;
|
||||
foreach ($insuranceStatus as $INS1) :
|
||||
if ($InsuranceOptions != $INS1['value']) {
|
||||
$optionsInsurance[$INS1['value']] = $INS1['name'];
|
||||
}
|
||||
|
||||
|
||||
|
||||
endforeach;
|
||||
}
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('insuranceStatus', $optionsInsurance, set_value('insuranceStatus'), 'id="insuranceStatus"', 'required="true"', 'class="form-control select2');
|
||||
echo form_dropdown('insuranceStatus', $optionsInsurance, set_value('insuranceStatus'), 'id="insuranceStatus"', 'required="true"', 'class="form-control select2');
|
||||
|
||||
|
||||
?>
|
||||
</div>
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="insuranceTxtDiv" style="display:block;">
|
||||
<label>Insurance No / Insurance Details<span class="badge mandatory" >*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'InsuranceNumber', 'value' => set_value('InsuranceNumber', $InsuranceNumber), 'id' => 'InsuranceNumber', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<label>Insurance No / Insurance Details<span class="badge mandatory">*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'InsuranceNumber', 'value' => set_value('InsuranceNumber', $InsuranceNumber), 'id' => 'InsuranceNumber', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<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>
|
||||
<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>
|
||||
@ -1000,7 +1013,7 @@ foreach ($PaymentTerms as $TER) {
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Req No<span class="badge mandatory" >*</span></label>
|
||||
<label>Req No<span class="badge mandatory">*</span></label>
|
||||
<div>
|
||||
<?php
|
||||
|
||||
@ -1042,7 +1055,7 @@ foreach ($PaymentTerms as $TER) {
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Item Code<span class="badge mandatory" >*</span></label>*</span></label>
|
||||
<label>Item Code<span class="badge mandatory">*</span></label>*</span></label>
|
||||
<div>
|
||||
<?php
|
||||
$options = array("0" => 'Item Code');
|
||||
@ -1106,7 +1119,7 @@ foreach ($PaymentTerms as $TER) {
|
||||
<div class="col-md-12">
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>Quantity<span class="badge mandatory" >*</span></label>*</span></label>
|
||||
<label>Quantity<span class="badge mandatory">*</span></label>*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'EditQuantity', 'value' => set_value('EditQuantity'), 'id' => 'EditQuantity', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'EditRatechange()');
|
||||
@ -1115,7 +1128,7 @@ foreach ($PaymentTerms as $TER) {
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label><?php echo "Rate ($INRSYM)"; ?><span class="badge mandatory" >*</span></label>*</span></label>
|
||||
<label><?php echo "Rate ($INRSYM)"; ?><span class="badge mandatory">*</span></label>*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'EditRate', 'value' => set_value('EditRate'), 'id' => 'EditRate', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'EditRatechange()');
|
||||
@ -1253,8 +1266,8 @@ foreach ($PaymentTerms as $TER) {
|
||||
</div>
|
||||
<div class="col-md-12" style="padding: 0px 30px 10px 30px;">
|
||||
<label>Service Description </label> <?php $data = array('name' => 'EdittxtSpcialInstruction', 'value' => set_value('EdittxtSpcialInstruction', $ServiceMaterialDescription), 'id' => 'EdittxtSpcialInstruction', 'class' => 'form-control', 'rows' => '3', 'cols' => '40');
|
||||
echo form_textarea($data);
|
||||
?> <input type="hidden" name="beforeEdittxtSpcialInstruction" id="beforeSpcialInstruction" value="<?php echo $ServiceMaterialDescription; ?>">
|
||||
echo form_textarea($data);
|
||||
?> <input type="hidden" name="beforeEdittxtSpcialInstruction" id="beforeSpcialInstruction" value="<?php echo $ServiceMaterialDescription; ?>">
|
||||
</div>
|
||||
<br />
|
||||
|
||||
@ -1487,7 +1500,7 @@ foreach ($PaymentTerms as $TER) {
|
||||
</div>
|
||||
<!--start new fields 1 sep-->
|
||||
<div class="col-md-12">
|
||||
<label>Description Of Service<span class="badge mandatory" >*</span></label>*</label>
|
||||
<label>Description Of Service<span class="badge mandatory">*</span></label>*</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'amenddescofpo', 'value' => set_value('amenddescofpo', $DescriptionOfPo), 'id' => 'amenddescofpo', 'class' => 'form-control', 'rows' => '3', 'cols' => '40');
|
||||
@ -1508,13 +1521,13 @@ foreach ($PaymentTerms as $TER) {
|
||||
<div class="col-md-12">
|
||||
<div class="row"><br />
|
||||
<div align="right" style="padding-right:10px">
|
||||
<div>
|
||||
<input type="file" name="POFile" id="POFile">
|
||||
<?php if($PrePOFile){ ?>
|
||||
<label><a title="previously uploaded PO File" href="<?php echo base_url().'public/uploads/POfiles/' . $PrePOFile ?>"><span>previously uploaded - </span><small><?= $PrePOFile; ?></small></a></label>
|
||||
<?php } ?>
|
||||
<input type="hidden" id="PrePOFile" name="PrePOFile" value="<?php echo $PrePOFile; ?>"/><br>
|
||||
</div>
|
||||
<div>
|
||||
<input type="file" name="POFile" id="POFile">
|
||||
<?php if ($PrePOFile) { ?>
|
||||
<label><a title="previously uploaded PO File" href="<?php echo base_url() . 'public/uploads/POfiles/' . $PrePOFile ?>"><span>previously uploaded - </span><small><?= $PrePOFile; ?></small></a></label>
|
||||
<?php } ?>
|
||||
<input type="hidden" id="PrePOFile" name="PrePOFile" value="<?php echo $PrePOFile; ?>" /><br>
|
||||
</div>
|
||||
<input type="hidden" name="txtPONO" id="txtPONO" value="<?php echo $PONO; ?>" />
|
||||
<input type="hidden" name="txtStatus" id="txtStatus" />
|
||||
<input type="hidden" name="txtDeletedRow" id="txtDeletedRow" />
|
||||
@ -1535,13 +1548,13 @@ foreach ($PaymentTerms as $TER) {
|
||||
<label>Request On :</label><?php echo $Reqon; ?><br />
|
||||
<label>Request By :</label><?php echo $RequesterName; ?><br />
|
||||
<label>Status : </label><?php
|
||||
$statusMappings = [
|
||||
$statusMappings = [
|
||||
'PO APPROVED' => 'AWAITING APPROVE',
|
||||
'AWAITING RELEASE' => 'AWAITING APPROVE',
|
||||
'RELEASER ONHOLD' => 'APPROVER ONHOLD',
|
||||
'PO RELEASED' => 'PO APPROVED',
|
||||
];
|
||||
|
||||
|
||||
if (isset($StatusName) && !empty($StatusName)) {
|
||||
if (isset($statusMappings[$StatusName])) {
|
||||
echo $statusMappings[$StatusName];
|
||||
@ -1551,7 +1564,7 @@ foreach ($PaymentTerms as $TER) {
|
||||
} else {
|
||||
echo "Status not provided";
|
||||
}
|
||||
?>
|
||||
?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@ -2068,7 +2081,7 @@ foreach ($PaymentTerms as $TER) {
|
||||
else if (ExceedBudget($('#txtEditBasicValue').val(), $('#EditAvlBudAmt').val()) == false) {
|
||||
$('#EditRate').focus();
|
||||
return false;
|
||||
} else {
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1734,16 +1734,24 @@ if (!empty($INRSYMBOL)) {
|
||||
text-align: center;
|
||||
margin: 0;
|
||||
}
|
||||
.centered {
|
||||
display: flex;
|
||||
/* justify-content: center; */
|
||||
align-items: center;
|
||||
height: 10vh;
|
||||
}
|
||||
.centered label, .centered input {
|
||||
margin: 0 5px;
|
||||
}
|
||||
.mandatory { color:red;text-align:right;background-color: white;}
|
||||
|
||||
.centered {
|
||||
display: flex;
|
||||
/* justify-content: center; */
|
||||
align-items: center;
|
||||
height: 10vh;
|
||||
}
|
||||
|
||||
.centered label,
|
||||
.centered input {
|
||||
margin: 0 5px;
|
||||
}
|
||||
|
||||
.mandatory {
|
||||
color: red;
|
||||
text-align: right;
|
||||
background-color: white;
|
||||
}
|
||||
</style>
|
||||
<div class="content-wrapper">
|
||||
<?php
|
||||
@ -1751,7 +1759,7 @@ if (!empty($INRSYMBOL)) {
|
||||
|
||||
echo form_open(base_url() . '/purchaseorder/addPO/', $attributes); ?>
|
||||
<section class="content">
|
||||
<div style="border:2px solid #333">
|
||||
<div class="box">
|
||||
<div id="content"></div>
|
||||
<div class="header-container">
|
||||
<h2>Revenue Purchase Order</h2>
|
||||
@ -1815,31 +1823,31 @@ if (!empty($INRSYMBOL)) {
|
||||
<div id="div1" style="display:block;">
|
||||
<b><u>Select Tax Range</u></b><br />
|
||||
<div class="centered">
|
||||
<?php
|
||||
echo form_label('Local', 'Local') . " " . form_radio(array(
|
||||
"name" => "Range",
|
||||
"id" => "Local",
|
||||
"value" => "0",
|
||||
'checked' => 'checked',
|
||||
'onchange' => 'SetVatorCST();'
|
||||
));
|
||||
?>
|
||||
<?php
|
||||
echo form_label('Inter state', 'Inter_state') . " " . form_radio(array(
|
||||
"name" => "Range",
|
||||
"id" => "Inter_state",
|
||||
"value" => "1",
|
||||
'onchange' => 'SetVatorCST();'
|
||||
));
|
||||
?>
|
||||
</div>
|
||||
<?php
|
||||
echo form_label('Local', 'Local') . " " . form_radio(array(
|
||||
"name" => "Range",
|
||||
"id" => "Local",
|
||||
"value" => "0",
|
||||
'checked' => 'checked',
|
||||
'onchange' => 'SetVatorCST();'
|
||||
));
|
||||
?>
|
||||
<?php
|
||||
echo form_label('Inter state', 'Inter_state') . " " . form_radio(array(
|
||||
"name" => "Range",
|
||||
"id" => "Inter_state",
|
||||
"value" => "1",
|
||||
'onchange' => 'SetVatorCST();'
|
||||
));
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<b><u>Select Delivery By<span class="badge mandatory" >*</span></u></b><br />
|
||||
<b><u>Select Delivery By<span class="badge mandatory">*</span></u></b><br />
|
||||
<div class="centered">
|
||||
<?php echo form_label('Date', 'Date') . " " . form_radio(array("name" => "DateRange", "id" => "Date", "value" => "0", "checked" => "checked")); ?>
|
||||
<?php echo form_label('Schedule', 'Schedule') . " " . form_radio(array("name" => "DateRange", "id" => "Schedule", "value" => "1")); ?>
|
||||
<?php echo form_label('Date', 'Date') . " " . form_radio(array("name" => "DateRange", "id" => "Date", "value" => "0", "checked" => "checked")); ?>
|
||||
<?php echo form_label('Schedule', 'Schedule') . " " . form_radio(array("name" => "DateRange", "id" => "Schedule", "value" => "1")); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="Deliverydtdiv">
|
||||
@ -1852,7 +1860,7 @@ if (!empty($INRSYMBOL)) {
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="Schedulediv" style="display:none;">
|
||||
<label>Schedule By<span class="badge mandatory" >*</span></label>
|
||||
<label>Schedule By<span class="badge mandatory">*</span></label>
|
||||
<?php
|
||||
$data = array('name' => 'Scheduleby', 'value' => set_value('Scheduleby'), 'id' => 'Scheduleby', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40', 'maxlength' => '110');
|
||||
echo Form_textarea($data);
|
||||
@ -1962,7 +1970,7 @@ if (!empty($INRSYMBOL)) {
|
||||
?>
|
||||
</div>
|
||||
<div class="col-md-3" id="otheroptiondiv" style="display:none;">
|
||||
<label>Description of Payable Terms<span class="badge mandatory" >*</span></label>
|
||||
<label>Description of Payable Terms<span class="badge mandatory">*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Otherpayment', 'Otherpayment' => set_value('Otherpayment'), 'id' => 'Otherpayment', 'class' => 'form-control', 'required' => 'true');
|
||||
@ -1984,7 +1992,7 @@ if (!empty($INRSYMBOL)) {
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="InsuranceNumberdiv" style="display:block;">
|
||||
<label>Insurance No / Insurance Details<span class="badge mandatory" >*</span></label>
|
||||
<label>Insurance No / Insurance Details<span class="badge mandatory">*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'InsuranceNumber', 'InsuranceNumber' => set_value('InsuranceNumber'), 'id' => 'InsuranceNumber', 'class' => 'form-control', 'required' => 'true');
|
||||
|
||||
@ -593,6 +593,7 @@ if (!empty($INRSYMBOL)) {
|
||||
.num {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.header-container {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
@ -605,17 +606,24 @@ if (!empty($INRSYMBOL)) {
|
||||
text-align: center;
|
||||
margin: 0;
|
||||
}
|
||||
.centered {
|
||||
display: flex;
|
||||
/* justify-content: center; */
|
||||
align-items: center;
|
||||
height: 10vh;
|
||||
}
|
||||
.centered label, .centered input {
|
||||
margin: 0 5px;
|
||||
}
|
||||
.mandatory { color:red;text-align:right;background-color: white;}
|
||||
|
||||
.centered {
|
||||
display: flex;
|
||||
/* justify-content: center; */
|
||||
align-items: center;
|
||||
height: 10vh;
|
||||
}
|
||||
|
||||
.centered label,
|
||||
.centered input {
|
||||
margin: 0 5px;
|
||||
}
|
||||
|
||||
.mandatory {
|
||||
color: red;
|
||||
text-align: right;
|
||||
background-color: white;
|
||||
}
|
||||
</style>
|
||||
<div class="content-wrapper">
|
||||
<?php
|
||||
@ -624,17 +632,17 @@ if (!empty($INRSYMBOL)) {
|
||||
echo form_open(base_url() . '/purchaseorder/addPO/', $attributes); ?>
|
||||
|
||||
<section class="content">
|
||||
<div style="border:2px solid #333">
|
||||
<div class="box">
|
||||
<div id="content"></div>
|
||||
<div class="header-container">
|
||||
<h2>Service Purchase Order</h2>
|
||||
<a href="<?php echo base_url() ?>CreatePO" class="btn btn-cancel" id="back" value="Back">Back</a>
|
||||
</div>
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Requistion No</label>
|
||||
<label>Requistion No</label>
|
||||
<?php
|
||||
|
||||
$options = array("0" => 'Selected Requisition Numbers');
|
||||
@ -652,17 +660,17 @@ if (!empty($INRSYMBOL)) {
|
||||
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Purchase Order Type</label>
|
||||
<div class="form-group">
|
||||
<label>Purchase Order Type</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'POType', 'value' => set_value('POType', SERVICE), 'id' => 'POType', 'class' => 'form-control', 'readonly' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
<?php
|
||||
$data = array('name' => 'POType', 'value' => set_value('POType', SERVICE), 'id' => 'POType', 'class' => 'form-control', 'readonly' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Supplier<span class="badge mandatory">*</span></label>
|
||||
<label>Supplier<span class="badge mandatory">*</span></label>
|
||||
|
||||
<?php
|
||||
$options = array("0" => 'Select Supplier');
|
||||
@ -680,120 +688,120 @@ if (!empty($INRSYMBOL)) {
|
||||
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Address</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'SupAddress', 'value' => set_value('SupAddress'), 'id' => 'SupAddress', 'class' => 'form-control', 'readonly' => 'true', 'rows' => '3', 'cols' => '40');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
</div>
|
||||
<label>Address</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'SupAddress', 'value' => set_value('SupAddress'), 'id' => 'SupAddress', 'class' => 'form-control', 'readonly' => 'true', 'rows' => '3', 'cols' => '40');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Work Status<span class="badge mandatory">*</span></label>
|
||||
<?php
|
||||
|
||||
$optionsWork = array("0" => 'Select Work Status');
|
||||
//print_r( $options);
|
||||
|
||||
if (!empty($WorkStatus)) {
|
||||
foreach ($WorkStatus as $WID) :
|
||||
|
||||
|
||||
$optionsWork[$WID->StatusCode] = $WID->StatusName;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('workstatus', $optionsWork, set_value('workstatus'), 'id="workstatus"', 'required="true"', 'class="form-control select2');
|
||||
|
||||
|
||||
?>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<b><u>Select Delivery By<span class="badge mandatory" >*</span></u></b><br />
|
||||
<div class="centered">
|
||||
<?php echo form_label('Date', 'Date') . " " . form_radio(array("name" => "DateRange", "id" => "Date", "value" => "0", 'checked' => set_radio('DateRange', '0', TRUE))); ?>
|
||||
<?php echo form_label('Schedule', 'Schedule') . " " . form_radio(array("name" => "DateRange", "id" => "Schedule", "value" => "1", 'checked' => set_radio('DateRange', '1', FALSE))); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="Deliverydtdiv">
|
||||
<label>Delivery Date<span class="badge mandatory" >*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Deliverydt', 'value' => set_value('Deliverydt', $CurrentDate), 'id' => 'Deliverydt', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="Schedulediv" style="display:none;">
|
||||
<label>Schedule By<span class="badge mandatory">*</span></label>
|
||||
<?php
|
||||
$data = array('name' => 'Scheduleby', 'value' => set_value('Scheduleby'), 'id' => 'Scheduleby', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40', 'maxlength' => '110');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>Delivery Address</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'DeliveryAddr', 'value' => set_value('DeliveryAddr', $CompanyAddress), 'id' => 'DeliveryAddr', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
</div>
|
||||
<label>Work Status<span class="badge mandatory">*</span></label>
|
||||
<?php
|
||||
|
||||
$optionsWork = array("0" => 'Select Work Status');
|
||||
//print_r( $options);
|
||||
|
||||
if (!empty($WorkStatus)) {
|
||||
foreach ($WorkStatus as $WID) :
|
||||
|
||||
|
||||
$optionsWork[$WID->StatusCode] = $WID->StatusName;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('workstatus', $optionsWork, set_value('workstatus'), 'id="workstatus"', 'required="true"', 'class="form-control select2');
|
||||
|
||||
|
||||
?>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<b><u>Select Delivery By<span class="badge mandatory">*</span></u></b><br />
|
||||
<div class="centered">
|
||||
<?php echo form_label('Date', 'Date') . " " . form_radio(array("name" => "DateRange", "id" => "Date", "value" => "0", 'checked' => set_radio('DateRange', '0', TRUE))); ?>
|
||||
<?php echo form_label('Schedule', 'Schedule') . " " . form_radio(array("name" => "DateRange", "id" => "Schedule", "value" => "1", 'checked' => set_radio('DateRange', '1', FALSE))); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="Deliverydtdiv">
|
||||
<label>Delivery Date<span class="badge mandatory">*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Deliverydt', 'value' => set_value('Deliverydt', $CurrentDate), 'id' => 'Deliverydt', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3" id="Schedulediv" style="display:none;">
|
||||
<label>Schedule By<span class="badge mandatory">*</span></label>
|
||||
<?php
|
||||
$data = array('name' => 'Scheduleby', 'value' => set_value('Scheduleby'), 'id' => 'Scheduleby', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40', 'maxlength' => '110');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>Delivery Address</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'DeliveryAddr', 'value' => set_value('DeliveryAddr', $CompanyAddress), 'id' => 'DeliveryAddr', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Purchase Order Date</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'PODate', 'value' => set_value('PODate', $CurrentDate), 'id' => 'PODate', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'PODate', 'value' => set_value('PODate', $CurrentDate), 'id' => 'PODate', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Mode Of Shipment</label>
|
||||
<div class="form-group">
|
||||
<label>Mode Of Shipment</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'addmodeofshipment', 'value' => set_value('addmodeofshipment'), 'id' => 'addmodeofshipment', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
<?php
|
||||
$data = array('name' => 'addmodeofshipment', 'value' => set_value('addmodeofshipment'), 'id' => 'addmodeofshipment', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Contact Reference</label>
|
||||
<div class="form-group">
|
||||
<div class="col-md-3">
|
||||
<label>Contact Reference</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'addsupplierreference', 'value' => set_value('addsupplierreference'), 'id' => 'addsupplierreference', 'class' => 'form-control', 'maxlength' => '40');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Supplier's Offer No</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'addsupplierreference', 'value' => set_value('addsupplierreference'), 'id' => 'addsupplierreference', 'class' => 'form-control', 'maxlength' => '40');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Supplier's Offer No</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'addsupplierofferno', 'value' => set_value('addsupplierofferno'), 'id' => 'addsupplierofferno', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
<?php
|
||||
$data = array('name' => 'addsupplierofferno', 'value' => set_value('addsupplierofferno'), 'id' => 'addsupplierofferno', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Our Reference(S)</label>
|
||||
@ -806,95 +814,95 @@ if (!empty($INRSYMBOL)) {
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Service Type Options</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
//$optionsWork = array("0"=>'Select Work Status');
|
||||
$optionsPO = array("0" => 'Select');
|
||||
<label>Service Type Options</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
//$optionsWork = array("0"=>'Select Work Status');
|
||||
$optionsPO = array("0" => 'Select');
|
||||
|
||||
if (!empty($PoTypeOptions)) {
|
||||
foreach ($PoTypeOptions as $POpt) :
|
||||
$optionsPO[$POpt->ConfigValue] = $POpt->ConfigValue;
|
||||
endforeach;
|
||||
}
|
||||
echo form_dropdown('PoTypeOptions', $optionsPO, set_value('PoTypeOptions'), 'id="PoTypeOptions"', 'required="true"', 'class="form-control select2');
|
||||
?>
|
||||
</div>
|
||||
if (!empty($PoTypeOptions)) {
|
||||
foreach ($PoTypeOptions as $POpt) :
|
||||
$optionsPO[$POpt->ConfigValue] = $POpt->ConfigValue;
|
||||
endforeach;
|
||||
}
|
||||
echo form_dropdown('PoTypeOptions', $optionsPO, set_value('PoTypeOptions'), 'id="PoTypeOptions"', 'required="true"', 'class="form-control select2');
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Payment Terms</label>
|
||||
<?php
|
||||
if (!empty($Payment)) {
|
||||
$options6 = array("0" => 'Select Payment Terms ');
|
||||
foreach ($Payment as $pay) :
|
||||
$options6[$pay->PaymentID] = $pay->PaymentTerms;
|
||||
endforeach;
|
||||
}
|
||||
<label>Payment Terms</label>
|
||||
<?php
|
||||
if (!empty($Payment)) {
|
||||
$options6 = array("0" => 'Select Payment Terms ');
|
||||
foreach ($Payment as $pay) :
|
||||
$options6[$pay->PaymentID] = $pay->PaymentTerms;
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('PaymentTerms', $options6, set_value('PaymentTerms'), 'id="PaymentTerms"', 'required="true"', 'class="form-control select2');
|
||||
echo form_dropdown('PaymentTerms', $options6, set_value('PaymentTerms'), 'id="PaymentTerms"', 'required="true"', 'class="form-control select2');
|
||||
|
||||
?>
|
||||
?>
|
||||
</div>
|
||||
<div class="col-md-3" id="otheroptiondiv" style="display:none;">
|
||||
|
||||
<label>Description of Payable Terms<span class="badge mandatory">*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Otherpayment', 'Otherpayment' => set_value('Otherpayment'), 'id' => 'Otherpayment', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
<label>Description of Payable Terms<span class="badge mandatory">*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Otherpayment', 'Otherpayment' => set_value('Otherpayment'), 'id' => 'Otherpayment', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Insurance Options</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
|
||||
if (!empty($insuranceStatus)) {
|
||||
foreach ($insuranceStatus as $INS) :
|
||||
|
||||
|
||||
$optionsInsurance[$INS['value']] = $INS['name'];
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('insuranceStatus', $optionsInsurance, set_value('insuranceStatus'), 'id="insuranceStatus"', 'required="true"', 'class="form-control select2');
|
||||
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-3" id="insuranceTxtDiv" style="display:block;">
|
||||
<label>Insurance No / Insurance Details<span class="badge mandatory">*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'InsuranceNumber', 'value' => set_value('InsuranceNumber'), 'id' => 'InsuranceNumber', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<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>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Insurance Options</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
|
||||
if (!empty($insuranceStatus)) {
|
||||
foreach ($insuranceStatus as $INS) :
|
||||
|
||||
|
||||
$optionsInsurance[$INS['value']] = $INS['name'];
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('insuranceStatus', $optionsInsurance, set_value('insuranceStatus'), 'id="insuranceStatus"', 'required="true"', 'class="form-control select2');
|
||||
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-3" id="insuranceTxtDiv" style="display:block;">
|
||||
<label>Insurance No / Insurance Details<span class="badge mandatory">*</span></label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'InsuranceNumber', 'value' => set_value('InsuranceNumber'), 'id' => 'InsuranceNumber', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<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 class="container-fluid">
|
||||
<table class="table table-bordered" style="border:1px solid #333" id="ServiceTable">
|
||||
@ -1259,7 +1267,7 @@ if (!empty($INRSYMBOL)) {
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Item Code<span class="badge mandatory" #fff ;">*</span></label>
|
||||
<label>Item Code<span class="badge mandatory" #fff ;">*</span></label>
|
||||
<div>
|
||||
<?php
|
||||
$options = array("0" => 'Item Code');
|
||||
|
||||
@ -1,437 +1,444 @@
|
||||
<style>
|
||||
.table-bordered>thead>tr>th, .table-bordered>tbody>tr>th, .table-bordered>tfoot>tr>th, .table-bordered>thead>tr>td, .table-bordered>tbody>tr>td, .table-bordered>tfoot>tr>td {border: 1px solid #333;}
|
||||
</style>
|
||||
.table-bordered>thead>tr>th,
|
||||
.table-bordered>tbody>tr>th,
|
||||
.table-bordered>tfoot>tr>th,
|
||||
.table-bordered>thead>tr>td,
|
||||
.table-bordered>tbody>tr>td,
|
||||
.table-bordered>tfoot>tr>td {
|
||||
border: 1px solid #333;
|
||||
}
|
||||
</style>
|
||||
<div class="content-wrapper">
|
||||
|
||||
|
||||
<section class="content">
|
||||
|
||||
<div style="border:2px solid #333">
|
||||
<center><b><h2>Service Purchase Order.</h2></b></center>
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-4">
|
||||
<label>Requistion No</label>
|
||||
<div class="form-control">
|
||||
<?php
|
||||
$options = array("0"=>'Requistion No');
|
||||
//print_r( $options);
|
||||
|
||||
if(!empty($POType))
|
||||
{
|
||||
foreach ($SupplierName as $SID):
|
||||
|
||||
|
||||
$options[$SID->SupplierID] = $SID->SupplierID.' '.' - '.' '.$SID->SupplierName;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('MaterialCode', $options,set_value('MaterialCode'),'id="MaterialCode"' ,'class="form-control required"','required="true"');
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<label>PO Date</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<label>Purchase Order Type</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<label>Supplier</label>
|
||||
<div class="form-control">
|
||||
<?php
|
||||
$options = array("0"=>'Supplier');
|
||||
//print_r( $options);
|
||||
|
||||
if(!empty($POType))
|
||||
{
|
||||
foreach ($SupplierName as $SID):
|
||||
|
||||
|
||||
$options[$SID->SupplierID] = $SID->SupplierID.' '.' - '.' '.$SID->SupplierName;
|
||||
<section class="content">
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('MaterialCode', $options,set_value('MaterialCode'),'id="MaterialCode"' ,'class="form-control required"','required="true"');
|
||||
<div class="box">
|
||||
<center><b>
|
||||
<h2>Service Purchase Order.</h2>
|
||||
</b></center>
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-4">
|
||||
<label>Requistion No</label>
|
||||
<div class="form-control">
|
||||
<?php
|
||||
$options = array("0" => 'Requistion No');
|
||||
//print_r( $options);
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<label>Address</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<label>City</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container-fluid">
|
||||
<table class="table table-bordered" style="border:1px solid #333">
|
||||
<div align="right" style="padding-right:10px">
|
||||
<div align="right">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3 col-md-offset-7" align="right" style="padding:10px">
|
||||
<!-- <input type="checkbox" id="IsOpenOrder" name="IsOpenOrder" value="1"> IS THIS OPEN ORDER FORMAT -->
|
||||
</div>
|
||||
<div class="col-md-1" align="right">
|
||||
<a data-toggle="modal" data-target="#myModal1"><button type="button" class="btn btn-success" data-dismiss="modal" >Add Line Item</button> </a>
|
||||
if (!empty($POType)) {
|
||||
foreach ($SupplierName as $SID) :
|
||||
|
||||
|
||||
$options[$SID->SupplierID] = $SID->SupplierID . ' ' . ' - ' . ' ' . $SID->SupplierName;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('MaterialCode', $options, set_value('MaterialCode'), 'id="MaterialCode"', 'class="form-control required"', 'required="true"');
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="modal fade" id="myModal1" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
<!-- Modal content-->
|
||||
<form>
|
||||
<div class="modal-content" style="width:900px;">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<center><h4>Add Item </h4></center>
|
||||
<div class="col-md-4">
|
||||
<label>PO Date</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<label>Purchase Order Type</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<label>Supplier</label>
|
||||
<div class="form-control">
|
||||
<?php
|
||||
$options = array("0" => 'Supplier');
|
||||
//print_r( $options);
|
||||
|
||||
if (!empty($POType)) {
|
||||
foreach ($SupplierName as $SID) :
|
||||
|
||||
|
||||
$options[$SID->SupplierID] = $SID->SupplierID . ' ' . ' - ' . ' ' . $SID->SupplierName;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('MaterialCode', $options, set_value('MaterialCode'), 'id="MaterialCode"', 'class="form-control required"', 'required="true"');
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<label>Address</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<label>City</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div align="left">
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Req No</label>
|
||||
<div class="form-control">
|
||||
<?php
|
||||
$options = array("0"=>'Req No');
|
||||
//print_r( $options);
|
||||
|
||||
if(!empty($POType))
|
||||
{
|
||||
foreach ($SupplierName as $SID):
|
||||
|
||||
|
||||
$options[$SID->SupplierID] = $SID->SupplierID.' '.' - '.' '.$SID->SupplierName;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('MaterialCode', $options,set_value('MaterialCode'),'id="MaterialCode"' ,'class="form-control required"','required="true"');
|
||||
|
||||
?>
|
||||
</div>
|
||||
<div class="container-fluid">
|
||||
<table class="table table-bordered" style="border:1px solid #333">
|
||||
<div align="right" style="padding-right:10px">
|
||||
<div align="right">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3 col-md-offset-7" align="right" style="padding:10px">
|
||||
<!-- <input type="checkbox" id="IsOpenOrder" name="IsOpenOrder" value="1"> IS THIS OPEN ORDER FORMAT -->
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>Department Name</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Cost Center Name</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Available Budget Amount</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-2">
|
||||
<label>Item Code</label>
|
||||
<div class="form-control">
|
||||
<?php
|
||||
$options = array("0"=>'Item Code');
|
||||
//print_r( $options);
|
||||
|
||||
if(!empty($POType))
|
||||
{
|
||||
foreach ($SupplierName as $SID):
|
||||
|
||||
|
||||
$options[$SID->SupplierID] = $SID->SupplierID.' '.' - '.' '.$SID->SupplierName;
|
||||
<div class="col-md-1" align="right">
|
||||
<a data-toggle="modal" data-target="#myModal1"><button type="button" class="btn btn-success" data-dismiss="modal">Add Line Item</button> </a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('MaterialCode', $options,set_value('MaterialCode'),'id="MaterialCode"' ,'class="form-control required"','required="true"');
|
||||
<div class="modal fade" id="myModal1" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
<!-- Modal content-->
|
||||
<form>
|
||||
<div class="modal-content" style="width:900px;">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<center>
|
||||
<h4>Add Item </h4>
|
||||
</center>
|
||||
</div>
|
||||
<div align="left">
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-2">
|
||||
<label>Item Name</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label>UOM</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label>Quantity</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label>Rate Per unit</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label>Total Amount</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-4">
|
||||
|
||||
Service Tax @12% :
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'placeholder' => 'After Service Tax','required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-4">
|
||||
Edu. cess @2% on service Tax
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'placeholder' => 'After Edu.','required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
|
||||
<div class="col-md-4">
|
||||
Sec. & Higher Edu. cess @1 % on service Tax
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'placeholder' => 'After High Edu.','required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-4">
|
||||
Other Taxes
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'placeholder' => 'After Other Taxes','required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-6 col-md-offset-6">
|
||||
<label>Total Order value</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'placeholder' => 'Total value','required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Req No</label>
|
||||
<div class="form-control">
|
||||
<?php
|
||||
$options = array("0" => 'Req No');
|
||||
//print_r( $options);
|
||||
|
||||
if (!empty($POType)) {
|
||||
foreach ($SupplierName as $SID) :
|
||||
|
||||
|
||||
$options[$SID->SupplierID] = $SID->SupplierID . ' ' . ' - ' . ' ' . $SID->SupplierName;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('MaterialCode', $options, set_value('MaterialCode'), 'id="MaterialCode"', 'class="form-control required"', 'required="true"');
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>Department Name</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Cost Center Name</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label>Available Budget Amount</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-2">
|
||||
<label>Item Code</label>
|
||||
<div class="form-control">
|
||||
<?php
|
||||
$options = array("0" => 'Item Code');
|
||||
//print_r( $options);
|
||||
|
||||
if (!empty($POType)) {
|
||||
foreach ($SupplierName as $SID) :
|
||||
|
||||
|
||||
$options[$SID->SupplierID] = $SID->SupplierID . ' ' . ' - ' . ' ' . $SID->SupplierName;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('MaterialCode', $options, set_value('MaterialCode'), 'id="MaterialCode"', 'class="form-control required"', 'required="true"');
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-2">
|
||||
<label>Item Name</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label>UOM</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label>Quantity</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label>Rate Per unit</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label>Total Amount</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-4">
|
||||
|
||||
Service Tax @12% :
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'placeholder' => 'After Service Tax', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-4">
|
||||
Edu. cess @2% on service Tax
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'placeholder' => 'After Edu.', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
|
||||
<div class="col-md-4">
|
||||
Sec. & Higher Edu. cess @1 % on service Tax
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'placeholder' => 'After High Edu.', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-4">
|
||||
Other Taxes
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'placeholder' => 'After Other Taxes', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-6 col-md-offset-6">
|
||||
<label>Total Order value</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'placeholder' => 'Total value', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" value="submit">Add</button>
|
||||
<button type="button" class="btn btn-default" value="submit" data-dismiss="modal">Cancel</button>
|
||||
<button type="reset" class="btn btn-default" value="reset">Reset</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" value="submit">Add</button>
|
||||
<button type="button" class="btn btn-default" value="submit" data-dismiss="modal">Cancel</button>
|
||||
<button type="reset" class="btn btn-default" value="reset">Reset</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<br/>
|
||||
<!-- <thead style="background-color:#fff"> -->
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" name="name1" /> </th>
|
||||
<th>R No</th>
|
||||
<th>Item Name</th>
|
||||
<th>Quantity</th>
|
||||
<th>UOM</th>
|
||||
<th>Rate</th>
|
||||
<th>Tax %</th>
|
||||
<th>Total</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><input type="checkbox" name="name2" /> </td>
|
||||
<td>1</td>
|
||||
<td>001</td>
|
||||
<td>Waste Sand</td>
|
||||
<td>Ton</td>
|
||||
<td>100</td>
|
||||
<td>High</td>
|
||||
<td>No Change</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="checkbox" name="name2" /> </td>
|
||||
<td>2</td>
|
||||
<td>002</td>
|
||||
<td>Resin</td>
|
||||
<td>Litre</td>
|
||||
<td>50</td>
|
||||
<td>High</td>
|
||||
<td>Change</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="checkbox" name="name2" /> </td>
|
||||
<td>3</td>
|
||||
<td>003</td>
|
||||
<td>Resin</td>
|
||||
<td>Litre</td>
|
||||
<td>100</td>
|
||||
<td>High</td>
|
||||
<td>Change</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
<div class="col-md-3 col-md-offset-9">
|
||||
|
||||
<div class="form-group">
|
||||
<label>Total Order Value :</label> <?php
|
||||
$data = array('name' => 'Quantity','value' => set_value('Quantity'),'id'=>'Quantity', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div align="right" style="padding-right:10px">
|
||||
<button type="button" class="btn btn-success">Save</button>
|
||||
<button type="button" class="btn btn-success">Cancel</button>
|
||||
|
||||
</div>
|
||||
<br/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<br />
|
||||
<!-- <thead style="background-color:#fff"> -->
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" name="name1" /> </th>
|
||||
<th>R No</th>
|
||||
<th>Item Name</th>
|
||||
<th>Quantity</th>
|
||||
<th>UOM</th>
|
||||
<th>Rate</th>
|
||||
<th>Tax %</th>
|
||||
<th>Total</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><input type="checkbox" name="name2" /> </td>
|
||||
<td>1</td>
|
||||
<td>001</td>
|
||||
<td>Waste Sand</td>
|
||||
<td>Ton</td>
|
||||
<td>100</td>
|
||||
<td>High</td>
|
||||
<td>No Change</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="checkbox" name="name2" /> </td>
|
||||
<td>2</td>
|
||||
<td>002</td>
|
||||
<td>Resin</td>
|
||||
<td>Litre</td>
|
||||
<td>50</td>
|
||||
<td>High</td>
|
||||
<td>Change</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="checkbox" name="name2" /> </td>
|
||||
<td>3</td>
|
||||
<td>003</td>
|
||||
<td>Resin</td>
|
||||
<td>Litre</td>
|
||||
<td>100</td>
|
||||
<td>High</td>
|
||||
<td>Change</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
<div class="col-md-3 col-md-offset-9">
|
||||
|
||||
<div class="form-group">
|
||||
<label>Total Order Value :</label> <?php
|
||||
$data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control', 'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div align="right" style="padding-right:10px">
|
||||
<button type="button" class="btn btn-success">Save</button>
|
||||
<button type="button" class="btn btn-success">Cancel</button>
|
||||
|
||||
</div>
|
||||
<br />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@ -257,10 +257,10 @@
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="buttonContainer">
|
||||
<div class="buttonContainer">
|
||||
<a class="btn btn-cancel" data-dismiss="modal" value="Close">Close</a>
|
||||
<a class="btn btn-primary" id="draftIGR" value="draftIGR">Draft IGR</a>
|
||||
<a class="btn btn-primary" id="generateIGR" value="generateIGR">Generate IGR</a>
|
||||
<a class="btn btn-primary" data-dismiss="modal" value="Close">Close</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@ -345,7 +345,7 @@
|
||||
<div class="modal-footer">
|
||||
<center>
|
||||
<a class="btn btn-primary" onclick="modalSave()" id="modalsave"> <span class="bold">Save</span>
|
||||
<a class="btn btn-primary" data-dismiss="modal" value="Close">Close</a>
|
||||
<a class="btn btn-cancel" data-dismiss="modal" value="Close">Close</a>
|
||||
</center>
|
||||
</div><!-- footer div closed -->
|
||||
</div><!-- modal content div closed-->
|
||||
@ -365,7 +365,7 @@
|
||||
</div>
|
||||
<div style="margin:20px;" id="HisStatement"></div>
|
||||
<div style="text-align: right; margin:5px;">
|
||||
<a class="btn btn-success" data-dismiss="modal" value="Close">Close</a>
|
||||
<a class="btn btn-cancel" data-dismiss="modal" value="Close">Close</a>
|
||||
</div>
|
||||
<br />
|
||||
</div>
|
||||
@ -386,7 +386,7 @@
|
||||
|
||||
<div style="margin:20px;" id="CCStatement"></div>
|
||||
<div style="text-align: right; margin:5px;">
|
||||
<a class="btn btn-success" data-dismiss="modal" value="Close">Close</a>
|
||||
<a class="btn btn-cancel" data-dismiss="modal" value="Close">Close</a>
|
||||
</div>
|
||||
<br />
|
||||
</div>
|
||||
@ -430,7 +430,7 @@
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="modal-footer">
|
||||
<a class="btn btn-primary" data-dismiss="modal" value="close">Close</a>
|
||||
<a class="btn btn-cancel" data-dismiss="modal" value="close">Close</a>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
@ -468,8 +468,7 @@
|
||||
<div class="col-md-12 text-right">
|
||||
<div class="col-md-4 col-md-offset-8">
|
||||
<a class="btn btn-success" onclick="fileupdate()"> <span class="bold">Update</span>
|
||||
|
||||
<a class="btn btn-success" data-dismiss="modal" value="Close">Close</a>
|
||||
<a class="btn btn-success" data-dismiss="modal" value="Close">Close</a>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- /.modal footer -->
|
||||
@ -607,10 +606,10 @@
|
||||
var dcd2 = (String(dcd.getDate()).padStart(2, '0') + '-' + (String(dcd.getMonth() + 1).padStart(2, '0')) + '-' + dcd.getFullYear());
|
||||
$("#Invoice_Date").val(dcd2);
|
||||
console.log(item.MaterialRcvdDate)
|
||||
var Mat_rcv_date = (item.MaterialRcvdDate === null) ? ' ' : formatDateTime(new Date(item.MaterialRcvdDate));
|
||||
$("#MaterialRcvdDate").val(GrossWeightDate);
|
||||
var Mat_rcv_date = (item.MaterialRcvdDate === null) ? ' ' : formatDateTime(item.MaterialRcvdDate,1);
|
||||
$("#MaterialRcvdDate").val(Mat_rcv_date);
|
||||
console.log(item.MaterialRcvdDate)
|
||||
var gross_rcv_date = (item.GrossWeightDate === null) ? ' ' : formatDateTime(new Date(item.GrossWeightDate));
|
||||
var gross_rcv_date = (item.GrossWeightDate === null) ? ' ' : formatDateTime(item.GrossWeightDate,2);
|
||||
$("#ser").val(item.ServiceDescription);
|
||||
|
||||
i = i + 1;
|
||||
@ -869,7 +868,7 @@
|
||||
function constructSentence(record) {
|
||||
let str = record.field;
|
||||
let fieldName = str.replace(/([a-z])([A-Z])/g, '$1 $2');
|
||||
let sentence = record.FullName + ' on ' + formatDateTime(record.history_dated) + " " + fieldName + " ";
|
||||
let sentence = record.FullName + ' on ' + formatDateTime(record.history_dated,2) + " " + fieldName + " ";
|
||||
if (parseInt(record.is_add) === 1) {
|
||||
sentence += record.new_data + " was added.";
|
||||
} else if (parseInt(record.is_edit) === 1) {
|
||||
@ -1150,9 +1149,9 @@ function deleteBill(Billno,i){
|
||||
|
||||
// Set modal inputs with the retrieved values
|
||||
$("#GrossWeight").val(v1);
|
||||
$("#GrossWeightDate").val(v2);
|
||||
$("#GrossWeightDate").val(formatDateTime(v2,2));
|
||||
$("#TareWeight").val(v3);
|
||||
$("#TareWeightDate").val(v4);
|
||||
$("#TareWeightDate").val(formatDateTime(v4,2) );
|
||||
$("#NetWeight").val(v5);
|
||||
$("#CurrentInx").val(inx);
|
||||
|
||||
@ -1257,30 +1256,52 @@ function deleteBill(Billno,i){
|
||||
|
||||
</script>
|
||||
<script>
|
||||
function formatDateTime(dateString) {
|
||||
// Check if the date string is null
|
||||
if (dateString === null) {
|
||||
return ' ';
|
||||
} else {
|
||||
// Create a new Date object from the date string
|
||||
var date = new Date(dateString);
|
||||
function formatDateTime(dateString,flag) {
|
||||
// Note 1 means DATE only
|
||||
// 2 means DATE and Time
|
||||
// Check if the date string is null or empty
|
||||
if (!dateString || dateString === null || dateString === '0000-00-00 00:00:00') {
|
||||
return '';
|
||||
} else {
|
||||
|
||||
console.log("Received date string:", dateString);
|
||||
|
||||
// Extract date components
|
||||
var day = date.getDate().toString().padStart(2, '0');
|
||||
var month = (date.getMonth() + 1).toString().padStart(2, '0'); // Months are zero-based
|
||||
var year = date.getFullYear();
|
||||
// Split the date string into date and time components
|
||||
var dateTimeParts = dateString.split(' ');
|
||||
var dateParts = dateTimeParts[0].split('-');
|
||||
var timeParts = dateTimeParts[1].split(':');
|
||||
|
||||
// Extract time components
|
||||
var hours = date.getHours().toString().padStart(2, '0');
|
||||
var minutes = date.getMinutes().toString().padStart(2, '0');
|
||||
var seconds = date.getSeconds().toString().padStart(2, '0');
|
||||
// Extract individual components
|
||||
var year = parseInt(dateParts[0], 10);
|
||||
var month = parseInt(dateParts[1], 10) - 1; // Months are zero-based in JavaScript
|
||||
var day = parseInt(dateParts[2], 10);
|
||||
|
||||
// Format the date and time in DD-MM-YYYY HH:MM:SS format
|
||||
var formattedDate = `${day}-${month}-${year} ${hours}:${minutes}:${seconds}`;
|
||||
var hours = parseInt(timeParts[0], 10);
|
||||
var minutes = parseInt(timeParts[1], 10);
|
||||
var seconds = parseInt(timeParts[2], 10);
|
||||
|
||||
return formattedDate;
|
||||
}
|
||||
// Create a new Date object
|
||||
var date = new Date(year, month, day, hours, minutes, seconds);
|
||||
|
||||
// Extract date components
|
||||
var day = date.getDate().toString().padStart(2, '0');
|
||||
var month = (date.getMonth() + 1).toString().padStart(2, '0'); // Months are zero-based
|
||||
var year = date.getFullYear();
|
||||
|
||||
// Extract time components
|
||||
var hours = date.getHours().toString().padStart(2, '0');
|
||||
var minutes = date.getMinutes().toString().padStart(2, '0');
|
||||
var seconds = date.getSeconds().toString().padStart(2, '0');
|
||||
var formattedDate = '';
|
||||
// Format the date and time in DD-MM-YYYY HH:MM:SS format
|
||||
if(flag == 1){
|
||||
formattedDate = `${day}-${month}-${year}`;
|
||||
}else if (flag == 2){
|
||||
formattedDate = `${day}-${month}-${year} ${hours}:${minutes}:${seconds}`;
|
||||
}
|
||||
return formattedDate;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<script>
|
||||
function SetRemarks(RowId) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user