| @@ 987-993 (lines=7) @@ | ||
| 984 | return $result->getArray($key); |
|
| 985 | } |
|
| 986 | $list = $result->getObjects(get_called_class(), $key); |
|
| 987 | if (!empty($options['forSelect'])) { |
|
| 988 | $return = []; |
|
| 989 | foreach ($list as $key => $item) { |
|
| 990 | $return[$key] = $item->name(); |
|
| 991 | } |
|
| 992 | return $return; |
|
| 993 | } |
|
| 994 | return $list; |
|
| 995 | } |
|
| 996 | ||
| @@ 1119-1125 (lines=7) @@ | ||
| 1116 | return 0; |
|
| 1117 | }); |
|
| 1118 | } |
|
| 1119 | if (!empty($options['forSelect'])) { |
|
| 1120 | $return = []; |
|
| 1121 | foreach ($items as $key => $item) { |
|
| 1122 | $return[$key] = $item->name(); |
|
| 1123 | } |
|
| 1124 | return $return; |
|
| 1125 | } |
|
| 1126 | return $items; |
|
| 1127 | } |
|
| 1128 | return []; |
|