function save_data($data)
{
    if (DataProcess::saveData($data)) {
        print 'With Success data unpack and saved!';
        exit;
    }
    print "Data can't unpack save!";
    exit;
}
Exemple #2
0
<?php

include "lib/dataprocess.php";
$dataprocess = new DataProcess();
$dataprocess->settings();
if (isset($_GET['quote_ref'])) {
    $dataprocess->DeleteQuote($_GET['quote_ref']);
}
header('Location:index.php');
Exemple #3
0
<?php

session_start();
include "lib/dataprocess.php";
if (!isset($_SESSION["user_log"])) {
    header('Location:log.php?Error=Session Expired.');
}
$process = new DataProcess();
$process->settings();
?>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Quotation for paint works</title>
<head>
	<title></title>
    <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
	<link href="quote.css" type="text/css" rel="stylesheet" />
    <link href="listing.css" type="text/css" rel="stylesheet" />
	<script language="Javascript" type="text/javascript" src="quote.js"></script>
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
    <script language="Javascript" type="text/javascript" src="quote_print.js"></script>

	<style type="text/css"> 
	.spacer {width:30px}
	.overlay { width:100%; height:100%; position:absolute; top:0px; left:0px; background-color:rgba(0,0,0,0.5); z-index:20; display:none}
	.frmTerms { z-index:21; background-color:white; padding:10px; width:450px;  margin:0 auto; margin-top:25px; display:none }
	.frmOfferSupply {z-index:22; background-color:white; padding:10px; width:350px;  margin:0 auto; margin-top:25px; display:none;  }
	.frmOfferSupplyAndApply {z-index:23; background-color:white; padding:10px; width:450px;  margin:0 auto; margin-top:25px; display:none;  }
Exemple #4
0
<?php

include "lib/Dataprocess.php";
$dataprocess = new DataProcess();
$dataprocess->settings();
$breadCrumb = "Login";
?>

<?php 
include "header.php";
?>
    <div style='border:1px solid #ebebeb; width:350px; margin:0 auto; margin-top:35px'>
	<form action="login.php" method="post" name="form1">

        <table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
                <td width="60" style="text-align:center"><img src="img/login.png" alt="" width="24" height="24" /></td>
                <td>
                <p><b>Staff login</a></b></p>
                </td>
        </tr>
        <tr>
                <td width="60">&nbsp;</td>
                <td>&nbsp;</td>
        </tr>
        <tr>
                <td width="60">&nbsp;</td>
                <td>Username:<br />
				<input type="text" name="user" size="35" value=""  />                </td>
        </tr>
        <tr>
<?php

session_start();
include "lib/dataprocess.php";
$dataprocess = new DataProcess();
$dataprocess->settings();
//check if writable
$data = json_decode($_POST['data-holder']);
$file = $_POST['file'];
$product = "product.zip";
$zipname = $file . '.zip';
if (file_exists($zipname)) {
    unlink($zipname);
}
if (file_exists($product)) {
    unlink($product);
}
$zip = new ZipArchive();
//echo getcwd(). "\\" .$zipname;
// create and open the archive
if ($zip->open($product, ZipArchive::CREATE) !== TRUE) {
    die("Could not open archive");
}
switch ($res) {
    case ZipArchive::ER_NOZIP:
        die('not a zip archive');
    case ZipArchive::ER_INCONS:
        die('consistency check failed');
    case ZipArchive::ER_CRC:
        die('checksum failed');
        // ... check for the other types of errors listed in the manual
Exemple #6
0
<?php

include "lib/Dataprocess.php";
$dataprocess = new DataProcess();
$dataprocess->settings();
include "header.php";
?>
    
<table width="100%" border="0" class='white' cellpadding="0" cellspacing="1">
    	<thead>
        <tr>
            <th width="4%"></th>
            <th width="45%"></th>
            <th width="10%">1st time Company<br/>Introduction</th>
            <th width="10%">Bidding</th>
            <th width="10%">Consultants</th>
            <th width="21%">Remarks</th>
        </tr>
        </thead>
        <tbody>
        <?php 
$getRow = $dataprocess->GetBiddingTable();
$i = 1;
$bid = 1;
$con = 1;
foreach ($getRow as $e) {
    echo "<tr>" . PHP_EOL . "";
    echo "<td>" . ($e['main'] == 1 ? $i : "") . "</td>" . PHP_EOL . "";
    echo "<td>" . $e["title"] . "</td>" . PHP_EOL . "";
    if ($e["company_introduction"] != '' && $i == 1) {
        echo "<td rowspan='30' style='text-align:center'><input type='checkbox' value='CompanyProfile.pdf'></td>" . PHP_EOL . "";
<?php

include "lib/dataprocess.php";
$dp = new DataProcess();
$dp->settings();
$row = $dp->checkifemailormobileExist($_GET['email'], $_GET['mobile']);
if (count($row) < 1) {
    $row = array();
}
echo json_encode($row);
Exemple #8
0
<?php

session_start();
if (!isset($_SESSION['user_log'])) {
    header('Location: log.php');
}
include "lib/Dataprocess.php";
$dataprocess = new DataProcess();
$dataprocess->settings();
$breadCrumb = "Submittal";
?>

<?php 
include "header.php";
?>
<style>
#accordion li { list-style:none}
</style>
 <form id='biddingFrom'>   
<table width="100%" border="0" class='white' cellpadding="0" cellspacing="1">
    	<thead>
        <tr>

            <th width="33%">1st time Company<br/>Introduction</th>
            <th width="33%">Bidding</th>
            <th width="34%">Consultants</th>

        </tr>
        </thead>
       
        <tbody>
Exemple #9
0
<?php

session_start();
//------------IF the person is not login. It will go back to login.php for authentication
if (!isset($_SESSION['user_log'])) {
    header('Location: log.php');
}
include "lib/dataprocess.php";
$dataprocess = new DataProcess();
$dataprocess->settings();
// GET THE LIST OF QUOTATION OF THE PERSON WHO LOGGED-IN
$rows = $dataprocess->getListing($_SESSION['user_log'], 'Q');
// GET THE LIST OF QUOTATION IN DRAFT OF THE PERSON WHO LOGGED-IN
$rowsDraft = $dataprocess->getListing($_SESSION['user_log'], 'D');
?>
<!DOCTYPE html>
<html>
<head>
	<title>><?php 
echo $_SESSION['company'];
?>
 - Quotation - Staff login</title>
    <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
	<link href="quote.css" type="text/css" rel="stylesheet" />
	<script language="Javascript" type="text/javascript" src="quote.js"></script>
	<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
    <script language="Javascript" type="text/javascript" src="js/listing.js"></script>
	<link href="listing.css" type="text/css" rel="stylesheet" />
</head>
<body >
 /**
  * function report()
  * A function that is similar to search()
  * But this function will return in a new page for print and report purpose.
  * @return string		string of the contents
  */
 public function report()
 {
     $dataProcess = new DataProcess(trim($_POST['ticketNumber']), trim($_POST['passengerName']), trim($_POST['rloc']), trim($_POST['date-from-field']), trim($_POST['date-to-field']), trim($_POST['system-selector']));
     $ticketNumber = $dataProcess->getTicketNumber();
     $passengerName = $dataProcess->getPassengerName();
     $rloc = $dataProcess->getRloc();
     $fromDate = $dataProcess->getNewFromDate();
     $toDate = $dataProcess->getNewToDate();
     if (empty($ticketNumber . $passengerName . $rloc . $fromDate . $toDate)) {
         return View::make('date', array('long' => 'Please enter at least one search condition.', 'back' => true));
     }
     $query = Document::query();
     $dataProcess->getQuery($query);
     $model = $query->orderBy('dateString', 'asc')->orderBy('documents_id', 'asc')->get();
     if (sizeof($model) > 0) {
         $longString = null;
         foreach ($model as $key => $value) {
             $document = $value->getAttributes();
             $content = "<div>" . $document['fileContent'] . "</div><hr>";
             $longString .= $content;
         }
     } else {
         $longString = 'Sorry the document does not exist, or hasn not been update yet, please click update and try again.';
     }
     return View::make('date', array('long' => $longString, 'back' => false));
 }
<?php

include "lib/dataprocess.php";
$dataprocess = new DataProcess();
$dataprocess->settings();
$a = explode(",", $_GET['q']);
$row = $dataprocess->getInfo($a[0]);
$apost = array("txtfullname" => $row[0]['fullname'], "txtemail" => $row[0]['email'], "txtmobile" => $row[0]['mobile'], "cmbcountry" => $row[0]['country'], "service" => $a[1] == '1' ? 'store' : ($a[1] == '2' ? 'consultation' : 'application'));
$dataprocess->sendfeedback($apost, $a[0]);
header('Location:listing.php');
<?php

include "lib/dataprocess.php";
$dataprocess = new DataProcess();
$dataprocess->settings();
$id = $dataprocess->feedback($_POST);
$dataprocess->sendfeedback($_POST, $id);
header('Location:entry.php?msg=Successfully save !!!');
Exemple #13
0
<?php

session_start();
include "lib/dataprocess.php";
if (!isset($_SESSION["user_log"])) {
    header('Location:log.php?Error=Session Expired.');
}
$process = new DataProcess();
$process->settings();
?>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Quotation for paint works</title>
<head>
	<title></title>
    <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
	<link href="quote.css" type="text/css" rel="stylesheet" />
    <link href="listing.css" type="text/css" rel="stylesheet" />
	<script language="Javascript" type="text/javascript" src="quote.js"></script>
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
    <script language="Javascript" type="text/javascript" src="quote_print.js"></script>
	<style type="text/css"> 
	.spacer {width:30px}
	.overlay { width:100%; height:100%; position:absolute; top:0px; left:0px; background-color:rgba(0,0,0,0.5); z-index:20; display:none}
	.frmTerms { z-index:21; background-color:white; padding:10px; width:450px;  margin:0 auto; margin-top:25px; display:none }
	.frmOfferSupply {z-index:22; background-color:white; padding:10px; width:350px;  margin:0 auto; margin-top:25px; display:none;  }
	.frmOfferSupplyAndApply {z-index:23; background-color:white; padding:10px; width:450px;  margin:0 auto; margin-top:25px; display:none;  }
	.supply {display:none}
Exemple #14
0
<?php

session_start();
include "lib/dataprocess.php";
if (!isset($_SESSION["user_log"])) {
    header('Location:log.php?Error=Session Expired.');
}
$process = new DataProcess();
$process->settings();
?>
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Quote Printing</title>
<style  type="text/css">
	
	  @page { @top-center { content: element(xx) }} 
    
</style>
</head>

<body>
<table>
   <thead class='ph'><tr><td>
   <!---header repeat--->
    <div class='xx'> xx------------------------------------------------------------------------xx</div>
   <!---end header repeat--->
   
   </td></tr></thead>
   <tbody>
Exemple #15
0
                 <td class='spacer'>&nbsp;</td>
        </tr>
       <tr>
                <td class='spacer'>&nbsp;</td>
                <td width="120">Attention</td><td><input type="text" name="attention" id="attention" size="55" value=""  /></td>
                 <td class='spacer'>&nbsp;</td>
        </tr>
        <tr>
                <td class='spacer'>&nbsp;</td>
                <td width="120">Kansai Contact</td><td>
                
                <!--<input type="text" name="contact" id="contact" size="55" value=""  />-->
                <select name="contact" id="contact">
                	<option value=''>-- Select sales personnel --</option> 
                    <?php 
$process = new DataProcess();
$process->settings();
$process->salespersonnel();
$process->disconnectDb();
?>
                </select>
                
                </td>
                 <td class='spacer'>&nbsp;</td>
        </tr> 
       <tr>
                <td class='spacer'>&nbsp;</td>
                <td width="120">Business Type</td><td>&nbsp;&nbsp;&nbsp;&nbsp;<input type="radio" name="sg" id="sg1" value="Supply" class='sc'/>&nbsp;Supply&nbsp;<input type="radio" name="sg"  id="sg2" value="Supply & Apply" class='sc'/>Supply & Apply&nbsp;</td>
                 <td class='spacer'>&nbsp;</td>
        </tr>
         <tr>
Exemple #16
0
<?php

require "dataprocess.php";
$dataprocess = new DataProcess();
$dataprocess->settings();
$data = json_decode($_POST['valueholder']);
$dataprocess->saveDraftorQuote($data, $_POST['bttnclick']);
$uri = rtrim(dirname($_SERVER['PHP_SELF']), '/\\');
$host = $_SERVER['DOCUMENT_ROOT'];
header("Location:../index.php");
exit;
Exemple #17
0
<?php

session_start();
include 'lib/dataprocess.php';
$dataprocess = new DataProcess();
$dataprocess->settings();
// Send a raw HTTP header
header('Content-Type: text/html; charset=UTF-8');
// Declare encoding META tag, it causes browser to load the UTF-8 charset
// before displaying the page.
echo '<meta http-equiv="Content-type" content="text/html; charset=UTF-8" />';
$rows = $dataprocess->Login($_POST['user'], $_POST['pass']);
if (count($rows) > 0) {
    $_SESSION['fullname'] = $rows[0]['fullname'];
    $_SESSION['user_log'] = $rows[0]['username'];
    $_SESSION['pwd'] = $rows[0]['password'];
    $_SESSION['company'] = $rows[0]['company'];
    $_SESSION['company_lang'] = $rows[0]['company_lang'];
    $_SESSION['address'] = $rows[0]['address'];
    $_SESSION['address_lang'] = $rows[0]['address_lang'];
    $_SESSION['entity_id'] = $rows[0]['entity_id'];
    $_SESSION['authorize_signatory'] = $rows[0]['authorize_signatory'];
    $_SESSION['currency'] = $rows[0]['currency'];
    header('Location: index.php');
} else {
    header('Location:log.php?Error=Invalid username or password.');
}
<?php

session_start();
$_SESSION['pwd'] = $_POST['pwd'];
include "lib/dataprocess.php";
$dataprocess = new DataProcess();
$dataprocess->settings();
$dataprocess->ChangePassword($_POST['username'], $_POST['pwd']);
header("Location: user.php?msg=Password already updated.");