changes linework to openable list

This commit is contained in:
Frank Schubert
2022-02-15 20:41:59 +01:00
parent a7ed80f6b9
commit 9f908e56db
17 changed files with 729 additions and 11 deletions
@@ -0,0 +1,30 @@
<?php
class ContractconfigGroup extends mfBaseModel {
private $items;
private $value;
public function getProperty($name) {
if($this->$name == null) {
if($name == "items") {
$this->items = ContractconfigItemModel::search(['group_id' => $this->id]);
return $this->items;
}
$classname = ucfirst($name);
$idfield = $name."_id";
$this->$name = new $classname($this->$idfield);
if($this->$name->id) {
return $this->$name;
} else {
return null;
}
}
return $this->$name;
}
}