$name = $tmp[0] . ' - ' . $user->getUserid(); } else { if (isset($tmp[1]) && $tmp[1] == 'NEW') { $name = $tmp[0] . ' - ' . 'NEW'; } else { $name = $tmp[0]; } } } else { if ($tmp[0] == 'ENTITYUPDATE') { if (isset($tmp[1]) && ctype_digit((string) $tmp[1])) { $entity = new sspmod_janus_Entity($janus_config); $entity->setEid($tmp[1]); try { $entity->load(); $name = $tmp[0] . ' - ' . $entity->getEntityid(); } catch (\Exception $ex) { $name = "Entity '{$tmp['1']}' does not exist"; } } else { $name = implode('-', $tmp); } } else { $name = implode('-', $tmp); } } echo '<option value="' . htmlspecialchars($subscription) . '">' . htmlspecialchars($name) . '</option>'; } echo '</select>'; echo '<a class="janus_button" onclick="addSubscription(' . $this->data['user']->getUid() . ', $(\'select#subscriptions_select option:selected\').val());">' . $this->t('admin_add') . '</a>'; }
$user->load(); $name = $tmp[0] . ' - ' . $user->getUserid(); } else { if (isset($tmp[1]) && $tmp[1] == 'NEW') { $name = $tmp[0] . ' - ' . 'NEW'; } else { $name = $tmp[0]; } } } else { if ($tmp[0] == 'ENTITYUPDATE') { if (isset($tmp[1]) && ctype_digit((string) $tmp[1])) { $entity = new sspmod_janus_Entity($janus_config); $entity->setEid($tmp[1]); $entity->load(); $name = $tmp[0] . ' - ' . $entity->getEntityid(); } else { $name = implode('-', $tmp); } } else { $name = implode('-', $tmp); } } echo '<option value="' . $subscription . '">' . $name . '</option>'; } echo '</select>'; echo '<a class="janus_button" onclick="addSubscription(' . $this->data['user']->getUid() . ', $(\'select#subscriptions_select option:selected\').val());">' . $this->t('admin_add') . '</a>'; } echo '</div>'; } ?>