1
0
mirror of https://github.com/fspc/Yellow-Bike-Database.git synced 2025-02-23 01:03:23 -05:00

Patron must be signed-in to complete a storage transaction.

This commit is contained in:
Jonathan Rosenbaum 2015-01-28 19:31:27 +00:00
parent c31551d66a
commit 6b8e10355f
2 changed files with 23 additions and 9 deletions

View File

@ -130,6 +130,7 @@ $(function() {
var diff = Number(obj.changed_change) - Number(obj.change); var diff = Number(obj.changed_change) - Number(obj.change);
var str = this.id; var str = this.id;
var id = str.match(/\d+/); var id = str.match(/\d+/);
if (diff != 0) { if (diff != 0) {
/* /*
if(!$("#" + id[0] + "_different_change").length) { if(!$("#" + id[0] + "_different_change").length) {
@ -648,17 +649,30 @@ $(function() {
$("#payment_type").hide(); $("#payment_type").hide();
} }
$("#date_fill").click(function(){ $("#date_fill").click(function(e){
var span_or_select = $("[name='sold_to']").is("span"), err0;
if(span_or_select) {
err0 = error_handler(span_or_select, date_error, true, "*Patron must be signed in to complete this transaction.",e);
}
if (err0 != 1) {
$("#price").show(); $("#price").show();
$("#payment_type").show(); $("#payment_type").show();
}
}) })
$("#date").on("input", function(){ $("#date").on("input", function(e){
var span_or_select = $("[name='sold_to']").is("span"), err0;
if(span_or_select) {
err0 = error_handler(span_or_select, date_error, true, "*Patron must be signed in to complete this transaction.",e);
}
date_test = /^\d{4}-((0\d)|(1[012]))-(([012]\d)|3[01])$/.test(this.value); date_test = /^\d{4}-((0\d)|(1[012]))-(([012]\d)|3[01])$/.test(this.value);
if ( date_test && this.value != "0000-00-00" ) { if ( date_test && this.value != "0000-00-00" ) {
if (err0 != 1) {
$("#price").show(); $("#price").show();
$("#payment_type").show(); $("#payment_type").show();
}
} else { } else {
$("#amount").val(""); $("#amount").val("");
$("#price").hide(); $("#price").hide();

View File

@ -414,10 +414,10 @@ if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "ChangeDate")) {
<tr><td>&nbsp;</td> <tr><td>&nbsp;</td>
<td><label>Transaction #:</label></td> <td><label>Transaction #:</label></td>
<td><?php echo $row_Recordset2['transaction_id']; ?> <td><em><?php echo $row_Recordset2['transaction_id']; ?>
<em><?php echo $row_Recordset3['message_transaction_id']; ?>
- -
<?php echo $row_Recordset2['shop_id']; ?></em> <?php echo $row_Recordset2['shop_id'];
echo "&nbsp;&nbsp" . $row_Recordset3['message_transaction_id'];?></em>
<input name="shop_id" type="hidden" id="shop_id" <input name="shop_id" type="hidden" id="shop_id"
value="<?php echo $row_Recordset2['shop_id']; ?>" /> value="<?php echo $row_Recordset2['shop_id']; ?>" />
</td> </td>