new OAID type "other" / added adrcd to preorderreporting api
This commit is contained in:
@@ -45,7 +45,8 @@ if ($argc > 1) {
|
||||
}
|
||||
|
||||
//$netowners = ["estmk", "rml"];
|
||||
$netowners = ["estmk", "rml"];
|
||||
//$netowners = ["estmk", "rml"];
|
||||
$netowners = ["sbidi"];
|
||||
//$netowners = ["rml"];
|
||||
$apiEdition = "prod";
|
||||
|
||||
@@ -188,6 +189,11 @@ foreach ($clusters as $cluster_data) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$preorder_only_oaid = false;
|
||||
$preorder_only_oaid = $adb_netzgebiet->getOption("preorder_only_oaid");
|
||||
$option_wo_ignore_status = $adb_netzgebiet->getOption("wo_ignore_status");
|
||||
|
||||
$AddressHelper = new ADBAddressHelper\AddressHelper(["log" => $log, "db" => $adb, "netzgebiet" => $adb_netzgebiet]);
|
||||
|
||||
/*
|
||||
@@ -436,7 +442,13 @@ foreach ($clusters as $cluster_data) {
|
||||
$rimo_oaid = $home->ftus->item[0]->oaidObject->name;
|
||||
$oaid = \OpenAccessIdModel::getFirst(["oaid" => $rimo_oaid]);
|
||||
if (!$oaid) {
|
||||
echo "!!! Home hat fremde OAID: $rimo_oaid (Home " . $unit->id . "\n";
|
||||
if($preorder_only_oaid) {
|
||||
// if campaign oaid handling "other" just import OAID and nothing else
|
||||
$unit->oaid = $rimo_oaid;
|
||||
$unit->save();
|
||||
} else {
|
||||
echo "!!! Home hat fremde OAID: $rimo_oaid (Home " . $unit->id . "\n";
|
||||
}
|
||||
} else {
|
||||
$unit->oaid = $rimo_oaid;
|
||||
|
||||
@@ -471,7 +483,7 @@ foreach ($clusters as $cluster_data) {
|
||||
}
|
||||
|
||||
} else {
|
||||
//
|
||||
// TODO maybe check if OAIDs match?
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -709,6 +721,8 @@ foreach ($clusters as $cluster_data) {
|
||||
continue;
|
||||
}
|
||||
|
||||
//if(($option_wo_ignore_status == "Documented" && $workorder_status == "Documented") || $workorder_status == "Cancelled") continue; // dont import status > Executed
|
||||
|
||||
\mfValuecache::singleton()->set("adbhausnummer-save-nesting-level-".$hausnummer->id, 0);
|
||||
\mfValuecache::singleton()->set("adbwohneinheit-save-nesting-level-".$unit->id, 0);
|
||||
//echo "Creating Workorder $rimo_workorder_id ($workorder_home_id)\n";
|
||||
|
||||
Reference in New Issue
Block a user