43 lines
1.1 KiB
PHP
43 lines
1.1 KiB
PHP
#!/usr/bin/php
|
|
<?php
|
|
|
|
//require 'vendor/autoload.php';
|
|
require("../../config/config.php");
|
|
|
|
define('FRONKDB_SQLDEBUG',false);
|
|
error_reporting(E_ALL & ~(E_NOTICE | E_STRICT | E_DEPRECATED));
|
|
|
|
require_once(LIBDIR."/mvcfronk/mfRouter/mfRouter.php");
|
|
require_once(LIBDIR."/mvcfronk/mfBase/mfBaseModel.php");
|
|
require_once(LIBDIR."/mvcfronk/mfBase/mfBaseController.php");
|
|
|
|
$me = new User(1);
|
|
|
|
foreach(ContractModel::getAll() as $contract) {
|
|
$address = new Address($contract->owner_id);
|
|
if(!$address) {
|
|
echo "contract id ".$contract->id." missing owner\n";
|
|
}
|
|
|
|
if($contract->billingaddress_id) {
|
|
$address = new Address($contract->billingaddress_id);
|
|
if(!$address) {
|
|
echo "contract id ".$contract->id." missing billingaddress\n";
|
|
}
|
|
}
|
|
}
|
|
|
|
foreach(OrderModel::getAll() as $order) {
|
|
$address = new Address($order->owner_id);
|
|
if(!$address) {
|
|
echo "order id ".$order->id." missing owner\n";
|
|
}
|
|
|
|
if($order->billingaddress_id) {
|
|
$address = new Address($order->billingaddress_id);
|
|
if(!$address) {
|
|
echo "order id ".$order->id." missing billingaddress\n";
|
|
}
|
|
}
|
|
}
|