Switch all array init calles to no space before bracket
Also bug fix in Form General for load int PK calls with non int types
This commit is contained in:
@@ -437,10 +437,10 @@ class Generate extends \CoreLibs\DB\Extended\ArrayIO
|
||||
// next for functions are pre_test fkts for easier default new,load, etc handling
|
||||
/**
|
||||
* default load procedure
|
||||
* @param int $archive_id archive id to load
|
||||
* @param string $archive_id archive id to load
|
||||
* @return void has no return
|
||||
*/
|
||||
public function formProcedureLoad(int $archive_id): void
|
||||
public function formProcedureLoad(string $archive_id): void
|
||||
{
|
||||
if ($this->archive && $archive_id && $this->base_acl_level >= $this->security_level['load']) {
|
||||
$this->formLoadTableArray($archive_id);
|
||||
@@ -742,8 +742,9 @@ class Generate extends \CoreLibs\DB\Extended\ArrayIO
|
||||
$data['value'][] = $i;
|
||||
$data['output'][] = $this->table_array[$element_name]['element_list'][$i];
|
||||
$data['name'] = $element_name;
|
||||
if (($i && isset($this->table_array[$element_name]['value'])) ||
|
||||
(!$i && !isset($this->table_array[$element_name]['value']))
|
||||
if (isset($this->table_array[$element_name]['value']) &&
|
||||
(($i && $this->table_array[$element_name]['value']) ||
|
||||
(!$i && !$this->table_array[$element_name]['value']))
|
||||
) {
|
||||
$data['checked'] = $this->table_array[$element_name]['value'];
|
||||
}
|
||||
@@ -1248,10 +1249,10 @@ class Generate extends \CoreLibs\DB\Extended\ArrayIO
|
||||
|
||||
/**
|
||||
* load a table & reference
|
||||
* @param int|null $pk_id overrule pk_id
|
||||
* @param string|null $pk_id overrule pk_id
|
||||
* @return void has no return
|
||||
*/
|
||||
public function formLoadTableArray(?int $pk_id = null): void
|
||||
public function formLoadTableArray(?string $pk_id = null): void
|
||||
{
|
||||
if ($pk_id) {
|
||||
$this->pk_id = $pk_id;
|
||||
|
||||
Reference in New Issue
Block a user