Skip to content

Commit

Permalink
fix: default use demo server to avoid confusion
Browse files Browse the repository at this point in the history
  • Loading branch information
jibon57 committed Dec 26, 2024
1 parent f1a0ec7 commit d3b7e94
Show file tree
Hide file tree
Showing 9 changed files with 324 additions and 150 deletions.
1 change: 1 addition & 0 deletions administrator/languages/en-GB/com_plugnmeet.ini
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ COM_PLUGNMEET_CONFIG_PLUGNMEET_API_KEY_LABEL = "plugNmeet API Key"
COM_PLUGNMEET_CONFIG_PLUGNMEET_SECRET_DESCRIPTION = "Enter plugNmeet Secret"
COM_PLUGNMEET_CONFIG_PLUGNMEET_SECRET_LABEL = "plugNmeet Secret"
COM_PLUGNMEET_CONFIG_PLUGNMEET_SERVER_URL_DESCRIPTION = "Enter plugNmeet Server URL"
COM_PLUGNMEET_CONFIG_PLUGNMEET_SERVER_URL_EMPTY = "You do not have configured plugNmeet Server URL. Please click 'Options' button to configure it."
COM_PLUGNMEET_CONFIG_PLUGNMEET_SERVER_URL_LABEL = "plugNmeet Server URL"
COM_PLUGNMEET_ACCESS_HEADING = "Access"
COM_PLUGNMEET_COMPONENT_DESC = "PlugNmeet web conference integration with Joomla"
Expand Down
62 changes: 30 additions & 32 deletions administrator/sql/install.mysql.utf8.sql
Original file line number Diff line number Diff line change
@@ -1,33 +1,31 @@
CREATE TABLE `#__plugnmeet_rooms` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`asset_id` int(10) unsigned NOT NULL DEFAULT 0,
`cat` int(11) NOT NULL,
`room_id` varchar(255) NOT NULL,
`room_title` varchar(255) NOT NULL,
`alias` varchar(255) NOT NULL,
`description` text DEFAULT NULL,
`moderator_pass` varchar(255) NOT NULL,
`attendee_pass` varchar(255) NOT NULL,
`welcome_message` text NOT NULL,
`max_participants` int(10) NOT NULL,
`room_metadata` text NOT NULL,
`design_customisation` text NOT NULL,
`params` text DEFAULT NULL,
`state` int(1) DEFAULT 1,
`created_by` int(10) NOT NULL,
`created` datetime NOT NULL DEFAULT current_timestamp(),
`modified_by` int(10) DEFAULT NULL,
`modified` datetime DEFAULT NULL ON UPDATE current_timestamp(),
`checked_out` int(11) unsigned DEFAULT NULL,
`checked_out_time` datetime DEFAULT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `room_id` (`room_id`),
KEY `state` (`state`),
KEY `created_by` (`created_by`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
CREATE TABLE `#__plugnmeet_rooms`
(
`id` int(11) NOT NULL AUTO_INCREMENT,
`asset_id` int(10) unsigned NOT NULL DEFAULT 0,
`cat` int(11) NOT NULL,
`room_id` varchar(255) NOT NULL,
`room_title` varchar(255) NOT NULL,
`alias` varchar(255) NOT NULL,
`description` text DEFAULT NULL,
`moderator_pass` varchar(255) NOT NULL,
`attendee_pass` varchar(255) NOT NULL,
`welcome_message` text NOT NULL,
`max_participants` int(10) NOT NULL,
`room_metadata` text NOT NULL,
`design_customisation` text NOT NULL,
`params` text DEFAULT NULL,
`state` int(1) DEFAULT 1,
`created_by` int(10) NOT NULL,
`created` datetime NOT NULL DEFAULT current_timestamp(),
`modified_by` int(10) DEFAULT NULL,
`modified` datetime DEFAULT NULL ON UPDATE current_timestamp(),
`checked_out` int(11) unsigned DEFAULT NULL,
`checked_out_time` datetime DEFAULT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `room_id` (`room_id`),
KEY `state` (`state`),
KEY `created_by` (`created_by`)
) ENGINE = InnoDB
DEFAULT CHARSET = utf8mb4
COLLATE = utf8mb4_unicode_ci;


INSERT INTO `#__content_types` (`type_title`, `type_alias`, `table`, `rules`, `field_mappings`, `router`, `content_history_options`)
SELECT * FROM ( SELECT 'Room Category','com_plugnmeet.rooms.category','{"special":{"dbtable":"#__categories","key":"id","type":"Category","prefix":"JTable","config":"array()"},"common": {"dbtable":"#__ucm_content","key":"ucm_id","type":"Corecontent","prefix":"JTable","config":"array()"}}', '','{"common":{"core_content_item_id":"id","core_title":"title","core_state":"published","core_alias":"alias","core_created_time":"created_time","core_modified_time":"modified_time","core_body":"description", "core_hits":"hits","core_publish_up":"null","core_publish_down":"null","core_access":"access", "core_params":"params", "core_featured":"null", "core_metadata":"metadata", "core_language":"language", "core_images":"null", "core_urls":"null", "core_version":"version", "core_ordering":"null", "core_metakey":"metakey", "core_metadesc":"metadesc", "core_catid":"parent_id", "core_xreference":"null", "asset_id":"asset_id"}, "special":{"parent_id":"parent_id","lft":"lft","rgt":"rgt","level":"level","path":"path","extension":"extension","note":"note"}}', 'PlugnmeetRouter::getCategoryRoute', '{"formFile":"administrator\/components\/com_categories\/models\/forms\/category.xml", "hideFields":["asset_id","checked_out","checked_out_time","version","lft","rgt","level","path","extension"], "ignoreChanges":["modified_user_id", "modified_time", "checked_out", "checked_out_time", "version", "hits", "path"],"convertToInt":["publish_up", "publish_down"], "displayLookup":[{"sourceColumn":"created_user_id","targetTable":"#__users","targetColumn":"id","displayColumn":"name"},{"sourceColumn":"access","targetTable":"#__viewlevels","targetColumn":"id","displayColumn":"title"},{"sourceColumn":"modified_user_id","targetTable":"#__users","targetColumn":"id","displayColumn":"name"},{"sourceColumn":"parent_id","targetTable":"#__categories","targetColumn":"id","displayColumn":"title"}]}') AS tmp WHERE NOT EXISTS (
SELECT type_alias FROM `#__content_types` WHERE (`type_alias` = 'com_plugnmeet.category')
) LIMIT 1;
8 changes: 8 additions & 0 deletions administrator/src/Controller/DisplayController.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@

\defined('_JEXEC') or die;

use Joomla\CMS\Component\ComponentHelper;
use Joomla\CMS\Language\Text;
use Joomla\CMS\MVC\Controller\BaseController;

/**
Expand Down Expand Up @@ -41,6 +43,12 @@ class DisplayController extends BaseController
*/
public function display($cachable = false, $urlparams = array())
{
$params = ComponentHelper::getParams("com_plugnmeet");
if (empty($params->get("plugnmeet_server_url")))
{
$this->app->enqueueMessage(Text::_("COM_PLUGNMEET_CONFIG_PLUGNMEET_SERVER_URL_EMPTY"), "error");
}

return parent::display();
}
}
Loading

0 comments on commit d3b7e94

Please sign in to comment.