Пример #1
0
 /**
  * Gets the backend print window (sem_f038)
  *
  * @param   int  $art  - The art
  * @param   int  $cid  - The cid
  * @param   int  $uid  - The uid
  *
  * @todo    fix and update
  * @return  string
  */
 public static function getBackendPrintWindow($art, $cid, $uid = 0)
 {
     $search = trim(strtolower(JFactory::getApplication()->input->get('search', '', 'string')));
     $limit = trim(JFactory::getApplication()->input->getInt('limit', 5));
     $limitstart = trim(JFactory::getApplication()->input->getInt('limitstart', 0));
     if (empty($uid)) {
         $uid = trim(JFactory::getApplication()->input->get('uid', 0));
     }
     $href = JURI::ROOT() . "index.php?tmpl=component&s=" . 0 . "&option=" . JFactory::getApplication()->input->get('option') . "&view=printeventlist&search=" . $search . "&limit=" . $limit . "&limitstart=" . $limitstart . "&cid=" . $cid . "&uid=" . $uid . "&todo=";
     $x = 550;
     $y = 300;
     $image = "1932";
     $title = JTEXT::_('COM_MATUKIO_PRINT');
     switch ($art) {
         case 1:
             // Art 36
             $href .= "print_eventlist";
             break;
         case 2:
             // Teilnehmerliste - 34
             $href .= "print_teilnehmerliste&art=1&cid=" . $cid;
             $image = "1932";
             $title = JTEXT::_('COM_MATUKIO_PRINT_SIGNATURE_LIST');
             break;
         case 3:
             $href .= "certificate&cid=" . $cid;
             $image = "2900";
             $title = JTEXT::_('COM_MATUKIO_PRINT_CERTIFICATE');
             break;
         case 4:
             // Unterschriftliste
             $href .= "print_teilnehmerliste&cid=" . $cid;
             $image = "2032";
             $title = JTEXT::_('COM_MATUKIO_PRINT_PARTICIPANTS_LIST');
             break;
         case 5:
             $href = JURI::ROOT() . "index.php?option=com_matukio&view=printeventlist&format=raw&todo=csvlist&cid=" . $cid;
             $image = "1632";
             $title = JTEXT::_('COM_MATUKIO_DOWNLOAD_CSV_FILE');
             break;
         case 6:
             // Invoice
             $href = JURI::ROOT() . "index.php?option=com_matukio&view=printeventlist&format=raw&todo=invoice&cid=" . $cid . "&uid=" . $uid;
             $image = "invoice";
             $title = JTEXT::_('COM_MATUKIO_PRINT_INVOICE');
             break;
     }
     if ($art != 5 && $art != 6) {
         $html = "<a title=\"" . $title . "\" class=\"modal cjmodal\" href=\"" . $href . "\" rel=\"{handler: 'iframe', size: {x: " . $x . ", y: " . $y . "}}\">";
     } else {
         $html = "<a title=\"" . $title . "\" href=\"" . $href . "\">";
     }
     $html .= "<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . $image . ".png\" border=\"0\" valign=\"absmiddle\" alt=\"" . $title . "\" /></a>";
     return $html;
 }
Пример #2
0
 /**
  * Returns an barchart
  *
  * @param   int  $done  - Is the loading done
  *
  * @return  string
  */
 public static function getProcentBarchart($done)
 {
     $max = 100;
     if ($done < 0) {
         $done = 0;
     }
     if ($done > $max) {
         $done = $max;
     }
     $displayValue = $done / $max * 100;
     $displayValue = number_format($displayValue, 0, '.', '');
     return "<span style=\"white-space: nowrap;\">\n\t\t<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "3000.png\" width=\"" . $displayValue . "\" style=\"height: 10px\" />\n\t\t<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "3001.png\" width=\"" . (100 - $displayValue) . "\" style=\"height: 10px\" /></span>";
 }
Пример #3
0
?>
"/>

			<?php 
echo JHTML::_('form.token');
?>
		</table>
	</form>
</div>
<div class="clear"></div>

	<div class="clear"></div>

<?php 
// Description of the icons
$imgpath = MatukioHelperUtilsBasic::getComponentImagePath();
?>
	<table class="admintable table" style="width: 100%; margin-bottom: 20px; text-align: left;">
		<!-- Status -->
		<thead>
		<tr>
			<th width="33%">
				<?php 
echo JTEXT::_('COM_MATUKIO_STATUS');
?>
			</th>
			<th width="33%">
				<?php 
echo JTEXT::_('COM_MATUKIO_AVAILABILITY');
?>
			</th>
Пример #4
0
    echo " <a title=\"" . JTEXT::_('COM_MATUKIO_BOOK') . "\" href=\"" . $bookinglink . "\"><span class=\"mat_book\" type=\"button\"><img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1116.png\" border=\"0\" align=\"absmiddle\">&nbsp;" . JTEXT::_('COM_MATUKIO_BOOK') . "</span></a>";
}
// Aenderungen speichern Veranstalter  , not really implemented here
if ($this->art == 3 and $usrid != 0 and ($this->event->nrbooked > 1 or $zfleer == 0)) {
    echo ' <input type="submit" class="button" value="' . JTEXT::_('COM_MATUKIO_SAVE_CHANGES') . '">';
}
// Aenderungen speichern Benutzer falls noch nicht gezahlt
if ($this->art == 1 and strtotime($this->event->booked) - time() >= MatukioHelperSettings::getSettings('booking_stornotage', 1) * 24 * 60 * 60 and $bezahlt == 0) {
    if ($this->user->id > 0) {
        $unbookinglink = JRoute::_("index.php?option=com_matukio&view=bookevent&task=cancelBooking&cid=" . $this->event->id);
        if (MatukioHelperSettings::getSettings('booking_stornotage', 1) > -1) {
            echo " <a border=\"0\" href=\"" . $unbookinglink . "\" ><span class=\"mat_book\" type=\"button\"><img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1532.png\" border=\"0\" align=\"absmiddle\" style=\"width: 16px; height: 16px;\">&nbsp;" . JTEXT::_('COM_MATUKIO_BOOKING_CANCELLED') . "</span></a>";
        }
    }
}
// Booking details to first booking
if (count($buchopt[2]) > 0) {
    $blink = JRoute::_("index.php?option=com_matukio&view=booking&uuid=" . $buchopt[2][0]->uuid);
    echo " <a href=\"" . $blink . "\"><span class=\"mat_button\" style=\"cursor:pointer;\"\n                                        title=\"" . JTEXT::_('COM_MATUKIO_BOOKING_DETAILS') . "\">" . "<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "0004.png\" border=\"0\" align=\"absmiddle\">&nbsp;" . JTEXT::_('COM_MATUKIO_BOOKING_DETAILS') . "</span></a>";
}
?>
	</div>
	</div>
	<?php 
echo $this->jevent->afterDisplayContent;
?>
	<?php 
echo MatukioHelperUtilsBasic::getCopyright();
?>
</div>
Пример #5
0
                } elseif ($this->art == 2) {
                    $htxt = "<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "240" . $row->grade . ".png\" alt=\"" . JTEXT::_('COM_MATUKIO_RATING') . "\">";
                }
                $htbr = 30;
            } else {
                $htxt = "&nbsp;";
                $htbr = "";
            }
            $html .= MatukioHelperUtilsEvents::getTableCell($htxt, 'h', '', $htbr, "sem_row");
        }
        // Ausgabe der Statusgrafik
        if (MatukioHelperSettings::getSettings('event_statusgraphic', 2) > 0) {
            $htxt = "&nbsp;";
            // Ampel
            if (MatukioHelperSettings::getSettings('event_statusgraphic', 2) == 1 and $row->nrbooked > 0) {
                $htxt = "<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "230" . $buchopt[3] . ".png\" alt=\"" . $buchopt[1] . "\">";
            } elseif (MatukioHelperSettings::getSettings('event_statusgraphic', 2) == 2 and $row->nrbooked > 0) {
                // Säule
                if (MatukioHelperSettings::getSettings('frontend_userviewteilnehmer', 0) == 2 and JFactory::getUser()->id and $this->art == 0 or MatukioHelperSettings::getSettings('frontend_userviewteilnehmer', 0) == 1 and $this->art == 0 or MatukioHelperSettings::getSettings('frontend_teilnehmerviewteilnehmer', 0) > 0 and JFactory::getUser()->id and $this->art == 1 or MatukioHelperSettings::getSettings('frontend_ownereditevent', 1) > 0 and $this->art == 2) {
                    $htxt = MatukioHelperUtilsEvents::getProcentBar($row->maxpupil, $buchopt[4], $buchopt[3]);
                }
            }
            $html .= MatukioHelperUtilsEvents::getTableCell($htxt, 'd', 'c', '24', "sem_row");
        }
        $html .= "</tr>";
    }
} else {
    $html .= "<tr>";
    $html .= MatukioHelperUtilsEvents::getTableCell(JTEXT::_('COM_MATUKIO_NO_EVENT_FOUND'), 'h', '', '100%', 'sem_row');
    $html .= "</tr>";
}
Пример #6
0
                    // Certificate USER LInk     javascript:semauf(13,'" . $row->sid . "','');
                    $certlink = JRoute::_("index.php?option=com_matukio&view=participants&task=certificateUser&uid=" . $row->sid . "&cid=" . $this->kurs->id);
                    $htxt = "<a title=\"" . $certtitel . "\" href=\"" . $certlink . "\"><img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "220" . $row->certificated . ".png\" border=\"0\" align=\"absmiddle\"></a>";
                    if ($row->certificated == 1) {
                        $htxt .= " " . MatukioHelperUtilsEvents::getPrintWindow(1, $row->sid, $row->id, '');
                    }
                }
                $html .= MatukioHelperUtilsEvents::getTableCell($htxt, 'd', 'c', '', "sem_row");
            }
            if (MatukioHelperSettings::getSettings('frontend_ratingsystem', 0) > 0) {
                $hinttext = JTEXT::_('COM_MATUKIO_RATING') . "::" . htmlspecialchars($row->comment);
                $htxt = "<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "240" . $row->grade . ".png\" class=\"editlinktip hasTip\" title=\"" . $hinttext . "\">";
                $html .= MatukioHelperUtilsEvents::getTableCell($htxt, 'd', 'c', '', "sem_row");
            }
        }
        $html .= MatukioHelperUtilsEvents::getTableCell("<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . $bild . "\" border=\"0\" alt=\"" . $altbild . "\">", 'd', 'c', '', "sem_row");
        $html .= "\n</tr>";
    }
} else {
    $spalten = 3;
    if ($this->art == 2) {
        $spalten = 9;
    }
    $html .= "\n<tr>" . MatukioHelperUtilsEvents::getTableCell(JTEXT::_('COM_MATUKIO_NO_BOOKING_FOUND'), 'd', 'l', '', 'sem_row', $spalten) . "</tr>";
}
$html .= MatukioHelperUtilsEvents::getTableHeader('e');
// Hidden fields
if ($this->kurs->nrbooked <= 1 || MatukioHelperSettings::getSettings('frontend_usermehrereplaetze', 1) < 1) {
    $html .= "<input type=\"hidden\" name=\"nrbooked\" value=\"1\" />";
}
$html .= MatukioHelperUtilsEvents::getHiddenFormElements($zurueck[$this->art], $this->catid, $this->search, $this->limit, $this->limitstart, $this->kurs->id, $this->dateid, -1);
Пример #7
0
 *
 * @copyright  Copyright (C) 2008 - 2014 Yves Hoppe - compojoom.com . All rights reserved.
 * @license    GNU General Public License version 2 or later; see LICENSE
 */
defined('_JEXEC') or die('Restricted access');
JHTML::_('stylesheet', 'media/com_matukio/css/matukio.css');
$htxt = str_replace("SEM_TITLE", $this->event->title, JTEXT::_('COM_MATUKIO_PLEASE_RATE_THIS_EVENT'));
$html = "\n<body onload=\"parent.sbox-window.focus();\">";
$html .= "<form action=\"index.php\" method=\"post\" name=\"FrontForm\">\n";
$html .= "<div class=\"sem_cat_title\">" . JTEXT::_('COM_MATUKIO_YOUR_RATING') . "</div><br />";
$html .= "<div class=\"sem_shortdesc\">" . $htxt . "</div>";
$html .= "<br /><center><table cellpadding=\"2\" cellspacing=\"0\" border=\"0\">";
$tempa = "";
$tempb = "";
for ($i = 6; $i > 0; $i = $i - 1) {
    $tempa .= "<th><img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "240" . $i . ".png\"></th><td width=\"10px\">&nbsp;</td>";
    $tempb .= "<th><input type=\"radio\" name=\"grade\" value=\"" . $i . "\"";
    if ($i == $this->booking->grade) {
        $tempb .= " checked";
    }
    $tempb .= "></th><td width=\"10px\">&nbsp;</td>";
}
$html .= "<tr>" . $tempa . "</tr>";
$html .= "<tr>" . $tempb . "</tr>";
$html .= "</table></center>";
$html .= "<br /><div class=\"sem_shortdesc\">" . JTEXT::_('COM_MATUKIO_COMMENT') . ":</div>";
$html .= "<br /><center><input type=\"text\" name=\"text\" size=\"70\" maxlength=\"200\" value=\"" . $this->booking->comment . "\"></center><br />";
$html .= "<input type=\"hidden\" name=\"option\" value=\"com_matukio\">\r\n        <input type=\"hidden\" name=\"view\" value=\"rateevent\" />\r\n        <input type=\"hidden\" name=\"controller\" value=\"rateevent\" />\r\n        <input type=\"hidden\" name=\"cid\" value=\"" . $this->event->id . "\">\r\n        <input type=\"hidden\" name=\"task\" value=\"rate\">";
$html .= "<center><button class=\"button\" style=\"cursor:pointer;\" type=\"button\" onclick=\"this.disabled=true;document.FrontForm.submit();\">" . JTEXT::_('COM_MATUKIO_SEND') . "</button></center>";
$html .= "</form>";
$html .= "</body></html>";
Пример #8
0
					<?php 
    if ($confusers->get('allowUserRegistration', 0) > 0) {
        ?>
						<button class="mat_button btn" type="button"
						        style="cursor:pointer;vertical-align:middle;padding:3px 5px;"
						        title="<?php 
        echo JTEXT::_('COM_MATUKIO_REGISTER');
        ?>
"
						        onClick="location.href='<?php 
        echo MatukioHelperUtilsBasic::getSitePath() . $baseuserurl . $registrationurl;
        ?>
'">
							<img src="<?php 
        echo MatukioHelperUtilsBasic::getComponentImagePath();
        ?>
0006.png"
							     style="vertical-align:middle; margin-top: 0px;">
						</button>
					<?php 
    }
    ?>
				</div>
			</div>
		<?php 
}
?>

		<?php 
// Navigation (Categories, search, reset, limitbox etc.
<?php 
// Buttons
?>
<div class="mat_buttons">
	<div class="mat_buttons_inner">
		<?php 
// Print Button
echo MatukioHelperUtilsEvents::getPrintWindow(2 + 2, '', '', 'b');
?>

		<?php 
/* New event button */
if (JFactory::getUser()->authorise('core.create', 'com_matukio')) {
    ?>
			<a href="<?php 
    echo JRoute::_("index.php?option=com_matukio&view=createevent");
    ?>
"><span class="mat_button"
			                                                                                          style="cursor:pointer;"><?php 
    echo JHTML::_('image', MatukioHelperUtilsBasic::getComponentImagePath() . '1816.png', null, array('border' => '0', 'align' => 'absmiddle'));
    ?>
					<?php 
    echo JTEXT::_('COM_MATUKIO_NEW_EVENT');
    ?>
</span></a>
		<?php 
}
?>
	</div>
</div>
Пример #10
0
 /**
  * Gets the upcoming events
  *
  * @param   object  $events  - The events
  * @param   object  $user    - The user
  *
  * @return  string - The html code
  */
 public static function getUpcomingEventsHTML($events, $user)
 {
     JHTML::_('stylesheet', 'media/com_matukio/css/upcoming.css');
     $html = "";
     if (count($events)) {
         $dispatcher = JDispatcher::getInstance();
         JPluginHelper::importPlugin('content');
         $params = JComponentHelper::getParams('com_matukio');
         foreach ($events as $event) {
             $buchopt = MatukioHelperUtilsEvents::getEventBookableArray(0, $event, $user->id);
             // Link
             $eventid_l = $event->id . ':' . JFilterOutput::stringURLSafe($event->title);
             $catid_l = $event->catid . ':' . JFilterOutput::stringURLSafe(MatukioHelperCategories::getCategoryAlias($event->catid));
             $link = JRoute::_(MatukioHelperRoute::getEventRoute($eventid_l, $catid_l), false);
             // Event image   -- TODO Add / Check for category image
             $linksbild = MatukioHelperUtilsBasic::getComponentImagePath() . "2601.png";
             if ($event->image != "" and MatukioHelperSettings::getSettings('event_image', 1) == 1) {
                 $linksbild = MatukioHelperUtilsBasic::getEventImagePath(1) . $event->image;
             }
             $hot = $event->hot_event ? " " : "";
             $top = $event->top_event ? " mat_top_event" : "";
             // Starting Row
             $html .= '<div class="mat_single_event' . $hot . $top . '">';
             $html .= '	<div class="mat_event_header">';
             $html .= '		<div class="mat_event_header_inner">';
             $html .= '			<div class="mat_event_header_line">';
             $html .= '				<div class="mat_event_image">';
             $html .= '					<img src="' . $linksbild . '" alt="' . $event->title . '" align="absmiddle" />';
             $html .= '				</div>';
             $html .= '				<div class="mat_event_title">';
             $html .= '					<h2><a href="' . $link . '" title="' . $event->title . '">' . $event->title . '</a></h2>';
             $html .= '				</div>';
             $html .= '			</div>';
             $html .= '			<div class="mat_event_location">';
             $begin = JHTML::_('date', $event->begin, MatukioHelperSettings::getSettings('date_format', 'd-m-Y, H:i'));
             $location = $event->place;
             $locobj = null;
             if ($event->place_id > 0) {
                 $locobj = MatukioHelperUtilsEvents::getLocation($event->place_id);
                 $placelink = JRoute::_("index.php?option=com_matukio&view=location&id=" . $locobj->id . ":" . JFilterOutput::stringURLSafe($locobj->title));
                 $location = '<a href="' . $placelink . '">' . $locobj->location . '</a>';
             }
             if (MatukioHelperSettings::getSettings('show_timezone', '1')) {
                 $begin .= " (GMT " . JHTML::_('date', $event->booked, 'P') . ")";
             }
             if ($event->webinar == 1) {
                 $locimg = MatukioHelperUtilsBasic::getComponentImagePath() . "webinar.png";
                 $html .= '<h4><img src="' . $locimg . '" title="' . JText::_("COM_MATUKIO_WEBINAR") . '" style="width: 22px; vertical-align:middle" /> ' . $location . " " . JText::_("COM_MATUKIO_AT") . " " . $begin . '</h4>';
             } else {
                 // TODO add map link
                 $locimg = MatukioHelperUtilsBasic::getComponentImagePath() . "home.png";
                 $html .= '<h4><img src="' . $locimg . '" title="' . JText::_("COM_MATUKIO_FIELDS_CITY") . '" style="width: 22px; vertical-align:middle" /> ' . $location . " " . JText::_("COM_MATUKIO_AT") . " " . $begin . '</h4>';
             }
             $html .= '			</div>';
             $html .= '		</div>';
             $html .= '	</div>';
             $html .= '	<div class="mat_event_description">';
             $html .= $event->shortdesc;
             $html .= '</div>';
             $html .= '	<div class="mat_event_footer">';
             $html .= '		<div class="mat_event_footer_inner">';
             $html .= '			<div class="mat_event_infoline">';
             $catlink = JRoute::_("index.php?option=com_matukio&view=eventlist&art=0&catid=" . $event->catid . ":" . JFilterOutput::stringURLSafe($event->category));
             $html .= '<a href="' . $catlink . '">' . JTEXT::_($event->category) . '</a>';
             // Infoline
             $gebucht = MatukioHelperUtilsEvents::calculateBookedPlaces($event);
             if (MatukioHelperSettings::getSettings('event_showinfoline', 1) == 1) {
                 $html .= " | ";
                 // Veranstaltungsnummer anzeigen
                 if ($event->semnum != "") {
                     $html .= JTEXT::_('COM_MATUKIO_NUMBER') . ": " . $event->semnum . " | ";
                 }
                 $html .= JTEXT::_('COM_MATUKIO_BOOKABLE') . ": " . $buchopt[4];
             }
             // Seminarleiter anzeigen
             if ($event->teacher != "") {
                 $html .= " | " . $event->teacher;
             }
             // Fees
             if ($event->fees > 0) {
                 $html .= " | ";
                 $gebuehr = MatukioHelperUtilsEvents::getFormatedCurrency($event->fees);
                 $currency = MatukioHelperSettings::getSettings('currency_symbol', '$');
                 if ($currency == '€') {
                     $html .= JTEXT::_('COM_MATUKIO_FEES') . ': ' . $gebuehr . " " . $currency;
                 } else {
                     $html .= JTEXT::_('COM_MATUKIO_FEES') . ': ' . $currency . " " . $gebuehr;
                 }
             }
             $html .= '</div>';
             $html .= '			<div class="mat_event_footer_buttons" align="right">';
             // Detail Link
             $html .= " <a title=\"" . $event->title . "\" href=\"" . $link . "\">" . "<span class=\"mat_button\"><img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "0012.png\" border=\"0\" align=\"absmiddle\">&nbsp;" . JTEXT::_('COM_MATUKIO_EVENT_DETAILS') . "</span></a> ";
             // Booking Link
             if (($user->id != 0 || MatukioHelperSettings::getSettings('booking_unregistered', 1) == 1) && MatukioHelperSettings::getSettings('oldbookingform', 0) != 1) {
                 if ($event->nrbooked > 0) {
                     $bookinglink = JRoute::_("index.php?option=com_matukio&view=bookevent&cid=" . $event->id . ":" . JFilterOutput::stringURLSafe($event->title));
                     $html .= " <a title=\"" . JTEXT::_('COM_MATUKIO_BOOK') . "\" href=\"" . $bookinglink . "\"><span class=\"mat_button mat_book\" type=\"button\"><img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1116.png\" border=\"0\" align=\"absmiddle\">&nbsp;" . JTEXT::_('COM_MATUKIO_BOOK') . "</span></a>";
                 }
             }
             $html .= '				<br />';
             $results = $dispatcher->trigger('onContentAfterButton', array('com_matukio.upcomingevent', &$event, &$params, 0));
             $html .= trim(implode("\n", $results));
             $html .= '			</div>';
             $html .= '		</div>';
             $html .= '	</div>';
             $html .= ' </div>';
         }
     }
     return $html;
 }
Пример #11
0
</td>
					<td><?php 
    echo $this->organizer->website;
    ?>
</td>
				</tr>
			<?php 
}
?>
			<?php 
if (MatukioHelperSettings::getSettings("sendmail_contact", 1)) {
    ?>
				<tr>
					<td colspan="2">
						<?php 
    echo MatukioHelperUtilsEvents::getEmailWindow(MatukioHelperUtilsBasic::getComponentImagePath(), $this->organizer->id, "organizer", "modern");
    // Kontaktformular
    // echo MatukioHelperUtilsEvents::getEmailWindow(MatukioHelperUtilsBasic::getComponentImagePath(), $this->event->id, 1, "modern");
    ?>
					</td>
				</tr>
			<?php 
}
?>
		</table>
	</div>
	<?php 
echo JHtml::_('content.prepare', $this->organizer->description);
// CComment and co
echo $this->jevent->afterDisplayContent;
// Since 3.1.0 - Show upcoming events with that organizer
Пример #12
0
    }
}
echo $html;
?>
</table>

<div class="buttons">
	<?php 
echo MatukioHelperUtilsEvents::getPrintWindow(2, $this->event->id, '', 'b', "bootstrap");
// Calendar
if (MatukioHelperSettings::getSettings('frontend_usericsdownload', 1) > 0) {
    echo MatukioHelperUtilsEvents::getCalendarButton($this->event, "bootstrap");
}
// Contact organizer
if (MatukioHelperSettings::getSettings("sendmail_contact", 1)) {
    echo MatukioHelperUtilsEvents::getEmailWindow(MatukioHelperUtilsBasic::getComponentImagePath(), $this->event->id, 1, "bootstrap");
}
// Invoice
if (MatukioHelperSettings::getSettings("download_invoice", 1) && ($this->booking->status == 0 || $this->booking->status == 1) && $this->event->fees > 0) {
    $href = JURI::ROOT() . "index.php?option=com_matukio&view=printeventlist&format=raw&todo=invoice&cid=" . $this->booking->semid . "&uuid=" . $this->booking->uuid;
    echo " <a border=\"0\" href=\"" . $href . "\" ><span class=\"btn\" type=\"button\">" . JTEXT::_('COM_MATUKIO_DOWNLOAD_INVOICE_BUTTON') . "</span></a>";
}
// Ticket
if (MatukioHelperSettings::getSettings("download_ticket", 1) && ($this->booking->status == 0 || $this->booking->status == 1)) {
    $href = JURI::ROOT() . "index.php?option=com_matukio&view=printeventlist&format=raw&todo=ticket&cid=" . $this->booking->semid . "&uuid=" . $this->booking->uuid;
    echo " <a border=\"0\" href=\"" . $href . "\" ><span class=\"btn\" type=\"button\">" . JTEXT::_('COM_MATUKIO_DOWNLOAD_TICKET_BUTTON') . "</span></a>";
}
// Certification
if (MatukioHelperSettings::getSettings('frontend_certificatesystem', 0) > 0) {
    if ($this->booking->certificated == 1 and $this->event->nrbooked > 0) {
        echo MatukioHelperUtilsEvents::getPrintWindow(1, $this->event->sid, $this->booking->id, 'CERT', 'btn');
Пример #13
0
$knopfoben = "<a title=\"" . JTEXT::_('COM_MATUKIO_BACK') . "\" href=\"" . $backlink . "\"><img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1032.png\" border=\"0\" align=\"absmiddle\"></a>";
$knopfunten .= "<a href=\"" . $backlink . "\"> <span class=\"btn\" style=\"cursor:pointer;\" type=\"button\">" . JTEXT::_('COM_MATUKIO_BACK') . "</span></a>";
// Submit
$knopfunten .= " <input type=\"submit\" id=\"btnSave\" class=\"btn btn-success\" style=\"cursor:pointer;\" value=\"" . JText::_("COM_MATUKIO_SAVE") . "\">";
if ($this->event->cancelled == 0) {
    $knopfunten .= " <a class=\"btn btn-danger\" href=\"index.php?option=com_matukio&view=createevent&task=cancel&cid=" . $this->event->id . "\">" . JText::_("COM_MATUKIO_CANCEL_EVENT") . "</a>";
} else {
    $knopfunten .= " <a class=\"btn btn-success\" href=\"index.php?option=com_matukio&view=createevent&task=uncancel&cid=" . $this->event->id . "\">" . JText::_("COM_MATUKIO_UNCANCEL_EVENT") . "</a>";
}
if ($this->event->id > 0) {
    // Event kopieren
    $duplicatelink = JRoute::_("index.php?option=com_matukio&view=createevent&task=duplicateEvent&cid=" . $this->event->id);
    $knopfunten .= " <a title=\"" . JTEXT::_('COM_MATUKIO_DUPLICATE') . "\" href=\"" . $duplicatelink . "\"><button class=\"btn\" style=\"cursor:pointer;\" type=\"button\">" . JTEXT::_('COM_MATUKIO_DUPLICATE') . "</button></a> ";
    // Delete (unpublish in reallity)
    $unpublishlink = JRoute::_("index.php?option=com_matukio&view=createevent&task=unpublishevent&cid=" . $this->event->id);
    $knopfoben .= "<a title=\"" . JTEXT::_('COM_MATUKIO_DELETE') . "\" href=\"" . $unpublishlink . "\">\n        <img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1532.png\" border=\"0\" align=\"absmiddle\"></a>";
    $knopfunten .= "<a href=\"" . $unpublishlink . "\"><button class=\"btn btn-danger\" style=\"cursor:pointer;\" type=\"button\">" . JTEXT::_('COM_MATUKIO_DELETE') . "</button></a>";
}
if (MatukioHelperSettings::getSettings('event_buttonposition', 2) == 0 or MatukioHelperSettings::getSettings('event_buttonposition', 2) == 2) {
    echo $knopfoben;
}
// MatukioHelperUtilsEvents::getEventlistHeaderEnd();
echo "<table class=\"table\" width=\"100%\" cellspacing=\"0\" cellpadding=\"4\" border=\"0\" style=\"border-top: 1px solid #ccc\">" . "<tr><td class=\"sem_anzeige\">";
// Anzeige Bereichsueberschrift
if ($this->event->id == "") {
    $temp1 = JTEXT::_('COM_MATUKIO_NEW_EVENT');
    $temp2 = JTEXT::_('COM_MATUKIO_SUBMIT_NEW_EVENT');
} else {
    $temp1 = JTEXT::_('COM_MATUKIO_EDIT_EVENT');
    $temp2 = JTEXT::_('COM_MATUKIO_CHANGE_INFORMATION');
}
Пример #14
0
    /**
     * Returns the fees html code
     *
     * @param   string  $different_fees  - The json encoded string
     * @param   object  $event           - The event
     * @param   array   $buchopt         - Array of booking informations
     *
     * @return string
     */
    public static function getEditBookingFeesList($different_fees, $event, $buchopt)
    {
        $json = json_decode($different_fees, true);
        $places = $json["places"];
        $types = $json["types"];
        $html = '<div id="fees_table">';
        $html .= '<table class="table">';
        // Fix for empty places / types - we need at least one
        if (empty($places)) {
            $places = array(1);
            $types = array(0);
        }
        // We also have to look for unpublished / ended fees..
        if (empty($event->different_fees_override)) {
            $fees_list = self::getFees("all", 0);
        } else {
            $html .= "<tr><td colspan=\"3\">" . JText::_("COM_MATUKIO_OVERRIDEN_CUSTOM_EVENT_FEES") . "</td></tr>";
            $fees_list = self::getOverrideFees($event->different_fees_override);
        }
        $html .= '<tr><td colspan="3">';
        // Add additional tickets in another category!
        $html .= "<div align=\"right\"><a id=\"addticket\" class=\"mat_addticket\" border=\"0\" href=\"#\">\n\t\t<span class=\"mat_add btn btn-success\" type=\"button\">\n\t\t\t\t\t<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1832.png\" border=\"0\" align=\"absmiddle\" style=\"width: 16px; height: 16px;\">&nbsp;" . JTEXT::_('COM_MATUKIO_ADD') . "</span></a></div>";
        $html .= '</td></tr>';
        $cnt = 0;
        for ($i = 0; $i < count($places); $i++) {
            $p = $places[$i];
            $t = $types[$i];
            $html .= '<tr id="tickets_' . $i . '">';
            $html .= '<td class="key" width="150px">';
            $html .= JText::_("COM_MATUKIO_PLACES") . ": ";
            $html .= MatukioHelperUtilsEvents::getPlaceSelect($buchopt, $event, $i, $p);
            $html .= '</td>';
            $html .= '<td>';
            $html .= JText::_("COM_MATUKIO_TICKET_TYPE_SHORT") . ": ";
            $html .= '<select id="ticket_fees' . $i . '" name="ticket_fees[' . $i . ']" class="sem_inputbox input-medium chzn-single ticket_fees" size="1">';
            if ($t != 0) {
                $html .= '<option value="0">- ' . JText::_("COM_MATUKIO_NORMAL") . ' -</option>';
            } else {
                $html .= '<option value="0" selected="selected">- ' . JText::_("COM_MATUKIO_NORMAL") . ' -</option>';
            }
            foreach ($fees_list as $f) {
                $disc_text = $f->discount ? '-' : '+';
                if (!$f->percent) {
                    $fval = MatukioHelperUtilsEvents::getFormatedCurrency($f->value, MatukioHelperSettings::getSettings('currency_symbol', '$'));
                } else {
                    $fval = $f->value . " %";
                }
                $selected = "";
                if ($f->id == $t) {
                    $selected = ' selected="selected"';
                }
                $html .= '<option value="' . $f->id . '"' . $selected . '>' . JText::_($f->title) . ' (' . $disc_text . $fval . ")" . '</option>';
            }
            $html .= '</select>';
            if ($buchopt[4] <= 0) {
                $html .= " * " . JText::_("COM_MATUKIO_BOOKING_ON_WAITLIST");
            }
            $html .= '<td style="text-align: right;">';
            // Delete ticket button
            $html .= " <a id=\"delticket" . $i . "\" border=\"0\" id=\"" . $i . "\"><span class=\"mat_remove btn btn-danger\" type=\"button\">" . "<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1532.png\" border=\"0\" align=\"absmiddle\" style=\"width: 16px; height: 16px;\">" . JTEXT::_('COM_MATUKIO_REMOVE_SMALL') . "</span></a>";
            $html .= '</td>';
            $html .= '</tr>';
            $html .= '<script type="text/javascript">';
            $html .= 'jQuery( document ).ready(function( $ ) {
				$("#delticket' . $i . '").click(function(){
					$("#tickets_' . $i . '").remove();
				});
			});';
            $html .= '</script>';
            $cnt++;
        }
        echo '<input type="hidden" name="numfees" id="numfees" value="' . $cnt . '" />';
        $html .= '</table>';
        $html .= '</div>';
        // Add the necessary js
        $doc = JFactory::getDocument();
        $doc->addScriptDeclaration('
			jQuery( document ).ready(function( $ ) {
				$("#addticket").click(function(){
					var numfees = $("#numfees").val();

					$.get( "' . JUri::root() . 'index.php?option=com_matukio&format=raw&view=requests&task=getnewfeerow&backend=1&event_id=' . $event->id . '",
					{ num: numfees } )
					.done(function( data ) {
						$("#fees_table").append( data );
						$("input .btn").button();

						numfees++;
						$("#numfees").val(numfees);
					});

					return false;
				});
			});
		');
        return $html;
    }
Пример #15
0
    } else {
        //proibida a inscricao em eventos simultaneos
        $erro = 4;
    }
} else {
    if (MatukioHelperSettings::getSettings('oldbookingform', 0) == 1) {
        if ($this->event->fees > 0) {
            $knopfunten .= " <input type=\"submit\" style=\"cursor:pointer;\" class=\"booking_button mat_button\" value=\"" . JTEXT::_('COM_MATUKIO_BOOK_PAID') . "\">";
        } else {
            $knopfunten .= " <input type=\"submit\" style=\"cursor:pointer;\" class=\"booking_button mat_button\" value=\"" . JTEXT::_('COM_MATUKIO_BOOK') . "\">";
        }
    } else {
        if ($this->event->catid == $idcatInscricao) {
            $bookinglink = JRoute::_("index.php?option=com_matukio&view=bookevent&cid=" . $this->event->id . ":" . JFilterOutput::stringURLSafe($this->event->title));
            $knopfoben .= "<a title=\"" . JTEXT::_('COM_MATUKIO_BOOK') . "\" href=\"" . $bookinglink . "\"><img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1132.png\" border=\"0\" align=\"absmiddle\"></a>";
            $knopfunten .= " <a title=\"" . JTEXT::_('COM_MATUKIO_BOOK') . "\" href=\"" . $bookinglink . "\"><span class=\"mat_button\" style=\"cursor:pointer;\"><img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1116.png\" border=\"0\" align=\"absmiddle\">&nbsp;" . JTEXT::_('COM_MATUKIO_BOOK') . "</span></a>";
        } else {
            //primeiramente deve haver alguma inscricao
            $erro = 5;
        }
    }
}
switch ($erro) {
    case 1:
        echo "<script type='text/javascript'>";
        echo "alert('Seu pacote de inscricao nao permite inscrições em Mini-Cursos!');";
        echo "</script>";
        break;
    case 2:
        echo "<script type='text/javascript'>";
        echo "alert('Seu pacote de inscricao nao permite inscrições em Palestras!');";
Пример #16
0
 /**
  * Gets the calendar button
  *
  * @param   object  $event     - THe event
  * @param   string  $template  - The template
  *
  * @return  string
  */
 public static function getCalendarButton($event, $template = "modern")
 {
     $config = JFactory::getConfig();
     $_suffix = $config->get('sef_suffix');
     if ($_suffix == 0) {
         // No .html suffix
         $icslink = JRoute::_("index.php?option=com_matukio&tmpl=component&view=ics&format=raw&cid=" . $event->id);
     } else {
         $icslink = JURI::ROOT() . "index.php?tmpl=component&option=com_matukio&view=ics&format=raw&cid=" . $event->id;
     }
     $btn_class = "mat_button";
     if ($template == "bootstrap") {
         $btn_class = "btn";
     }
     $img = "<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "3316.png\" border=\"0\" align=\"absmiddle\">&nbsp;";
     if ($template == "bootstrap") {
         $img = "";
     }
     return " <a title=\"" . JTEXT::_('COM_MATUKIO_DOWNLOAD_CALENDER_FILE') . "\" href=\"" . $icslink . "\" target=\"_BLANK\">" . "<span class=\"" . $btn_class . "\">" . $img . JTEXT::_('COM_MATUKIO_DOWNLOAD_CALENDER_FILE') . "</span></a> ";
 }
Пример #17
0
                if (!$f->percent) {
                    $fval = MatukioHelperUtilsEvents::getFormatedCurrency($f->value, MatukioHelperSettings::getSettings('currency_symbol', '$'));
                } else {
                    $fval = $f->value . " %";
                }
                echo '<option value="' . $f->id . '" discvalue="' . $f->value . '" percent="' . $f->percent . '" discount="' . $f->discount . '">' . JText::_($f->title) . ' (' . $disc_text . $fval . ")" . '</option>';
            }
        }
        echo '</select>';
        if ($buchopt[4] <= 0) {
            echo " *" . JText::_("COM_MATUKIO_ON_WAITLIST");
        }
        echo '</td>';
        echo '<td style="text-align: right;">';
        // Add additional tickets in another category!
        echo " <a id=\"addticket\" class=\"mat_addticket\" border=\"0\" href=\"#\"><span class=\"mat_add\" type=\"button\">\r\n\t\t\t\t\t<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1832.png\" border=\"0\" align=\"absmiddle\" style=\"width: 16px; height: 16px;\">&nbsp;" . JTEXT::_('COM_MATUKIO_ADD') . "</span></a>";
        echo '</td>';
        echo '</tr>';
        echo "</table>";
        echo "</div>";
    }
} else {
    // Just one single ticket!
    echo "<input type=\"hidden\" name=\"nrbooked\" id=\"nrbooked\" value=\"1\" />";
    // Different Fees @since 3.0.0
    if ($this->event->different_fees) {
        $fees_list = MatukioHelperFees::getFees();
        echo "<input type=\"hidden\" name=\"places[0]\" id=\"places0\" value=\"1\" class=\"ticket_places\" />";
        if (!empty($this->event->different_fees_override)) {
            // We have an override for this event
            $fees_list = MatukioHelperFees::getOverrideFees($this->event->different_fees_override);
Пример #18
0
            $disc_text = "";
            $fval = MatukioHelperUtilsEvents::getFormatedCurrency($fval, MatukioHelperSettings::getSettings('currency_symbol', '$'));
        } else {
            if (!$f->percent) {
                $fval = MatukioHelperUtilsEvents::getFormatedCurrency($f->value, MatukioHelperSettings::getSettings('currency_symbol', '$'));
            } else {
                $fval = $f->value . " %";
            }
        }
        echo '<option value="' . $f->id . '" discvalue="' . $f->value . '" percent="' . $f->percent . '" discount="' . $f->discount . '">' . JText::_($f->title) . ' (' . $disc_text . $fval . ")" . '</option>';
    }
    echo '</select>';
    echo '</td>';
    echo '<td style="text-align: right;">';
    // Add additional tickets in another category!
    echo " <a id=\"delticket" . $num . "\" border=\"0\" num=\"" . $num . "\" class=\"btn btn-danger\"><span type=\"button\">" . "<img src=\"" . MatukioHelperUtilsBasic::getComponentImagePath() . "1532.png\" border=\"0\" align=\"absmiddle\" style=\"width: 16px; height: 16px; margin-right: 8px;\" />" . JTEXT::_('COM_MATUKIO_REMOVE') . "</span></a>";
    echo '</td>';
    echo '</tr>';
    echo "</table>";
    if ($backend) {
        echo '<script type="text/javascript">';
        echo 'jQuery( document ).ready(function( $ ) {
				$("#delticket' . $num . '").click(function(){
					$("#tickets_' . $num . '").remove();
				});
			});';
        echo '</script>';
    }
} elseif ($task == 'get_total_different') {
    $total = 0.0;
    $nrbooked = $input->getInt('nrbooked', 1);
Пример #19
0
    }
    if (MatukioHelperSettings::getSettings('show_different_fees', 1) && $this->event->different_fees) {
        $htxt .= MatukioHelperFees::getFeesShow($this->event);
    }
    $html .= MatukioHelperUtilsEvents::getTableCell($htxt, 'd', 'l', '80%', 'sem_rowd') . "</tr>";
}
// Dateien herunterladen
$datfeld = MatukioHelperUtilsEvents::getEventFileArray($this->event);
$htxt = array();
for ($i = 0; $i < count($datfeld[0]); $i++) {
    if ($datfeld[0][$i] != "" and ($datfeld[2][$i] == 0 or $my->id > 0 and $datfeld[2][$i] == 1 or $buchopt[0] == 2 and $datfeld[2][$i] == 2 or $buchopt[2][0]->paid == 1 and $datfeld[2][$i] == 3)) {
        // TODO improve security.. dirks way is a joke.. security by obscurity in opensource!!1
        // index.php?s=" . MatukioHelperUtilsBasic::getRandomChar() . "&amp;option=" . JFactory::getApplication()->input->get('option') . "&amp;task=34&amp;a6d5dgdee4cu7eho8e7fc6ed4e76z="
        // . sha1(md5($datfeld[0][$i])) . $this->event->id .
        $filelink = JRoute::_("index.php?option=com_matukio&view=matukio&task=downloadfile&a6d5dgdee4cu7eho8e7fc6ed4e76z=" . sha1(md5($datfeld[0][$i])) . $this->event->id);
        $htxt[] = "<tr><td style=\"white-space:nowrap;vertical-align:top;\"><span style=\"background-image:url(" . MatukioHelperUtilsBasic::getComponentImagePath() . "0002.png);background-repeat:no-repeat;background-position:2px;padding-left:18px;vertical-align:middle;\" >\n            <a href=\"" . $filelink . "\" target=\"_blank\">" . $datfeld[0][$i] . "</a></span></td><td width=\"80%\" style=\"vertical-align:top;\">" . $datfeld[1][$i] . "</td></tr>";
    }
}
if (count($htxt) > 0) {
    $html .= "\n<tr>" . MatukioHelperUtilsEvents::getTableCell(JTEXT::_('COM_MATUKIO_FILES') . ":", 'd', 'l', '20%', 'sem_rowd');
    $htxt = MatukioHelperUtilsEvents::getTableHeader(4) . implode($htxt) . MatukioHelperUtilsEvents::getTableHeader('e');
    $html .= MatukioHelperUtilsEvents::getTableCell($htxt, 'd', 'l', '80%', 'sem_rowd') . "</tr>";
}
// Beschreibung anzeigen
if ($this->event->description != "") {
    $html .= "\n<tr>" . MatukioHelperUtilsEvents::getTableCell(MatukioHelperUtilsBasic::parseOutput(JHtml::_('content.prepare', JText::_($this->event->description)), $parse), 'd', '', '', 'sem_rowd', 2) . "</tr>";
}
if (MatukioHelperSettings::getSettings('oldbookingform', false)) {
    if ($this->event->nrbooked > 0) {
        // Name und E-Mail, falls Buchung fuer nichtregistrierte User erlaubt
        $hidden = "";