-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of git@github.com:maxolasersquad/FLOSS-POS
- Loading branch information
Showing
3 changed files
with
87 additions
and
195 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,146 +1,66 @@ | ||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> | ||
<html lang="en"> | ||
<head> | ||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> | ||
<title>Fannie - Item Maintenance</title> | ||
<link rel="STYLESHEET" href="../style.css" type="text/css"> | ||
</head> | ||
<body bgcolor="FFFFFF"> | ||
<div align="center"> | ||
<table width="750" border="0" cellpadding="0" cellspacing="0"> | ||
<tr> | ||
<td colspan="3" width="750"> | ||
<table width="750" border="0" cellpadding="0" cellspacing="0"> | ||
<tr> | ||
<td width="750" colspan="3"> | ||
<span style="font-size:28px;color:330066"> | ||
Fannie | ||
</span> | ||
</td> | ||
</tr> | ||
<tr> | ||
<td width="330"> | ||
<span style="font-size:20px;color:666666"> | ||
IS4C maintenance & reporting | ||
</span> | ||
</td> | ||
<td width="400" align="right"> | ||
<table width="400" border="0" cellpadding="0" cellspacing="0"> | ||
<tr> | ||
<td align="right" height="20"> | ||
<span style="color:AAAAAA"> | ||
search for product | ||
</span> | ||
<input type="text" onFocus="this.style.background='FFFFFF';" onBlur="this.style.background='F9F9F9';"> | ||
<input type="submit" style="padding:0;background-color:330066;border:0;color:FFFFFF;width:25;font-weight:bold" value="GO"> | ||
</td> | ||
</tr> | ||
</table> | ||
</td> | ||
<td width="20"></td> | ||
</tr> | ||
</table> | ||
</td> | ||
</tr> | ||
<tr> | ||
<td colspan="3" height="15" bgcolor="FFFFFF"></td> | ||
</tr> | ||
<tr> | ||
<td colspan="3" height="1" bgcolor="CCCCCC"></td> | ||
</tr> | ||
<tr> | ||
<td colspan="3" height="10" bgcolor="FFFFFF"></td> | ||
</tr> | ||
<tr> | ||
<td width="170" bgcolor="FFFFFF" valign="top"> | ||
<span style="font-size:6px"><br></span> | ||
<div align="center"> | ||
<?php | ||
include_once('../navbar.html'); | ||
?> | ||
<span style="font-size:6px"><br></span> | ||
</div> | ||
</td> | ||
<td width="1" bgcolor="CCCCCC"></td> | ||
<td width="579" valign="top"> | ||
<span style="font-size:6px"><br></span> | ||
<div align="center"> | ||
<table width="549" border="0" cellpadding="0" cellspacing="0"> | ||
<tr> | ||
<td colspan="4" height="1" bgcolor="AAAAAA"></td> | ||
<td width="5" height="1" bgcolor="FFFFFF"></td> | ||
</tr> | ||
<tr> | ||
<td width="1" bgcolor="AAAAAA"></td> | ||
<td rowspan="2" colspan="2" width="542" height="27" bgcolor="F9F9F9" style="color:330066;font-size:15px"> Update Registers</td> | ||
<td width="1" bgcolor="AAAAAA"></td> | ||
<td width="5" height="4" bgcolor="FFFFFF"></td> | ||
</tr> | ||
<tr> | ||
<td width="1" bgcolor="AAAAAA"></td> | ||
<td width="1" bgcolor="AAAAAA"></td> | ||
<td width="5" bgcolor="F0F0F0" height="23"></td> | ||
</tr> | ||
<tr> | ||
<td width="1" bgcolor="AAAAAA"></td> | ||
<td colspan="2" height="1" bgcolor="AAAAAA"></td> | ||
<td width="1" bgcolor="AAAAAA"></td> | ||
<td width="5" bgcolor="F0F0F0"></td> | ||
</tr> | ||
<tr> | ||
<td width="1" bgcolor="AAAAAA"></td> | ||
<td colspan="2" bgcolor="FFFFFF"> | ||
<table width="542" border="0" cellpadding="17" cellspacing="0"> | ||
<tr> | ||
<td style="color:999999;line-height:1.6em"> | ||
<div align="justify"> | ||
<? | ||
include("reload.php"); | ||
<?php | ||
/* | ||
* Some places may be comfortable posting the form back to this page and | ||
* using a status message to signal a successful synchronization. At the | ||
* Wedge, we're more comfortable displaying the results per lane on a | ||
* different page (synchronizeproducts.php) -jdp | ||
*/ | ||
|
||
reloadtable("tenders"); | ||
require_once($_SERVER["DOCUMENT_ROOT"]."/define.conf"); | ||
|
||
?> | ||
</div> | ||
</td> | ||
</tr> | ||
</table> | ||
</td> | ||
<td width="1" bgcolor="AAAAAA"></td> | ||
<td width="5" bgcolor="F0F0F0"></td> | ||
</tr> | ||
<tr> | ||
<td width="1" bgcolor="AAAAAA"></td> | ||
<td colspan="2" height="1" bgcolor="AAAAAA"></td> | ||
<td width="1" bgcolor="AAAAAA"></td> | ||
<td width="5" bgcolor="F0F0F0"></td> | ||
</tr> | ||
<tr> | ||
<td width="1" height="5" bgcolor="FFFFFF"></td> | ||
<td width="4" height="5" bgcolor="FFFFFF"></td> | ||
<td width="538" height="5" bgcolor="F0F0F0"></td> | ||
<td width="1" height="5" bgcolor="F0F0F0"></td> | ||
<td width="5" height="5" bgcolor="F0F0F0"></td> | ||
</tr> | ||
</table> | ||
<span style="font-size:6px"><br></span> | ||
</div> | ||
</td> | ||
</tr> | ||
<tr> | ||
<td colspan="3" height="10" bgcolor="FFFFFF"></td> | ||
</tr> | ||
<tr> | ||
<td colspan="3" height="1" bgcolor="CCCCCC"></td> | ||
</tr> | ||
<tr> | ||
<td colspan="3" height="5" bgcolor="FFFFFF"></td> | ||
</tr> | ||
<tr> | ||
<td colspan="3" bgcolor="FFFFFF" align="right"> | ||
Copyleft © 2006, <a href="http://www.designslife.com" style="font-size:12px;color:AAAAAA">designslife</a>. All Rights Reserved. | ||
</td> | ||
</tr> | ||
</table> | ||
</div> | ||
</body> | ||
</html> | ||
$html='<!DOCTYPE HTML> | ||
<html> | ||
<head> | ||
<link href="screen.css" media="screen" rel="stylesheet" type="text/css"/> | ||
<title>Synchronization - Products</title> | ||
</head> | ||
<body> | ||
<h1>Synchronize Products</h1> | ||
<form action="./synchronizeproducts.php" method="post" name="synchronize_products">'; | ||
|
||
// TODO - Auto generate lanes from define.conf, for now, hardcode | ||
$lanes=array( | ||
array('Name'=>'Lane 01', 'IP'=>'10.10.10.115'), | ||
array('Name'=>'Fake', 'IP'=>'10.10.10.100') | ||
); | ||
foreach ($lanes as $lane) { | ||
$html.=' | ||
<label>'.$lane['Name'].'</label> | ||
<input checked name="lanes[]" type="checkbox" value="'.$lane['IP'].'"/>'; | ||
} | ||
|
||
$html.=' | ||
<input type="submit"/> | ||
</form> | ||
<p class="status">'; | ||
|
||
$link=mysql_connect($_SESSION["mServer"], $_SESSION["mUser"], $_SESSION["mPass"]); | ||
if ($link) { | ||
$query='SELECT `synchronizationLog`.`datetime` FROM `is4c_log`.`synchronizationLog` WHERE `synchronizationLog`.`name`=\'product\' AND `synchronizationLog`.`status`=1 ORDER BY `synchronizationLog`.`datetime` DESC LIMIT 1'; | ||
$result=mysql_query($query, $link); | ||
if ($result && mysql_num_rows($result)==1) { | ||
$row=mysql_fetch_array($result); | ||
$html.='Last synchronized @ '.$row['datetime']; | ||
|
||
$query='SELECT COUNT(*) AS \'count\' FROM `is4c_op`.`products` WHERE `products`.`modified`>=\''.$row['datetime'].'\''; | ||
$result=mysql_query($query, $link); | ||
if ($result && mysql_num_rows($result)==1) { | ||
$row=mysql_fetch_array($result); | ||
$html.='</p> | ||
<p>'.$row['count'].' unsynchronized product'.(($row['count']==1)?'':'s'); | ||
} else { | ||
// Should the user be notified? | ||
} | ||
} else { | ||
$html.='Unable to query synchronization log.'; | ||
} | ||
} else { | ||
$html.='Unable to connect to main server.'; | ||
} | ||
|
||
$html.='</p> | ||
</body> | ||
</html>'; | ||
|
||
print_r($html); | ||
?> |