| @@ 134-141 (lines=8) @@ | ||
| 131 | ||
| 132 | $hide_groups = json_decode($this->config_text->get('phpbb_ads_hide_groups'), true); |
|
| 133 | $groups = $this->manager->load_groups(); |
|
| 134 | foreach ($groups as $group) |
|
| 135 | { |
|
| 136 | $this->template->assign_block_vars('groups', array( |
|
| 137 | 'ID' => $group['group_id'], |
|
| 138 | 'NAME' => $this->group_helper->get_name($group['group_name']), |
|
| 139 | 'S_SELECTED' => in_array($group['group_id'], $hide_groups), |
|
| 140 | )); |
|
| 141 | } |
|
| 142 | ||
| 143 | $this->template->assign_vars(array( |
|
| 144 | 'U_ACTION' => $this->u_action, |
|
| @@ 71-79 (lines=9) @@ | ||
| 68 | */ |
|
| 69 | public function assign_locations($ad_locations = false) |
|
| 70 | { |
|
| 71 | foreach ($this->location_manager->get_all_locations() as $location_id => $location_data) |
|
| 72 | { |
|
| 73 | $this->template->assign_block_vars('ad_locations', array( |
|
| 74 | 'LOCATION_ID' => $location_id, |
|
| 75 | 'LOCATION_DESC' => $location_data['desc'], |
|
| 76 | 'LOCATION_NAME' => $location_data['name'], |
|
| 77 | 'S_SELECTED' => $ad_locations ? in_array($location_id, $ad_locations) : false, |
|
| 78 | )); |
|
| 79 | } |
|
| 80 | } |
|
| 81 | ||
| 82 | /** |
|