예제 #1
0
                // Or if the transaction type is a restock and the InventoryModelId matches, remove the index from the array.
                if (($this->ctlInventoryTransact->intTransactionTypeId == 1 || $this->ctlInventoryTransact->intTransactionTypeId == 4) && $value->InventoryLocationId == $strParameter || $this->ctlInventoryTransact->intTransactionTypeId == 4 && $value->InventoryModelId == $strParameter) {
                    unset($this->ctlInventoryTransact->objInventoryLocationArray[$key]);
                }
            }
        }
    }
    // Display the edit form
    public function DisplayEdit($blnDisplay)
    {
        if ($blnDisplay) {
            $this->ctlInventoryEdit->Display = true;
        } else {
            $this->ctlInventoryEdit->Display = false;
        }
    }
    // Display the transaction form
    public function DisplayTransaction($blnDisplay, $intTransactionTypeId = null)
    {
        if ($blnDisplay) {
            $this->ctlInventoryTransact->SetupDisplay($intTransactionTypeId);
            $this->ctlInventoryTransact->Display = true;
        } else {
            $this->ctlInventoryTransact->Display = false;
        }
    }
}
// Go ahead and run this form object to render the page and its event handlers, using
// generated/inventory_location_edit.php.inc as the included HTML template file
InventoryModelEditForm::Run('InventoryModelEditForm', 'inventory_edit.tpl.php');
예제 #2
0
// Include prepend.inc to load Qcodo
require '../includes/prepend.inc.php';
/* if you DO NOT have "includes/" in your include_path */
// require('prepend.inc.php');				/* if you DO have "includes/" in your include_path */
// Include the classfile for InventoryModelEditFormBase
require __FORMBASE_CLASSES__ . '/InventoryModelEditFormBase.class.php';
// Security check for ALLOW_REMOTE_ADMIN
// To allow access REGARDLESS of ALLOW_REMOTE_ADMIN, simply remove the line below
QApplication::CheckRemoteAdmin();
/**
 * This is a quick-and-dirty draft form object to do Create, Edit, and Delete functionality
 * of the InventoryModel class.  It extends from the code-generated
 * abstract InventoryModelEditFormBase class.
 *
 * Any display customizations and presentation-tier logic can be implemented
 * here by overriding existing or implementing new methods, properties and variables.
 *
 * Additional qform control objects can also be defined and used here, as well.
 * 
 * @package My Application
 * @subpackage FormDraftObjects
 * 
 */
class InventoryModelEditForm extends InventoryModelEditFormBase
{
}
// Go ahead and run this form object to render the page and its event handlers, using
// generated/inventory_model_edit.tpl.php as the included HTML template file
InventoryModelEditForm::Run('InventoryModelEditForm', 'generated/inventory_model_edit.tpl.php');