Stable release of v5.0.0

Moved to Joomla 4 and 5.
This commit is contained in:
Robot 2024-01-23 19:16:25 +02:00
parent 8d583feb3f
commit 415b8a2e46
Signed by: Robot
GPG Key ID: 14DECD44E7E1BB95
643 changed files with 10753 additions and 12458 deletions

View File

@ -1,172 +1,3 @@
# v2.1.0
# v5.0.0
- Move all JText to use the namespaced class Text directly.
- Move all JHtml to use the namespaced class Html directly.
- Move all JFactory to use the namespaced class Factory directly.
- Move all JRoute to use the namespaced class Route directly.
- Move all JFormHelper to use the namespaced class FormHelper directly.
- Move all JLayout to use the namespaced class FileLayout directly.
- Move all JLanguageMultilang to use the namespaced class Multilanguage directly.
- Move all JComponentHelper to use the namespaced class ComponentHelper directly.
- Move all JCategoryNode to use the namespaced class CategoryNode directly.
- Move all JComponentHelper to use the namespaced class ComponentHelper directly.
- Move all JToolbar to use the namespaced class Toolbar directly.
- Move all JToolbarHelper to use the namespaced class ToolbarHelper directly.
- Convert all addStyleSheet to make use of Html class instead.
- Convert all addScript to make use of Html class instead.
# v2.0.32
- Fixed other search related issues.
# v2.0.31
- Fixed #10 so that exact search results now work correctly.
- Update scripture loader to version 3.0.3
# v2.0.30
- Update scripture loader to version 3.0.2
# v2.0.29
- Update scripture loader to version 3.0.1
# v2.0.28
- Small xml fix
# v2.0.27
- Improved the load scripture plugin.
# v2.0.26
- Adds few try catch blocks in the API.
- Adds local link to daily scripture module.
# v2.0.25
- Adds getBible Loader Plugin
# v2.0.23
- Refactored all core helper functions to make use of New classes
- Adds open ai meta data to page
- Other JCB fixes
# v2.0.22
- Fixed search redirect bug
# v2.0.21
- Adds Tags meta data to tag pages
- Adds option to share a tag
- Improve the URL creation, and return URL feature for search and tag pages
# v2.0.20
- First step to resolve getBible/support#8 so that the selection works on mobile browsers.
- Fixed the scrolling for mobiles.
# v2.0.19
- Adds metadata to each Bible page to resolve getBible/support#6
- Adds option to force chapter hash checking.
# v2.0.18
- Adds bottom module position on tag, search, ai and app pages.
- Fixed JavaScript Database Manager some more.
# v2.0.17
- Adds brut-force protection
# v2.0.16
- Fixed JavaScript Database Manager
# v2.0.15
- Adds new session option
- Adds make public switches to back-end
# v2.0.14
- Adds install mysql commands for faster queries on large systems.
- Fixes mobile layout on settings active session tab.
- Making correction to tag descriptions.
# v2.0.13
- Fix tag issues
- Adds Footable to back-end
- Fix chapter issue of app page
- Moves translations tab
# v2.0.12
- Fixes Links to Translations (to use their own book names)
# v2.0.11
- Adds better translation selection by Language
# v2.0.9
- Adds create tags on front-end.
- Adds update tags on front-end.
- Adds delete of tags on front-end.
- Improves verse view in note, and tag modal.
- Other bug fixes.
# v2.0.8
- Adds easy option to update book names in the back-end.
- Adds easy option to sync translations details in the back-end.
# v2.0.7
- Adds force update option
- Improves the book name display on Bible page
# v2.0.6
- Adds updating watchers for book names, and translation details.
- Adds edit option to owned tags
- Better session management that allows sharing sessions.
- Few bug fixes
# v2.0.5
- Adds list of default system tags
- Adds linker session manager
- Adds option to share sessions
# v2.0.4
- Added the option to set the default Translation.
- Fixed sharing of a verse, so its auto selected when verse number is clicked.
# v2.0.3
- Fixed getBible/support#2 so that the view value does not result into Undefined.
- Fixed getBible/support#3 so that empty translations and translations without the selected books better manage the mismatching query.
# v2.0.2
- Adds missing Marked JS file
# v2.0.1
- New System Architecture as to how Scripture is added
- New Application Page (Bible Page)
- New Linker (anonymous users) system
- SEO for each chapter of the Bible
- New Easy Sharing System
- New Tagging system
- New Notes system
- New Search system
- Integration with OpenAI
- Moved to Joomla 4 and 5

1820
GetbibleInstallerScript.php Normal file

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
# Get Bible (2.1.0)
# Get Bible (5.0.0)
![Get Bible image](https://git.vdm.dev/getBible/joomla-component/raw/branch/master/admin/assets/images/vdm-component.jpg "GetBible")
![Get Bible image](https://git.vdm.dev/getBible/joomla-component/raw/branch/5.0/admin/assets/images/vdm-component.jpg "GetBible")
Welcome to the next level of scripture engagement - The Bible for Joomla! Our purpose is to bring the Word of God to every person, in their native language, entirely free. This isn't just a typical extension; it's a groundbreaking tool developed to span language divides and deliver a rich, customizable Bible study experience to users worldwide.
@ -18,38 +18,38 @@ In essence, The Bible for Joomla is designed to transform how the Word of God is
+ *Author*: [Llewellyn van der Merwe](mailto:joomla@vdm.io)
+ *Name*: [Get Bible](https://getbible.net)
+ *First Build*: 3rd December, 2015
+ *Last Build*: 23rd December, 2023
+ *Version*: 2.1.0
+ *Last Build*: 23rd January, 2024
+ *Version*: 5.0.0
+ *Copyright*: Copyright (C) 2015. All Rights Reserved
+ *License*: GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
## Build Time
**566 Hours** or **71 Eight Hour Days** (actual time the author saved -
**558 Hours** or **70 Eight Hour Days** (actual time the author saved -
due to [Automated Component Builder](https://www.joomlacomponentbuilder.com))
> (if creating a folder and file took **5 seconds** and writing one line of code took **10 seconds**,
> never making one mistake or taking any coffee break.)
+ *Line count*: **202968**
+ *File count*: **1745**
+ *Folder count*: **167**
+ *Line count*: **199899**
+ *File count*: **1710**
+ *Folder count*: **176**
**374 Hours** or **47 Eight Hour Days** (the actual time the author spent)
**368 Hours** or **46 Eight Hour Days** (the actual time the author spent)
> (with the following break down:
> **debugging @142hours** = codingtime / 4;
> **planning @81hours** = codingtime / 7;
> **mapping @57hours** = codingtime / 10;
> **office @94hours** = codingtime / 6;)
> **debugging @139hours** = codingtime / 4;
> **planning @80hours** = codingtime / 7;
> **mapping @56hours** = codingtime / 10;
> **office @93hours** = codingtime / 6;)
**940 Hours** or **118 Eight Hour Days**
**926 Hours** or **116 Eight Hour Days**
(a total of the realistic time frame for this project)
> (if creating a folder and file took **5 seconds** and writing one line of code took **10 seconds**,
> with the normal everyday realities at the office, that includes the component planning, mapping & debugging.)
Project duration: **23.6 weeks** or **4.9 months**
Project duration: **23.2 weeks** or **4.8 months**
> This **component** was build with a Joomla [Automated Component Builder](https://www.joomlacomponentbuilder.com).
> Developed by [Llewellyn van der Merwe](mailto:joomla@vdm.io)

View File

@ -1,6 +1,6 @@
# Get Bible (2.1.0)
# Get Bible (5.0.0)
![Get Bible image](https://git.vdm.dev/getBible/joomla-component/raw/branch/master/admin/assets/images/vdm-component.jpg "GetBible")
![Get Bible image](https://git.vdm.dev/getBible/joomla-component/raw/branch/5.0/admin/assets/images/vdm-component.jpg "GetBible")
Welcome to the next level of scripture engagement - The Bible for Joomla! Our purpose is to bring the Word of God to every person, in their native language, entirely free. This isn't just a typical extension; it's a groundbreaking tool developed to span language divides and deliver a rich, customizable Bible study experience to users worldwide.
@ -18,38 +18,38 @@ In essence, The Bible for Joomla is designed to transform how the Word of God is
+ *Author*: [Llewellyn van der Merwe](mailto:joomla@vdm.io)
+ *Name*: [Get Bible](https://getbible.net)
+ *First Build*: 3rd December, 2015
+ *Last Build*: 23rd December, 2023
+ *Version*: 2.1.0
+ *Last Build*: 23rd January, 2024
+ *Version*: 5.0.0
+ *Copyright*: Copyright (C) 2015. All Rights Reserved
+ *License*: GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
## Build Time
**566 Hours** or **71 Eight Hour Days** (actual time the author saved -
**558 Hours** or **70 Eight Hour Days** (actual time the author saved -
due to [Automated Component Builder](https://www.joomlacomponentbuilder.com))
> (if creating a folder and file took **5 seconds** and writing one line of code took **10 seconds**,
> never making one mistake or taking any coffee break.)
+ *Line count*: **202968**
+ *File count*: **1745**
+ *Folder count*: **167**
+ *Line count*: **199899**
+ *File count*: **1710**
+ *Folder count*: **176**
**374 Hours** or **47 Eight Hour Days** (the actual time the author spent)
**368 Hours** or **46 Eight Hour Days** (the actual time the author spent)
> (with the following break down:
> **debugging @142hours** = codingtime / 4;
> **planning @81hours** = codingtime / 7;
> **mapping @57hours** = codingtime / 10;
> **office @94hours** = codingtime / 6;)
> **debugging @139hours** = codingtime / 4;
> **planning @80hours** = codingtime / 7;
> **mapping @56hours** = codingtime / 10;
> **office @93hours** = codingtime / 6;)
**940 Hours** or **118 Eight Hour Days**
**926 Hours** or **116 Eight Hour Days**
(a total of the realistic time frame for this project)
> (if creating a folder and file took **5 seconds** and writing one line of code took **10 seconds**,
> with the normal everyday realities at the office, that includes the component planning, mapping & debugging.)
Project duration: **23.6 weeks** or **4.9 months**
Project duration: **23.2 weeks** or **4.8 months**
> This **component** was build with a Joomla [Automated Component Builder](https://www.joomlacomponentbuilder.com).
> Developed by [Llewellyn van der Merwe](mailto:joomla@vdm.io)

View File

@ -17,153 +17,153 @@
/* CSS Document */
.dashboard-container {
margin-left: 10px;
margin-top: 10px;
width: 100%;
margin-left: 10px;
margin-top: 10px;
width: 100%;
}
.dashboard-container [class*="span"] {
display: block;
float: none;
margin-left: 0;
width: auto;
display: block;
float: none;
margin-left: 0;
width: auto;
}
.dashboard-container:before, .dashboard-container:after {
content: "";
display: table;
content: "";
display: table;
}
.dashboard-container:after {
clear: both;
clear: both;
}
.dashboard-container [class*="span"] {
box-sizing: border-box;
display: block;
float: left;
min-height: 145px;
min-width: 96px;
width: 100%;
box-sizing: border-box;
display: block;
float: left;
min-height: 145px;
min-width: 96px;
width: 100%;
}
.dashboard-container [class*="span"]:first-child {
margin-left: 0;
margin-left: 0;
}
.dashboard-wraper {
background: none repeat scroll 0 0 hsl(0, 0%, 93%);
border-radius: 5px;
float: left;
margin: 1%;
padding: 3px;
width: 17%;
min-height: 194px;
min-width: 96px;
background: none repeat scroll 0 0 hsl(0, 0%, 93%);
border-radius: 5px;
float: left;
margin: 1%;
padding: 3px;
width: 17%;
min-height: 194px;
min-width: 96px;
}
.dashboard-content a {
background: linear-gradient(to bottom, hsl(0, 0%, 100%) 0%, hsl(0, 0%, 96%) 47%, hsl(0, 0%, 93%) 100%) repeat scroll 0 0 hsla(0, 0%, 0%, 0);
border: 1px solid hsl(0, 0%, 85%);
border-radius: 4px;
box-shadow: 0 0 3px hsla(0, 0%, 0%, 0.1) inset;
color: hsl(0, 0%, 20%);
display: block;
min-height: 89px;
padding: 10px;
text-align: center;
text-decoration: none;
background: linear-gradient(to bottom, hsl(0, 0%, 100%) 0%, hsl(0, 0%, 96%) 47%, hsl(0, 0%, 93%) 100%) repeat scroll 0 0 hsla(0, 0%, 0%, 0);
border: 1px solid hsl(0, 0%, 85%);
border-radius: 4px;
box-shadow: 0 0 3px hsla(0, 0%, 0%, 0.1) inset;
color: hsl(0, 0%, 20%);
display: block;
min-height: 89px;
padding: 10px;
text-align: center;
text-decoration: none;
}
.dashboard-content a:hover {
background: linear-gradient(to bottom, hsl(0, 0%, 90%) 0%, hsl(0, 0%, 100%) 100%) repeat scroll 0 0 hsla(0, 0%, 0%, 0);
color: hsl(200, 100%, 30%);
text-decoration: none;
background: linear-gradient(to bottom, hsl(0, 0%, 90%) 0%, hsl(0, 0%, 100%) 100%) repeat scroll 0 0 hsla(0, 0%, 0%, 0);
color: hsl(200, 100%, 30%);
text-decoration: none;
}
.dashboard-title {
display: block;
padding-top: 5px;
display: block;
padding-top: 5px;
}
.dashboard-info {
background: linear-gradient(to bottom, hsl(0, 0%, 100%) 0%, hsl(0, 0%, 96%) 47%, hsl(0, 0%, 93%) 100%) repeat scroll 0 0 hsla(0, 0%, 0%, 0);
border: 1px solid hsl(0, 0%, 85%);
border-radius: 4px;
box-shadow: 0 0 3px hsla(0, 0%, 0%, 0.1) inset;
color: hsl(0, 0%, 20%);
display: block;
font-size: 12px;
padding: 10px;
text-align: center;
background: linear-gradient(to bottom, hsl(0, 0%, 100%) 0%, hsl(0, 0%, 96%) 47%, hsl(0, 0%, 93%) 100%) repeat scroll 0 0 hsla(0, 0%, 0%, 0);
border: 1px solid hsl(0, 0%, 85%);
border-radius: 4px;
box-shadow: 0 0 3px hsla(0, 0%, 0%, 0.1) inset;
color: hsl(0, 0%, 20%);
display: block;
font-size: 12px;
padding: 10px;
text-align: center;
}
.dashboard-info span {
display: block;
text-align: center;
display: block;
text-align: center;
}
.dashboard-info img {
margin: 0 auto;
margin: 0 auto;
}
.dashboard-table {
border-top: 1px solid hsl(0, 0%, 87%);
margin-top: 5px;
width: 100%;
border-top: 1px solid hsl(0, 0%, 87%);
margin-top: 5px;
width: 100%;
}
.dashboard-info h5 {
font-size: 11px;
font-weight: bold;
font-size: 11px;
font-weight: bold;
}
.dashboard-block {
background: linear-gradient(to bottom, hsl(0, 0%, 95%) 0%, hsl(0, 0%, 86%) 100%) repeat scroll 0 0 hsla(0, 0%, 0%, 0);
border: 1px solid hsl(0, 0%, 76%);
border-radius: 3px;
box-shadow: 0 1px 0 hsl(0, 0%, 98%) inset;
margin-bottom: 20px;
background: linear-gradient(to bottom, hsl(0, 0%, 95%) 0%, hsl(0, 0%, 86%) 100%) repeat scroll 0 0 hsla(0, 0%, 0%, 0);
border: 1px solid hsl(0, 0%, 76%);
border-radius: 3px;
box-shadow: 0 1px 0 hsl(0, 0%, 98%) inset;
margin-bottom: 20px;
}
.dashboard-block .dashboard-block-head {
background: linear-gradient(to bottom, hsl(0, 0%, 95%) 0%, hsl(0, 0%, 86%) 100%) repeat scroll 0 0 hsla(0, 0%, 0%, 0);
border-bottom: 1px solid hsl(0, 0%, 76%);
border-radius: 3px 3px 0 0;
box-shadow: 0 1px 0 hsl(0, 0%, 98%) inset, 0 0 3px hsl(0, 0%, 87%);
height: 40px;
position: relative;
background: linear-gradient(to bottom, hsl(0, 0%, 95%) 0%, hsl(0, 0%, 86%) 100%) repeat scroll 0 0 hsla(0, 0%, 0%, 0);
border-bottom: 1px solid hsl(0, 0%, 76%);
border-radius: 3px 3px 0 0;
box-shadow: 0 1px 0 hsl(0, 0%, 98%) inset, 0 0 3px hsl(0, 0%, 87%);
height: 40px;
position: relative;
}
.dashboard-block .dashboard-block-head h5 {
font-size: 12px;
margin: 0;
padding-left: 10px;
padding-top: 11px;
text-transform: uppercase;
font-size: 12px;
margin: 0;
padding-left: 10px;
padding-top: 11px;
text-transform: uppercase;
}
.dashboard-block .dashboard-block-content {
background: none repeat scroll 0 0 hsl(0, 0%, 93%);
border-radius: 0 0 3px 3px;
background: none repeat scroll 0 0 hsl(0, 0%, 93%);
border-radius: 0 0 3px 3px;
}
.dashboard-block .dashboard-block-box {
background: none repeat scroll 0 0 hsl(0, 0%, 100%);
border-top: 1px solid hsl(0, 0%, 82%);
box-shadow: 0 0 5px hsl(0, 0%, 87%) inset;
background: none repeat scroll 0 0 hsl(0, 0%, 100%);
border-top: 1px solid hsl(0, 0%, 82%);
box-shadow: 0 0 5px hsl(0, 0%, 87%) inset;
}
.dashboard-block .dashboard-block-content .dashboard-block-box {
margin-top: 0 !important;
margin-top: 0 !important;
}
.dashboard-block .dashboard-block-content .dashboard-block-box .dashboard-block-table {
margin-bottom: 0 !important;
margin-bottom: 0 !important;
}
.dashboard-block-table {
background-color: hsla(0, 0%, 0%, 0);
border-collapse: collapse;
border-spacing: 0;
margin-bottom: 20px;
max-width: 100%;
width: 100%;
background-color: hsla(0, 0%, 0%, 0);
border-collapse: collapse;
border-spacing: 0;
margin-bottom: 20px;
max-width: 100%;
width: 100%;
}
.dashboard-block-table th, .dashboard-block-table td {
border-top: 1px solid hsl(0, 0%, 87%);
line-height: 20px;
padding: 5px;
text-align: left;
vertical-align: middle;
border-top: 1px solid hsl(0, 0%, 87%);
line-height: 20px;
padding: 5px;
text-align: left;
vertical-align: middle;
}
.dashboard-badge {
background-color: hsl(0, 0%, 60%);
border-radius: 9px;
color: hsl(0, 0%, 100%);
font-size: 11.844px;
font-weight: bold;
line-height: 14px;
padding: 1px 9px 2px;
text-shadow: 0 -1px 0 hsla(0, 0%, 0%, 0.25);
vertical-align: baseline;
white-space: nowrap;
background-color: hsl(0, 0%, 60%);
border-radius: 9px;
color: hsl(0, 0%, 100%);
font-size: 11.844px;
font-weight: bold;
line-height: 14px;
padding: 1px 9px 2px;
text-shadow: 0 -1px 0 hsla(0, 0%, 0%, 0.25);
vertical-align: baseline;
white-space: nowrap;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 64 KiB

After

Width:  |  Height:  |  Size: 65 KiB

View File

@ -1,8 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<config>
<fieldset
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
name="global_config"
label="COM_GETBIBLE_CONFIG_GLOBAL_LABEL"
description="COM_GETBIBLE_CONFIG_GLOBAL_DESC">
@ -174,59 +174,6 @@
readonly="true"
class="readonly"
/>
<field type="spacer" name="spacerContributor1" hr="true" />
<field name="contributor1"
type="spacer"
class="text"
label="COM_GETBIBLE_CONFIG_CONTRIBUTOR_ONE"
/>
<field name="titleContributor1"
type="text"
label="COM_GETBIBLE_CONFIG_CONTRIBUTOR_TITLE_LABEL"
description="COM_GETBIBLE_CONFIG_CONTRIBUTOR_TITLE_DESC"
size="60"
default="Modules"
/>
<field name="nameContributor1"
type="text"
label="COM_GETBIBLE_CONFIG_CONTRIBUTOR_NAME_LABEL"
description="COM_GETBIBLE_CONFIG_CONTRIBUTOR_NAME_DESC"
size="60"
default="CrossWire"
/>
<field name="emailContributor1"
type="email"
label="COM_GETBIBLE_CONFIG_CONTRIBUTOR_EMAIL_LABEL"
description="COM_GETBIBLE_CONFIG_CONTRIBUTOR_EMAIL_DESC"
size="60"
default="sword-support@crosswire.org"
/>
<field name="linkContributor1"
type="url"
label="COM_GETBIBLE_CONFIG_CONTRIBUTOR_LINK_LABEL"
description="COM_GETBIBLE_CONFIG_CONTRIBUTOR_LINK_DESC"
size="60"
default="https://wiki.crosswire.org/"
/>
<field name="useContributor1"
type="list"
default="2"
label="COM_GETBIBLE_CONFIG_CONTRIBUTOR_USE_LABEL"
description="COM_GETBIBLE_CONFIG_CONTRIBUTOR_USE_DESC">
<option value="0">COM_GETBIBLE_CONFIG_CONTRIBUTOR_USE_NONE</option>
<option value="1">COM_GETBIBLE_CONFIG_CONTRIBUTOR_USE_EMAIL</option>
<option value="2">COM_GETBIBLE_CONFIG_CONTRIBUTOR_USE_WWW</option>
</field>
<field name="showContributor1"
type="list"
default="3"
label="COM_GETBIBLE_CONFIG_CONTRIBUTOR_SHOW_LABEL"
description="COM_GETBIBLE_CONFIG_CONTRIBUTOR_SHOW_DESC">
<option value="0">COM_GETBIBLE_CONFIG_CONTRIBUTOR_SHOW_NONE</option>
<option value="1">COM_GETBIBLE_CONFIG_CONTRIBUTOR_SHOW_BACK</option>
<option value="2">COM_GETBIBLE_CONFIG_CONTRIBUTOR_SHOW_FRONT</option>
<option value="3">COM_GETBIBLE_CONFIG_CONTRIBUTOR_SHOW_ALL</option>
</field>
</fieldset>
<fieldset
name="uikit_config"

View File

@ -1,134 +0,0 @@
<?php
/*----------------------------------------------------------------------------------| io.vdm.dev |----/
Vast Development Method
/-------------------------------------------------------------------------------------------------------/
@package getBible.net
@created 3rd December, 2015
@author Llewellyn van der Merwe <https://getbible.net>
@git Get Bible <https://git.vdm.dev/getBible>
@github Get Bible <https://github.com/getBible>
@support Get Bible <https://git.vdm.dev/getBible/support>
@copyright Copyright (C) 2015. All Rights Reserved
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
/------------------------------------------------------------------------------------------------------*/
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
use Joomla\CMS\MVC\Controller\BaseController;
use Joomla\Utilities\ArrayHelper;
use Joomla\CMS\Language\Text;
use Joomla\CMS\Router\Route;
use VDM\Joomla\Utilities\ArrayHelper as UtilitiesArrayHelper;
use VDM\Joomla\Utilities\StringHelper;
/**
* General Controller of Getbible component
*/
class GetbibleController extends BaseController
{
/**
* Constructor.
*
* @param array $config An optional associative array of configuration settings.
* Recognized key values include 'name', 'default_task', 'model_path', and
* 'view_path' (this list is not meant to be comprehensive).
*
* @since 3.0
*/
public function __construct($config = [])
{
// set the default view
$config['default_view'] = 'getbible';
parent::__construct($config);
}
/**
* display task
*
* @return void
*/
function display($cachable = false, $urlparams = false)
{
// set default view if not set
$view = $this->input->getCmd('view', 'getbible');
$data = $this->getViewRelation($view);
$layout = $this->input->get('layout', null, 'WORD');
$id = $this->input->getInt('id');
// Check for edit form.
if(UtilitiesArrayHelper::check($data))
{
if ($data['edit'] && $layout == 'edit' && !$this->checkEditId('com_getbible.edit.'.$data['view'], $id))
{
// Somehow the person just went to the form - we don't allow that.
$this->setError(Text::sprintf('JLIB_APPLICATION_ERROR_UNHELD_ID', $id));
$this->setMessage($this->getError(), 'error');
// check if item was opend from other then its own list view
$ref = $this->input->getCmd('ref', 0);
$refid = $this->input->getInt('refid', 0);
// set redirect
if ($refid > 0 && StringHelper::check($ref))
{
// redirect to item of ref
$this->setRedirect(Route::_('index.php?option=com_getbible&view='.(string)$ref.'&layout=edit&id='.(int)$refid, false));
}
elseif (StringHelper::check($ref))
{
// redirect to ref
$this->setRedirect(Route::_('index.php?option=com_getbible&view='.(string)$ref, false));
}
else
{
// normal redirect back to the list view
$this->setRedirect(Route::_('index.php?option=com_getbible&view='.$data['views'], false));
}
return false;
}
}
return parent::display($cachable, $urlparams);
}
protected function getViewRelation($view)
{
// check the we have a value
if (StringHelper::check($view))
{
// the view relationships
$views = array(
'linker' => 'linkers',
'note' => 'notes',
'tagged_verse' => 'tagged_verses',
'prompt' => 'prompts',
'open_ai_response' => 'open_ai_responses',
'open_ai_message' => 'open_ai_messages',
'password' => 'passwords',
'tag' => 'tags',
'translation' => 'translations',
'book' => 'books',
'chapter' => 'chapters',
'verse' => 'verses'
);
// check if this is a list view
if (in_array($view, $views))
{
// this is a list view
return array('edit' => false, 'view' => array_search($view,$views), 'views' => $view);
}
// check if it is an edit view
elseif (array_key_exists($view, $views))
{
// this is a edit view
return array('edit' => true, 'view' => $view, 'views' => $views[$view]);
}
}
return false;
}
}

View File

@ -1,8 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<form
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
>
<config>
<inlinehelp button="show"/>
</config>
<fieldset name="details">
<!-- Default Fields. -->
<!-- Id Field. Type: Text (joomla) -->
@ -159,7 +162,7 @@
message="COM_GETBIBLE_BOOK_SHA_MESSAGE"
/>
</fieldset>
<!-- Access Control Fields. -->
<fieldset name="accesscontrol">
<!-- Asset Id Field. Type: Hidden (joomla) -->

View File

@ -1,8 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<form
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
>
<config>
<inlinehelp button="show"/>
</config>
<fieldset name="details">
<!-- Default Fields. -->
<!-- Id Field. Type: Text (joomla) -->
@ -171,7 +174,7 @@
message="COM_GETBIBLE_CHAPTER_SHA_MESSAGE"
/>
</fieldset>
<!-- Access Control Fields. -->
<fieldset name="accesscontrol">
<!-- Asset Id Field. Type: Hidden (joomla) -->

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<form
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
>
<fields name="filter">
<field
@ -17,39 +17,41 @@
name="published"
label="COM_GETBIBLE_FILTER_PUBLISHED"
description="COM_GETBIBLE_FILTER_PUBLISHED_BOOKS"
onchange="this.form.submit();"
class="js-select-submit-on-change"
>
<option value="">JOPTION_SELECT_PUBLISHED</option>
</field>
<field
type="accesslevel"
name="access"
label="JFIELD_ACCESS_LABEL"
description="JFIELD_ACCESS_DESC"
label="JGRID_HEADING_ACCESS"
hint="JOPTION_SELECT_ACCESS"
multiple="true"
class="multipleAccessLevels"
onchange="this.form.submit();"
class="js-select-submit-on-change"
layout="joomla.form.field.list-fancy-select"
/>
<field
type="booksfiltername"
name="name"
label="COM_GETBIBLE_BOOK_NAME_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="translations"
name="abbreviation"
label="COM_GETBIBLE_BOOK_ABBREVIATION_LABEL"
multiple="false"
onchange="this.form.submit();"
layout="joomla.form.field.list-fancy-select"
multiple="true"
hint="COM_GETBIBLE_FILTER_SELECT_TRANSLATION"
class="js-select-submit-on-change"
/>
<field
type="booksfilternr"
name="nr"
label="COM_GETBIBLE_BOOK_NR_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<input type="hidden" name="form_submited" value="1"/>
</fields>
@ -58,9 +60,8 @@
<field
name="fullordering"
type="list"
label="COM_CONTENT_LIST_FULL_ORDERING"
description="COM_CONTENT_LIST_FULL_ORDERING_DESC"
onchange="this.form.submit();"
label="JGLOBAL_SORT_BY"
class="js-select-submit-on-change"
default="g.translation asc"
validate="options"
>
@ -82,11 +83,9 @@
<field
name="limit"
type="limitbox"
label="COM_CONTENT_LIST_LIMIT"
description="COM_CONTENT_LIST_LIMIT_DESC"
class="input-mini"
label="JGLOBAL_LIST_LIMIT"
default="25"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
</fields>
</form>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<form
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
>
<fields name="filter">
<field
@ -17,41 +17,43 @@
name="published"
label="COM_GETBIBLE_FILTER_PUBLISHED"
description="COM_GETBIBLE_FILTER_PUBLISHED_CHAPTERS"
onchange="this.form.submit();"
class="js-select-submit-on-change"
>
<option value="">JOPTION_SELECT_PUBLISHED</option>
</field>
<field
type="accesslevel"
name="access"
label="JFIELD_ACCESS_LABEL"
description="JFIELD_ACCESS_DESC"
label="JGRID_HEADING_ACCESS"
hint="JOPTION_SELECT_ACCESS"
multiple="true"
class="multipleAccessLevels"
onchange="this.form.submit();"
class="js-select-submit-on-change"
layout="joomla.form.field.list-fancy-select"
/>
<field
type="chaptersfilterchapter"
name="chapter"
label="COM_GETBIBLE_CHAPTER_CHAPTER_LABEL"
class="multipleChaptersfilterchapter"
layout="joomla.form.field.list-fancy-select"
multiple="true"
onchange="this.form.submit();"
hint="COM_GETBIBLE_FILTER_SELECT_CHAPTER"
class="js-select-submit-on-change"
/>
<field
type="chaptersfilterbooknr"
name="book_nr"
label="COM_GETBIBLE_CHAPTER_BOOK_NR_LABEL"
class="multipleChaptersfilterbooknr"
layout="joomla.form.field.list-fancy-select"
multiple="true"
onchange="this.form.submit();"
hint="COM_GETBIBLE_FILTER_SELECT_BOOK_NUMBER"
class="js-select-submit-on-change"
/>
<field
type="translations"
name="abbreviation"
label="COM_GETBIBLE_CHAPTER_ABBREVIATION_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<input type="hidden" name="form_submited" value="1"/>
</fields>
@ -60,9 +62,8 @@
<field
name="fullordering"
type="list"
label="COM_CONTENT_LIST_FULL_ORDERING"
description="COM_CONTENT_LIST_FULL_ORDERING_DESC"
onchange="this.form.submit();"
label="JGLOBAL_SORT_BY"
class="js-select-submit-on-change"
default="g.translation asc"
validate="options"
>
@ -86,11 +87,9 @@
<field
name="limit"
type="limitbox"
label="COM_CONTENT_LIST_LIMIT"
description="COM_CONTENT_LIST_LIMIT_DESC"
class="input-mini"
label="JGLOBAL_LIST_LIMIT"
default="25"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
</fields>
</form>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<form
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
>
<fields name="filter">
<field
@ -17,39 +17,39 @@
name="published"
label="COM_GETBIBLE_FILTER_PUBLISHED"
description="COM_GETBIBLE_FILTER_PUBLISHED_LINKERS"
onchange="this.form.submit();"
class="js-select-submit-on-change"
>
<option value="">JOPTION_SELECT_PUBLISHED</option>
</field>
<field
type="accesslevel"
name="access"
label="JFIELD_ACCESS_LABEL"
description="JFIELD_ACCESS_DESC"
label="JGRID_HEADING_ACCESS"
hint="JOPTION_SELECT_ACCESS"
multiple="true"
class="multipleAccessLevels"
onchange="this.form.submit();"
class="js-select-submit-on-change"
layout="joomla.form.field.list-fancy-select"
/>
<field
type="linkersfiltername"
name="name"
label="COM_GETBIBLE_LINKER_NAME_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="linkersfilterpublictaggedverses"
name="public_tagged_verses"
label="COM_GETBIBLE_LINKER_PUBLIC_TAGGED_VERSES_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="linkersfilterpublicnotes"
name="public_notes"
label="COM_GETBIBLE_LINKER_PUBLIC_NOTES_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<input type="hidden" name="form_submited" value="1"/>
</fields>
@ -58,9 +58,8 @@
<field
name="fullordering"
type="list"
label="COM_CONTENT_LIST_FULL_ORDERING"
description="COM_CONTENT_LIST_FULL_ORDERING_DESC"
onchange="this.form.submit();"
label="JGLOBAL_SORT_BY"
class="js-select-submit-on-change"
default="a.id DESC"
validate="options"
>
@ -82,11 +81,9 @@
<field
name="limit"
type="limitbox"
label="COM_CONTENT_LIST_LIMIT"
description="COM_CONTENT_LIST_LIMIT_DESC"
class="input-mini"
label="JGLOBAL_LIST_LIMIT"
default="25"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
</fields>
</form>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<form
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
>
<fields name="filter">
<field
@ -17,7 +17,7 @@
name="published"
label="COM_GETBIBLE_FILTER_PUBLISHED"
description="COM_GETBIBLE_FILTER_PUBLISHED_NOTES"
onchange="this.form.submit();"
class="js-select-submit-on-change"
>
<option value="">JOPTION_SELECT_PUBLISHED</option>
</field>
@ -26,35 +26,35 @@
name="book_nr"
label="COM_GETBIBLE_NOTE_BOOK_NR_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="linkers"
name="linker"
label="COM_GETBIBLE_NOTE_LINKER_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="notesfilteraccess"
name="access"
label="COM_GETBIBLE_NOTE_ACCESS_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="notesfilterverse"
name="verse"
label="COM_GETBIBLE_NOTE_VERSE_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="notesfilterchapter"
name="chapter"
label="COM_GETBIBLE_NOTE_CHAPTER_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<input type="hidden" name="form_submited" value="1"/>
</fields>
@ -63,9 +63,8 @@
<field
name="fullordering"
type="list"
label="COM_CONTENT_LIST_FULL_ORDERING"
description="COM_CONTENT_LIST_FULL_ORDERING_DESC"
onchange="this.form.submit();"
label="JGLOBAL_SORT_BY"
class="js-select-submit-on-change"
default="a.id DESC"
validate="options"
>
@ -87,11 +86,9 @@
<field
name="limit"
type="limitbox"
label="COM_CONTENT_LIST_LIMIT"
description="COM_CONTENT_LIST_LIMIT_DESC"
class="input-mini"
label="JGLOBAL_LIST_LIMIT"
default="25"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
</fields>
</form>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<form
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
>
<fields name="filter">
<field
@ -17,46 +17,46 @@
name="published"
label="COM_GETBIBLE_FILTER_PUBLISHED"
description="COM_GETBIBLE_FILTER_PUBLISHED_OPEN_AI_MESSAGES"
onchange="this.form.submit();"
class="js-select-submit-on-change"
>
<option value="">JOPTION_SELECT_PUBLISHED</option>
</field>
<field
type="accesslevel"
name="access"
label="JFIELD_ACCESS_LABEL"
description="JFIELD_ACCESS_DESC"
label="JGRID_HEADING_ACCESS"
hint="JOPTION_SELECT_ACCESS"
multiple="true"
class="multipleAccessLevels"
onchange="this.form.submit();"
class="js-select-submit-on-change"
layout="joomla.form.field.list-fancy-select"
/>
<field
type="openaimessagesfilterrole"
name="role"
label="COM_GETBIBLE_OPEN_AI_MESSAGE_ROLE_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="openairesponses"
name="open_ai_response"
label="COM_GETBIBLE_OPEN_AI_MESSAGE_OPEN_AI_RESPONSE_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="prompts"
name="prompt"
label="COM_GETBIBLE_OPEN_AI_MESSAGE_PROMPT_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="openaimessagesfiltersource"
name="source"
label="COM_GETBIBLE_OPEN_AI_MESSAGE_SOURCE_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<input type="hidden" name="form_submited" value="1"/>
</fields>
@ -65,9 +65,8 @@
<field
name="fullordering"
type="list"
label="COM_CONTENT_LIST_FULL_ORDERING"
description="COM_CONTENT_LIST_FULL_ORDERING_DESC"
onchange="this.form.submit();"
label="JGLOBAL_SORT_BY"
class="js-select-submit-on-change"
default="a.id desc"
validate="options"
>
@ -91,11 +90,9 @@
<field
name="limit"
type="limitbox"
label="COM_CONTENT_LIST_LIMIT"
description="COM_CONTENT_LIST_LIMIT_DESC"
class="input-mini"
label="JGLOBAL_LIST_LIMIT"
default="25"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
</fields>
</form>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<form
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
>
<fields name="filter">
<field
@ -17,39 +17,39 @@
name="published"
label="COM_GETBIBLE_FILTER_PUBLISHED"
description="COM_GETBIBLE_FILTER_PUBLISHED_OPEN_AI_RESPONSES"
onchange="this.form.submit();"
class="js-select-submit-on-change"
>
<option value="">JOPTION_SELECT_PUBLISHED</option>
</field>
<field
type="accesslevel"
name="access"
label="JFIELD_ACCESS_LABEL"
description="JFIELD_ACCESS_DESC"
label="JGRID_HEADING_ACCESS"
hint="JOPTION_SELECT_ACCESS"
multiple="true"
class="multipleAccessLevels"
onchange="this.form.submit();"
class="js-select-submit-on-change"
layout="joomla.form.field.list-fancy-select"
/>
<field
type="openairesponsesfilterresponseid"
name="response_id"
label="COM_GETBIBLE_OPEN_AI_RESPONSE_RESPONSE_ID_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="prompts"
name="prompt"
label="COM_GETBIBLE_OPEN_AI_RESPONSE_PROMPT_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="openairesponsesfilterresponsemodel"
name="response_model"
label="COM_GETBIBLE_OPEN_AI_RESPONSE_RESPONSE_MODEL_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<input type="hidden" name="form_submited" value="1"/>
</fields>
@ -58,9 +58,8 @@
<field
name="fullordering"
type="list"
label="COM_CONTENT_LIST_FULL_ORDERING"
description="COM_CONTENT_LIST_FULL_ORDERING_DESC"
onchange="this.form.submit();"
label="JGLOBAL_SORT_BY"
class="js-select-submit-on-change"
default="a.id desc"
validate="options"
>
@ -86,11 +85,9 @@
<field
name="limit"
type="limitbox"
label="COM_CONTENT_LIST_LIMIT"
description="COM_CONTENT_LIST_LIMIT_DESC"
class="input-mini"
label="JGLOBAL_LIST_LIMIT"
default="25"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
</fields>
</form>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<form
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
>
<fields name="filter">
<field
@ -17,32 +17,32 @@
name="published"
label="COM_GETBIBLE_FILTER_PUBLISHED"
description="COM_GETBIBLE_FILTER_PUBLISHED_PASSWORDS"
onchange="this.form.submit();"
class="js-select-submit-on-change"
>
<option value="">JOPTION_SELECT_PUBLISHED</option>
</field>
<field
type="accesslevel"
name="access"
label="JFIELD_ACCESS_LABEL"
description="JFIELD_ACCESS_DESC"
label="JGRID_HEADING_ACCESS"
hint="JOPTION_SELECT_ACCESS"
multiple="true"
class="multipleAccessLevels"
onchange="this.form.submit();"
class="js-select-submit-on-change"
layout="joomla.form.field.list-fancy-select"
/>
<field
type="passwordsfiltername"
name="name"
label="COM_GETBIBLE_PASSWORD_NAME_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="linkers"
name="linker"
label="COM_GETBIBLE_PASSWORD_LINKER_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<input type="hidden" name="form_submited" value="1"/>
</fields>
@ -51,9 +51,8 @@
<field
name="fullordering"
type="list"
label="COM_CONTENT_LIST_FULL_ORDERING"
description="COM_CONTENT_LIST_FULL_ORDERING_DESC"
onchange="this.form.submit();"
label="JGLOBAL_SORT_BY"
class="js-select-submit-on-change"
default="a.id DESC"
validate="options"
>
@ -73,11 +72,9 @@
<field
name="limit"
type="limitbox"
label="COM_CONTENT_LIST_LIMIT"
description="COM_CONTENT_LIST_LIMIT_DESC"
class="input-mini"
label="JGLOBAL_LIST_LIMIT"
default="25"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
</fields>
</form>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<form
addrulepath="/administrator/components/com_getbible/models/rules"
addfieldpath="/administrator/components/com_getbible/models/fields"
addruleprefix="TrueChristianChurch\Component\Getbible\Administrator\Rule"
addfieldprefix="TrueChristianChurch\Component\Getbible\Administrator\Field"
>
<fields name="filter">
<field
@ -17,46 +17,46 @@
name="published"
label="COM_GETBIBLE_FILTER_PUBLISHED"
description="COM_GETBIBLE_FILTER_PUBLISHED_PROMPTS"
onchange="this.form.submit();"
class="js-select-submit-on-change"
>
<option value="">JOPTION_SELECT_PUBLISHED</option>
</field>
<field
type="accesslevel"
name="access"
label="JFIELD_ACCESS_LABEL"
description="JFIELD_ACCESS_DESC"
label="JGRID_HEADING_ACCESS"
hint="JOPTION_SELECT_ACCESS"
multiple="true"
class="multipleAccessLevels"
onchange="this.form.submit();"
class="js-select-submit-on-change"
layout="joomla.form.field.list-fancy-select"
/>
<field
type="promptsfiltername"
name="name"
label="COM_GETBIBLE_PROMPT_NAME_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="promptsfiltercachebehaviour"
name="cache_behaviour"
label="COM_GETBIBLE_PROMPT_CACHE_BEHAVIOUR_LABEL"
multiple="false"
onchange="this.form.submit();"
class="js-select-submit-on-change"
/>
<field
type="targettranslations"
name="abbreviation"
label="COM_GETBIBLE_PROMPT_ABBREVIATION_LABEL"