|
193 | 193 | $tpl->assign('form', $formToString); |
194 | 194 |
|
195 | 195 | // Default URL |
196 | | -$url = Display::url( |
| 196 | +$urlList[] = Display::url( |
197 | 197 | $plugin->get_lang('EnterConference'), |
198 | 198 | $conferenceUrl, |
199 | 199 | ['target' => '_blank', 'class' => 'btn btn-primary btn-large'] |
200 | 200 | ); |
201 | 201 |
|
202 | 202 | $type = $plugin->get('launch_type'); |
203 | 203 | $warningIntefaceMessage = ''; |
| 204 | +$showClientOptions = false; |
204 | 205 |
|
205 | 206 | switch ($type) { |
206 | 207 | case BBBPlugin::LAUNCH_TYPE_DEFAULT: |
207 | | - $url = Display::url( |
| 208 | + $urlList = []; |
| 209 | + $urlList[] = Display::url( |
208 | 210 | $plugin->get_lang('EnterConference'), |
209 | 211 | $conferenceUrl.'&interface='.$plugin->get('interface'), |
210 | 212 | ['target' => '_blank', 'class' => 'btn btn-primary btn-large'] |
211 | 213 | ); |
212 | 214 | break; |
213 | 215 | case BBBPlugin::LAUNCH_TYPE_SET_BY_TEACHER: |
214 | 216 | if ($conferenceManager) { |
215 | | - $url = $plugin->getUrlInterfaceLinks($conferenceUrl); |
| 217 | + $urlList = $plugin->getUrlInterfaceLinks($conferenceUrl); |
216 | 218 | $warningIntefaceMessage = Display::return_message($plugin->get_lang('ParticipantsWillUseSameInterface')); |
| 219 | + $showClientOptions = true; |
217 | 220 | } else { |
218 | 221 | $meetingInfo = $bbb->getMeetingByName($videoConferenceName); |
219 | 222 | switch ($meetingInfo['interface']) { |
|
228 | 231 | break; |
229 | 232 | case BBBPlugin::LAUNCH_TYPE_SET_BY_STUDENT: |
230 | 233 | if ($conferenceManager) { |
231 | | - $url = $plugin->getUrlInterfaceLinks($conferenceUrl); |
| 234 | + $urlList = $plugin->getUrlInterfaceLinks($conferenceUrl); |
| 235 | + $showClientOptions = true; |
232 | 236 | } else { |
233 | 237 | if ($meetingExists) { |
234 | 238 | $meetingInfo = $bbb->getMeetingByName($videoConferenceName); |
235 | 239 | $meetinUserInfo = $bbb->getMeetingParticipantInfo($meetingInfo['id'], api_get_user_id()); |
236 | | - $url = $plugin->getUrlInterfaceLinks($conferenceUrl); |
| 240 | + $urlList = $plugin->getUrlInterfaceLinks($conferenceUrl); |
| 241 | + $showClientOptions = true; |
237 | 242 |
|
238 | 243 | /*if (empty($meetinUserInfo)) { |
239 | 244 | $url = $plugin->getUrlInterfaceLinks($conferenceUrl); |
|
253 | 258 | break; |
254 | 259 | } |
255 | 260 |
|
256 | | -$tpl->assign('enter_conference_links', $url); |
| 261 | +$tpl->assign('enter_conference_links', $urlList); |
257 | 262 | $tpl->assign('warning_inteface_msg', $warningIntefaceMessage); |
| 263 | +$tpl->assign('show_client_options', $showClientOptions); |
258 | 264 |
|
259 | 265 | $listing_tpl = 'bbb/listing.tpl'; |
260 | 266 | $content = $tpl->fetch($listing_tpl); |
|
0 commit comments