Library manager implementation #195

Merged
Llewellyn merged 24 commits from staging into master 2017-12-12 13:31:16 +00:00
835 changed files with 24527 additions and 13925 deletions

View File

@ -10,7 +10,7 @@ The Component Builder for [Joomla](https://extensions.joomla.org/extension/compo
Whether you're a seasoned [Joomla](https://extensions.joomla.org/extension/component-builder/) developer, or have just started, Component Builder will safe you lots of time and money. A real must have! Whether you're a seasoned [Joomla](https://extensions.joomla.org/extension/component-builder/) developer, or have just started, Component Builder will safe you lots of time and money. A real must have!
You can install it quite easily and with no limitations. On [github](https://github.com/vdm-io/Joomla-Component-Builder/releases) is the latest release (2.6.5) with **ALL** its features and **ALL** concepts totally open-source and free! You can install it quite easily and with no limitations. On [github](https://github.com/vdm-io/Joomla-Component-Builder/releases) is the latest release (2.6.6) with **ALL** its features and **ALL** concepts totally open-source and free!
> Watch Quick Build of a Hello World component in [JCB on Youtube](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45) > Watch Quick Build of a Hello World component in [JCB on Youtube](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45)
@ -111,13 +111,13 @@ Component Builder is mapped as a component in itself on my local development env
+ *Author*: [Llewellyn van der Merwe](mailto:joomla@vdm.io) + *Author*: [Llewellyn van der Merwe](mailto:joomla@vdm.io)
+ *Name*: [Component Builder](http://vdm.bz/component-builder) + *Name*: [Component Builder](http://vdm.bz/component-builder)
+ *First Build*: 30th April, 2015 + *First Build*: 30th April, 2015
+ *Last Build*: 21st November, 2017 + *Last Build*: 12th December, 2017
+ *Version*: 2.6.5 + *Version*: 2.6.6
+ *Copyright*: Copyright (C) 2015. All Rights Reserved + *Copyright*: Copyright (C) 2015. All Rights Reserved
+ *License*: GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html + *License*: GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
+ *Line count*: **168387** + *Line count*: **177938**
+ *File count*: **1073** + *File count*: **1142**
+ *Folder count*: **176** + *Folder count*: **184**
> This **component** was build with a Joomla [Automated Component Builder](http://vdm.bz/component-builder). > This **component** was build with a Joomla [Automated Component Builder](http://vdm.bz/component-builder).
> Developed by [Llewellyn van der Merwe](mailto:joomla@vdm.io) > Developed by [Llewellyn van der Merwe](mailto:joomla@vdm.io)
@ -126,5 +126,5 @@ Component Builder is mapped as a component in itself on my local development env
Come on buy me a coffee :) Come on buy me a coffee :)
* PayPal: [paypal.me/payvdm](https://www.paypal.me/payvdm) * PayPal: [paypal.me/payvdm](https://www.paypal.me/payvdm)
* Bitcoin: 1FLxiT6wyxgZ3boeviLkYJ1DRpp41uzpxa * Bitcoin: 18vURxYpPFjvNk8BnUy1ovCAyQmY3MzkSf
* Ethereum: 0x243392daa3c9c8bc841fcacf7c7f72541cb16823 * Ethereum: 0x9548144662b47327c954f3e214edb96662d51218

View File

@ -10,7 +10,7 @@ The Component Builder for [Joomla](https://extensions.joomla.org/extension/compo
Whether you're a seasoned [Joomla](https://extensions.joomla.org/extension/component-builder/) developer, or have just started, Component Builder will safe you lots of time and money. A real must have! Whether you're a seasoned [Joomla](https://extensions.joomla.org/extension/component-builder/) developer, or have just started, Component Builder will safe you lots of time and money. A real must have!
You can install it quite easily and with no limitations. On [github](https://github.com/vdm-io/Joomla-Component-Builder/releases) is the latest release (2.6.5) with **ALL** its features and **ALL** concepts totally open-source and free! You can install it quite easily and with no limitations. On [github](https://github.com/vdm-io/Joomla-Component-Builder/releases) is the latest release (2.6.6) with **ALL** its features and **ALL** concepts totally open-source and free!
> Watch Quick Build of a Hello World component in [JCB on Youtube](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45) > Watch Quick Build of a Hello World component in [JCB on Youtube](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45)
@ -111,13 +111,13 @@ Component Builder is mapped as a component in itself on my local development env
+ *Author*: [Llewellyn van der Merwe](mailto:joomla@vdm.io) + *Author*: [Llewellyn van der Merwe](mailto:joomla@vdm.io)
+ *Name*: [Component Builder](http://vdm.bz/component-builder) + *Name*: [Component Builder](http://vdm.bz/component-builder)
+ *First Build*: 30th April, 2015 + *First Build*: 30th April, 2015
+ *Last Build*: 21st November, 2017 + *Last Build*: 12th December, 2017
+ *Version*: 2.6.5 + *Version*: 2.6.6
+ *Copyright*: Copyright (C) 2015. All Rights Reserved + *Copyright*: Copyright (C) 2015. All Rights Reserved
+ *License*: GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html + *License*: GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
+ *Line count*: **168387** + *Line count*: **177938**
+ *File count*: **1073** + *File count*: **1142**
+ *Folder count*: **176** + *Folder count*: **184**
> This **component** was build with a Joomla [Automated Component Builder](http://vdm.bz/component-builder). > This **component** was build with a Joomla [Automated Component Builder](http://vdm.bz/component-builder).
> Developed by [Llewellyn van der Merwe](mailto:joomla@vdm.io) > Developed by [Llewellyn van der Merwe](mailto:joomla@vdm.io)
@ -126,5 +126,5 @@ Component Builder is mapped as a component in itself on my local development env
Come on buy me a coffee :) Come on buy me a coffee :)
* PayPal: [paypal.me/payvdm](https://www.paypal.me/payvdm) * PayPal: [paypal.me/payvdm](https://www.paypal.me/payvdm)
* Bitcoin: 1FLxiT6wyxgZ3boeviLkYJ1DRpp41uzpxa * Bitcoin: 18vURxYpPFjvNk8BnUy1ovCAyQmY3MzkSf
* Ethereum: 0x243392daa3c9c8bc841fcacf7c7f72541cb16823 * Ethereum: 0x9548144662b47327c954f3e214edb96662d51218

View File

@ -229,6 +229,7 @@
<action name="get_snippets.access" title="COM_COMPONENTBUILDER_GET_SNIPPETS_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_ACCESS_DESC" /> <action name="get_snippets.access" title="COM_COMPONENTBUILDER_GET_SNIPPETS_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_ACCESS_DESC" />
<action name="get_snippets.custom_admin_views" title="COM_COMPONENTBUILDER_GET_SNIPPETS_CUSTOM_ADMIN_VIEWS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_CUSTOM_ADMIN_VIEWS_BUTTON_ACCESS_DESC" /> <action name="get_snippets.custom_admin_views" title="COM_COMPONENTBUILDER_GET_SNIPPETS_CUSTOM_ADMIN_VIEWS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_CUSTOM_ADMIN_VIEWS_BUTTON_ACCESS_DESC" />
<action name="get_snippets.layouts" title="COM_COMPONENTBUILDER_GET_SNIPPETS_LAYOUTS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_LAYOUTS_BUTTON_ACCESS_DESC" /> <action name="get_snippets.layouts" title="COM_COMPONENTBUILDER_GET_SNIPPETS_LAYOUTS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_LAYOUTS_BUTTON_ACCESS_DESC" />
<action name="get_snippets.libraries" title="COM_COMPONENTBUILDER_GET_SNIPPETS_LIBRARIES_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_LIBRARIES_BUTTON_ACCESS_DESC" />
<action name="get_snippets.site_views" title="COM_COMPONENTBUILDER_GET_SNIPPETS_SITE_VIEWS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_SITE_VIEWS_BUTTON_ACCESS_DESC" /> <action name="get_snippets.site_views" title="COM_COMPONENTBUILDER_GET_SNIPPETS_SITE_VIEWS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_SITE_VIEWS_BUTTON_ACCESS_DESC" />
<action name="get_snippets.snippets" title="COM_COMPONENTBUILDER_GET_SNIPPETS_SNIPPETS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_SNIPPETS_BUTTON_ACCESS_DESC" /> <action name="get_snippets.snippets" title="COM_COMPONENTBUILDER_GET_SNIPPETS_SNIPPETS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_SNIPPETS_BUTTON_ACCESS_DESC" />
<action name="get_snippets.templates" title="COM_COMPONENTBUILDER_GET_SNIPPETS_TEMPLATES_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_TEMPLATES_BUTTON_ACCESS_DESC" /> <action name="get_snippets.templates" title="COM_COMPONENTBUILDER_GET_SNIPPETS_TEMPLATES_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_GET_SNIPPETS_TEMPLATES_BUTTON_ACCESS_DESC" />
@ -297,12 +298,35 @@
<action name="layout.submenu" title="COM_COMPONENTBUILDER_LAYOUTS_SUBMENU" description="COM_COMPONENTBUILDER_LAYOUTS_SUBMENU_DESC" /> <action name="layout.submenu" title="COM_COMPONENTBUILDER_LAYOUTS_SUBMENU" description="COM_COMPONENTBUILDER_LAYOUTS_SUBMENU_DESC" />
<action name="library.access" title="COM_COMPONENTBUILDER_LIBRARIES_ACCESS" description="COM_COMPONENTBUILDER_LIBRARIES_ACCESS_DESC" /> <action name="library.access" title="COM_COMPONENTBUILDER_LIBRARIES_ACCESS" description="COM_COMPONENTBUILDER_LIBRARIES_ACCESS_DESC" />
<action name="library.batch" title="COM_COMPONENTBUILDER_LIBRARIES_BATCH_USE" description="COM_COMPONENTBUILDER_LIBRARIES_BATCH_USE_DESC" /> <action name="library.batch" title="COM_COMPONENTBUILDER_LIBRARIES_BATCH_USE" description="COM_COMPONENTBUILDER_LIBRARIES_BATCH_USE_DESC" />
<action name="library_config.access" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_ACCESS" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_ACCESS_DESC" />
<action name="library_config.batch" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_BATCH_USE" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_BATCH_USE_DESC" />
<action name="library_config.create" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_CREATE" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_CREATE_DESC" />
<action name="library_config.delete" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_DELETE" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_DELETE_DESC" />
<action name="library_config.edit" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_DESC" />
<action name="library_config.edit.created_by" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_CREATED_BY" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_CREATED_BY_DESC" />
<action name="library_config.edit.created" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_CREATED_DATE" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_CREATED_DATE_DESC" />
<action name="library_config.edit.own" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_OWN" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_OWN_DESC" />
<action name="library_config.edit.state" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_STATE" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_STATE_DESC" />
<action name="library_config.version" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_VERSION" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_VERSION_DESC" />
<action name="library.create" title="COM_COMPONENTBUILDER_LIBRARIES_CREATE" description="COM_COMPONENTBUILDER_LIBRARIES_CREATE_DESC" /> <action name="library.create" title="COM_COMPONENTBUILDER_LIBRARIES_CREATE" description="COM_COMPONENTBUILDER_LIBRARIES_CREATE_DESC" />
<action name="library.dashboard_list" title="COM_COMPONENTBUILDER_LIBRARIES_DASHBOARD_LIST" description="COM_COMPONENTBUILDER_LIBRARIES_DASHBOARD_LIST_DESC" />
<action name="library.delete" title="COM_COMPONENTBUILDER_LIBRARIES_DELETE" description="COM_COMPONENTBUILDER_LIBRARIES_DELETE_DESC" /> <action name="library.delete" title="COM_COMPONENTBUILDER_LIBRARIES_DELETE" description="COM_COMPONENTBUILDER_LIBRARIES_DELETE_DESC" />
<action name="library.edit" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_DESC" /> <action name="library.edit" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_DESC" />
<action name="library.edit.own" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_OWN" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_OWN_DESC" /> <action name="library.edit.own" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_OWN" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_OWN_DESC" />
<action name="library.edit.state" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_STATE" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_STATE_DESC" /> <action name="library.edit.state" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_STATE" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_STATE_DESC" />
<action name="library.version" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_VERSION" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_VERSION_DESC" /> <action name="library.version" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_VERSION" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_VERSION_DESC" />
<action name="library_files_folders_urls.access" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_ACCESS" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_ACCESS_DESC" />
<action name="library_files_folders_urls.batch" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_BATCH_USE" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_BATCH_USE_DESC" />
<action name="library_files_folders_urls.create" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_CREATE" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_CREATE_DESC" />
<action name="library_files_folders_urls.delete" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_DELETE" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_DELETE_DESC" />
<action name="library_files_folders_urls.edit" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_DESC" />
<action name="library_files_folders_urls.edit.created_by" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_CREATED_BY" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_CREATED_BY_DESC" />
<action name="library_files_folders_urls.edit.created" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_CREATED_DATE" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_CREATED_DATE_DESC" />
<action name="library_files_folders_urls.edit.own" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_OWN" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_OWN_DESC" />
<action name="library_files_folders_urls.edit.state" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_STATE" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_STATE_DESC" />
<action name="library_files_folders_urls.version" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_VERSION" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_VERSION_DESC" />
<action name="library.submenu" title="COM_COMPONENTBUILDER_LIBRARIES_SUBMENU" description="COM_COMPONENTBUILDER_LIBRARIES_SUBMENU_DESC" />
<action name="library.get_snippets" title="COM_COMPONENTBUILDER_LIBRARY_GET_SNIPPETS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_LIBRARY_GET_SNIPPETS_BUTTON_ACCESS_DESC" />
<action name="site_view.get_snippets" title="COM_COMPONENTBUILDER_SITE_VIEW_GET_SNIPPETS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_SITE_VIEW_GET_SNIPPETS_BUTTON_ACCESS_DESC" /> <action name="site_view.get_snippets" title="COM_COMPONENTBUILDER_SITE_VIEW_GET_SNIPPETS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_SITE_VIEW_GET_SNIPPETS_BUTTON_ACCESS_DESC" />
<action name="site_view.access" title="COM_COMPONENTBUILDER_SITE_VIEWS_ACCESS" description="COM_COMPONENTBUILDER_SITE_VIEWS_ACCESS_DESC" /> <action name="site_view.access" title="COM_COMPONENTBUILDER_SITE_VIEWS_ACCESS" description="COM_COMPONENTBUILDER_SITE_VIEWS_ACCESS_DESC" />
<action name="site_view.batch" title="COM_COMPONENTBUILDER_SITE_VIEWS_BATCH_USE" description="COM_COMPONENTBUILDER_SITE_VIEWS_BATCH_USE_DESC" /> <action name="site_view.batch" title="COM_COMPONENTBUILDER_SITE_VIEWS_BATCH_USE" description="COM_COMPONENTBUILDER_SITE_VIEWS_BATCH_USE_DESC" />
@ -418,6 +442,15 @@
<action name="custom_code.access" title="COM_COMPONENTBUILDER_CUSTOM_CODES_ACCESS" description="COM_COMPONENTBUILDER_CUSTOM_CODES_ACCESS_DESC" /> <action name="custom_code.access" title="COM_COMPONENTBUILDER_CUSTOM_CODES_ACCESS" description="COM_COMPONENTBUILDER_CUSTOM_CODES_ACCESS_DESC" />
<action name="custom_code.version" title="COM_COMPONENTBUILDER_CUSTOM_CODES_EDIT_VERSION" description="COM_COMPONENTBUILDER_CUSTOM_CODES_EDIT_VERSION_DESC" /> <action name="custom_code.version" title="COM_COMPONENTBUILDER_CUSTOM_CODES_EDIT_VERSION" description="COM_COMPONENTBUILDER_CUSTOM_CODES_EDIT_VERSION_DESC" />
</section> </section>
<section name="library">
<action name="library.edit" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_DESC" />
<action name="library.edit.own" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_OWN" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_OWN_DESC" />
<action name="library.edit.state" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_STATE" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_STATE_DESC" />
<action name="library.create" title="COM_COMPONENTBUILDER_LIBRARIES_CREATE" description="COM_COMPONENTBUILDER_LIBRARIES_CREATE_DESC" />
<action name="library.delete" title="COM_COMPONENTBUILDER_LIBRARIES_DELETE" description="COM_COMPONENTBUILDER_LIBRARIES_DELETE_DESC" />
<action name="library.access" title="COM_COMPONENTBUILDER_LIBRARIES_ACCESS" description="COM_COMPONENTBUILDER_LIBRARIES_ACCESS_DESC" />
<action name="library.version" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_VERSION" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_VERSION_DESC" />
</section>
<section name="snippet"> <section name="snippet">
<action name="core.edit" title="COM_COMPONENTBUILDER_SNIPPETS_EDIT" description="COM_COMPONENTBUILDER_SNIPPETS_EDIT_DESC" /> <action name="core.edit" title="COM_COMPONENTBUILDER_SNIPPETS_EDIT" description="COM_COMPONENTBUILDER_SNIPPETS_EDIT_DESC" />
<action name="core.edit.state" title="COM_COMPONENTBUILDER_SNIPPETS_EDIT_STATE" description="COM_COMPONENTBUILDER_SNIPPETS_EDIT_STATE_DESC" /> <action name="core.edit.state" title="COM_COMPONENTBUILDER_SNIPPETS_EDIT_STATE" description="COM_COMPONENTBUILDER_SNIPPETS_EDIT_STATE_DESC" />
@ -619,14 +652,27 @@
<action name="snippet_type.access" title="COM_COMPONENTBUILDER_SNIPPET_TYPES_ACCESS" description="COM_COMPONENTBUILDER_SNIPPET_TYPES_ACCESS_DESC" /> <action name="snippet_type.access" title="COM_COMPONENTBUILDER_SNIPPET_TYPES_ACCESS" description="COM_COMPONENTBUILDER_SNIPPET_TYPES_ACCESS_DESC" />
<action name="snippet_type.version" title="COM_COMPONENTBUILDER_SNIPPET_TYPES_EDIT_VERSION" description="COM_COMPONENTBUILDER_SNIPPET_TYPES_EDIT_VERSION_DESC" /> <action name="snippet_type.version" title="COM_COMPONENTBUILDER_SNIPPET_TYPES_EDIT_VERSION" description="COM_COMPONENTBUILDER_SNIPPET_TYPES_EDIT_VERSION_DESC" />
</section> </section>
<section name="library"> <section name="library_config">
<action name="library.edit" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_DESC" /> <action name="library_config.edit" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_DESC" />
<action name="library.edit.own" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_OWN" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_OWN_DESC" /> <action name="library_config.edit.own" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_OWN" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_OWN_DESC" />
<action name="library.edit.state" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_STATE" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_STATE_DESC" /> <action name="library_config.edit.state" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_STATE" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_STATE_DESC" />
<action name="library.create" title="COM_COMPONENTBUILDER_LIBRARIES_CREATE" description="COM_COMPONENTBUILDER_LIBRARIES_CREATE_DESC" /> <action name="library_config.edit.created_by" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_CREATED_BY" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_CREATED_BY_DESC" />
<action name="library.delete" title="COM_COMPONENTBUILDER_LIBRARIES_DELETE" description="COM_COMPONENTBUILDER_LIBRARIES_DELETE_DESC" /> <action name="library_config.edit.created" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_CREATED_DATE" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_CREATED_DATE_DESC" />
<action name="library.access" title="COM_COMPONENTBUILDER_LIBRARIES_ACCESS" description="COM_COMPONENTBUILDER_LIBRARIES_ACCESS_DESC" /> <action name="library_config.create" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_CREATE" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_CREATE_DESC" />
<action name="library.version" title="COM_COMPONENTBUILDER_LIBRARIES_EDIT_VERSION" description="COM_COMPONENTBUILDER_LIBRARIES_EDIT_VERSION_DESC" /> <action name="library_config.delete" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_DELETE" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_DELETE_DESC" />
<action name="library_config.access" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_ACCESS" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_ACCESS_DESC" />
<action name="library_config.version" title="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_VERSION" description="COM_COMPONENTBUILDER_LIBRARIES_CONFIG_EDIT_VERSION_DESC" />
</section>
<section name="library_files_folders_urls">
<action name="library_files_folders_urls.edit" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_DESC" />
<action name="library_files_folders_urls.edit.own" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_OWN" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_OWN_DESC" />
<action name="library_files_folders_urls.edit.state" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_STATE" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_STATE_DESC" />
<action name="library_files_folders_urls.edit.created_by" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_CREATED_BY" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_CREATED_BY_DESC" />
<action name="library_files_folders_urls.edit.created" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_CREATED_DATE" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_CREATED_DATE_DESC" />
<action name="library_files_folders_urls.create" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_CREATE" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_CREATE_DESC" />
<action name="library_files_folders_urls.delete" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_DELETE" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_DELETE_DESC" />
<action name="library_files_folders_urls.access" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_ACCESS" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_ACCESS_DESC" />
<action name="library_files_folders_urls.version" title="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_VERSION" description="COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS_EDIT_VERSION_DESC" />
</section> </section>
<section name="category.fields"> <section name="category.fields">
<action name="core.create" title="JACTION_CREATE" description="JACTION_CREATE_COMPONENT_DESC" /> <action name="core.create" title="JACTION_CREATE" description="JACTION_CREATE_COMPONENT_DESC" />

View File

@ -25,3 +25,21 @@
/* CSS Document */ /* CSS Document */
#jform_snippet_chzn {
width: 100% !important;
}
.jform_snippet_input_width {
width: 90% !important;
}
#jform_main_get_chzn {
width: 100% !important;
}
.jform_main_get_input_width {
width: 90% !important;
}
#jform_dynamic_get_chzn {
width: 100% !important;
}
.jform_dynamic_get_input_width {
width: 90% !important;
}

View File

@ -25,3 +25,15 @@
/* CSS Document */ /* CSS Document */
#jform_snippet_chzn {
width: 100% !important;
}
.jform_snippet_input_width {
width: 90% !important;
}
#jform_dynamic_get_chzn {
width: 100% !important;
}
.jform_dynamic_get_input_width {
width: 90% !important;
}

View File

@ -0,0 +1,27 @@
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
__ __ _ _____ _ _ __ __ _ _ _
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
| |
|_|
/-------------------------------------------------------------------------------------------------------------------------------/
@version 2.6.x
@created 30th April, 2015
@package Component Builder
@subpackage libraries_config.css
@author Llewellyn van der Merwe <http://vdm.bz/component-builder>
@github Joomla Component Builder <https://github.com/vdm-io/Joomla-Component-Builder>
@copyright Copyright (C) 2015. All Rights Reserved
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
Builds Complex Joomla Components
/-----------------------------------------------------------------------------------------------------------------------------*/
/* CSS Document */

View File

@ -0,0 +1,27 @@
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
__ __ _ _____ _ _ __ __ _ _ _
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
| |
|_|
/-------------------------------------------------------------------------------------------------------------------------------/
@version 2.6.x
@created 30th April, 2015
@package Component Builder
@subpackage libraries_files_folders_urls.css
@author Llewellyn van der Merwe <http://vdm.bz/component-builder>
@github Joomla Component Builder <https://github.com/vdm-io/Joomla-Component-Builder>
@copyright Copyright (C) 2015. All Rights Reserved
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
Builds Complex Joomla Components
/-----------------------------------------------------------------------------------------------------------------------------*/
/* CSS Document */

View File

@ -0,0 +1,27 @@
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
__ __ _ _____ _ _ __ __ _ _ _
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
| |
|_|
/-------------------------------------------------------------------------------------------------------------------------------/
@version 2.6.x
@created 30th April, 2015
@package Component Builder
@subpackage library_config.css
@author Llewellyn van der Merwe <http://vdm.bz/component-builder>
@github Joomla Component Builder <https://github.com/vdm-io/Joomla-Component-Builder>
@copyright Copyright (C) 2015. All Rights Reserved
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
Builds Complex Joomla Components
/-----------------------------------------------------------------------------------------------------------------------------*/
/* CSS Document */

View File

@ -0,0 +1,30 @@
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
__ __ _ _____ _ _ __ __ _ _ _
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
| |
|_|
/-------------------------------------------------------------------------------------------------------------------------------/
@version 2.6.x
@created 30th April, 2015
@package Component Builder
@subpackage library_files_folders_urls.css
@author Llewellyn van der Merwe <http://vdm.bz/component-builder>
@github Joomla Component Builder <https://github.com/vdm-io/Joomla-Component-Builder>
@copyright Copyright (C) 2015. All Rights Reserved
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
Builds Complex Joomla Components
/-----------------------------------------------------------------------------------------------------------------------------*/
/* CSS Document */
.control-group, .controls, .controls input[type="url"], .controls input[type="text"], .controls input[type="number"], .controls input[type="email"], .controls select, .controls textarea {
max-width: 100%;
}

View File

@ -25,3 +25,21 @@
/* CSS Document */ /* CSS Document */
#jform_snippet_chzn {
width: 100% !important;
}
.jform_snippet_input_width {
width: 90% !important;
}
#jform_main_get_chzn {
width: 100% !important;
}
.jform_main_get_input_width {
width: 90% !important;
}
#jform_dynamic_get_chzn {
width: 100% !important;
}
.jform_dynamic_get_input_width {
width: 90% !important;
}

View File

@ -25,3 +25,15 @@
/* CSS Document */ /* CSS Document */
#jform_snippet_chzn {
width: 100% !important;
}
.jform_snippet_input_width {
width: 90% !important;
}
#jform_dynamic_get_chzn {
width: 100% !important;
}
.jform_dynamic_get_input_width {
width: 90% !important;
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

View File

@ -650,6 +650,31 @@ abstract class ###Component###Helper
return false; return false;
} }
/**
* Check if we are connected
* Thanks https://stackoverflow.com/a/4860432/1429677
*
* @returns bool true on success
**/
public static function isConnected()
{
// If example.com is down, then probably the whole internet is down, since IANA maintains the domain. Right?
$connected = @fsockopen("www.example.com", 80);
// website, port (try 80 or 443)
if ($connected)
{
//action when connected
$is_conn = true;
fclose($connected);
}
else
{
//action in connection failure
$is_conn = false;
}
return $is_conn;
}
public static function mergeArrays($arrays) public static function mergeArrays($arrays)
{ {
if(self::checkArray($arrays)) if(self::checkArray($arrays))

View File

@ -645,6 +645,31 @@ abstract class ###Component###Helper
return false; return false;
} }
/**
* Check if we are connected
* Thanks https://stackoverflow.com/a/4860432/1429677
*
* @returns bool true on success
**/
public static function isConnected()
{
// If example.com is down, then probably the whole internet is down, since IANA maintains the domain. Right?
$connected = @fsockopen("www.example.com", 80);
// website, port (try 80 or 443)
if ($connected)
{
//action when connected
$is_conn = true;
fclose($connected);
}
else
{
//action in connection failure
$is_conn = false;
}
return $is_conn;
}
public static function mergeArrays($arrays) public static function mergeArrays($arrays)
{ {
if(self::checkArray($arrays)) if(self::checkArray($arrays))

View File

@ -82,7 +82,7 @@ class ###Component###Model###View### extends JModelAdmin
{###LICENSE_LOCKED_CHECK### {###LICENSE_LOCKED_CHECK###
if ($item = parent::getItem($pk)) if ($item = parent::getItem($pk))
{ {
if (!empty($item->params)) if (!empty($item->params) && !is_array($item->params))
{ {
// Convert the params field to an array. // Convert the params field to an array.
$registry = new Registry; $registry = new Registry;

View File

@ -54,7 +54,7 @@ class ###Component###View###SView### extends JViewLegacy
* Prepares the document * Prepares the document
*/ */
protected function setDocument() protected function setDocument()
{###CUSTOM_ADMIN_DOCUMENT_METADATA### ###CUSTOM_ADMIN_UIKIT_LOADER### ###CUSTOM_ADMIN_GOOGLECHART_LOADER### ###CUSTOM_ADMIN_FOOTABLE_LOADER### ###CUSTOM_ADMIN_DOCUMENT_CUSTOM_PHP### {###CUSTOM_ADMIN_LIBRARIES_LOADER### ###CUSTOM_ADMIN_DOCUMENT_METADATA### ###CUSTOM_ADMIN_UIKIT_LOADER### ###CUSTOM_ADMIN_GOOGLECHART_LOADER### ###CUSTOM_ADMIN_FOOTABLE_LOADER### ###CUSTOM_ADMIN_DOCUMENT_CUSTOM_PHP###
// add the document default css file // add the document default css file
$this->document->addStyleSheet(JURI::root(true) .'/administrator/components/com_###component###/assets/css/###sview###.css');###CUSTOM_ADMIN_DOCUMENT_CUSTOM_CSS### ###CUSTOM_ADMIN_DOCUMENT_CUSTOM_JS### $this->document->addStyleSheet(JURI::root(true) .'/administrator/components/com_###component###/assets/css/###sview###.css');###CUSTOM_ADMIN_DOCUMENT_CUSTOM_CSS### ###CUSTOM_ADMIN_DOCUMENT_CUSTOM_JS###
} }

View File

@ -117,11 +117,14 @@ class ###Component###View###View### extends JViewLegacy
protected function setDocument() protected function setDocument()
{ {
$isNew = ($this->item->id < 1); $isNew = ($this->item->id < 1);
$document = JFactory::getDocument(); if (!isset($this->document))
$document->setTitle(JText::_($isNew ? 'COM_###COMPONENT###_###VIEW###_NEW' : 'COM_###COMPONENT###_###VIEW###_EDIT')); {
$document->addStyleSheet(JURI::root() . "administrator/components/com_###component###/assets/css/###view###.css");###AJAXTOKE### ###LINKEDVIEWTABLESCRIPTS### $this->document = JFactory::getDocument();
$document->addScript(JURI::root() . $this->script); }
$document->addScript(JURI::root() . "administrator/components/com_###component###/views/###view###/submitbutton.js"); ###DOCUMENT_CUSTOM_PHP### $this->document->setTitle(JText::_($isNew ? 'COM_###COMPONENT###_###VIEW###_NEW' : 'COM_###COMPONENT###_###VIEW###_EDIT'));
$this->document->addStyleSheet(JURI::root() . "administrator/components/com_###component###/assets/css/###view###.css");###AJAXTOKE### ###LINKEDVIEWTABLESCRIPTS###
$this->document->addScript(JURI::root() . $this->script);
$this->document->addScript(JURI::root() . "administrator/components/com_###component###/views/###view###/submitbutton.js"); ###DOCUMENT_CUSTOM_PHP###
JText::script('view not acceptable. Error'); JText::script('view not acceptable. Error');
} }
} }

View File

@ -121,16 +121,19 @@ class ###Component###View###View### extends JViewLegacy
protected function setDocument() protected function setDocument()
{ {
$isNew = ($this->item->id < 1); $isNew = ($this->item->id < 1);
$document = JFactory::getDocument(); if (!isset($this->document))
$document->setTitle(JText::_($isNew ? 'COM_###COMPONENT###_###VIEW###_NEW' : 'COM_###COMPONENT###_###VIEW###_EDIT')); {
$this->document = JFactory::getDocument();
}
$this->document->setTitle(JText::_($isNew ? 'COM_###COMPONENT###_###VIEW###_NEW' : 'COM_###COMPONENT###_###VIEW###_EDIT'));
// we need this to fix the form display // we need this to fix the form display
$document->addStyleSheet(JURI::root()."administrator/templates/isis/css/template.css"); $this->document->addStyleSheet(JURI::root()."administrator/templates/isis/css/template.css");
$document->addScript(JURI::root()."administrator/templates/isis/js/template.js"); $this->document->addScript(JURI::root()."administrator/templates/isis/js/template.js");
// the default style of this view // the default style of this view
$document->addStyleSheet(JURI::root()."components/com_###component###/assets/css/###view###.css");###AJAXTOKE### ###LINKEDVIEWTABLESCRIPTS### $this->document->addStyleSheet(JURI::root()."components/com_###component###/assets/css/###view###.css");###AJAXTOKE### ###LINKEDVIEWTABLESCRIPTS###
// default javascript of this view // default javascript of this view
$document->addScript(JURI::root().$this->script); $this->document->addScript(JURI::root().$this->script);
$document->addScript(JURI::root(). "components/com_###component###/views/###view###/submitbutton.js"); ###DOCUMENT_CUSTOM_PHP### $this->document->addScript(JURI::root(). "components/com_###component###/views/###view###/submitbutton.js"); ###DOCUMENT_CUSTOM_PHP###
JText::script('view not acceptable. Error'); JText::script('view not acceptable. Error');
} }
} }

View File

@ -197,9 +197,12 @@ class ###Component###View###Views### extends JViewLegacy
*/ */
protected function setDocument() protected function setDocument()
{ {
$document = JFactory::getDocument(); if (!isset($this->document))
$document->setTitle(JText::_('COM_###COMPONENT###_###VIEWS###')); {
$document->addStyleSheet(JURI::root() . "administrator/components/com_###component###/assets/css/###views###.css"); $this->document = JFactory::getDocument();
}
$this->document->setTitle(JText::_('COM_###COMPONENT###_###VIEWS###'));
$this->document->addStyleSheet(JURI::root() . "administrator/components/com_###component###/assets/css/###views###.css");
} }
/** /**

View File

@ -54,7 +54,7 @@ class ###Component###View###SViews### extends JViewLegacy
* Prepares the document * Prepares the document
*/ */
protected function setDocument() protected function setDocument()
{###CUSTOM_ADMIN_UIKIT_LOADER### ###CUSTOM_ADMIN_GOOGLECHART_LOADER### ###CUSTOM_ADMIN_FOOTABLE_LOADER### ###CUSTOM_ADMIN_DOCUMENT_CUSTOM_PHP### {###CUSTOM_ADMIN_LIBRARIES_LOADER### ###CUSTOM_ADMIN_UIKIT_LOADER### ###CUSTOM_ADMIN_GOOGLECHART_LOADER### ###CUSTOM_ADMIN_FOOTABLE_LOADER### ###CUSTOM_ADMIN_DOCUMENT_CUSTOM_PHP###
// add the document default css file // add the document default css file
$this->document->addStyleSheet(JURI::root(true) .'/administrator/components/com_###component###/assets/css/###sviews###.css');###CUSTOM_ADMIN_DOCUMENT_CUSTOM_CSS### ###CUSTOM_ADMIN_DOCUMENT_CUSTOM_JS### $this->document->addStyleSheet(JURI::root(true) .'/administrator/components/com_###component###/assets/css/###sviews###.css');###CUSTOM_ADMIN_DOCUMENT_CUSTOM_CSS### ###CUSTOM_ADMIN_DOCUMENT_CUSTOM_JS###
} }

View File

@ -52,7 +52,7 @@ class ###Component###View###SViews### extends JViewLegacy
* Prepares the document * Prepares the document
*/ */
protected function _prepareDocument() protected function _prepareDocument()
{###SITE_UIKIT_LOADER### ###SITE_GOOGLECHART_LOADER### ###SITE_FOOTABLE_LOADER### ###SITE_DOCUMENT_METADATA### ###SITE_DOCUMENT_CUSTOM_PHP### {###SITE_LIBRARIES_LOADER### ###SITE_UIKIT_LOADER### ###SITE_GOOGLECHART_LOADER### ###SITE_FOOTABLE_LOADER### ###SITE_DOCUMENT_METADATA### ###SITE_DOCUMENT_CUSTOM_PHP###
// add the document default css file // add the document default css file
$this->document->addStyleSheet(JURI::root(true) .'/components/com_###component###/assets/css/###sview###.css');###SITE_DOCUMENT_CUSTOM_CSS### ###SITE_DOCUMENT_CUSTOM_JS### $this->document->addStyleSheet(JURI::root(true) .'/components/com_###component###/assets/css/###sview###.css');###SITE_DOCUMENT_CUSTOM_CSS### ###SITE_DOCUMENT_CUSTOM_JS###
} }

View File

@ -52,7 +52,7 @@ class ###Component###View###SView### extends JViewLegacy
* Prepares the document * Prepares the document
*/ */
protected function _prepareDocument() protected function _prepareDocument()
{###SITE_UIKIT_LOADER### ###SITE_GOOGLECHART_LOADER### ###SITE_FOOTABLE_LOADER### ###SITE_DOCUMENT_METADATA### ###SITE_DOCUMENT_CUSTOM_PHP### {###SITE_LIBRARIES_LOADER### ###SITE_UIKIT_LOADER### ###SITE_GOOGLECHART_LOADER### ###SITE_FOOTABLE_LOADER### ###SITE_DOCUMENT_METADATA### ###SITE_DOCUMENT_CUSTOM_PHP###
// add the document default css file // add the document default css file
$this->document->addStyleSheet(JURI::root(true) .'/components/com_###component###/assets/css/###sview###.css');###SITE_DOCUMENT_CUSTOM_CSS### ###SITE_DOCUMENT_CUSTOM_JS### $this->document->addStyleSheet(JURI::root(true) .'/components/com_###component###/assets/css/###sview###.css');###SITE_DOCUMENT_CUSTOM_CSS### ###SITE_DOCUMENT_CUSTOM_JS###
} }

View File

@ -48,22 +48,18 @@
<field type="spacer" name="spacerHistory" hr="true" /> <field type="spacer" name="spacerHistory" hr="true" />
<!-- Minify Field. Type: Radio. (joomla) --> <!-- Minify Field. Type: Radio. (joomla) -->
<field <field type="radio"
type="radio"
name="minify" name="minify"
label="COM_COMPONENTBUILDER_CONFIG_MINIFY_LABEL" label="COM_COMPONENTBUILDER_CONFIG_MINIFY_LABEL"
description="COM_COMPONENTBUILDER_CONFIG_MINIFY_DESCRIPTION" description="COM_COMPONENTBUILDER_CONFIG_MINIFY_DESCRIPTION"
class="btn-group btn-group-yesno" class="btn-group btn-group-yesno"
default="0"> default="0">
<!-- Option Set. --> <!-- Option Set.-->
<option value="1"> <option value="1">COM_COMPONENTBUILDER_CONFIG_YES</option>
COM_COMPONENTBUILDER_CONFIG_YES</option> <option value="0">COM_COMPONENTBUILDER_CONFIG_NO</option>
<option value="0">
COM_COMPONENTBUILDER_CONFIG_NO</option>
</field> </field>
<!-- Percentagelanguageadd Field. Type: Number. (joomla) --> <!-- Percentagelanguageadd Field. Type: Number. (joomla) -->
<field <field type="number"
type="number"
name="percentagelanguageadd" name="percentagelanguageadd"
label="COM_COMPONENTBUILDER_CONFIG_PERCENTAGELANGUAGEADD_LABEL" label="COM_COMPONENTBUILDER_CONFIG_PERCENTAGELANGUAGEADD_LABEL"
default="50" default="50"
@ -72,35 +68,31 @@
required="true" required="true"
min="10" min="10"
max="100" max="100"
step="10" step="10" />
/>
<!-- Spacer_hr_a Field. Type: Spacer. A None Database Field. (joomla) --> <!-- Spacer_hr_a Field. Type: Spacer. A None Database Field. (joomla) -->
<field type="spacer" name="spacer_hr_a" hr="true" class="spacer_hr_a" /> <field type="spacer"
name="spacer_hr_a"
hr="true"
class="spacer_hr_a" />
<!-- Api Field. Type: User. (joomla) --> <!-- Api Field. Type: User. (joomla) -->
<field <field type="user"
type="user"
name="api" name="api"
label="COM_COMPONENTBUILDER_CONFIG_API_LABEL" label="COM_COMPONENTBUILDER_CONFIG_API_LABEL"
description="COM_COMPONENTBUILDER_CONFIG_API_DESCRIPTION" description="COM_COMPONENTBUILDER_CONFIG_API_DESCRIPTION" />
/>
<!-- Set_browser_storage Field. Type: Radio. (joomla) --> <!-- Set_browser_storage Field. Type: Radio. (joomla) -->
<field <field type="radio"
type="radio"
name="set_browser_storage" name="set_browser_storage"
label="COM_COMPONENTBUILDER_CONFIG_SET_BROWSER_STORAGE_LABEL" label="COM_COMPONENTBUILDER_CONFIG_SET_BROWSER_STORAGE_LABEL"
description="COM_COMPONENTBUILDER_CONFIG_SET_BROWSER_STORAGE_DESCRIPTION" description="COM_COMPONENTBUILDER_CONFIG_SET_BROWSER_STORAGE_DESCRIPTION"
class="btn-group btn-group-yesno" class="btn-group btn-group-yesno"
default="1" default="1"
required="true"> required="true">
<!-- Option Set. --> <!-- Option Set.-->
<option value="1"> <option value="1">COM_COMPONENTBUILDER_CONFIG_ACTIVE</option>
COM_COMPONENTBUILDER_CONFIG_ACTIVE</option> <option value="0">COM_COMPONENTBUILDER_CONFIG_INACTIVE</option>
<option value="0">
COM_COMPONENTBUILDER_CONFIG_INACTIVE</option>
</field> </field>
<!-- Storage_time_to_live Field. Type: List. (joomla) --> <!-- Storage_time_to_live Field. Type: List. (joomla) -->
<field <field type="list"
type="list"
name="storage_time_to_live" name="storage_time_to_live"
label="COM_COMPONENTBUILDER_CONFIG_STORAGE_TIME_TO_LIVE_LABEL" label="COM_COMPONENTBUILDER_CONFIG_STORAGE_TIME_TO_LIVE_LABEL"
description="COM_COMPONENTBUILDER_CONFIG_STORAGE_TIME_TO_LIVE_DESCRIPTION" description="COM_COMPONENTBUILDER_CONFIG_STORAGE_TIME_TO_LIVE_DESCRIPTION"
@ -108,34 +100,25 @@
multiple="false" multiple="false"
default="global" default="global"
showon="set_browser_storage:1"> showon="set_browser_storage:1">
<!-- Option Set. --> <!-- Option Set.-->
<option value="global"> <option value="global">COM_COMPONENTBUILDER_CONFIG_EVERY_SESSION</option>
COM_COMPONENTBUILDER_CONFIG_EVERY_SESSION</option> <option value="30">COM_COMPONENTBUILDER_CONFIG_EVERY_THIRTY_SECONDS</option>
<option value="30"> <option value="60">COM_COMPONENTBUILDER_CONFIG_EVERY_MINUTE</option>
COM_COMPONENTBUILDER_CONFIG_EVERY_THIRTY_SECONDS</option> <option value="300">COM_COMPONENTBUILDER_CONFIG_EVERY_FIVE_MINUTES</option>
<option value="60"> <option value="900">COM_COMPONENTBUILDER_CONFIG_EVERY_FIFTEEN_MINUTES</option>
COM_COMPONENTBUILDER_CONFIG_EVERY_MINUTE</option> <option value="1800">COM_COMPONENTBUILDER_CONFIG_EVERY_THIRTY_MINUTES</option>
<option value="300"> <option value="3600">COM_COMPONENTBUILDER_CONFIG_EVERY_HOUR</option>
COM_COMPONENTBUILDER_CONFIG_EVERY_FIVE_MINUTES</option> <option value="18000">COM_COMPONENTBUILDER_CONFIG_EVERY_FIVE_HOURS</option>
<option value="900"> <option value="36000">COM_COMPONENTBUILDER_CONFIG_EVERY_TEN_HOURS</option>
COM_COMPONENTBUILDER_CONFIG_EVERY_FIFTEEN_MINUTES</option> <option value="86400">COM_COMPONENTBUILDER_CONFIG_EVERY_DAY</option>
<option value="1800"> <option value="604800">COM_COMPONENTBUILDER_CONFIG_EVERY_WEEK</option>
COM_COMPONENTBUILDER_CONFIG_EVERY_THIRTY_MINUTES</option> <option value="0">COM_COMPONENTBUILDER_CONFIG_NEVER_UPDATE</option>
<option value="3600">
COM_COMPONENTBUILDER_CONFIG_EVERY_HOUR</option>
<option value="18000">
COM_COMPONENTBUILDER_CONFIG_EVERY_FIVE_HOURS</option>
<option value="36000">
COM_COMPONENTBUILDER_CONFIG_EVERY_TEN_HOURS</option>
<option value="86400">
COM_COMPONENTBUILDER_CONFIG_EVERY_DAY</option>
<option value="604800">
COM_COMPONENTBUILDER_CONFIG_EVERY_WEEK</option>
<option value="0">
COM_COMPONENTBUILDER_CONFIG_NEVER_UPDATE</option>
</field> </field>
<!-- Spacer_hr_b Field. Type: Spacer. A None Database Field. (joomla) --> <!-- Spacer_hr_b Field. Type: Spacer. A None Database Field. (joomla) -->
<field type="spacer" name="spacer_hr_b" hr="true" class="spacer_hr_b" /> <field type="spacer"
name="spacer_hr_b"
hr="true"
class="spacer_hr_b" />
<field name="autorTitle" <field name="autorTitle"
type="spacer" type="spacer"
label="COM_COMPONENTBUILDER_CONFIG_AUTHOR" label="COM_COMPONENTBUILDER_CONFIG_AUTHOR"
@ -558,10 +541,14 @@
label="COM_COMPONENTBUILDER_CONFIG_CRONJOB"> label="COM_COMPONENTBUILDER_CONFIG_CRONJOB">
<!-- Backupcronjob_note Field. Type: Note. A None Database Field. (joomla) --> <!-- Backupcronjob_note Field. Type: Note. A None Database Field. (joomla) -->
<field type="note" name="backupcronjob_note" label="COM_COMPONENTBUILDER_CONFIG_BACKUPCRONJOB_NOTE_LABEL" description="COM_COMPONENTBUILDER_CONFIG_BACKUPCRONJOB_NOTE_DESCRIPTION" heading="h4" class="backupcronjob_note" /> <field type="note"
name="backupcronjob_note"
label="COM_COMPONENTBUILDER_CONFIG_BACKUPCRONJOB_NOTE_LABEL"
description="COM_COMPONENTBUILDER_CONFIG_BACKUPCRONJOB_NOTE_DESCRIPTION"
heading="h4"
class="backupcronjob_note" />
<!-- Cronjob_backup_folder_path Field. Type: Text. (joomla) --> <!-- Cronjob_backup_folder_path Field. Type: Text. (joomla) -->
<field <field type="text"
type="text"
name="cronjob_backup_folder_path" name="cronjob_backup_folder_path"
label="COM_COMPONENTBUILDER_CONFIG_CRONJOB_BACKUP_FOLDER_PATH_LABEL" label="COM_COMPONENTBUILDER_CONFIG_CRONJOB_BACKUP_FOLDER_PATH_LABEL"
size="70" size="70"
@ -573,11 +560,9 @@
required="false" required="false"
filter="PATH" filter="PATH"
message="COM_COMPONENTBUILDER_CONFIG_CRONJOB_BACKUP_FOLDER_PATH_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_CRONJOB_BACKUP_FOLDER_PATH_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_CRONJOB_BACKUP_FOLDER_PATH_HINT" hint="COM_COMPONENTBUILDER_CONFIG_CRONJOB_BACKUP_FOLDER_PATH_HINT" />
/>
<!-- Backup_email Field. Type: Text. (joomla) --> <!-- Backup_email Field. Type: Text. (joomla) -->
<field <field type="text"
type="text"
name="backup_email" name="backup_email"
label="COM_COMPONENTBUILDER_CONFIG_BACKUP_EMAIL_LABEL" label="COM_COMPONENTBUILDER_CONFIG_BACKUP_EMAIL_LABEL"
size="10" size="10"
@ -587,13 +572,16 @@
filter="STRING" filter="STRING"
validate="email" validate="email"
message="COM_COMPONENTBUILDER_CONFIG_BACKUP_EMAIL_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_BACKUP_EMAIL_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_BACKUP_EMAIL_HINT" hint="COM_COMPONENTBUILDER_CONFIG_BACKUP_EMAIL_HINT" />
/>
<!-- Package_name_plaeholders Field. Type: Note. A None Database Field. (joomla) --> <!-- Package_name_plaeholders Field. Type: Note. A None Database Field. (joomla) -->
<field type="note" name="package_name_plaeholders" label="COM_COMPONENTBUILDER_CONFIG_PACKAGE_NAME_PLAEHOLDERS_LABEL" description="COM_COMPONENTBUILDER_CONFIG_PACKAGE_NAME_PLAEHOLDERS_DESCRIPTION" heading="h4" class="package_name_plaeholders" /> <field type="note"
name="package_name_plaeholders"
label="COM_COMPONENTBUILDER_CONFIG_PACKAGE_NAME_PLAEHOLDERS_LABEL"
description="COM_COMPONENTBUILDER_CONFIG_PACKAGE_NAME_PLAEHOLDERS_DESCRIPTION"
heading="h4"
class="package_name_plaeholders" />
<!-- Backup_package_name Field. Type: Text. (joomla) --> <!-- Backup_package_name Field. Type: Text. (joomla) -->
<field <field type="text"
type="text"
name="backup_package_name" name="backup_package_name"
label="COM_COMPONENTBUILDER_CONFIG_BACKUP_PACKAGE_NAME_LABEL" label="COM_COMPONENTBUILDER_CONFIG_BACKUP_PACKAGE_NAME_LABEL"
size="40" size="40"
@ -606,18 +594,21 @@
required="true" required="true"
filter="STRING" filter="STRING"
message="COM_COMPONENTBUILDER_CONFIG_BACKUP_PACKAGE_NAME_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_BACKUP_PACKAGE_NAME_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_BACKUP_PACKAGE_NAME_HINT" hint="COM_COMPONENTBUILDER_CONFIG_BACKUP_PACKAGE_NAME_HINT" />
/>
</fieldset> </fieldset>
<fieldset <fieldset
name="folder_paths_custom_config" name="folder_paths_custom_config"
label="COM_COMPONENTBUILDER_CONFIG_FOLDER_PATHS"> label="COM_COMPONENTBUILDER_CONFIG_FOLDER_PATHS">
<!-- Note_compiler_folder_path Field. Type: Note. A None Database Field. (joomla) --> <!-- Note_compiler_folder_path Field. Type: Note. A None Database Field. (joomla) -->
<field type="note" name="note_compiler_folder_path" label="COM_COMPONENTBUILDER_CONFIG_NOTE_COMPILER_FOLDER_PATH_LABEL" description="COM_COMPONENTBUILDER_CONFIG_NOTE_COMPILER_FOLDER_PATH_DESCRIPTION" heading="h4" class="alert alert-info note_compiler_folder_path" /> <field type="note"
name="note_compiler_folder_path"
label="COM_COMPONENTBUILDER_CONFIG_NOTE_COMPILER_FOLDER_PATH_LABEL"
description="COM_COMPONENTBUILDER_CONFIG_NOTE_COMPILER_FOLDER_PATH_DESCRIPTION"
heading="h4"
class="alert alert-info note_compiler_folder_path" />
<!-- Compiler_folder_path Field. Type: Text. (joomla) --> <!-- Compiler_folder_path Field. Type: Text. (joomla) -->
<field <field type="text"
type="text"
name="compiler_folder_path" name="compiler_folder_path"
label="COM_COMPONENTBUILDER_CONFIG_COMPILER_FOLDER_PATH_LABEL" label="COM_COMPONENTBUILDER_CONFIG_COMPILER_FOLDER_PATH_LABEL"
size="70" size="70"
@ -629,13 +620,16 @@
required="false" required="false"
filter="PATH" filter="PATH"
message="COM_COMPONENTBUILDER_CONFIG_COMPILER_FOLDER_PATH_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_COMPILER_FOLDER_PATH_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_COMPILER_FOLDER_PATH_HINT" hint="COM_COMPONENTBUILDER_CONFIG_COMPILER_FOLDER_PATH_HINT" />
/>
<!-- Note_custom_folder_path Field. Type: Note. A None Database Field. (joomla) --> <!-- Note_custom_folder_path Field. Type: Note. A None Database Field. (joomla) -->
<field type="note" name="note_custom_folder_path" label="COM_COMPONENTBUILDER_CONFIG_NOTE_CUSTOM_FOLDER_PATH_LABEL" description="COM_COMPONENTBUILDER_CONFIG_NOTE_CUSTOM_FOLDER_PATH_DESCRIPTION" heading="h4" class="alert alert-info note_custom_folder_path" /> <field type="note"
name="note_custom_folder_path"
label="COM_COMPONENTBUILDER_CONFIG_NOTE_CUSTOM_FOLDER_PATH_LABEL"
description="COM_COMPONENTBUILDER_CONFIG_NOTE_CUSTOM_FOLDER_PATH_DESCRIPTION"
heading="h4"
class="alert alert-info note_custom_folder_path" />
<!-- Custom_folder_path Field. Type: Text. (joomla) --> <!-- Custom_folder_path Field. Type: Text. (joomla) -->
<field <field type="text"
type="text"
name="custom_folder_path" name="custom_folder_path"
label="COM_COMPONENTBUILDER_CONFIG_CUSTOM_FOLDER_PATH_LABEL" label="COM_COMPONENTBUILDER_CONFIG_CUSTOM_FOLDER_PATH_LABEL"
size="70" size="70"
@ -647,13 +641,16 @@
required="false" required="false"
filter="PATH" filter="PATH"
message="COM_COMPONENTBUILDER_CONFIG_CUSTOM_FOLDER_PATH_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_CUSTOM_FOLDER_PATH_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_CUSTOM_FOLDER_PATH_HINT" hint="COM_COMPONENTBUILDER_CONFIG_CUSTOM_FOLDER_PATH_HINT" />
/>
<!-- Note_backup_folder_path Field. Type: Note. A None Database Field. (joomla) --> <!-- Note_backup_folder_path Field. Type: Note. A None Database Field. (joomla) -->
<field type="note" name="note_backup_folder_path" label="COM_COMPONENTBUILDER_CONFIG_NOTE_BACKUP_FOLDER_PATH_LABEL" description="COM_COMPONENTBUILDER_CONFIG_NOTE_BACKUP_FOLDER_PATH_DESCRIPTION" heading="h4" class="alert alert-info note_backup_folder_path" /> <field type="note"
name="note_backup_folder_path"
label="COM_COMPONENTBUILDER_CONFIG_NOTE_BACKUP_FOLDER_PATH_LABEL"
description="COM_COMPONENTBUILDER_CONFIG_NOTE_BACKUP_FOLDER_PATH_DESCRIPTION"
heading="h4"
class="alert alert-info note_backup_folder_path" />
<!-- Backup_folder_path Field. Type: Text. (joomla) --> <!-- Backup_folder_path Field. Type: Text. (joomla) -->
<field <field type="text"
type="text"
name="backup_folder_path" name="backup_folder_path"
label="COM_COMPONENTBUILDER_CONFIG_BACKUP_FOLDER_PATH_LABEL" label="COM_COMPONENTBUILDER_CONFIG_BACKUP_FOLDER_PATH_LABEL"
size="70" size="70"
@ -665,13 +662,16 @@
required="false" required="false"
filter="PATH" filter="PATH"
message="COM_COMPONENTBUILDER_CONFIG_BACKUP_FOLDER_PATH_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_BACKUP_FOLDER_PATH_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_BACKUP_FOLDER_PATH_HINT" hint="COM_COMPONENTBUILDER_CONFIG_BACKUP_FOLDER_PATH_HINT" />
/>
<!-- Note_git_folder_path Field. Type: Note. A None Database Field. (joomla) --> <!-- Note_git_folder_path Field. Type: Note. A None Database Field. (joomla) -->
<field type="note" name="note_git_folder_path" label="COM_COMPONENTBUILDER_CONFIG_NOTE_GIT_FOLDER_PATH_LABEL" description="COM_COMPONENTBUILDER_CONFIG_NOTE_GIT_FOLDER_PATH_DESCRIPTION" heading="h4" class="alert alert-info note_git_folder_path" /> <field type="note"
name="note_git_folder_path"
label="COM_COMPONENTBUILDER_CONFIG_NOTE_GIT_FOLDER_PATH_LABEL"
description="COM_COMPONENTBUILDER_CONFIG_NOTE_GIT_FOLDER_PATH_DESCRIPTION"
heading="h4"
class="alert alert-info note_git_folder_path" />
<!-- Git_folder_path Field. Type: Text. (joomla) --> <!-- Git_folder_path Field. Type: Text. (joomla) -->
<field <field type="text"
type="text"
name="git_folder_path" name="git_folder_path"
label="COM_COMPONENTBUILDER_CONFIG_GIT_FOLDER_PATH_LABEL" label="COM_COMPONENTBUILDER_CONFIG_GIT_FOLDER_PATH_LABEL"
size="70" size="70"
@ -683,16 +683,14 @@
required="false" required="false"
filter="PATH" filter="PATH"
message="COM_COMPONENTBUILDER_CONFIG_GIT_FOLDER_PATH_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_GIT_FOLDER_PATH_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_GIT_FOLDER_PATH_HINT" hint="COM_COMPONENTBUILDER_CONFIG_GIT_FOLDER_PATH_HINT" />
/>
</fieldset> </fieldset>
<fieldset <fieldset
name="company_custom_config" name="company_custom_config"
label="COM_COMPONENTBUILDER_CONFIG_COMPANY"> label="COM_COMPONENTBUILDER_CONFIG_COMPANY">
<!-- Export_company Field. Type: Text. (joomla) --> <!-- Export_company Field. Type: Text. (joomla) -->
<field <field type="text"
type="text"
name="export_company" name="export_company"
label="COM_COMPONENTBUILDER_CONFIG_EXPORT_COMPANY_LABEL" label="COM_COMPONENTBUILDER_CONFIG_EXPORT_COMPANY_LABEL"
size="40" size="40"
@ -704,11 +702,9 @@
required="true" required="true"
filter="STRING" filter="STRING"
message="COM_COMPONENTBUILDER_CONFIG_EXPORT_COMPANY_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_EXPORT_COMPANY_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_COMPANY_HINT" hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_COMPANY_HINT" />
/>
<!-- Export_owner Field. Type: Text. (joomla) --> <!-- Export_owner Field. Type: Text. (joomla) -->
<field <field type="text"
type="text"
name="export_owner" name="export_owner"
label="COM_COMPONENTBUILDER_CONFIG_EXPORT_OWNER_LABEL" label="COM_COMPONENTBUILDER_CONFIG_EXPORT_OWNER_LABEL"
size="10" size="10"
@ -720,11 +716,9 @@
required="true" required="true"
filter="HTML" filter="HTML"
message="COM_COMPONENTBUILDER_CONFIG_EXPORT_OWNER_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_EXPORT_OWNER_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_OWNER_HINT" hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_OWNER_HINT" />
/>
<!-- Export_email Field. Type: Text. (joomla) --> <!-- Export_email Field. Type: Text. (joomla) -->
<field <field type="text"
type="text"
name="export_email" name="export_email"
label="COM_COMPONENTBUILDER_CONFIG_EXPORT_EMAIL_LABEL" label="COM_COMPONENTBUILDER_CONFIG_EXPORT_EMAIL_LABEL"
size="40" size="40"
@ -735,11 +729,9 @@
filter="STRING" filter="STRING"
validate="email" validate="email"
message="COM_COMPONENTBUILDER_CONFIG_EXPORT_EMAIL_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_EXPORT_EMAIL_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_EMAIL_HINT" hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_EMAIL_HINT" />
/>
<!-- Export_website Field. Type: Url. (joomla) --> <!-- Export_website Field. Type: Url. (joomla) -->
<field <field type="url"
type="url"
name="export_website" name="export_website"
label="COM_COMPONENTBUILDER_CONFIG_EXPORT_WEBSITE_LABEL" label="COM_COMPONENTBUILDER_CONFIG_EXPORT_WEBSITE_LABEL"
size="60" size="60"
@ -750,11 +742,9 @@
filter="url" filter="url"
validated="url" validated="url"
message="COM_COMPONENTBUILDER_CONFIG_EXPORT_WEBSITE_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_EXPORT_WEBSITE_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_WEBSITE_HINT" hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_WEBSITE_HINT" />
/>
<!-- Export_license Field. Type: Textarea. (joomla) --> <!-- Export_license Field. Type: Textarea. (joomla) -->
<field <field type="textarea"
type="textarea"
name="export_license" name="export_license"
label="COM_COMPONENTBUILDER_CONFIG_EXPORT_LICENSE_LABEL" label="COM_COMPONENTBUILDER_CONFIG_EXPORT_LICENSE_LABEL"
rows="7" rows="7"
@ -764,11 +754,9 @@
class="text_area span12" class="text_area span12"
filter="HTML" filter="HTML"
hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_LICENSE_HINT" hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_LICENSE_HINT"
required="true" required="true" />
/>
<!-- Export_copyright Field. Type: Textarea. (joomla) --> <!-- Export_copyright Field. Type: Textarea. (joomla) -->
<field <field type="textarea"
type="textarea"
name="export_copyright" name="export_copyright"
label="COM_COMPONENTBUILDER_CONFIG_EXPORT_COPYRIGHT_LABEL" label="COM_COMPONENTBUILDER_CONFIG_EXPORT_COPYRIGHT_LABEL"
rows="7" rows="7"
@ -778,11 +766,9 @@
class="text_area span12" class="text_area span12"
filter="HTML" filter="HTML"
hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_COPYRIGHT_HINT" hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_COPYRIGHT_HINT"
required="true" required="true" />
/>
<!-- Export_buy_link Field. Type: Url. (joomla) --> <!-- Export_buy_link Field. Type: Url. (joomla) -->
<field <field type="url"
type="url"
name="export_buy_link" name="export_buy_link"
label="COM_COMPONENTBUILDER_CONFIG_EXPORT_BUY_LINK_LABEL" label="COM_COMPONENTBUILDER_CONFIG_EXPORT_BUY_LINK_LABEL"
size="60" size="60"
@ -793,8 +779,7 @@
filter="url" filter="url"
validated="url" validated="url"
message="COM_COMPONENTBUILDER_CONFIG_EXPORT_BUY_LINK_MESSAGE" message="COM_COMPONENTBUILDER_CONFIG_EXPORT_BUY_LINK_MESSAGE"
hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_BUY_LINK_HINT" hint="COM_COMPONENTBUILDER_CONFIG_EXPORT_BUY_LINK_HINT" />
/>
</fieldset> </fieldset>
<fieldset <fieldset
name="permissions" name="permissions"

View File

@ -96,6 +96,7 @@ class ComponentbuilderController extends JControllerLegacy
'layout' => 'layouts', 'layout' => 'layouts',
'dynamic_get' => 'dynamic_gets', 'dynamic_get' => 'dynamic_gets',
'custom_code' => 'custom_codes', 'custom_code' => 'custom_codes',
'library' => 'libraries',
'snippet' => 'snippets', 'snippet' => 'snippets',
'field' => 'fields', 'field' => 'fields',
'fieldtype' => 'fieldtypes', 'fieldtype' => 'fieldtypes',
@ -115,7 +116,8 @@ class ComponentbuilderController extends JControllerLegacy
'component_dashboard' => 'components_dashboard', 'component_dashboard' => 'components_dashboard',
'component_files_folders' => 'components_files_folders', 'component_files_folders' => 'components_files_folders',
'snippet_type' => 'snippet_types', 'snippet_type' => 'snippet_types',
'library' => 'libraries' 'library_config' => 'libraries_config',
'library_files_folders_urls' => 'libraries_files_folders_urls'
); );
// check if this is a list view // check if this is a list view
if (in_array($view,$views)) if (in_array($view,$views))

View File

@ -52,6 +52,7 @@ class ComponentbuilderControllerAjax extends JControllerLegacy
$this->registerTask('getButton', 'ajax'); $this->registerTask('getButton', 'ajax');
$this->registerTask('getButtonID', 'ajax'); $this->registerTask('getButtonID', 'ajax');
$this->registerTask('getAjaxDisplay', 'ajax'); $this->registerTask('getAjaxDisplay', 'ajax');
$this->registerTask('getSnippets', 'ajax');
$this->registerTask('templateDetails', 'ajax'); $this->registerTask('templateDetails', 'ajax');
$this->registerTask('getLayoutDetails', 'ajax'); $this->registerTask('getLayoutDetails', 'ajax');
$this->registerTask('dbTableColumns', 'ajax'); $this->registerTask('dbTableColumns', 'ajax');
@ -457,6 +458,44 @@ class ComponentbuilderControllerAjax extends JControllerLegacy
} }
} }
break; break;
case 'getSnippets':
try
{
$returnRaw = $jinput->get('raw', false, 'BOOLEAN');
$librariesValue = $jinput->get('libraries', NULL, 'STRING');
if($librariesValue && $user->id != 0)
{
$result = $this->getModel('ajax')->getSnippets($librariesValue);
}
else
{
$result = false;
}
if($callback = $jinput->get('callback', null, 'CMD'))
{
echo $callback . "(".json_encode($result).");";
}
elseif($returnRaw)
{
echo json_encode($result);
}
else
{
echo "(".json_encode($result).");";
}
}
catch(Exception $e)
{
if($callback = $jinput->get('callback', null, 'CMD'))
{
echo $callback."(".json_encode($e).");";
}
else
{
echo "(".json_encode($e).");";
}
}
break;
case 'templateDetails': case 'templateDetails':
try try
{ {

View File

@ -52,11 +52,20 @@ class ComponentbuilderControllerGet_snippets extends JControllerAdmin
return; return;
} }
public function openLibraries()
{
// Check for request forgeries
JSession::checkToken() or die(JText::_('JINVALID_TOKEN'));
// redirect to the libraries
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=libraries', false));
return;
}
public function openSnippets() public function openSnippets()
{ {
// Check for request forgeries // Check for request forgeries
JSession::checkToken() or die(JText::_('JINVALID_TOKEN')); JSession::checkToken() or die(JText::_('JINVALID_TOKEN'));
// redirect to the snippets admin view // redirect to the snippets
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=snippets', false)); $this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=snippets', false));
return; return;
} }
@ -65,7 +74,7 @@ class ComponentbuilderControllerGet_snippets extends JControllerAdmin
{ {
// Check for request forgeries // Check for request forgeries
JSession::checkToken() or die(JText::_('JINVALID_TOKEN')); JSession::checkToken() or die(JText::_('JINVALID_TOKEN'));
// redirect to the snippets admin view // redirect to the site views
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=site_views', false)); $this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=site_views', false));
return; return;
} }
@ -74,7 +83,7 @@ class ComponentbuilderControllerGet_snippets extends JControllerAdmin
{ {
// Check for request forgeries // Check for request forgeries
JSession::checkToken() or die(JText::_('JINVALID_TOKEN')); JSession::checkToken() or die(JText::_('JINVALID_TOKEN'));
// redirect to the snippets admin view // redirect to the custom admin views
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=custom_admin_views', false)); $this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=custom_admin_views', false));
return; return;
} }
@ -83,7 +92,7 @@ class ComponentbuilderControllerGet_snippets extends JControllerAdmin
{ {
// Check for request forgeries // Check for request forgeries
JSession::checkToken() or die(JText::_('JINVALID_TOKEN')); JSession::checkToken() or die(JText::_('JINVALID_TOKEN'));
// redirect to the snippets admin view // redirect to the templates
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=templates', false)); $this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=templates', false));
return; return;
} }
@ -92,7 +101,7 @@ class ComponentbuilderControllerGet_snippets extends JControllerAdmin
{ {
// Check for request forgeries // Check for request forgeries
JSession::checkToken() or die(JText::_('JINVALID_TOKEN')); JSession::checkToken() or die(JText::_('JINVALID_TOKEN'));
// redirect to the snippets admin view // redirect to the layouts
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=layouts', false)); $this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=layouts', false));
return; return;
} }

View File

@ -45,4 +45,13 @@ class ComponentbuilderControllerLibraries extends JControllerAdmin
return $model; return $model;
} }
public function getSnippets()
{
// Check for request forgeries
JSession::checkToken() or die(JText::_('JINVALID_TOKEN'));
// redirect to the import snippets custom admin view
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=get_snippets', false));
return;
}
} }

View File

@ -0,0 +1,48 @@
<?php
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
__ __ _ _____ _ _ __ __ _ _ _
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
| |
|_|
/-------------------------------------------------------------------------------------------------------------------------------/
@version 2.6.x
@created 30th April, 2015
@package Component Builder
@subpackage libraries_config.php
@author Llewellyn van der Merwe <http://vdm.bz/component-builder>
@github Joomla Component Builder <https://github.com/vdm-io/Joomla-Component-Builder>
@copyright Copyright (C) 2015. All Rights Reserved
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
Builds Complex Joomla Components
/-----------------------------------------------------------------------------------------------------------------------------*/
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
// import Joomla controlleradmin library
jimport('joomla.application.component.controlleradmin');
/**
* Libraries_config Controller
*/
class ComponentbuilderControllerLibraries_config extends JControllerAdmin
{
protected $text_prefix = 'COM_COMPONENTBUILDER_LIBRARIES_CONFIG';
/**
* Proxy for getModel.
* @since 2.5
*/
public function getModel($name = 'Library_config', $prefix = 'ComponentbuilderModel', $config = array())
{
$model = parent::getModel($name, $prefix, array('ignore_request' => true));
return $model;
}
}

View File

@ -0,0 +1,48 @@
<?php
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
__ __ _ _____ _ _ __ __ _ _ _
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
| |
|_|
/-------------------------------------------------------------------------------------------------------------------------------/
@version 2.6.x
@created 30th April, 2015
@package Component Builder
@subpackage libraries_files_folders_urls.php
@author Llewellyn van der Merwe <http://vdm.bz/component-builder>
@github Joomla Component Builder <https://github.com/vdm-io/Joomla-Component-Builder>
@copyright Copyright (C) 2015. All Rights Reserved
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
Builds Complex Joomla Components
/-----------------------------------------------------------------------------------------------------------------------------*/
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
// import Joomla controlleradmin library
jimport('joomla.application.component.controlleradmin');
/**
* Libraries_files_folders_urls Controller
*/
class ComponentbuilderControllerLibraries_files_folders_urls extends JControllerAdmin
{
protected $text_prefix = 'COM_COMPONENTBUILDER_LIBRARIES_FILES_FOLDERS_URLS';
/**
* Proxy for getModel.
* @since 2.5
*/
public function getModel($name = 'Library_files_folders_urls', $prefix = 'ComponentbuilderModel', $config = array())
{
$model = parent::getModel($name, $prefix, array('ignore_request' => true));
return $model;
}
}

View File

@ -320,6 +320,31 @@ class ComponentbuilderControllerLibrary extends JControllerForm
*/ */
protected function postSaveHook(JModelLegacy $model, $validData = array()) protected function postSaveHook(JModelLegacy $model, $validData = array())
{ {
// get the state object (Joomla\CMS\Object\CMSObject)
$state = $model->get('state');
// if we save2copy we need to also copy linked tables found!
if ($state->task === 'save2copy' && $state->{'library.new'})
{
// get new ID
$newID = $state->{'library.id'};
// get old ID
$oldID = $this->input->get('id', 0, 'INT');
// linked tables to update
$_tablesArray = array(
'library_config',
'library_files_folders_urls'
);
foreach($_tablesArray as $_updateTable)
{
// get the linked ID
if ($_value = ComponentbuilderHelper::getVar($_updateTable, $oldID, 'library', 'id'))
{
// copy fields to new linked table
ComponentbuilderHelper::copyItem(/*id->*/ $_value, /*table->*/ $_updateTable, /*change->*/ array('library' => $newID));
}
}
}
return; return;
} }

View File

@ -0,0 +1,326 @@
<?php
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
__ __ _ _____ _ _ __ __ _ _ _
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
| |
|_|
/-------------------------------------------------------------------------------------------------------------------------------/
@version 2.6.x
@created 30th April, 2015
@package Component Builder
@subpackage library_config.php
@author Llewellyn van der Merwe <http://vdm.bz/component-builder>
@github Joomla Component Builder <https://github.com/vdm-io/Joomla-Component-Builder>
@copyright Copyright (C) 2015. All Rights Reserved
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
Builds Complex Joomla Components
/-----------------------------------------------------------------------------------------------------------------------------*/
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
// import Joomla controllerform library
jimport('joomla.application.component.controllerform');
/**
* Library_config Controller
*/
class ComponentbuilderControllerLibrary_config extends JControllerForm
{
/**
* Current or most recently performed task.
*
* @var string
* @since 12.2
* @note Replaces _task.
*/
protected $task;
public function __construct($config = array())
{
$this->view_list = 'Libraries_config'; // safeguard for setting the return view listing to the main view.
parent::__construct($config);
}
/**
* Method override to check if you can add a new record.
*
* @param array $data An array of input data.
*
* @return boolean
*
* @since 1.6
*/
protected function allowAdd($data = array())
{
// Access check.
$access = JFactory::getUser()->authorise('library_config.access', 'com_componentbuilder');
if (!$access)
{
return false;
}
// In the absense of better information, revert to the component permissions.
return JFactory::getUser()->authorise('library_config.create', $this->option);
}
/**
* Method override to check if you can edit an existing record.
*
* @param array $data An array of input data.
* @param string $key The name of the key for the primary key.
*
* @return boolean
*
* @since 1.6
*/
protected function allowEdit($data = array(), $key = 'id')
{
// get user object.
$user = JFactory::getUser();
// get record id.
$recordId = (int) isset($data[$key]) ? $data[$key] : 0;
// Access check.
$access = ($user->authorise('library_config.access', 'com_componentbuilder.library_config.' . (int) $recordId) && $user->authorise('library_config.access', 'com_componentbuilder'));
if (!$access)
{
return false;
}
if ($recordId)
{
// The record has been set. Check the record permissions.
$permission = $user->authorise('library_config.edit', 'com_componentbuilder.library_config.' . (int) $recordId);
if (!$permission)
{
if ($user->authorise('library_config.edit.own', 'com_componentbuilder.library_config.' . $recordId))
{
// Now test the owner is the user.
$ownerId = (int) isset($data['created_by']) ? $data['created_by'] : 0;
if (empty($ownerId))
{
// Need to do a lookup from the model.
$record = $this->getModel()->getItem($recordId);
if (empty($record))
{
return false;
}
$ownerId = $record->created_by;
}
// If the owner matches 'me' then allow.
if ($ownerId == $user->id)
{
if ($user->authorise('library_config.edit.own', 'com_componentbuilder'))
{
return true;
}
}
}
return false;
}
}
// Since there is no permission, revert to the component permissions.
return $user->authorise('library_config.edit', $this->option);
}
/**
* Gets the URL arguments to append to an item redirect.
*
* @param integer $recordId The primary key id for the item.
* @param string $urlVar The name of the URL variable for the id.
*
* @return string The arguments to append to the redirect URL.
*
* @since 12.2
*/
protected function getRedirectToItemAppend($recordId = null, $urlVar = 'id')
{
$tmpl = $this->input->get('tmpl');
$layout = $this->input->get('layout', 'edit', 'string');
$ref = $this->input->get('ref', 0, 'string');
$refid = $this->input->get('refid', 0, 'int');
// Setup redirect info.
$append = '';
if ($refid)
{
$append .= '&ref='.(string)$ref.'&refid='.(int)$refid;
}
elseif ($ref)
{
$append .= '&ref='.(string)$ref;
}
if ($tmpl)
{
$append .= '&tmpl=' . $tmpl;
}
if ($layout)
{
$append .= '&layout=' . $layout;
}
if ($recordId)
{
$append .= '&' . $urlVar . '=' . $recordId;
}
return $append;
}
/**
* Method to run batch operations.
*
* @param object $model The model.
*
* @return boolean True if successful, false otherwise and internal error is set.
*
* @since 2.5
*/
public function batch($model = null)
{
JSession::checkToken() or jexit(JText::_('JINVALID_TOKEN'));
// Set the model
$model = $this->getModel('Library_config', '', array());
// Preset the redirect
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=libraries_config' . $this->getRedirectToListAppend(), false));
return parent::batch($model);
}
/**
* Method to cancel an edit.
*
* @param string $key The name of the primary key of the URL variable.
*
* @return boolean True if access level checks pass, false otherwise.
*
* @since 12.2
*/
public function cancel($key = null)
{
// get the referal details
$this->ref = $this->input->get('ref', 0, 'word');
$this->refid = $this->input->get('refid', 0, 'int');
$cancel = parent::cancel($key);
if ($cancel)
{
if ($this->refid)
{
$redirect = '&view='.(string)$this->ref.'&layout=edit&id='.(int)$this->refid;
// Redirect to the item screen.
$this->setRedirect(
JRoute::_(
'index.php?option=' . $this->option . $redirect, false
)
);
}
elseif ($this->ref)
{
$redirect = '&view='.(string)$this->ref;
// Redirect to the list screen.
$this->setRedirect(
JRoute::_(
'index.php?option=' . $this->option . $redirect, false
)
);
}
}
else
{
// Redirect to the items screen.
$this->setRedirect(
JRoute::_(
'index.php?option=' . $this->option . '&view=' . $this->view_list, false
)
);
}
return $cancel;
}
/**
* Method to save a record.
*
* @param string $key The name of the primary key of the URL variable.
* @param string $urlVar The name of the URL variable if different from the primary key (sometimes required to avoid router collisions).
*
* @return boolean True if successful, false otherwise.
*
* @since 12.2
*/
public function save($key = null, $urlVar = null)
{
// get the referal details
$this->ref = $this->input->get('ref', 0, 'word');
$this->refid = $this->input->get('refid', 0, 'int');
if ($this->ref || $this->refid)
{
// to make sure the item is checkedin on redirect
$this->task = 'save';
}
$saved = parent::save($key, $urlVar);
if ($this->refid && $saved)
{
$redirect = '&view='.(string)$this->ref.'&layout=edit&id='.(int)$this->refid;
// Redirect to the item screen.
$this->setRedirect(
JRoute::_(
'index.php?option=' . $this->option . $redirect, false
)
);
}
elseif ($this->ref && $saved)
{
$redirect = '&view='.(string)$this->ref;
// Redirect to the list screen.
$this->setRedirect(
JRoute::_(
'index.php?option=' . $this->option . $redirect, false
)
);
}
return $saved;
}
/**
* Function that allows child controller access to model data
* after the data has been saved.
*
* @param JModel &$model The data model object.
* @param array $validData The validated data.
*
* @return void
*
* @since 11.1
*/
protected function postSaveHook(JModelLegacy $model, $validData = array())
{
return;
}
}

View File

@ -0,0 +1,326 @@
<?php
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
__ __ _ _____ _ _ __ __ _ _ _
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
| |
|_|
/-------------------------------------------------------------------------------------------------------------------------------/
@version 2.6.x
@created 30th April, 2015
@package Component Builder
@subpackage library_files_folders_urls.php
@author Llewellyn van der Merwe <http://vdm.bz/component-builder>
@github Joomla Component Builder <https://github.com/vdm-io/Joomla-Component-Builder>
@copyright Copyright (C) 2015. All Rights Reserved
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
Builds Complex Joomla Components
/-----------------------------------------------------------------------------------------------------------------------------*/
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
// import Joomla controllerform library
jimport('joomla.application.component.controllerform');
/**
* Library_files_folders_urls Controller
*/
class ComponentbuilderControllerLibrary_files_folders_urls extends JControllerForm
{
/**
* Current or most recently performed task.
*
* @var string
* @since 12.2
* @note Replaces _task.
*/
protected $task;
public function __construct($config = array())
{
$this->view_list = 'Libraries_files_folders_urls'; // safeguard for setting the return view listing to the main view.
parent::__construct($config);
}
/**
* Method override to check if you can add a new record.
*
* @param array $data An array of input data.
*
* @return boolean
*
* @since 1.6
*/
protected function allowAdd($data = array())
{
// Access check.
$access = JFactory::getUser()->authorise('library_files_folders_urls.access', 'com_componentbuilder');
if (!$access)
{
return false;
}
// In the absense of better information, revert to the component permissions.
return JFactory::getUser()->authorise('library_files_folders_urls.create', $this->option);
}
/**
* Method override to check if you can edit an existing record.
*
* @param array $data An array of input data.
* @param string $key The name of the key for the primary key.
*
* @return boolean
*
* @since 1.6
*/
protected function allowEdit($data = array(), $key = 'id')
{
// get user object.
$user = JFactory::getUser();
// get record id.
$recordId = (int) isset($data[$key]) ? $data[$key] : 0;
// Access check.
$access = ($user->authorise('library_files_folders_urls.access', 'com_componentbuilder.library_files_folders_urls.' . (int) $recordId) && $user->authorise('library_files_folders_urls.access', 'com_componentbuilder'));
if (!$access)
{
return false;
}
if ($recordId)
{
// The record has been set. Check the record permissions.
$permission = $user->authorise('library_files_folders_urls.edit', 'com_componentbuilder.library_files_folders_urls.' . (int) $recordId);
if (!$permission)
{
if ($user->authorise('library_files_folders_urls.edit.own', 'com_componentbuilder.library_files_folders_urls.' . $recordId))
{
// Now test the owner is the user.
$ownerId = (int) isset($data['created_by']) ? $data['created_by'] : 0;
if (empty($ownerId))
{
// Need to do a lookup from the model.
$record = $this->getModel()->getItem($recordId);
if (empty($record))
{
return false;
}
$ownerId = $record->created_by;
}
// If the owner matches 'me' then allow.
if ($ownerId == $user->id)
{
if ($user->authorise('library_files_folders_urls.edit.own', 'com_componentbuilder'))
{
return true;
}
}
}
return false;
}
}
// Since there is no permission, revert to the component permissions.
return $user->authorise('library_files_folders_urls.edit', $this->option);
}
/**
* Gets the URL arguments to append to an item redirect.
*
* @param integer $recordId The primary key id for the item.
* @param string $urlVar The name of the URL variable for the id.
*
* @return string The arguments to append to the redirect URL.
*
* @since 12.2
*/
protected function getRedirectToItemAppend($recordId = null, $urlVar = 'id')
{
$tmpl = $this->input->get('tmpl');
$layout = $this->input->get('layout', 'edit', 'string');
$ref = $this->input->get('ref', 0, 'string');
$refid = $this->input->get('refid', 0, 'int');
// Setup redirect info.
$append = '';
if ($refid)
{
$append .= '&ref='.(string)$ref.'&refid='.(int)$refid;
}
elseif ($ref)
{
$append .= '&ref='.(string)$ref;
}
if ($tmpl)
{
$append .= '&tmpl=' . $tmpl;
}
if ($layout)
{
$append .= '&layout=' . $layout;
}
if ($recordId)
{
$append .= '&' . $urlVar . '=' . $recordId;
}
return $append;
}
/**
* Method to run batch operations.
*
* @param object $model The model.
*
* @return boolean True if successful, false otherwise and internal error is set.
*
* @since 2.5
*/
public function batch($model = null)
{
JSession::checkToken() or jexit(JText::_('JINVALID_TOKEN'));
// Set the model
$model = $this->getModel('Library_files_folders_urls', '', array());
// Preset the redirect
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=libraries_files_folders_urls' . $this->getRedirectToListAppend(), false));
return parent::batch($model);
}
/**
* Method to cancel an edit.
*
* @param string $key The name of the primary key of the URL variable.
*
* @return boolean True if access level checks pass, false otherwise.
*
* @since 12.2
*/
public function cancel($key = null)
{
// get the referal details
$this->ref = $this->input->get('ref', 0, 'word');
$this->refid = $this->input->get('refid', 0, 'int');
$cancel = parent::cancel($key);
if ($cancel)
{
if ($this->refid)
{
$redirect = '&view='.(string)$this->ref.'&layout=edit&id='.(int)$this->refid;
// Redirect to the item screen.
$this->setRedirect(
JRoute::_(
'index.php?option=' . $this->option . $redirect, false
)
);
}
elseif ($this->ref)
{
$redirect = '&view='.(string)$this->ref;
// Redirect to the list screen.
$this->setRedirect(
JRoute::_(
'index.php?option=' . $this->option . $redirect, false
)
);
}
}
else
{
// Redirect to the items screen.
$this->setRedirect(
JRoute::_(
'index.php?option=' . $this->option . '&view=' . $this->view_list, false
)
);
}
return $cancel;
}
/**
* Method to save a record.
*
* @param string $key The name of the primary key of the URL variable.
* @param string $urlVar The name of the URL variable if different from the primary key (sometimes required to avoid router collisions).
*
* @return boolean True if successful, false otherwise.
*
* @since 12.2
*/
public function save($key = null, $urlVar = null)
{
// get the referal details
$this->ref = $this->input->get('ref', 0, 'word');
$this->refid = $this->input->get('refid', 0, 'int');
if ($this->ref || $this->refid)
{
// to make sure the item is checkedin on redirect
$this->task = 'save';
}
$saved = parent::save($key, $urlVar);
if ($this->refid && $saved)
{
$redirect = '&view='.(string)$this->ref.'&layout=edit&id='.(int)$this->refid;
// Redirect to the item screen.
$this->setRedirect(
JRoute::_(
'index.php?option=' . $this->option . $redirect, false
)
);
}
elseif ($this->ref && $saved)
{
$redirect = '&view='.(string)$this->ref;
// Redirect to the list screen.
$this->setRedirect(
JRoute::_(
'index.php?option=' . $this->option . $redirect, false
)
);
}
return $saved;
}
/**
* Function that allows child controller access to model data
* after the data has been saved.
*
* @param JModel &$model The data model object.
* @param array $validData The validated data.
*
* @return void
*
* @since 11.1
*/
protected function postSaveHook(JModelLegacy $model, $validData = array())
{
return;
}
}

View File

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

Some files were not shown because too many files have changed in this diff Show More