static function edit($option, $pkg, $ids, $formid, $parent)
 {
     $database = JFactory::getDBO();
     JArrayHelper::toInteger($ids);
     $row = new facileFormsMenus($database);
     if ($formid == '') {
         $row->load($ids[0]);
     } else {
         if ($formid > 0) {
             $form = new facileFormsForms($database);
             $form->load($formid);
             $row->title = $form->title;
             $row->name = $form->name;
         }
         // if
         $row->parent = $parent;
         $database->setQuery("select max(ordering)+1 " . "from #__facileforms_compmenus " . "where parent={$parent}");
         $row->ordering = $database->loadResult();
     }
     // if
     $lists = array();
     $parents = array();
     $parents[] = JHTML::_('select.option', 0, BFText::_('COM_BREEZINGFORMS_MENUS_TOP'));
     $database->setQuery("select id as value, title as text " . "from #__facileforms_compmenus " . "where parent=0 " . "order by title, id");
     $plist = $database->loadObjectList();
     if (count($plist)) {
         foreach ($plist as $obj) {
             $parents[] = $obj;
         }
     }
     $lists['parents'] = JHTML::_('select.genericlist', $parents, 'parent', 'class="inputbox" size="1"', 'value', 'text', intval($row->parent));
     $order = JHTML::_('list.genericordering', "select ordering as value, title as text " . "from #__facileforms_compmenus " . "where parent=" . $row->parent . " and package= " . $database->Quote($pkg) . " " . "order by ordering");
     $lists['ordering'] = JHTML::_('select.genericlist', $order, 'ordering', 'class="inputbox" size="1"', 'value', 'text', intval($row->ordering));
     $lists['imgs'] = array('js/ThemeOffice/add_section.png', 'js/ThemeOffice/backup.png', 'js/ThemeOffice/categories.png', 'js/ThemeOffice/checkin.png', 'js/ThemeOffice/component.png', 'js/ThemeOffice/config.png', 'js/ThemeOffice/content.png', 'js/ThemeOffice/controlpanel.png', 'js/ThemeOffice/credits.png', 'js/ThemeOffice/db.png', 'js/ThemeOffice/document.png', 'js/ThemeOffice/edit.png', 'js/ThemeOffice/globe1.png', 'js/ThemeOffice/globe2.png', 'js/ThemeOffice/globe3.png', 'js/ThemeOffice/globe4.png', 'js/ThemeOffice/help.png', 'js/ThemeOffice/home.png', 'js/ThemeOffice/install.png', 'js/ThemeOffice/language.png', 'js/ThemeOffice/license.png', 'js/ThemeOffice/mail.png', 'js/ThemeOffice/mainmenu.png', 'js/ThemeOffice/mass_email.png', 'js/ThemeOffice/media.png', 'js/ThemeOffice/menus.png', 'js/ThemeOffice/messaging.png', 'js/ThemeOffice/messaging_config.png', 'js/ThemeOffice/messaging_inbox.png', 'js/ThemeOffice/module.png', 'js/ThemeOffice/preview.png', 'js/ThemeOffice/query.png', 'js/ThemeOffice/restore.png', 'js/ThemeOffice/search_text.png', 'js/ThemeOffice/sections.png', 'js/ThemeOffice/statistics.png', 'js/ThemeOffice/sysinfo.png', 'js/ThemeOffice/template.png', 'js/ThemeOffice/tooltip.png', 'js/ThemeOffice/trash.png', 'js/ThemeOffice/tux.png', 'js/ThemeOffice/user.png', 'js/ThemeOffice/users.png', 'js/ThemeOffice/users_add.png', 'js/ThemeOffice/warning.png');
     HTML_facileFormsMenu::edit($option, $pkg, $row, $lists);
 }
Example #2
0
	function getPageDestination($option, $pkg, $form, $page)
	{
		global $database;
		$database = JFactory::getDBO();
		$row = new facileFormsForms($database);
		$row->load($form);
		$lst = array();
		for($p = 1; $p <= $row->pages; $p++)
			$lst[] = JHTML::_('select.option', $p, BFText::_('COM_BREEZINGFORMS_ELEMENTS_PAGE').' '.$p);
		$sellist =
			JHTML::_('select.genericlist',
				$lst, 'destination', 'class="inputbox" size="15"',
				'value', 'text', $page
			);
		HTML_facileFormsElement::getPagedest($option, $pkg, $form, $page, $sellist);
	} // getPageDestination
Example #3
0
	function order($option, $pkg, $ids, $inc)
	{
		global $database;
		$database = JFactory::getDBO();
		$row = new facileFormsForms($database);
		$row->load($ids[0]);
		$row->move($inc, "package=".$database->Quote($pkg)."" );
		JFactory::getApplication()->redirect("index.php?option=$option&act=manageforms&pkg=$pkg");
	} // order
Example #4
0
 static function order($option, $pkg, $ids, $inc)
 {
     global $database;
     JArrayHelper::toInteger($ids);
     $database = JFactory::getDBO();
     $row = new facileFormsForms($database);
     $row->load($ids[0]);
     $row->move($inc, "package=" . $database->Quote($pkg) . "");
     JFactory::getApplication()->redirect("index.php?option={$option}&act=manageforms&pkg={$pkg}");
 }