Compare commits
23 Commits
Author | SHA1 | Date | |
---|---|---|---|
737bd03e46
|
|||
339aec221e
|
|||
7fa8964b44
|
|||
7edbe20c33
|
|||
e6c02a29f6
|
|||
f44f385159
|
|||
e8abe8e3cf
|
|||
e771e7d243
|
|||
e614f2ec23
|
|||
d28e4c74af
|
|||
a2ec013566
|
|||
4217b22f67
|
|||
6c42b5af61
|
|||
1c7515d0f5
|
|||
9f5c7deec8
|
|||
7759738938
|
|||
461edf5c3f
|
|||
9f30f30b9e
|
|||
f1cb398f7a
|
|||
f2ea22d0ad
|
|||
869a1879cb
|
|||
d4843d6696
|
|||
9db33ad449
|
12
CHANGELOG.md
Normal file
12
CHANGELOG.md
Normal file
@ -0,0 +1,12 @@
|
||||
# v3.1.19
|
||||
|
||||
- We fixed #972 so that custom code (in the header) will be added after the power namespaces
|
||||
- We added a message to show when a server move failed
|
||||
- We fixed the BaseConfig to not use '_' as separator
|
||||
- We fixed the footable loading issue
|
||||
- We removed the need for passing placeholders by reference
|
||||
- We added the option to generate a CHANGELOG
|
||||
- We fixed the server class to load new client if server details changed.
|
||||
- We fixed the readme placeholder issue #978.
|
||||
- We fixed the empty server url issue #978.
|
||||
- Fixed Package import to now use the phplibsec version 3
|
62
README.md
62
README.md
@ -1,5 +1,5 @@
|
||||
|
||||
# Joomla Component Builder ([JCB](http://joomlacomponentbuilder.com))
|
||||
# Joomla Component Builder ([JCB](https://www.joomlacomponentbuilder.com))
|
||||
|
||||
This is a [Joomla 3.x](https://extensions.joomla.org/extension/component-builder/) component. [__See In Action__](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45)
|
||||
|
||||
@ -9,7 +9,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 save you lots of time and money. A real must have!
|
||||
|
||||
You can install it quite easily and with no limitations. On [gitea](https://git.vdm.dev/joomla/Component-Builder/tags) is the latest release (3.1.8) with **ALL** its features and **ALL** concepts totally open-source and free!
|
||||
You can install it quite easily and with no limitations. On [gitea](https://git.vdm.dev/joomla/Component-Builder/tags) is the latest release (3.1.19) 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)
|
||||
|
||||
@ -23,8 +23,8 @@ Some of the Features
|
||||
+ Add you [own dashboard](https://www.youtube.com/watch?v=tU7TeYn1Djo&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=60) in the back-end.
|
||||
+ [Dynamic File and Folder](https://www.youtube.com/watch?v=_c7wzW075lA&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=56) Inclusion concept.
|
||||
+ [Easy Translation](https://www.youtube.com/watch?v=q5NwKGnOHoQ&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=51) via excel.
|
||||
+ Adding your [own rule validation](https://www.youtube.com/watch?v=Z6-ggKtX35o&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=46) to a field in [JCB](http://joomlacomponentbuilder.com)
|
||||
+ [Automated backup system](https://www.youtube.com/watch?v=GUWZaODo_IM&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=40) in [JCB](http://joomlacomponentbuilder.com).
|
||||
+ Adding your [own rule validation](https://www.youtube.com/watch?v=Z6-ggKtX35o&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=46) to a field in [JCB](https://www.joomlacomponentbuilder.com)
|
||||
+ [Automated backup system](https://www.youtube.com/watch?v=GUWZaODo_IM&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=40) in [JCB](https://www.joomlacomponentbuilder.com).
|
||||
+ Adding mySQL Dump to any View/Table.
|
||||
+ Grab existing Table data and build a dynamic dump.
|
||||
+ Unlimited [Joomla](https://extensions.joomla.org/extension/component-builder/) Components.
|
||||
@ -83,13 +83,13 @@ You are in Control
|
||||
+ You can dynamically add internal help structures to all component.
|
||||
+ There is no limitations on how big or how much you want to build (server limitation only).
|
||||
+ This is a complete factory kind of component that functions like a deployment hub.
|
||||
+ Export any component completely mapped in [JCB](http://joomlacomponentbuilder.com) and import into another [JCB](http://joomlacomponentbuilder.com).
|
||||
+ Export any component completely mapped in [JCB](https://www.joomlacomponentbuilder.com) and import into another [JCB](https://www.joomlacomponentbuilder.com).
|
||||
+ This and much much more are all possible with this component builder!
|
||||
|
||||
Get More Demo Content
|
||||
====================
|
||||
|
||||
> You can now get access to the WOW factor, [JCB](http://joomlacomponentbuilder.com) fully mapped can now be yours! Including many other [JCB](http://joomlacomponentbuilder.com) mapped components.
|
||||
> You can now get access to the WOW factor, [JCB](https://www.joomlacomponentbuilder.com) fully mapped can now be yours! Including many other [JCB](https://www.joomlacomponentbuilder.com) mapped components.
|
||||
|
||||
### All you need to do is [explained here](https://vdm.bz/how-to-get-free-vdm-package-keys)!
|
||||
|
||||
@ -99,18 +99,22 @@ To install these packages [watch this tutorial](https://vdm.bz/how-to-install-jc
|
||||
Where can you get support and help?
|
||||
====================
|
||||
|
||||
+ [The JCB Tutorials](https://www.youtube.com/playlist?list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE)
|
||||
+ [German Basic Introduction](https://www.youtube.com/playlist?list=PLQRGFI8XZ_wu0tDFxJtZFwW7AxA4JHQV7)
|
||||
+ [Hello World Tutorial](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45)
|
||||
+ [The JCB! Wiki](https://git.vdm.dev/joomla/Component-Builder/wiki)
|
||||
+ [Forum](https://vdm.bz/jcb-forum)
|
||||
+ [Report a Security Issue](http://joomlacomponentbuilder.com/report-security-issues)
|
||||
+ [Community Complaint](http://joomlacomponentbuilder.com/community-complaint)
|
||||
+ [Open Issue On Gitea](https://git.vdm.dev/joomla/Component-Builder/issues) ^^
|
||||
|
||||
Since [JCB](http://joomlacomponentbuilder.com) has [become a community](https://git.vdm.dev/joomla/Component-Builder/src/branch/master/.github/SUPPORT.md) project [VDM.io](https://www.vdm.io/) is **no longer solely responsible** for support.
|
||||
|
||||
We have started a [**JCB forum**](https://vdm.bz/jcb-forum) where you can post questions, about how things work, or if you need some kind of help in relation to your development of your components.
|
||||
- [Package](https://git.vdm.dev/joomla/pkg-component-builder).
|
||||
- [Download](https://git.vdm.dev/joomla/pkg-component-builder/archive/master.zip).
|
||||
- [Tutorials](https://www.youtube.com/playlist?list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE).
|
||||
- [German](https://www.youtube.com/playlist?list=PLQRGFI8XZ_wu0tDFxJtZFwW7AxA4JHQV7).
|
||||
- [Hello World](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45).
|
||||
- [Discussions](https://github.com/vdm-io/Joomla-Component-Builder/discussions).
|
||||
- [Wiki](https://git.vdm.dev/joomla/Component-Builder/wiki).
|
||||
- [Issues](https://git.vdm.dev/joomla/Component-Builder/issues).
|
||||
- [Issues Stream](https://t.me/jcb_issues). ^^
|
||||
- [Updates](https://t.me/jcb_updates).
|
||||
- [User Group](https://t.me/jcb_group).
|
||||
- [Announcement](https://t.me/Joomla_component_builder).
|
||||
- [Beta](https://git.vdm.dev/joomla-beta/pkg-component-builder).
|
||||
- [Nightly Build](https://git.vdm.dev/joomla-beta/pkg-component-builder/archive/master.zip).
|
||||
- [Community Complaint](https://www.joomlacomponentbuilder.com/community-complaint).
|
||||
- [Security](https://www.vdm.io/report-security-issues).
|
||||
|
||||
^^ Then if you run into any issues, related to the [JCB](https://git.vdm.dev/joomla/Component-Builder/issues) code, like bugs, **start by searching** the (*open & closed*) issues over on [Gitea](https://git.vdm.dev/joomla/Component-Builder/issues), and if the issue has not been mentioned before, **then only** open a new issue, following the [community guidelines](https://git.vdm.dev/joomla/Component-Builder/src/branch/master/.github/CONTRIBUTING.md).
|
||||
|
||||
@ -125,14 +129,14 @@ Our idea was to almost let this tool serve as a cheat sheet to how things can be
|
||||
MAKING IT BETTER!
|
||||
====================
|
||||
|
||||
Get involved on the forums, and the Gitea issues, and you can even help us develop/improve the pipeline of [JCB](http://joomlacomponentbuilder.com) for continues delivery. We really want to see [JCB](http://joomlacomponentbuilder.com) remain the tool of choice for all [Joomla Component Development](https://extensions.joomla.org/extension/component-builder/) needs and ideas.
|
||||
Get involved on the forums, and the Gitea issues, and you can even help us develop/improve the pipeline of [JCB](https://www.joomlacomponentbuilder.com) for continues delivery. We really want to see [JCB](https://www.joomlacomponentbuilder.com) remain the tool of choice for all [Joomla Component Development](https://extensions.joomla.org/extension/component-builder/) needs and ideas.
|
||||
|
||||
TODO
|
||||
======
|
||||
|
||||
- Add automatic unit testing. To nurture pipeline integration for all components build with [JCB](http://joomlacomponentbuilder.com).
|
||||
- Team collaborative development across [JCB](http://joomlacomponentbuilder.com) installations offline and online.
|
||||
- Documentation (maintained by the community) for [JCB](http://joomlacomponentbuilder.com). (help us select the best system for this)
|
||||
- Add automatic unit testing. To nurture pipeline integration for all components build with [JCB](https://www.joomlacomponentbuilder.com).
|
||||
- Team collaborative development across [JCB](https://www.joomlacomponentbuilder.com) installations offline and online.
|
||||
- Documentation (maintained by the community) for [JCB](https://www.joomlacomponentbuilder.com). (help us select the best system for this)
|
||||
|
||||
# Build Details
|
||||
|
||||
@ -140,16 +144,16 @@ TODO
|
||||
+ *Author*: [Llewellyn van der Merwe](mailto:joomla@vdm.io)
|
||||
+ *Name*: [Component Builder](https://git.vdm.dev/joomla/Component-Builder)
|
||||
+ *First Build*: 30th April, 2015
|
||||
+ *Last Build*: 20th September, 2022
|
||||
+ *Version*: 3.1.8
|
||||
+ *Last Build*: 27th February, 2023
|
||||
+ *Version*: 3.1.19
|
||||
+ *Copyright*: Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
+ *License*: GNU General Public License version 2 or later; see LICENSE.txt
|
||||
+ *Line count*: **331607**
|
||||
+ *Field count*: **2004**
|
||||
+ *File count*: **2170**
|
||||
+ *Folder count*: **376**
|
||||
+ *Line count*: **366135**
|
||||
+ *Field count*: **2021**
|
||||
+ *File count*: **2339**
|
||||
+ *Folder count*: **411**
|
||||
|
||||
> This **component** was build with a [Joomla](https://extensions.joomla.org/extension/component-builder/) [Automated Component Builder](http://joomlacomponentbuilder.com).
|
||||
> This **component** was build with a [Joomla](https://extensions.joomla.org/extension/component-builder/) [Automated Component Builder](https://www.joomlacomponentbuilder.com).
|
||||
> Developed by [Llewellyn van der Merwe](mailto:llewellyn@joomlacomponentbuilder.com)
|
||||
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
|
||||
# Joomla Component Builder ([JCB](http://joomlacomponentbuilder.com))
|
||||
# Joomla Component Builder ([JCB](https://www.joomlacomponentbuilder.com))
|
||||
|
||||
This is a [Joomla 3.x](https://extensions.joomla.org/extension/component-builder/) component. [__See In Action__](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45)
|
||||
|
||||
@ -9,7 +9,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 save you lots of time and money. A real must have!
|
||||
|
||||
You can install it quite easily and with no limitations. On [gitea](https://git.vdm.dev/joomla/Component-Builder/tags) is the latest release (3.1.8) with **ALL** its features and **ALL** concepts totally open-source and free!
|
||||
You can install it quite easily and with no limitations. On [gitea](https://git.vdm.dev/joomla/Component-Builder/tags) is the latest release (3.1.19) 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)
|
||||
|
||||
@ -23,8 +23,8 @@ Some of the Features
|
||||
+ Add you [own dashboard](https://www.youtube.com/watch?v=tU7TeYn1Djo&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=60) in the back-end.
|
||||
+ [Dynamic File and Folder](https://www.youtube.com/watch?v=_c7wzW075lA&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=56) Inclusion concept.
|
||||
+ [Easy Translation](https://www.youtube.com/watch?v=q5NwKGnOHoQ&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=51) via excel.
|
||||
+ Adding your [own rule validation](https://www.youtube.com/watch?v=Z6-ggKtX35o&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=46) to a field in [JCB](http://joomlacomponentbuilder.com)
|
||||
+ [Automated backup system](https://www.youtube.com/watch?v=GUWZaODo_IM&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=40) in [JCB](http://joomlacomponentbuilder.com).
|
||||
+ Adding your [own rule validation](https://www.youtube.com/watch?v=Z6-ggKtX35o&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=46) to a field in [JCB](https://www.joomlacomponentbuilder.com)
|
||||
+ [Automated backup system](https://www.youtube.com/watch?v=GUWZaODo_IM&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=0s&index=40) in [JCB](https://www.joomlacomponentbuilder.com).
|
||||
+ Adding mySQL Dump to any View/Table.
|
||||
+ Grab existing Table data and build a dynamic dump.
|
||||
+ Unlimited [Joomla](https://extensions.joomla.org/extension/component-builder/) Components.
|
||||
@ -83,13 +83,13 @@ You are in Control
|
||||
+ You can dynamically add internal help structures to all component.
|
||||
+ There is no limitations on how big or how much you want to build (server limitation only).
|
||||
+ This is a complete factory kind of component that functions like a deployment hub.
|
||||
+ Export any component completely mapped in [JCB](http://joomlacomponentbuilder.com) and import into another [JCB](http://joomlacomponentbuilder.com).
|
||||
+ Export any component completely mapped in [JCB](https://www.joomlacomponentbuilder.com) and import into another [JCB](https://www.joomlacomponentbuilder.com).
|
||||
+ This and much much more are all possible with this component builder!
|
||||
|
||||
Get More Demo Content
|
||||
====================
|
||||
|
||||
> You can now get access to the WOW factor, [JCB](http://joomlacomponentbuilder.com) fully mapped can now be yours! Including many other [JCB](http://joomlacomponentbuilder.com) mapped components.
|
||||
> You can now get access to the WOW factor, [JCB](https://www.joomlacomponentbuilder.com) fully mapped can now be yours! Including many other [JCB](https://www.joomlacomponentbuilder.com) mapped components.
|
||||
|
||||
### All you need to do is [explained here](https://vdm.bz/how-to-get-free-vdm-package-keys)!
|
||||
|
||||
@ -99,18 +99,22 @@ To install these packages [watch this tutorial](https://vdm.bz/how-to-install-jc
|
||||
Where can you get support and help?
|
||||
====================
|
||||
|
||||
+ [The JCB Tutorials](https://www.youtube.com/playlist?list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE)
|
||||
+ [German Basic Introduction](https://www.youtube.com/playlist?list=PLQRGFI8XZ_wu0tDFxJtZFwW7AxA4JHQV7)
|
||||
+ [Hello World Tutorial](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45)
|
||||
+ [The JCB! Wiki](https://git.vdm.dev/joomla/Component-Builder/wiki)
|
||||
+ [Forum](https://vdm.bz/jcb-forum)
|
||||
+ [Report a Security Issue](http://joomlacomponentbuilder.com/report-security-issues)
|
||||
+ [Community Complaint](http://joomlacomponentbuilder.com/community-complaint)
|
||||
+ [Open Issue On Gitea](https://git.vdm.dev/joomla/Component-Builder/issues) ^^
|
||||
|
||||
Since [JCB](http://joomlacomponentbuilder.com) has [become a community](https://git.vdm.dev/joomla/Component-Builder/src/branch/master/.github/SUPPORT.md) project [VDM.io](https://www.vdm.io/) is **no longer solely responsible** for support.
|
||||
|
||||
We have started a [**JCB forum**](https://vdm.bz/jcb-forum) where you can post questions, about how things work, or if you need some kind of help in relation to your development of your components.
|
||||
- [Package](https://git.vdm.dev/joomla/pkg-component-builder).
|
||||
- [Download](https://git.vdm.dev/joomla/pkg-component-builder/archive/master.zip).
|
||||
- [Tutorials](https://www.youtube.com/playlist?list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE).
|
||||
- [German](https://www.youtube.com/playlist?list=PLQRGFI8XZ_wu0tDFxJtZFwW7AxA4JHQV7).
|
||||
- [Hello World](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45).
|
||||
- [Discussions](https://github.com/vdm-io/Joomla-Component-Builder/discussions).
|
||||
- [Wiki](https://git.vdm.dev/joomla/Component-Builder/wiki).
|
||||
- [Issues](https://git.vdm.dev/joomla/Component-Builder/issues).
|
||||
- [Issues Stream](https://t.me/jcb_issues). ^^
|
||||
- [Updates](https://t.me/jcb_updates).
|
||||
- [User Group](https://t.me/jcb_group).
|
||||
- [Announcement](https://t.me/Joomla_component_builder).
|
||||
- [Beta](https://git.vdm.dev/joomla-beta/pkg-component-builder).
|
||||
- [Nightly Build](https://git.vdm.dev/joomla-beta/pkg-component-builder/archive/master.zip).
|
||||
- [Community Complaint](https://www.joomlacomponentbuilder.com/community-complaint).
|
||||
- [Security](https://www.vdm.io/report-security-issues).
|
||||
|
||||
^^ Then if you run into any issues, related to the [JCB](https://git.vdm.dev/joomla/Component-Builder/issues) code, like bugs, **start by searching** the (*open & closed*) issues over on [Gitea](https://git.vdm.dev/joomla/Component-Builder/issues), and if the issue has not been mentioned before, **then only** open a new issue, following the [community guidelines](https://git.vdm.dev/joomla/Component-Builder/src/branch/master/.github/CONTRIBUTING.md).
|
||||
|
||||
@ -125,14 +129,14 @@ Our idea was to almost let this tool serve as a cheat sheet to how things can be
|
||||
MAKING IT BETTER!
|
||||
====================
|
||||
|
||||
Get involved on the forums, and the Gitea issues, and you can even help us develop/improve the pipeline of [JCB](http://joomlacomponentbuilder.com) for continues delivery. We really want to see [JCB](http://joomlacomponentbuilder.com) remain the tool of choice for all [Joomla Component Development](https://extensions.joomla.org/extension/component-builder/) needs and ideas.
|
||||
Get involved on the forums, and the Gitea issues, and you can even help us develop/improve the pipeline of [JCB](https://www.joomlacomponentbuilder.com) for continues delivery. We really want to see [JCB](https://www.joomlacomponentbuilder.com) remain the tool of choice for all [Joomla Component Development](https://extensions.joomla.org/extension/component-builder/) needs and ideas.
|
||||
|
||||
TODO
|
||||
======
|
||||
|
||||
- Add automatic unit testing. To nurture pipeline integration for all components build with [JCB](http://joomlacomponentbuilder.com).
|
||||
- Team collaborative development across [JCB](http://joomlacomponentbuilder.com) installations offline and online.
|
||||
- Documentation (maintained by the community) for [JCB](http://joomlacomponentbuilder.com). (help us select the best system for this)
|
||||
- Add automatic unit testing. To nurture pipeline integration for all components build with [JCB](https://www.joomlacomponentbuilder.com).
|
||||
- Team collaborative development across [JCB](https://www.joomlacomponentbuilder.com) installations offline and online.
|
||||
- Documentation (maintained by the community) for [JCB](https://www.joomlacomponentbuilder.com). (help us select the best system for this)
|
||||
|
||||
# Build Details
|
||||
|
||||
@ -140,16 +144,16 @@ TODO
|
||||
+ *Author*: [Llewellyn van der Merwe](mailto:joomla@vdm.io)
|
||||
+ *Name*: [Component Builder](https://git.vdm.dev/joomla/Component-Builder)
|
||||
+ *First Build*: 30th April, 2015
|
||||
+ *Last Build*: 20th September, 2022
|
||||
+ *Version*: 3.1.8
|
||||
+ *Last Build*: 27th February, 2023
|
||||
+ *Version*: 3.1.19
|
||||
+ *Copyright*: Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
+ *License*: GNU General Public License version 2 or later; see LICENSE.txt
|
||||
+ *Line count*: **331607**
|
||||
+ *Field count*: **2004**
|
||||
+ *File count*: **2170**
|
||||
+ *Folder count*: **376**
|
||||
+ *Line count*: **366135**
|
||||
+ *Field count*: **2021**
|
||||
+ *File count*: **2339**
|
||||
+ *Folder count*: **411**
|
||||
|
||||
> This **component** was build with a [Joomla](https://extensions.joomla.org/extension/component-builder/) [Automated Component Builder](http://joomlacomponentbuilder.com).
|
||||
> This **component** was build with a [Joomla](https://extensions.joomla.org/extension/component-builder/) [Automated Component Builder](https://www.joomlacomponentbuilder.com).
|
||||
> Developed by [Llewellyn van der Merwe](mailto:llewellyn@joomlacomponentbuilder.com)
|
||||
|
||||
|
||||
|
@ -19,7 +19,6 @@
|
||||
<action name="admin_view.access" title="COM_COMPONENTBUILDER_ADMIN_VIEWS_ACCESS" description="COM_COMPONENTBUILDER_ADMIN_VIEWS_ACCESS_DESC" />
|
||||
<action name="admin_view.batch" title="COM_COMPONENTBUILDER_ADMIN_VIEWS_BATCH_USE" description="COM_COMPONENTBUILDER_ADMIN_VIEWS_BATCH_USE_DESC" />
|
||||
<action name="admin_view.create" title="COM_COMPONENTBUILDER_ADMIN_VIEWS_CREATE" description="COM_COMPONENTBUILDER_ADMIN_VIEWS_CREATE_DESC" />
|
||||
<action name="admin_view.dashboard_add" title="COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_ADD" description="COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_ADD_DESC" />
|
||||
<action name="admin_view.dashboard_list" title="COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_LIST" description="COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_LIST_DESC" />
|
||||
<action name="admin_view.delete" title="COM_COMPONENTBUILDER_ADMIN_VIEWS_DELETE" description="COM_COMPONENTBUILDER_ADMIN_VIEWS_DELETE_DESC" />
|
||||
<action name="admin_view.edit" title="COM_COMPONENTBUILDER_ADMIN_VIEWS_EDIT" description="COM_COMPONENTBUILDER_ADMIN_VIEWS_EDIT_DESC" />
|
||||
@ -235,7 +234,6 @@
|
||||
<action name="custom_admin_view.get_snippets" title="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEW_GET_SNIPPETS_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEW_GET_SNIPPETS_BUTTON_ACCESS_DESC" />
|
||||
<action name="custom_admin_view.access" title="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_ACCESS" description="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_ACCESS_DESC" />
|
||||
<action name="custom_admin_view.batch" title="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_BATCH_USE" description="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_BATCH_USE_DESC" />
|
||||
<action name="custom_admin_view.dashboard_add" title="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_ADD" description="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_ADD_DESC" />
|
||||
<action name="custom_admin_view.dashboard_list" title="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_LIST" description="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_LIST_DESC" />
|
||||
<action name="custom_admin_view.version" title="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_EDIT_VERSION" description="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_EDIT_VERSION_DESC" />
|
||||
<action name="custom_admin_view.export" title="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_EXPORT" description="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_EXPORT_DESC" />
|
||||
@ -500,6 +498,7 @@
|
||||
<action name="power.submenu" title="COM_COMPONENTBUILDER_POWERS_SUBMENU" description="COM_COMPONENTBUILDER_POWERS_SUBMENU_DESC" />
|
||||
<action name="search.access" title="COM_COMPONENTBUILDER_SEARCH_ACCESS" description="COM_COMPONENTBUILDER_SEARCH_ACCESS_DESC" />
|
||||
<action name="search.compiler" title="COM_COMPONENTBUILDER_SEARCH_COMPILER_BUTTON_ACCESS" description="COM_COMPONENTBUILDER_SEARCH_COMPILER_BUTTON_ACCESS_DESC" />
|
||||
<action name="search.dashboard_list" title="COM_COMPONENTBUILDER_SEARCH_DASHBOARD_LIST" description="COM_COMPONENTBUILDER_SEARCH_DASHBOARD_LIST_DESC" />
|
||||
<action name="search.submenu" title="COM_COMPONENTBUILDER_SEARCH_SUBMENU" description="COM_COMPONENTBUILDER_SEARCH_SUBMENU_DESC" />
|
||||
<action name="server.access" title="COM_COMPONENTBUILDER_SERVERS_ACCESS" description="COM_COMPONENTBUILDER_SERVERS_ACCESS_DESC" />
|
||||
<action name="server.batch" title="COM_COMPONENTBUILDER_SERVERS_BATCH_USE" description="COM_COMPONENTBUILDER_SERVERS_BATCH_USE_DESC" />
|
||||
@ -518,7 +517,6 @@
|
||||
<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.batch" title="COM_COMPONENTBUILDER_SITE_VIEWS_BATCH_USE" description="COM_COMPONENTBUILDER_SITE_VIEWS_BATCH_USE_DESC" />
|
||||
<action name="site_view.dashboard_add" title="COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_ADD" description="COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_ADD_DESC" />
|
||||
<action name="site_view.dashboard_list" title="COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_LIST" description="COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_LIST_DESC" />
|
||||
<action name="site_view.version" title="COM_COMPONENTBUILDER_SITE_VIEWS_EDIT_VERSION" description="COM_COMPONENTBUILDER_SITE_VIEWS_EDIT_VERSION_DESC" />
|
||||
<action name="site_view.export" title="COM_COMPONENTBUILDER_SITE_VIEWS_EXPORT" description="COM_COMPONENTBUILDER_SITE_VIEWS_EXPORT_DESC" />
|
||||
|
@ -10,4 +10,31 @@
|
||||
|
||||
/* CSS Document */
|
||||
|
||||
|
||||
.selected {
|
||||
background-color:#d7d8db !important
|
||||
}
|
||||
tr.selected td {
|
||||
background-color:#d7d8db !important
|
||||
}
|
||||
#search_settings_block .controls {
|
||||
margin-left: 1px !important;
|
||||
}
|
||||
tr {
|
||||
cursor:pointer
|
||||
}
|
||||
.found_code {
|
||||
color: #46a546;
|
||||
font-weight: bolder;
|
||||
}
|
||||
.search_details_title {
|
||||
font-size: large;
|
||||
font-weight: bolder;
|
||||
}
|
||||
.small_column {
|
||||
padding: 2px;
|
||||
text-align: center;
|
||||
}
|
||||
th.small_column {
|
||||
padding: 2px !important;
|
||||
text-align: center !important;
|
||||
}
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 15 KiB |
Binary file not shown.
Before Width: | Height: | Size: 23 KiB |
Binary file not shown.
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 34 KiB |
BIN
admin/assets/images/icons/search.png
Normal file
BIN
admin/assets/images/icons/search.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 13 KiB |
Binary file not shown.
Before Width: | Height: | Size: 21 KiB |
956
admin/assets/js/search.js
Normal file
956
admin/assets/js/search.js
Normal file
@ -0,0 +1,956 @@
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 30th April, 2015
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
/* JS Document */
|
||||
/**
|
||||
* JS Function to execute the search
|
||||
*/
|
||||
const doSearch = async (signal, tables) => {
|
||||
try {
|
||||
// build form
|
||||
const formData = new FormData();
|
||||
|
||||
// load the result table
|
||||
const resultsTable = new DataTable('#search_results_table');
|
||||
|
||||
// get the search mode
|
||||
let typeSearch = modeObject.querySelector('input[type=\'radio\']:checked').value;
|
||||
|
||||
// set some search values
|
||||
let searchValue = searchObject.value;
|
||||
let replaceValue = replaceObject.value;
|
||||
let matchValue = matchObject.checked ? 1 : 0;
|
||||
let wholeValue = wholeObject.checked ? 1 : 0;
|
||||
let regexValue = regexObject.checked ? 1 : 0;
|
||||
|
||||
// add the form data
|
||||
formData.append('table_name', '');
|
||||
formData.append('type_search', typeSearch);
|
||||
formData.append('search_value', searchValue);
|
||||
formData.append('replace_value', replaceValue);
|
||||
formData.append('match_case', matchValue);
|
||||
formData.append('whole_word', wholeValue);
|
||||
formData.append('regex_search', regexValue);
|
||||
|
||||
// update the URL
|
||||
updateUrlQuery(searchValue, replaceValue, matchValue, wholeValue, regexValue, typeSearch);
|
||||
|
||||
let abort_this_search_values = false;
|
||||
|
||||
// reset the progress bar
|
||||
searchProgressBarObject.style.width = '0%';
|
||||
searchProgressBarObject.innerHTML = '0%';
|
||||
|
||||
// show the progress bar
|
||||
searchProgressObject.style.display = '';
|
||||
|
||||
// hidde the search button
|
||||
startSearchButton.style.display = 'none';
|
||||
|
||||
// show the stop search button
|
||||
stopSearchButton.style.display = '';
|
||||
|
||||
// start search timer
|
||||
startSearchTimer();
|
||||
|
||||
// reset our global counters
|
||||
fieldCount = 0;
|
||||
lineCount = 0;
|
||||
|
||||
// set our local counters
|
||||
let total = 0;
|
||||
let progress = tables.length;
|
||||
let index;
|
||||
|
||||
for (index = 0; index < progress; index++) {
|
||||
|
||||
let tableName = tables[index];
|
||||
|
||||
// add the table name
|
||||
formData.set('table_name', tableName);
|
||||
|
||||
let options = {
|
||||
signal: signal,
|
||||
method: 'POST', // *GET, POST, PUT, DELETE, etc.
|
||||
body: formData
|
||||
}
|
||||
|
||||
if (abort_this_search_values) {
|
||||
break;
|
||||
}
|
||||
const response = await fetch(UrlAjax + 'doSearch', options).then(response => {
|
||||
total++;
|
||||
// return the json response
|
||||
if (response.ok) {
|
||||
return response.json();
|
||||
} else {
|
||||
UIkit.notify(Joomla.JText._('COM_COMPONENTBUILDER_THE_SEARCH_PROCESS_HAD_AN_ERROR_WITH_TABLE') + ' ' + tableName, {pos:'top-right', status:'danger'});
|
||||
}
|
||||
}).then((data) => {
|
||||
if (typeof data.success !== 'undefined') {
|
||||
UIkit.notify(data.success, {pos:'top-right', timeout : 200, status:'success'});
|
||||
//} else if (typeof data.not_found !== 'undefined') {
|
||||
// UIkit.notify(data.not_found, {pos:'bottom-right', timeout : 200});
|
||||
}
|
||||
if (typeof data.items !== 'undefined') {
|
||||
addTableItems(resultsTable, data.items, typeSearch);
|
||||
}
|
||||
if (typeof data.fields_count !== 'undefined') {
|
||||
fieldCount += data.fields_count;
|
||||
}
|
||||
if (typeof data.line_count !== 'undefined') {
|
||||
lineCount += data.line_count;
|
||||
}
|
||||
// calculate the percent
|
||||
let percent = 100.0 * (total / progress);
|
||||
// update the progress bar
|
||||
searchProgressObject.style.display = ''; // always make sure it still shows...
|
||||
searchProgressBarObject.style.width = percent.toFixed(2) + '%';
|
||||
searchProgressBarObject.innerHTML = percent.toFixed(2) + '%';
|
||||
// when complete hide the progress bar
|
||||
if (progress == total) {
|
||||
let total_field_line = ' ' + fieldCount + ' ' + Joomla.JText._('COM_COMPONENTBUILDER_FIELDS_THAT_HAD') + ' ' + lineCount + ' ' + Joomla.JText._('COM_COMPONENTBUILDER_LINES') + ' ';
|
||||
if (progress == 1) {
|
||||
searchProgressBarObject.innerHTML = Joomla.JText._('COM_COMPONENTBUILDER_SEARCHING') + ' ' + tableName + total_field_line + Joomla.JText._('COM_COMPONENTBUILDER_AND_FINISHED_THE_SEARCH_IN') + ' ' + getSearchLenght() + ' ' + Joomla.JText._('COM_COMPONENTBUILDER_SECONDS');
|
||||
} else {
|
||||
searchProgressBarObject.innerHTML = Joomla.JText._('COM_COMPONENTBUILDER_SEARCHING') + ' ' + progress + ' ' + Joomla.JText._('COM_COMPONENTBUILDER_TABLES_WITH') + total_field_line + Joomla.JText._('COM_COMPONENTBUILDER_AND_FINISHED_THE_SEARCH_IN') + ' ' + getSearchLenght() + ' ' + Joomla.JText._('COM_COMPONENTBUILDER_SECONDS');
|
||||
}
|
||||
// show the search button
|
||||
startSearchButton.style.display = '';
|
||||
// hidde the stop search button
|
||||
stopSearchButton.style.display = 'none';
|
||||
setTimeout(function () {
|
||||
// hide the progress bar again
|
||||
searchProgressObject.style.display = 'none';
|
||||
}, 13000);
|
||||
}
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
if (error.name === "AbortError") {
|
||||
abort_this_search_values = true;
|
||||
}
|
||||
});
|
||||
}
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
} finally {
|
||||
// Executed regardless if we caught the error
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* JS Function to start search timer
|
||||
*/
|
||||
const startSearchTimer = () => {
|
||||
startSearchTime = new Date();
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to get search lenght
|
||||
*/
|
||||
const getSearchLenght = () => {
|
||||
// set ending time
|
||||
endSearchTime = new Date();
|
||||
|
||||
// get diff in ms
|
||||
var timeDiff = endSearchTime - startSearchTime;
|
||||
|
||||
// strip the ms
|
||||
timeDiff /= 1000;
|
||||
|
||||
// get seconds
|
||||
return Math.round(timeDiff);
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to fetch selected item
|
||||
*/
|
||||
const getSelectedItem = async (table, row, field, line) => {
|
||||
try {
|
||||
// get the search mode
|
||||
let mode = modeObject.querySelector('input[type=\'radio\']:checked').value;
|
||||
|
||||
// build form
|
||||
const formData = new FormData();
|
||||
|
||||
formData.append('field_name', field);
|
||||
formData.append('row_id', row);
|
||||
formData.append('table_name', table);
|
||||
formData.append('search_value', searchObject.value);
|
||||
formData.append('replace_value', replaceObject.value);
|
||||
formData.append('match_case', matchObject.checked ? 1 : 0);
|
||||
formData.append('whole_word', wholeObject.checked ? 1 : 0);
|
||||
formData.append('regex_search', regexObject.checked ? 1 : 0);
|
||||
|
||||
// get search value
|
||||
if (mode == 2) {
|
||||
// add the line value
|
||||
formData.append('line_nr', line);
|
||||
// calling URL
|
||||
postURL = UrlAjax + 'getReplaceValue';
|
||||
} else {
|
||||
// calling URL
|
||||
postURL = UrlAjax + 'getSearchValue';
|
||||
}
|
||||
|
||||
let options = {
|
||||
method: 'POST', // *GET, POST, PUT, DELETE, etc.
|
||||
body: formData
|
||||
}
|
||||
|
||||
const response = await fetch(postURL, options).then(response => {
|
||||
if (response.ok) {
|
||||
return response.json();
|
||||
}
|
||||
}).then((data) => {
|
||||
if (typeof data.success !== 'undefined') {
|
||||
UIkit.notify(data.success, {pos:'top-right', status:'success'});
|
||||
}
|
||||
if (typeof data.value !== 'undefined') {
|
||||
addSelectedItem(data.value, table, row, field, line);
|
||||
}
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
});
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
} finally {
|
||||
// Executed regardless if we caught the error
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to check if we should save/update the all current found items
|
||||
*/
|
||||
const replaceAllCheck = () => {
|
||||
// get the current searc and replace values
|
||||
let searchValue = searchObject.value;
|
||||
let replaceValue = replaceObject.value;
|
||||
// load question
|
||||
let question = Joomla.JText._('COM_COMPONENTBUILDER_YOUR_ARE_ABOUT_TO_UPDATE_BALLB_VALUES_THAT_CAN_BE_FOUND_IN_THE_DATABASE') + '<br />' +
|
||||
Joomla.JText._('COM_COMPONENTBUILDER_YOU_WILL_REPLACE') + ': [<span class="found_code">' + htmlentities(searchValue) + '</span>] ' +
|
||||
Joomla.JText._('COM_COMPONENTBUILDER_WITH') + ': [<span class="found_code">' + htmlentities(replaceValue) + '</span>]<br />' +
|
||||
Joomla.JText._('COM_COMPONENTBUILDER_THIS_CAN_NOT_BE_UNDONE_BYOU_HAVE_BEEN_WARNEDB') + '<br /><br />' +
|
||||
Joomla.JText._('COM_COMPONENTBUILDER_ARE_YOU_THEREFORE_ABSOLUTELY_SURE_YOU_WANT_TO_CONTINUE');
|
||||
// do check
|
||||
UIkit.modal.confirm(question, function () {
|
||||
|
||||
// show the search settings again
|
||||
showSearch();
|
||||
|
||||
// Create new controller and issue new request
|
||||
controller_replace = new AbortController();
|
||||
|
||||
// check if any specific table was set
|
||||
let tables = [];
|
||||
let table = tableObject.value;
|
||||
if (table != -1) {
|
||||
tables.push(table);
|
||||
replaceAll(controller_replace.signal, tables);
|
||||
} else {
|
||||
replaceAll(controller_replace.signal, searchTables);
|
||||
}
|
||||
}, {labels: { Ok: Joomla.JText._('COM_COMPONENTBUILDER_YES_UPDATE_ALL'), Cancel: Joomla.JText._('COM_COMPONENTBUILDER_NO') }});
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to execute the search
|
||||
*/
|
||||
const replaceAll = async (signal, tables) => {
|
||||
try {
|
||||
// build form
|
||||
const formData = new FormData();
|
||||
|
||||
// get the search mode
|
||||
let typeSearch = modeObject.querySelector('input[type=\'radio\']:checked').value;
|
||||
|
||||
// set some search values
|
||||
let searchValue = searchObject.value;
|
||||
let replaceValue = replaceObject.value;
|
||||
let matchValue = matchObject.checked ? 1 : 0;
|
||||
let wholeValue = wholeObject.checked ? 1 : 0;
|
||||
let regexValue = regexObject.checked ? 1 : 0;
|
||||
|
||||
// add the form data
|
||||
formData.append('table_name', '');
|
||||
formData.append('type_search', typeSearch);
|
||||
formData.append('search_value', searchValue);
|
||||
formData.append('replace_value', replaceValue);
|
||||
formData.append('match_case', matchValue);
|
||||
formData.append('whole_word', wholeValue);
|
||||
formData.append('regex_search', regexValue);
|
||||
|
||||
// reset the progress bar
|
||||
replaceProgressBarObject.style.width = '0%';
|
||||
|
||||
// show the progress bar
|
||||
replaceProgressObject.style.display = '';
|
||||
|
||||
let abort_this_replace_values = false;
|
||||
|
||||
let total = 0;
|
||||
let progress = tables.length;
|
||||
let index;
|
||||
|
||||
for (index = 0; index < progress; index++) {
|
||||
|
||||
let tableName = tables[index];
|
||||
|
||||
// add the table name
|
||||
formData.set('table_name', tableName);
|
||||
|
||||
let options = {
|
||||
signal: signal,
|
||||
method: 'POST', // *GET, POST, PUT, DELETE, etc.
|
||||
body: formData
|
||||
}
|
||||
|
||||
if (abort_this_replace_values) {
|
||||
break;
|
||||
}
|
||||
const response = await fetch(UrlAjax + 'replaceAll', options).then(response => {
|
||||
total++;
|
||||
if (response.ok) {
|
||||
return response.json();
|
||||
} else {
|
||||
UIkit.notify(Joomla.JText._('COM_COMPONENTBUILDER_THE_REPLACE_PROCESS_HAD_AN_ERROR_WITH_TABLE') + ' ' + tableName, {pos:'top-right', status:'danger'});
|
||||
}
|
||||
}).then((data) => {
|
||||
if (typeof data.success !== 'undefined') {
|
||||
UIkit.notify(data.success, {pos:'top-right', timeout : 200, status:'success'});
|
||||
} else if (typeof data.error !== 'undefined') {
|
||||
UIkit.notify(data.error, {pos:'bottom-right', timeout : 200});
|
||||
}
|
||||
// calculate the percent
|
||||
let percent = 100.0 * (total / progress);
|
||||
// update the progress bar
|
||||
replaceProgressBarObject.style.width = percent.toFixed(2) + '%';
|
||||
// when complete hide the progress bar
|
||||
if (progress == total) {
|
||||
setTimeout(function () {
|
||||
// hide the progress bar again
|
||||
replaceProgressObject.style.display = 'none';
|
||||
// we clear the table again
|
||||
clearAll();
|
||||
// if not reqex we reverse the search for you so you can see the update was a success
|
||||
if (regexValue == 0) {
|
||||
// set the replace value as the search value
|
||||
UIkit.modal.confirm(Joomla.JText._('COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_DO_A_REVERSE_SEARCH'), function(){
|
||||
startNewSearch(replaceValue, searchValue, matchValue, wholeValue, regexValue, 2);
|
||||
}, function () {
|
||||
UIkit.modal.confirm(Joomla.JText._('COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_REPEAT_THE_SAME_SEARCH'), function(){
|
||||
startSearch();
|
||||
}, function () {
|
||||
clearSearch();
|
||||
}, {labels: { Ok: Joomla.JText._('COM_COMPONENTBUILDER_YES'), Cancel: Joomla.JText._('COM_COMPONENTBUILDER_NO') }});
|
||||
}, {labels: { Ok: Joomla.JText._('COM_COMPONENTBUILDER_YES'), Cancel: Joomla.JText._('COM_COMPONENTBUILDER_NO') }});
|
||||
} else {
|
||||
// else we search it again just to prove its changed
|
||||
UIkit.modal.confirm(Joomla.JText._('COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_REPEAT_THE_SAME_SEARCH'), function(){
|
||||
startSearch();
|
||||
}, function () {
|
||||
clearSearch();
|
||||
}, {labels: { Ok: Joomla.JText._('COM_COMPONENTBUILDER_YES'), Cancel: Joomla.JText._('COM_COMPONENTBUILDER_NO') }});
|
||||
}
|
||||
}, 3000);
|
||||
}
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
if (error.name === "AbortError") {
|
||||
abort_this_replace_values = true;
|
||||
}
|
||||
});
|
||||
}
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
} finally {
|
||||
// Executed regardless if we caught the error
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to check if we should save/update the current selected item
|
||||
*/
|
||||
const setValueCheck = (row, field, table) => {
|
||||
// load question
|
||||
let question = Joomla.JText._('COM_COMPONENTBUILDER_YOUR_ARE_ABOUT_TO_UPDATE_ROW') + ' (' + row + ') -> (' + field + ') ' +
|
||||
Joomla.JText._('COM_COMPONENTBUILDER_FIELD_IN_THE') + ' (' + table + ') ' + Joomla.JText._('COM_COMPONENTBUILDER_TABLE') + '.<br /><br />' +
|
||||
Joomla.JText._('COM_COMPONENTBUILDER_THIS_CAN_NOT_BE_UNDONE_ARE_YOU_SURE_YOU_WANT_TO_CONTINUE');
|
||||
// do check
|
||||
UIkit.modal.confirm(question, function () {
|
||||
setValue(row, field, table);
|
||||
}, {labels: { Ok: Joomla.JText._('COM_COMPONENTBUILDER_YES'), Cancel: Joomla.JText._('COM_COMPONENTBUILDER_NO') }});
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to set the current selected item
|
||||
*/
|
||||
const setValue = async (row, field, table) => {
|
||||
try {
|
||||
// get the value from the editor
|
||||
let value = editorObject.getValue();
|
||||
|
||||
// build form
|
||||
const formData = new FormData();
|
||||
|
||||
formData.append('value', value);
|
||||
formData.append('row_id', row);
|
||||
formData.append('field_name', field);
|
||||
formData.append('table_name', table);
|
||||
|
||||
let options = {
|
||||
method: 'POST', // *GET, POST, PUT, DELETE, etc.
|
||||
body: formData
|
||||
}
|
||||
|
||||
const response = await fetch(UrlAjax + 'setValue', options).then(response => {
|
||||
if (response.ok) {
|
||||
return response.json();
|
||||
}
|
||||
}).then((data) => {
|
||||
if (typeof data.success !== 'undefined') {
|
||||
UIkit.notify(data.success, {pos:'top-right', status:'success'});
|
||||
clearSelectedItem();
|
||||
tableActiveObject.remove().draw();
|
||||
}
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
});
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
} finally {
|
||||
// Executed regardless if we caught the error
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to add item to the editor
|
||||
*/
|
||||
const addSelectedItem = async (value, table, row, field, line) => {
|
||||
// display area
|
||||
if (value.length > 1)
|
||||
{
|
||||
// add value to editor
|
||||
editorObject.setValue(value);
|
||||
|
||||
// set item details notice area
|
||||
itemNoticeObject.style.display = '';
|
||||
itemEditButtonObject.innerHTML = editButtonSelected;
|
||||
itemTableNameObject.innerHTML = table;
|
||||
itemRowIdObject.innerHTML = row;
|
||||
itemFieldNameObject.innerHTML = field;
|
||||
itemLineNumberObject.innerHTML = line;
|
||||
// set button and editor line if we have a line number
|
||||
if (typeof line == 'number') {
|
||||
// show and set the save button
|
||||
buttonUpdateItemObject.style.display = '';
|
||||
buttonUpdateItemObject.setAttribute('onclick',"setValueCheck(" + row + ", '" + field + "', '" + table + "');");
|
||||
|
||||
// get top of the code line
|
||||
let top = editorObject.charCoords({line: line, ch: 0}, "local").top;
|
||||
// scroll to the line
|
||||
editorObject.scrollTo(null, top - 12);
|
||||
// select the line
|
||||
editorObject.setCursor(line - 1);
|
||||
} else {
|
||||
// no line so no data we can't save this data
|
||||
buttonUpdateItemObject.setAttribute('onclick', "");
|
||||
buttonUpdateItemObject.style.display = 'none';
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to clear item from the editor and hide it
|
||||
*/
|
||||
const clearSelectedItem = async () => {
|
||||
// display area
|
||||
editorObject.setValue('');
|
||||
// clear notice area
|
||||
itemNoticeObject.style.display = 'none';
|
||||
itemEditButtonObject.innerHTML = '...';
|
||||
itemTableNameObject.innerHTML = '...';
|
||||
itemRowIdObject.innerHTML = '...';
|
||||
itemFieldNameObject.innerHTML = '...';
|
||||
itemLineNumberObject.innerHTML = '...';
|
||||
// clear update button
|
||||
buttonUpdateItemObject.setAttribute('onclick', '');
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to clear table items
|
||||
*/
|
||||
const clearTableItems = async () => {
|
||||
let table = new DataTable('#search_results_table');
|
||||
// clear search
|
||||
table.search('').columns().search( '' );
|
||||
// clear items
|
||||
table.clear().draw( true );
|
||||
|
||||
// hide the update all items
|
||||
buttonUpdateAllStyleDisplay('none');
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to clear all details of the search
|
||||
*/
|
||||
const clearAll = async () => {
|
||||
// clear all details
|
||||
clearTableItems();
|
||||
clearSelectedItem();
|
||||
searchedObject.innerHTML = '....';
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to clear the search and replace values
|
||||
*/
|
||||
const clearSearch = async () => {
|
||||
// clear the search and replace values
|
||||
searchObject.value = '';
|
||||
replaceObject.value = '';
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to set the search and replace values
|
||||
*/
|
||||
const startNewSearch = async (search, replace = '', match = 0, whole = 0, regex = 0, mode = 1) => {
|
||||
// redirect to a new search
|
||||
window.location.href = getSearchURL(search, replace, match, whole, regex, mode);
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to update the URL of the browser with the search query
|
||||
*/
|
||||
const updateUrlQuery = async (search, replace = '', match = 0, whole = 0, regex = 0, mode = 1) => {
|
||||
// update the url query
|
||||
window.history.pushState({}, '', getSearchURL(search, replace, match, whole, regex, mode));
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to get the current search URL
|
||||
*/
|
||||
const getSearchURL = (search, replace = '', match = 0, whole = 0, regex = 0, mode = 1) => {
|
||||
// check if its a single table search
|
||||
let table = tableObject.value;
|
||||
let table_name = '';
|
||||
if (table != -1) {
|
||||
table_name = '&table_name=' + urlencode(table);
|
||||
}
|
||||
// update the type of search
|
||||
if (mode == 1) {
|
||||
return UrlSearch + table_name +
|
||||
'&search_value=' + urlencode(search) +
|
||||
'&type_search=1&match_case=' + match +
|
||||
'&whole_word=' + whole +
|
||||
'®ex_search=' + regex;
|
||||
} else if (mode == 2) {
|
||||
return UrlSearch + table_name +
|
||||
'&search_value=' + urlencode(search) +
|
||||
'&replace_value=' + urlencode(replace) +
|
||||
'&type_search=2&match_case=' + match +
|
||||
'&whole_word=' + whole +
|
||||
'®ex_search=' + regex;
|
||||
}
|
||||
return UrlSearch + table_name;
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to check if a element has a class
|
||||
*/
|
||||
const hasClass = (elementObject, classNaam) => {
|
||||
return !!elementObject.className.match(new RegExp('(\\s|^)' + classNaam + '(\\s|$)'));
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function add a class from an element
|
||||
*/
|
||||
const addClass = (elementObject, classNaam) => {
|
||||
if (!hasClass(elementObject, classNaam)) {
|
||||
elementObject.className += " " + classNaam;
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function remove a class from an element
|
||||
*/
|
||||
const removeClass = (elementObject, classNaam) => {
|
||||
if (hasClass(elementObject, classNaam)) {
|
||||
var reg = new RegExp('(\\s|^)' + classNaam + '(\\s|$)');
|
||||
elementObject.className = elementObject.className.replace(reg, ' ');
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to add items to the table
|
||||
*/
|
||||
const addTableItems = async (table, items, typeSearch) => {
|
||||
table.rows.add(items).draw( false );
|
||||
if (typeSearch == 2) {
|
||||
buttonUpdateAllStyleDisplay(''); // TODO should only show once all items are loaded
|
||||
} else {
|
||||
buttonUpdateAllStyleDisplay('none'); // TODO should only show once all items are loaded
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to update the update all button
|
||||
*/
|
||||
const buttonUpdateAllStyleDisplay = async (value) => {
|
||||
buttonUpdateAllObject.forEach((buttonObject) => {
|
||||
buttonObject.style.display = value;
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to execute (A) on search/replace text change , (B) on search options changes
|
||||
*/
|
||||
const startSearch = (field, forced = false) => {
|
||||
// check mode
|
||||
let mode = modeObject.querySelector('input[type=\'radio\']:checked').value;
|
||||
if (mode == 0) {
|
||||
// reset the search area
|
||||
window.location.href = UrlSearch;
|
||||
}
|
||||
// check if we have an Enter click
|
||||
if (field && typeof field.code !== 'undefined' && field.code === "Enter") {
|
||||
forced = true;
|
||||
}
|
||||
// get replace value if set
|
||||
const replaceValue = replaceObject.value;
|
||||
if (replaceValue.length > 0) {
|
||||
// set the searched value
|
||||
replacedObject.innerHTML = htmlentities(replaceValue);
|
||||
} else {
|
||||
replacedObject.innerHTML = '';
|
||||
}
|
||||
// get search value
|
||||
const searchValue = searchObject.value;
|
||||
if (searchValue.length > 2 || (searchValue.length > 0 && forced)) {
|
||||
// Cancel any ongoing requests
|
||||
if (controller) controller.abort();
|
||||
|
||||
// we clear the table again
|
||||
clearAll();
|
||||
|
||||
// set the searched value
|
||||
searchedObject.innerHTML = htmlentities(searchValue);
|
||||
|
||||
// Create new controller and issue new request
|
||||
controller = new AbortController();
|
||||
|
||||
// check if any specific table was set
|
||||
let tables = [];
|
||||
let table = tableObject.value;
|
||||
if (table != -1) {
|
||||
tables.push(table);
|
||||
doSearch(controller.signal, tables);
|
||||
} else {
|
||||
doSearch(controller.signal, searchTables);
|
||||
}
|
||||
} else {
|
||||
// Clear the table
|
||||
clearAll();
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to stop a search
|
||||
*/
|
||||
const stopSearch = () => {
|
||||
// Cancel any ongoing requests
|
||||
if (controller) controller.abort();
|
||||
// show the search button
|
||||
startSearchButton.style.display = '';
|
||||
// hidde the stop search button
|
||||
stopSearchButton.style.display = 'none';
|
||||
// remove the progress bar at some point
|
||||
setTimeout(function () {
|
||||
// hide the progress bar again
|
||||
searchProgressObject.style.display = 'none';
|
||||
}, 13000);
|
||||
}
|
||||
|
||||
/**
|
||||
* JS Function to hide search settings and show table search
|
||||
*/
|
||||
const showSearch = () => {
|
||||
searchSettingsObject.style.display = '';
|
||||
searchDetailsObject.style.display = 'none';
|
||||
replaceDetailsObject.style.display = 'none';
|
||||
tableSearchObject.style.display = 'none';
|
||||
tableLengthObject.style.display = 'none';
|
||||
};
|
||||
|
||||
/**
|
||||
* JS Function to show search settings and hide table search
|
||||
*/
|
||||
const hideSearch = () => {
|
||||
searchSettingsObject.style.display = 'none';
|
||||
searchDetailsObject.style.display = '';
|
||||
tableSearchObject.style.display = '';
|
||||
tableLengthObject.style.display = '';
|
||||
// check if we are in replace mode
|
||||
let mode = modeObject.querySelector('input[type=\'radio\']:checked').value;
|
||||
if (mode == 2) {
|
||||
replaceDetailsObject.style.display = '';
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
function htmlentities(string, quoteStyle, charset, doubleEncode) {
|
||||
// discuss at: https://locutus.io/php/htmlentities/
|
||||
// original by: Kevin van Zonneveld (https://kvz.io)
|
||||
// revised by: Kevin van Zonneveld (https://kvz.io)
|
||||
// revised by: Kevin van Zonneveld (https://kvz.io)
|
||||
// improved by: nobbler
|
||||
// improved by: Jack
|
||||
// improved by: Rafał Kukawski (https://blog.kukawski.pl)
|
||||
// improved by: Dj (https://locutus.io/php/htmlentities:425#comment_134018)
|
||||
// bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
|
||||
// bugfixed by: Brett Zamir (https://brett-zamir.me)
|
||||
// input by: Ratheous
|
||||
// note 1: function is compatible with PHP 5.2 and older
|
||||
// example 1: htmlentities('Kevin & van Zonneveld')
|
||||
// returns 1: 'Kevin & van Zonneveld'
|
||||
// example 2: htmlentities("foo'bar","ENT_QUOTES")
|
||||
// returns 2: 'foo'bar'
|
||||
const hashMap = getHtmlTranslationTable('HTML_ENTITIES', quoteStyle)
|
||||
string = string === null ? '' : string + ''
|
||||
if (!hashMap) {
|
||||
return false
|
||||
}
|
||||
if (quoteStyle && quoteStyle === 'ENT_QUOTES') {
|
||||
hashMap["'"] = '''
|
||||
}
|
||||
doubleEncode = doubleEncode === null || !!doubleEncode
|
||||
const regex = new RegExp('&(?:#\\d+|#x[\\da-f]+|[a-zA-Z][\\da-z]*);|[' +
|
||||
Object.keys(hashMap)
|
||||
.join('')
|
||||
// replace regexp special chars
|
||||
.replace(/([()[\]{}\-.*+?^$|/\\])/g, '\\$1') + ']',
|
||||
'g')
|
||||
return string.replace(regex, function (ent) {
|
||||
if (ent.length > 1) {
|
||||
return doubleEncode ? hashMap['&'] + ent.substr(1) : ent
|
||||
}
|
||||
return hashMap[ent]
|
||||
})
|
||||
}
|
||||
|
||||
function getHtmlTranslationTable(table, quoteStyle) { // eslint-disable-line camelcase
|
||||
// discuss at: https://locutus.io/php/get_html_translation_table/
|
||||
// original by: Philip Peterson
|
||||
// revised by: Kevin van Zonneveld (https://kvz.io)
|
||||
// bugfixed by: noname
|
||||
// bugfixed by: Alex
|
||||
// bugfixed by: Marco
|
||||
// bugfixed by: madipta
|
||||
// bugfixed by: Brett Zamir (https://brett-zamir.me)
|
||||
// bugfixed by: T.Wild
|
||||
// improved by: KELAN
|
||||
// improved by: Brett Zamir (https://brett-zamir.me)
|
||||
// input by: Frank Forte
|
||||
// input by: Ratheous
|
||||
// note 1: It has been decided that we're not going to add global
|
||||
// note 1: dependencies to Locutus, meaning the constants are not
|
||||
// note 1: real constants, but strings instead. Integers are also supported if someone
|
||||
// note 1: chooses to create the constants themselves.
|
||||
// example 1: get_html_translation_table('HTML_SPECIALCHARS')
|
||||
// returns 1: {'"': '"', '&': '&', '<': '<', '>': '>'}
|
||||
|
||||
const entities = {}
|
||||
const hashMap = {}
|
||||
let decimal
|
||||
const constMappingTable = {}
|
||||
const constMappingQuoteStyle = {}
|
||||
let useTable = {}
|
||||
let useQuoteStyle = {}
|
||||
|
||||
// Translate arguments
|
||||
constMappingTable[0] = 'HTML_SPECIALCHARS'
|
||||
constMappingTable[1] = 'HTML_ENTITIES'
|
||||
constMappingQuoteStyle[0] = 'ENT_NOQUOTES'
|
||||
constMappingQuoteStyle[2] = 'ENT_COMPAT'
|
||||
constMappingQuoteStyle[3] = 'ENT_QUOTES'
|
||||
|
||||
useTable = !isNaN(table)
|
||||
? constMappingTable[table]
|
||||
: table
|
||||
? table.toUpperCase()
|
||||
: 'HTML_SPECIALCHARS'
|
||||
|
||||
useQuoteStyle = !isNaN(quoteStyle)
|
||||
? constMappingQuoteStyle[quoteStyle]
|
||||
: quoteStyle
|
||||
? quoteStyle.toUpperCase()
|
||||
: 'ENT_COMPAT'
|
||||
|
||||
if (useTable !== 'HTML_SPECIALCHARS' && useTable !== 'HTML_ENTITIES') {
|
||||
throw new Error('Table: ' + useTable + ' not supported')
|
||||
}
|
||||
|
||||
entities['38'] = '&'
|
||||
if (useTable === 'HTML_ENTITIES') {
|
||||
entities['160'] = ' '
|
||||
entities['161'] = '¡'
|
||||
entities['162'] = '¢'
|
||||
entities['163'] = '£'
|
||||
entities['164'] = '¤'
|
||||
entities['165'] = '¥'
|
||||
entities['166'] = '¦'
|
||||
entities['167'] = '§'
|
||||
entities['168'] = '¨'
|
||||
entities['169'] = '©'
|
||||
entities['170'] = 'ª'
|
||||
entities['171'] = '«'
|
||||
entities['172'] = '¬'
|
||||
entities['173'] = '­'
|
||||
entities['174'] = '®'
|
||||
entities['175'] = '¯'
|
||||
entities['176'] = '°'
|
||||
entities['177'] = '±'
|
||||
entities['178'] = '²'
|
||||
entities['179'] = '³'
|
||||
entities['180'] = '´'
|
||||
entities['181'] = 'µ'
|
||||
entities['182'] = '¶'
|
||||
entities['183'] = '·'
|
||||
entities['184'] = '¸'
|
||||
entities['185'] = '¹'
|
||||
entities['186'] = 'º'
|
||||
entities['187'] = '»'
|
||||
entities['188'] = '¼'
|
||||
entities['189'] = '½'
|
||||
entities['190'] = '¾'
|
||||
entities['191'] = '¿'
|
||||
entities['192'] = 'À'
|
||||
entities['193'] = 'Á'
|
||||
entities['194'] = 'Â'
|
||||
entities['195'] = 'Ã'
|
||||
entities['196'] = 'Ä'
|
||||
entities['197'] = 'Å'
|
||||
entities['198'] = 'Æ'
|
||||
entities['199'] = 'Ç'
|
||||
entities['200'] = 'È'
|
||||
entities['201'] = 'É'
|
||||
entities['202'] = 'Ê'
|
||||
entities['203'] = 'Ë'
|
||||
entities['204'] = 'Ì'
|
||||
entities['205'] = 'Í'
|
||||
entities['206'] = 'Î'
|
||||
entities['207'] = 'Ï'
|
||||
entities['208'] = 'Ð'
|
||||
entities['209'] = 'Ñ'
|
||||
entities['210'] = 'Ò'
|
||||
entities['211'] = 'Ó'
|
||||
entities['212'] = 'Ô'
|
||||
entities['213'] = 'Õ'
|
||||
entities['214'] = 'Ö'
|
||||
entities['215'] = '×'
|
||||
entities['216'] = 'Ø'
|
||||
entities['217'] = 'Ù'
|
||||
entities['218'] = 'Ú'
|
||||
entities['219'] = 'Û'
|
||||
entities['220'] = 'Ü'
|
||||
entities['221'] = 'Ý'
|
||||
entities['222'] = 'Þ'
|
||||
entities['223'] = 'ß'
|
||||
entities['224'] = 'à'
|
||||
entities['225'] = 'á'
|
||||
entities['226'] = 'â'
|
||||
entities['227'] = 'ã'
|
||||
entities['228'] = 'ä'
|
||||
entities['229'] = 'å'
|
||||
entities['230'] = 'æ'
|
||||
entities['231'] = 'ç'
|
||||
entities['232'] = 'è'
|
||||
entities['233'] = 'é'
|
||||
entities['234'] = 'ê'
|
||||
entities['235'] = 'ë'
|
||||
entities['236'] = 'ì'
|
||||
entities['237'] = 'í'
|
||||
entities['238'] = 'î'
|
||||
entities['239'] = 'ï'
|
||||
entities['240'] = 'ð'
|
||||
entities['241'] = 'ñ'
|
||||
entities['242'] = 'ò'
|
||||
entities['243'] = 'ó'
|
||||
entities['244'] = 'ô'
|
||||
entities['245'] = 'õ'
|
||||
entities['246'] = 'ö'
|
||||
entities['247'] = '÷'
|
||||
entities['248'] = 'ø'
|
||||
entities['249'] = 'ù'
|
||||
entities['250'] = 'ú'
|
||||
entities['251'] = 'û'
|
||||
entities['252'] = 'ü'
|
||||
entities['253'] = 'ý'
|
||||
entities['254'] = 'þ'
|
||||
entities['255'] = 'ÿ'
|
||||
}
|
||||
|
||||
if (useQuoteStyle !== 'ENT_NOQUOTES') {
|
||||
entities['34'] = '"'
|
||||
}
|
||||
if (useQuoteStyle === 'ENT_QUOTES') {
|
||||
entities['39'] = '''
|
||||
}
|
||||
entities['60'] = '<'
|
||||
entities['62'] = '>'
|
||||
|
||||
// ascii decimals to real symbols
|
||||
for (decimal in entities) {
|
||||
if (entities.hasOwnProperty(decimal)) {
|
||||
hashMap[String.fromCharCode(decimal)] = entities[decimal]
|
||||
}
|
||||
}
|
||||
|
||||
return hashMap
|
||||
}
|
||||
|
||||
|
||||
function urlencode (str) {
|
||||
// discuss at: https://locutus.io/php/urlencode/
|
||||
// original by: Philip Peterson
|
||||
// improved by: Kevin van Zonneveld (https://kvz.io)
|
||||
// improved by: Kevin van Zonneveld (https://kvz.io)
|
||||
// improved by: Brett Zamir (https://brett-zamir.me)
|
||||
// improved by: Lars Fischer
|
||||
// improved by: Waldo Malqui Silva (https://fayr.us/waldo/)
|
||||
// input by: AJ
|
||||
// input by: travc
|
||||
// input by: Brett Zamir (https://brett-zamir.me)
|
||||
// input by: Ratheous
|
||||
// bugfixed by: Kevin van Zonneveld (https://kvz.io)
|
||||
// bugfixed by: Kevin van Zonneveld (https://kvz.io)
|
||||
// bugfixed by: Joris
|
||||
// reimplemented by: Brett Zamir (https://brett-zamir.me)
|
||||
// reimplemented by: Brett Zamir (https://brett-zamir.me)
|
||||
// note 1: This reflects PHP 5.3/6.0+ behavior
|
||||
// note 1: Please be aware that this function
|
||||
// note 1: expects to encode into UTF-8 encoded strings, as found on
|
||||
// note 1: pages served as UTF-8
|
||||
// example 1: urlencode('Kevin van Zonneveld!')
|
||||
// returns 1: 'Kevin+van+Zonneveld%21'
|
||||
// example 2: urlencode('https://kvz.io/')
|
||||
// returns 2: 'https%3A%2F%2Fkvz.io%2F'
|
||||
// example 3: urlencode('https://www.google.nl/search?q=Locutus&ie=utf-8')
|
||||
// returns 3: 'https%3A%2F%2Fwww.google.nl%2Fsearch%3Fq%3DLocutus%26ie%3Dutf-8'
|
||||
str = (str + '')
|
||||
return encodeURIComponent(str)
|
||||
.replace(/!/g, '%21')
|
||||
.replace(/'/g, '%27')
|
||||
.replace(/\(/g, '%28')
|
||||
.replace(/\)/g, '%29')
|
||||
.replace(/\*/g, '%2A')
|
||||
.replace(/~/g, '%7E')
|
||||
.replace(/%20/g, '+')
|
||||
}
|
@ -17,8 +17,7 @@ defined('_JEXEC') or die('Restricted access');
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use Joomla\CMS\MVC\Controller\BaseController;
|
||||
use Joomla\Utilities\ArrayHelper;
|
||||
###IMPORT_CONTROLLER_HEADER###
|
||||
|
||||
/**
|
||||
* ###Component### Import Base Controller
|
||||
|
@ -17,8 +17,7 @@ defined('_JEXEC') or die('Restricted access');
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use Joomla\CMS\MVC\Controller\BaseController;
|
||||
use Joomla\Utilities\ArrayHelper;
|
||||
###IMPORT_CUSTOM_CONTROLLER_HEADER###
|
||||
|
||||
/**
|
||||
* ###Component### ###View### Base Controller
|
||||
|
@ -17,13 +17,9 @@ defined('_JEXEC') or die('Restricted access');
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use Joomla\CMS\MVC\Model\BaseDatabaseModel;
|
||||
use Joomla\CMS\Filesystem\File;
|
||||
use Joomla\CMS\Filesystem\Folder;
|
||||
use Joomla\Utilities\ArrayHelper;
|
||||
use PhpOffice\PhpSpreadsheet\IOFactory;
|
||||
###IMPORT_MODEL_HEADER###
|
||||
|
||||
/**
|
||||
/***
|
||||
* ###Component### Import Base Database Model
|
||||
*/
|
||||
class ###Component###ModelImport extends BaseDatabaseModel
|
||||
|
@ -17,11 +17,7 @@ defined('_JEXEC') or die('Restricted access');
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use Joomla\CMS\MVC\Model\BaseDatabaseModel;
|
||||
use Joomla\CMS\Filesystem\File;
|
||||
use Joomla\CMS\Filesystem\Folder;
|
||||
use Joomla\Utilities\ArrayHelper;
|
||||
use PhpOffice\PhpSpreadsheet\IOFactory;
|
||||
###IMPORT_CUSTOM_MODEL_HEADER###
|
||||
|
||||
/**
|
||||
* ###Component### ###View### Base Database Model
|
||||
|
1
admin/compiler/joomla_3/CHANGELOG.md
Normal file
1
admin/compiler/joomla_3/CHANGELOG.md
Normal file
@ -0,0 +1 @@
|
||||
###CHANGELOG###
|
@ -207,6 +207,12 @@
|
||||
"rename": false,
|
||||
"type": "file"
|
||||
},
|
||||
"CHANGELOG.md": {
|
||||
"naam": "CHANGELOG.md",
|
||||
"path": "c0mp0n3nt/",
|
||||
"rename": false,
|
||||
"type": "file"
|
||||
},
|
||||
"headercheck.php": {
|
||||
"naam": "headercheck.php",
|
||||
"path": "c0mp0n3nt/site/helpers",
|
||||
|
@ -207,6 +207,12 @@
|
||||
"rename": false,
|
||||
"type": "file"
|
||||
},
|
||||
"CHANGELOG.md": {
|
||||
"naam": "CHANGELOG.md",
|
||||
"path": "c0mp0n3nt/",
|
||||
"rename": false,
|
||||
"type": "file"
|
||||
},
|
||||
"headercheck.php": {
|
||||
"naam": "headercheck.php",
|
||||
"path": "c0mp0n3nt/site/helpers",
|
||||
|
@ -67,8 +67,11 @@ class ComponentbuilderControllerAjax extends BaseController
|
||||
$this->registerTask('fieldTypeProperties', 'ajax');
|
||||
$this->registerTask('getFieldPropertyDesc', 'ajax');
|
||||
$this->registerTask('getCodeGlueOptions', 'ajax');
|
||||
$this->registerTask('searchTable', 'ajax');
|
||||
$this->registerTask('updateTable', 'ajax');
|
||||
$this->registerTask('doSearch', 'ajax');
|
||||
$this->registerTask('replaceAll', 'ajax');
|
||||
$this->registerTask('getSearchValue', 'ajax');
|
||||
$this->registerTask('getReplaceValue', 'ajax');
|
||||
$this->registerTask('setValue', 'ajax');
|
||||
$this->registerTask('snippetDetails', 'ajax');
|
||||
$this->registerTask('setSnippetGithub', 'ajax');
|
||||
$this->registerTask('getSnippets', 'ajax');
|
||||
@ -1633,18 +1636,19 @@ class ComponentbuilderControllerAjax extends BaseController
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'searchTable':
|
||||
case 'doSearch':
|
||||
try
|
||||
{
|
||||
$table_nameValue = $jinput->get('table_name', NULL, 'WORD');
|
||||
$type_searchValue = $jinput->get('type_search', 1, 'INT');
|
||||
$search_valueValue = $jinput->get('search_value', NULL, 'RAW');
|
||||
$match_caseValue = $jinput->get('match_case', 0, 'INT');
|
||||
$whole_wordValue = $jinput->get('whole_word', 0, 'INT');
|
||||
$regex_searchValue = $jinput->get('regex_search', 0, 'INT');
|
||||
$component_idValue = $jinput->get('component_id', 0, 'INT');
|
||||
if($table_nameValue && $user->id != 0 && $search_valueValue)
|
||||
if($table_nameValue && $user->id != 0 && $type_searchValue && $search_valueValue)
|
||||
{
|
||||
$result = $this->getModel('ajax')->searchTable($table_nameValue, $search_valueValue, $match_caseValue, $whole_wordValue, $regex_searchValue, $component_idValue);
|
||||
$result = $this->getModel('ajax')->doSearch($table_nameValue, $type_searchValue, $search_valueValue, $match_caseValue, $whole_wordValue, $regex_searchValue, $component_idValue);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -1679,7 +1683,7 @@ class ComponentbuilderControllerAjax extends BaseController
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'updateTable':
|
||||
case 'replaceAll':
|
||||
try
|
||||
{
|
||||
$table_nameValue = $jinput->get('table_name', NULL, 'WORD');
|
||||
@ -1691,7 +1695,148 @@ class ComponentbuilderControllerAjax extends BaseController
|
||||
$component_idValue = $jinput->get('component_id', 0, 'INT');
|
||||
if($table_nameValue && $user->id != 0 && $search_valueValue)
|
||||
{
|
||||
$result = $this->getModel('ajax')->updateTable($table_nameValue, $search_valueValue, $replace_valueValue, $match_caseValue, $whole_wordValue, $regex_searchValue, $component_idValue);
|
||||
$result = $this->getModel('ajax')->replaceAll($table_nameValue, $search_valueValue, $replace_valueValue, $match_caseValue, $whole_wordValue, $regex_searchValue, $component_idValue);
|
||||
}
|
||||
else
|
||||
{
|
||||
$result = false;
|
||||
}
|
||||
if($callback)
|
||||
{
|
||||
echo $callback . "(".json_encode($result).");";
|
||||
}
|
||||
elseif($returnRaw)
|
||||
{
|
||||
echo json_encode($result);
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "(".json_encode($result).");";
|
||||
}
|
||||
}
|
||||
catch(Exception $e)
|
||||
{
|
||||
if($callback)
|
||||
{
|
||||
echo $callback."(".json_encode($e).");";
|
||||
}
|
||||
elseif($returnRaw)
|
||||
{
|
||||
echo json_encode($e);
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "(".json_encode($e).");";
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'getSearchValue':
|
||||
try
|
||||
{
|
||||
$field_nameValue = $jinput->get('field_name', NULL, 'WORD');
|
||||
$row_idValue = $jinput->get('row_id', NULL, 'INT');
|
||||
$table_nameValue = $jinput->get('table_name', NULL, 'WORD');
|
||||
$search_valueValue = $jinput->get('search_value', NULL, 'RAW');
|
||||
$replace_valueValue = $jinput->get('replace_value', NULL, 'RAW');
|
||||
$match_caseValue = $jinput->get('match_case', 0, 'INT');
|
||||
$whole_wordValue = $jinput->get('whole_word', 0, 'INT');
|
||||
$regex_searchValue = $jinput->get('regex_search', 0, 'INT');
|
||||
if($field_nameValue && $user->id != 0 && $row_idValue && $table_nameValue && $search_valueValue)
|
||||
{
|
||||
$result = $this->getModel('ajax')->getSearchValue($field_nameValue, $row_idValue, $table_nameValue, $search_valueValue, $replace_valueValue, $match_caseValue, $whole_wordValue, $regex_searchValue);
|
||||
}
|
||||
else
|
||||
{
|
||||
$result = false;
|
||||
}
|
||||
if($callback)
|
||||
{
|
||||
echo $callback . "(".json_encode($result).");";
|
||||
}
|
||||
elseif($returnRaw)
|
||||
{
|
||||
echo json_encode($result);
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "(".json_encode($result).");";
|
||||
}
|
||||
}
|
||||
catch(Exception $e)
|
||||
{
|
||||
if($callback)
|
||||
{
|
||||
echo $callback."(".json_encode($e).");";
|
||||
}
|
||||
elseif($returnRaw)
|
||||
{
|
||||
echo json_encode($e);
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "(".json_encode($e).");";
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'getReplaceValue':
|
||||
try
|
||||
{
|
||||
$field_nameValue = $jinput->get('field_name', NULL, 'WORD');
|
||||
$row_idValue = $jinput->get('row_id', NULL, 'INT');
|
||||
$line_nrValue = $jinput->get('line_nr', 0, 'STRING');
|
||||
$table_nameValue = $jinput->get('table_name', NULL, 'WORD');
|
||||
$search_valueValue = $jinput->get('search_value', NULL, 'RAW');
|
||||
$replace_valueValue = $jinput->get('replace_value', NULL, 'RAW');
|
||||
$match_caseValue = $jinput->get('match_case', 0, 'INT');
|
||||
$whole_wordValue = $jinput->get('whole_word', 0, 'INT');
|
||||
$regex_searchValue = $jinput->get('regex_search', 0, 'INT');
|
||||
if($field_nameValue && $user->id != 0 && $row_idValue && $table_nameValue && $search_valueValue)
|
||||
{
|
||||
$result = $this->getModel('ajax')->getReplaceValue($field_nameValue, $row_idValue, $line_nrValue, $table_nameValue, $search_valueValue, $replace_valueValue, $match_caseValue, $whole_wordValue, $regex_searchValue);
|
||||
}
|
||||
else
|
||||
{
|
||||
$result = false;
|
||||
}
|
||||
if($callback)
|
||||
{
|
||||
echo $callback . "(".json_encode($result).");";
|
||||
}
|
||||
elseif($returnRaw)
|
||||
{
|
||||
echo json_encode($result);
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "(".json_encode($result).");";
|
||||
}
|
||||
}
|
||||
catch(Exception $e)
|
||||
{
|
||||
if($callback)
|
||||
{
|
||||
echo $callback."(".json_encode($e).");";
|
||||
}
|
||||
elseif($returnRaw)
|
||||
{
|
||||
echo json_encode($e);
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "(".json_encode($e).");";
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'setValue':
|
||||
try
|
||||
{
|
||||
$valueValue = $jinput->get('value', NULL, 'RAW');
|
||||
$row_idValue = $jinput->get('row_id', NULL, 'INT');
|
||||
$field_nameValue = $jinput->get('field_name', NULL, 'WORD');
|
||||
$table_nameValue = $jinput->get('table_name', NULL, 'WORD');
|
||||
if($valueValue && $user->id != 0 && $row_idValue && $field_nameValue && $table_nameValue)
|
||||
{
|
||||
$result = $this->getModel('ajax')->setValue($valueValue, $row_idValue, $field_nameValue, $table_nameValue);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -51,7 +51,7 @@ class ComponentbuilderControllerCompiler extends AdminController
|
||||
*
|
||||
* @return true on success
|
||||
*/
|
||||
public function getCompilerAnimations()
|
||||
public function getDynamicContent()
|
||||
{
|
||||
// Check for request forgeries
|
||||
JSession::checkToken() or jexit(JText::_('JINVALID_TOKEN'));
|
||||
@ -65,7 +65,7 @@ class ComponentbuilderControllerCompiler extends AdminController
|
||||
{
|
||||
// get the model
|
||||
$model = $this->getModel('compiler');
|
||||
if ($model->getCompilerAnimations($message))
|
||||
if ($model->getDynamicContent($message))
|
||||
{
|
||||
$message = JText::_('COM_COMPONENTBUILDER_BALL_THE_COMPILER_ANIMATIONS_WERE_SUCCESSFULLY_DOWNLOADED_TO_THIS_JOOMLA_INSTALLB');
|
||||
$this->setRedirect($redirect_url, $message, 'message');
|
||||
@ -171,19 +171,19 @@ class ComponentbuilderControllerCompiler extends AdminController
|
||||
}
|
||||
$message[] = '<h2>Total time saved</h2>';
|
||||
$message[] = '<ul>';
|
||||
$message[] = '<li>Total folders created: <b>'.$model->compiler->folderCount.'</b></li>';
|
||||
$message[] = '<li>Total files created: <b>'.$model->compiler->fileCount.'</b></li>';
|
||||
$message[] = '<li>Total fields created: <b>'.$model->compiler->fieldCount.'</b></li>';
|
||||
$message[] = '<li>Total lines written: <b>'.$model->compiler->lineCount.'</b></li>';
|
||||
$message[] = '<li>A4 Book of: <b>'.$model->compiler->pageCount.' pages</b></li>';
|
||||
$message[] = '<li>Total folders created: <b>#'.'##FOLDER_COUNT##'.'#</b></li>';
|
||||
$message[] = '<li>Total files created: <b>#'.'##FILE_COUNT##'.'#</b></li>';
|
||||
$message[] = '<li>Total fields created: <b>#'.'##FIELD_COUNT##'.'#</b></li>';
|
||||
$message[] = '<li>Total lines written: <b>#'.'##LINE_COUNT##'.'#</b></li>';
|
||||
$message[] = '<li>A4 Book of: <b>#'.'##PAGE_COUNT##'.'# pages</b></li>';
|
||||
$message[] = '</ul>';
|
||||
$message[] = '<p><b>'.$model->compiler->totalHours.' Hours</b> or <b>'.$model->compiler->totalDays.' Eight Hour Days</b> <em>(actual time you saved)</em><br />';
|
||||
$message[] = '<p><b>#'.'##totalHours##'.'# Hours</b> or <b>#'.'##totalDays##'.'# Eight Hour Days</b> <em>(actual time you saved)</em><br />';
|
||||
$message[] = '<small>(if creating a folder and file took <b>5 seconds</b> and writing one line of code took <b>10 seconds</b>, never making one mistake or taking any coffee break.)</small><br />';
|
||||
$message[] = '<b>'.$model->compiler->actualHoursSpent.' Hours</b> or <b>'.$model->compiler->actualDaysSpent.' Eight Hour Days</b> <em>(the actual time you spent)</em><br />';
|
||||
$message[] = '<small>(with the following break down: <b>debugging @'.$model->compiler->debuggingHours.'hours</b> = codingtime / 4; <b>planning @'.$model->compiler->planningHours.'hours</b> = codingtime / 7; <b>mapping @'.$model->compiler->mappingHours.'hours</b> = codingtime / 10; <b>office @'.$model->compiler->officeHours.'hours</b> = codingtime / 6;)</small></p>';
|
||||
$message[] = '<p><b>'.$model->compiler->actualTotalHours.' Hours</b> or <b>'.$model->compiler->actualTotalDays.' Eight Hour Days</b> <em>(a total of the realistic time frame for this project)</em><br />';
|
||||
$message[] = '<b>#'.'##actualHoursSpent##'.'# Hours</b> or <b>#'.'##actualDaysSpent##'.'# Eight Hour Days</b> <em>(the actual time you spent)</em><br />';
|
||||
$message[] = '<small>(with the following break down: <b>debugging @#'.'##debuggingHours##'.'#hours</b> = codingtime / 4; <b>planning @#'.'##planningHours##'.'#hours</b> = codingtime / 7; <b>mapping @#'.'##mappingHours##'.'#hours</b> = codingtime / 10; <b>office @#'.'##officeHours##'.'#hours</b> = codingtime / 6;)</small></p>';
|
||||
$message[] = '<p><b>#'.'##actualTotalHours##'.'# Hours</b> or <b>#'.'##actualTotalDays##'.'# Eight Hour Days</b> <em>(a total of the realistic time frame for this project)</em><br />';
|
||||
$message[] = '<small>(if creating a folder and file took <b>5 seconds</b> and writing one line of code took <b>10 seconds</b>, with the normal everyday realities at the office, that includes the component planning, mapping & debugging.)</small></p>';
|
||||
$message[] = '<p>Project duration: <b>'.$model->compiler->projectWeekTime. ' weeks</b> or <b>'.$model->compiler->projectMonthTime.' months</b></p>';
|
||||
$message[] = '<p>Project duration: <b>'.$model->compiler->projectWeekTime. ' weeks</b> or <b>#'.'##projectMonthTime##'.'# months</b></p>';
|
||||
// check if we have modules or plugins
|
||||
if ($add_multi_install)
|
||||
{
|
||||
@ -254,9 +254,14 @@ class ComponentbuilderControllerCompiler extends AdminController
|
||||
$message[] = '<a class="btn btn-success" href="' . $url . '" ><span class="icon-download icon-white"></span>Download</a></p>';
|
||||
$message[] = '<p><small><b>Remember!</b> This zip file is in your tmp folder and therefore publicly accessible until you click [Clear tmp]!</small> </p>';
|
||||
}
|
||||
$message[] = '<p><small>Compilation took <b>'.$model->compiler->secondsCompiled.'</b> seconds to complete.</small> </p>';
|
||||
$message[] = '<p><small>Compilation took <b>#'.'##COMPILER_TIMER##'.'#</b> seconds to complete.</small> </p>';
|
||||
// pass the message via the user state... wow this is painful
|
||||
$app->setUserState('com_componentbuilder.success_message', implode(PHP_EOL, $message));
|
||||
$app->setUserState('com_componentbuilder.success_message',
|
||||
CFactory::_('Placeholder')->update(
|
||||
implode(PHP_EOL, $message),
|
||||
CFactory::_('Content')->active
|
||||
)
|
||||
);
|
||||
// set redirect
|
||||
$this->setRedirect($redirect_url, '<h2>Successful Build!</h2>', 'message');
|
||||
$app->setUserState('com_componentbuilder.component_folder_name', $model->compiler->filepath['component-folder']);
|
||||
|
@ -14,6 +14,7 @@ defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use Joomla\CMS\MVC\Controller\BaseController;
|
||||
use Joomla\Utilities\ArrayHelper;
|
||||
use VDM\Joomla\Componentbuilder\Package\Factory as PackageFactory;
|
||||
|
||||
/**
|
||||
* Componentbuilder Import_joomla_components Base Controller
|
||||
|
@ -14,6 +14,10 @@ defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use Joomla\CMS\MVC\Controller\AdminController;
|
||||
use Joomla\Utilities\ArrayHelper;
|
||||
use VDM\Joomla\Componentbuilder\Package\Factory as PackageFactory;
|
||||
use VDM\Joomla\Utilities\ArrayHelper as JCBArrayHelper;
|
||||
use VDM\Joomla\Utilities\StringHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
|
||||
/**
|
||||
* Joomla_components Admin Controller
|
||||
@ -198,12 +202,12 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
$session->set('backto_VDM_IMPORT', 'joomla_components');
|
||||
$session->set('dataType_VDM_IMPORTINTO', 'smart_package');
|
||||
// Redirect to import view.
|
||||
$message = JText::_('COM_COMPONENTBUILDER_YOU_CAN_NOW_SELECT_THE_COMPONENT_BZIPB_PACKAGE_YOU_WOULD_LIKE_TO_IMPORTBR_SMALLPLEASE_NOTE_THAT_SMART_COMPONENT_IMPORT_ONLY_WORKS_WITH_THE_FOLLOWING_FORMAT_BZIPBSMALL');
|
||||
$message = Text::_('COM_COMPONENTBUILDER_YOU_CAN_NOW_SELECT_THE_COMPONENT_BZIPB_PACKAGE_YOU_WOULD_LIKE_TO_IMPORTBR_SMALLPLEASE_NOTE_THAT_SMART_COMPONENT_IMPORT_ONLY_WORKS_WITH_THE_FOLLOWING_FORMAT_BZIPBSMALL');
|
||||
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=import_joomla_components&target=smartPackage', false), $message);
|
||||
return;
|
||||
}
|
||||
// Redirect to the list screen with error.
|
||||
$message = JText::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_IMPORT_A_COMPONENT_PLEASE_CONTACT_YOUR_SYSTEM_ADMINISTRATOR_FOR_MORE_HELP');
|
||||
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_IMPORT_A_COMPONENT_PLEASE_CONTACT_YOUR_SYSTEM_ADMINISTRATOR_FOR_MORE_HELP');
|
||||
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=joomla_components', false), $message, 'error');
|
||||
return;
|
||||
}
|
||||
@ -211,7 +215,7 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
public function smartExport()
|
||||
{
|
||||
// Check for request forgeries
|
||||
JSession::checkToken() or die(JText::_('JINVALID_TOKEN'));
|
||||
JSession::checkToken() or die(Text::_('JINVALID_TOKEN'));
|
||||
// Get the model
|
||||
$model = $this->getModel('Joomla_components');
|
||||
// check if export is allowed for this user.
|
||||
@ -224,10 +228,10 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
// Sanitize the input
|
||||
JArrayHelper::toInteger($pks);
|
||||
// check if there is any selections
|
||||
if (!ComponentbuilderHelper::checkArray($pks))
|
||||
if (!JCBArrayHelper::check($pks))
|
||||
{
|
||||
// Redirect to the list screen with error.
|
||||
$message = JText::_('COM_COMPONENTBUILDER_NO_COMPONENTS_WERE_SELECTED_PLEASE_MAKE_A_SELECTION_AND_TRY_AGAIN');
|
||||
$message = Text::_('COM_COMPONENTBUILDER_NO_COMPONENTS_WERE_SELECTED_PLEASE_MAKE_A_SELECTION_AND_TRY_AGAIN');
|
||||
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=joomla_components', false), $message, 'error');
|
||||
return;
|
||||
}
|
||||
@ -237,43 +241,44 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
if ($model->getSmartExport($pks))
|
||||
{
|
||||
// set the key string
|
||||
if (componentbuilderHelper::checkString($model->key) && strlen($model->key) == 32)
|
||||
if (StringHelper::check($model->key) && strlen($model->key) == 32)
|
||||
{
|
||||
$keyNotice = '<h1>' . JText::sprintf('COM_COMPONENTBUILDER_THE_PACKAGE_KEY_IS_CODESCODE', $model->key) . '</h1>';
|
||||
$keyNotice .= '<p>' . JText::_('COM_COMPONENTBUILDER_YOUR_DATA_IS_ENCRYPTED_WITH_A_AES_ONE_HUNDRED_AND_TWENTY_EIGHT_BIT_ENCRYPTION_USING_THE_ABOVE_THIRTY_TWO_CHARACTER_KEY') . '</h1>';
|
||||
$keyNotice = '<h1>' . Text::sprintf('COM_COMPONENTBUILDER_THE_PACKAGE_KEY_IS_CODESCODE', $model->key) . '</h1>';
|
||||
$keyNotice .= '<p>' . Text::_('COM_COMPONENTBUILDER_YOUR_DATA_IS_ENCRYPTED_WITH_A_AES_TWO_HUNDRED_AND_FIFTY_SIX_BIT_ENCRYPTION_USING_THE_ABOVE_THIRTY_TWO_CHARACTER_KEY') . '</p>';
|
||||
|
||||
// set the package owner info
|
||||
if (componentbuilderHelper::getPackageOwnerValue('owner', $model->info) || componentbuilderHelper::getPackageOwnerValue('company', $model->info))
|
||||
if (PackageFactory::_('Display.Details')->hasOwner($model->info))
|
||||
{
|
||||
$ownerDetails = componentbuilderHelper::getPackageOwnerDetailsDisplay($model->info, true);
|
||||
$ownerDetails = PackageFactory::_('Display.Details')->owner($model->info, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
$ownerDetails = '<h2>' . JText::_('COM_COMPONENTBUILDER_PACKAGE_OWNER_NOT_SET') . '</h2>';
|
||||
$ownerDetails .= '<p>' . JText::_('COM_COMPONENTBUILDER_TO_CHANGE_THE_PACKAGE_OWNER_DEFAULTS_OPEN_THE_BJCB_GLOBAL_OPTIONSB_GO_TO_THE_BCOMPANYB_TAB_AND_ADD_THE_CORRECT_COMPANY_DETAILS_THERE') . '</p>';
|
||||
$ownerDetails .= '<h3>' . JText::_('COM_COMPONENTBUILDER_YOU_SHOULD_ADD_THE_CORRECT_OWNER_DETAILS') . '</h3>';
|
||||
$ownerDetails .= '<p>' . JText::_('COM_COMPONENTBUILDER_SINCE_THE_OWNER_DETAILS_ARE_DISPLAYED_DURING_BIMPORT_PROCESSB_BEFORE_ADDING_THE_KEY_THIS_WAY_IF_THE_USERDEV_BDOES_NOTB_HAVE_THE_KEY_THEY_CAN_SEE_BWHERE_TO_GET_ITB') . '</p>';
|
||||
$ownerDetails = '<h2>' . Text::_('COM_COMPONENTBUILDER_PACKAGE_OWNER_NOT_SET') . '</h2>';
|
||||
$ownerDetails .= '<p>' . Text::_('COM_COMPONENTBUILDER_TO_CHANGE_THE_PACKAGE_OWNER_DEFAULTS_OPEN_THE_BJCB_GLOBAL_OPTIONSB_GO_TO_THE_BCOMPANYB_TAB_AND_ADD_THE_CORRECT_COMPANY_DETAILS_THERE') . '</p>';
|
||||
$ownerDetails .= '<h3>' . Text::_('COM_COMPONENTBUILDER_YOU_SHOULD_ADD_THE_CORRECT_OWNER_DETAILS') . '</h3>';
|
||||
$ownerDetails .= '<p>' . Text::_('COM_COMPONENTBUILDER_SINCE_THE_OWNER_DETAILS_ARE_DISPLAYED_DURING_BIMPORT_PROCESSB_BEFORE_ADDING_THE_KEY_THIS_WAY_IF_THE_USERDEV_BDOES_NOTB_HAVE_THE_KEY_THEY_CAN_SEE_BWHERE_TO_GET_ITB') . '</p>';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$keyNotice = '<h1>' . JText::_('COM_COMPONENTBUILDER_THIS_PACKAGE_HAS_NO_KEY') . '</h1>';
|
||||
$ownerDetails = '<p>' . JText::_('COM_COMPONENTBUILDER_THAT_MEANS_ANYONE_WHO_HAS_THIS_PACKAGE_CAN_INSTALL_IT_INTO_JCB_TO_ADD_AN_EXPORT_KEY_SIMPLY_OPEN_THE_COMPONENT_GO_TO_THE_TAB_CALLED_BSETTINGSB_BOTTOM_RIGHT_THERE_IS_A_FIELD_CALLED_BEXPORT_KEYB') . '</p>';
|
||||
$keyNotice = '<h1>' . Text::_('COM_COMPONENTBUILDER_THIS_PACKAGE_HAS_NO_KEY') . '</h1>';
|
||||
$ownerDetails = '<p>' . Text::_('COM_COMPONENTBUILDER_THAT_MEANS_ANYONE_WHO_HAS_THIS_PACKAGE_CAN_INSTALL_IT_INTO_JCB_TO_ADD_AN_EXPORT_KEY_SIMPLY_OPEN_THE_COMPONENT_GO_TO_THE_TAB_CALLED_BSETTINGSB_BOTTOM_RIGHT_THERE_IS_A_FIELD_CALLED_BEXPORT_KEYB') . '</p>';
|
||||
}
|
||||
// Redirect to the list screen with success.
|
||||
$message = array();
|
||||
$message[] = '<h1>' . JText::_('COM_COMPONENTBUILDER_EXPORT_COMPLETED') . '</h1>';
|
||||
$message[] = '<h1>' . Text::_('COM_COMPONENTBUILDER_EXPORT_COMPLETED') . '</h1>';
|
||||
$message[] = '<p>' . JText::sprintf('COM_COMPONENTBUILDER_PATH_TO_THE_ZIPPED_PACKAGE_IS_CODESCODE_BR_S_S', $model->zipPath, $keyNotice, $ownerDetails) . '</p>';
|
||||
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=joomla_components', false), implode('', $message), 'Success');
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (componentbuilderHelper::checkString($model->packagePath))
|
||||
if (StringHelper::check($model->packagePath))
|
||||
{
|
||||
// clear all if not successful
|
||||
ComponentbuilderHelper::removeFolder($model->packagePath);
|
||||
}
|
||||
if (componentbuilderHelper::checkString($model->zipPath))
|
||||
if (StringHelper::check($model->zipPath))
|
||||
{
|
||||
// clear all if not successful
|
||||
JFile::delete($model->zipPath);
|
||||
@ -281,7 +286,7 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
}
|
||||
}
|
||||
// Redirect to the list screen with error.
|
||||
$message = JText::_('COM_COMPONENTBUILDER_EXPORT_FAILED_PLEASE_TRY_AGAIN_LATTER');
|
||||
$message = Text::_('COM_COMPONENTBUILDER_EXPORT_FAILED_PLEASE_TRY_AGAIN_LATTER');
|
||||
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=joomla_components', false), $message, 'error');
|
||||
return;
|
||||
}
|
||||
@ -318,8 +323,8 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
{
|
||||
$textNotice = array();
|
||||
$keyNotice = '<h1>' . JText::sprintf('COM_COMPONENTBUILDER_THE_PACKAGE_KEY_IS_CODESCODE', $model->key) . '</h1>';
|
||||
$keyNotice .= '<p>' . JText::_('COM_COMPONENTBUILDER_YOUR_DATA_IS_ENCRYPTED_WITH_A_AES_TWO_HUNDRED_AND_FIFTY_SIX_BIT_ENCRYPTION_USING_THE_ABOVE_THIRTY_TWO_CHARACTER_KEY') . '</p>';
|
||||
$textNotice[] = JText::sprintf('COM_COMPONENTBUILDER_THE_PACKAGE_KEY_IS_S', $model->key);
|
||||
$keyNotice .= JText::_('COM_COMPONENTBUILDER_YOUR_DATA_IS_ENCRYPTED_WITH_A_AES_ONE_HUNDRED_AND_TWENTY_EIGHT_BIT_ENCRYPTION_USING_THE_ABOVE_THIRTY_TWO_CHARACTER_KEY_WITHOUT_THIS_KEY_IT_WILL_TAKE_THE_CURRENT_TECHNOLOGY_WITH_A_BRUTE_FORCE_ATTACK_METHOD_MORE_THEN_A_HREFHTTPRANDOMIZECOMHOWLONGTOHACKPASS_TARGET_BLANK_TITLEHOW_LONG_TO_HACK_PASSSEVEN_HUNDRED_ZERO_ZERO_ZERO_ZERO_ZERO_ZERO_ZERO_ZERO_ZERO_ZEROA_YEARS_TO_CRACK_THEORETICALLY_UNLESS_THEY_HAVE_THIS_KEY_ABOVE_SO_DO_KEEP_IT_SAFE') . '<br />';
|
||||
// set the package owner info
|
||||
if ((isset($model->info['getKeyFrom']['company']) && componentbuilderHelper::checkString($model->info['getKeyFrom']['company'])) || (isset($model->info['getKeyFrom']['owner']) && componentbuilderHelper::checkString($model->info['getKeyFrom']['owner'])))
|
||||
{
|
||||
@ -449,7 +454,7 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
public function cloner()
|
||||
{
|
||||
// Check for request forgeries
|
||||
JSession::checkToken() or die(JText::_('JINVALID_TOKEN'));
|
||||
JSession::checkToken() or die(Text::_('JINVALID_TOKEN'));
|
||||
// Get the model
|
||||
$model = $this->getModel('Joomla_components');
|
||||
// check if export is allowed for this user.
|
||||
@ -462,10 +467,10 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
// Sanitize the input
|
||||
JArrayHelper::toInteger($pks);
|
||||
// check if there is any selections
|
||||
if (!ComponentbuilderHelper::checkArray($pks))
|
||||
if (!JCBArrayHelper::check($pks))
|
||||
{
|
||||
// Redirect to the list screen with error.
|
||||
$message = JText::_('COM_COMPONENTBUILDER_NO_COMPONENT_WAS_SELECTED_PLEASE_MAKE_A_SELECTION_OF_ONE_COMPONENT_AND_TRY_AGAIN');
|
||||
$message = Text::_('COM_COMPONENTBUILDER_NO_COMPONENT_WAS_SELECTED_PLEASE_MAKE_A_SELECTION_OF_ONE_COMPONENT_AND_TRY_AGAIN');
|
||||
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=joomla_components', false), $message, 'error');
|
||||
return;
|
||||
}
|
||||
@ -473,7 +478,7 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
elseif (count( (array) $pks) !== 1)
|
||||
{
|
||||
// Redirect to the list screen with error.
|
||||
$message = JText::_('COM_COMPONENTBUILDER_ONLY_ONE_COMPONENT_CAN_BE_CLONED_AT_A_TIME_PLEASE_SELECT_ONE_AND_TRY_AGAIN');
|
||||
$message = Text::_('COM_COMPONENTBUILDER_ONLY_ONE_COMPONENT_CAN_BE_CLONED_AT_A_TIME_PLEASE_SELECT_ONE_AND_TRY_AGAIN');
|
||||
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=joomla_components', false), $message, 'error');
|
||||
return;
|
||||
}
|
||||
@ -483,17 +488,17 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
if ($model->cloner($pks))
|
||||
{
|
||||
// clone was successful
|
||||
$message = JText::_('COM_COMPONENTBUILDER_THE_COMPONENT_WITH_ALL_LINKED_ADMIN_VIEWS_FIELDS_LINKED_TO_ADMIN_VIEWS_CUSTOM_ADMIN_VIEWS_SITE_VIEWS_TEMPLATES_AND_LAYOUTS_WERE_CLONED_SUCCESSFUL');
|
||||
$message = Text::_('COM_COMPONENTBUILDER_THE_COMPONENT_WITH_ALL_LINKED_ADMIN_VIEWS_FIELDS_LINKED_TO_ADMIN_VIEWS_CUSTOM_ADMIN_VIEWS_SITE_VIEWS_TEMPLATES_AND_LAYOUTS_WERE_CLONED_SUCCESSFUL');
|
||||
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=joomla_components', false), $message);
|
||||
return;
|
||||
}
|
||||
// Redirect to the list screen with error.
|
||||
$message = JText::_('COM_COMPONENTBUILDER_CLONE_FAILED');
|
||||
$message = Text::_('COM_COMPONENTBUILDER_CLONE_FAILED');
|
||||
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=joomla_components', false), $message, 'error');
|
||||
return;
|
||||
}
|
||||
// Redirect to the list screen with error.
|
||||
$message = JText::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_CLONE_A_COMPONENT_PLEASE_CONTACT_YOUR_SYSTEM_ADMINISTRATOR_FOR_MORE_HELP');
|
||||
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_CLONE_A_COMPONENT_PLEASE_CONTACT_YOUR_SYSTEM_ADMINISTRATOR_FOR_MORE_HELP');
|
||||
$this->setRedirect(JRoute::_('index.php?option=com_componentbuilder&view=joomla_components', false), $message, 'error');
|
||||
return;
|
||||
}
|
||||
@ -502,5 +507,6 @@ class ComponentbuilderControllerJoomla_components extends AdminController
|
||||
{
|
||||
// admin area does not have API user, only front-end (so we fallback on login user)
|
||||
return JFactory::getUser();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -19,6 +19,7 @@ use VDM\Joomla\Utilities\StringHelper;
|
||||
use VDM\Joomla\Utilities\ArrayHelper;
|
||||
use VDM\Joomla\Utilities\ObjectHelper;
|
||||
use VDM\Joomla\Utilities\FileHelper;
|
||||
use VDM\Joomla\Utilities\GetHelper;
|
||||
use VDM\Joomla\Utilities\MathHelper;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Factory as CFactory;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Utilities\Placefix;
|
||||
@ -30,11 +31,11 @@ ComponentbuilderHelper::autoLoader();
|
||||
|
||||
/**
|
||||
* Compiler class
|
||||
* @deprecated 3.3
|
||||
*/
|
||||
class Compiler extends Infusion
|
||||
{
|
||||
|
||||
|
||||
/**
|
||||
* The Temp path
|
||||
*
|
||||
@ -79,7 +80,8 @@ class Compiler extends Infusion
|
||||
{
|
||||
// to check the compiler speed
|
||||
$this->time_start = microtime(true);
|
||||
// first we run the perent constructors
|
||||
CFactory::_('Utilities.Counter')->start();
|
||||
// first we run the parent constructors
|
||||
if (parent::__construct())
|
||||
{
|
||||
// set temp directory
|
||||
@ -99,33 +101,33 @@ class Compiler extends Infusion
|
||||
$this->repoPath = $this->params->get('git_folder_path', null);
|
||||
}
|
||||
// remove site folder if not needed (TODO add check if custom script was moved to site folder then we must do a more complex cleanup here)
|
||||
if ($this->removeSiteFolder && $this->removeSiteEditFolder)
|
||||
if (CFactory::_('Config')->remove_site_folder && CFactory::_('Config')->remove_site_edit_folder)
|
||||
{
|
||||
// first remove the files and folders
|
||||
$this->removeFolder($this->componentPath . '/site');
|
||||
CFactory::_('Utilities.Folder')->remove(CFactory::_('Utilities.Paths')->component_path . '/site');
|
||||
// clear form component xml
|
||||
$xmlPath = $this->componentPath . '/'
|
||||
. $this->fileContentStatic[Placefix::_h('component')] . '.xml';
|
||||
$componentXML = ComponentbuilderHelper::getFileContents(
|
||||
$xmlPath
|
||||
);
|
||||
$textToSite = ComponentbuilderHelper::getBetween(
|
||||
$xmlPath = CFactory::_('Utilities.Paths')->component_path . '/'
|
||||
. CFactory::_('Content')->get('component') . '.xml';
|
||||
$componentXML = FileHelper::getContent($xmlPath);
|
||||
$textToSite = GetHelper::between(
|
||||
$componentXML, '<files folder="site">', '</files>'
|
||||
);
|
||||
$textToSiteLang = ComponentbuilderHelper::getBetween(
|
||||
$textToSiteLang = GetHelper::between(
|
||||
$componentXML, '<languages folder="site">', '</languages>'
|
||||
);
|
||||
$componentXML = str_replace(
|
||||
array('<files folder="site">' . $textToSite . "</files>",
|
||||
'<languages folder="site">' . $textToSiteLang
|
||||
. "</languages>"), array('', ''), $componentXML
|
||||
. "</languages>"), array('', ''), (string) $componentXML
|
||||
);
|
||||
$this->writeFile($xmlPath, $componentXML);
|
||||
CFactory::_('Utilities.File')->write($xmlPath, $componentXML);
|
||||
}
|
||||
// for plugin event TODO change event api signatures
|
||||
$component_context = CFactory::_('Config')->component_context;
|
||||
// Trigger Event: jcb_ce_onBeforeUpdateFiles
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onBeforeUpdateFiles',
|
||||
array(&$this->componentContext, &$this)
|
||||
array(&$component_context, &$this)
|
||||
);
|
||||
// now update the files
|
||||
if (!$this->updateFiles())
|
||||
@ -135,7 +137,7 @@ class Compiler extends Infusion
|
||||
// Trigger Event: jcb_ce_onBeforeGetCustomCode
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onBeforeGetCustomCode',
|
||||
array(&$this->componentContext, &$this)
|
||||
array(&$component_context, &$this)
|
||||
);
|
||||
// now insert into the new files
|
||||
if (CFactory::_('Customcode')->get())
|
||||
@ -143,7 +145,7 @@ class Compiler extends Infusion
|
||||
// Trigger Event: jcb_ce_onBeforeAddCustomCode
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onBeforeAddCustomCode',
|
||||
array(&$this->componentContext, &$this)
|
||||
array(&$component_context, &$this)
|
||||
);
|
||||
|
||||
$this->addCustomCode();
|
||||
@ -151,7 +153,7 @@ class Compiler extends Infusion
|
||||
// Trigger Event: jcb_ce_onBeforeSetLangFileData
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onBeforeSetLangFileData',
|
||||
array(&$this->componentContext, &$this)
|
||||
array(&$component_context, &$this)
|
||||
);
|
||||
// set the lang data now
|
||||
$this->setLangFileData();
|
||||
@ -218,13 +220,15 @@ class Compiler extends Infusion
|
||||
$message_fix['sql'] = JText::_(
|
||||
'The <b>SQL</b> fix updates the #__assets table\'s column size on installation of the component and reverses it back to the Joomla default on uninstall of the component.'
|
||||
);
|
||||
// get the asset table fix switch
|
||||
$add_assets_table_fix = CFactory::_('Config')->get('add_assets_table_fix', 0);
|
||||
// set assets table rules column notice
|
||||
if (CFactory::_('Config')->add_assets_table_fix)
|
||||
if ($add_assets_table_fix)
|
||||
{
|
||||
$this->app->enqueueMessage(
|
||||
JText::_('<hr /><h3>Assets Table Notice</h3>'), 'Notice'
|
||||
);
|
||||
$asset_table_fix_type = (CFactory::_('Config')->add_assets_table_fix == 2)
|
||||
$asset_table_fix_type = ($add_assets_table_fix == 2)
|
||||
? 'intelligent' : 'sql';
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf(
|
||||
@ -243,13 +247,13 @@ class Compiler extends Infusion
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf(
|
||||
'The Joomla #__assets table\'s rules column has to be fixed for this component to work coherently. JCB has detected that in worse case the rules column in the #__assets table may require <b>%s</b> characters, and yet the Joomla default is only <b>varchar(5120)</b>. JCB has three option to resolve this issue, first <b>use less permissions</b> in your component, second use the <b>SQL</b> fix, or the <b>intelligent</b> fix. %s %s',
|
||||
$this->accessWorseCase, $message_fix['intelligent'],
|
||||
CFactory::_('Config')->access_worse_case, $message_fix['intelligent'],
|
||||
$message_fix['sql']
|
||||
), 'Warning'
|
||||
);
|
||||
}
|
||||
// set assets table name column warning if not set
|
||||
if (!CFactory::_('Config')->add_assets_table_fix && $this->addAssetsTableNameFix)
|
||||
if (!$add_assets_table_fix && CFactory::_('Config')->add_assets_table_name_fix)
|
||||
{
|
||||
// only add if not already added
|
||||
if ($this->accessSize < 30)
|
||||
@ -269,8 +273,6 @@ class Compiler extends Infusion
|
||||
}
|
||||
// move the update server into place
|
||||
$this->setUpdateServer();
|
||||
// set the global counters
|
||||
$this->setCountingStuff();
|
||||
// build read me
|
||||
$this->buildReadMe();
|
||||
// set local repos
|
||||
@ -361,6 +363,7 @@ class Compiler extends Infusion
|
||||
// end the timer here
|
||||
$this->time_end = microtime(true);
|
||||
$this->secondsCompiled = $this->time_end - $this->time_start;
|
||||
CFactory::_('Utilities.Counter')->end();
|
||||
|
||||
// completed the compilation
|
||||
return true;
|
||||
@ -377,15 +380,13 @@ class Compiler extends Infusion
|
||||
*/
|
||||
protected function updateFiles()
|
||||
{
|
||||
if (isset($this->newFiles['static'])
|
||||
&& ArrayHelper::check($this->newFiles['static'])
|
||||
&& isset($this->newFiles['dynamic'])
|
||||
&& ArrayHelper::check($this->newFiles['dynamic']))
|
||||
if (CFactory::_('Utilities.Files')->exists('static')
|
||||
&& CFactory::_('Utilities.Files')->exists('dynamic'))
|
||||
{
|
||||
// get the bom file
|
||||
$bom = ComponentbuilderHelper::getFileContents($this->bomPath);
|
||||
$bom = FileHelper::getContent(CFactory::_('Config')->bom_path);
|
||||
// first we do the static files
|
||||
foreach ($this->newFiles['static'] as $static)
|
||||
foreach (CFactory::_('Utilities.Files')->get('static') as $static)
|
||||
{
|
||||
if (File::exists($static['path']))
|
||||
{
|
||||
@ -395,11 +396,11 @@ class Compiler extends Infusion
|
||||
}
|
||||
}
|
||||
// now we do the dynamic files
|
||||
foreach ($this->newFiles['dynamic'] as $view => $files)
|
||||
foreach (CFactory::_('Utilities.Files')->get('dynamic') as $view => $files)
|
||||
{
|
||||
if (isset($this->fileContentDynamic[$view])
|
||||
if (CFactory::_('Content')->exist_($view)
|
||||
&& ArrayHelper::check(
|
||||
$this->fileContentDynamic[$view]
|
||||
CFactory::_('Content')->get_($view)
|
||||
))
|
||||
{
|
||||
foreach ($files as $file)
|
||||
@ -417,20 +418,17 @@ class Compiler extends Infusion
|
||||
}
|
||||
}
|
||||
// free up some memory
|
||||
unset($this->fileContentDynamic[$view]);
|
||||
CFactory::_('Content')->remove_($view);
|
||||
}
|
||||
// free up some memory
|
||||
unset($this->newFiles['dynamic']);
|
||||
CFactory::_('Utilities.Files')->remove('dynamic');
|
||||
// do modules if found
|
||||
if (ArrayHelper::check($this->joomlaModules))
|
||||
if (CFactory::_('Joomlamodule.Data')->exists())
|
||||
{
|
||||
foreach ($this->joomlaModules as $module)
|
||||
foreach (CFactory::_('Joomlamodule.Data')->get() as $module)
|
||||
{
|
||||
if (ObjectHelper::check($module)
|
||||
&& isset($this->newFiles[$module->key])
|
||||
&& ArrayHelper::check(
|
||||
$this->newFiles[$module->key]
|
||||
))
|
||||
&& CFactory::_('Utilities.Files')->exists($module->key))
|
||||
{
|
||||
// move field or rule if needed
|
||||
if (isset($module->fields_rules_paths)
|
||||
@ -486,7 +484,7 @@ class Compiler extends Infusion
|
||||
}
|
||||
}
|
||||
// update the module files
|
||||
foreach ($this->newFiles[$module->key] as $module_file)
|
||||
foreach (CFactory::_('Utilities.Files')->get($module->key) as $module_file)
|
||||
{
|
||||
if (File::exists($module_file['path']))
|
||||
{
|
||||
@ -497,21 +495,18 @@ class Compiler extends Infusion
|
||||
}
|
||||
}
|
||||
// free up some memory
|
||||
unset($this->newFiles[$module->key]);
|
||||
unset($this->fileContentDynamic[$module->key]);
|
||||
CFactory::_('Utilities.Files')->remove($module->key);
|
||||
CFactory::_('Content')->remove_($module->key);
|
||||
}
|
||||
}
|
||||
}
|
||||
// do plugins if found
|
||||
if (ArrayHelper::check($this->joomlaPlugins))
|
||||
if (CFactory::_('Joomlaplugin.Data')->exists())
|
||||
{
|
||||
foreach ($this->joomlaPlugins as $plugin)
|
||||
foreach (CFactory::_('Joomlaplugin.Data')->get() as $plugin)
|
||||
{
|
||||
if (ObjectHelper::check($plugin)
|
||||
&& isset($this->newFiles[$plugin->key])
|
||||
&& ArrayHelper::check(
|
||||
$this->newFiles[$plugin->key]
|
||||
))
|
||||
&& CFactory::_('Utilities.Files')->exists($plugin->key))
|
||||
{
|
||||
// move field or rule if needed
|
||||
if (isset($plugin->fields_rules_paths)
|
||||
@ -567,7 +562,7 @@ class Compiler extends Infusion
|
||||
}
|
||||
}
|
||||
// update the plugin files
|
||||
foreach ($this->newFiles[$plugin->key] as $plugin_file)
|
||||
foreach (CFactory::_('Utilities.Files')->get($plugin->key) as $plugin_file)
|
||||
{
|
||||
if (File::exists($plugin_file['path']))
|
||||
{
|
||||
@ -578,8 +573,8 @@ class Compiler extends Infusion
|
||||
}
|
||||
}
|
||||
// free up some memory
|
||||
unset($this->newFiles[$plugin->key]);
|
||||
unset($this->fileContentDynamic[$plugin->key]);
|
||||
CFactory::_('Utilities.Files')->remove($plugin->key);
|
||||
CFactory::_('Content')->remove_($plugin->key);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -589,13 +584,10 @@ class Compiler extends Infusion
|
||||
foreach (CFactory::_('Power')->active as $power)
|
||||
{
|
||||
if (ObjectHelper::check($power)
|
||||
&& isset($this->newFiles[$power->key])
|
||||
&& ArrayHelper::check(
|
||||
$this->newFiles[$power->key]
|
||||
))
|
||||
&& CFactory::_('Utilities.Files')->exists($power->key))
|
||||
{
|
||||
// update the power files
|
||||
foreach ($this->newFiles[$power->key] as $power_file)
|
||||
foreach (CFactory::_('Utilities.Files')->get($power->key) as $power_file)
|
||||
{
|
||||
if (File::exists($power_file['path']))
|
||||
{
|
||||
@ -606,8 +598,8 @@ class Compiler extends Infusion
|
||||
}
|
||||
}
|
||||
// free up some memory
|
||||
unset($this->newFiles[$power->key]);
|
||||
unset($this->fileContentDynamic[$power->key]);
|
||||
CFactory::_('Utilities.Files')->remove($power->key);
|
||||
CFactory::_('Content')->remove_($power->key);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -626,59 +618,73 @@ class Compiler extends Infusion
|
||||
*/
|
||||
protected function setFileContent(&$name, &$path, &$bom, $view = null)
|
||||
{
|
||||
// for plugin event TODO change event api signatures
|
||||
$component_context = CFactory::_('Config')->component_context;
|
||||
|
||||
// Trigger Event: jcb_ce_onBeforeSetFileContent
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onBeforeSetFileContent',
|
||||
array(&$this->componentContext, &$name, &$path, &$bom, &$view)
|
||||
array(&$component_context, &$name, &$path, &$bom, &$view)
|
||||
);
|
||||
|
||||
// set the file name
|
||||
$this->fileContentStatic[Placefix::_h('FILENAME')] = $name;
|
||||
CFactory::_('Content')->set('FILENAME', $name);
|
||||
|
||||
// check if the file should get PHP opening
|
||||
$php = '';
|
||||
if (ComponentbuilderHelper::checkFileType($name, 'php'))
|
||||
{
|
||||
$php = "<?php\n";
|
||||
}
|
||||
|
||||
// get content of the file
|
||||
$string = ComponentbuilderHelper::getFileContents($path);
|
||||
$string = FileHelper::getContent($path);
|
||||
|
||||
// Trigger Event: jcb_ce_onGetFileContents
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onGetFileContents',
|
||||
array(&$this->componentContext, &$string, &$name, &$path, &$bom,
|
||||
array(&$component_context, &$string, &$name, &$path, &$bom,
|
||||
&$view)
|
||||
);
|
||||
|
||||
// see if we should add a BOM
|
||||
if (strpos($string, Placefix::_h('BOM')) !== false)
|
||||
if (strpos((string) $string, (string) Placefix::_h('BOM')) !== false)
|
||||
{
|
||||
list($wast, $code) = explode(
|
||||
Placefix::_h('BOM'), $string
|
||||
Placefix::_h('BOM'), (string) $string
|
||||
);
|
||||
$string = $php . $bom . $code;
|
||||
}
|
||||
|
||||
// set the answer
|
||||
$answer = CFactory::_('Placeholder')->update($string, $this->fileContentStatic, 3);
|
||||
$answer = CFactory::_('Placeholder')->update($string, CFactory::_('Content')->active, 3);
|
||||
|
||||
// set the dynamic answer
|
||||
if ($view)
|
||||
{
|
||||
$answer = CFactory::_('Placeholder')->update(
|
||||
$answer, $this->fileContentDynamic[$view], 3
|
||||
$answer, CFactory::_('Content')->get_($view), 3
|
||||
);
|
||||
}
|
||||
|
||||
// check if this file needs extra care :)
|
||||
if (isset($this->updateFileContent[$path]))
|
||||
if (CFactory::_('Registry')->exists('update.file.content.' . $path))
|
||||
{
|
||||
$answer = CFactory::_('Customcode')->update($answer);
|
||||
}
|
||||
|
||||
// Trigger Event: jcb_ce_onBeforeSetFileContent
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onBeforeWriteFileContent',
|
||||
array(&$this->componentContext, &$answer, &$name, &$path, &$bom,
|
||||
array(&$component_context, &$answer, &$name, &$path, &$bom,
|
||||
&$view)
|
||||
);
|
||||
|
||||
// add answer back to file
|
||||
$this->writeFile($path, $answer);
|
||||
CFactory::_('Utilities.File')->write($path, $answer);
|
||||
|
||||
// count the file lines
|
||||
$this->lineCount = $this->lineCount + substr_count($answer, PHP_EOL);
|
||||
CFactory::_('Utilities.Counter')->line += substr_count((string) $answer, PHP_EOL);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -690,32 +696,39 @@ class Compiler extends Infusion
|
||||
protected function setUpdateServer()
|
||||
{
|
||||
// move the component update server to host
|
||||
if ($this->componentData->add_update_server == 1
|
||||
&& $this->componentData->update_server_target == 1
|
||||
if (CFactory::_('Component')->get('add_update_server', 0) == 1
|
||||
&& isset($this->updateServerFileName)
|
||||
&& $this->dynamicIntegration)
|
||||
{
|
||||
$update_server_xml_path = $this->componentPath . '/'
|
||||
$update_server_xml_path = CFactory::_('Utilities.Paths')->component_path . '/'
|
||||
. $this->updateServerFileName . '.xml';
|
||||
// make sure we have the correct file
|
||||
if (File::exists($update_server_xml_path)
|
||||
&& isset($this->componentData->update_server))
|
||||
&& ($update_server = CFactory::_('Component')->get('update_server')) !== null)
|
||||
{
|
||||
// move to server
|
||||
ComponentbuilderHelper::moveToServer(
|
||||
if (!CFactory::_('Server')->legacyMove(
|
||||
$update_server_xml_path,
|
||||
$this->updateServerFileName . '.xml',
|
||||
(int) $this->componentData->update_server,
|
||||
$this->componentData->update_server_protocol
|
||||
);
|
||||
(int) $update_server,
|
||||
CFactory::_('Component')->get('update_server_protocol')
|
||||
))
|
||||
{
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf(
|
||||
'Upload of component (%s) update server XML failed.',
|
||||
CFactory::_('Component')->get('system_name')
|
||||
), 'Error'
|
||||
);
|
||||
}
|
||||
// remove the local file
|
||||
File::delete($update_server_xml_path);
|
||||
}
|
||||
}
|
||||
// move the modules update server to host
|
||||
if (ArrayHelper::check($this->joomlaModules))
|
||||
if (CFactory::_('Joomlamodule.Data')->exists())
|
||||
{
|
||||
foreach ($this->joomlaModules as $module)
|
||||
foreach (CFactory::_('Joomlamodule.Data')->get() as $module)
|
||||
{
|
||||
if (ObjectHelper::check($module)
|
||||
&& isset($module->add_update_server)
|
||||
@ -733,12 +746,20 @@ class Compiler extends Infusion
|
||||
))
|
||||
{
|
||||
// move to server
|
||||
ComponentbuilderHelper::moveToServer(
|
||||
if (!CFactory::_('Server')->legacyMove(
|
||||
$module->update_server_xml_path,
|
||||
$module->update_server_xml_file_name,
|
||||
(int) $module->update_server,
|
||||
$module->update_server_protocol
|
||||
);
|
||||
))
|
||||
{
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf(
|
||||
'Upload of module (%s) update server XML failed.',
|
||||
$module->name
|
||||
), 'Error'
|
||||
);
|
||||
}
|
||||
// remove the local file
|
||||
File::delete($module->update_server_xml_path);
|
||||
}
|
||||
@ -746,9 +767,9 @@ class Compiler extends Infusion
|
||||
}
|
||||
}
|
||||
// move the plugins update server to host
|
||||
if (ArrayHelper::check($this->joomlaPlugins))
|
||||
if (CFactory::_('Joomlaplugin.Data')->exists())
|
||||
{
|
||||
foreach ($this->joomlaPlugins as $plugin)
|
||||
foreach (CFactory::_('Joomlaplugin.Data')->get() as $plugin)
|
||||
{
|
||||
if (ObjectHelper::check($plugin)
|
||||
&& isset($plugin->add_update_server)
|
||||
@ -766,12 +787,20 @@ class Compiler extends Infusion
|
||||
))
|
||||
{
|
||||
// move to server
|
||||
ComponentbuilderHelper::moveToServer(
|
||||
if (!CFactory::_('Server')->legacyMove(
|
||||
$plugin->update_server_xml_path,
|
||||
$plugin->update_server_xml_file_name,
|
||||
(int) $plugin->update_server,
|
||||
$plugin->update_server_protocol
|
||||
);
|
||||
))
|
||||
{
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf(
|
||||
'Upload of plugin (%s) update server XML failed.',
|
||||
$plugin->name
|
||||
), 'Error'
|
||||
);
|
||||
}
|
||||
// remove the local file
|
||||
File::delete($plugin->update_server_xml_path);
|
||||
}
|
||||
@ -787,7 +816,7 @@ class Compiler extends Infusion
|
||||
&& ArrayHelper::check(
|
||||
$data['config']
|
||||
)
|
||||
&& $this->componentData->mvc_versiondate == 1)
|
||||
&& CFactory::_('Component')->get('mvc_versiondate', 0) == 1)
|
||||
{
|
||||
foreach ($data['config'] as $key => $value)
|
||||
{
|
||||
@ -805,68 +834,52 @@ class Compiler extends Infusion
|
||||
$value = '@update number ' . $value . ' of this MVC';
|
||||
}
|
||||
}
|
||||
$this->fileContentStatic[$key] = $value;
|
||||
CFactory::_('Content')->set($key, $value);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
// else insure to reset to global
|
||||
$this->fileContentStatic[Placefix::_h('CREATIONDATE')]
|
||||
= $this->fileContentStatic[Placefix::_h('CREATIONDATE')
|
||||
. 'GLOBAL'];
|
||||
$this->fileContentStatic[Placefix::_h('BUILDDATE')]
|
||||
= $this->fileContentStatic[Placefix::_h('BUILDDATE')
|
||||
. 'GLOBAL'];
|
||||
$this->fileContentStatic[Placefix::_h('VERSION')]
|
||||
= $this->fileContentStatic[Placefix::_h('VERSION')
|
||||
. 'GLOBAL'];
|
||||
CFactory::_('Content')->set('CREATIONDATE', CFactory::_('Content')->get('GLOBALCREATIONDATE'));
|
||||
CFactory::_('Content')->set('BUILDDATE', CFactory::_('Content')->get('GLOBALBUILDDATE'));
|
||||
CFactory::_('Content')->set('VERSION', CFactory::_('Content')->get('GLOBALVERSION'));
|
||||
}
|
||||
|
||||
// set all global numbers
|
||||
/**
|
||||
* Set all global numbers
|
||||
*
|
||||
* @return void
|
||||
* @deprecated 3.3
|
||||
*/
|
||||
protected function setCountingStuff()
|
||||
{
|
||||
// what is the size in terms of an A4 book
|
||||
$this->pageCount = round($this->lineCount / 56);
|
||||
// setup the unrealistic numbers
|
||||
$this->folderSeconds = $this->folderCount * 5;
|
||||
$this->fileSeconds = $this->fileCount * 5;
|
||||
$this->lineSeconds = $this->lineCount * 10;
|
||||
$this->seconds = $this->folderSeconds + $this->fileSeconds
|
||||
+ $this->lineSeconds;
|
||||
$this->totalHours = round($this->seconds / 3600);
|
||||
$this->totalDays = round($this->totalHours / 8);
|
||||
// setup the more realistic numbers
|
||||
$this->secondsDebugging = $this->seconds / 4;
|
||||
$this->secondsPlanning = $this->seconds / 7;
|
||||
$this->secondsMapping = $this->seconds / 10;
|
||||
$this->secondsOffice = $this->seconds / 6;
|
||||
$this->actualSeconds = $this->folderSeconds + $this->fileSeconds
|
||||
+ $this->lineSeconds + $this->secondsDebugging
|
||||
+ $this->secondsPlanning + $this->secondsMapping
|
||||
+ $this->secondsOffice;
|
||||
$this->actualTotalHours = round($this->actualSeconds / 3600);
|
||||
$this->actualTotalDays = round($this->actualTotalHours / 8);
|
||||
$this->debuggingHours = round($this->secondsDebugging / 3600);
|
||||
$this->planningHours = round($this->secondsPlanning / 3600);
|
||||
$this->mappingHours = round($this->secondsMapping / 3600);
|
||||
$this->officeHours = round($this->secondsOffice / 3600);
|
||||
// the actual time spent
|
||||
$this->actualHoursSpent = $this->actualTotalHours - $this->totalHours;
|
||||
$this->actualDaysSpent = $this->actualTotalDays - $this->totalDays;
|
||||
// calculate the projects actual time frame of completion
|
||||
$this->projectWeekTime = round($this->actualTotalDays / 5, 1);
|
||||
$this->projectMonthTime = round($this->actualTotalDays / 24, 1);
|
||||
// set notice that we could not get a valid string from the target
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf('<hr /><h3>%s Warning</h3>', __CLASS__), 'Error'
|
||||
);
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf(
|
||||
'Use of a deprecated method (%s)!', __METHOD__
|
||||
), 'Error'
|
||||
);
|
||||
}
|
||||
|
||||
private function buildReadMe()
|
||||
{
|
||||
// do a final run to update the readme file
|
||||
$two = 0;
|
||||
foreach ($this->newFiles['static'] as $static)
|
||||
// counter data if not set already
|
||||
if (!CFactory::_('Content')->exist('LINE_COUNT')
|
||||
|| CFactory::_('Content')->get('LINE_COUNT') != CFactory::_('Utilities.Counter')->line)
|
||||
{
|
||||
CFactory::_('Utilities.Counter')->set();
|
||||
}
|
||||
// search for the readme
|
||||
foreach (CFactory::_('Utilities.Files')->get('static') as $static)
|
||||
{
|
||||
if (('README.md' === $static['name']
|
||||
|| 'README.txt' === $static['name'])
|
||||
&& $this->componentData->addreadme
|
||||
&& CFactory::_('Component')->get('addreadme')
|
||||
&& File::exists($static['path']))
|
||||
{
|
||||
$this->setReadMe($static['path']);
|
||||
@ -877,97 +890,36 @@ class Compiler extends Infusion
|
||||
break;
|
||||
}
|
||||
}
|
||||
unset($this->newFiles['static']);
|
||||
CFactory::_('Utilities.Files')->remove('static');
|
||||
}
|
||||
|
||||
private function setReadMe($path)
|
||||
{
|
||||
// set readme data if not set already
|
||||
if (!isset(
|
||||
$this->fileContentStatic[Placefix::_h('LINE_COUNT')]
|
||||
)
|
||||
|| $this->fileContentStatic[Placefix::_h('LINE_COUNT')]
|
||||
!= $this->lineCount)
|
||||
{
|
||||
$this->buildReadMeData();
|
||||
}
|
||||
// get the file
|
||||
$string = ComponentbuilderHelper::getFileContents($path);
|
||||
$string = FileHelper::getContent($path);
|
||||
// update the file
|
||||
$answer = CFactory::_('Placeholder')->update($string, $this->fileContentStatic);
|
||||
$answer = CFactory::_('Placeholder')->update($string, CFactory::_('Content')->active);
|
||||
// add to zip array
|
||||
$this->writeFile($path, $answer);
|
||||
CFactory::_('Utilities.File')->write($path, $answer);
|
||||
}
|
||||
|
||||
/**
|
||||
* Build README data
|
||||
*
|
||||
* @return void
|
||||
* @deprecated 3.3
|
||||
*/
|
||||
private function buildReadMeData()
|
||||
{
|
||||
// set some defaults
|
||||
$this->fileContentStatic[Placefix::_h('LINE_COUNT')]
|
||||
= $this->lineCount;
|
||||
$this->fileContentStatic[Placefix::_h('FIELD_COUNT')]
|
||||
= $this->fieldCount;
|
||||
$this->fileContentStatic[Placefix::_h('FILE_COUNT')]
|
||||
= $this->fileCount;
|
||||
$this->fileContentStatic[Placefix::_h('FOLDER_COUNT')]
|
||||
= $this->folderCount;
|
||||
$this->fileContentStatic[Placefix::_h('PAGE_COUNT')]
|
||||
= $this->pageCount;
|
||||
$this->fileContentStatic[Placefix::_h('folders')]
|
||||
= $this->folderSeconds;
|
||||
$this->fileContentStatic[Placefix::_h('foldersSeconds')]
|
||||
= $this->folderSeconds;
|
||||
$this->fileContentStatic[Placefix::_h('files')]
|
||||
= $this->fileSeconds;
|
||||
$this->fileContentStatic[Placefix::_h('filesSeconds')]
|
||||
= $this->fileSeconds;
|
||||
$this->fileContentStatic[Placefix::_h('lines')]
|
||||
= $this->lineSeconds;
|
||||
$this->fileContentStatic[Placefix::_h('linesSeconds')]
|
||||
= $this->lineSeconds;
|
||||
$this->fileContentStatic[Placefix::_h('seconds')]
|
||||
= $this->actualSeconds;
|
||||
$this->fileContentStatic[Placefix::_h('actualSeconds')]
|
||||
= $this->actualSeconds;
|
||||
$this->fileContentStatic[Placefix::_h('totalHours')]
|
||||
= $this->totalHours;
|
||||
$this->fileContentStatic[Placefix::_h('totalDays')]
|
||||
= $this->totalDays;
|
||||
$this->fileContentStatic[Placefix::_h('debugging')]
|
||||
= $this->secondsDebugging;
|
||||
$this->fileContentStatic[Placefix::_h('secondsDebugging')]
|
||||
= $this->secondsDebugging;
|
||||
$this->fileContentStatic[Placefix::_h('planning')]
|
||||
= $this->secondsPlanning;
|
||||
$this->fileContentStatic[Placefix::_h('secondsPlanning')]
|
||||
= $this->secondsPlanning;
|
||||
$this->fileContentStatic[Placefix::_h('mapping')]
|
||||
= $this->secondsMapping;
|
||||
$this->fileContentStatic[Placefix::_h('secondsMapping')]
|
||||
= $this->secondsMapping;
|
||||
$this->fileContentStatic[Placefix::_h('office')]
|
||||
= $this->secondsOffice;
|
||||
$this->fileContentStatic[Placefix::_h('secondsOffice')]
|
||||
= $this->secondsOffice;
|
||||
$this->fileContentStatic[Placefix::_h('actualTotalHours')]
|
||||
= $this->actualTotalHours;
|
||||
$this->fileContentStatic[Placefix::_h('actualTotalDays')]
|
||||
= $this->actualTotalDays;
|
||||
$this->fileContentStatic[Placefix::_h('debuggingHours')]
|
||||
= $this->debuggingHours;
|
||||
$this->fileContentStatic[Placefix::_h('planningHours')]
|
||||
= $this->planningHours;
|
||||
$this->fileContentStatic[Placefix::_h('mappingHours')]
|
||||
= $this->mappingHours;
|
||||
$this->fileContentStatic[Placefix::_h('officeHours')]
|
||||
= $this->officeHours;
|
||||
$this->fileContentStatic[Placefix::_h('actualHoursSpent')]
|
||||
= $this->actualHoursSpent;
|
||||
$this->fileContentStatic[Placefix::_h('actualDaysSpent')]
|
||||
= $this->actualDaysSpent;
|
||||
$this->fileContentStatic[Placefix::_h('projectWeekTime')]
|
||||
= $this->projectWeekTime;
|
||||
$this->fileContentStatic[Placefix::_h('projectMonthTime')]
|
||||
= $this->projectMonthTime;
|
||||
// set notice that we could not get a valid string from the target
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf('<hr /><h3>%s Warning</h3>', __CLASS__), 'Error'
|
||||
);
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf(
|
||||
'Use of a deprecated method (%s)!', __METHOD__
|
||||
), 'Error'
|
||||
);
|
||||
}
|
||||
|
||||
private function setLocalRepos()
|
||||
@ -980,29 +932,32 @@ class Compiler extends Infusion
|
||||
{
|
||||
// set the repo path
|
||||
$repoFullPath = $this->repoPath . '/com_'
|
||||
. $this->componentData->sales_name . '__joomla_'
|
||||
. CFactory::_('Component')->get('sales_name') . '__joomla_'
|
||||
. CFactory::_('Config')->get('version', 3);
|
||||
// for plugin event TODO change event api signatures
|
||||
$component_context = CFactory::_('Config')->component_context;
|
||||
$component_path = CFactory::_('Utilities.Paths')->component_path;
|
||||
// Trigger Event: jcb_ce_onBeforeUpdateRepo
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onBeforeUpdateRepo',
|
||||
array(&$this->componentContext, &$this->componentPath,
|
||||
array(&$component_context, &$component_path,
|
||||
&$repoFullPath, &$this->componentData)
|
||||
);
|
||||
// remove old data
|
||||
$this->removeFolder($repoFullPath, $this->componentData->toignore);
|
||||
CFactory::_('Utilities.Folder')->remove($repoFullPath, CFactory::_('Component')->get('toignore'));
|
||||
// set the new data
|
||||
Folder::copy($this->componentPath, $repoFullPath, '', true);
|
||||
Folder::copy(CFactory::_('Utilities.Paths')->component_path, $repoFullPath, '', true);
|
||||
// Trigger Event: jcb_ce_onAfterUpdateRepo
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onAfterUpdateRepo',
|
||||
array(&$this->componentContext, &$this->componentPath,
|
||||
array(&$component_context, &$component_path,
|
||||
&$repoFullPath, &$this->componentData)
|
||||
);
|
||||
|
||||
// move the modules to local folder repos
|
||||
if (ArrayHelper::check($this->joomlaModules))
|
||||
if (CFactory::_('Joomlamodule.Data')->exists())
|
||||
{
|
||||
foreach ($this->joomlaModules as $module)
|
||||
foreach (CFactory::_('Joomlamodule.Data')->get() as $module)
|
||||
{
|
||||
if (ObjectHelper::check($module)
|
||||
&& isset($module->file_name))
|
||||
@ -1020,8 +975,8 @@ class Compiler extends Infusion
|
||||
&$repoFullPath, &$module)
|
||||
);
|
||||
// remove old data
|
||||
$this->removeFolder(
|
||||
$repoFullPath, $this->componentData->toignore
|
||||
CFactory::_('Utilities.Folder')->remove(
|
||||
$repoFullPath, CFactory::_('Component')->get('toignore')
|
||||
);
|
||||
// set the new data
|
||||
Folder::copy(
|
||||
@ -1037,9 +992,9 @@ class Compiler extends Infusion
|
||||
}
|
||||
}
|
||||
// move the plugins to local folder repos
|
||||
if (ArrayHelper::check($this->joomlaPlugins))
|
||||
if (CFactory::_('Joomlaplugin.Data')->exists())
|
||||
{
|
||||
foreach ($this->joomlaPlugins as $plugin)
|
||||
foreach (CFactory::_('Joomlaplugin.Data')->get() as $plugin)
|
||||
{
|
||||
if (ObjectHelper::check($plugin)
|
||||
&& isset($plugin->file_name))
|
||||
@ -1057,8 +1012,8 @@ class Compiler extends Infusion
|
||||
&$repoFullPath, &$plugin)
|
||||
);
|
||||
// remove old data
|
||||
$this->removeFolder(
|
||||
$repoFullPath, $this->componentData->toignore
|
||||
CFactory::_('Utilities.Folder')->remove(
|
||||
$repoFullPath, CFactory::_('Component')->get('toignore')
|
||||
);
|
||||
// set the new data
|
||||
Folder::copy(
|
||||
@ -1079,20 +1034,25 @@ class Compiler extends Infusion
|
||||
private function zipComponent()
|
||||
{
|
||||
// Component Folder Name
|
||||
$this->filepath['component-folder'] = $this->componentFolderName;
|
||||
$this->filepath['component-folder'] = CFactory::_('Utilities.Paths')->component_folder_name;
|
||||
// the name of the zip file to create
|
||||
$this->filepath['component'] = $this->tempPath . '/'
|
||||
. $this->filepath['component-folder'] . '.zip';
|
||||
// for plugin event TODO change event api signatures
|
||||
$component_context = CFactory::_('Config')->component_context;
|
||||
$component_path = CFactory::_('Utilities.Paths')->component_path;
|
||||
$component_sales_name = CFactory::_('Utilities.Paths')->component_sales_name;
|
||||
$component_folder_name = CFactory::_('Utilities.Paths')->component_folder_name;
|
||||
// Trigger Event: jcb_ce_onBeforeZipComponent
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onBeforeZipComponent',
|
||||
array(&$this->componentContext, &$this->componentPath,
|
||||
array(&$component_context, &$component_path,
|
||||
&$this->filepath['component'], &$this->tempPath,
|
||||
&$this->componentFolderName, &$this->componentData)
|
||||
&$component_folder_name, &$this->componentData)
|
||||
);
|
||||
//create the zip file
|
||||
if (FileHelper::zip(
|
||||
$this->componentPath, $this->filepath['component']
|
||||
CFactory::_('Utilities.Paths')->component_path, $this->filepath['component']
|
||||
))
|
||||
{
|
||||
// now move to backup if zip was made and backup is required
|
||||
@ -1100,7 +1060,7 @@ class Compiler extends Infusion
|
||||
{
|
||||
// Trigger Event: jcb_ce_onBeforeBackupZip
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onBeforeBackupZip', array(&$this->componentContext,
|
||||
'jcb_ce_onBeforeBackupZip', array(&$component_context,
|
||||
&$this->filepath['component'],
|
||||
&$this->tempPath,
|
||||
&$this->backupPath,
|
||||
@ -1109,42 +1069,50 @@ class Compiler extends Infusion
|
||||
// copy the zip to backup path
|
||||
File::copy(
|
||||
$this->filepath['component'],
|
||||
$this->backupPath . '/' . $this->componentBackupName
|
||||
$this->backupPath . '/' . CFactory::_('Utilities.Paths')->component_backup_name
|
||||
. '.zip'
|
||||
);
|
||||
}
|
||||
// move to sales server host
|
||||
if ($this->componentData->add_sales_server == 1
|
||||
if (CFactory::_('Component')->get('add_sales_server', 0) == 1
|
||||
&& $this->dynamicIntegration)
|
||||
{
|
||||
// make sure we have the correct file
|
||||
if (isset($this->componentData->sales_server))
|
||||
if (CFactory::_('Component')->get('sales_server'))
|
||||
{
|
||||
// Trigger Event: jcb_ce_onBeforeMoveToServer
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onBeforeMoveToServer',
|
||||
array(&$this->componentContext,
|
||||
array(&$component_context,
|
||||
&$this->filepath['component'], &$this->tempPath,
|
||||
&$this->componentSalesName, &$this->componentData)
|
||||
&$component_sales_name, &$this->componentData)
|
||||
);
|
||||
// move to server
|
||||
ComponentbuilderHelper::moveToServer(
|
||||
if (!CFactory::_('Server')->legacyMove(
|
||||
$this->filepath['component'],
|
||||
$this->componentSalesName . '.zip',
|
||||
(int) $this->componentData->sales_server,
|
||||
$this->componentData->sales_server_protocol
|
||||
);
|
||||
$component_sales_name . '.zip',
|
||||
(int) CFactory::_('Component')->get('sales_server'),
|
||||
CFactory::_('Component')->get('sales_server_protocol')
|
||||
))
|
||||
{
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf(
|
||||
'Upload of component (%s) zip file failed.',
|
||||
CFactory::_('Component')->get('system_name')
|
||||
), 'Error'
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
// Trigger Event: jcb_ce_onAfterZipComponent
|
||||
CFactory::_('Event')->trigger(
|
||||
'jcb_ce_onAfterZipComponent',
|
||||
array(&$this->componentContext, &$this->filepath['component'],
|
||||
&$this->tempPath, &$this->componentFolderName,
|
||||
array(&$component_context, &$this->filepath['component'],
|
||||
&$this->tempPath, &$component_folder_name,
|
||||
&$this->componentData)
|
||||
);
|
||||
// remove the component folder since we are done
|
||||
if ($this->removeFolder($this->componentPath))
|
||||
if (CFactory::_('Utilities.Folder')->remove(CFactory::_('Utilities.Paths')->component_path))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@ -1155,9 +1123,9 @@ class Compiler extends Infusion
|
||||
|
||||
private function zipModules()
|
||||
{
|
||||
if (ArrayHelper::check($this->joomlaModules))
|
||||
if (CFactory::_('Joomlamodule.Data')->exists())
|
||||
{
|
||||
foreach ($this->joomlaModules as $module)
|
||||
foreach (CFactory::_('Joomlamodule.Data')->get() as $module)
|
||||
{
|
||||
if (ObjectHelper::check($module)
|
||||
&& isset($module->zip_name)
|
||||
@ -1223,12 +1191,20 @@ class Compiler extends Infusion
|
||||
&$module)
|
||||
);
|
||||
// move to server
|
||||
ComponentbuilderHelper::moveToServer(
|
||||
if (!CFactory::_('Server')->legacyMove(
|
||||
$this->filepath['modules'][$module->id],
|
||||
$module->zip_name . '.zip',
|
||||
(int) $module->sales_server,
|
||||
$module->sales_server_protocol
|
||||
);
|
||||
))
|
||||
{
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf(
|
||||
'Upload of module (%s) zip file failed.',
|
||||
$module->name
|
||||
), 'Error'
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
// Trigger Event: jcb_ce_onAfterZipModule
|
||||
@ -1240,7 +1216,7 @@ class Compiler extends Infusion
|
||||
&$module)
|
||||
);
|
||||
// remove the module folder since we are done
|
||||
$this->removeFolder($module->folder_path);
|
||||
CFactory::_('Utilities.Folder')->remove($module->folder_path);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1249,9 +1225,9 @@ class Compiler extends Infusion
|
||||
|
||||
private function zipPlugins()
|
||||
{
|
||||
if (ArrayHelper::check($this->joomlaPlugins))
|
||||
if (CFactory::_('Joomlaplugin.Data')->exists())
|
||||
{
|
||||
foreach ($this->joomlaPlugins as $plugin)
|
||||
foreach (CFactory::_('Joomlaplugin.Data')->get() as $plugin)
|
||||
{
|
||||
if (ObjectHelper::check($plugin)
|
||||
&& isset($plugin->zip_name)
|
||||
@ -1317,12 +1293,20 @@ class Compiler extends Infusion
|
||||
&$plugin)
|
||||
);
|
||||
// move to server
|
||||
ComponentbuilderHelper::moveToServer(
|
||||
if (!CFactory::_('Server')->legacyMove(
|
||||
$this->filepath['plugins'][$plugin->id],
|
||||
$plugin->zip_name . '.zip',
|
||||
(int) $plugin->sales_server,
|
||||
$plugin->sales_server_protocol
|
||||
);
|
||||
))
|
||||
{
|
||||
$this->app->enqueueMessage(
|
||||
JText::sprintf(
|
||||
'Upload of plugin (%s) zip file failed.',
|
||||
$plugin->name
|
||||
), 'Error'
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
// Trigger Event: jcb_ce_onAfterZipPlugin
|
||||
@ -1334,7 +1318,7 @@ class Compiler extends Infusion
|
||||
&$plugin)
|
||||
);
|
||||
// remove the plugin folder since we are done
|
||||
$this->removeFolder($plugin->folder_path);
|
||||
CFactory::_('Utilities.Folder')->remove($plugin->folder_path);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1358,7 +1342,7 @@ class Compiler extends Infusion
|
||||
$target['hashtarget'][1]
|
||||
))
|
||||
{
|
||||
$file = $this->componentPath . '/' . $target['path'];
|
||||
$file = CFactory::_('Utilities.Paths')->component_path . '/' . $target['path'];
|
||||
$size = (int) $target['hashtarget'][0];
|
||||
$hash = $target['hashtarget'][1];
|
||||
$cut = $size - 1;
|
||||
@ -1462,8 +1446,8 @@ class Compiler extends Infusion
|
||||
$target['id']
|
||||
);
|
||||
$data = $placeholder['start'] . PHP_EOL
|
||||
. CFactory::_('Placeholder')->update(
|
||||
$target['code'], CFactory::_('Placeholder')->active
|
||||
. CFactory::_('Placeholder')->update_(
|
||||
$target['code']
|
||||
) . $placeholder['end'] . PHP_EOL;
|
||||
if ($target['type'] == 2)
|
||||
{
|
||||
@ -1547,7 +1531,7 @@ class Compiler extends Infusion
|
||||
$_commentType = " -->";
|
||||
}
|
||||
// escape the code
|
||||
$code = explode(PHP_EOL, $target['code']);
|
||||
$code = explode(PHP_EOL, (string) $target['code']);
|
||||
$code = PHP_EOL . $commentType . implode(
|
||||
$_commentType . PHP_EOL . $commentType, $code
|
||||
) . $_commentType . PHP_EOL;
|
||||
@ -1581,10 +1565,10 @@ class Compiler extends Infusion
|
||||
// move to the position where we should add the data
|
||||
fseek($fpFile, $position);
|
||||
// Add the data
|
||||
fwrite($fpFile, $data);
|
||||
fwrite($fpFile, (string) $data);
|
||||
// truncate file at the end of the data that was added
|
||||
$remove = MathHelper::bc(
|
||||
'add', $position, mb_strlen($data, '8bit')
|
||||
'add', $position, mb_strlen((string) $data, '8bit')
|
||||
);
|
||||
ftruncate($fpFile, $remove);
|
||||
// check if this was a replacement of data
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -12,13 +12,22 @@
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
// add the autoloader for the composer classes
|
||||
$composer_autoloader = JPATH_LIBRARIES . '/phpseclib3/vendor/autoload.php';
|
||||
if (file_exists($composer_autoloader))
|
||||
{
|
||||
require_once $composer_autoloader;
|
||||
}
|
||||
|
||||
// register this component namespace
|
||||
spl_autoload_register(function ($class) {
|
||||
// project-specific base directories and namespace prefix
|
||||
$search = array(
|
||||
$search = [
|
||||
'libraries/jcb_powers/VDM.Joomla' => 'VDM\\Joomla',
|
||||
'libraries/jcb_powers/VDM.Gitea' => 'VDM\\Gitea'
|
||||
);
|
||||
'libraries/jcb_powers/VDM.Minify' => 'VDM\\Minify',
|
||||
'libraries/jcb_powers/VDM.Gitea' => 'VDM\\Gitea',
|
||||
'libraries/jcb_powers/VDM.Psr' => 'VDM\\Psr'
|
||||
];
|
||||
// Start the search and load if found
|
||||
$found = false;
|
||||
$found_base_dir = "";
|
||||
@ -40,7 +49,7 @@ spl_autoload_register(function ($class) {
|
||||
// check if we found a match
|
||||
if (!$found)
|
||||
{
|
||||
// no, move to the next registered autoloader
|
||||
// not found so move to the next registered autoloader
|
||||
return;
|
||||
}
|
||||
// get the relative class name
|
||||
@ -64,10 +73,10 @@ use Joomla\Utilities\ArrayHelper;
|
||||
use PhpOffice\PhpSpreadsheet\IOFactory;
|
||||
use PhpOffice\PhpSpreadsheet\Spreadsheet;
|
||||
use PhpOffice\PhpSpreadsheet\Writer\Xlsx;
|
||||
use VDM\Joomla\Utilities;
|
||||
use Joomla\Archive\Archive;
|
||||
use Joomla\CMS\Filesystem\Folder;
|
||||
use Joomla\CMS\Filesystem\Path;
|
||||
use VDM\Joomla\Utilities;
|
||||
|
||||
/**
|
||||
* Componentbuilder component helper.
|
||||
@ -1071,8 +1080,6 @@ abstract class ComponentbuilderHelper
|
||||
{
|
||||
// import the Joomla librarys
|
||||
jimport('joomla.application.component.modellist');
|
||||
// include class to minify js
|
||||
require_once JPATH_ADMINISTRATOR.'/components/com_componentbuilder/helpers/js.php';
|
||||
}
|
||||
// load only if smart
|
||||
if ('smart' === $type)
|
||||
@ -3813,31 +3820,31 @@ abstract class ComponentbuilderHelper
|
||||
switch ($mode)
|
||||
{
|
||||
case 'CTR':
|
||||
self::$CRYPT[$key] = new $CLASS($CLASS::MODE_CTR);
|
||||
self::$CRYPT[$key] = new $CLASS('ctr');
|
||||
break;
|
||||
case 'ECB':
|
||||
self::$CRYPT[$key] = new $CLASS($CLASS::MODE_ECB);
|
||||
self::$CRYPT[$key] = new $CLASS('ecb');
|
||||
break;
|
||||
case 'CBC':
|
||||
self::$CRYPT[$key] = new $CLASS($CLASS::MODE_CBC);
|
||||
self::$CRYPT[$key] = new $CLASS('cbc');
|
||||
break;
|
||||
case 'CBC3':
|
||||
self::$CRYPT[$key] = new $CLASS($CLASS::MODE_CBC3);
|
||||
self::$CRYPT[$key] = new $CLASS('cbc3');
|
||||
break;
|
||||
case 'CFB':
|
||||
self::$CRYPT[$key] = new $CLASS($CLASS::MODE_CFB);
|
||||
self::$CRYPT[$key] = new $CLASS('cfb');
|
||||
break;
|
||||
case 'CFB8':
|
||||
self::$CRYPT[$key] = new $CLASS($CLASS::MODE_CFB8);
|
||||
self::$CRYPT[$key] = new $CLASS('cfb8');
|
||||
break;
|
||||
case 'OFB':
|
||||
self::$CRYPT[$key] = new $CLASS($CLASS::MODE_OFB);
|
||||
self::$CRYPT[$key] = new $CLASS('ofb');
|
||||
break;
|
||||
case 'GCM':
|
||||
self::$CRYPT[$key] = new $CLASS($CLASS::MODE_GCM);
|
||||
self::$CRYPT[$key] = new $CLASS('gcm');
|
||||
break;
|
||||
case 'STREAM':
|
||||
self::$CRYPT[$key] = new $CLASS($CLASS::MODE_STREAM);
|
||||
self::$CRYPT[$key] = new $CLASS('stream');
|
||||
break;
|
||||
default:
|
||||
// No valid mode has been specified
|
||||
@ -3848,7 +3855,7 @@ abstract class ComponentbuilderHelper
|
||||
}
|
||||
else
|
||||
{
|
||||
// set the
|
||||
// set the default
|
||||
self::$CRYPT[$key] = new $CLASS();
|
||||
}
|
||||
// return the object
|
||||
@ -6321,11 +6328,6 @@ abstract class ComponentbuilderHelper
|
||||
{
|
||||
JHtmlSidebar::addEntry(JText::_('COM_COMPONENTBUILDER_SUBMENU_COMPILER'), 'index.php?option=com_componentbuilder&view=compiler', $submenu === 'compiler');
|
||||
}
|
||||
// Access control (search.submenu).
|
||||
if ($user->authorise('search.submenu', 'com_componentbuilder'))
|
||||
{
|
||||
JHtmlSidebar::addEntry(JText::_('COM_COMPONENTBUILDER_SUBMENU_SEARCH'), 'index.php?option=com_componentbuilder&view=search', $submenu === 'search');
|
||||
}
|
||||
if ($user->authorise('joomla_component.access', 'com_componentbuilder') && $user->authorise('joomla_component.submenu', 'com_componentbuilder'))
|
||||
{
|
||||
JHtmlSidebar::addEntry(JText::_('COM_COMPONENTBUILDER_SUBMENU_JOOMLA_COMPONENTS'), 'index.php?option=com_componentbuilder&view=joomla_components', $submenu === 'joomla_components');
|
||||
@ -6342,6 +6344,11 @@ abstract class ComponentbuilderHelper
|
||||
{
|
||||
JHtmlSidebar::addEntry(JText::_('COM_COMPONENTBUILDER_SUBMENU_POWERS'), 'index.php?option=com_componentbuilder&view=powers', $submenu === 'powers');
|
||||
}
|
||||
// Access control (search.access && search.submenu).
|
||||
if ($user->authorise('search.access', 'com_componentbuilder') && $user->authorise('search.submenu', 'com_componentbuilder'))
|
||||
{
|
||||
JHtmlSidebar::addEntry(JText::_('COM_COMPONENTBUILDER_SUBMENU_SEARCH'), 'index.php?option=com_componentbuilder&view=search', $submenu === 'search');
|
||||
}
|
||||
if ($user->authorise('admin_view.access', 'com_componentbuilder') && $user->authorise('admin_view.submenu', 'com_componentbuilder'))
|
||||
{
|
||||
JHtmlSidebar::addEntry(JText::_('COM_COMPONENTBUILDER_SUBMENU_ADMIN_VIEWS'), 'index.php?option=com_componentbuilder&view=admin_views', $submenu === 'admin_views');
|
||||
|
@ -26,6 +26,11 @@
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use VDM\Joomla\Utilities\StringHelper;
|
||||
use VDM\Joomla\Utilities\JsonHelper;
|
||||
use VDM\Joomla\Utilities\GetHelper;
|
||||
use VDM\Joomla\Utilities\ArrayHelper;
|
||||
|
||||
/**
|
||||
* Mapping class
|
||||
*/
|
||||
@ -102,7 +107,7 @@ class Mapping
|
||||
// set the app to insure messages can be set
|
||||
$this->app = JFactory::getApplication();
|
||||
// check that we have data
|
||||
if (ComponentbuilderHelper::checkArray($data))
|
||||
if (ArrayHelper::check($data))
|
||||
{
|
||||
// make sure we have an id
|
||||
if (isset($data['id']) && $data['id'] > 0)
|
||||
@ -117,15 +122,15 @@ class Mapping
|
||||
{
|
||||
case 'base64':
|
||||
// set needed value
|
||||
$this->$key = base64_decode($value);
|
||||
$this->$key = base64_decode((string) $value);
|
||||
break;
|
||||
case 'json':
|
||||
// set needed value
|
||||
$this->$key = json_decode($value, true);
|
||||
$this->$key = json_decode((string) $value, true);
|
||||
break;
|
||||
case 'safeString':
|
||||
// set needed value
|
||||
$this->$key = ComponentbuilderHelper::safeString($value);
|
||||
$this->$key = StringHelper::check($value);
|
||||
break;
|
||||
default :
|
||||
$this->$key = $value;
|
||||
@ -134,10 +139,10 @@ class Mapping
|
||||
}
|
||||
}
|
||||
// get linked admin views
|
||||
$addadmin_views = ComponentbuilderHelper::getVar('component_admin_views', $data['id'], 'joomla_component', 'addadmin_views');
|
||||
if (ComponentbuilderHelper::checkJson($addadmin_views))
|
||||
$addadmin_views = GetHelper::var('component_admin_views', $data['id'], 'joomla_component', 'addadmin_views');
|
||||
if (JsonHelper::check($addadmin_views))
|
||||
{
|
||||
$this->addadmin_views = json_decode($addadmin_views, true);
|
||||
$this->addadmin_views = json_decode((string)$addadmin_views, true);
|
||||
}
|
||||
// set the map of the views needed
|
||||
if ($this->setMap())
|
||||
@ -173,7 +178,7 @@ class Mapping
|
||||
{
|
||||
// start parsing the sql dump data
|
||||
$queries = JDatabaseDriver::splitSql($this->buildcompsql);
|
||||
if (ComponentbuilderHelper::checkArray($queries))
|
||||
if (ArrayHelper::check($queries))
|
||||
{
|
||||
foreach ($queries as $query)
|
||||
{
|
||||
@ -208,7 +213,7 @@ class Mapping
|
||||
}
|
||||
}
|
||||
// check if the mapping was done
|
||||
if (ComponentbuilderHelper::checkArray($this->map))
|
||||
if (ArrayHelper::check($this->map))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@ -224,12 +229,12 @@ class Mapping
|
||||
if (strpos($query, '`#__') !== false)
|
||||
{
|
||||
// get table name
|
||||
$tableName = ComponentbuilderHelper::getBetween($query, '`#__', "`");
|
||||
$tableName = GetHelper::between($query, '`#__', "`");
|
||||
}
|
||||
elseif (strpos($query, "'#__") !== false)
|
||||
{
|
||||
// get table name
|
||||
$tableName = ComponentbuilderHelper::getBetween($query, "'#__", "'");
|
||||
$tableName = GetHelper::between($query, "'#__", "'");
|
||||
}
|
||||
// if it still was not found
|
||||
if (!isset($tableName) || !ComponentbuilderHelper::checkString($tableName))
|
||||
@ -267,12 +272,12 @@ class Mapping
|
||||
if (0 === strpos($row, '`'))
|
||||
{
|
||||
// get field name
|
||||
$name = ComponentbuilderHelper::getBetween($row, '`', '`');
|
||||
$name = GetHelper::between($row, '`', '`');
|
||||
}
|
||||
if (0 === strpos($row, "'"))
|
||||
{
|
||||
// get field name
|
||||
$name = ComponentbuilderHelper::getBetween($row, "'", "'");
|
||||
$name = GetHelper::between($row, "'", "'");
|
||||
}
|
||||
// check if the name was found
|
||||
if (ComponentbuilderHelper::checkString($name))
|
||||
@ -289,7 +294,7 @@ class Mapping
|
||||
{
|
||||
$field['row'] = $row;
|
||||
$field['name'] = $name;
|
||||
$field['label'] = ComponentbuilderHelper::safeString($name, 'W');
|
||||
$field['label'] = StringHelper::check($name, 'W');
|
||||
$field['fieldType'] = $fieldType;
|
||||
$field['size'] = $this->getSize($row, $field);
|
||||
$field['sizeOther'] = '';
|
||||
@ -319,7 +324,7 @@ class Mapping
|
||||
}
|
||||
}
|
||||
}
|
||||
if (ComponentbuilderHelper::checkArray($fields))
|
||||
if (ArrayHelper::check($fields))
|
||||
{
|
||||
return $fields;
|
||||
}
|
||||
@ -352,7 +357,7 @@ class Mapping
|
||||
{
|
||||
if (in_array($field['dataType'], $this->dataSize))
|
||||
{
|
||||
return ComponentbuilderHelper::getBetween($row, $field['dataType'].'(', ')');
|
||||
return GetHelper::between($row, $field['dataType'].'(', ')');
|
||||
}
|
||||
return '';
|
||||
}
|
||||
@ -365,12 +370,12 @@ class Mapping
|
||||
// get default value
|
||||
if (strpos($row, 'DEFAULT "') !== false) // to sure it this is correct...
|
||||
{
|
||||
return ComponentbuilderHelper::getBetween($row, 'DEFAULT "', '"');
|
||||
return GetHelper::between($row, 'DEFAULT "', '"');
|
||||
}
|
||||
// get default value
|
||||
if (strpos($row, "DEFAULT '") !== false)
|
||||
{
|
||||
return ComponentbuilderHelper::getBetween($row, "DEFAULT '", "'");
|
||||
return GetHelper::between($row, "DEFAULT '", "'");
|
||||
}
|
||||
return '';
|
||||
}
|
||||
|
@ -26,6 +26,10 @@
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Factory as CFactory;
|
||||
use VDM\Joomla\Utilities\StringHelper;
|
||||
use VDM\Joomla\Utilities\GetHelper;
|
||||
|
||||
/**
|
||||
* Builder class
|
||||
*/
|
||||
@ -102,7 +106,7 @@ class Builder extends Mapping
|
||||
{
|
||||
// set the view object
|
||||
$object = new stdClass();
|
||||
$object->system_name = ComponentbuilderHelper::safeString($name, 'W') . ' (dynamic build)';
|
||||
$object->system_name = StringHelper::check($name, 'W') . ' (dynamic build)';
|
||||
$object->name_single = $name;
|
||||
$object->name_list = $name. 's';
|
||||
$object->short_description = $name. ' view (dynamic build)';
|
||||
@ -257,14 +261,14 @@ class Builder extends Mapping
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* get the field type id from system
|
||||
*/
|
||||
protected function getFieldType($fieldName)
|
||||
{
|
||||
// load the field settings
|
||||
return ComponentbuilderHelper::getVar('fieldtype', $fieldName, 'name', 'id');
|
||||
return GetHelper::var('fieldtype', $fieldName, 'name', 'id');
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -26,6 +26,9 @@
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use VDM\Joomla\Utilities\GetHelper;
|
||||
use VDM\Joomla\Utilities\ArrayHelper;
|
||||
|
||||
/**
|
||||
* Extrusion class
|
||||
*/
|
||||
@ -58,10 +61,10 @@ class Extrusion extends Builder
|
||||
protected function setAdminViews(&$component_id)
|
||||
{
|
||||
// check if views were set
|
||||
if (ComponentbuilderHelper::checkArray($this->views))
|
||||
if (ArrayHelper::check($this->views))
|
||||
{
|
||||
$count = 0;
|
||||
if (ComponentbuilderHelper::checkArray($this->addadmin_views))
|
||||
if (ArrayHelper::check($this->addadmin_views))
|
||||
{
|
||||
$count = (int) count((array)$this->addadmin_views) + 3;
|
||||
}
|
||||
@ -84,7 +87,7 @@ class Extrusion extends Builder
|
||||
$this->addadmin_views['addadmin_views'.$pointer]['order'] = $pointer + 1;
|
||||
}
|
||||
}
|
||||
if (isset($this->addadmin_views) && ComponentbuilderHelper::checkArray($this->addadmin_views))
|
||||
if (isset($this->addadmin_views) && ArrayHelper::check($this->addadmin_views))
|
||||
{
|
||||
// set the field object
|
||||
$object = new stdClass();
|
||||
@ -94,7 +97,7 @@ class Extrusion extends Builder
|
||||
$object->created_by = $this->user->id;
|
||||
$object->published = 1;
|
||||
// check if it is already set
|
||||
if ($item_id = ComponentbuilderHelper::getVar('component_admin_views', $component_id, 'joomla_component', 'id'))
|
||||
if ($item_id = GetHelper::var('component_admin_views', $component_id, 'joomla_component', 'id'))
|
||||
{
|
||||
// set ID
|
||||
$object->id = (int) $item_id;
|
||||
|
@ -1,7 +0,0 @@
|
||||
in
|
||||
public
|
||||
extends
|
||||
private
|
||||
protected
|
||||
implements
|
||||
instanceof
|
@ -1,28 +0,0 @@
|
||||
do
|
||||
in
|
||||
let
|
||||
new
|
||||
var
|
||||
case
|
||||
else
|
||||
enum
|
||||
void
|
||||
with
|
||||
class
|
||||
const
|
||||
yield
|
||||
delete
|
||||
export
|
||||
import
|
||||
public
|
||||
return
|
||||
static
|
||||
typeof
|
||||
extends
|
||||
package
|
||||
private
|
||||
continue
|
||||
function
|
||||
protected
|
||||
implements
|
||||
instanceof
|
@ -1,47 +0,0 @@
|
||||
do
|
||||
if
|
||||
in
|
||||
for
|
||||
let
|
||||
new
|
||||
try
|
||||
var
|
||||
case
|
||||
else
|
||||
enum
|
||||
eval
|
||||
null
|
||||
this
|
||||
true
|
||||
void
|
||||
with
|
||||
break
|
||||
catch
|
||||
class
|
||||
const
|
||||
false
|
||||
super
|
||||
throw
|
||||
while
|
||||
yield
|
||||
delete
|
||||
export
|
||||
import
|
||||
public
|
||||
return
|
||||
static
|
||||
switch
|
||||
typeof
|
||||
default
|
||||
extends
|
||||
finally
|
||||
package
|
||||
private
|
||||
continue
|
||||
debugger
|
||||
function
|
||||
arguments
|
||||
interface
|
||||
protected
|
||||
implements
|
||||
instanceof
|
@ -1,381 +0,0 @@
|
||||
<?php
|
||||
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
|
||||
__ __ _ _____ _ _ __ __ _ _ _
|
||||
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
|
||||
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
|
||||
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
|
||||
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
|
||||
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
|
||||
| |
|
||||
|_|
|
||||
/-------------------------------------------------------------------------------------------------------------------------------/
|
||||
|
||||
@version 2.6.x
|
||||
@created 30th April, 2015
|
||||
@package Component Builder
|
||||
@subpackage minify.php
|
||||
@author Llewellyn van der Merwe <http://joomlacomponentbuilder.com>
|
||||
@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');
|
||||
|
||||
/**
|
||||
* Abstract minifier class.
|
||||
*
|
||||
* Please report bugs on https://github.com/matthiasmullie/minify/issues
|
||||
*
|
||||
* @author Matthias Mullie <minify@mullie.eu>
|
||||
*
|
||||
* @copyright Copyright (c) 2012, Matthias Mullie. All rights reserved.
|
||||
* @license MIT License
|
||||
*/
|
||||
abstract class Minify
|
||||
{
|
||||
/**
|
||||
* The data to be minified
|
||||
*
|
||||
* @var string[]
|
||||
*/
|
||||
protected $data = array();
|
||||
|
||||
/**
|
||||
* Array of patterns to match.
|
||||
*
|
||||
* @var string[]
|
||||
*/
|
||||
protected $patterns = array();
|
||||
|
||||
/**
|
||||
* This array will hold content of strings and regular expressions that have
|
||||
* been extracted from the JS source code, so we can reliably match "code",
|
||||
* without having to worry about potential "code-like" characters inside.
|
||||
*
|
||||
* @var string[]
|
||||
*/
|
||||
public $extracted = array();
|
||||
|
||||
/**
|
||||
* Init the minify class - optionally, code may be passed along already.
|
||||
*/
|
||||
public function __construct(/* $data = null, ... */)
|
||||
{
|
||||
// it's possible to add the source through the constructor as well ;)
|
||||
if (func_num_args()) {
|
||||
call_user_func_array(array($this, 'add'), func_get_args());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Add a file or straight-up code to be minified.
|
||||
*
|
||||
* @param string $data
|
||||
*/
|
||||
public function add($data /* $data = null, ... */)
|
||||
{
|
||||
// bogus "usage" of parameter $data: scrutinizer warns this variable is
|
||||
// not used (we're using func_get_args instead to support overloading),
|
||||
// but it still needs to be defined because it makes no sense to have
|
||||
// this function without argument :)
|
||||
$args = array($data) + func_get_args();
|
||||
|
||||
// this method can be overloaded
|
||||
foreach ($args as $data) {
|
||||
// redefine var
|
||||
$data = (string) $data;
|
||||
|
||||
// load data
|
||||
$value = $this->load($data);
|
||||
$key = ($data != $value) ? $data : count($this->data);
|
||||
|
||||
// store data
|
||||
$this->data[$key] = $value;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Load data.
|
||||
*
|
||||
* @param string $data Either a path to a file or the content itself.
|
||||
* @return string
|
||||
*/
|
||||
protected function load($data)
|
||||
{
|
||||
// check if the data is a file
|
||||
if (@file_exists($data) && is_file($data)) {
|
||||
$data = @file_get_contents($data);
|
||||
|
||||
// strip BOM, if any
|
||||
if (substr($data, 0, 3) == "\xef\xbb\xbf") {
|
||||
$data = substr($data, 3);
|
||||
}
|
||||
}
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
/**
|
||||
* Save to file
|
||||
*
|
||||
* @param string $content The minified data.
|
||||
* @param string $path The path to save the minified data to.
|
||||
* @throws Exception
|
||||
*/
|
||||
protected function save($content, $path)
|
||||
{
|
||||
// create file & open for writing
|
||||
if (($handler = @fopen($path, 'w')) === false) {
|
||||
throw new Exception('The file "'.$path.'" could not be opened. Check if PHP has enough permissions.');
|
||||
}
|
||||
|
||||
// write to file
|
||||
if (@fwrite($handler, $content) === false) {
|
||||
throw new Exception('The file "'.$path.'" could not be written to. Check if PHP has enough permissions.');
|
||||
}
|
||||
|
||||
// close the file
|
||||
@fclose($handler);
|
||||
}
|
||||
|
||||
/**
|
||||
* Minify the data & (optionally) saves it to a file.
|
||||
*
|
||||
* @param string[optional] $path Path to write the data to.
|
||||
* @return string The minified data.
|
||||
*/
|
||||
public function minify($path = null)
|
||||
{
|
||||
$content = $this->execute($path);
|
||||
|
||||
// save to path
|
||||
if ($path !== null) {
|
||||
$this->save($content, $path);
|
||||
}
|
||||
|
||||
return $content;
|
||||
}
|
||||
|
||||
/**
|
||||
* Minify & gzip the data & (optionally) saves it to a file.
|
||||
*
|
||||
* @param string[optional] $path Path to write the data to.
|
||||
* @param int[optional] $level Compression level, from 0 to 9.
|
||||
* @return string The minified & gzipped data.
|
||||
*/
|
||||
public function gzip($path = null, $level = 9)
|
||||
{
|
||||
$content = $this->execute($path);
|
||||
$content = gzencode($content, $level, FORCE_GZIP);
|
||||
|
||||
// save to path
|
||||
if ($path !== null) {
|
||||
$this->save($content, $path);
|
||||
}
|
||||
|
||||
return $content;
|
||||
}
|
||||
|
||||
/**
|
||||
* Minify the data.
|
||||
*
|
||||
* @param string[optional] $path Path to write the data to.
|
||||
* @return string The minified data.
|
||||
*/
|
||||
abstract protected function execute($path = null);
|
||||
|
||||
/**
|
||||
* Register a pattern to execute against the source content.
|
||||
*
|
||||
* @param string $pattern PCRE pattern.
|
||||
* @param string|callable $replacement Replacement value for matched pattern.
|
||||
* @throws Exception
|
||||
*/
|
||||
protected function registerPattern($pattern, $replacement = '')
|
||||
{
|
||||
// study the pattern, we'll execute it more than once
|
||||
$pattern .= 'S';
|
||||
|
||||
$this->patterns[] = array($pattern, $replacement);
|
||||
}
|
||||
|
||||
/**
|
||||
* We can't "just" run some regular expressions against JavaScript: it's a
|
||||
* complex language. E.g. having an occurrence of // xyz would be a comment,
|
||||
* unless it's used within a string. Of you could have something that looks
|
||||
* like a 'string', but inside a comment.
|
||||
* The only way to accurately replace these pieces is to traverse the JS one
|
||||
* character at a time and try to find whatever starts first.
|
||||
*
|
||||
* @param string $content The content to replace patterns in.
|
||||
* @return string The (manipulated) content.
|
||||
*/
|
||||
protected function replace($content)
|
||||
{
|
||||
$processed = '';
|
||||
$positions = array_fill(0, count($this->patterns), -1);
|
||||
$matches = array();
|
||||
|
||||
while ($content) {
|
||||
// find first match for all patterns
|
||||
foreach ($this->patterns as $i => $pattern) {
|
||||
list($pattern, $replacement) = $pattern;
|
||||
|
||||
// no need to re-run matches that are still in the part of the
|
||||
// content that hasn't been processed
|
||||
if ($positions[$i] >= 0) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$match = null;
|
||||
if (preg_match($pattern, $content, $match)) {
|
||||
$matches[$i] = $match;
|
||||
|
||||
// we'll store the match position as well; that way, we
|
||||
// don't have to redo all preg_matches after changing only
|
||||
// the first (we'll still know where those others are)
|
||||
$positions[$i] = strpos($content, $match[0]);
|
||||
} else {
|
||||
// if the pattern couldn't be matched, there's no point in
|
||||
// executing it again in later runs on this same content;
|
||||
// ignore this one until we reach end of content
|
||||
unset($matches[$i]);
|
||||
$positions[$i] = strlen($content);
|
||||
}
|
||||
}
|
||||
|
||||
// no more matches to find: everything's been processed, break out
|
||||
if (!$matches) {
|
||||
$processed .= $content;
|
||||
break;
|
||||
}
|
||||
|
||||
// see which of the patterns actually found the first thing (we'll
|
||||
// only want to execute that one, since we're unsure if what the
|
||||
// other found was not inside what the first found)
|
||||
$discardLength = min($positions);
|
||||
$firstPattern = array_search($discardLength, $positions);
|
||||
$match = $matches[$firstPattern][0];
|
||||
|
||||
// execute the pattern that matches earliest in the content string
|
||||
list($pattern, $replacement) = $this->patterns[$firstPattern];
|
||||
$replacement = $this->replacePattern($pattern, $replacement, $content);
|
||||
|
||||
// figure out which part of the string was unmatched; that's the
|
||||
// part we'll execute the patterns on again next
|
||||
$content = substr($content, $discardLength);
|
||||
$unmatched = (string) substr($content, strpos($content, $match) + strlen($match));
|
||||
|
||||
// move the replaced part to $processed and prepare $content to
|
||||
// again match batch of patterns against
|
||||
$processed .= substr($replacement, 0, strlen($replacement) - strlen($unmatched));
|
||||
$content = $unmatched;
|
||||
|
||||
// first match has been replaced & that content is to be left alone,
|
||||
// the next matches will start after this replacement, so we should
|
||||
// fix their offsets
|
||||
foreach ($positions as $i => $position) {
|
||||
$positions[$i] -= $discardLength + strlen($match);
|
||||
}
|
||||
}
|
||||
|
||||
return $processed;
|
||||
}
|
||||
|
||||
/**
|
||||
* This is where a pattern is matched against $content and the matches
|
||||
* are replaced by their respective value.
|
||||
* This function will be called plenty of times, where $content will always
|
||||
* move up 1 character.
|
||||
*
|
||||
* @param string $pattern Pattern to match.
|
||||
* @param string|callable $replacement Replacement value.
|
||||
* @param string $content Content to match pattern against.
|
||||
* @return string
|
||||
*/
|
||||
protected function replacePattern($pattern, $replacement, $content)
|
||||
{
|
||||
if (is_callable($replacement)) {
|
||||
return preg_replace_callback($pattern, $replacement, $content, 1, $count);
|
||||
} else {
|
||||
return preg_replace($pattern, $replacement, $content, 1, $count);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Strings are a pattern we need to match, in order to ignore potential
|
||||
* code-like content inside them, but we just want all of the string
|
||||
* content to remain untouched.
|
||||
*
|
||||
* This method will replace all string content with simple STRING#
|
||||
* placeholder text, so we've rid all strings from characters that may be
|
||||
* misinterpreted. Original string content will be saved in $this->extracted
|
||||
* and after doing all other minifying, we can restore the original content
|
||||
* via restoreStrings()
|
||||
*
|
||||
* @param string[optional] $chars
|
||||
*/
|
||||
protected function extractStrings($chars = '\'"')
|
||||
{
|
||||
// PHP only supports $this inside anonymous functions since 5.4
|
||||
$minifier = $this;
|
||||
$callback = function ($match) use ($minifier) {
|
||||
if (!$match[1]) {
|
||||
/*
|
||||
* Empty strings need no placeholder; they can't be confused for
|
||||
* anything else anyway.
|
||||
* But we still needed to match them, for the extraction routine
|
||||
* to skip over this particular string.
|
||||
*/
|
||||
return $match[0];
|
||||
}
|
||||
|
||||
$count = count($minifier->extracted);
|
||||
$placeholder = $match[1].$count.$match[1];
|
||||
$minifier->extracted[$placeholder] = $match[1].$match[2].$match[1];
|
||||
|
||||
return $placeholder;
|
||||
};
|
||||
|
||||
/*
|
||||
* The \\ messiness explained:
|
||||
* * Don't count ' or " as end-of-string if it's escaped (has backslash
|
||||
* in front of it)
|
||||
* * Unless... that backslash itself is escaped (another leading slash),
|
||||
* in which case it's no longer escaping the ' or "
|
||||
* * So there can be either no backslash, or an even number
|
||||
* * multiply all of that times 4, to account for the escaping that has
|
||||
* to be done to pass the backslash into the PHP string without it being
|
||||
* considered as escape-char (times 2) and to get it in the regex,
|
||||
* escaped (times 2)
|
||||
*/
|
||||
$this->registerPattern('/(['.$chars.'])(.*?((?<!\\\\)|\\\\\\\\+))\\1/s', $callback);
|
||||
}
|
||||
|
||||
/**
|
||||
* This method will restore all extracted data (strings, regexes) that were
|
||||
* replaced with placeholder text in extract*(). The original content was
|
||||
* saved in $this->extracted.
|
||||
*
|
||||
* @param string $content
|
||||
* @return string
|
||||
*/
|
||||
protected function restoreExtractedData($content)
|
||||
{
|
||||
if (!$this->extracted) {
|
||||
// nothing was extracted, nothing to restore
|
||||
return $content;
|
||||
}
|
||||
|
||||
$content = strtr($content, $this->extracted);
|
||||
|
||||
$this->extracted = array();
|
||||
|
||||
return $content;
|
||||
}
|
||||
}
|
@ -1,45 +0,0 @@
|
||||
+
|
||||
-
|
||||
*
|
||||
/
|
||||
%
|
||||
=
|
||||
+=
|
||||
-=
|
||||
*=
|
||||
/=
|
||||
%=
|
||||
<<=
|
||||
>>=
|
||||
>>>=
|
||||
&=
|
||||
^=
|
||||
|=
|
||||
&
|
||||
|
|
||||
^
|
||||
~
|
||||
<<
|
||||
>>
|
||||
>>>
|
||||
==
|
||||
===
|
||||
!=
|
||||
!==
|
||||
>
|
||||
<
|
||||
>=
|
||||
<=
|
||||
&&
|
||||
||
|
||||
.
|
||||
[
|
||||
]
|
||||
?
|
||||
:
|
||||
,
|
||||
;
|
||||
(
|
||||
)
|
||||
{
|
||||
}
|
@ -1,43 +0,0 @@
|
||||
+
|
||||
-
|
||||
*
|
||||
/
|
||||
%
|
||||
=
|
||||
+=
|
||||
-=
|
||||
*=
|
||||
/=
|
||||
%=
|
||||
<<=
|
||||
>>=
|
||||
>>>=
|
||||
&=
|
||||
^=
|
||||
|=
|
||||
&
|
||||
|
|
||||
^
|
||||
~
|
||||
<<
|
||||
>>
|
||||
>>>
|
||||
==
|
||||
===
|
||||
!=
|
||||
!==
|
||||
>
|
||||
<
|
||||
>=
|
||||
<=
|
||||
&&
|
||||
||
|
||||
!
|
||||
.
|
||||
[
|
||||
?
|
||||
:
|
||||
,
|
||||
;
|
||||
(
|
||||
{
|
@ -416,8 +416,6 @@ COM_COMPONENTBUILDER_ADMIN_VIEWS_BATCH_USE="Admin Views Batch Use"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_BATCH_USE_DESC="Allows users in this group to use batch copy/update method of batch admin views"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_CREATE="Admin Views Create"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_CREATE_DESC="Allows the users in this group to create create admin views"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_ADD="Admin Views Dashboard Add"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_ADD_DESC="Allows the users in this group to dashboard add of admin view"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_LIST="Admin Views Dashboard List"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_LIST_DESC="Allows the users in this group to dashboard list of admin view"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_DELETE="Admin Views Delete"
|
||||
@ -1286,12 +1284,14 @@ COM_COMPONENTBUILDER_ADMIN_VIEW_YES="Yes"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEW_YOUTUBE="Youtube"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEW_ZOOM_IN="Zoom In"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEW_ZOOM_OUT="Zoom Out"
|
||||
COM_COMPONENTBUILDER_ADVANCED_OPTIONS="Advanced Options"
|
||||
COM_COMPONENTBUILDER_AHEAD="Ahead"
|
||||
COM_COMPONENTBUILDER_AHEAD_MEANS_YOUR_BLOCAL_SNIPPETB_WITH_THE_SAME_NAME_LIBRARY_AND_TYPE_HAS_A_BNEWER_MODIFIED_DATEB_THEN_THE_COMMUNITY_SNIPPET_WITH_THE_SAME_NAME_LIBRARY_AND_TYPE="Ahead means your <b>local snippet</b> (with the same name, library and type) has a <b>newer modified date</b> then the community snippet (with the same name, library and type)."
|
||||
COM_COMPONENTBUILDER_AJAX="Ajax"
|
||||
COM_COMPONENTBUILDER_ALIAS="Alias"
|
||||
COM_COMPONENTBUILDER_ALIGNMENT="Alignment"
|
||||
COM_COMPONENTBUILDER_ALL="All"
|
||||
COM_COMPONENTBUILDER_ALLOWS_YOU_TO_OVERRIDE_THE_BUILD_DATE_BY_SELECTING_A_DATE_MANUALLY_FROM_THE_CALENDER="Allows you to override the build date by selecting a date manually from the calender."
|
||||
COM_COMPONENTBUILDER_ALL_FOUND_INSTANCES_IN_S_WHERE_REPLACED="All found instances in %s where replaced"
|
||||
COM_COMPONENTBUILDER_ALL_IS_GOOD_PLEASE_CHECK_AGAIN_LATTER="All is good, please check again latter."
|
||||
COM_COMPONENTBUILDER_ALL_IS_GOOD_THERE_IS_NO_NOTICE_AT_THIS_TIME="All is good, there is no notice at this time."
|
||||
@ -1302,6 +1302,7 @@ COM_COMPONENTBUILDER_ALREADY_SELECTED_TRY_ANOTHER="Already selected, try another
|
||||
COM_COMPONENTBUILDER_ALREADY_TRANSLATED_INTO="Already translated into"
|
||||
COM_COMPONENTBUILDER_ALWAYS_ADD="Always Add"
|
||||
COM_COMPONENTBUILDER_ALWAYS_INSURE_THAT_YOU_HAVE_YOUR_LOCAL_COMPONENTS_BACKED_UP_BY_MAKING_AN_EXPORT_OF_ALL_YOUR_LOCAL_COMPONENTS_BEFORE_IMPORTING_ANY_NEW_COMPONENTS_SMALLMAKE_BSUREB_TO_MOVE_THIS_ZIPPED_BACKUP_PACKAGE_OUT_OF_THE_TMP_FOLDER_BEFORE_DOING_AN_IMPORTSMALLBR_IF_YOU_ARE_IMPORTING_A_PACKAGE_OF_A_THREERD_PARTY_JCB_PACKAGE_DEVELOPER_BMAKE_SURE_IT_IS_A_REPUTABLE_JCB_PACKAGE_DEVELOPERSB_A_SFIND_OUT_WHYA="Always insure that you have your local components backed up, by making an export of all your local components before importing any new components. <small>(Make <b>SURE</b> to move this zipped backup package out of the tmp folder before doing an import)</small><br />If you are importing a package of a 3rd party JCB package developer, <b>make sure it is a reputable JCB package developers!</b> <a %s>Find out why!</a>"
|
||||
COM_COMPONENTBUILDER_AND_FINISHED_THE_SEARCH_IN="and finished the search in"
|
||||
COM_COMPONENTBUILDER_ANY_LANGUAGE="Any language"
|
||||
COM_COMPONENTBUILDER_ANY_SELECTION_ONLY_FOUR_LISTRADIOCHECKBOXESDYNAMIC_LIST="Any Selection (only 4 list/radio/checkboxes/dynamic_list)"
|
||||
COM_COMPONENTBUILDER_AN_ERROR_HAS_OCCURRED="An error has occurred"
|
||||
@ -1312,12 +1313,14 @@ COM_COMPONENTBUILDER_ARE_YOU_SURE_YOU_WOULD_LIKE_TO_CONTINUE="Are you sure you w
|
||||
COM_COMPONENTBUILDER_ARE_YOU_SURE_YOU_WOULD_LIKE_TO_REPLACE_YOUR_LOCAL_SNIPPET_WITH_THIS_JCB_COMMUNITY_SNIPPET="Are you sure you would like to replace your local snippet with this JCB community snippet?"
|
||||
COM_COMPONENTBUILDER_ARE_YOU_SURE_YOU_WOULD_LIKE_TO_UPDATE_YOUR_LOCAL_SNIPPET_WITH_THIS_NEWER_JCB_COMMUNITY_SNIPPET="Are you sure you would like to update your local snippet with this newer JCB community snippet?"
|
||||
COM_COMPONENTBUILDER_ARE_YOU_SURE_YOU_WOULD_LIKE_TO_UPDATE_YOUR_LOCAL_SNIPPET_WITH_THIS_OLDER_JCB_COMMUNITY_SNIPPET="Are you sure you would like to update your local snippet with this older JCB community snippet?"
|
||||
COM_COMPONENTBUILDER_ARE_YOU_THEREFORE_ABSOLUTELY_SURE_YOU_WANT_TO_CONTINUE="Are you therefore absolutely sure you want to continue?"
|
||||
COM_COMPONENTBUILDER_AUTHOR="Author"
|
||||
COM_COMPONENTBUILDER_AUTHOR_EMAIL="Author Email"
|
||||
COM_COMPONENTBUILDER_AUTHOR_NAME="Author Name"
|
||||
COM_COMPONENTBUILDER_AUTHOR_WEBSITE="Author Website"
|
||||
COM_COMPONENTBUILDER_AUTO_CHECKIN="Auto Check-in"
|
||||
COM_COMPONENTBUILDER_AVAILABLE_LIBRARIES="Available Libraries"
|
||||
COM_COMPONENTBUILDER_A_METHOD_SETDYNAMICFZEROLDTHREERS_WAS_ADDED_TO_THE_INSTALL_BSCRIPTPHPB_OF_THIS_PACKAGE_TO_INSURE_THAT_THE_FOLDERS_ARE_COPIED_INTO_THE_CORRECT_PLACE_WHEN_THIS_COMPONENT_IS_INSTALLED="A method (setDynamicF0ld3rs) was added to the install <b>script.php</b> of this package to insure that the folder(s) are copied into the correct place when this component is installed!"
|
||||
COM_COMPONENTBUILDER_A_S_SPAN_CLASSICONFLAG_SPANREPORT_BROKEN_PACKAGEA="<a %s ><span class="icon-flag"> </span>Report Broken Package</a>"
|
||||
COM_COMPONENTBUILDER_BACK="Back"
|
||||
COM_COMPONENTBUILDER_BACKUP="Backup"
|
||||
@ -1331,9 +1334,12 @@ COM_COMPONENTBUILDER_BASIC_TUTORIAL_ON_GIT_BSB="Basic Tutorial on git: <b>%s</b>
|
||||
COM_COMPONENTBUILDER_BBEST_TO_NOT_CONTINUEBBR_WE_COULD_NOT_LOAD_THE_CHECKSUM_FOR_THIS_PACKAGE_AND_SO_NO_VALIDATION_WAS_POSSIBLE_THIS_MAY_BE_DUE_TO_YOUR_NETWORK_OR_A_CHANGE_TO_THAT_PACKAGE_NAME="<b>Best to not continue!</b><br />We could not load the checksum for this package, and so no validation was possible. This may be due to your network, or a change to that package name."
|
||||
COM_COMPONENTBUILDER_BBEST_TO_NOT_CONTINUEBBR_YOU_CAN_REFRESH_AND_TRY_AGAINBR_BUT_NOTE_THAT_THIS_PACKAGE_BFAILEDB_CHECKSUM_VALIDATION_THIS_COULD_BE_A_SERIOUS_SECURITY_BREACH_DO_NOT_CONTINUE="<b>Best to not continue!</b><br />You can Refresh and try again.<br />But note that this package <b>FAILED</b> checksum validation, this could be a serious security breach! DO NOT CONTINUE!!!"
|
||||
COM_COMPONENTBUILDER_BCUSTOM_FILESB_NOT_MOVED_TO_CORRECT_LOCATION="<b>Custom files</b> not moved to correct location!"
|
||||
COM_COMPONENTBUILDER_BECOME_A_CONTRIBUTOR="Become a Contributor"
|
||||
COM_COMPONENTBUILDER_BEHAVIOUR="Behaviour"
|
||||
COM_COMPONENTBUILDER_BEHIND="Behind"
|
||||
COM_COMPONENTBUILDER_BEHIND_MEANS_YOUR_BLOCAL_SNIPPETB_WITH_THE_SAME_NAME_LIBRARY_AND_TYPE_HAS_A_BOLDER_MODIFIED_DATEB_THEN_THE_COMMUNITY_SNIPPET_WITH_THE_SAME_NAME_LIBRARY_AND_TYPE="Behind means your <b>local snippet</b> (with the same name, library and type) has a <b>older modified date</b> then the community snippet (with the same name, library and type)."
|
||||
COM_COMPONENTBUILDER_BETA_RELEASE="Beta Release"
|
||||
COM_COMPONENTBUILDER_BE_A_PART_OF_JCB="Be a Part of JCB"
|
||||
COM_COMPONENTBUILDER_BE_CAUTIOUS_DO_NOT_CONTINUE_UNLESS_YOU_TRUST_THE_ORIGIN_OF_THIS_PACKAGE="Be cautious! Do not continue unless you trust the origin of this package!"
|
||||
COM_COMPONENTBUILDER_BFIELD_TYPEB_IDS_MISMATCH_IN_BSB="<b>Field type</b> id:%s mismatch in <b>%s</b>."
|
||||
COM_COMPONENTBUILDER_BFIELD_TYPEB_NOT_SET_FOR_BSB="<b>Field type</b> not set for <b>%s</b>."
|
||||
@ -1351,6 +1357,7 @@ COM_COMPONENTBUILDER_BTHE_EXPANSION_WAS_SUCCESSFULLYB_TO_SEE_MORE_INFORMATION_CH
|
||||
COM_COMPONENTBUILDER_BTHE_TMP_FOLDER_HAS_BEEN_CLEAR_SUCCESSFULLYB="<b>The tmp folder has been clear successfully!</b>"
|
||||
COM_COMPONENTBUILDER_BUILD="Build"
|
||||
COM_COMPONENTBUILDER_BUILDIN="Build-in"
|
||||
COM_COMPONENTBUILDER_BUILD_DATE="Build Date"
|
||||
COM_COMPONENTBUILDER_BULK="Bulk"
|
||||
COM_COMPONENTBUILDER_BULK_GET_ALL_NEW_SNIPPETS="Bulk Get All New Snippets"
|
||||
COM_COMPONENTBUILDER_BULK_TOOLS="Bulk Tools"
|
||||
@ -1650,6 +1657,7 @@ COM_COMPONENTBUILDER_CLASS_PROPERTY_VERSION_DESC="A count of the number of times
|
||||
COM_COMPONENTBUILDER_CLASS_PROPERTY_VERSION_LABEL="Version"
|
||||
COM_COMPONENTBUILDER_CLASS_PROPERTY_VISIBILITY_DESCRIPTION="The visibility of a function/method or property can be defined by prefixing the declaration with the keywords public, protected or private. You also have the option to make function/method or property static."
|
||||
COM_COMPONENTBUILDER_CLASS_PROPERTY_VISIBILITY_LABEL="Visibility"
|
||||
COM_COMPONENTBUILDER_CLEAR="Clear"
|
||||
COM_COMPONENTBUILDER_CLEAR_TMP="Clear tmp"
|
||||
COM_COMPONENTBUILDER_CLONE="Clone"
|
||||
COM_COMPONENTBUILDER_CLONE_FAILED="Clone failed!"
|
||||
@ -1721,6 +1729,7 @@ COM_COMPONENTBUILDER_COMPONENTS_ADMIN_VIEWS_N_ITEMS_UNFEATURED="%s Components Ad
|
||||
COM_COMPONENTBUILDER_COMPONENTS_ADMIN_VIEWS_N_ITEMS_UNFEATURED_1="%s Component Admin Views unfeatured."
|
||||
COM_COMPONENTBUILDER_COMPONENTS_ADMIN_VIEWS_N_ITEMS_UNPUBLISHED="%s Components Admin Views unpublished."
|
||||
COM_COMPONENTBUILDER_COMPONENTS_ADMIN_VIEWS_N_ITEMS_UNPUBLISHED_1="%s Component Admin Views unpublished."
|
||||
COM_COMPONENTBUILDER_COMPONENTS_BR_SMALLDISABLED_SOONSMALL="Components <br /><small>(disabled... soon!)</small>"
|
||||
COM_COMPONENTBUILDER_COMPONENTS_CONFIG="Components Config"
|
||||
COM_COMPONENTBUILDER_COMPONENTS_CONFIG_ACCESS="Components Config Access"
|
||||
COM_COMPONENTBUILDER_COMPONENTS_CONFIG_ACCESS_DESC="Allows the users in this group to access access components config"
|
||||
@ -3663,6 +3672,7 @@ COM_COMPONENTBUILDER_CONFIG_VIEW_FIELD_LABEL="View & Field"
|
||||
COM_COMPONENTBUILDER_CONFIG_YES="Yes"
|
||||
COM_COMPONENTBUILDER_CONFIRMATION_STEP_BEFORE_IMPORTING="Confirmation Step Before Importing!"
|
||||
COM_COMPONENTBUILDER_CONTEXT="Context"
|
||||
COM_COMPONENTBUILDER_CONTRIBUTE_TO_JCB="Contribute to JCB"
|
||||
COM_COMPONENTBUILDER_CONTRIBUTOR="Contributor"
|
||||
COM_COMPONENTBUILDER_CONTRIBUTORS="Contributors"
|
||||
COM_COMPONENTBUILDER_COPYRIGHT="Copyright"
|
||||
@ -3686,8 +3696,6 @@ COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_BATCH_USE="Custom Admin Views Batch Use"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_BATCH_USE_DESC="Allows users in this group to use batch copy/update method of batch custom admin views"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_CREATE="Custom Admin Views Create"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_CREATE_DESC="Allows the users in this group to create create custom admin views"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_ADD="Custom Admin Views Dashboard Add"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_ADD_DESC="Allows the users in this group to dashboard add of custom admin view"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_LIST="Custom Admin Views Dashboard List"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_LIST_DESC="Allows the users in this group to dashboard list of custom admin view"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DELETE="Custom Admin Views Delete"
|
||||
@ -4352,10 +4360,8 @@ COM_COMPONENTBUILDER_DASH="Dashboard"
|
||||
COM_COMPONENTBUILDER_DASHBOARD="Component Builder Dashboard"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_ADD_RECORD="Dashboard (add record)"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_ADMIN_VIEWS="Admin Views<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_ADMIN_VIEW_ADD="Add Admin View<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_COMPILER="Compiler<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_CUSTOM_ADMIN_VIEWS="Custom Admin Views<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_CUSTOM_ADMIN_VIEW_ADD="Add Custom Admin View<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_CUSTOM_CODES="Custom Codes<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_DYNAMIC_GETS="Dynamic Gets<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_DYNAMIC_GET_ADD="Add Dynamic Get<br /><br />"
|
||||
@ -4376,9 +4382,9 @@ COM_COMPONENTBUILDER_DASHBOARD_LIBRARIES="Libraries<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_LIST_OF_RECORDS="Dashboard (list of records)"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_PLACEHOLDERS="Placeholders<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_POWERS="Powers<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_SEARCH="Search<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_SERVERS="Servers<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_SITE_VIEWS="Site Views<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_SITE_VIEW_ADD="Add Site View<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_SNIPPETS="Snippets<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_TEMPLATES="Templates<br /><br />"
|
||||
COM_COMPONENTBUILDER_DASHBOARD_TEMPLATE_ADD="Add Template<br /><br />"
|
||||
@ -4394,6 +4400,8 @@ COM_COMPONENTBUILDER_DISPLAY_SWITCH_FOR_DYNAMIC_PLACEMENT_IN_RELATION_TO_THE_USE
|
||||
COM_COMPONENTBUILDER_DIVERGED="Diverged"
|
||||
COM_COMPONENTBUILDER_DIVERGED_MEANS_YOUR_BLOCAL_SNIPPETB_WITH_THE_SAME_NAME_LIBRARY_AND_TYPE_HAS_A_BDIVERGEDB_FROM_THE_COMMUNITY_SNIPPET_WITH_THE_SAME_NAME_LIBRARY_AND_TYPE_IN_THAT_IT_DOES_NOT_HAVE_THE_SAME_BCREATIONB_OR_BMODIFIED_DATEB="Diverged means your <b>local snippet</b> (with the same name, library and type) has a <b>diverged</b> from the community snippet (with the same name, library and type) in that it does not have the same <b>creation</b> or <b>modified date</b>."
|
||||
COM_COMPONENTBUILDER_DOES_THIS_PACKAGE_REQUIRE_A_KEY_TO_INSTALL="Does this package require a key to install."
|
||||
COM_COMPONENTBUILDER_DONATE_TO_JCB="Donate to JCB"
|
||||
COM_COMPONENTBUILDER_DONATIONS="Donations!"
|
||||
COM_COMPONENTBUILDER_DOWNLOAD_UPDATE="Download Update"
|
||||
COM_COMPONENTBUILDER_DO_NOT_ADD="Do not add"
|
||||
COM_COMPONENTBUILDER_DTCOMPANYDTDDSDD="<dt>Company</dt><dd>%s</dd>"
|
||||
@ -4704,9 +4712,11 @@ COM_COMPONENTBUILDER_EDIT_CREATED_DATE="Edit Created Date"
|
||||
COM_COMPONENTBUILDER_EDIT_CREATED_DATE_DESC="Allows users in this group to edit created date."
|
||||
COM_COMPONENTBUILDER_EDIT_S="Edit %s"
|
||||
COM_COMPONENTBUILDER_EDIT_S_FOR_THIS_S="Edit %s for this %s"
|
||||
COM_COMPONENTBUILDER_EDIT_S_S_DIRECTLY="Edit %s (%s) directly"
|
||||
COM_COMPONENTBUILDER_EDIT_VERSIONS="Edit Version"
|
||||
COM_COMPONENTBUILDER_EDIT_VERSIONS_DESC="Allows users in this group to edit versions."
|
||||
COM_COMPONENTBUILDER_EDIT_VIEW="Edit View"
|
||||
COM_COMPONENTBUILDER_ELEVATE_JCB_TODAY="Elevate JCB Today"
|
||||
COM_COMPONENTBUILDER_EMAIL="Email"
|
||||
COM_COMPONENTBUILDER_EMAIL_S="Email %s"
|
||||
COM_COMPONENTBUILDER_EMAIL_WITH_THE_NEW_KEY_WAS_SENT="Email with the new key was sent"
|
||||
@ -4715,8 +4725,12 @@ COM_COMPONENTBUILDER_EMCOPYRIGHTEM_BSB="<em>Copyright:</em> <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_EMEMAILEM_BSB="<em>Email:</em> <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_EMLICENSEEM_BSB="<em>License:</em> <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_EMOWNEREM_BSB="<em>Owner:</em> <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_EMPOWER_JCB="Empower JCB"
|
||||
COM_COMPONENTBUILDER_EMPOWER_THE_FUTURE_WITH_JCB="Empower the Future with JCB"
|
||||
COM_COMPONENTBUILDER_EMPTY_TRASH="Empty trash"
|
||||
COM_COMPONENTBUILDER_EMWEBSITEEM_BSB="<em>Website:</em> <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_ENTER_YOUR_REPLACE_TEXT="Enter your replace text"
|
||||
COM_COMPONENTBUILDER_ENTER_YOUR_SEARCH_TEXT="Enter your search text"
|
||||
COM_COMPONENTBUILDER_EQUAL="Equal"
|
||||
COM_COMPONENTBUILDER_EQUAL_MEANS_THAT_THE_COMMUNITY_SNIPPET_WITH_THE_SAME_NAME_LIBRARY_AND_TYPE_AND_YOUR_LOCAL_SNIPPET_WITH_THE_SAME_NAME_LIBRARY_AND_TYPE_HAS_THE_SAME_BCREATIONB_AND_BMODIFIED_DATEB="Equal means that the community snippet (with the same name, library and type) and your local snippet (with the same name, library and type) has the same <b>creation</b> and <b>modified date</b>."
|
||||
COM_COMPONENTBUILDER_ERROR="Error"
|
||||
@ -4789,6 +4803,7 @@ COM_COMPONENTBUILDER_FIELDS_N_ITEMS_UNPUBLISHED="%s Fields unpublished."
|
||||
COM_COMPONENTBUILDER_FIELDS_N_ITEMS_UNPUBLISHED_1="%s Field unpublished."
|
||||
COM_COMPONENTBUILDER_FIELDS_SUBMENU="Fields Submenu"
|
||||
COM_COMPONENTBUILDER_FIELDS_SUBMENU_DESC="Allows the users in this group to submenu of field"
|
||||
COM_COMPONENTBUILDER_FIELDS_THAT_HAD="fields that had"
|
||||
COM_COMPONENTBUILDER_FIELDTYPE="Fieldtype"
|
||||
COM_COMPONENTBUILDER_FIELDTYPES="Fieldtypes"
|
||||
COM_COMPONENTBUILDER_FIELDTYPES_ACCESS="Fieldtypes Access"
|
||||
@ -5030,6 +5045,7 @@ $mediumkey = ComponentbuilderHelper::getCryptKey('medium');
|
||||
$medium = new FOFEncryptAes($mediumkey);"
|
||||
COM_COMPONENTBUILDER_FIELD_INITIATOR_ON_SAVE_MODEL_LABEL="Initiator<br /><small>on save model</small>"
|
||||
COM_COMPONENTBUILDER_FIELD_INT="INT"
|
||||
COM_COMPONENTBUILDER_FIELD_IN_THE="field in the"
|
||||
COM_COMPONENTBUILDER_FIELD_JAVASCRIPT_VIEWS_FOOTER_DESCRIPTION="Add JavaScript for the list view that is loaded in the footer inside script tags. Do not add the script tags."
|
||||
COM_COMPONENTBUILDER_FIELD_JAVASCRIPT_VIEWS_FOOTER_LABEL="Javascript (list view footer)"
|
||||
COM_COMPONENTBUILDER_FIELD_JAVASCRIPT_VIEW_FOOTER_DESCRIPTION="Add JavaScript for the edit view that is loaded in the footer inside script tags. Do not add the script tags."
|
||||
@ -5444,6 +5460,9 @@ COM_COMPONENTBUILDER_FOLDER_BSB_WAS_MOVED_TO_BSB="Folder <b>%s</b> was moved to
|
||||
COM_COMPONENTBUILDER_FOLDER_BSB_WAS_NOT_MOVED_TO_BSB="Folder <b>%s</b> was not moved to <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_FORCE_LOCAL_UPDATE="Force Local Update"
|
||||
COM_COMPONENTBUILDER_FORCE_THAT_THIS_JCB_PACKAGE_IMPORT_SEARCH_FOR_LOCAL_ITEMS_TO_BE_DONE_WITH_GUID_VALUE_ONLY_IF_BMERGEB_IS_SET_TO_YES_ABOVE="Force that this JCB package import (search for local items) to be done with GUID value only, if <b>Merge</b> is set to yes above."
|
||||
COM_COMPONENTBUILDER_FOUND="Found"
|
||||
COM_COMPONENTBUILDER_FOUND_TEXT="Found Text"
|
||||
COM_COMPONENTBUILDER_FOUR_SPACES="4 Spaces"
|
||||
COM_COMPONENTBUILDER_FREEOPEN="Free/Open"
|
||||
COM_COMPONENTBUILDER_FULL_WIDTH_IN_TAB="Full Width in Tab"
|
||||
COM_COMPONENTBUILDER_FUNCTION_NAME_ALREADY_TAKEN_PLEASE_TRY_AGAIN="Function name already taken, please try again."
|
||||
@ -5480,6 +5499,7 @@ COM_COMPONENTBUILDER_GET_THE_SNIPPET_FROM_GITHUB_AND_INSTALL_IT_LOCALLY="Get the
|
||||
COM_COMPONENTBUILDER_GET_THE_SNIPPET_FROM_GITHUB_AND_UPDATE_THE_LOCAL_VERSION="Get the snippet from gitHub and update the local version"
|
||||
COM_COMPONENTBUILDER_GET_TOKEN="Get Token"
|
||||
COM_COMPONENTBUILDER_GET_TOKEN_FROM_VDM_TO_GET_UPDATE_NOTICE_AND_ADD_IT_TO_YOUR_GLOBAL_OPTIONS="Get token from VDM to get update notice, and add it to your global options."
|
||||
COM_COMPONENTBUILDER_GIVE_TO_JCB="Give to JCB"
|
||||
COM_COMPONENTBUILDER_GLOBAL="Global"
|
||||
COM_COMPONENTBUILDER_GLUECODE="Glue/Code"
|
||||
COM_COMPONENTBUILDER_GREAT_THIS_FUNCTION_NAME_WILL_WORK="Great, this function name will work!"
|
||||
@ -5487,6 +5507,7 @@ COM_COMPONENTBUILDER_GREAT_THIS_PLACEHOLDER_WILL_WORK="Great, this placeholder w
|
||||
COM_COMPONENTBUILDER_GREAT_THIS_VALIDATION_RULE_NAME_S_WILL_WORK="Great, this validation rule name (%s) will work!"
|
||||
COM_COMPONENTBUILDER_GROUP="group"
|
||||
COM_COMPONENTBUILDER_HAS_METADATA="Has Metadata"
|
||||
COM_COMPONENTBUILDER_HEADERS="Headers"
|
||||
COM_COMPONENTBUILDER_HELP_DOCUMENT="Help Document"
|
||||
COM_COMPONENTBUILDER_HELP_DOCUMENTS="Help Documents"
|
||||
COM_COMPONENTBUILDER_HELP_DOCUMENTS_ACCESS="Help Documents Access"
|
||||
@ -5586,7 +5607,10 @@ COM_COMPONENTBUILDER_HELP_DOCUMENT_URL_LABEL="URL"
|
||||
COM_COMPONENTBUILDER_HELP_DOCUMENT_URL_MESSAGE="Error! Please add url here."
|
||||
COM_COMPONENTBUILDER_HELP_DOCUMENT_VERSION_DESC="A count of the number of times this Help Document has been revised."
|
||||
COM_COMPONENTBUILDER_HELP_DOCUMENT_VERSION_LABEL="Version"
|
||||
COM_COMPONENTBUILDER_HELP_JCB_GROW="Help JCB Grow"
|
||||
COM_COMPONENTBUILDER_HELP_MANAGER="Help"
|
||||
COM_COMPONENTBUILDER_HERE_YOU_CAN_ENTER_THE_REPLACE_TEXT_THAT_YOU_WOULD_LIKE_TO_USE_AS_REPLACEMENT_FOR_THE_SEARCH_TEXT_FOUND="Here you can enter the replace text that you would like to use as replacement for the search text found."
|
||||
COM_COMPONENTBUILDER_HERE_YOU_CAN_ENTER_YOUR_SEARCH_TEXT="Here you can enter your search text."
|
||||
COM_COMPONENTBUILDER_HFOUR_CLASSNAVHEADERCOPYRIGHTHFOURPSP="<h4 class="nav-header">Copyright</h4><p>%s</p>"
|
||||
COM_COMPONENTBUILDER_HFOUR_CLASSNAVHEADERLICENSEHFOURPSP="<h4 class="nav-header">License</h4><p>%s</p>"
|
||||
COM_COMPONENTBUILDER_HI="Hi"
|
||||
@ -5594,9 +5618,15 @@ COM_COMPONENTBUILDER_HIDE_ONLY="Hide Only"
|
||||
COM_COMPONENTBUILDER_HIDE_TOGGLE="Hide Toggle"
|
||||
COM_COMPONENTBUILDER_HOW_TO_GET_A_S_FREE_KEYSA_FROM_VDM="How to get <a %s >free keys</a> from VDM."
|
||||
COM_COMPONENTBUILDER_HR_HTHREECUSTOM_CODES_WARNINGHTHREE="<hr /><h3>Custom Codes Warning</h3>"
|
||||
COM_COMPONENTBUILDER_HR_HTHREECZEROMPZERONTHREENT_ISSUE_FOUNDHTHREEPTHE_PATH_S_COULD_NOT_BE_USEDP="<hr /><h3>c0mp0n3nt issue found</h3><p>The path (%s) could not be used.</p>"
|
||||
COM_COMPONENTBUILDER_HR_HTHREEDASHBOARD_ERRORHTHREE="<hr /><h3>Dashboard Error</h3>"
|
||||
COM_COMPONENTBUILDER_HR_HTHREEDYNAMIC_FOLDERS_WERE_DETECTEDHTHREE="<hr /><h3>Dynamic folder(s) were detected.</h3>"
|
||||
COM_COMPONENTBUILDER_HR_HTHREEEXTERNAL_CODE_ERRORHTHREE="<hr /><h3>External Code Error</h3>"
|
||||
COM_COMPONENTBUILDER_HR_HTHREEEXTERNAL_CODE_NOTICEHTHREE="<hr /><h3>External Code Notice</h3>"
|
||||
COM_COMPONENTBUILDER_HR_HTHREEEXTERNAL_CODE_WARNINGHTHREE="<hr /><h3>External Code Warning</h3>"
|
||||
COM_COMPONENTBUILDER_HR_HTHREEFIELD_NOTICEHTHREE="<hr /><h3>Field Notice</h3>"
|
||||
COM_COMPONENTBUILDER_HR_HTHREEFILE_PATH_ERRORHTHREE="<hr /><h3>File Path Error</h3>"
|
||||
COM_COMPONENTBUILDER_HR_HTHREEFOLDER_PATH_ERRORHTHREE="<hr /><h3>Folder Path Error</h3>"
|
||||
COM_COMPONENTBUILDER_HTHREEPLACEHOLDER_REMOVEDHTHREEPBTHISB_CUSTOM_CODE_CAN_ONLY_BE_USED_IN_BOTHERB_CUSTOM_CODE_NOT_IN_IT_SELF_SINCE_THAT_WILL_CAUSE_A_INFINITE_LOOP_IN_THE_COMPILERP="<h3>Placeholder Removed!</h3><p><b>This</b> custom code can only be used in <b>other</b> custom code, not in it self! Since that will cause a infinite loop in the compiler.</p>"
|
||||
COM_COMPONENTBUILDER_HTHREESHTHREEPCUSTOM_CODE_CAN_ONLY_BE_USED_IN_OTHER_CUSTOM_CODE_IF_SET_AS_BJCB_MANUALB_YOU_CAN_NOT_ADD_THEM_TO_EMHASH_AUTOMATIONEM_CODE_AT_THIS_POINTP="<h3>%s</h3><p>Custom code can only be used in other custom code if set as <b>JCB (manual)</b>, you can not add them to <em>Hash (Automation)</em> code at this point.</p>"
|
||||
COM_COMPONENTBUILDER_HTHREES_NAMESPACE_ERROR_SHTHREEPYOU_MUST_ATLEAST_HAVE_TWO_SECTIONS_IN_YOUR_NAMESPACE_YOU_JUST_HAVE_ONE_S_THIS_IS_AN_UNACCEPTABLE_ACTION_PLEASE_SEE_A_HREFS_PSRFOURA_FOR_MORE_INFOPPTHIS_S_WAS_THEREFORE_REMOVED_A_HREFSCLICK_HEREA_TO_FIX_THIS_ISSUEP="<h3>%s namespace error (%s)</h3><p>You must at-least have two sections in your namespace, you just have one (%s). This is an unacceptable action, please see <a href=%s >psr-4</a> for more info.</p><p>This %s was therefore removed, <a href=%s>click here</a> to fix this issue.</p>"
|
||||
@ -5604,11 +5634,12 @@ COM_COMPONENTBUILDER_HTHREES_NAMESPACE_ERROR_SHTHREEPYOU_MUST_ATLEAST_HAVE_TWO_S
|
||||
COM_COMPONENTBUILDER_HTWOCURL_NOT_FOUNDHTWOPPLEASE_SETUP_CURL_ON_YOUR_SYSTEM_OR_BCOMPONENTBUILDERB_WILL_NOT_FUNCTION_CORRECTLYP="<h2>Curl Not Found!</h2><p>Please setup curl on your system, or <b>componentbuilder</b> will not function correctly!</p>"
|
||||
COM_COMPONENTBUILDER_HTWODATA_IS_CORRUPTHTWOTHIS_COULD_BE_DUE_TO_BKEY_ERRORB_OR_BROKEN_PACKAGE="<h2>Data is corrupt!</h2>This could be due to <b>key error</b>, or broken package!"
|
||||
COM_COMPONENTBUILDER_HTWODATA_IS_CORRUPTHTWOTHIS_COULD_BE_DUE_TO_BROKEN_PACKAGE="<h2>Data is corrupt!</h2>This could be due to broken package!"
|
||||
COM_COMPONENTBUILDER_HTWOWE_COULD_NOT_OPEN_THE_ENCRYPT_DATAHTWO_THIS_COULD_BE_DUE_TO_THE_FOFENCRYPTION_THAT_IS_NO_LONGER_SUPPORTED_IN_JOOMLABR_PLEASE_EXPORT_YOUR_PACKAGES_WITH_JCB_VTHREEZEROELEVENPRO_OR_VTWOONETWOSEVENTEENPUBLIC_OR_HIGHER_TO_BE_ABLE_TO_IMPORT_IT_INTO_THIS_VERSION_OF_JCB="<h2>We could not open the encrypt data!</h2> This could be due to the FOFEncryption that is no longer supported in Joomla.<br />Please export your packages with JCB v3.0.11(pro) or v2.12.17(public) or higher to be able to import it into this version of JCB."
|
||||
COM_COMPONENTBUILDER_HTWOWE_COULD_NOT_OPEN_THE_ENCRYPT_DATAHTWO_THIS_COULD_BE_DUE_TO_THE_FOFENCRYPTION_THAT_IS_NO_LONGER_SUPPORTED_IN_JOOMLABR_PLEASE_EXPORT_YOUR_PACKAGES_WITH_JCB_VTHREEONEONENINE_OR_HIGHER_TO_BE_ABLE_TO_IMPORT_IT_INTO_THIS_VERSION_OF_JCB="<h2>We could not open the encrypt data!</h2> This could be due to the FOFEncryption that is no longer supported in Joomla.<br />Please export your packages with JCB v3.1.19 or higher to be able to import it into this version of JCB."
|
||||
COM_COMPONENTBUILDER_HTWOWE_COULD_NOT_OPEN_THE_PACKAGEHTWOTHIS_COULD_BE_DUE_TO_THE_FOFENCRYPTION_THAT_IS_NO_LONGER_SUPPORTED_IN_JOOMLA_PLEASE_EXPORT_YOUR_PACKAGES_WITH_JCB_VTHREEZEROELEVENPRO_OR_VTWOONETWOSEVENTEENPUBLIC_OR_HIGHER_TO_BE_ABLE_TO_IMPORT_IT_INTO_THIS_VERSION_OF_JCB="<h2>We could not open the package!</h2>This could be due to the FOFEncryption that is no longer supported in Joomla. Please export your packages with JCB v3.0.11(pro) or v2.12.17(public) or higher to be able to import it into this version of JCB."
|
||||
COM_COMPONENTBUILDER_IAUTHORI_BSB="<i>Author:</i> <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_ICOMPANYI_BSB="<i>Company:</i> <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_ICON="Icon"
|
||||
COM_COMPONENTBUILDER_ID="id"
|
||||
COM_COMPONENTBUILDER_ID_MISMATCH_WAS_DETECTED_WITH_THE_SSSS_GUI_CODE_FIELD_SO_THE_PLACEHOLDER_WAS_NOT_SET="ID mismatch was detected with the %s.%s.%s.%s GUI code field. So the placeholder was not set."
|
||||
COM_COMPONENTBUILDER_IEMAILI_BSB="<i>Email:</i> <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_IMPORT_BY_GUID_ONLY="Import by GUID only!"
|
||||
@ -5670,20 +5701,77 @@ COM_COMPONENTBUILDER_IMPORT_UNABLE_TO_FIND_IMPORT_PACKAGE="Package to import not
|
||||
COM_COMPONENTBUILDER_IMPORT_UPDATE_DATA="Import Data"
|
||||
COM_COMPONENTBUILDER_IMPORT_UPLOAD_BOTTON="Upload File"
|
||||
COM_COMPONENTBUILDER_INACTIVE="Inactive"
|
||||
COM_COMPONENTBUILDER_INDENTATION_OPTIONS="Indentation Options"
|
||||
COM_COMPONENTBUILDER_INVEST_IN_JCB="Invest in JCB"
|
||||
COM_COMPONENTBUILDER_INVEST_IN_THE_FUTURE_OF_JOOMLA_COMPONENT_BUILDER_JCB_BY_MAKING_A_BFINANCIAL_CONTRIBUTIONB_NO_MATTER_HOW_SMALL_THE_CONTINUAL_SUPPORT_OF_ALL_THOSE_USING_THE_TOOL_WILL_BE_MORE_THAN_ENOUGH_TO_ENSURE_ITS_CONTINUED_GROWTH_AND_RELEVANCE_BY_INVESTING_IN_THIS_OPENSOURCE_PROJECT_YOU_ARE_SECURING_ITS_FUTURE_AS_A_VITAL_TOOL_FOR_PHP_PROGRAMMERS="Invest in the future of Joomla Component Builder (JCB) by making a <b>financial contribution</b>, no matter how small. The continual support of all those using the tool will be more than enough to ensure its continued growth and relevance. By investing in this open-source project, you are securing its future as a vital tool for PHP programmers."
|
||||
COM_COMPONENTBUILDER_INVEST_IN_THE_FUTURE_OF_JOOMLA_COMPONENT_BUILDER_JCB_BY_MAKING_A_BFINANCIAL_DONATIONB_SUPPORT_THE_NECESSARY_DEVELOPMENT_AND_MAINTENANCE_OF_THIS_OPENSOURCE_PROJECT_ENSURING_ITS_CONTINUED_GROWTH_AND_RELEVANCE_FOR_THE_COMMUNITY_YOUR_CONTRIBUTION_WILL_HELP_SECURE_THE_FUTURE_OF_THIS_VITAL_TOOL_FOR_PHP_PROGRAMMERS="Invest in the future of Joomla Component Builder (JCB) by making a <b>financial donation</b>. Support the necessary development and maintenance of this open-source project, ensuring its continued growth and relevance for the community. Your contribution will help secure the future of this vital tool for PHP programmers."
|
||||
COM_COMPONENTBUILDER_IN_SYNC="In Sync"
|
||||
COM_COMPONENTBUILDER_ISOLATE="Isolate"
|
||||
COM_COMPONENTBUILDER_IS_BEING_COMPILED="is being compiled"
|
||||
COM_COMPONENTBUILDER_IS_NOT_ONLY_FOUR_LISTRADIOCHECKBOXES="Is Not (only 4 list/radio/checkboxes)"
|
||||
COM_COMPONENTBUILDER_IS_ONLY_FOUR_LISTRADIOCHECKBOXES="Is (only 4 list/radio/checkboxes)"
|
||||
COM_COMPONENTBUILDER_ITEM_CODE="Item Code"
|
||||
COM_COMPONENTBUILDER_IWEBSITEI_BSB="<i>Website:</i> <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_JCB_BE_THE_CHANGE="JCB: Be the Change"
|
||||
COM_COMPONENTBUILDER_JCB_BUILDS_A_BETTER_FUTURE="JCB Builds a Better Future"
|
||||
COM_COMPONENTBUILDER_JCB_COMMUNITY="JCB Community"
|
||||
COM_COMPONENTBUILDER_JCB_COMMUNITY_PACKAGES="JCB Community Packages"
|
||||
COM_COMPONENTBUILDER_JCB_COMMUNITY_SNIPPETS="JCB Community Snippets"
|
||||
COM_COMPONENTBUILDER_JCB_CONTRIBUTES_TO_OPENSOURCE="JCB Contributes to Open-Source"
|
||||
COM_COMPONENTBUILDER_JCB_EMPOWERS_PHP_DEVELOPERS="JCB Empowers PHP Developers"
|
||||
COM_COMPONENTBUILDER_JCB_ENABLES_PHP_DEVELOPMENT="JCB Enables PHP Development"
|
||||
COM_COMPONENTBUILDER_JCB_ENHANCES_PRODUCTIVITY="JCB Enhances Productivity"
|
||||
COM_COMPONENTBUILDER_JCB_FOSTERS_A_STRONG_COMMUNITY="JCB Fosters a Strong Community"
|
||||
COM_COMPONENTBUILDER_JCB_HELPS_GROW_BUSINESSES="JCB Helps Grow Businesses"
|
||||
COM_COMPONENTBUILDER_JCB_HELPS_PHP_THRIVE="JCB Helps PHP Thrive"
|
||||
COM_COMPONENTBUILDER_JCB_IMPROVES_PHPS_REPUTATION="JCB Improves PHP's Reputation"
|
||||
COM_COMPONENTBUILDER_JCB_IMPROVES_PHP_DEVELOPMENT="JCB Improves PHP Development"
|
||||
COM_COMPONENTBUILDER_JCB_IMPROVES_USER_EXPERIENCE="JCB Improves User Experience"
|
||||
COM_COMPONENTBUILDER_JCB_IMPROVES_WORKFLOW="JCB Improves Workflow"
|
||||
COM_COMPONENTBUILDER_JCB_INCREASES_DEVELOPMENT_SPEED="JCB Increases Development Speed"
|
||||
COM_COMPONENTBUILDER_JCB_INCREASES_REVENUE="JCB Increases Revenue"
|
||||
COM_COMPONENTBUILDER_JCB_INCREASES_USER_SATISFACTION="JCB Increases User Satisfaction"
|
||||
COM_COMPONENTBUILDER_JCB_INVESTS_IN_PHPS_SUCCESS="JCB Invests in PHP's Success"
|
||||
COM_COMPONENTBUILDER_JCB_INVEST_IN_CHANGE="JCB: Invest in Change"
|
||||
COM_COMPONENTBUILDER_JCB_INVEST_IN_IMPACT="JCB: Invest in Impact"
|
||||
COM_COMPONENTBUILDER_JCB_INVEST_IN_PROGRESS="JCB: Invest in Progress"
|
||||
COM_COMPONENTBUILDER_JCB_INVEST_IN_PROGRESS_TODAY="JCB: Invest in Progress Today"
|
||||
COM_COMPONENTBUILDER_JCB_INVEST_IN_SUCCESS="JCB: Invest in Success"
|
||||
COM_COMPONENTBUILDER_JCB_INVEST_IN_THE_COMMUNITY="JCB: Invest in the Community"
|
||||
COM_COMPONENTBUILDER_JCB_INVEST_IN_THE_FUTURE="JCB: Invest in the Future"
|
||||
COM_COMPONENTBUILDER_JCB_INVEST_IN_YOUR_FUTURE="JCB: Invest in Your Future"
|
||||
COM_COMPONENTBUILDER_JCB_IS_NOT_YET_FULLY_READY_FOR_JOOMLA_FOUR_BUT_WITH_YOUR_HELP_WE_CAN_MAKE_THE_TRANSITION_FASTER_SHOW_YOUR_SUPPORT_BY_MAKING_A_DONATION_TODAY_AND_HELP_US_BRING_JCB_TO_THE_NEXT_LEVELBR_BR_BYOUR_COMPONENT_WILL_STILL_ONLY_BE_COMPILED_FOR_JOOMLA_THREEB="JCB is not yet fully ready for Joomla 4, but with your help, we can make the transition faster. Show your support by making a donation today and help us bring JCB to the next level.<br /><br /><b>Your component will still only be compiled for Joomla 3</b>"
|
||||
COM_COMPONENTBUILDER_JCB_LOWERS_DEVELOPMENT_STRESS="JCB Lowers Development Stress"
|
||||
COM_COMPONENTBUILDER_JCB_NEEDS_YOU="JCB Needs You"
|
||||
COM_COMPONENTBUILDER_JCB_OFFERS_A_STRONGER_SOLUTION="JCB Offers a Stronger Solution"
|
||||
COM_COMPONENTBUILDER_JCB_OFFERS_MORE_FEATURES="JCB Offers More Features"
|
||||
COM_COMPONENTBUILDER_JCB_PACKAGE_IMPORT="JCB Package Import"
|
||||
COM_COMPONENTBUILDER_JCB_PACKAGE_INFO_PATH_DOES_NOT_WORK_WE_ADVICE_YOU_BNOT_TO_CONTINUEB_WITH_THE_IMPORT_OF_THE_SELECTED_PACKAGE="JCB Package info path does not work, we advice you <b>not to continue</b> with the import of the selected package!"
|
||||
COM_COMPONENTBUILDER_JCB_PROMOTES_EFFICIENCY="JCB Promotes Efficiency"
|
||||
COM_COMPONENTBUILDER_JCB_PROMOTES_GOODWILL="JCB Promotes Goodwill"
|
||||
COM_COMPONENTBUILDER_JCB_PROVIDES_A_BETTER_EXPERIENCE="JCB Provides a Better Experience"
|
||||
COM_COMPONENTBUILDER_JCB_PRO_BOARD="JCB Pro board"
|
||||
COM_COMPONENTBUILDER_JCB_PRO_NOTICE_BOARD="JCB Pro Notice Board"
|
||||
COM_COMPONENTBUILDER_JCB_REDUCES_DEVELOPMENT_COSTS="JCB Reduces Development Costs"
|
||||
COM_COMPONENTBUILDER_JCB_SAVES_TIME="JCB Saves Time"
|
||||
COM_COMPONENTBUILDER_JCB_STREAMLINES_DEVELOPMENT="JCB Streamlines Development"
|
||||
COM_COMPONENTBUILDER_JCB_SUPPORTS_A_THRIVING_ECOSYSTEM="JCB Supports a Thriving Ecosystem"
|
||||
COM_COMPONENTBUILDER_JCB_SUPPORTS_A_WORTHY_CAUSE="JCB Supports a Worthy Cause"
|
||||
COM_COMPONENTBUILDER_JCB_SUPPORTS_OPENSOURCE="JCB Supports Open-Source"
|
||||
COM_COMPONENTBUILDER_JCB_SUPPORTS_PHP_INNOVATION="JCB Supports PHP Innovation"
|
||||
COM_COMPONENTBUILDER_JCB_SUPPORTS_THE_PHP_COMMUNITY="JCB Supports the PHP Community"
|
||||
COM_COMPONENTBUILDER_JCB_YOUR_CONTRIBUTION_MATTERS="JCB: Your Contribution Matters"
|
||||
COM_COMPONENTBUILDER_JCB_YOUR_DONATION_MATTERS="JCB: Your Donation Matters"
|
||||
COM_COMPONENTBUILDER_JCB_YOUR_SUPPORT_COUNTS="JCB: Your Support Counts"
|
||||
COM_COMPONENTBUILDER_JCB_YOUR_SUPPORT_IS_KEY="JCB: Your Support is Key"
|
||||
COM_COMPONENTBUILDER_JCB_YOUR_SUPPORT_MATTERS="JCB: Your Support Matters"
|
||||
COM_COMPONENTBUILDER_JCB_YOUR_SUPPORT_MATTERS_MOST="JCB: Your Support Matters Most"
|
||||
COM_COMPONENTBUILDER_JOIN_FIELDS="Join Fields"
|
||||
COM_COMPONENTBUILDER_JOIN_JCBS_COMMUNITY="Join JCB's Community"
|
||||
COM_COMPONENTBUILDER_JOIN_JCBS_JOURNEY="Join JCB's Journey"
|
||||
COM_COMPONENTBUILDER_JOIN_JCBS_MISSION="Join JCB's Mission"
|
||||
COM_COMPONENTBUILDER_JOIN_JCBS_SUCCESS="Join JCB's Success"
|
||||
COM_COMPONENTBUILDER_JOIN_JCBS_VISION="Join JCB's Vision"
|
||||
COM_COMPONENTBUILDER_JOIN_TYPE="Join Type"
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENT="Joomla Component"
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENTS="Joomla Components"
|
||||
@ -5794,6 +5882,7 @@ COM_COMPONENTBUILDER_JOOMLA_COMPONENT_BUILDCOMPSQL_LABEL="MySQL"
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENT_BUILDCOMP_DESCRIPTION="To build the component fields and back-end views dynamically using a mySQL table file."
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENT_BUILDCOMP_LABEL="Build Backend-views Dynamically"
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENT_BUILDER_BACKUP_KEY="Joomla Component Builder - Backup Key"
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENT_BUILDER_JCB_IS_A_CRUCIAL_TOOL_FOR_PHP_PROGRAMMERS_WHO_USE_JOOMLA_TO_EARN_A_LIVING_BY_MAKING_A_BFINANCIAL_DONATIONB_YOU_CAN_SUPPORT_THE_GROWTH_AND_CONTINUITY_OF_THIS_VITAL_RESOURCE_AND_ENSURE_ITS_RELEVANCE_FOR_YEARS_TO_COME_YOUR_CONTRIBUTION_NO_MATTER_HOW_BIG_OR_SMALL_WILL_BE_DEEPLY_APPRECIATED_BY_THE_PROJECTS_TEAM_AND_THE_WIDER_COMMUNITY="Joomla Component Builder (JCB) is a crucial tool for PHP programmers who use Joomla to earn a living. By making a <b>financial donation</b>, you can support the growth and continuity of this vital resource and ensure its relevance for years to come. Your contribution, no matter how big or small, will be deeply appreciated by the project's team and the wider community."
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENT_CLEAR_TMP_BUTTON_ACCESS="Joomla Component Clear tmp Button Access"
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENT_CLEAR_TMP_BUTTON_ACCESS_DESC="Allows the users in this group to access the clear tmp button."
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENT_CLONE_BUTTON_ACCESS="Joomla Component Clone Button Access"
|
||||
@ -5987,7 +6076,7 @@ COM_COMPONENTBUILDER_JOOMLA_COMPONENT_NOTE_README_DESCRIPTION="<div style='margi
|
||||
## Build Time<br />
|
||||
<br />
|
||||
**###totalHours### Hours** or **###totalDays### Eight Hour Days** (actual time the author saved - <br />
|
||||
due to [Automated Component Builder](http://joomlacomponentbuilder.com))<br />
|
||||
due to [Automated Component Builder](https://www.joomlacomponentbuilder.com))<br />
|
||||
<br />
|
||||
> (if creating a folder and file took **5 seconds** and writing one line of code took **10 seconds**,<br />
|
||||
> never making one mistake or taking any coffee break.)<br />
|
||||
@ -6012,7 +6101,7 @@ due to [Automated Component Builder](http://joomlacomponentbuilder.com))<br />
|
||||
<br />
|
||||
Project duration: **###projectWeekTime### weeks** or **###projectMonthTime### months**<br />
|
||||
<br />
|
||||
> This **component** was build with a Joomla [Automated Component Builder](http://joomlacomponentbuilder.com).<br />
|
||||
> This **component** was build with a Joomla [Automated Component Builder](https://www.joomlacomponentbuilder.com).<br />
|
||||
> Developed by [Llewellyn van der Merwe](mailto:llewellyn@joomlacomponentbuilder.com)<br />
|
||||
<br />
|
||||
## Donations<br />
|
||||
@ -6139,6 +6228,7 @@ COM_COMPONENTBUILDER_JOOMLA_COMPONENT_WHMCS_URL_MESSAGE="Error! Please add websi
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENT_YES="Yes"
|
||||
COM_COMPONENTBUILDER_JOOMLA_COMPONENT_ZIP="ZIP"
|
||||
COM_COMPONENTBUILDER_JOOMLA_FIELDS="Joomla fields"
|
||||
COM_COMPONENTBUILDER_JOOMLA_FOUR="Joomla 4"
|
||||
COM_COMPONENTBUILDER_JOOMLA_MODULE="Joomla Module"
|
||||
COM_COMPONENTBUILDER_JOOMLA_MODULES="Joomla Modules"
|
||||
COM_COMPONENTBUILDER_JOOMLA_MODULES_ACCESS="Joomla Modules Access"
|
||||
@ -7080,6 +7170,8 @@ COM_COMPONENTBUILDER_JOOMLA_PLUGIN_VERSION_DESC="A count of the number of times
|
||||
COM_COMPONENTBUILDER_JOOMLA_PLUGIN_VERSION_LABEL="Version"
|
||||
COM_COMPONENTBUILDER_JOOMLA_PLUGIN_YES="Yes"
|
||||
COM_COMPONENTBUILDER_JOOMLA_PLUGIN_ZIP="ZIP"
|
||||
COM_COMPONENTBUILDER_JOOMLA_THREE="Joomla 3"
|
||||
COM_COMPONENTBUILDER_JOOMLA_VERSION="Joomla Version"
|
||||
COM_COMPONENTBUILDER_JUST_GET_ALL_SNIPPETS="Just Get All Snippets"
|
||||
COM_COMPONENTBUILDER_KEEP_HISTORY="Keep History"
|
||||
COM_COMPONENTBUILDER_KEEP_ORIGINAL_ACCESS="- Keep Original Access -"
|
||||
@ -7738,6 +7830,8 @@ COM_COMPONENTBUILDER_LIBRARY_VERSION_DESC="A count of the number of times this L
|
||||
COM_COMPONENTBUILDER_LIBRARY_VERSION_LABEL="Version"
|
||||
COM_COMPONENTBUILDER_LICENSE="License"
|
||||
COM_COMPONENTBUILDER_LICENSE_S="License: %s"
|
||||
COM_COMPONENTBUILDER_LINE="line"
|
||||
COM_COMPONENTBUILDER_LINES="lines"
|
||||
COM_COMPONENTBUILDER_LINK="Link"
|
||||
COM_COMPONENTBUILDER_LINK_LOCAL_DYNAMIC="Link & Local (dynamic)"
|
||||
COM_COMPONENTBUILDER_LINK_TO_THE_CONTRIBUTOR="Link to the contributor"
|
||||
@ -7748,7 +7842,10 @@ COM_COMPONENTBUILDER_LOCAL="Local"
|
||||
COM_COMPONENTBUILDER_LOCAL_GET="Local (get)"
|
||||
COM_COMPONENTBUILDER_LOCAL_SNIPPET="Local snippet"
|
||||
COM_COMPONENTBUILDER_MAIN_MENU="Main Menu"
|
||||
COM_COMPONENTBUILDER_MAKE_A_DIFFERENCE_WITH_JCB="Make a Difference with JCB"
|
||||
COM_COMPONENTBUILDER_MANUAL="Manual"
|
||||
COM_COMPONENTBUILDER_MATCH_BEHAVIOUR="Match Behaviour"
|
||||
COM_COMPONENTBUILDER_MATCH_CASE="Match Case"
|
||||
COM_COMPONENTBUILDER_MATCH_FIELD="Match Field"
|
||||
COM_COMPONENTBUILDER_MATCH_OPTIONS="Match Options"
|
||||
COM_COMPONENTBUILDER_MAX_LENGTH_ONLY_FOUR_TEXT_FIELD="Max Length (only 4 text_field)"
|
||||
@ -7756,6 +7853,7 @@ COM_COMPONENTBUILDER_MERGE="Merge"
|
||||
COM_COMPONENTBUILDER_METHODS="Methods"
|
||||
COM_COMPONENTBUILDER_MINIFY_JAVASCRIPT="Minify JavaScript"
|
||||
COM_COMPONENTBUILDER_MIN_LENGTH_ONLY_FOUR_TEXT_FIELD="Min Length (only 4 text_field)"
|
||||
COM_COMPONENTBUILDER_MODE="Mode"
|
||||
COM_COMPONENTBUILDER_MODEL_AFTER_MODELLING="Model (after modelling)"
|
||||
COM_COMPONENTBUILDER_MODEL_BEFORE_MODELLING="Model (before modelling)"
|
||||
COM_COMPONENTBUILDER_MODULE="Module"
|
||||
@ -7790,7 +7888,7 @@ COM_COMPONENTBUILDER_NO_CRONJOB_PATH_FOUND_SINCE_INCORRECT_TYPE_REQUESTED="No cr
|
||||
COM_COMPONENTBUILDER_NO_DESCRIPTION_FOUND="No description found."
|
||||
COM_COMPONENTBUILDER_NO_FILES_LINKED="No Files Linked"
|
||||
COM_COMPONENTBUILDER_NO_FOUND="No Found"
|
||||
COM_COMPONENTBUILDER_NO_INSTANCES_WHERE_FOUND_S="No instances where found %s"
|
||||
COM_COMPONENTBUILDER_NO_INSTANCES_WHERE_FOUND_IN_S="No instances where found in %s"
|
||||
COM_COMPONENTBUILDER_NO_ITEM_FOUND="No Item Found"
|
||||
COM_COMPONENTBUILDER_NO_KEYS_WERE_FOUND_TO_ADD_AN_EXPORT_KEY_SIMPLY_OPEN_THE_COMPONENT_GO_TO_THE_TAB_CALLED_SETTINGS_BOTTOM_RIGHT_THERE_IS_A_FIELD_CALLED_EXPORT_KEY="No keys were found. To add an export key simply open the component, go to the tab called settings, bottom right there is a field called Export Key."
|
||||
COM_COMPONENTBUILDER_NO_LANGUAGES_FOUND="No Languages Found"
|
||||
@ -7997,13 +8095,29 @@ COM_COMPONENTBUILDER_POWERS_N_ITEMS_UNPUBLISHED_1="%s Power unpublished."
|
||||
COM_COMPONENTBUILDER_POWERS_SUBMENU="Powers Submenu"
|
||||
COM_COMPONENTBUILDER_POWERS_SUBMENU_DESC="Allows the users in this group to submenu of power"
|
||||
COM_COMPONENTBUILDER_POWER_ABSTRACT_CLASS="abstract class"
|
||||
COM_COMPONENTBUILDER_POWER_ACCESS_POINT_DESCRIPTION="Library path to the autoload.php file"
|
||||
COM_COMPONENTBUILDER_POWER_ACCESS_POINT_HINT="custom_folder/vendor/autoload.php (must be in the .../public_html/library/ folder of Joomla)"
|
||||
COM_COMPONENTBUILDER_POWER_ACCESS_POINT_LABEL="Access Point"
|
||||
COM_COMPONENTBUILDER_POWER_ACCESS_POINT_MESSAGE="Error! Please add autoload full path here."
|
||||
COM_COMPONENTBUILDER_POWER_ADD_HEAD_DESCRIPTION="You can add your own custom header script, combined with the default header script that make the extended class work."
|
||||
COM_COMPONENTBUILDER_POWER_ADD_HEAD_LABEL="Add Custom Class Header"
|
||||
COM_COMPONENTBUILDER_POWER_ADD_LICENSING_TEMPLATE_DESCRIPTION="The option to override the licensing template."
|
||||
COM_COMPONENTBUILDER_POWER_ADD_LICENSING_TEMPLATE_LABEL="Add Licensing Template"
|
||||
COM_COMPONENTBUILDER_POWER_AS_LABEL="as"
|
||||
COM_COMPONENTBUILDER_POWER_AUTOLOAD_COMPOSER_NOTE_DESCRIPTION="<p>Once you have manually pulled composer classes into your own custom folder in libraries area (via composer), you can link it here.</p>
|
||||
|
||||
<p>So this feature gives you the ability to add your own custom <b>composer</b> set of classes to your project. Yes, you will still have to manually pull them into your own custom and unique folder into the libraries area of Joomla (on this JCB development system). But you can link it here and JCB will take care of adding it to your component.</p>
|
||||
|
||||
<p>First and most importantly (due to obvious risk of collusion), avoid pulling classes into your custom set of composer classes that are already included in the Joomla vendor folder. Those classes that Joomla loads are already available to you. To use them, just add the <b>use Namespace;</b> of that class to the header of this power, and the PHP auto linker will take care of the rest.</p>
|
||||
|
||||
<p>So all composer projects =>(vendor folders) has an <code>autoload.php</code> file that is located in the root of the vendor folder. We call this the <b>access point</b> to that cluster of classes. This means you will have <b>one access point</b> for multiple namespaces.</p>
|
||||
|
||||
<p>Due the continued risk of collusion <b>we allow only one access point per/power</b>. But for even more peace of mind, it is best to have only one access point per/project. Which means you should try to consolidate your custom composer additional classes (outside of the Joomla vendor folder) into one vendor folder. This will result in <b>one access point</b>, that you will use multiple times for various powers.</p>"
|
||||
COM_COMPONENTBUILDER_POWER_AUTOLOAD_COMPOSER_NOTE_LABEL="When to use Autoloader Composer Powers?"
|
||||
COM_COMPONENTBUILDER_POWER_CLASS="class"
|
||||
COM_COMPONENTBUILDER_POWER_CODE="Code"
|
||||
COM_COMPONENTBUILDER_POWER_COMPOSER="Composer"
|
||||
COM_COMPONENTBUILDER_POWER_COMPOSER_LABEL="Autoloader Composer Powers"
|
||||
COM_COMPONENTBUILDER_POWER_CREATED_BY_DESC="The user that created this Power."
|
||||
COM_COMPONENTBUILDER_POWER_CREATED_BY_LABEL="Created By"
|
||||
COM_COMPONENTBUILDER_POWER_CREATED_DATE_DESC="The date this Power was created."
|
||||
@ -8035,7 +8149,7 @@ COM_COMPONENTBUILDER_POWER_LICENSING="Licensing"
|
||||
COM_COMPONENTBUILDER_POWER_LICENSING_TEMPLATE_HINT="/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 3rd September, 2015
|
||||
* @created 4th September, 2015
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
@ -8121,7 +8235,9 @@ COM_COMPONENTBUILDER_POWER_TYPE_DESCRIPTION="The type of power being build"
|
||||
COM_COMPONENTBUILDER_POWER_TYPE_LABEL="Type of Power"
|
||||
COM_COMPONENTBUILDER_POWER_USE="Use"
|
||||
COM_COMPONENTBUILDER_POWER_USE_GLOBAL="Use Global"
|
||||
COM_COMPONENTBUILDER_POWER_USE_LABEL="use"
|
||||
COM_COMPONENTBUILDER_POWER_USE_HINT="Name\Project\ClassName"
|
||||
COM_COMPONENTBUILDER_POWER_USE_LABEL="Use"
|
||||
COM_COMPONENTBUILDER_POWER_USE_MESSAGE="Error! Please add namespace here."
|
||||
COM_COMPONENTBUILDER_POWER_USE_SELECTION_DESCRIPTION="Select namespace you want to use in your power."
|
||||
COM_COMPONENTBUILDER_POWER_USE_SELECTION_LABEL="Use Selection"
|
||||
COM_COMPONENTBUILDER_POWER_VERSION_DESC="A count of the number of times this Power has been revised."
|
||||
@ -8141,9 +8257,13 @@ COM_COMPONENTBUILDER_PUBLISHING="Publishing"
|
||||
COM_COMPONENTBUILDER_README="Readme"
|
||||
COM_COMPONENTBUILDER_READY_TO_COMPILE_A_COMPONENT="Ready to compile a component"
|
||||
COM_COMPONENTBUILDER_REFRESH="Refresh"
|
||||
COM_COMPONENTBUILDER_REGEX_SEARCH="Regex Search"
|
||||
COM_COMPONENTBUILDER_REMOVE="Remove"
|
||||
COM_COMPONENTBUILDER_REMOVING_ALL_ZIP_PACKAGES_FROM_THE_TEMPORARY_FOLDER_OF_THE_JOOMLA_INSTALL="Removing all zip packages from the temporary folder of the Joomla install"
|
||||
COM_COMPONENTBUILDER_RENAME="Rename"
|
||||
COM_COMPONENTBUILDER_REPLACE="Replace"
|
||||
COM_COMPONENTBUILDER_REPLACED_WITH="replaced with"
|
||||
COM_COMPONENTBUILDER_REPLACE_PROCESS_COMPLETE="replace process complete"
|
||||
COM_COMPONENTBUILDER_REPORT_AN_ISSUE_BSB="Report an issue: <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_REQUIRES_THE_VALUE_ENTERED_BE_ONE_OF_THE_OPTIONS_IN_AN_ELEMENT_OF_TYPEQUOTLISTQUOT_THAT_IS_THAT_THE_ELEMENT_IS_A_SELECT_LIST="Requires the value entered be one of the options in an element of type="list": that is, that the element is a select list."
|
||||
COM_COMPONENTBUILDER_REQUIRES_THE_VALUE_TO_BE_A_TELEPHONE_NUMBER_COMPLYING_WITH_THE_STANDARDS_OF_NANPA_ITUT_TRECEONE_HUNDRED_AND_SIXTY_FOUR_OR_IETF_RFCFOUR_THOUSAND_NINE_HUNDRED_AND_THIRTY_THREE="Requires the value to be a Telephone number complying with the standards of nanpa, ITU-T T-REC-E.164 or ietf rfc4933."
|
||||
@ -8152,18 +8272,27 @@ COM_COMPONENTBUILDER_REVERT_ALL_AHEAD_SNIPPETS="Revert All Ahead Snippets"
|
||||
COM_COMPONENTBUILDER_RIGHT_IN_TAB="Right in Tab"
|
||||
COM_COMPONENTBUILDER_RIGHT_OF_TABS="Right of Tabs"
|
||||
COM_COMPONENTBUILDER_RUN_EXPANSION="Run Expansion"
|
||||
COM_COMPONENTBUILDER_SAVE_ALL_CHANGES_MADE_TO_THE_SELECTED_ITEM="Save all changes made to the selected item."
|
||||
COM_COMPONENTBUILDER_SAVE_ITEM="Save Item"
|
||||
COM_COMPONENTBUILDER_SAVE_SUCCESS="Great! Item successfully saved."
|
||||
COM_COMPONENTBUILDER_SAVE_WARNING="The value already existed so please select another."
|
||||
COM_COMPONENTBUILDER_SBR_YOU_CAN_ADD_A_BGITHUB_ACCESS_TOKENB_TO_COMPONENTBUILDER_GLOBAL_OPTIONS_TO_MAKE_AUTHENTICATED_REQUESTS_TO_GITHUB_AN_ACCESS_TOKEN_WITH_ONLY_PUBLIC_ACCESS_WILL_DO_TO_RETRIEVE_S="%s<br />You can add a <b>gitHub Access Token</b> to Componentbuilder global options to make authenticated requests to gitHub. An access token with only public access will do to retrieve %s."
|
||||
COM_COMPONENTBUILDER_SEARCH="Search"
|
||||
COM_COMPONENTBUILDER_SEARCHABLE="Searchable"
|
||||
COM_COMPONENTBUILDER_SEARCHED_FOR="searched for"
|
||||
COM_COMPONENTBUILDER_SEARCHING="searching"
|
||||
COM_COMPONENTBUILDER_SEARCH_ACCESS="Search Access"
|
||||
COM_COMPONENTBUILDER_SEARCH_ACCESS_DESC="Allows the users in this group to access search."
|
||||
COM_COMPONENTBUILDER_SEARCH_COMPILER_BUTTON_ACCESS="Search Compiler Button Access"
|
||||
COM_COMPONENTBUILDER_SEARCH_COMPILER_BUTTON_ACCESS_DESC="Allows the users in this group to access the compiler button."
|
||||
COM_COMPONENTBUILDER_SEARCH_DASHBOARD_LIST="Search Dashboard List"
|
||||
COM_COMPONENTBUILDER_SEARCH_DASHBOARD_LIST_DESC="Allows the users in this group to dashboard list of Search"
|
||||
COM_COMPONENTBUILDER_SEARCH_DATABASE_AGAIN="Search Database Again"
|
||||
COM_COMPONENTBUILDER_SEARCH_DESC="JCB Search"
|
||||
COM_COMPONENTBUILDER_SEARCH_OR_SEARCH_AND_REPLACE="Search, or Search and Replace"
|
||||
COM_COMPONENTBUILDER_SEARCH_SUBMENU="Search Submenu"
|
||||
COM_COMPONENTBUILDER_SEARCH_SUBMENU_DESC="Allows the users in this group to submenu of Search"
|
||||
COM_COMPONENTBUILDER_SECONDS="seconds"
|
||||
COM_COMPONENTBUILDER_SEE_ALL_IMPORT_INFO="See All Import Info"
|
||||
COM_COMPONENTBUILDER_SELECTION="selection"
|
||||
COM_COMPONENTBUILDER_SELECT_ADMIN_VIEW="Select Admin View"
|
||||
@ -8172,11 +8301,14 @@ COM_COMPONENTBUILDER_SELECT_AN_OPTION="Select an option"
|
||||
COM_COMPONENTBUILDER_SELECT_A_PROPERTY="Select a property"
|
||||
COM_COMPONENTBUILDER_SELECT_A_SITE_VIEW="Select a site view"
|
||||
COM_COMPONENTBUILDER_SELECT_A_SNIPPET="select a snippet"
|
||||
COM_COMPONENTBUILDER_SELECT_BUILD_DATE="Select Build Date"
|
||||
COM_COMPONENTBUILDER_SELECT_COMPONENT="Select Component"
|
||||
COM_COMPONENTBUILDER_SELECT_EXTENSION="Select Extension"
|
||||
COM_COMPONENTBUILDER_SELECT_THE_COMPONENT_TO_COMPILE="Select the component to compile"
|
||||
COM_COMPONENTBUILDER_SELECT_THE_COMPONENT_TO_SEARCH="Select the component to search"
|
||||
COM_COMPONENTBUILDER_SELECT_THE_COMPONENT_YOUR_WOULD_LIKE_TO_IMPORT="Select the component your would like to import."
|
||||
COM_COMPONENTBUILDER_SELECT_THE_PACKAGE_TO_IMPORT="Select the package to import"
|
||||
COM_COMPONENTBUILDER_SELECT_THE_TABLE_TO_SEARCH="Select the table to search"
|
||||
COM_COMPONENTBUILDER_SERVER="Server"
|
||||
COM_COMPONENTBUILDER_SERVERS="Servers"
|
||||
COM_COMPONENTBUILDER_SERVERS_ACCESS="Servers Access"
|
||||
@ -8317,6 +8449,7 @@ COM_COMPONENTBUILDER_SERVER_VERSION_DESC="A count of the number of times this Se
|
||||
COM_COMPONENTBUILDER_SERVER_VERSION_LABEL="Version"
|
||||
COM_COMPONENTBUILDER_SET_A_CLASS_VALUE_FOR_THE_LIST_VIEW_OF_THIS_FIELD="Set a class value for the list view of this field."
|
||||
COM_COMPONENTBUILDER_SET_CUSTOM="Set Custom"
|
||||
COM_COMPONENTBUILDER_SET_THE_SEARCH_BEHAVIOUR_HERE="Set the search behaviour here."
|
||||
COM_COMPONENTBUILDER_SHARE_SNIPPETS="Share Snippets"
|
||||
COM_COMPONENTBUILDER_SHOULD_JCB_ADD_ANY_POWERS_THAT_ARE_CONNECTED_TO_THIS_COMPONENT_THIS_MAY_BE_HELPFUL_IF_YOU_ARE_LOADING_POWERS_VIA_ANOTHER_COMPONENT_AND_WOULD_LIKE_TO_AVOID_ADDING_IT_TO_BOTH_JUST_REMEMBER_THAT_IN_THIS_CASE_YOU_NEED_TO_LOAD_THE_POWERS_VIA_A_PLUGIN="Should JCB add any powers that are connected to this component? This may be helpful if you are loading powers via another component, and would like to avoid adding it to both, just remember that in this case you need to load the powers via a plugin."
|
||||
COM_COMPONENTBUILDER_SHOULD_JCB_INSERT_THE_CUSTOM_CODE_PLACEHOLDERS_THIS_IS_ONLY_APPLICABLE_IF_THIS_COMPONENT_HAS_CUSTOM_CODE="Should JCB insert the custom code placeholders? This is only applicable if this component has custom code."
|
||||
@ -8327,6 +8460,7 @@ COM_COMPONENTBUILDER_SHOULD_THIS_FIELD_BE_ESCAPED_IN_THE_LIST_VIEW="Should this
|
||||
COM_COMPONENTBUILDER_SHOULD_WE_BE_SHOWING_MORE_ELABORATE_INFORMATION_DURING_IMPORT="Should we be showing more elaborate information during import."
|
||||
COM_COMPONENTBUILDER_SHOULD_WE_FORCE_THE_UPDATE_OF_ALL_LOCAL_DATA_EVEN_IF_IT_IS_NEWER_THEN_THE_DATA_BEING_IMPORTED="Should we force the update of all local data, even if it is newer then the data being imported."
|
||||
COM_COMPONENTBUILDER_SHOULD_WE_MERGE_THE_COMPONENTS_WITH_SIMILAR_LOCAL_COMPONENTS_MERGING_THE_COMPONENTS_USE_TO_BE_THE_DEFAULT_BEHAVIOUR_BUT_NOW_YOU_CAN_IMPORT_THE_COMPONENTS_AND_FORCE_IT_NOT_TO_MERGE_THE_FOLLOWING_AREAS_VALIDATION_RULE_FIELDTYPE_SNIPPET_LANGUAGE_LANGUAGE_TRANSLATION_JOOMLA_PLUGIN_GROUP_CLASS_EXTENDS_CLASS_PROPERTY_CLASS_METHOD_BMUST_AND_WILL_STILLB_MERGE_EVEN_OF_YOUR_SELECTION_IS_BNOB_BECAUSE_OF_THE_SINGULAR_NATURE_OF_THOSE_AREAS="Should we merge the component/s with similar local component/s. Merging the component/s use to be the default behaviour, but now you can import the component/s and force it not to merge. The following areas (validation_rule, fieldtype, snippet, language, language_translation, joomla_plugin_group, class_extends, class_property, class_method) <b>must and will still</b> merge even of your selection is <b>No</b>, because of the singular nature of those areas."
|
||||
COM_COMPONENTBUILDER_SHOW_ADVANCED_OPTIONS="Show Advanced Options"
|
||||
COM_COMPONENTBUILDER_SHOW_IN_ALL_LIST_VIEWS="Show in All List Views"
|
||||
COM_COMPONENTBUILDER_SHOW_ONLY="Show Only"
|
||||
COM_COMPONENTBUILDER_SHOW_TOGGLE="Show Toggle"
|
||||
@ -8342,8 +8476,6 @@ COM_COMPONENTBUILDER_SITE_VIEWS_BATCH_USE="Site Views Batch Use"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_BATCH_USE_DESC="Allows users in this group to use batch copy/update method of batch site views"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_CREATE="Site Views Create"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_CREATE_DESC="Allows the users in this group to create create site views"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_ADD="Site Views Dashboard Add"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_ADD_DESC="Allows the users in this group to dashboard add of site view"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_LIST="Site Views Dashboard List"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_LIST_DESC="Allows the users in this group to dashboard list of site view"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_DELETE="Site Views Delete"
|
||||
@ -8962,6 +9094,10 @@ COM_COMPONENTBUILDER_SORRY_THIS_PLACEHOLDER_IS_ALREADY_IN_USE_IN_THE_COMPILER="S
|
||||
COM_COMPONENTBUILDER_SORRY_THIS_VALIDATION_RULE_NAME_S_ALREADY_EXIST_AS_PART_OF_THE_JOOMLA_CORE_NO_NEED_TO_CREATE_IT_IF_YOU_ARE_ADAPTING_IT_GIVE_IT_YOUR_OWN_UNIQUE_NAME="Sorry this validation rule name (%s) already exist as part of the Joomla core! No need to create it, if you are adapting it give it your own unique name."
|
||||
COM_COMPONENTBUILDER_SORRY_THIS_VALIDATION_RULE_NAME_S_ALREADY_EXIST_IN_YOUR_SYSTEM="Sorry this validation rule name (%s) already exist in your system!"
|
||||
COM_COMPONENTBUILDER_SORTABLE="Sortable"
|
||||
COM_COMPONENTBUILDER_SOURCE_CODE="source code"
|
||||
COM_COMPONENTBUILDER_SOURCE_CODE_FOR_JOOMLA_COMPONENT="Source Code for Joomla Component"
|
||||
COM_COMPONENTBUILDER_START_A_SEARCH="Start a Search"
|
||||
COM_COMPONENTBUILDER_STOP_A_SEARCH="Stop a Search"
|
||||
COM_COMPONENTBUILDER_SUBMENU="Submenu"
|
||||
COM_COMPONENTBUILDER_SUBMENU_ADMIN_VIEWS="Admin Views"
|
||||
COM_COMPONENTBUILDER_SUBMENU_COMPILER="Compiler"
|
||||
@ -8990,7 +9126,8 @@ COM_COMPONENTBUILDER_SUBMENU_TEMPLATES="Templates"
|
||||
COM_COMPONENTBUILDER_SUBMENU_VALIDATION_RULES="Validation Rules"
|
||||
COM_COMPONENTBUILDER_SUCCESS_THE_SNIPPET_WAS_SAVED="Success! The snippet was saved."
|
||||
COM_COMPONENTBUILDER_SUCCESS_THE_SNIPPET_WAS_SAVED_BUT_THE_MODIFIED_DATE_COULD_NOT_BE_ADJUSTED_BR_BR_BTHIS_MEANS_THE_SNIPPETS_WILL_CONTINUE_TO_APPEAR_OUT_OF_DATEB="Success! The snippet was saved. But the modified date could not be adjusted. <br /><br /><b>This means the snippets will continue to appear out of date.</b>"
|
||||
COM_COMPONENTBUILDER_SZDEQZDMVSMHBTRWFIFTYTSQFLVVXJTMTHREEJTWOIXM="%szdEQzdmVsMHBtRW50T%sQFlvVXJTM3J2IXM="
|
||||
COM_COMPONENTBUILDER_SUPPORT_JCB_TODAY="Support JCB Today"
|
||||
COM_COMPONENTBUILDER_SUPPORT_JOOMLA_COMPONENT_BUILDER_JCB_WITH_A_BFINANCIAL_DONATIONB_TO_SHOW_GRATITUDE_FOR_THE_TIME_AND_EFFORT_SAVED_IN_YOUR_DEVELOPMENT_PROCESS_YOUR_CONTRIBUTION_NO_MATTER_THE_SIZE_WILL_BE_APPRECIATED_BY_THE_PROJECTS_TEAM_AND_THE_WIDER_COMMUNITY_HELP_ENSURE_THE_GROWTH_AND_RELEVANCE_OF_THIS_ESSENTIAL_TOOL="Support Joomla Component Builder (JCB) with a <b>financial donation</b> to show gratitude for the time and effort saved in your development process. Your contribution, no matter the size, will be appreciated by the project's team and the wider community. Help ensure the growth and relevance of this essential tool."
|
||||
COM_COMPONENTBUILDER_SZIP_COULD_NOT_BE_INSTALLED="%s.zip could not be installed!"
|
||||
COM_COMPONENTBUILDER_SZIP_WAS_REMOVED_THE_FROM_TMP_FOLDER_DURING_INSTALLATION="%s.zip was removed the from tmp folder during installation!"
|
||||
COM_COMPONENTBUILDER_S_BEING_IMPORTED="%s Being Imported"
|
||||
@ -9000,6 +9137,9 @@ COM_COMPONENTBUILDER_S_S_NUMBER_BSB_COULD_NOT_BE_DOWNLOADED_SUCCESSFULLY_TO_THIS
|
||||
COM_COMPONENTBUILDER_S_WE_DETECTED_A_CHANGE_IN_BEXTERNALCODEB_BUT_YOU_DO_NOT_HAVE_PERMISSION_TO_ALLOW_THIS_CHANGE_SO_BSB_WAS_REMOVED_FROM_THE_COMPILATION_PLEASE_CONTACT_YOUR_SYSTEM_ADMINISTRATOR_FOR_MORE_INFOBR_SMALLADMIN_ACCESS_REQUIREDSMALL="%s, we detected a change in <b>EXTERNALCODE</b>, but you do not have permission to allow this change so <b>%s</b> was removed from the compilation. Please contact your system administrator for more info!<br /><small>(admin access required)</small>"
|
||||
COM_COMPONENTBUILDER_S_WE_DETECTED_BNEW_EXTERNALCODEB_BUT_YOU_DO_NOT_HAVE_PERMISSION_TO_ALLOW_THIS_NEW_CODESTRING_SO_BSB_WAS_REMOVED_FROM_THE_COMPILATION_PLEASE_CONTACT_YOU_SYSTEM_ADMINISTRATOR_FOR_MORE_INFOBR_SMALLADMIN_ACCESS_REQUIREDSMALL="%s, we detected <b>NEW EXTERNALCODE</b>, but you do not have permission to allow this new code/string so <b>%s</b> was removed from the compilation. Please contact you system administrator for more info!<br /><small>(admin access required)</small>"
|
||||
COM_COMPONENTBUILDER_TAB="Tab"
|
||||
COM_COMPONENTBUILDER_TABLE="Table"
|
||||
COM_COMPONENTBUILDER_TABLES="Tables"
|
||||
COM_COMPONENTBUILDER_TABLES_WITH="tables with"
|
||||
COM_COMPONENTBUILDER_TABLE_BSB_NOT_FOUND_IN_THE_LOCAL_DATABASE_SO_ITS_VALUES_COULD_NOT_BE_IMPORTED_PLEASE_UPDATE_YOUR_JCB_INSTALL_AND_TRY_AGAIN="Table <b>%s</b> not found in the local database so its values could not be imported, please update your JCB install and try again."
|
||||
COM_COMPONENTBUILDER_TABLE_BSB_NOT_FOUND_IN_THE_LOCAL_DATABASE_SO_ITS_VALUES_COULD_NOT_BE_IMPORTED_THE_WHOLE_POWERS_FEATURE_IS_ONLY_AVAILABLE_TO_A_HREFSPRO_MEMBERSA_AT_THIS_TIME="Table <b>%s</b> not found in the local database so its values could not be imported. The whole powers feature is only available to <a href=%s>PRO Members</a> at this time."
|
||||
COM_COMPONENTBUILDER_TARGET_BEHAVIOUR="Target Behaviour"
|
||||
@ -9143,6 +9283,7 @@ COM_COMPONENTBUILDER_THE_BNONE_DBB_OPTION_WILL_REMOVE_THIS_FIELD_FROM_BEING_SAVE
|
||||
COM_COMPONENTBUILDER_THE_BONLY_IN_ADMIN_LIST_VIEWB_OPTION_WILL_ONLY_ADD_THIS_FIELD_TO_THE_ADMIN_LIST_VIEW_NOT_TO_ANY_LINKED_VIEWS="The <b>Only in Admin List View</b> option will only Add this field to the admin list view, not to any linked views."
|
||||
COM_COMPONENTBUILDER_THE_BONLY_IN_LINKED_LIST_VIEWSB_OPTION_WILL_ONLY_ADD_THIS_FIELD_TO_THE_LINKED_LIST_VIEW_IF_THIS_VIEW_GETS_LINKED_TO_OTHER_VIEW_NOT_TO_THIS_ADMIN_LIST_VIEW="The <b>Only in Linked List Views</b> option will only Add this field to the linked list view, if this view gets linked to other view, not to this admin list view."
|
||||
COM_COMPONENTBUILDER_THE_BPHPSECLIBNETSFTPB_LIBRARYCLASS_IS_NOT_AVAILABLE_THIS_LIBRARYCLASS_SHOULD_HAVE_BEEN_ADDED_TO_YOUR_BLIBRARIESVDM_IOVENDORB_FOLDER_PLEASE_CONTACT_YOUR_SYSTEM_ADMINISTRATOR_FOR_MORE_INFO="The <b>phpseclib\NET\SFTP</b> library\class is not available! This library\class should have been added to your <b>libraries/vdm_io/vendor</b> folder. Please contact your system administrator for more info"
|
||||
COM_COMPONENTBUILDER_THE_BSB_BSB_IS_NOT_AVAILABLE_IN_YOUR_COMPONENT_PLEASE_INSURE_TO_ONLY_USED_S_FOR_A_DYNAMIC_DASHBOARD_THAT_ARE_STILL_LINKED_TO_YOUR_COMPONENT="The <b>%s</b> (<b>%s</b>) is not available in your component! Please insure to only used %s, for a dynamic dashboard, that are still linked to your component."
|
||||
COM_COMPONENTBUILDER_THE_BSB_CUT_SEQUENCE_FAILED_ON_THE_RETURNED_EXTERNAL_CODESTRING_AS_MORE_LINES_HAS_TO_BE_CUT_THEN_WAS_FOUND_IN_THE_CODESTRING_WE_HAVE_COMPLETELY_REMOVED_THE_CODE_PLEASE_CHECK_THIS_CODESTRING="The <b>%s</b> cut sequence failed on the returned external code/string as more lines has to be cut then was found in the code/string. We have completely removed the code. Please check this code/string!"
|
||||
COM_COMPONENTBUILDER_THE_BSB_FILE_COULD_NOT_BE_MOVED_TO_BSB_PATH_ON_BSB_SERVER="The <b>%s</b> file could not be moved to <b>%s</b> path on <b>%s</b> server."
|
||||
COM_COMPONENTBUILDER_THE_BSB_FILE_COULD_NOT_BE_MOVED_TO_BSB_SERVER="The <b>%s</b> file could not be moved to <b>%s</b> server."
|
||||
@ -9150,11 +9291,13 @@ COM_COMPONENTBUILDER_THE_BSB_IS_NOT_A_VALID_URLPATH="The <b>%s</b> is not a vali
|
||||
COM_COMPONENTBUILDER_THE_BSB_LIBRARYCLASS_IS_NOT_AVAILABLE_THIS_LIBRARYCLASS_SHOULD_HAVE_BEEN_ADDED_TO_YOUR_BLIBRARIESPHPSECLIBVENDORB_FOLDER_PLEASE_CONTACT_YOUR_SYSTEM_ADMINISTRATOR_FOR_MORE_INFO="The <b>%s</b> library\class is not available! This library\class should have been added to your <b>libraries/phpseclib/vendor</b> folder. Please contact your system administrator for more info!"
|
||||
COM_COMPONENTBUILDER_THE_BSB_LIBRARY_CAN_NOT_BE_DELETED_OR_THINGS_WILL_BREAK="The <b>%s</b> library can not be deleted, or things will break."
|
||||
COM_COMPONENTBUILDER_THE_BSB_RETURNED_AN_INVALID_STRING="The <b>%s</b> returned an invalid string!"
|
||||
COM_COMPONENTBUILDER_THE_BSB_VALUE_FOR_THE_DYNAMIC_DASHBOARD_IS_INVALID="The <b>%s</b> value for the dynamic dashboard is invalid."
|
||||
COM_COMPONENTBUILDER_THE_BSHOW_IN_ALL_LIST_VIEWSB_OPTION_WILL_ADD_THIS_FIELD_TO_ALL_LIST_VIEWS_ADMIN_AMP_LINKED="The <b>Show in All List Views</b> option will Add this field to all list views, admin & linked."
|
||||
COM_COMPONENTBUILDER_THE_BSINGLE_FILTERB_SELECTION_OPTION_ALLOWS_THE_USER_TO_SELECT_JUST_ONE_VALUE_IN_THIS_FILTERFIELD="The <b>single filter</b> selection option allows the user to select just one value in this filter/field."
|
||||
COM_COMPONENTBUILDER_THE_CODESTRING_FROM_BSB_HAS_BEEN_ADDED_FOR_THE_BFIRST_TIMEB_PLEASE_IINVESTIGATEI_TO_ENSURE_THE_CORRECT_CODESTRING_WAS_USED_BSHOULD_YOU_NOT_KNOW_ABOUT_THIS_NEW_EXTERNAL_CODESTRING_BEING_ADDED_THEN_THIS_IS_A_SERIOUS_DANGER_AND_REQUIRES_IMMEDIATE_ATTENTIONB_DO_NOT_IGNORE_THIS_WARNING_AS_IT_WILL_ONLY_SHOW_BONCEB="The code/string from <b>%s</b> has been added for the <b>first time</b>. Please <i>investigate</i> to ensure the correct code/string was used! <b>Should you not know about this NEW external code/string being added, then this is a serious danger! and requires immediate attention!</b> Do not ignore this warning as it will only show <b>once</b>."
|
||||
COM_COMPONENTBUILDER_THE_CODESTRING_FROM_BSB_HAS_BEEN_BCHANGEDB_SINCE_THE_LAST_COMPILATION_PLEASE_INVESTIGATE_TO_ENSURE_THE_CHANGES_ARE_SAFE_BSHOULD_YOU_NOT_EXPECT_THIS_CHANGE_TO_THE_EXTERNAL_CODESTRING_BEING_ADDED_THEN_THIS_IS_A_SERIOUS_ISSUE_AND_REQUIRES_IMMEDIATE_ATTENTIONB_DO_NOT_IGNORE_THIS_WARNING_AS_IT_WILL_ONLY_SHOW_BONCEB="The code/string from <b>%s</b> has been <b>changed</b> since the last compilation. Please investigate to ensure the changes are safe! <b>Should you not expect this change to the external code/string being added, then this is a serious issue! and requires immediate attention!</b> Do not ignore this warning as it will only show <b>once</b>."
|
||||
COM_COMPONENTBUILDER_THE_COMPONENT="The Component"
|
||||
COM_COMPONENTBUILDER_THE_COMPONENTS_LAST_MODIFIED_DATE_WILL_BE_USED="The component's last modified date will be used."
|
||||
COM_COMPONENTBUILDER_THE_COMPONENT_ADMIN_VIEWS="The component admin views"
|
||||
COM_COMPONENTBUILDER_THE_COMPONENT_CONFIG="The component config"
|
||||
COM_COMPONENTBUILDER_THE_COMPONENT_CUSTOM_ADMIN_MENUS="The component custom admin menus"
|
||||
@ -9168,6 +9311,9 @@ COM_COMPONENTBUILDER_THE_COMPONENT_PLUGINS="The component plugins"
|
||||
COM_COMPONENTBUILDER_THE_COMPONENT_SITE_VIEWS="The component site views"
|
||||
COM_COMPONENTBUILDER_THE_COMPONENT_UPDATES="The component updates"
|
||||
COM_COMPONENTBUILDER_THE_COMPONENT_WITH_ALL_LINKED_ADMIN_VIEWS_FIELDS_LINKED_TO_ADMIN_VIEWS_CUSTOM_ADMIN_VIEWS_SITE_VIEWS_TEMPLATES_AND_LAYOUTS_WERE_CLONED_SUCCESSFUL="The Component with all linked admin views, fields linked to admin views, custom admin views, site views, templates and layouts were cloned successful!"
|
||||
COM_COMPONENTBUILDER_THE_CONTINUED_SUPPORT_OF_INDIVIDUALS_LIKE_YOU_HAS_ALLOWED_JOOMLA_COMPONENT_BUILDER_JCB_TO_THRIVE_FOR_SEVEN_YEARS_SINCE_GOING_PUBLIC_YOUR_CONTRIBUTIONS_HAVE_BEEN_CRUCIAL_IN_ENSURING_THE_GROWTH_AND_RELEVANCE_OF_THIS_VITAL_TOOL_FOR_PHP_PROGRAMMERS_THANK_YOU_FOR_YOUR_SUPPORT_AND_FOR_BEING_A_PART_OF_JCBS_JOURNEY="The continued support of individuals like you has allowed Joomla Component Builder (JCB) to thrive for seven years since going public. Your contributions have been crucial in ensuring the growth and relevance of this vital tool for PHP programmers. Thank you for your support and for being a part of JCB's journey."
|
||||
COM_COMPONENTBUILDER_THE_FILE_PATH_BSB_DOES_NOT_EXIST_AND_WAS_NOT_ADDED="The file path: <b>%s</b> does not exist, and was not added!"
|
||||
COM_COMPONENTBUILDER_THE_FOLDER_PATH_BSB_DOES_NOT_EXIST_AND_WAS_NOT_ADDED="The folder path: <b>%s</b> does not exist, and was not added!"
|
||||
COM_COMPONENTBUILDER_THE_FTP_CONNECTION_FOR_BSB_COULD_NOT_BE_MADE_PLEASE_CHECK_YOUR_SIGNATURE_DETAILS="The FTP connection for <b>%s</b> could not be made. Please check your signature details!"
|
||||
COM_COMPONENTBUILDER_THE_FTP_SIGNATURE_FOR_BSB_WAS_NOT_WELL_FORMED_PLEASE_CHECK_YOUR_SIGNATURE_DETAILS="The FTP signature for <b>%s</b> was not well formed, please check your signature details!"
|
||||
COM_COMPONENTBUILDER_THE_KEY_OF_THIS_PACKAGE="The key of this package."
|
||||
@ -9186,7 +9332,9 @@ COM_COMPONENTBUILDER_THE_PRIVATE_KEY_FIELD_COULD_NOT_BE_LOADED_FOR_BSB_SERVER="T
|
||||
COM_COMPONENTBUILDER_THE_PRIVATE_KEY_FILE_COULD_NOT_BE_LOADEDFOUND_FOR_BSB_SERVER="The private key file could not be loaded/found for <b>%s</b> server!"
|
||||
COM_COMPONENTBUILDER_THE_PRO_BOARD_IS_LOADING="The pro board is loading"
|
||||
COM_COMPONENTBUILDER_THE_README_IS_LOADING="The readme is loading"
|
||||
COM_COMPONENTBUILDER_THE_REPLACE_PROCESS_HAD_AN_ERROR_WITH_TABLE="The replace process had an error with table"
|
||||
COM_COMPONENTBUILDER_THE_SEARCH_FOR_THE_SNIPPETS_ARE_CASE_SENSITIVE_SO_IF_YOU_CHANGED_THE_LOCAL_BNAMESB_OF_EITHER_OR_THE_BSNIPPET_LIBRARY_OR_SNIPPET_TYPESB_IN_ANY_SMALL_WAY_THE_SYSTEM_WILL_NOT_BE_ABLE_TO_CONNECT_YOUR_LOCAL_SNIPPETS_WITH_THOSE_IN_THE_COMMUNITY_REPOSITORY_SO_WE_STRONGLY_ADVICE_TO_BKEEP_TO_THE_COMMUNITY_NAMINGB_TO_AVOID_MISMATCHING_THAT_WILL_IN_TURN_CAUSE_DUPLICATION_SO_IF_YOU_CHANGED_ANY_NAMES_JUST_CHANGE_THEM_BACK_AND_ALL_WILL_AGAIN_WORK_AS_EXPECTED="The search for the snippets are case sensitive so if you changed the local <b>names</b> of either or the <b>snippet, library or snippet types</b> in any small way, the system will not be able to connect your local snippets with those in the community repository. So we strongly advice to <b>keep to the community naming</b> to avoid mismatching, that will in turn cause duplication. So if you changed any names, just change them back and all will again work as expected."
|
||||
COM_COMPONENTBUILDER_THE_SEARCH_PROCESS_HAD_AN_ERROR_WITH_TABLE="The search process had an error with table"
|
||||
COM_COMPONENTBUILDER_THE_SERVER_DETAILS_FOR_BID_SB_COULD_NOT_BE_RETRIEVED="The server details for <b>(ID: %s)</b> could not be retrieved!"
|
||||
COM_COMPONENTBUILDER_THE_SNIPPETS_WERE_SUCCESSFULLY_EXPORTED="The Snippets Were Successfully Exported!"
|
||||
COM_COMPONENTBUILDER_THE_SNIPPET_WAS_SUCCESSFULLY_EXPORTED="The Snippet Was Successfully Exported!"
|
||||
@ -9197,6 +9345,8 @@ COM_COMPONENTBUILDER_THE_URL_S_SET_TO_RETRIEVE_THE_PACKAGES_DOES_NOT_RETURN_ANY_
|
||||
COM_COMPONENTBUILDER_THE_WIKI_CAN_ONLY_BE_LOADED_WHEN_YOUR_JCB_SYSTEM_HAS_INTERNET_CONNECTION="The wiki can only be loaded when your JCB system has internet connection."
|
||||
COM_COMPONENTBUILDER_THE_WIKI_IS_LOADING="The wiki is loading"
|
||||
COM_COMPONENTBUILDER_THIS_BSB_IS_NOT_LINKED_TO_ANY_OTHER_AREAS_OF_JCB_AT_THIS_TIME="This <b>%s</b> is not linked to any other areas of JCB at this time!"
|
||||
COM_COMPONENTBUILDER_THIS_CAN_NOT_BE_UNDONE_ARE_YOU_SURE_YOU_WANT_TO_CONTINUE="This can not be undone, are you sure you want to continue?"
|
||||
COM_COMPONENTBUILDER_THIS_CAN_NOT_BE_UNDONE_BYOU_HAVE_BEEN_WARNEDB="This can not be undone, <b>you have been warned</b>!"
|
||||
COM_COMPONENTBUILDER_THIS_MAY_TAKE_A_WHILE_DEPENDING_ON_THE_SIZE_OF_YOUR_PROJECT="This may take a while depending on the size of your project."
|
||||
COM_COMPONENTBUILDER_THIS_PACKAGE_BPASSEDB_THE_CHECKSUM_VALIDATIONBR_BR_SMALLMANUALLY_ALSO_VALIDATE_THAT_THE_CORRECT_CHECKSUM_WAS_USEDSMALLBR_THIS_CHECKSUM_BSB_MUST_BE_THE_SAME_AS_THE_ONE_FOUND_A_S_SA="This package <b>PASSED</b> the checksum validation!<br /><br /><small>Manually also validate that the correct checksum was used.</small><br />This checksum: <b>%s</b> must be the same as the one found @ <a %s %s</a>"
|
||||
COM_COMPONENTBUILDER_THIS_PACKAGE_HAS_NO_KEY="This package has no key."
|
||||
@ -9215,6 +9365,7 @@ COM_COMPONENTBUILDER_TRASHED_ITEMS="Trashed items"
|
||||
COM_COMPONENTBUILDER_TRASH_AREA="Trash Area"
|
||||
COM_COMPONENTBUILDER_TUTORIAL_ON_FORKING_JCB_SNIPPETS_BSB="Tutorial on forking JCB snippets: <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_TUTORIAL_ON_MAKING_A_PULL_REQUEST_BSB="Tutorial on making a pull request: <b>%s</b>"
|
||||
COM_COMPONENTBUILDER_TWO_SPACES="2 Spaces"
|
||||
COM_COMPONENTBUILDER_TYPE="Type"
|
||||
COM_COMPONENTBUILDER_TYPE_ADMIN_CUSTOM_TABS="Admin Custom Tabs"
|
||||
COM_COMPONENTBUILDER_TYPE_ADMIN_FIELDS="Admin Fields"
|
||||
@ -9272,7 +9423,9 @@ COM_COMPONENTBUILDER_TYPE_VALIDATION_RULE="Validation Rule"
|
||||
COM_COMPONENTBUILDER_UNACTIVE_ONLY_FOUR_TEXT_FIELD="Unactive (only 4 text_field)"
|
||||
COM_COMPONENTBUILDER_UNDERNEATH_TABS="Underneath Tabs"
|
||||
COM_COMPONENTBUILDER_UPDATE="Update"
|
||||
COM_COMPONENTBUILDER_UPDATE_ALL="Update All"
|
||||
COM_COMPONENTBUILDER_UPDATE_ALL_DIVERGED_SNIPPETS="Update All Diverged Snippets"
|
||||
COM_COMPONENTBUILDER_UPDATE_ALL_ITEMS_FOUND_WITH_THIS_DATABASE_SEARCH_WITH_THE_REPLACE_VALUE="Update all items found with this database search, with the replace value."
|
||||
COM_COMPONENTBUILDER_UPDATE_ALL_OUT_DATED_SNIPPETS="Update All Out Dated Snippets"
|
||||
COM_COMPONENTBUILDER_UP_TO_DATE="Up to date"
|
||||
COM_COMPONENTBUILDER_USAGE="Usage"
|
||||
@ -9383,15 +9536,30 @@ COM_COMPONENTBUILDER_WEBSITE="Website"
|
||||
COM_COMPONENTBUILDER_WEBSITE_OF_S="Website of %s"
|
||||
COM_COMPONENTBUILDER_WEBSITE_S="Website: %s"
|
||||
COM_COMPONENTBUILDER_WE_DID_NOT_CHECK_THE_SNIPPET_IT_SELF_TO_SEE_IF_IT_CHANGED_WE_ONLY_WORK_ON_DATES="We did not check the snippet it self, to see if it changed. We only work on dates."
|
||||
COM_COMPONENTBUILDER_WE_EXTEND_OUR_GRATITUDE_TO_ALL_THOSE_WHO_SUPPORT_JOOMLA_COMPONENT_BUILDER_JCB_WHETHER_AS_A_HOBBY_OR_AS_A_PART_OF_THEIR_BUSINESS_YOUR_CONTRIBUTIONS_WHETHER_FINANCIAL_OR_IN_THE_FORM_OF_ACTIVE_INVOLVEMENT_HAVE_HAD_A_SIGNIFICANT_IMPACT_ON_ENSURING_THE_GROWTH_AND_RELEVANCE_OF_THIS_VITAL_TOOL_FOR_PHP_PROGRAMMERS_WE_HIGHLY_VALUE_THE_DEDICATION_OF_HOBBYISTS_AND_THE_COMMITMENT_OF_COMPANIES_WHO_SUPPORT_JCB_AS_THEY_HAVE_ALLOWED_THE_PROJECT_TO_CONTINUE_ITS_DEVELOPMENT_AND_MAINTENANCE_PROVIDING_VALUABLE_RESOURCES_FOR_THE_COMMUNITY_WE_ARE_GRATEFUL_FOR_YOUR_CONTRIBUTIONS_NO_MATTER_HOW_SMALL_AND_THANK_YOU_FOR_BEING_A_PART_OF_THE_POSITIVE_IMPACT_THAT_JCB_HAS_ON_THE_PHP_PROGRAMMING_COMMUNITY="We extend our gratitude to all those who support Joomla Component Builder (JCB), whether as a hobby or as a part of their business. Your contributions, whether financial or in the form of active involvement, have had a significant impact on ensuring the growth and relevance of this vital tool for PHP programmers. We highly value the dedication of hobbyists and the commitment of companies who support JCB, as they have allowed the project to continue its development and maintenance, providing valuable resources for the community. We are grateful for your contributions, no matter how small, and thank you for being a part of the positive impact that JCB has on the PHP programming community."
|
||||
COM_COMPONENTBUILDER_WE_EXTEND_OUR_HEARTFELT_APPRECIATION_TO_THOSE_WHO_HAVE_SUPPORTED_THE_JOOMLA_COMPONENT_BUILDER_JCB_PROJECT_OVER_THE_YEARS_YOUR_CONTRIBUTIONS_NO_MATTER_HOW_BIG_OR_SMALL_HAVE_BEEN_INSTRUMENTAL_IN_ENSURING_ITS_GROWTH_AND_RELEVANCE_AS_A_VITAL_TOOL_FOR_PHP_PROGRAMMERS_SEVEN_YEARS_AFTER_GOING_PUBLIC_JCB_IS_STILL_HERE_TODAY_BECAUSE_OF_THE_SUPPORT_OF_INDIVIDUALS_LIKE_YOU_WHO_BELIEVE_IN_THE_IMPORTANCE_OF_THIS_OPENSOURCE_PROJECT_YOUR_GENEROSITY_HAS_ALLOWED_THE_PROJECT_TO_CONTINUE_ITS_DEVELOPMENT_AND_MAINTENANCE_PROVIDING_VALUABLE_RESOURCES_FOR_THE_COMMUNITY_THANK_YOU_FOR_YOUR_UNWAVERING_SUPPORT_AND_FOR_BEING_A_PART_OF_JCBS_JOURNEY="We extend our heartfelt appreciation to those who have supported the Joomla Component Builder (JCB) project over the years. Your contributions, no matter how big or small, have been instrumental in ensuring its growth and relevance as a vital tool for PHP programmers. Seven years after going public, JCB is still here today because of the support of individuals like you who believe in the importance of this open-source project. Your generosity has allowed the project to continue its development and maintenance, providing valuable resources for the community. Thank you for your unwavering support and for being a part of JCB's journey."
|
||||
COM_COMPONENTBUILDER_WE_EXTEND_OUR_SINCERE_APPRECIATION_TO_THE_COMPANIES_WHO_USE_JOOMLA_COMPONENT_BUILDER_JCB_AND_SUPPORT_THE_PROJECT_YOUR_CONTRIBUTIONS_WHETHER_FINANCIAL_OR_IN_THE_FORM_OF_ACTIVE_INVOLVEMENT_HAVE_BEEN_INSTRUMENTAL_IN_ENSURING_THE_GROWTH_AND_RELEVANCE_OF_THIS_VITAL_TOOL_FOR_PHP_PROGRAMMERS_YOUR_SUPPORT_HAS_ALLOWED_JCB_TO_CONTINUE_ITS_DEVELOPMENT_AND_MAINTENANCE_PROVIDING_VALUABLE_RESOURCES_FOR_THE_COMMUNITY_THANK_YOU_FOR_YOUR_UNWAVERING_COMMITMENT_TO_THE_PROJECT_AND_FOR_BEING_A_PART_OF_JCBS_JOURNEY="We extend our sincere appreciation to the companies who use Joomla Component Builder (JCB) and support the project. Your contributions, whether financial or in the form of active involvement, have been instrumental in ensuring the growth and relevance of this vital tool for PHP programmers. Your support has allowed JCB to continue its development and maintenance, providing valuable resources for the community. Thank you for your unwavering commitment to the project and for being a part of JCB's journey."
|
||||
COM_COMPONENTBUILDER_WE_FAILED_TO_MOVE_BSB="We failed to move <b>%s</b>!"
|
||||
COM_COMPONENTBUILDER_WE_FOUND_DYNAMIC_CODE_BALL_IN_ONE_LINEB_AND_IGNORED_IT_PLEASE_REVIEW_S_FOR_MORE_DETAILS="We found dynamic code <b>all in one line</b>, and ignored it! Please review (%s) for more details!"
|
||||
COM_COMPONENTBUILDER_WE_FOUND_SOME_INSTANCES_IN_S="We found some instances in %s"
|
||||
COM_COMPONENTBUILDER_WE_SUCCESSFULLY_MOVED_BSB="We successfully moved <b>%s</b>!"
|
||||
COM_COMPONENTBUILDER_WHAT_VERSION_OF_JOOMLA_WOULD_YOU_LIKE_TO_TARGET="What version of Joomla would you like to target."
|
||||
COM_COMPONENTBUILDER_WHICH_TYPE_OF_INDENTATION_WOULD_YOU_LIKE_TO_USE_PLEASE_NOTE_THAT_THIS_DOES_NOT_YET_IMPACT_THE_STATIC_TEMPLATES="Which type of indentation would you like to use? Please note that this does not yet impact the static templates."
|
||||
COM_COMPONENTBUILDER_WHILE_WE_DOWNLOAD_ALL_TWENTY_SIX_COMPILER_GIF_ANIMATIONS_RANDOMLY_USED_IN_THE_COMPILER_GUI_DURING_COMPILATION="While we download all 26 compiler GIF animations randomly used in the compiler GUI during compilation"
|
||||
COM_COMPONENTBUILDER_WHOLE_WORD="Whole Word"
|
||||
COM_COMPONENTBUILDER_WIKI="Wiki"
|
||||
COM_COMPONENTBUILDER_WITH="with"
|
||||
COM_COMPONENTBUILDER_WITHOUT_SUFFICIENT_SUPPORT_THE_FUTURE_OF_JOOMLA_COMPONENT_BUILDER_JCB_IS_IN_JEOPARDY_AS_A_VITAL_TOOL_FOR_PHP_PROGRAMMERS_IT_IS_CRUCIAL_TO_ENSURE_ITS_CONTINUED_DEVELOPMENT_AND_MAINTENANCE_BY_MAKING_A_BFINANCIAL_CONTRIBUTIONB_NO_MATTER_HOW_SMALL_YOU_ARE_HELPING_TO_SAFEGUARD_THE_FUTURE_OF_THIS_OPENSOURCE_PROJECT_NEGLECTING_TO_SUPPORT_JCB_COULD_RESULT_IN_ITS_DECLINE_AND_LOSS_AS_A_RESOURCE_FOR_THE_COMMUNITY="Without sufficient support, the future of Joomla Component Builder (JCB) is in jeopardy. As a vital tool for PHP programmers, it is crucial to ensure its continued development and maintenance. By making a <b>financial contribution</b>, no matter how small, you are helping to safeguard the future of this open-source project. Neglecting to support JCB could result in its decline and loss as a resource for the community."
|
||||
COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_DO_A_REVERSE_SEARCH="Would you like to do a reverse search?"
|
||||
COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_OVERRIDE_THE_BUILD_DATE="Would you like to override the build date."
|
||||
COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_REPEAT_THE_SAME_SEARCH="Would you like to repeat the same search?"
|
||||
COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_SEE_THE_ADVANCED_COMPILER_OPTIONS="Would you like to see the advanced compiler options?"
|
||||
COM_COMPONENTBUILDER_YES="Yes"
|
||||
COM_COMPONENTBUILDER_YOUR_DATA_IS_ENCRYPTED_WITH_A_AES_ONE_HUNDRED_AND_TWENTY_EIGHT_BIT_ENCRYPTION_USING_THE_ABOVE_THIRTY_TWO_CHARACTER_KEY="Your data is encrypted with a AES 128 bit encryption using the above 32 character key."
|
||||
COM_COMPONENTBUILDER_YOUR_DATA_IS_ENCRYPTED_WITH_A_AES_ONE_HUNDRED_AND_TWENTY_EIGHT_BIT_ENCRYPTION_USING_THE_ABOVE_THIRTY_TWO_CHARACTER_KEY_WITHOUT_THIS_KEY_IT_WILL_TAKE_THE_CURRENT_TECHNOLOGY_WITH_A_BRUTE_FORCE_ATTACK_METHOD_MORE_THEN_A_HREFHTTPRANDOMIZECOMHOWLONGTOHACKPASS_TARGET_BLANK_TITLEHOW_LONG_TO_HACK_PASSSEVEN_HUNDRED_ZERO_ZERO_ZERO_ZERO_ZERO_ZERO_ZERO_ZERO_ZERO_ZEROA_YEARS_TO_CRACK_THEORETICALLY_UNLESS_THEY_HAVE_THIS_KEY_ABOVE_SO_DO_KEEP_IT_SAFE="Your data is encrypted with a AES 128 bit encryption using the above 32 character key. Without this key it will take the current technology with a brute force attack method more then <a href="http://random-ize.com/how-long-to-hack-pass/" target="_blank" title="How long to hack pass">700 000 000 000 000 000 000 000 000 000 000</a> years to crack theoretically. Unless they have this key above, so do keep it safe."
|
||||
COM_COMPONENTBUILDER_YES_UPDATE_ALL="Yes! Update ALL"
|
||||
COM_COMPONENTBUILDER_YOUR_ARE_ABOUT_TO_UPDATE_BALLB_VALUES_THAT_CAN_BE_FOUND_IN_THE_DATABASE="Your are about to update <b>ALL</b> values that can be found in the database."
|
||||
COM_COMPONENTBUILDER_YOUR_ARE_ABOUT_TO_UPDATE_ROW="Your are about to update row"
|
||||
COM_COMPONENTBUILDER_YOUR_COMPONENT_WILL_BE_COMPILED_TO_WORK_IN_JOOMLA_THREE="Your component will be compiled to work in Joomla 3"
|
||||
COM_COMPONENTBUILDER_YOUR_DATA_IS_ENCRYPTED_WITH_A_AES_TWO_HUNDRED_AND_FIFTY_SIX_BIT_ENCRYPTION_USING_THE_ABOVE_THIRTY_TWO_CHARACTER_KEY="Your data is encrypted with a AES 256 bit encryption using the above 32 character key."
|
||||
COM_COMPONENTBUILDER_YOU_ARE_CURRENTLY_VIEWING_THE_TRASHED_ITEMS="You are currently viewing the trashed items."
|
||||
COM_COMPONENTBUILDER_YOU_ARE_CURRENTLY_VIEWING_THE_TRASH_AREA_AND_YOU_DONT_HAVE_ANY_ITEMS_IN_TRASH_AT_THE_MOMENT="You are currently viewing the trash area, and you don't have any items in trash at the moment!"
|
||||
COM_COMPONENTBUILDER_YOU_CAN_DIRECTLY_DOWNLOAD_THE_LATEST_UPDATE_OR_USE_THE_JOOMLA_UPDATE_AREA="You can directly download the latest update, or use the Joomla update area."
|
||||
@ -9418,9 +9586,11 @@ COM_COMPONENTBUILDER_YOU_MUST_SELECT_A_COMPONENT="You must select a component!"
|
||||
COM_COMPONENTBUILDER_YOU_SHOULD_ADD_THE_CORRECT_OWNER_DETAILS="You should add the correct owner details."
|
||||
COM_COMPONENTBUILDER_YOU_SHOULD_ONLY_CONTINUE_THIS_IMPORT_IF_YOU_HAVE_BACKUP_YOUR_COMPONENTS_AND_INSURED_THAT_THE_PACKAGE_OWNER_IS_REPUTABLE="You should only continue this import if you have backup your components, and insured that the package owner is reputable."
|
||||
COM_COMPONENTBUILDER_YOU_WILL_NEED_TO_KNOW_HOW_S_WORKS_BASIC_YOU_WILL_ALSO_NEED_A_S_ACCOUNT_AND_KNOW_HOW_TO_MAKE_A_PULL_REQUEST_ON_GITHUB="you will need to know how %s works (basic). You will also need a %s account and know how to make a pull request on github."
|
||||
COM_COMPONENTBUILDER_YOU_WILL_REPLACE="You will replace"
|
||||
COM_COMPONENTBUILDER_ZIPPED_FILE_LOCATION="Zipped File Location"
|
||||
COM_COMPONENTBUILDER__ADD_YOUR_PHP_SCRIPT_HERE="// Add your php script here"
|
||||
COM_COMPONENTBUILDER__HAS_BEEN_CHECKED_OUT_BY_S="% has been checked out by %s"
|
||||
COM_COMPONENTBUILDER__SEARCH_ALL_="- Search All -"
|
||||
COM_COMPONENTBUILDER__SELECT_COMPONENT_="- Select Component -"
|
||||
COM_COMPONENTBUILDER__SELECT_PACKAGE_="- Select Package -"
|
||||
COM_COMPONENTBUILDER__SINCE_YOU_DONT_HAVE_PERMISSION_TO_CREATE_S=", since you don't have permission to create %s!"
|
||||
|
@ -85,8 +85,6 @@ COM_COMPONENTBUILDER_ADMIN_VIEWS_BATCH_USE="Admin Views Batch Use"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_BATCH_USE_DESC="Allows users in this group to use batch copy/update method of batch admin views"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_CREATE="Admin Views Create"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_CREATE_DESC="Allows the users in this group to create create admin views"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_ADD="Admin Views Dashboard Add"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_ADD_DESC="Allows the users in this group to dashboard add of admin view"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_LIST="Admin Views Dashboard List"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_DASHBOARD_LIST_DESC="Allows the users in this group to dashboard list of admin view"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEWS_DELETE="Admin Views Delete"
|
||||
@ -440,8 +438,6 @@ COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_BATCH_USE="Custom Admin Views Batch Use"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_BATCH_USE_DESC="Allows users in this group to use batch copy/update method of batch custom admin views"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_CREATE="Custom Admin Views Create"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_CREATE_DESC="Allows the users in this group to create create custom admin views"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_ADD="Custom Admin Views Dashboard Add"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_ADD_DESC="Allows the users in this group to dashboard add of custom admin view"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_LIST="Custom Admin Views Dashboard List"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DASHBOARD_LIST_DESC="Allows the users in this group to dashboard list of custom admin view"
|
||||
COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEWS_DELETE="Custom Admin Views Delete"
|
||||
@ -1022,6 +1018,8 @@ COM_COMPONENTBUILDER_SEARCH_ACCESS="Search Access"
|
||||
COM_COMPONENTBUILDER_SEARCH_ACCESS_DESC="Allows the users in this group to access search."
|
||||
COM_COMPONENTBUILDER_SEARCH_COMPILER_BUTTON_ACCESS="Search Compiler Button Access"
|
||||
COM_COMPONENTBUILDER_SEARCH_COMPILER_BUTTON_ACCESS_DESC="Allows the users in this group to access the compiler button."
|
||||
COM_COMPONENTBUILDER_SEARCH_DASHBOARD_LIST="Search Dashboard List"
|
||||
COM_COMPONENTBUILDER_SEARCH_DASHBOARD_LIST_DESC="Allows the users in this group to dashboard list of Search"
|
||||
COM_COMPONENTBUILDER_SEARCH_SUBMENU="Search Submenu"
|
||||
COM_COMPONENTBUILDER_SEARCH_SUBMENU_DESC="Allows the users in this group to submenu of Search"
|
||||
COM_COMPONENTBUILDER_SERVERS_ACCESS="Servers Access"
|
||||
@ -1058,8 +1056,6 @@ COM_COMPONENTBUILDER_SITE_VIEWS_BATCH_USE="Site Views Batch Use"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_BATCH_USE_DESC="Allows users in this group to use batch copy/update method of batch site views"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_CREATE="Site Views Create"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_CREATE_DESC="Allows the users in this group to create create site views"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_ADD="Site Views Dashboard Add"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_ADD_DESC="Allows the users in this group to dashboard add of site view"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_LIST="Site Views Dashboard List"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_DASHBOARD_LIST_DESC="Allows the users in this group to dashboard list of site view"
|
||||
COM_COMPONENTBUILDER_SITE_VIEWS_DELETE="Site Views Delete"
|
||||
|
116
admin/layouts/jcbsupportmessage.php
Normal file
116
admin/layouts/jcbsupportmessage.php
Normal file
@ -0,0 +1,116 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 30th April, 2015
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
// No direct access to this file
|
||||
defined('JPATH_BASE') or die('Restricted access');
|
||||
|
||||
// Different support requests/appreciation
|
||||
$support = [
|
||||
JText::_("COM_COMPONENTBUILDER_JOOMLA_COMPONENT_BUILDER_JCB_IS_A_CRUCIAL_TOOL_FOR_PHP_PROGRAMMERS_WHO_USE_JOOMLA_TO_EARN_A_LIVING_BY_MAKING_A_BFINANCIAL_DONATIONB_YOU_CAN_SUPPORT_THE_GROWTH_AND_CONTINUITY_OF_THIS_VITAL_RESOURCE_AND_ENSURE_ITS_RELEVANCE_FOR_YEARS_TO_COME_YOUR_CONTRIBUTION_NO_MATTER_HOW_BIG_OR_SMALL_WILL_BE_DEEPLY_APPRECIATED_BY_THE_PROJECTS_TEAM_AND_THE_WIDER_COMMUNITY"),
|
||||
JText::_("COM_COMPONENTBUILDER_THE_CONTINUED_SUPPORT_OF_INDIVIDUALS_LIKE_YOU_HAS_ALLOWED_JOOMLA_COMPONENT_BUILDER_JCB_TO_THRIVE_FOR_SEVEN_YEARS_SINCE_GOING_PUBLIC_YOUR_CONTRIBUTIONS_HAVE_BEEN_CRUCIAL_IN_ENSURING_THE_GROWTH_AND_RELEVANCE_OF_THIS_VITAL_TOOL_FOR_PHP_PROGRAMMERS_THANK_YOU_FOR_YOUR_SUPPORT_AND_FOR_BEING_A_PART_OF_JCBS_JOURNEY"),
|
||||
JText::_("COM_COMPONENTBUILDER_SUPPORT_JOOMLA_COMPONENT_BUILDER_JCB_WITH_A_BFINANCIAL_DONATIONB_TO_SHOW_GRATITUDE_FOR_THE_TIME_AND_EFFORT_SAVED_IN_YOUR_DEVELOPMENT_PROCESS_YOUR_CONTRIBUTION_NO_MATTER_THE_SIZE_WILL_BE_APPRECIATED_BY_THE_PROJECTS_TEAM_AND_THE_WIDER_COMMUNITY_HELP_ENSURE_THE_GROWTH_AND_RELEVANCE_OF_THIS_ESSENTIAL_TOOL"),
|
||||
JText::_("COM_COMPONENTBUILDER_INVEST_IN_THE_FUTURE_OF_JOOMLA_COMPONENT_BUILDER_JCB_BY_MAKING_A_BFINANCIAL_DONATIONB_SUPPORT_THE_NECESSARY_DEVELOPMENT_AND_MAINTENANCE_OF_THIS_OPENSOURCE_PROJECT_ENSURING_ITS_CONTINUED_GROWTH_AND_RELEVANCE_FOR_THE_COMMUNITY_YOUR_CONTRIBUTION_WILL_HELP_SECURE_THE_FUTURE_OF_THIS_VITAL_TOOL_FOR_PHP_PROGRAMMERS"),
|
||||
JText::_("COM_COMPONENTBUILDER_INVEST_IN_THE_FUTURE_OF_JOOMLA_COMPONENT_BUILDER_JCB_BY_MAKING_A_BFINANCIAL_CONTRIBUTIONB_NO_MATTER_HOW_SMALL_THE_CONTINUAL_SUPPORT_OF_ALL_THOSE_USING_THE_TOOL_WILL_BE_MORE_THAN_ENOUGH_TO_ENSURE_ITS_CONTINUED_GROWTH_AND_RELEVANCE_BY_INVESTING_IN_THIS_OPENSOURCE_PROJECT_YOU_ARE_SECURING_ITS_FUTURE_AS_A_VITAL_TOOL_FOR_PHP_PROGRAMMERS"),
|
||||
JText::_("COM_COMPONENTBUILDER_WE_EXTEND_OUR_GRATITUDE_TO_ALL_THOSE_WHO_SUPPORT_JOOMLA_COMPONENT_BUILDER_JCB_WHETHER_AS_A_HOBBY_OR_AS_A_PART_OF_THEIR_BUSINESS_YOUR_CONTRIBUTIONS_WHETHER_FINANCIAL_OR_IN_THE_FORM_OF_ACTIVE_INVOLVEMENT_HAVE_HAD_A_SIGNIFICANT_IMPACT_ON_ENSURING_THE_GROWTH_AND_RELEVANCE_OF_THIS_VITAL_TOOL_FOR_PHP_PROGRAMMERS_WE_HIGHLY_VALUE_THE_DEDICATION_OF_HOBBYISTS_AND_THE_COMMITMENT_OF_COMPANIES_WHO_SUPPORT_JCB_AS_THEY_HAVE_ALLOWED_THE_PROJECT_TO_CONTINUE_ITS_DEVELOPMENT_AND_MAINTENANCE_PROVIDING_VALUABLE_RESOURCES_FOR_THE_COMMUNITY_WE_ARE_GRATEFUL_FOR_YOUR_CONTRIBUTIONS_NO_MATTER_HOW_SMALL_AND_THANK_YOU_FOR_BEING_A_PART_OF_THE_POSITIVE_IMPACT_THAT_JCB_HAS_ON_THE_PHP_PROGRAMMING_COMMUNITY"),
|
||||
JText::_("COM_COMPONENTBUILDER_WITHOUT_SUFFICIENT_SUPPORT_THE_FUTURE_OF_JOOMLA_COMPONENT_BUILDER_JCB_IS_IN_JEOPARDY_AS_A_VITAL_TOOL_FOR_PHP_PROGRAMMERS_IT_IS_CRUCIAL_TO_ENSURE_ITS_CONTINUED_DEVELOPMENT_AND_MAINTENANCE_BY_MAKING_A_BFINANCIAL_CONTRIBUTIONB_NO_MATTER_HOW_SMALL_YOU_ARE_HELPING_TO_SAFEGUARD_THE_FUTURE_OF_THIS_OPENSOURCE_PROJECT_NEGLECTING_TO_SUPPORT_JCB_COULD_RESULT_IN_ITS_DECLINE_AND_LOSS_AS_A_RESOURCE_FOR_THE_COMMUNITY"),
|
||||
JText::_("COM_COMPONENTBUILDER_WE_EXTEND_OUR_HEARTFELT_APPRECIATION_TO_THOSE_WHO_HAVE_SUPPORTED_THE_JOOMLA_COMPONENT_BUILDER_JCB_PROJECT_OVER_THE_YEARS_YOUR_CONTRIBUTIONS_NO_MATTER_HOW_BIG_OR_SMALL_HAVE_BEEN_INSTRUMENTAL_IN_ENSURING_ITS_GROWTH_AND_RELEVANCE_AS_A_VITAL_TOOL_FOR_PHP_PROGRAMMERS_SEVEN_YEARS_AFTER_GOING_PUBLIC_JCB_IS_STILL_HERE_TODAY_BECAUSE_OF_THE_SUPPORT_OF_INDIVIDUALS_LIKE_YOU_WHO_BELIEVE_IN_THE_IMPORTANCE_OF_THIS_OPENSOURCE_PROJECT_YOUR_GENEROSITY_HAS_ALLOWED_THE_PROJECT_TO_CONTINUE_ITS_DEVELOPMENT_AND_MAINTENANCE_PROVIDING_VALUABLE_RESOURCES_FOR_THE_COMMUNITY_THANK_YOU_FOR_YOUR_UNWAVERING_SUPPORT_AND_FOR_BEING_A_PART_OF_JCBS_JOURNEY"),
|
||||
JText::_("COM_COMPONENTBUILDER_WE_EXTEND_OUR_SINCERE_APPRECIATION_TO_THE_COMPANIES_WHO_USE_JOOMLA_COMPONENT_BUILDER_JCB_AND_SUPPORT_THE_PROJECT_YOUR_CONTRIBUTIONS_WHETHER_FINANCIAL_OR_IN_THE_FORM_OF_ACTIVE_INVOLVEMENT_HAVE_BEEN_INSTRUMENTAL_IN_ENSURING_THE_GROWTH_AND_RELEVANCE_OF_THIS_VITAL_TOOL_FOR_PHP_PROGRAMMERS_YOUR_SUPPORT_HAS_ALLOWED_JCB_TO_CONTINUE_ITS_DEVELOPMENT_AND_MAINTENANCE_PROVIDING_VALUABLE_RESOURCES_FOR_THE_COMMUNITY_THANK_YOU_FOR_YOUR_UNWAVERING_COMMITMENT_TO_THE_PROJECT_AND_FOR_BEING_A_PART_OF_JCBS_JOURNEY")
|
||||
];
|
||||
|
||||
// build the support message
|
||||
$support_message = $support[random_int(0, 8)];
|
||||
|
||||
// the button titles
|
||||
$titles = [
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_ENABLES_PHP_DEVELOPMENT"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_SUPPORTS_OPENSOURCE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_SAVES_TIME"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_IMPROVES_WORKFLOW"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_EMPOWERS_PHP_DEVELOPERS"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_STREAMLINES_DEVELOPMENT"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_PROMOTES_EFFICIENCY"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_ENHANCES_PRODUCTIVITY"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INCREASES_REVENUE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_REDUCES_DEVELOPMENT_COSTS"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_SUPPORTS_THE_PHP_COMMUNITY"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_IMPROVES_PHP_DEVELOPMENT"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_HELPS_GROW_BUSINESSES"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_SUPPORTS_PHP_INNOVATION"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_CONTRIBUTES_TO_OPENSOURCE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_PROVIDES_A_BETTER_EXPERIENCE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_OFFERS_MORE_FEATURES"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INCREASES_DEVELOPMENT_SPEED"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_IMPROVES_USER_EXPERIENCE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INCREASES_USER_SATISFACTION"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_LOWERS_DEVELOPMENT_STRESS"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_PROMOTES_GOODWILL"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_OFFERS_A_STRONGER_SOLUTION"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_SUPPORTS_A_WORTHY_CAUSE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_BUILDS_A_BETTER_FUTURE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_FOSTERS_A_STRONG_COMMUNITY"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_IMPROVES_PHPS_REPUTATION"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_SUPPORTS_A_THRIVING_ECOSYSTEM"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_HELPS_PHP_THRIVE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INVESTS_IN_PHPS_SUCCESS")
|
||||
];
|
||||
|
||||
// build the support button
|
||||
$support_titles = $titles[random_int(0, 29)];
|
||||
|
||||
// the button names
|
||||
$button_names = [
|
||||
JText::_("COM_COMPONENTBUILDER_DONATE_TO_JCB"),
|
||||
JText::_("COM_COMPONENTBUILDER_SUPPORT_JCB_TODAY"),
|
||||
JText::_("COM_COMPONENTBUILDER_CONTRIBUTE_TO_JCB"),
|
||||
JText::_("COM_COMPONENTBUILDER_INVEST_IN_JCB"),
|
||||
JText::_("COM_COMPONENTBUILDER_GIVE_TO_JCB"),
|
||||
JText::_("COM_COMPONENTBUILDER_JOIN_JCBS_MISSION"),
|
||||
JText::_("COM_COMPONENTBUILDER_HELP_JCB_GROW"),
|
||||
JText::_("COM_COMPONENTBUILDER_BE_A_PART_OF_JCB"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_NEEDS_YOU"),
|
||||
JText::_("COM_COMPONENTBUILDER_BECOME_A_CONTRIBUTOR"),
|
||||
JText::_("COM_COMPONENTBUILDER_EMPOWER_JCB"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INVEST_IN_IMPACT"),
|
||||
JText::_("COM_COMPONENTBUILDER_JOIN_JCBS_COMMUNITY"),
|
||||
JText::_("COM_COMPONENTBUILDER_MAKE_A_DIFFERENCE_WITH_JCB"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_YOUR_SUPPORT_MATTERS"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INVEST_IN_THE_FUTURE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JOIN_JCBS_JOURNEY"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_YOUR_SUPPORT_COUNTS"),
|
||||
JText::_("COM_COMPONENTBUILDER_EMPOWER_THE_FUTURE_WITH_JCB"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_YOUR_CONTRIBUTION_MATTERS"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INVEST_IN_PROGRESS"),
|
||||
JText::_("COM_COMPONENTBUILDER_JOIN_JCBS_VISION"),
|
||||
JText::_("COM_COMPONENTBUILDER_ELEVATE_JCB_TODAY"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INVEST_IN_CHANGE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_YOUR_DONATION_MATTERS"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_BE_THE_CHANGE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JOIN_JCBS_SUCCESS"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INVEST_IN_SUCCESS"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_YOUR_SUPPORT_IS_KEY"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INVEST_IN_THE_COMMUNITY"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_YOUR_SUPPORT_MATTERS_MOST"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INVEST_IN_YOUR_FUTURE"),
|
||||
JText::_("COM_COMPONENTBUILDER_JCB_INVEST_IN_PROGRESS_TODAY")
|
||||
];
|
||||
|
||||
// build the support button
|
||||
$support_button = $button_names[random_int(0, 32)];
|
||||
|
||||
?>
|
||||
<?php echo $support_message; ?>
|
||||
<br /><br />
|
||||
<img src="https://opencollective.com/joomla-component-builder/tiers/badge.svg" />
|
||||
<br /><br />
|
||||
<a class="btn btn-mini btn-success" href="https://opencollective.com/joomla-component-builder/donate?interval=month&amount=20" title="<?php echo $support_titles; ?>" trage="_blank">
|
||||
<?php echo $support_button; ?>
|
||||
</a>
|
||||
<br />
|
45
admin/layouts/power/composer_fullwidth.php
Normal file
45
admin/layouts/power/composer_fullwidth.php
Normal file
@ -0,0 +1,45 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 30th April, 2015
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
// get the form
|
||||
$form = $displayData->getForm();
|
||||
|
||||
// get the layout fields override method name (from layout path/ID)
|
||||
$layout_path_array = explode('.', $this->getLayoutId());
|
||||
// Since we cannot pass the layout and tab names as parameters to the model method
|
||||
// this name combination of tab and layout in the method name is the only work around
|
||||
// seeing that JCB uses those two values (tab_name & layout_name) as the layout file name.
|
||||
// example of layout name: details_left.php
|
||||
// example of method name: getFields_details_left()
|
||||
$fields_tab_layout = 'fields_' . $layout_path_array[1];
|
||||
|
||||
// get the fields
|
||||
$fields = $displayData->get($fields_tab_layout) ?: array(
|
||||
'autoload_composer_note',
|
||||
'composer'
|
||||
);
|
||||
|
||||
$hiddenFields = $displayData->get('hidden_fields') ?: array();
|
||||
|
||||
?>
|
||||
<?php if ($fields && count((array) $fields)) :?>
|
||||
<div class="form-vertical">
|
||||
<?php foreach($fields as $field): ?>
|
||||
<?php if (in_array($field, $hiddenFields)) : ?>
|
||||
<?php $form->setFieldAttribute($field, 'type', 'hidden'); ?>
|
||||
<?php endif; ?>
|
||||
<?php echo $form->renderField($field, null, null, array('class' => 'control-wrapper-' . $field)); ?>
|
||||
<?php endforeach; ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
43
admin/layouts/rows.php
Normal file
43
admin/layouts/rows.php
Normal file
@ -0,0 +1,43 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 30th April, 2015
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
// No direct access to this file
|
||||
defined('JPATH_BASE') or die('Restricted access');
|
||||
|
||||
$headers = $displayData['headers'];
|
||||
$items = $displayData['items'];
|
||||
|
||||
?>
|
||||
<?php if (is_array($items)): ?>
|
||||
<?php foreach ($items as $row => $values): ?>
|
||||
<tr>
|
||||
<?php foreach($values as $value): ?>
|
||||
<td class=""><?php echo $value; ?></td>
|
||||
<?php endforeach; ?>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
<?php elseif (is_numeric($items) && is_array($headers)): ?>
|
||||
<?php for( $row = 0; $row < $items; $row++): ?>
|
||||
<tr class="">
|
||||
<?php foreach($headers as $header): ?>
|
||||
<td class=""> </td>
|
||||
<?php endforeach; ?>
|
||||
</tr>
|
||||
<?php endfor; ?>
|
||||
<?php elseif (is_numeric($items) && is_numeric($headers)): ?>
|
||||
<?php for( $row = 0; $row < $items; $row++): ?>
|
||||
<tr class="">
|
||||
<?php for( $column = 0; $column < $headers; $column++): ?>
|
||||
<td class=""> </td>
|
||||
<?php endfor; ?>
|
||||
</tr>
|
||||
<?php endfor; ?>
|
||||
<?php endif; ?>
|
72
admin/layouts/table.php
Normal file
72
admin/layouts/table.php
Normal file
@ -0,0 +1,72 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 30th April, 2015
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
// No direct access to this file
|
||||
defined('JPATH_BASE') or die('Restricted access');
|
||||
|
||||
$table_id = (isset($displayData['id'])) ? $displayData['id'] : ComponentbuilderHelper::randomkey(7);
|
||||
$name = (isset($displayData['name'])) ? $displayData['name'] : false;
|
||||
$headers = (isset($displayData['headers'])) ? $displayData['headers'] : [JText::_('COM_COMPONENTBUILDER_NO'), JText::_('COM_COMPONENTBUILDER_HEADERS'), JText::_('COM_COMPONENTBUILDER_FOUND')];
|
||||
$items = (isset($displayData['items'])) ? $displayData['items'] : 6;
|
||||
|
||||
?>
|
||||
<div class="uk-overflow-auto">
|
||||
<table id="<?php echo $table_id; ?>" class="uk-table">
|
||||
<thead>
|
||||
<?php if (is_array($headers)): ?>
|
||||
<?php if ($name): ?>
|
||||
<tr>
|
||||
<th colspan="<?php echo count($headers); ?>" style="text-align:center"><b><?php echo $name; ?></b></th>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<tr>
|
||||
<?php foreach($headers as $code_name => $header): ?>
|
||||
<?php
|
||||
if (is_numeric($code_name))
|
||||
{
|
||||
$code_name = ComponentbuilderHelper::safeString($header);
|
||||
}
|
||||
?>
|
||||
<th data-name="<?php echo $code_name; ?>"><?php echo $header; ?></th>
|
||||
<?php endforeach; ?>
|
||||
</tr>
|
||||
<?php elseif (is_numeric($headers)): ?>
|
||||
<?php if ($name): ?>
|
||||
<tr>
|
||||
<th colspan="<?php echo (int) $headers; ?>" style="text-align:center"><b><?php echo $name; ?></b></th>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<tr style="position: absolute; top: -9999px; left: -9999px;">
|
||||
<?php for( $row = 0; $row < $headers; $row++): ?>
|
||||
<th><?php echo ComponentbuilderHelper::safeString($row); ?></th>
|
||||
<?php endfor; ?>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php echo JLayoutHelper::render('rows', ['headers' => $headers, 'items' => $items]); ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<?php
|
||||
// Initialize the table if [init is not set], or [is true]
|
||||
// To stop initialization set $displayData['init'] = false;
|
||||
if (!isset($displayData['init']) || $displayData['init']) :
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
jQuery(document).ready(function() {
|
||||
var <?php echo $table_id; ?> = jQuery('#<?php echo $table_id; ?>').DataTable({
|
||||
paging: false,
|
||||
select: true
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<?php endif; ?>
|
@ -14,8 +14,13 @@ defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use Joomla\CMS\MVC\Model\ListModel;
|
||||
use Joomla\Utilities\ArrayHelper;
|
||||
use Joomla\Registry\Registry;
|
||||
use VDM\Gitea\Gitea;
|
||||
use VDM\Joomla\Componentbuilder\Package\Factory as PackageFactory;
|
||||
use VDM\Joomla\Utilities\FileHelper;
|
||||
use VDM\Joomla\Utilities\JsonHelper;
|
||||
use VDM\Joomla\Utilities\StringHelper;
|
||||
use Joomla\Registry\Registry;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use VDM\Joomla\Componentbuilder\Search\Factory as SearchFactory;
|
||||
|
||||
/**
|
||||
@ -90,7 +95,7 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
// set the url
|
||||
$url = "https://api.crowdin.com/api/project/$identifier/info?key=$key&json";
|
||||
// get the details
|
||||
if (($details = ComponentbuilderHelper::getFileContents($url, false)) !== false && ComponentbuilderHelper::checkJson($details))
|
||||
if (($details = FileHelper::getContent($url, false)) !== false && JsonHelper::check($details))
|
||||
{
|
||||
$details = json_decode($details, true);
|
||||
// check if there is an error
|
||||
@ -102,9 +107,9 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
if (isset($details['details']))
|
||||
{
|
||||
$html = '<div class="alert alert-success" id="crowdin_message">';
|
||||
$html .= '<h1>' . JText::_('COM_COMPONENTBUILDER_COMPONENT_SUCCESSFULLY_LINKED') . '</h1>';
|
||||
$html .= '<h1>' . Text::_('COM_COMPONENTBUILDER_COMPONENT_SUCCESSFULLY_LINKED') . '</h1>';
|
||||
$html .= '<h3>' . $details['details']['name'] . '</h3>';
|
||||
if (ComponentbuilderHelper::checkString($details['details']['description']))
|
||||
if (StringHelper::check($details['details']['description']))
|
||||
{
|
||||
$html .= '<p>';
|
||||
$html .= $details['details']['description'];
|
||||
@ -128,7 +133,7 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
$html .= '</b></li>';
|
||||
$html .= '</ul>';
|
||||
$html .= '</div>';
|
||||
return array('html' => $html);
|
||||
return ['html' => $html];
|
||||
}
|
||||
}
|
||||
return false;
|
||||
@ -153,7 +158,7 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
$db->execute();
|
||||
if ($db->loadRowList())
|
||||
{
|
||||
return array( 'html' => $this->componentDetailsDisplay($db->loadObject()));
|
||||
return ['html' => $this->componentDetailsDisplay($db->loadObject())];
|
||||
}
|
||||
return false;
|
||||
}
|
||||
@ -166,47 +171,26 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
// convert URL
|
||||
$url = base64_decode($package);
|
||||
$url = str_replace('.zip', '.info', $url);
|
||||
|
||||
// check if url exist
|
||||
if ($info = ComponentbuilderHelper::getFileContents($url, false))
|
||||
if ($info = FileHelper::getContent($url, false))
|
||||
{
|
||||
// Get the encryption object.
|
||||
$db = 'COM_COMPONENTBUILDER_VJRZDESSMHBTRWFIFTYTWVZEROAESFLVVXJTMTHREEJTWOIXM';
|
||||
$password = base64_decode(JText::sprintf($db, 'QzdmV', '9kQ'));
|
||||
// we first use the new encryption
|
||||
// load phpseclib <https://phpseclib.com/docs/symmetric>
|
||||
$opened = false;
|
||||
if(ComponentbuilderHelper::crypt('AES', 'CBC') instanceof \phpseclib\Crypt\Rijndael)
|
||||
if ((($info_ = PackageFactory::_('Crypt')->decrypt($info, 'local')) !== null && JsonHelper::check($info_)) ||
|
||||
(($info_ = PackageFactory::_('Crypt')->decrypt($info, 'local.legacy')) !== null && JsonHelper::check($info_)) ||
|
||||
(($info_ = PackageFactory::_('Crypt')->decrypt($info, 'local.fof')) !== null && JsonHelper::check($info_)))
|
||||
{
|
||||
// load the system password
|
||||
ComponentbuilderHelper::crypt('AES', 'CBC')->setPassword($password, 'pbkdf2', 'sha256', 'VastDevelopmentMethod/salt');
|
||||
// open the info block
|
||||
$_info = ComponentbuilderHelper::crypt('AES', 'CBC')->decrypt(base64_decode($info));
|
||||
// check if we had success
|
||||
if ($_info !== false)
|
||||
{
|
||||
$opened = true;
|
||||
}
|
||||
}
|
||||
// check if we had success
|
||||
if (!$opened && class_exists('FOFEncryptAes'))
|
||||
{
|
||||
$opener = new FOFEncryptAes($password, 128);
|
||||
$_info = $opener->decryptString($info);
|
||||
// check if we had success
|
||||
if ($_info !== false)
|
||||
{
|
||||
$opened = true;
|
||||
$_info = rtrim($_info, "\0");
|
||||
}
|
||||
}
|
||||
// check if we have json
|
||||
if ($opened && ComponentbuilderHelper::checkJson($_info))
|
||||
{
|
||||
$info = json_decode($_info, true);
|
||||
return array('owner' => ComponentbuilderHelper::getPackageOwnerDetailsDisplay($info, true), 'packages' => ComponentbuilderHelper::getPackageComponentsDetailsDisplay($info));
|
||||
$info = json_decode($info_, true);
|
||||
|
||||
return [
|
||||
'owner' => PackageFactory::_('Display.Details')->owner($info, true),
|
||||
'packages' => PackageFactory::_('Display.Details')->components($info)
|
||||
];
|
||||
}
|
||||
}
|
||||
return array('error' => JText::_('COM_COMPONENTBUILDER_JCB_PACKAGE_INFO_PATH_DOES_NOT_WORK_WE_ADVICE_YOU_BNOT_TO_CONTINUEB_WITH_THE_IMPORT_OF_THE_SELECTED_PACKAGE'));
|
||||
|
||||
return [
|
||||
'error' => Text::_('COM_COMPONENTBUILDER_JCB_PACKAGE_INFO_PATH_DOES_NOT_WORK_WE_ADVICE_YOU_BNOT_TO_CONTINUEB_WITH_THE_IMPORT_OF_THE_SELECTED_PACKAGE')
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
@ -215,29 +199,29 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
protected function componentDetailsDisplay($object)
|
||||
{
|
||||
// set some vars
|
||||
$image = (ComponentbuilderHelper::checkString($object->image)) ? '<img alt="Joomla Component Image" src="'. JURI::root() . $object->image . '" style="float: right;">': '';
|
||||
$desc = (ComponentbuilderHelper::checkString($object->description)) ? $object->description : $object->short_description;
|
||||
$placeholder = ($object->add_placeholders == 1) ? '<span class="btn btn-small btn-success"> ' . JText::_('COM_COMPONENTBUILDER_YES') . ' </span>' : '<span class="btn btn-small btn-danger"> ' .JText::_('COM_COMPONENTBUILDER_NO') . ' </span>' ;
|
||||
$debug = ($object->debug_linenr == 1) ? '<span class="btn btn-small btn-success"> ' .JText::_('COM_COMPONENTBUILDER_YES') . '</span>' : ' <span class="btn btn-small btn-danger"> ' .JText::_('COM_COMPONENTBUILDER_NO') . ' </span>' ;
|
||||
$image = (StringHelper::check($object->image)) ? '<img alt="Joomla Component Image" src="'. JURI::root() . $object->image . '" style="float: right;">': '';
|
||||
$desc = (StringHelper::check($object->description)) ? $object->description : $object->short_description;
|
||||
$placeholder = ($object->add_placeholders == 1) ? '<span class="btn btn-small btn-success"> ' . Text::_('COM_COMPONENTBUILDER_YES') . ' </span>' : '<span class="btn btn-small btn-danger"> ' .Text::_('COM_COMPONENTBUILDER_NO') . ' </span>' ;
|
||||
$debug = ($object->debug_linenr == 1) ? '<span class="btn btn-small btn-success"> ' .Text::_('COM_COMPONENTBUILDER_YES') . '</span>' : ' <span class="btn btn-small btn-danger"> ' .Text::_('COM_COMPONENTBUILDER_NO') . ' </span>' ;
|
||||
$html = array();
|
||||
$html[] = '<h3>' . $object->name . ' (v' . $object->component_version . ')</h3>';
|
||||
$html[] = '<p>' . $desc . $image . '</p>';
|
||||
$html[] = '<ul>';
|
||||
$html[] = '<li>' . JText::_('COM_COMPONENTBUILDER_COMPANY') . ': <b>' . $object->companyname . '</b></li>';
|
||||
$html[] = '<li>' . JText::_('COM_COMPONENTBUILDER_AUTHOR') . ': <b>' . $object->author . '</b></li>';
|
||||
$html[] = '<li>' . JText::_('COM_COMPONENTBUILDER_EMAIL') . ': <b>' . $object->email . '</b></li>';
|
||||
$html[] = '<li>' . JText::_('COM_COMPONENTBUILDER_WEBSITE') . ': <b>' . $object->website . '</b></li>';
|
||||
$html[] = '<li>' . Text::_('COM_COMPONENTBUILDER_COMPANY') . ': <b>' . $object->companyname . '</b></li>';
|
||||
$html[] = '<li>' . Text::_('COM_COMPONENTBUILDER_AUTHOR') . ': <b>' . $object->author . '</b></li>';
|
||||
$html[] = '<li>' . Text::_('COM_COMPONENTBUILDER_EMAIL') . ': <b>' . $object->email . '</b></li>';
|
||||
$html[] = '<li>' . Text::_('COM_COMPONENTBUILDER_WEBSITE') . ': <b>' . $object->website . '</b></li>';
|
||||
$html[] = '</ul>';
|
||||
$html[] = '<h4>' . JText::_('COM_COMPONENTBUILDER_COMPONENT_GLOBAL_SETTINGS') . '</h4>';
|
||||
$html[] = '<h4>' . Text::_('COM_COMPONENTBUILDER_COMPONENT_GLOBAL_SETTINGS') . '</h4>';
|
||||
$html[] = '<p>';
|
||||
$html[] = JText::_('COM_COMPONENTBUILDER_ADD_CUSTOM_CODE_PLACEHOLDERS') . '<br />' . $placeholder . '<br />';
|
||||
$html[] = JText::_('COM_COMPONENTBUILDER_DEBUG_LINE_NUMBERS') . '<br />' . $debug ;
|
||||
$html[] = Text::_('COM_COMPONENTBUILDER_ADD_CUSTOM_CODE_PLACEHOLDERS') . '<br />' . $placeholder . '<br />';
|
||||
$html[] = Text::_('COM_COMPONENTBUILDER_DEBUG_LINE_NUMBERS') . '<br />' . $debug ;
|
||||
$html[] = '</p>';
|
||||
$html[] = '<h4>' . JText::_('COM_COMPONENTBUILDER_LICENSE') . '</h4>';
|
||||
$html[] = '<h4>' . Text::_('COM_COMPONENTBUILDER_LICENSE') . '</h4>';
|
||||
$html[] = '<p>' . $object->license . '</p>';
|
||||
$html[] = '<h4>' . JText::_('COM_COMPONENTBUILDER_COPYRIGHT') . '</h4>';
|
||||
$html[] = '<h4>' . Text::_('COM_COMPONENTBUILDER_COPYRIGHT') . '</h4>';
|
||||
$html[] = '<p>' . $object->copyright . '<br /><br />';
|
||||
$html[] = '<a href="index.php?option=com_componentbuilder&ref=compiler&view=joomla_components&task=joomla_component.edit&id=' . (int) $object->id . '" class="btn btn-small span12"><span class="icon-edit"></span> ' . JText::_('COM_COMPONENTBUILDER_EDIT') . ' ' .$object->system_name . '</a></p>';
|
||||
$html[] = '<a href="index.php?option=com_componentbuilder&ref=compiler&view=joomla_components&task=joomla_component.edit&id=' . (int) $object->id . '" class="btn btn-small span12"><span class="icon-edit"></span> ' . Text::_('COM_COMPONENTBUILDER_EDIT') . ' ' .$object->system_name . '</a></p>';
|
||||
// now return the diplay
|
||||
return implode("\n", $html);
|
||||
}
|
||||
@ -247,7 +231,7 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
**/
|
||||
public function getCronPath($type)
|
||||
{
|
||||
$result = array('error' => '<span style="color: red;">' . JText::_('COM_COMPONENTBUILDER_NO_CRONJOB_PATH_FOUND_SINCE_INCORRECT_TYPE_REQUESTED') . '</span>');
|
||||
$result = array('error' => '<span style="color: red;">' . Text::_('COM_COMPONENTBUILDER_NO_CRONJOB_PATH_FOUND_SINCE_INCORRECT_TYPE_REQUESTED') . '</span>');
|
||||
if ('backup' === $type)
|
||||
{
|
||||
$result['error'] = '<span style="color: red;">' . JText::sprintf('COM_COMPONENTBUILDER_NO_CRONJOB_PATH_FOUND_FOR_S', $type) . '</span>';
|
||||
@ -333,7 +317,7 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
return ['error' => $message];
|
||||
}
|
||||
|
||||
return ['error' => JText::_('COM_COMPONENTBUILDER_THE_WIKI_CAN_ONLY_BE_LOADED_WHEN_YOUR_JCB_SYSTEM_HAS_INTERNET_CONNECTION')];
|
||||
return ['error' => Text::_('COM_COMPONENTBUILDER_THE_WIKI_CAN_ONLY_BE_LOADED_WHEN_YOUR_JCB_SYSTEM_HAS_INTERNET_CONNECTION')];
|
||||
}
|
||||
|
||||
public function getVersion($version = null)
|
||||
@ -377,7 +361,7 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
// now check if this version is out dated
|
||||
if ($current_version === $local_version)
|
||||
{
|
||||
return ['notice' => '<small><span style="color:green;"><span class="icon-shield"></span>' . JText::_('COM_COMPONENTBUILDER_UP_TO_DATE') . '</span></small>'];
|
||||
return ['notice' => '<small><span style="color:green;"><span class="icon-shield"></span>' . Text::_('COM_COMPONENTBUILDER_UP_TO_DATE') . '</span></small>'];
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -388,15 +372,15 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
($local_array[0] == $current_array[0] && $local_array[1] > $current_array[1]) ||
|
||||
($local_array[0] == $current_array[0] && $local_array[1] == $current_array[1] && $local_array[2] > $current_array[2]))
|
||||
{
|
||||
return ['notice' => '<small><span style="color:#F7B033;"><span class="icon-wrench"></span>' . JText::_('COM_COMPONENTBUILDER_BETA_RELEASE') . '</span></small>'];
|
||||
return ['notice' => '<small><span style="color:#F7B033;"><span class="icon-wrench"></span>' . Text::_('COM_COMPONENTBUILDER_BETA_RELEASE') . '</span></small>'];
|
||||
}
|
||||
else
|
||||
{
|
||||
// download link of the latest version
|
||||
$download = "https://git.vdm.dev/api/v1/repos/joomla/pkg-component-builder/archive/" . $tags[0]->name . ".zip?access_token=" . $token;
|
||||
|
||||
return ['notice' => '<small><span style="color:red;"><span class="icon-warning-circle"></span>' . JText::_('COM_COMPONENTBUILDER_OUT_OF_DATE') . '!</span> <a style="color:green;" href="' .
|
||||
$download . '" title="' . JText::_('COM_COMPONENTBUILDER_YOU_CAN_DIRECTLY_DOWNLOAD_THE_LATEST_UPDATE_OR_USE_THE_JOOMLA_UPDATE_AREA') . '">' . JText::_('COM_COMPONENTBUILDER_DOWNLOAD_UPDATE') . '!</a></small>'];
|
||||
return ['notice' => '<small><span style="color:red;"><span class="icon-warning-circle"></span>' . Text::_('COM_COMPONENTBUILDER_OUT_OF_DATE') . '!</span> <a style="color:green;" href="' .
|
||||
$download . '" title="' . Text::_('COM_COMPONENTBUILDER_YOU_CAN_DIRECTLY_DOWNLOAD_THE_LATEST_UPDATE_OR_USE_THE_JOOMLA_UPDATE_AREA') . '">' . Text::_('COM_COMPONENTBUILDER_DOWNLOAD_UPDATE') . '!</a></small>'];
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -416,11 +400,12 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
|
||||
if ($message)
|
||||
{
|
||||
return ['error' => $a . $message . $a_ . JText::_('COM_COMPONENTBUILDER_GET_TOKEN') . $_a];
|
||||
return ['error' => $a . $message . $a_ . Text::_('COM_COMPONENTBUILDER_GET_TOKEN') . $_a];
|
||||
}
|
||||
|
||||
return ['error' => $a . JText::_('COM_COMPONENTBUILDER_GET_TOKEN_FROM_VDM_TO_GET_UPDATE_NOTICE_AND_ADD_IT_TO_YOUR_GLOBAL_OPTIONS') . $a_ . JText::_('COM_COMPONENTBUILDER_GET_TOKEN') . $_a];
|
||||
return ['error' => $a . Text::_('COM_COMPONENTBUILDER_GET_TOKEN_FROM_VDM_TO_GET_UPDATE_NOTICE_AND_ADD_IT_TO_YOUR_GLOBAL_OPTIONS') . $a_ . Text::_('COM_COMPONENTBUILDER_GET_TOKEN') . $_a];
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Used in joomla_module
|
||||
@ -3610,6 +3595,7 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
* Search for value in a table
|
||||
*
|
||||
* @param string $tableName The main table to search
|
||||
* @param int $typeSearch The type of search being done
|
||||
* @param string $searchValue The value to search for
|
||||
* @param int $matchCase The switch to control match case
|
||||
* @param int $wholeWord The switch to control whole word
|
||||
@ -3619,26 +3605,43 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
* @return array|null
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public function searchTable(string $tableName, string $searchValue,
|
||||
public function doSearch(string $tableName, int $typeSearch, string $searchValue,
|
||||
int $matchCase, int $wholeWord, int $regexSearch, int $componentId): ?array
|
||||
{
|
||||
// check if this is a valid table
|
||||
if (SearchFactory::_('Table')->exist($tableName))
|
||||
{
|
||||
// load the configurations
|
||||
SearchFactory::_('Config')->table_name = $tableName;
|
||||
SearchFactory::_('Config')->search_value = $searchValue;
|
||||
SearchFactory::_('Config')->match_case = $matchCase;
|
||||
SearchFactory::_('Config')->whole_word = $wholeWord;
|
||||
SearchFactory::_('Config')->regex_search = $regexSearch;
|
||||
SearchFactory::_('Config')->component_id = $componentId;
|
||||
|
||||
if (($items = SearchFactory::_('Agent')->find()) !== null)
|
||||
try
|
||||
{
|
||||
return ['success' => JText::sprintf('COM_COMPONENTBUILDER_WE_FOUND_SOME_INSTANCES_IN_S', $tableName), 'items' => $items];
|
||||
}
|
||||
// load the configurations
|
||||
SearchFactory::_('Config')->table_name = $tableName;
|
||||
SearchFactory::_('Config')->type_search = $typeSearch;
|
||||
SearchFactory::_('Config')->search_value = $searchValue;
|
||||
SearchFactory::_('Config')->match_case = $matchCase;
|
||||
SearchFactory::_('Config')->whole_word = $wholeWord;
|
||||
SearchFactory::_('Config')->regex_search = $regexSearch;
|
||||
SearchFactory::_('Config')->component_id = $componentId;
|
||||
|
||||
return ['success' => JText::sprintf('COM_COMPONENTBUILDER_NO_INSTANCES_WHERE_FOUND_S', $tableName)];
|
||||
if (($items = SearchFactory::_('Agent')->table($tableName)) !== null)
|
||||
{
|
||||
return [
|
||||
'success' => JText::sprintf('COM_COMPONENTBUILDER_WE_FOUND_SOME_INSTANCES_IN_S', $tableName),
|
||||
'items' => $items,
|
||||
'fields_count' => SearchFactory::_('Config')->field_counter,
|
||||
'line_count' => SearchFactory::_('Config')->line_counter
|
||||
];
|
||||
}
|
||||
|
||||
return [
|
||||
'not_found' => JText::sprintf('COM_COMPONENTBUILDER_NO_INSTANCES_WHERE_FOUND_IN_S', $tableName),
|
||||
'fields_count' => SearchFactory::_('Config')->field_counter,
|
||||
'line_count' => SearchFactory::_('Config')->line_counter
|
||||
];
|
||||
}
|
||||
catch(Exception $error)
|
||||
{
|
||||
return ['error' => $error->getMessage()];
|
||||
}
|
||||
}
|
||||
|
||||
return ['error' => JText::_('COM_COMPONENTBUILDER_THERE_HAS_BEEN_AN_ERROR_PLEASE_TRY_AGAIN')];
|
||||
@ -3649,33 +3652,159 @@ class ComponentbuilderModelAjax extends ListModel
|
||||
*
|
||||
* @param string $tableName The main table to search
|
||||
* @param string $searchValue The value to search for
|
||||
* @param string|null $replaceValue The value to replace search value
|
||||
* @param int $matchCase The switch to control match case
|
||||
* @param int $wholeWord The switch to control whole word
|
||||
* @param int $regexSearch The switch to control regex search
|
||||
* @param int $componentId The option to filter by component
|
||||
* @param string|null $replaceValue The value to replace search value
|
||||
* @param int $matchCase The switch to control match case
|
||||
* @param int $wholeWord The switch to control whole word
|
||||
* @param int $regexSearch The switch to control regex search
|
||||
* @param int $componentId The option to filter by component
|
||||
*
|
||||
* @return array|null
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public function updateTable(string $tableName, string $searchValue, ?string $replaceValue = null,
|
||||
public function replaceAll(string $tableName, string $searchValue, ?string $replaceValue = null,
|
||||
int $matchCase, int $wholeWord, int $regexSearch, int $componentId): ?array
|
||||
{
|
||||
// check if this is a valid table
|
||||
if (SearchFactory('Table')->exist($tableName))
|
||||
if (SearchFactory::_('Table')->exist($tableName))
|
||||
{
|
||||
// load the configurations
|
||||
SearchFactory('Config')->table_name = $tableName;
|
||||
SearchFactory('Config')->search_value = $searchValue;
|
||||
SearchFactory('Config')->replace_value = $replaceValue;
|
||||
SearchFactory('Config')->match_case = $matchCase;
|
||||
SearchFactory('Config')->whole_word = $wholeWord;
|
||||
SearchFactory('Config')->regex_search = $regexSearch;
|
||||
SearchFactory('Config')->component_id = $componentId;
|
||||
try
|
||||
{
|
||||
// load the configurations
|
||||
SearchFactory::_('Config')->table_name = $tableName;
|
||||
SearchFactory::_('Config')->search_value = $searchValue;
|
||||
SearchFactory::_('Config')->replace_value = $replaceValue;
|
||||
SearchFactory::_('Config')->match_case = $matchCase;
|
||||
SearchFactory::_('Config')->whole_word = $wholeWord;
|
||||
SearchFactory::_('Config')->regex_search = $regexSearch;
|
||||
SearchFactory::_('Config')->component_id = $componentId;
|
||||
|
||||
SearchFactory('Agent')->replace();
|
||||
if (($number = SearchFactory::_('Agent')->replace()) !== 0)
|
||||
{
|
||||
return ['success' => JText::sprintf('COM_COMPONENTBUILDER_ALL_FOUND_INSTANCES_IN_S_WHERE_REPLACED', $tableName)];
|
||||
}
|
||||
return ['not_found' => JText::sprintf('COM_COMPONENTBUILDER_NO_INSTANCES_WHERE_FOUND_IN_S', $tableName)];
|
||||
}
|
||||
catch(Exception $error)
|
||||
{
|
||||
return ['error' => $error->getMessage()];
|
||||
}
|
||||
}
|
||||
return ['error' => JText::_('COM_COMPONENTBUILDER_THERE_HAS_BEEN_AN_ERROR_PLEASE_TRY_AGAIN')];
|
||||
}
|
||||
|
||||
return ['success' => JText::sprintf('COM_COMPONENTBUILDER_ALL_FOUND_INSTANCES_IN_S_WHERE_REPLACED', $tableName)];
|
||||
/**
|
||||
* Get a selected search value from a given table and row
|
||||
*
|
||||
* @param string $fieldName The field key
|
||||
* @param int $rowId The item ID
|
||||
* @param string $tableName The table
|
||||
* @param string $searchValue The value to search for
|
||||
* @param string|null $replaceValue The value to replace search value
|
||||
* @param int $matchCase The switch to control match case
|
||||
* @param int $wholeWord The switch to control whole word
|
||||
* @param int $regexSearch The switch to control regex search
|
||||
*
|
||||
* @return array
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public function getSearchValue(string $fieldName, int $rowId, string $tableName,
|
||||
string $searchValue, ?string $replaceValue = null, int $matchCase, int $wholeWord, int $regexSearch): array
|
||||
{
|
||||
// check if this is a valid table and field
|
||||
if ($rowId > 0 && SearchFactory::_('Table')->exist($tableName, $fieldName))
|
||||
{
|
||||
try
|
||||
{
|
||||
// load the configurations
|
||||
SearchFactory::_('Config')->table_name = $tableName;
|
||||
SearchFactory::_('Config')->type_search = 1;
|
||||
SearchFactory::_('Config')->search_value = $searchValue;
|
||||
SearchFactory::_('Config')->replace_value = $replaceValue;
|
||||
SearchFactory::_('Config')->match_case = $matchCase;
|
||||
SearchFactory::_('Config')->whole_word = $wholeWord;
|
||||
SearchFactory::_('Config')->regex_search = $regexSearch;
|
||||
|
||||
if (($value = SearchFactory::_('Agent')->getValue($rowId, $fieldName, 0, $tableName)) !== null)
|
||||
{
|
||||
// load the value
|
||||
return ['value' => $value];
|
||||
}
|
||||
}
|
||||
catch(Exception $error)
|
||||
{
|
||||
return ['error' => $error->getMessage()];
|
||||
}
|
||||
}
|
||||
return ['error' => JText::_('COM_COMPONENTBUILDER_THERE_HAS_BEEN_AN_ERROR_PLEASE_TRY_AGAIN')];
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a replaced search value from a given table and row
|
||||
*
|
||||
* @param string $fieldName The field key
|
||||
* @param int $rowId The item ID
|
||||
* @param mixed $line The line line
|
||||
* @param string $tableName The table
|
||||
* @param string $searchValue The value to search for
|
||||
* @param string|null $replaceValue The value to replace search value
|
||||
* @param int $matchCase The switch to control match case
|
||||
* @param int $wholeWord The switch to control whole word
|
||||
* @param int $regexSearch The switch to control regex search
|
||||
*
|
||||
* @return array
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public function getReplaceValue(string $fieldName, int $rowId, $line, string $tableName,
|
||||
string $searchValue, ?string $replaceValue = null, int $matchCase, int $wholeWord, int $regexSearch): array
|
||||
{
|
||||
// check if this is a valid table and field
|
||||
if ($rowId > 0 && SearchFactory::_('Table')->exist($tableName, $fieldName))
|
||||
{
|
||||
try
|
||||
{
|
||||
// load the configurations
|
||||
SearchFactory::_('Config')->table_name = $tableName;
|
||||
SearchFactory::_('Config')->type_search = 2;
|
||||
SearchFactory::_('Config')->search_value = $searchValue;
|
||||
SearchFactory::_('Config')->replace_value = $replaceValue;
|
||||
SearchFactory::_('Config')->match_case = $matchCase;
|
||||
SearchFactory::_('Config')->whole_word = $wholeWord;
|
||||
SearchFactory::_('Config')->regex_search = $regexSearch;
|
||||
|
||||
// load the value
|
||||
if (($value = SearchFactory::_('Agent')->getValue($rowId, $fieldName, $line, $tableName, true)) !== null)
|
||||
{
|
||||
return ['value' => $value];
|
||||
}
|
||||
}
|
||||
catch(Exception $error)
|
||||
{
|
||||
return ['error' => $error->getMessage()];
|
||||
}
|
||||
}
|
||||
return ['error' => JText::_('COM_COMPONENTBUILDER_THERE_HAS_BEEN_AN_ERROR_PLEASE_TRY_AGAIN')];
|
||||
}
|
||||
|
||||
/**
|
||||
* Set selected search value in a given table and row
|
||||
*
|
||||
* @param mixed $value The field value
|
||||
* @param int $rowId The item ID
|
||||
* @param string $fieldName The field key
|
||||
* @param string $tableName The table
|
||||
*
|
||||
* @return array
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public function setValue($value, int $rowId, string $fieldName, string $tableName): array
|
||||
{
|
||||
// check if this is a valid table and field
|
||||
if ($rowId > 0 && SearchFactory::_('Table')->exist($tableName, $fieldName) &&
|
||||
SearchFactory::_('Agent')->setValue($value, $rowId, $fieldName, $tableName))
|
||||
{
|
||||
return ['success' => JText::sprintf(
|
||||
'<b>%s</b> (%s:%s) was successfully updated!',
|
||||
$tableName, $rowId, $fieldName)];
|
||||
}
|
||||
return ['error' => JText::_('COM_COMPONENTBUILDER_THERE_HAS_BEEN_AN_ERROR_PLEASE_TRY_AGAIN')];
|
||||
}
|
||||
|
@ -139,69 +139,6 @@ class ComponentbuilderModelCompiler extends ListModel
|
||||
|
||||
public $compiler;
|
||||
|
||||
public function getComponents()
|
||||
{
|
||||
// Get a db connection.
|
||||
$db = JFactory::getDbo();
|
||||
// Create a new query object.
|
||||
$query = $db->getQuery(true);
|
||||
// Order it by the ordering field.
|
||||
$query->select($db->quoteName(array('id', 'system_name'),array('id', 'name')));
|
||||
$query->from($db->quoteName('#__componentbuilder_joomla_component'));
|
||||
$query->where($db->quoteName('published') . ' = 1');
|
||||
$query->order('modified DESC');
|
||||
$query->order('created DESC');
|
||||
// Reset the query using our newly populated query object.
|
||||
$db->setQuery($query);
|
||||
// return the result
|
||||
return $db->loadObjectList();
|
||||
}
|
||||
|
||||
public function getCompilerAnimations(&$errorMessage)
|
||||
{
|
||||
// convert error message to array
|
||||
$errorMessage = array();
|
||||
$searchArray = array(
|
||||
// add banners (width - height)
|
||||
'banner' => array(
|
||||
'728-90',
|
||||
'160-600'
|
||||
),
|
||||
// The build-gif by size (width - height)
|
||||
'builder-gif' => array(
|
||||
'480-540'
|
||||
)
|
||||
);
|
||||
// start search, and get
|
||||
foreach ($searchArray as $type => $sizes)
|
||||
{
|
||||
// per size
|
||||
foreach ($sizes as $size)
|
||||
{
|
||||
// get size
|
||||
if (($set_size = ComponentbuilderHelper::getDynamicContentSize($type, $size)) !== 0)
|
||||
{
|
||||
// we loop over all type size artwork
|
||||
for ($target = 1; $target <= $set_size; $target++)
|
||||
{
|
||||
if (!ComponentbuilderHelper::getDynamicContent($type, $size, false, 0, $target))
|
||||
{
|
||||
$errorMessage[] = JText::sprintf('COM_COMPONENTBUILDER_S_S_NUMBER_BSB_COULD_NOT_BE_DOWNLOADED_SUCCESSFULLY_TO_THIS_JOOMLA_INSTALL', $type, $size, $target);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// check if we had any errors
|
||||
if (ComponentbuilderHelper::checkArray($errorMessage))
|
||||
{
|
||||
// flatten the error message array
|
||||
$errorMessage = implode('<br />', $errorMessage);
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public function builder()
|
||||
{
|
||||
// run compiler
|
||||
@ -359,5 +296,91 @@ class ComponentbuilderModelCompiler extends ListModel
|
||||
$this->cleanCache('mod_menu', 1);
|
||||
|
||||
return $result;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get all components in the system
|
||||
*
|
||||
* @return array
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public function getComponents(): array
|
||||
{
|
||||
// Get a db connection.
|
||||
$db = $this->getDbo();
|
||||
|
||||
// Create a new query object.
|
||||
$query = $db->getQuery(true);
|
||||
|
||||
// Select only id and system name
|
||||
$query->select($db->quoteName(array('id', 'system_name'),array('id', 'name')));
|
||||
$query->from($db->quoteName('#__componentbuilder_joomla_component'));
|
||||
|
||||
// only the active components
|
||||
$query->where($db->quoteName('published') . ' = 1');
|
||||
|
||||
// Order it by the ordering field.
|
||||
$query->order('modified DESC');
|
||||
$query->order('created DESC');
|
||||
|
||||
// Reset the query using our newly populated query object.
|
||||
$db->setQuery($query);
|
||||
|
||||
// return the result
|
||||
return $db->loadObjectList();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get all dynamic content
|
||||
*
|
||||
* @return bool
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public function getDynamicContent(&$errorMessage): bool
|
||||
{
|
||||
// convert error message to array
|
||||
$errorMessage = [];
|
||||
$searchArray = [
|
||||
// add banners (width - height)
|
||||
'banner' => [
|
||||
'728-90',
|
||||
'160-600'
|
||||
],
|
||||
// The build-gif by size (width - height)
|
||||
'builder-gif' => [
|
||||
'480-540'
|
||||
]
|
||||
];
|
||||
// start search, and get
|
||||
foreach ($searchArray as $type => $sizes)
|
||||
{
|
||||
// per size
|
||||
foreach ($sizes as $size)
|
||||
{
|
||||
// get size
|
||||
if (($set_size = ComponentbuilderHelper::getDynamicContentSize($type, $size)) !== 0)
|
||||
{
|
||||
// we loop over all type size artwork
|
||||
for ($target = 1; $target <= $set_size; $target++)
|
||||
{
|
||||
if (!ComponentbuilderHelper::getDynamicContent($type, $size, false, 0, $target))
|
||||
{
|
||||
$errorMessage[] = JText::sprintf('COM_COMPONENTBUILDER_S_S_NUMBER_BSB_COULD_NOT_BE_DOWNLOADED_SUCCESSFULLY_TO_THIS_JOOMLA_INSTALL', $type, $size, $target);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// check if we had any errors
|
||||
if (ComponentbuilderHelper::checkArray($errorMessage))
|
||||
{
|
||||
// flatten the error message array
|
||||
$errorMessage = implode('<br />', $errorMessage);
|
||||
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -14,8 +14,8 @@ defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use Joomla\CMS\MVC\Model\ListModel;
|
||||
use Joomla\Utilities\ArrayHelper;
|
||||
use Joomla\Registry\Registry;
|
||||
use VDM\Gitea\Gitea;
|
||||
use Joomla\Registry\Registry;
|
||||
|
||||
/**
|
||||
* Componentbuilder List Model
|
||||
@ -30,13 +30,15 @@ class ComponentbuilderModelComponentbuilder extends ListModel
|
||||
$icons = array();
|
||||
// view groups array
|
||||
$viewGroups = array(
|
||||
'main' => array('png.compiler', 'png.joomla_components', 'png.joomla_modules', 'png.joomla_plugins', 'png.powers', 'png||importjcbpackages||index.php?option=com_componentbuilder&view=joomla_components&task=joomla_components.smartImport', 'png.admin_view.add', 'png.admin_views', 'png.custom_admin_view.add', 'png.custom_admin_views', 'png.site_view.add', 'png.site_views', 'png.template.add', 'png.templates', 'png.layouts', 'png.dynamic_get.add', 'png.dynamic_gets', 'png.custom_codes', 'png.placeholders', 'png.libraries', 'png.snippets', 'png.get_snippets', 'png.validation_rules', 'png.field.add', 'png.fields', 'png.fields.catid_qpo0O0oqp_com_componentbuilder_po0O0oq_field', 'png.fieldtypes', 'png.fieldtypes.catid_qpo0O0oqp_com_componentbuilder_po0O0oq_fieldtype', 'png.language_translations', 'png.servers', 'png.help_documents')
|
||||
'main' => array('png.compiler', 'png.joomla_components', 'png.joomla_modules', 'png.joomla_plugins', 'png.powers', 'png.search', 'png||importjcbpackages||index.php?option=com_componentbuilder&view=joomla_components&task=joomla_components.smartImport', 'png.admin_views', 'png.custom_admin_views', 'png.site_views', 'png.template.add', 'png.templates', 'png.layouts', 'png.dynamic_get.add', 'png.dynamic_gets', 'png.custom_codes', 'png.placeholders', 'png.libraries', 'png.snippets', 'png.get_snippets', 'png.validation_rules', 'png.field.add', 'png.fields', 'png.fields.catid_qpo0O0oqp_com_componentbuilder_po0O0oq_field', 'png.fieldtypes', 'png.fieldtypes.catid_qpo0O0oqp_com_componentbuilder_po0O0oq_fieldtype', 'png.language_translations', 'png.servers', 'png.help_documents')
|
||||
);
|
||||
// view access array
|
||||
$viewAccess = array(
|
||||
'compiler.submenu' => 'compiler.submenu',
|
||||
'compiler.dashboard_list' => 'compiler.dashboard_list',
|
||||
'search.access' => 'search.access',
|
||||
'search.submenu' => 'search.submenu',
|
||||
'search.dashboard_list' => 'search.dashboard_list',
|
||||
'get_snippets.submenu' => 'get_snippets.submenu',
|
||||
'get_snippets.dashboard_list' => 'get_snippets.dashboard_list',
|
||||
'joomla_component.create' => 'joomla_component.create',
|
||||
@ -64,17 +66,14 @@ class ComponentbuilderModelComponentbuilder extends ListModel
|
||||
'admin_view.access' => 'admin_view.access',
|
||||
'admin_views.submenu' => 'admin_view.submenu',
|
||||
'admin_views.dashboard_list' => 'admin_view.dashboard_list',
|
||||
'admin_view.dashboard_add' => 'admin_view.dashboard_add',
|
||||
'custom_admin_views.access' => 'custom_admin_view.access',
|
||||
'custom_admin_view.access' => 'custom_admin_view.access',
|
||||
'custom_admin_views.submenu' => 'custom_admin_view.submenu',
|
||||
'custom_admin_views.dashboard_list' => 'custom_admin_view.dashboard_list',
|
||||
'custom_admin_view.dashboard_add' => 'custom_admin_view.dashboard_add',
|
||||
'site_views.access' => 'site_view.access',
|
||||
'site_view.access' => 'site_view.access',
|
||||
'site_views.submenu' => 'site_view.submenu',
|
||||
'site_views.dashboard_list' => 'site_view.dashboard_list',
|
||||
'site_view.dashboard_add' => 'site_view.dashboard_add',
|
||||
'templates.access' => 'template.access',
|
||||
'template.access' => 'template.access',
|
||||
'templates.submenu' => 'template.submenu',
|
||||
|
@ -153,6 +153,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_ADMIN_CUSTOM_TABS_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_ADMIN_CUSTOM_TABS_NAME_MESSAGE"
|
||||
|
@ -608,6 +608,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_ADMIN_VIEW_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_ADMIN_VIEW_NAME_MESSAGE"
|
||||
@ -1786,6 +1788,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_ADMIN_VIEW_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_ADMIN_VIEW_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_CLASS_EXTENDS_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_CLASS_EXTENDS_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_CLASS_METHOD_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_CLASS_METHOD_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_CLASS_PROPERTY_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_CLASS_PROPERTY_NAME_MESSAGE"
|
||||
|
@ -137,6 +137,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_COMPONENT_CUSTOM_ADMIN_MENUS_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_COMPONENT_CUSTOM_ADMIN_MENUS_NAME_MESSAGE"
|
||||
|
@ -138,6 +138,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_COMPONENT_DASHBOARD_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_COMPONENT_DASHBOARD_NAME_MESSAGE"
|
||||
|
@ -116,6 +116,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEW_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEW_NAME_MESSAGE"
|
||||
@ -1118,6 +1120,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEW_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_CUSTOM_ADMIN_VIEW_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_DYNAMIC_GET_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_DYNAMIC_GET_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_FIELD_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_FIELD_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_FIELDTYPE_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_FIELDTYPE_NAME_MESSAGE"
|
||||
@ -322,6 +324,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_FIELDTYPE_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_FIELDTYPE_NAME_MESSAGE"
|
||||
|
@ -1217,6 +1217,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_JOOMLA_COMPONENT_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_JOOMLA_COMPONENT_NAME_MESSAGE"
|
||||
|
@ -890,6 +890,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_JOOMLA_MODULE_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_JOOMLA_MODULE_NAME_MESSAGE"
|
||||
|
@ -857,6 +857,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_JOOMLA_PLUGIN_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_JOOMLA_PLUGIN_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_JOOMLA_PLUGIN_GROUP_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_JOOMLA_PLUGIN_GROUP_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_LANGUAGE_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_LANGUAGE_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_LAYOUT_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_LAYOUT_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_LIBRARY_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_LIBRARY_NAME_MESSAGE"
|
||||
|
@ -186,22 +186,6 @@
|
||||
</field>
|
||||
<!-- Load_powers_note Field. Type: Note. A None Database Field. (joomla) -->
|
||||
<field type="note" name="load_powers_note" label="COM_COMPONENTBUILDER_POWER_LOAD_POWERS_NOTE_LABEL" description="COM_COMPONENTBUILDER_POWER_LOAD_POWERS_NOTE_DESCRIPTION" heading="h4" class="alert alert-info load_powers_note" />
|
||||
<!-- Main_class_code Field. Type: Editor. (joomla) -->
|
||||
<field
|
||||
type="editor"
|
||||
name="main_class_code"
|
||||
label="COM_COMPONENTBUILDER_POWER_MAIN_CLASS_CODE_LABEL"
|
||||
description="COM_COMPONENTBUILDER_POWER_MAIN_CLASS_CODE_DESCRIPTION"
|
||||
width="100%"
|
||||
height="800px"
|
||||
cols="40"
|
||||
rows="300"
|
||||
buttons="no"
|
||||
syntax="php"
|
||||
editor="codemirror|none"
|
||||
filter="raw"
|
||||
validate="code"
|
||||
/>
|
||||
<!-- Description Field. Type: Textarea. (joomla) -->
|
||||
<field
|
||||
type="textarea"
|
||||
@ -227,6 +211,63 @@
|
||||
validate="code"
|
||||
showon="add_licensing_template:2"
|
||||
/>
|
||||
<!-- Composer Field. Type: Subform. (joomla) -->
|
||||
<field
|
||||
type="subform"
|
||||
name="composer"
|
||||
label="COM_COMPONENTBUILDER_POWER_COMPOSER_LABEL"
|
||||
layout="joomla.form.field.subform.repeatable-table"
|
||||
multiple="true"
|
||||
buttons="add,remove,move"
|
||||
icon="list"
|
||||
max="1"
|
||||
min="0">
|
||||
<form hidden="true" name="list_composer_modal" repeat="true">
|
||||
<!-- Access_point Field. Type: Text. (joomla) -->
|
||||
<field
|
||||
type="text"
|
||||
name="access_point"
|
||||
label="COM_COMPONENTBUILDER_POWER_ACCESS_POINT_LABEL"
|
||||
size="70"
|
||||
maxlength="300"
|
||||
description="COM_COMPONENTBUILDER_POWER_ACCESS_POINT_DESCRIPTION"
|
||||
class="text_area"
|
||||
required="true"
|
||||
filter="PATH"
|
||||
message="COM_COMPONENTBUILDER_POWER_ACCESS_POINT_MESSAGE"
|
||||
hint="COM_COMPONENTBUILDER_POWER_ACCESS_POINT_HINT"
|
||||
/>
|
||||
<!-- Namespace Field. Type: Subform. (joomla) -->
|
||||
<field
|
||||
type="subform"
|
||||
name="namespace"
|
||||
label="COM_COMPONENTBUILDER_POWER_NAMESPACE_LABEL"
|
||||
layout="joomla.form.field.subform.repeatable-table"
|
||||
multiple="true"
|
||||
buttons="add,remove,move"
|
||||
icon="list"
|
||||
max="30"
|
||||
min="1"
|
||||
nested_depth="1">
|
||||
<form hidden="true" name="list_namespace_modal" repeat="true">
|
||||
<!-- Use Field. Type: Text. (joomla) -->
|
||||
<field
|
||||
type="text"
|
||||
name="use"
|
||||
label="COM_COMPONENTBUILDER_POWER_USE_LABEL"
|
||||
size="70"
|
||||
maxlength="300"
|
||||
class="text_area"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_POWER_USE_MESSAGE"
|
||||
hint="COM_COMPONENTBUILDER_POWER_USE_HINT"
|
||||
autocomplete="on"
|
||||
/>
|
||||
</form>
|
||||
</field>
|
||||
</form>
|
||||
</field>
|
||||
<!-- Property_selection Field. Type: Subform. (joomla) -->
|
||||
<field
|
||||
type="subform"
|
||||
@ -372,21 +413,8 @@
|
||||
required="false"
|
||||
validate="code"
|
||||
/>
|
||||
<!-- Add_licensing_template Field. Type: Radio. (joomla) -->
|
||||
<field
|
||||
type="radio"
|
||||
name="add_licensing_template"
|
||||
label="COM_COMPONENTBUILDER_POWER_ADD_LICENSING_TEMPLATE_LABEL"
|
||||
description="COM_COMPONENTBUILDER_POWER_ADD_LICENSING_TEMPLATE_DESCRIPTION"
|
||||
class="btn-group btn-group-yesno"
|
||||
default="1"
|
||||
required="true">
|
||||
<!-- Option Set. -->
|
||||
<option value="1">
|
||||
COM_COMPONENTBUILDER_POWER_USE_GLOBAL</option>
|
||||
<option value="2">
|
||||
COM_COMPONENTBUILDER_POWER_OVERRIDE</option>
|
||||
</field>
|
||||
<!-- Autoload_composer_note Field. Type: Note. A None Database Field. (joomla) -->
|
||||
<field type="note" name="autoload_composer_note" label="COM_COMPONENTBUILDER_POWER_AUTOLOAD_COMPOSER_NOTE_LABEL" description="COM_COMPONENTBUILDER_POWER_AUTOLOAD_COMPOSER_NOTE_DESCRIPTION" heading="h4" class="alert alert-info autoload_composer_note" />
|
||||
<!-- Use_selection Field. Type: Subform. (joomla) -->
|
||||
<field
|
||||
type="subform"
|
||||
@ -397,9 +425,8 @@
|
||||
buttons="add,remove,move"
|
||||
description="COM_COMPONENTBUILDER_POWER_USE_SELECTION_DESCRIPTION"
|
||||
icon="list"
|
||||
max="30"
|
||||
min="0"
|
||||
showon="type!:interface">
|
||||
max="100"
|
||||
min="0">
|
||||
<form hidden="true" name="list_use_selection_modal" repeat="true">
|
||||
<!-- Use Field. Type: Namespaces. (custom) -->
|
||||
<field
|
||||
@ -425,6 +452,37 @@
|
||||
/>
|
||||
</form>
|
||||
</field>
|
||||
<!-- Add_licensing_template Field. Type: Radio. (joomla) -->
|
||||
<field
|
||||
type="radio"
|
||||
name="add_licensing_template"
|
||||
label="COM_COMPONENTBUILDER_POWER_ADD_LICENSING_TEMPLATE_LABEL"
|
||||
description="COM_COMPONENTBUILDER_POWER_ADD_LICENSING_TEMPLATE_DESCRIPTION"
|
||||
class="btn-group btn-group-yesno"
|
||||
default="1"
|
||||
required="true">
|
||||
<!-- Option Set. -->
|
||||
<option value="1">
|
||||
COM_COMPONENTBUILDER_POWER_USE_GLOBAL</option>
|
||||
<option value="2">
|
||||
COM_COMPONENTBUILDER_POWER_OVERRIDE</option>
|
||||
</field>
|
||||
<!-- Main_class_code Field. Type: Editor. (joomla) -->
|
||||
<field
|
||||
type="editor"
|
||||
name="main_class_code"
|
||||
label="COM_COMPONENTBUILDER_POWER_MAIN_CLASS_CODE_LABEL"
|
||||
description="COM_COMPONENTBUILDER_POWER_MAIN_CLASS_CODE_DESCRIPTION"
|
||||
width="100%"
|
||||
height="800px"
|
||||
cols="40"
|
||||
rows="300"
|
||||
buttons="no"
|
||||
syntax="php"
|
||||
editor="codemirror|none"
|
||||
filter="raw"
|
||||
validate="code"
|
||||
/>
|
||||
<!-- Guid Field. Type: Text. (joomla) -->
|
||||
<field
|
||||
type="text"
|
||||
@ -448,6 +506,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_POWER_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_POWER_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_SERVER_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_SERVER_NAME_MESSAGE"
|
||||
|
@ -116,6 +116,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_SITE_VIEW_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_SITE_VIEW_NAME_MESSAGE"
|
||||
@ -1137,6 +1139,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_SITE_VIEW_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_SITE_VIEW_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_SNIPPET_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_SNIPPET_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_SNIPPET_TYPE_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_SNIPPET_TYPE_NAME_MESSAGE"
|
||||
|
@ -102,6 +102,8 @@
|
||||
maxlength="150"
|
||||
description="COM_COMPONENTBUILDER_TEMPLATE_NAME_DESCRIPTION"
|
||||
class="text_area"
|
||||
readonly="false"
|
||||
disabled="false"
|
||||
required="true"
|
||||
filter="STRING"
|
||||
message="COM_COMPONENTBUILDER_TEMPLATE_NAME_MESSAGE"
|
||||
|
@ -18,7 +18,7 @@ use Joomla\CMS\Filesystem\Folder;
|
||||
use Joomla\Utilities\ArrayHelper;
|
||||
use PhpOffice\PhpSpreadsheet\IOFactory;
|
||||
|
||||
/**
|
||||
/***
|
||||
* Componentbuilder Import Base Database Model
|
||||
*/
|
||||
class ComponentbuilderModelImport extends BaseDatabaseModel
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -64,6 +64,12 @@ class ComponentbuilderModelPower extends AdminModel
|
||||
'add_licensing_template',
|
||||
'licensing_template'
|
||||
)
|
||||
),
|
||||
'composer' => array(
|
||||
'fullwidth' => array(
|
||||
'autoload_composer_note',
|
||||
'composer'
|
||||
)
|
||||
)
|
||||
);
|
||||
|
||||
@ -178,12 +184,6 @@ class ComponentbuilderModelPower extends AdminModel
|
||||
$item->metadata = $registry->toArray();
|
||||
}
|
||||
|
||||
if (!empty($item->main_class_code))
|
||||
{
|
||||
// base64 Decode main_class_code.
|
||||
$item->main_class_code = base64_decode($item->main_class_code);
|
||||
}
|
||||
|
||||
if (!empty($item->licensing_template))
|
||||
{
|
||||
// base64 Decode licensing_template.
|
||||
@ -196,6 +196,12 @@ class ComponentbuilderModelPower extends AdminModel
|
||||
$item->head = base64_decode($item->head);
|
||||
}
|
||||
|
||||
if (!empty($item->main_class_code))
|
||||
{
|
||||
// base64 Decode main_class_code.
|
||||
$item->main_class_code = base64_decode($item->main_class_code);
|
||||
}
|
||||
|
||||
if (!empty($item->load_selection))
|
||||
{
|
||||
// Convert the load_selection field to an array.
|
||||
@ -204,6 +210,14 @@ class ComponentbuilderModelPower extends AdminModel
|
||||
$item->load_selection = $load_selection->toArray();
|
||||
}
|
||||
|
||||
if (!empty($item->composer))
|
||||
{
|
||||
// Convert the composer field to an array.
|
||||
$composer = new Registry;
|
||||
$composer->loadString($item->composer);
|
||||
$item->composer = $composer->toArray();
|
||||
}
|
||||
|
||||
if (!empty($item->property_selection))
|
||||
{
|
||||
// Convert the property_selection field to an array.
|
||||
@ -1050,6 +1064,19 @@ class ComponentbuilderModelPower extends AdminModel
|
||||
$data['load_selection'] = '';
|
||||
}
|
||||
|
||||
// Set the composer items to data.
|
||||
if (isset($data['composer']) && is_array($data['composer']))
|
||||
{
|
||||
$composer = new JRegistry;
|
||||
$composer->loadArray($data['composer']);
|
||||
$data['composer'] = (string) $composer;
|
||||
}
|
||||
elseif (!isset($data['composer']))
|
||||
{
|
||||
// Set the empty composer to data
|
||||
$data['composer'] = '';
|
||||
}
|
||||
|
||||
// Set the property_selection items to data.
|
||||
if (isset($data['property_selection']) && is_array($data['property_selection']))
|
||||
{
|
||||
@ -1102,12 +1129,6 @@ class ComponentbuilderModelPower extends AdminModel
|
||||
$data['use_selection'] = '';
|
||||
}
|
||||
|
||||
// Set the main_class_code string to base64 string.
|
||||
if (isset($data['main_class_code']))
|
||||
{
|
||||
$data['main_class_code'] = base64_encode($data['main_class_code']);
|
||||
}
|
||||
|
||||
// Set the licensing_template string to base64 string.
|
||||
if (isset($data['licensing_template']))
|
||||
{
|
||||
@ -1119,6 +1140,12 @@ class ComponentbuilderModelPower extends AdminModel
|
||||
{
|
||||
$data['head'] = base64_encode($data['head']);
|
||||
}
|
||||
|
||||
// Set the main_class_code string to base64 string.
|
||||
if (isset($data['main_class_code']))
|
||||
{
|
||||
$data['main_class_code'] = base64_encode($data['main_class_code']);
|
||||
}
|
||||
|
||||
// Set the Params Items to data
|
||||
if (isset($data['params']) && is_array($data['params']))
|
||||
|
@ -271,7 +271,7 @@ class ComponentbuilderModelPowers extends ListModel
|
||||
else
|
||||
{
|
||||
$search = $db->quote('%' . $db->escape($search) . '%');
|
||||
$query->where('(a.system_name LIKE '.$search.' OR a.type LIKE '.$search.' OR a.description LIKE '.$search.' OR a.extends_custom LIKE '.$search.' OR a.extends LIKE '.$search.' OR a.name LIKE '.$search.')');
|
||||
$query->where('(a.system_name LIKE '.$search.' OR a.type LIKE '.$search.' OR a.description LIKE '.$search.' OR a.extends_custom LIKE '.$search.' OR a.extends LIKE '.$search.' OR a.guid LIKE '.$search.' OR a.name LIKE '.$search.')');
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -114,8 +114,8 @@ class ComponentbuilderModelSearch extends ItemModel
|
||||
$query = $db->getQuery(true);
|
||||
|
||||
// Get data
|
||||
// load the tables and components (soon)
|
||||
$data = ['tables' => SearchFactory::_('Table')->tables(), 'components' => null];
|
||||
// load the tables and components
|
||||
$data = ['tables' => SearchFactory::_('Table')->tables(), 'components' => $this->getComponents()];
|
||||
|
||||
|
||||
if (empty($data))
|
||||
@ -148,6 +148,51 @@ class ComponentbuilderModelSearch extends ItemModel
|
||||
return $this->_item[$pk];
|
||||
}
|
||||
|
||||
/**
|
||||
* Custom Method
|
||||
*
|
||||
* @return mixed item data object on success, false on failure.
|
||||
*
|
||||
*/
|
||||
public function getUrlValues()
|
||||
{
|
||||
|
||||
if (!isset($this->initSet) || !$this->initSet)
|
||||
{
|
||||
$this->user = JFactory::getUser();
|
||||
$this->userId = $this->user->get('id');
|
||||
$this->guest = $this->user->get('guest');
|
||||
$this->groups = $this->user->get('groups');
|
||||
$this->authorisedGroups = $this->user->getAuthorisedGroups();
|
||||
$this->levels = $this->user->getAuthorisedViewLevels();
|
||||
$this->initSet = true;
|
||||
}
|
||||
// Get a db connection.
|
||||
$db = JFactory::getDbo();
|
||||
|
||||
// Create a new query object.
|
||||
$query = $db->getQuery(true);
|
||||
|
||||
// Get data
|
||||
$data = [
|
||||
'type_search' => SearchFactory::_('Config')->get('type_search', 1),
|
||||
'search_value' => SearchFactory::_('Config')->get('search_value', ''),
|
||||
'replace_value' => SearchFactory::_('Config')->get('replace_value', ''),
|
||||
'match_case' => SearchFactory::_('Config')->get('match_case', 0),
|
||||
'whole_word' => SearchFactory::_('Config')->get('whole_word', 0),
|
||||
'regex_search' => SearchFactory::_('Config')->get('regex_search', 0),
|
||||
'table_name' => SearchFactory::_('Config')->get('table_name', -1)
|
||||
];
|
||||
|
||||
if (empty($data))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
// return data object.
|
||||
return $data;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the uikit needed components
|
||||
*
|
||||
@ -162,4 +207,38 @@ class ComponentbuilderModelSearch extends ItemModel
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get all components in the system
|
||||
*
|
||||
* @return array
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public function getComponents(): array
|
||||
{
|
||||
// Get a db connection.
|
||||
$db = $this->getDbo();
|
||||
|
||||
// Create a new query object.
|
||||
$query = $db->getQuery(true);
|
||||
|
||||
// Select only id and system name
|
||||
$query->select($db->quoteName(array('id', 'system_name'),array('id', 'name')));
|
||||
$query->from($db->quoteName('#__componentbuilder_joomla_component'));
|
||||
|
||||
// only the active components
|
||||
$query->where($db->quoteName('published') . ' = 1');
|
||||
|
||||
// Order it by the ordering field.
|
||||
$query->order('modified DESC');
|
||||
$query->order('created DESC');
|
||||
|
||||
// Reset the query using our newly populated query object.
|
||||
$db->setQuery($query);
|
||||
|
||||
// return the result
|
||||
return $db->loadObjectList();
|
||||
}
|
||||
|
||||
}
|
||||
|
File diff suppressed because one or more lines are too long
1
admin/sql/updates/mysql/3.1.12.sql
Normal file
1
admin/sql/updates/mysql/3.1.12.sql
Normal file
@ -0,0 +1 @@
|
||||
ALTER TABLE `#__componentbuilder_power` ADD `composer` TEXT NOT NULL AFTER `add_licensing_template`;
|
@ -25,7 +25,6 @@ $selectNotice .= '<p>' . JText::_('COM_COMPONENTBUILDER_PLEASE_SELECT_A_COMPONEN
|
||||
$noticeboardOptions = array('vdm', 'pro');
|
||||
?>
|
||||
<?php if ($this->canDo->get('compiler.access')): ?>
|
||||
<form action="<?php echo JRoute::_('index.php?option=com_componentbuilder&view=compiler'); ?>" method="post" name="adminForm" id="adminForm" class="form-validate" enctype="multipart/form-data">
|
||||
|
||||
<script type="text/javascript">
|
||||
Joomla.submitbutton = function(task, key)
|
||||
@ -35,7 +34,7 @@ Joomla.submitbutton = function(task, key)
|
||||
} else {
|
||||
var component = jQuery('#component_id').val();
|
||||
var isValid = true;
|
||||
|
||||
|
||||
if(component == '' && task == 'compiler.compiler'){
|
||||
isValid = false;
|
||||
}
|
||||
@ -127,73 +126,74 @@ jQuery('<div id="compiling"></div>')
|
||||
<div id="j-main-container">
|
||||
<?php endif; ?>
|
||||
<?php if (ComponentbuilderHelper::checkString($this->SuccessMessage)): ?>
|
||||
<div class="alert alert-success">
|
||||
<button type="button" class="close" data-dismiss="alert">×</button>
|
||||
<?= $this->SuccessMessage; ?>
|
||||
</div>
|
||||
<div class="alert alert-success">
|
||||
<button type="button" class="close" data-dismiss="alert">×</button>
|
||||
<?php echo $this->SuccessMessage; ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<div id="form">
|
||||
<div class="span4">
|
||||
<h3><?= JText::_('COM_COMPONENTBUILDER_READY_TO_COMPILE_A_COMPONENT') ?></h3>
|
||||
<div id="compilerForm">
|
||||
<div>
|
||||
<span class="notice" style="display:none; color:red;"><?= JText::_('COM_COMPONENTBUILDER_YOU_MUST_SELECT_A_COMPONENT') ?></span><br />
|
||||
<?php if ($this->form): ?>
|
||||
<?php foreach ($this->form as $field): ?>
|
||||
<div class="control-group">
|
||||
<div class="control-label"><?= $field->label ?></div>
|
||||
<div class="controls"><?= $field->input ?></div>
|
||||
<form action="<?php echo JRoute::_('index.php?option=com_componentbuilder&view=compiler'); ?>"
|
||||
method="post" name="adminForm" id="adminForm" class="form-validate" enctype="multipart/form-data">
|
||||
<div id="form" >
|
||||
<div class="span4">
|
||||
<h3><?php echo JText::_('COM_COMPONENTBUILDER_READY_TO_COMPILE_A_COMPONENT'); ?></h3>
|
||||
<div id="compilerForm">
|
||||
<div>
|
||||
<span class="notice" style="display:none; color:red;"><?php echo JText::_('COM_COMPONENTBUILDER_YOU_MUST_SELECT_A_COMPONENT'); ?></span><br />
|
||||
<?php if ($this->form): ?>
|
||||
<?php echo $this->form->renderFieldset('builder'); ?>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<?php endforeach; ?>
|
||||
<?php endif; ?>
|
||||
<br />
|
||||
<div class="clearfix"></div>
|
||||
<button class="btn btn-small btn-success" onclick="Joomla.submitbutton('compiler.compiler')"><span class="icon-cog icon-white"></span>
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_COMPILE_COMPONENT'); ?>
|
||||
</button>
|
||||
<input type="hidden" name="install_item_id" value="0">
|
||||
<input type="hidden" name="version" value="3" />
|
||||
</div>
|
||||
<br />
|
||||
<div class="clearfix"></div>
|
||||
<button class="btn btn-small btn-success" onclick="Joomla.submitbutton('compiler.compiler')"><span class="icon-cog icon-white"></span>
|
||||
<?= JText::_('COM_COMPONENTBUILDER_COMPILE_COMPONENT') ?>
|
||||
</button>
|
||||
<input type="hidden" name="install_item_id" value="0">
|
||||
<input type="hidden" name="version" value="3" />
|
||||
</div>
|
||||
<div class="span7">
|
||||
<div id="advance-details"><?php echo $this->form->renderFieldset('advanced'); ?></div>
|
||||
<div id="component-details"><?php echo $selectNotice; ?></div>
|
||||
<?php echo JLayoutHelper::render('jcbnoticeboardtabs', array('id' => 'noticeboard' , 'active' => $noticeboardOptions[array_rand($noticeboardOptions)])); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="span7">
|
||||
<div id="component-details"><?= $selectNotice ?></div>
|
||||
<?= JLayoutHelper::render('jcbnoticeboardtabs', array('id' => 'noticeboard' , 'active' => $noticeboardOptions[array_rand($noticeboardOptions)])) ?>
|
||||
</div>
|
||||
</div>
|
||||
<div id="get-compiler-animations" style="display:none;">
|
||||
<h1><?= JText::_('COM_COMPONENTBUILDER_PLEASE_WAIT') ?></h1>
|
||||
<h4><?= JText::_('COM_COMPONENTBUILDER_WHILE_WE_DOWNLOAD_ALL_TWENTY_SIX_COMPILER_GIF_ANIMATIONS_RANDOMLY_USED_IN_THE_COMPILER_GUI_DURING_COMPILATION') ?> <span class="loading-dots">.</span></h4>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
<div id="clear" style="display:none;">
|
||||
<h1><?= JText::_('COM_COMPONENTBUILDER_PLEASE_WAIT') ?></h1>
|
||||
<h4><?= JText::_('COM_COMPONENTBUILDER_REMOVING_ALL_ZIP_PACKAGES_FROM_THE_TEMPORARY_FOLDER_OF_THE_JOOMLA_INSTALL') ?> <span class="loading-dots">.</span></h4>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
<div id="compiler" style="display:none;">
|
||||
<div id="compiler-spinner" class="span4" style="display:none;">
|
||||
<h3><?= JText::sprintf('COM_COMPONENTBUILDER_S_PLEASE_WAIT', $this->user->name) ?></h3>
|
||||
<p style="font-size: smaller;"><?= JText::_('COM_COMPONENTBUILDER_THIS_MAY_TAKE_A_WHILE_DEPENDING_ON_THE_SIZE_OF_YOUR_PROJECT') ?></p>
|
||||
<p><b><span class="component-name"><?= JText::_('COM_COMPONENTBUILDER_THE_COMPONENT') ?></span></b> <?= JText::_('COM_COMPONENTBUILDER_IS_BEING_COMPILED') ?> <span class="loading-dots">.</span></p>
|
||||
<div style="text-align: center;"><?= ComponentbuilderHelper::getDynamicContent('builder-gif', $this->builder_gif_size) ?></div>
|
||||
<div id="get-compiler-animations" style="display:none;">
|
||||
<h1><?php echo JText::_('COM_COMPONENTBUILDER_PLEASE_WAIT'); ?></h1>
|
||||
<h4><?php echo JText::_('COM_COMPONENTBUILDER_WHILE_WE_DOWNLOAD_ALL_TWENTY_SIX_COMPILER_GIF_ANIMATIONS_RANDOMLY_USED_IN_THE_COMPILER_GUI_DURING_COMPILATION'); ?> <span class="loading-dots">.</span></h4>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
<div id="compiler-notice" class="span7" style="display:none;">
|
||||
<?= JLayoutHelper::render('jcbnoticeboard' . $noticeboardOptions[array_rand($noticeboardOptions)], null) ?>
|
||||
<div><?= ComponentbuilderHelper::getDynamicContent('banner', '728-90') ?></div>
|
||||
<div id="clear" style="display:none;">
|
||||
<h1><?php echo JText::_('COM_COMPONENTBUILDER_PLEASE_WAIT'); ?></h1>
|
||||
<h4><?php echo JText::_('COM_COMPONENTBUILDER_REMOVING_ALL_ZIP_PACKAGES_FROM_THE_TEMPORARY_FOLDER_OF_THE_JOOMLA_INSTALL'); ?> <span class="loading-dots">.</span></h4>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="compiler" style="display:none;">
|
||||
<div id="compiler-spinner" class="span4" style="display:none;">
|
||||
<h3><?php echo JText::sprintf('COM_COMPONENTBUILDER_S_PLEASE_WAIT', $this->user->name); ?></h3>
|
||||
<p style="font-size: smaller;"><?php echo JText::_('COM_COMPONENTBUILDER_THIS_MAY_TAKE_A_WHILE_DEPENDING_ON_THE_SIZE_OF_YOUR_PROJECT'); ?></p>
|
||||
<p><b><span class="component-name"><?php echo JText::_('COM_COMPONENTBUILDER_THE_COMPONENT'); ?></span></b> <?php echo JText::_('COM_COMPONENTBUILDER_IS_BEING_COMPILED'); ?> <span class="loading-dots">.</span></p>
|
||||
<div style="text-align: center;"><?php echo ComponentbuilderHelper::getDynamicContent('builder-gif', $this->builder_gif_size); ?></div>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
<div id="compiler-notice" class="span7" style="display:none;">
|
||||
<?php echo JLayoutHelper::render('jcbnoticeboard' . $noticeboardOptions[array_rand($noticeboardOptions)], null); ?>
|
||||
<div><?php echo ComponentbuilderHelper::getDynamicContent('banner', '728-90'); ?></div>
|
||||
</div>
|
||||
</div>
|
||||
<input type="hidden" name="task" value="" />
|
||||
<?php echo JHtml::_('form.token'); ?>
|
||||
</form>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
// token
|
||||
var token = '<?= JSession::getFormToken() ?>';
|
||||
var all_is_good = '<?= JText::_('COM_COMPONENTBUILDER_ALL_IS_GOOD_THERE_IS_NO_NOTICE_AT_THIS_TIME') ?>';
|
||||
var token = '<?php echo JSession::getFormToken(); ?>';
|
||||
var all_is_good = '<?php echo JText::_('COM_COMPONENTBUILDER_ALL_IS_GOOD_THERE_IS_NO_NOTICE_AT_THIS_TIME'); ?>';
|
||||
jQuery('#compilerForm').on('change', '#component_id',function (e)
|
||||
{
|
||||
var component = jQuery('#component_id').val();
|
||||
if(component == "") {
|
||||
jQuery('#component-details').html("<?= $selectNotice ?>");
|
||||
jQuery('#component-details').html("<?php echo $selectNotice; ?>");
|
||||
jQuery("#noticeboard").show();
|
||||
jQuery('.notice').show();
|
||||
} else {
|
||||
@ -233,9 +233,6 @@ function JRouter(link) {
|
||||
return url+link;
|
||||
}
|
||||
</script>
|
||||
<input type="hidden" name="task" value="" />
|
||||
<?php echo JHtml::_('form.token'); ?>
|
||||
</form>
|
||||
<?php else: ?>
|
||||
<h1><?php echo JText::_('COM_COMPONENTBUILDER_NO_ACCESS_GRANTED'); ?></h1>
|
||||
<?php endif; ?>
|
||||
|
@ -14,6 +14,7 @@ defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use Joomla\CMS\MVC\View\HtmlView;
|
||||
use Joomla\CMS\Filesystem\File;
|
||||
use Joomla\CMS\Form\Form;
|
||||
|
||||
/**
|
||||
* Componentbuilder Html View class for the Compiler
|
||||
@ -40,11 +41,18 @@ class ComponentbuilderViewCompiler extends HtmlView
|
||||
JHtmlSidebar::setAction('index.php?option=com_componentbuilder&view=compiler');
|
||||
$this->sidebar = JHtmlSidebar::render();
|
||||
}
|
||||
// get the success message if set
|
||||
$this->SuccessMessage = $this->app->getUserState('com_componentbuilder.success_message', false);
|
||||
|
||||
// get active components
|
||||
$this->Components = $this->get('Components');
|
||||
$this->form = $this->setForm();
|
||||
|
||||
// get the needed form fields
|
||||
$this->form = $this->getDynamicForm();
|
||||
|
||||
// set the compiler artwork from global settings
|
||||
$this->builder_gif_size = $this->params->get('builder_gif_size', '480-272');
|
||||
|
||||
// only run these checks if he has access
|
||||
if ($this->canDo->get('compiler.compiler_animations'))
|
||||
{
|
||||
@ -96,121 +104,401 @@ class ComponentbuilderViewCompiler extends HtmlView
|
||||
// JLayoutHelper::render('sectionjcb', [?]); // added to ensure the layout are loaded
|
||||
// JLayoutHelper::render('repeatablejcb', [?]); // added to ensure the layout are loaded
|
||||
|
||||
public function setForm()
|
||||
/**
|
||||
* Get the dynamic build form fields needed on the page
|
||||
*
|
||||
* @return Form|null The form fields
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function getDynamicForm(): ?Form
|
||||
{
|
||||
if(ComponentbuilderHelper::checkArray($this->Components))
|
||||
{
|
||||
// start the form
|
||||
$form = array();
|
||||
$form = new Form('Builder');
|
||||
|
||||
$form->load('<form
|
||||
addrulepath="/administrator/components/com_componentbuilder/models/rules"
|
||||
addfieldpath="/administrator/components/com_componentbuilder/models/fields">
|
||||
<fieldset name="builder"></fieldset>
|
||||
<fieldset name="advanced"></fieldset>
|
||||
</form>');
|
||||
|
||||
// sales attributes
|
||||
$attributes = array(
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'backup',
|
||||
'label' => 'COM_COMPONENTBUILDER_ADD_TO_BACKUP_FOLDER_AMP_SALES_SERVER_SMALLIF_SETSMALL',
|
||||
'class' => 'btn-group btn-group-yesno',
|
||||
'description' => 'COM_COMPONENTBUILDER_SHOULD_THE_ZIPPED_PACKAGE_OF_THE_COMPONENT_BE_MOVED_TO_THE_LOCAL_BACKUP_AND_REMOTE_SALES_SERVER_THIS_IS_ONLY_APPLICABLE_IF_THIS_COMPONENT_HAS_THOSE_VALUES_SET',
|
||||
'default' => '0');
|
||||
'default' => '0'];
|
||||
// set the sales options
|
||||
$options = array(
|
||||
$options = [
|
||||
'1' => 'COM_COMPONENTBUILDER_YES',
|
||||
'0' => 'COM_COMPONENTBUILDER_NO');
|
||||
'0' => 'COM_COMPONENTBUILDER_NO'];
|
||||
|
||||
// add to form
|
||||
$form[] = ComponentbuilderHelper::getFieldObject($attributes, 0, $options);
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'builder');
|
||||
}
|
||||
|
||||
// repository attributes
|
||||
$attributes = array(
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'repository',
|
||||
'label' => 'COM_COMPONENTBUILDER_ADD_TO_REPOSITORY_FOLDER',
|
||||
'class' => 'btn-group btn-group-yesno',
|
||||
'description' => 'COM_COMPONENTBUILDER_SHOULD_THE_COMPONENT_BE_MOVED_TO_YOUR_LOCAL_REPOSITORY_FOLDER',
|
||||
'default' => '1');
|
||||
'default' => '1'];
|
||||
// start the repository options
|
||||
$options = array(
|
||||
$options = [
|
||||
'1' => 'COM_COMPONENTBUILDER_YES',
|
||||
'0' => 'COM_COMPONENTBUILDER_NO');
|
||||
'0' => 'COM_COMPONENTBUILDER_NO'];
|
||||
|
||||
// add to form
|
||||
$form[] = ComponentbuilderHelper::getFieldObject($attributes, 1, $options);
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'builder');
|
||||
}
|
||||
|
||||
// placeholders attributes
|
||||
$attributes = array(
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'add_placeholders',
|
||||
'label' => 'COM_COMPONENTBUILDER_ADD_CUSTOM_CODE_PLACEHOLDERS',
|
||||
'class' => 'btn-group btn-group-yesno',
|
||||
'description' => 'COM_COMPONENTBUILDER_SHOULD_JCB_INSERT_THE_CUSTOM_CODE_PLACEHOLDERS_THIS_IS_ONLY_APPLICABLE_IF_THIS_COMPONENT_HAS_CUSTOM_CODE',
|
||||
'default' => '2');
|
||||
'default' => '2'];
|
||||
// start the placeholders options
|
||||
$options = array(
|
||||
$options = [
|
||||
'2' => 'COM_COMPONENTBUILDER_GLOBAL',
|
||||
'1' => 'COM_COMPONENTBUILDER_YES',
|
||||
'0' => 'COM_COMPONENTBUILDER_NO');
|
||||
'0' => 'COM_COMPONENTBUILDER_NO'];
|
||||
|
||||
// add to form
|
||||
$form[] = ComponentbuilderHelper::getFieldObject($attributes, 2, $options);
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'builder');
|
||||
}
|
||||
|
||||
// debuglinenr attributes
|
||||
$attributes = array(
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'debug_line_nr',
|
||||
'label' => 'COM_COMPONENTBUILDER_DEBUG_LINE_NUMBERS',
|
||||
'class' => 'btn-group btn-group-yesno',
|
||||
'description' => 'COM_COMPONENTBUILDER_ADD_CORRESPONDING_LINE_NUMBERS_TO_THE_DYNAMIC_COMMENTS_SO_TO_SEE_WHERE_IN_THE_COMPILER_THE_LINES_OF_CODE_WAS_BUILD_THIS_WILL_HELP_IF_YOU_NEED_TO_GET_MORE_TECHNICAL_WITH_AN_ISSUE_ON_GITHUB_OR_EVEN_FOR_YOUR_OWN_DEBUGGING',
|
||||
'default' => '2');
|
||||
$options = array(
|
||||
'default' => '2'];
|
||||
$options = [
|
||||
'2' => 'COM_COMPONENTBUILDER_GLOBAL',
|
||||
'1' => 'COM_COMPONENTBUILDER_YES',
|
||||
'0' => 'COM_COMPONENTBUILDER_NO');
|
||||
'0' => 'COM_COMPONENTBUILDER_NO'];
|
||||
|
||||
// add to form
|
||||
$form[] = ComponentbuilderHelper::getFieldObject($attributes, 2, $options);
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'builder');
|
||||
}
|
||||
|
||||
// minify attributes
|
||||
$attributes = array(
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'minify',
|
||||
'label' => 'COM_COMPONENTBUILDER_MINIFY_JAVASCRIPT',
|
||||
'class' => 'btn-group btn-group-yesno',
|
||||
'description' => 'COM_COMPONENTBUILDER_SHOULD_THE_JAVASCRIPT_BE_MINIFIED_IN_THE_COMPONENT',
|
||||
'default' => '2');
|
||||
$options = array(
|
||||
'default' => '2'];
|
||||
$options = [
|
||||
'2' => 'COM_COMPONENTBUILDER_GLOBAL',
|
||||
'1' => 'COM_COMPONENTBUILDER_YES',
|
||||
'0' => 'COM_COMPONENTBUILDER_NO');
|
||||
'0' => 'COM_COMPONENTBUILDER_NO'];
|
||||
|
||||
// add to form
|
||||
$form[] = ComponentbuilderHelper::getFieldObject($attributes, 2, $options);
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'builder');
|
||||
}
|
||||
|
||||
// powers attributes
|
||||
$attributes = array(
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'powers',
|
||||
'label' => 'COM_COMPONENTBUILDER_ADD_POWERS',
|
||||
'class' => 'btn-group btn-group-yesno',
|
||||
'description' => 'COM_COMPONENTBUILDER_SHOULD_JCB_ADD_ANY_POWERS_THAT_ARE_CONNECTED_TO_THIS_COMPONENT_THIS_MAY_BE_HELPFUL_IF_YOU_ARE_LOADING_POWERS_VIA_ANOTHER_COMPONENT_AND_WOULD_LIKE_TO_AVOID_ADDING_IT_TO_BOTH_JUST_REMEMBER_THAT_IN_THIS_CASE_YOU_NEED_TO_LOAD_THE_POWERS_VIA_A_PLUGIN',
|
||||
'default' => '2');
|
||||
$options = array(
|
||||
'default' => '2'];
|
||||
$options = [
|
||||
'2' => 'COM_COMPONENTBUILDER_GLOBAL',
|
||||
'1' => 'COM_COMPONENTBUILDER_YES',
|
||||
'0' => 'COM_COMPONENTBUILDER_NO');
|
||||
'0' => 'COM_COMPONENTBUILDER_NO'];
|
||||
|
||||
// add to form
|
||||
$form[] = ComponentbuilderHelper::getFieldObject($attributes, 2, $options);
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'builder');
|
||||
}
|
||||
|
||||
// component attributes
|
||||
$attributes = array(
|
||||
$attributes = [
|
||||
'type' => 'list',
|
||||
'name' => 'component_id',
|
||||
'label' => 'COM_COMPONENTBUILDER_COMPONENTS',
|
||||
'class' => 'list_class',
|
||||
'description' => 'COM_COMPONENTBUILDER_SELECT_THE_COMPONENT_TO_COMPILE',
|
||||
'required' => 'true');
|
||||
'required' => 'true'];
|
||||
// start the component options
|
||||
$options = array();
|
||||
$options = [];
|
||||
$options[''] = 'COM_COMPONENTBUILDER__SELECT_COMPONENT_';
|
||||
// load component options from array
|
||||
foreach($this->Components as $component)
|
||||
{
|
||||
$options[(int) $component->id] = $this->escape($component->name);
|
||||
}
|
||||
|
||||
// add to form
|
||||
$form[] = ComponentbuilderHelper::getFieldObject($attributes, '', $options);
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'builder');
|
||||
}
|
||||
|
||||
// Advanced Options
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'show_advanced_options',
|
||||
'label' => 'COM_COMPONENTBUILDER_SHOW_ADVANCED_OPTIONS',
|
||||
'class' => 'btn-group btn-group-yesno',
|
||||
'description' => 'COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_SEE_THE_ADVANCED_COMPILER_OPTIONS',
|
||||
'default' => '0'];
|
||||
// start the advanced options switch
|
||||
$options = [
|
||||
'1' => 'COM_COMPONENTBUILDER_YES',
|
||||
'0' => 'COM_COMPONENTBUILDER_NO'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'builder');
|
||||
}
|
||||
|
||||
// Advanced Options note attributes
|
||||
$attributes = [
|
||||
'type' => 'note',
|
||||
'name' => 'show_advanced_options_note',
|
||||
'label' => "COM_COMPONENTBUILDER_ADVANCED_OPTIONS",
|
||||
'heading' => 'h3',
|
||||
'showon' => 'show_advanced_options:1'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// Joomla Versions attributes
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'joomla_version_donations',
|
||||
'label' => 'COM_COMPONENTBUILDER_JOOMLA_VERSION',
|
||||
'class' => 'btn-group btn-group-yesno',
|
||||
'description' => 'COM_COMPONENTBUILDER_WHAT_VERSION_OF_JOOMLA_WOULD_YOU_LIKE_TO_TARGET',
|
||||
'default' => '3',
|
||||
'showon' => 'show_advanced_options:1'];
|
||||
// start the joomla versions options
|
||||
$options = [
|
||||
'3' => 'COM_COMPONENTBUILDER_JOOMLA_THREE',
|
||||
'4' => 'COM_COMPONENTBUILDER_JOOMLA_FOUR'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// Joomla Version 3 attributes
|
||||
$attributes = [
|
||||
'type' => 'note',
|
||||
'name' => 'joomla_version_note_three',
|
||||
'description' => 'COM_COMPONENTBUILDER_YOUR_COMPONENT_WILL_BE_COMPILED_TO_WORK_IN_JOOMLA_THREE',
|
||||
'class' => 'alert alert-success',
|
||||
'showon' => 'show_advanced_options:1[AND]joomla_version_donations:3'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// Joomla Version 4 attributes
|
||||
$attributes = [
|
||||
'type' => 'note',
|
||||
'name' => 'joomla_version_note_four',
|
||||
'description' => 'COM_COMPONENTBUILDER_JCB_IS_NOT_YET_FULLY_READY_FOR_JOOMLA_FOUR_BUT_WITH_YOUR_HELP_WE_CAN_MAKE_THE_TRANSITION_FASTER_SHOW_YOUR_SUPPORT_BY_MAKING_A_DONATION_TODAY_AND_HELP_US_BRING_JCB_TO_THE_NEXT_LEVELBR_BR_BYOUR_COMPONENT_WILL_STILL_ONLY_BE_COMPILED_FOR_JOOMLA_THREEB',
|
||||
'class' => 'alert alert-info',
|
||||
'showon' => 'show_advanced_options:1[AND]joomla_version_donations:4'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// Indentation attributes
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'indentation_value',
|
||||
'label' => 'COM_COMPONENTBUILDER_INDENTATION_OPTIONS',
|
||||
'class' => 'btn-group btn-group-yesno',
|
||||
'description' => 'COM_COMPONENTBUILDER_WHICH_TYPE_OF_INDENTATION_WOULD_YOU_LIKE_TO_USE_PLEASE_NOTE_THAT_THIS_DOES_NOT_YET_IMPACT_THE_STATIC_TEMPLATES',
|
||||
'default' => '1',
|
||||
'showon' => 'show_advanced_options:1'];
|
||||
|
||||
// start the indentation options
|
||||
$options = [
|
||||
'1' => 'COM_COMPONENTBUILDER_TAB',
|
||||
'2' => 'COM_COMPONENTBUILDER_TWO_SPACES',
|
||||
'4' => 'COM_COMPONENTBUILDER_FOUR_SPACES'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// Build date attributes
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'add_build_date',
|
||||
'label' => 'COM_COMPONENTBUILDER_BUILD_DATE',
|
||||
'class' => 'btn-group btn-group-yesno',
|
||||
'description' => 'COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_OVERRIDE_THE_BUILD_DATE',
|
||||
'default' => '1',
|
||||
'showon' => 'show_advanced_options:1'];
|
||||
// start the build date options
|
||||
$options = [
|
||||
'1' => 'COM_COMPONENTBUILDER_DEFAULT',
|
||||
'2' => 'COM_COMPONENTBUILDER_MANUAL',
|
||||
'3' => 'COM_COMPONENTBUILDER_COMPONENT'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// Build date note attributes
|
||||
$attributes = [
|
||||
'type' => 'note',
|
||||
'name' => 'add_build_date_note_two',
|
||||
'description' => 'COM_COMPONENTBUILDER_ALLOWS_YOU_TO_OVERRIDE_THE_BUILD_DATE_BY_SELECTING_A_DATE_MANUALLY_FROM_THE_CALENDER',
|
||||
'class' => 'alert alert-info',
|
||||
'showon' => 'show_advanced_options:1[AND]add_build_date:2'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// Build date note attributes
|
||||
$attributes = [
|
||||
'type' => 'note',
|
||||
'name' => 'add_build_date_note_three',
|
||||
'description' => "COM_COMPONENTBUILDER_THE_COMPONENTS_LAST_MODIFIED_DATE_WILL_BE_USED",
|
||||
'class' => 'alert alert-info',
|
||||
'showon' => 'show_advanced_options:1[AND]add_build_date:3'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// Build date calendar attributes
|
||||
$attributes = [
|
||||
'type' => 'calendar',
|
||||
'name' => 'build_date',
|
||||
'label' => 'COM_COMPONENTBUILDER_SELECT_BUILD_DATE',
|
||||
'format' => '%Y-%m-%d',
|
||||
'filter' => 'user_utc',
|
||||
'default' => 'now',
|
||||
'size' => '22',
|
||||
'showon' => 'show_advanced_options:1[AND]add_build_date:2'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// Build date note attributes
|
||||
$attributes = [
|
||||
'type' => 'note',
|
||||
'name' => 'donations_note',
|
||||
'label' => "COM_COMPONENTBUILDER_DONATIONS",
|
||||
'description' => $this->getSupportMessage(),
|
||||
'class' => 'alert alert-success',
|
||||
'heading' => 'h1',
|
||||
'showon' => 'show_advanced_options:1'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// Build date note line attributes
|
||||
$attributes = [
|
||||
'type' => 'note',
|
||||
'name' => 'donations_note_line',
|
||||
'description' => '<hr />',
|
||||
'showon' => 'show_advanced_options:1'];
|
||||
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'advanced');
|
||||
}
|
||||
|
||||
// return the form array
|
||||
return $form;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the dynamic support request/gratitude message
|
||||
*
|
||||
* @return string The support message
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected function getSupportMessage(): string
|
||||
{
|
||||
return JLayoutHelper::render('jcbsupportmessage', []);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Prepares the document
|
||||
@ -396,7 +684,7 @@ class ComponentbuilderViewCompiler extends HtmlView
|
||||
if ($this->canDo->get('compiler.compiler_animations'))
|
||||
{
|
||||
// add Compiler Animations button.
|
||||
JToolBarHelper::custom('compiler.getCompilerAnimations', 'download custom-button-getcompileranimations', '', 'COM_COMPONENTBUILDER_COMPILER_ANIMATIONS', false);
|
||||
JToolBarHelper::custom('compiler.getDynamicContent', 'download custom-button-getdynamiccontent', '', 'COM_COMPONENTBUILDER_COMPILER_ANIMATIONS', false);
|
||||
}
|
||||
if ($this->canDo->get('compiler.clear_tmp'))
|
||||
{
|
||||
|
@ -92,7 +92,6 @@ class ComponentbuilderViewGet_snippets extends HtmlView
|
||||
{
|
||||
// Set the default uikit components in this view.
|
||||
$uikitComp = array();
|
||||
$uikitComp[] = 'UIkit.notify';
|
||||
$uikitComp[] = 'data-uk-grid';
|
||||
}
|
||||
|
||||
|
@ -213,14 +213,14 @@ jQuery('<div id="loading"></div>')
|
||||
</div>
|
||||
<?php if ($hasOwner): ?>
|
||||
<div class="well span6">
|
||||
<?php echo ComponentbuilderHelper::getPackageOwnerDetailsDisplay($this->packageInfo); ?>
|
||||
<?php echo \VDM\Joomla\Componentbuilder\Package\Factory::_('Display.Details')->owner($this->packageInfo); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
|
||||
<?php if (isset($this->packageInfo['name']) && ComponentbuilderHelper::checkArray($this->packageInfo['name'])) : ?>
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'jcbImportTab', 'info', JText::sprintf('COM_COMPONENTBUILDER_S_BEING_IMPORTED', $comP)); ?>
|
||||
<?php echo ComponentbuilderHelper::getPackageComponentsDetailsDisplay($this->packageInfo); ?>
|
||||
<?php echo \VDM\Joomla\Componentbuilder\Package\Factory::_('Display.Details')->components($this->packageInfo); ?>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
<?php endif; ?>
|
||||
|
||||
|
@ -64,6 +64,16 @@ $componentParams = $this->params; // will be removed just use $this->params inst
|
||||
</div>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'powerTab', 'composer', JText::_('COM_COMPONENTBUILDER_POWER_COMPOSER', true)); ?>
|
||||
<div class="row-fluid form-horizontal-desktop">
|
||||
</div>
|
||||
<div class="row-fluid form-horizontal-desktop">
|
||||
<div class="span12">
|
||||
<?php echo JLayoutHelper::render('power.composer_fullwidth', $this); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'powerTab', 'licensing', JText::_('COM_COMPONENTBUILDER_POWER_LICENSING', true)); ?>
|
||||
<div class="row-fluid form-horizontal-desktop">
|
||||
</div>
|
||||
|
@ -16,7 +16,16 @@ JHtml::addIncludePath(JPATH_COMPONENT.'/helpers/html');
|
||||
JHtml::_('behavior.formvalidator');
|
||||
JHtml::_('formbehavior.chosen', 'select');
|
||||
JHtml::_('behavior.keepalive');
|
||||
use VDM\Joomla\Componentbuilder\Search\Factory as SearchFactory;
|
||||
|
||||
// allow main menu selection
|
||||
$this->app->input->set('hidemainmenu', false);
|
||||
|
||||
// set the basu URL
|
||||
$url_base = JUri::base() . 'index.php?option=com_componentbuilder';
|
||||
$url_search = $url_base . '&view=search';
|
||||
|
||||
// get main search input field
|
||||
$search_value = $this->form->getField('search_value');
|
||||
?>
|
||||
<?php if ($this->canDo->get('search.access')): ?>
|
||||
<script type="text/javascript">
|
||||
@ -32,7 +41,6 @@ use VDM\Joomla\Componentbuilder\Search\Factory as SearchFactory;
|
||||
}
|
||||
</script>
|
||||
<?php $urlId = (isset($this->item->id)) ? '&id='. (int) $this->item->id : ''; ?>
|
||||
<form action="<?php echo JRoute::_('index.php?option=com_componentbuilder&view=search' . $urlId); ?>" method="post" name="adminForm" id="adminForm" class="form-validate" enctype="multipart/form-data">
|
||||
|
||||
<?php if(!empty( $this->sidebar)): ?>
|
||||
<div id="j-sidebar-container" class="span2">
|
||||
@ -42,33 +50,291 @@ use VDM\Joomla\Componentbuilder\Search\Factory as SearchFactory;
|
||||
<?php else : ?>
|
||||
<div id="j-main-container">
|
||||
<?php endif; ?>
|
||||
<?php
|
||||
// let's do some tests with the API
|
||||
$tableName = 'admin_view';
|
||||
$searchValue = '\b\w+Helper';
|
||||
// set the search configurations
|
||||
SearchFactory::_('Config')->table_name = $tableName;
|
||||
SearchFactory::_('Config')->search_value = $searchValue;
|
||||
SearchFactory::_('Config')->match_case = 1;
|
||||
SearchFactory::_('Config')->whole_word = 0;
|
||||
SearchFactory::_('Config')->regex_search = 1;
|
||||
SearchFactory::_('Config')->component_id = 0;
|
||||
<?php if ($this->form): ?>
|
||||
<form action="<?php echo JRoute::_($url_search); ?>" method="post"
|
||||
name="adminForm" id="adminForm" class="form-validate" enctype="multipart/form-data">
|
||||
<div class="form-horizontal">
|
||||
<div class="row-fluid" id="search_progress_block" style="display: none">
|
||||
<div class="uk-progress uk-progress-striped uk-active">
|
||||
<div id="search_progress_bar" class="uk-progress-bar" style="width: 0%;">0%</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row-fluid" id="replace_progress_block" style="display: none">
|
||||
<div class="uk-progress uk-progress-small uk-progress-danger uk-progress-striped uk-active">
|
||||
<div id="replace_progress_bar" class="uk-progress-bar" style="width: 0%;"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row-fluid" id="search_details_block" style="display: none">
|
||||
<span id="search_details">
|
||||
<span class="search_details_title"><?php echo JText::_('COM_COMPONENTBUILDER_SEARCHED_FOR'); ?></span>:
|
||||
[<span id="searched" class="found_code">....</span>]
|
||||
</span>
|
||||
<span id="replace_details" style="display: none">
|
||||
<span class="search_details_title"><?php echo JText::_('COM_COMPONENTBUILDER_REPLACED_WITH'); ?></span>:
|
||||
[<span id="replaced" class="found_code">....</span>]
|
||||
</span>
|
||||
<div class="btn-group" style="float: right;">
|
||||
<button style="display: none;" type="button" onclick="replaceAllCheck();" class="update_all_block hasTooltip btn button-new btn-danger"
|
||||
title="<?php echo JText::_('COM_COMPONENTBUILDER_UPDATE_ALL_ITEMS_FOUND_WITH_THIS_DATABASE_SEARCH_WITH_THE_REPLACE_VALUE'); ?>">
|
||||
<span class="icon-database icon-white" aria-hidden="true"></span>
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_UPDATE_ALL'); ?>
|
||||
</button>
|
||||
<button type="button" onclick="showSearch();" class="btn button-new btn-success">
|
||||
<span class="icon-search icon-white" aria-hidden="true"></span>
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_SEARCH_DATABASE_AGAIN'); ?>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row-fluid" id="search_settings_block">
|
||||
<div class="span7">
|
||||
<?php echo $this->form->renderField('type_search'); ?>
|
||||
<div class="btn-wrapper input-append">
|
||||
<?php echo $search_value->input; ?>
|
||||
<button id="start_search_button" onclick="startSearch(this, true);" type="button" class="btn hasTooltip"
|
||||
title="<?php echo JHtml::_('tooltipText', 'COM_COMPONENTBUILDER_START_A_SEARCH'); ?>"
|
||||
aria-label="<?php echo JText::_('COM_COMPONENTBUILDER_START_A_SEARCH'); ?>">
|
||||
<span class="icon-search" aria-hidden="true"></span>
|
||||
</button>
|
||||
<button id="stop_search_button" onclick="stopSearch();" type="button" class="btn btn-danger hasTooltip" style="display: none"
|
||||
title="<?php echo JHtml::_('tooltipText', 'COM_COMPONENTBUILDER_STOP_A_SEARCH'); ?>"
|
||||
aria-label="<?php echo JText::_('COM_COMPONENTBUILDER_STOP_A_SEARCH'); ?>">
|
||||
<span class="icon-stop" aria-hidden="true"></span>
|
||||
</button>
|
||||
</div>
|
||||
<?php echo $this->form->renderField('replace_value'); ?>
|
||||
<div class="update_all_block" style="display: none;">
|
||||
<button type="button" onclick="replaceAllCheck();" class="hasTooltip btn btn-small button-new btn-danger span11"
|
||||
title="<?php echo JText::_('COM_COMPONENTBUILDER_UPDATE_ALL_ITEMS_FOUND_WITH_THIS_DATABASE_SEARCH_WITH_THE_REPLACE_VALUE'); ?>">
|
||||
<span class="icon-database icon-white" aria-hidden="true"></span>
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_UPDATE_ALL'); ?>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="span4">
|
||||
<?php echo $this->form->renderFieldset('settings'); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row-fluid" id="search_results_block">
|
||||
<hr>
|
||||
<div id="search_results_table_block">
|
||||
<?php echo JLayoutHelper::render('table', ['id' => 'search_results_table', 'headers' => $this->table_headers, 'items' => 7, 'init' => false]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row-fluid" id="item_view_block">
|
||||
<div id="item_notice_block" style="display: none">
|
||||
<hr>
|
||||
<span id="item_edit_button"></span>
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_TABLE'); ?>: <b><span id="item_table_name">
|
||||
</span></b>(<?php echo JText::_('COM_COMPONENTBUILDER_ID'); ?>:<b><span id="item_row_id">
|
||||
</span></b>) |
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_FIELD'); ?>: <b><span id="item_field_name">
|
||||
</span></b>(<?php echo JText::_('COM_COMPONENTBUILDER_LINE'); ?>:<b><span id="item_line_number">
|
||||
</span></b>)
|
||||
<button type="button" id="item_button_update" onclick="" class="hasTooltip btn btn-small button-new btn-success"
|
||||
title="<?php echo JText::_('COM_COMPONENTBUILDER_SAVE_ALL_CHANGES_MADE_TO_THE_SELECTED_ITEM'); ?>">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_SAVE_ITEM'); ?>
|
||||
</button>
|
||||
</div>
|
||||
<hr>
|
||||
<?php echo $this->form->getInput('item_code'); ?>
|
||||
</div>
|
||||
</div>
|
||||
<input type="hidden" name="task" value="" />
|
||||
<?php echo JHtml::_('form.token'); ?>
|
||||
</form>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<?php if (isset($this->item['tables']) && ComponentbuilderHelper::checkArray($this->item['tables'])) : ?>
|
||||
<script>
|
||||
// To class="uk-autoload uk-progress" UIkit.notify
|
||||
|
||||
if (($items = SearchFactory::_('Agent')->find()) !== null)
|
||||
{
|
||||
echo JText::sprintf('COM_COMPONENTBUILDER_WE_FOUND_SOME_INSTANCES_IN_S', $tableName) . '<br /><pre>';
|
||||
var_dump($items);
|
||||
echo '</pre>';
|
||||
}
|
||||
else
|
||||
{
|
||||
echo JText::sprintf('COM_COMPONENTBUILDER_NO_INSTANCES_WHERE_FOUND_S', $tableName);
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<input type="hidden" name="task" value="" />
|
||||
<?php echo JHtml::_('form.token'); ?>
|
||||
</form>
|
||||
// get search table values
|
||||
const searchTables = <?php echo json_encode($this->item['tables']); ?>;
|
||||
|
||||
// the search Ajax URLs
|
||||
const UrlAjax = '<?php echo $url_base; ?>&format=json&raw=true&<?php echo JSession::getFormToken(); ?>=1&task=ajax.';
|
||||
|
||||
// the search URL
|
||||
const UrlSearch = '<?php echo $url_search; ?>';
|
||||
|
||||
// make sure our controller is set
|
||||
let controller = null;
|
||||
let controller_replace = null;
|
||||
|
||||
// some counters
|
||||
var fieldCount = 0;
|
||||
var lineCount = 0;
|
||||
|
||||
// start search time keepers
|
||||
var startSearchTime, endSearchTime;
|
||||
|
||||
// active edit button of row selected
|
||||
var editButtonSelected;
|
||||
|
||||
// get search progress area
|
||||
const searchProgressObject = document.getElementById("search_progress_block");
|
||||
const searchProgressBarObject = document.getElementById("search_progress_bar");
|
||||
const replaceProgressObject = document.getElementById("replace_progress_block");
|
||||
const replaceProgressBarObject = document.getElementById("replace_progress_bar");
|
||||
|
||||
// get search settings area
|
||||
const searchSettingsObject = document.getElementById("search_settings_block");
|
||||
const searchDetailsObject = document.getElementById("search_details_block");
|
||||
const searchedObject = document.getElementById("searched");
|
||||
|
||||
// get replace settings area
|
||||
const replaceDetailsObject = document.getElementById("replace_details");
|
||||
const replacedObject = document.getElementById("replaced");
|
||||
|
||||
// set the search mode objects
|
||||
const modeObject = document.getElementById("type_search");
|
||||
const typeSearchObject = document.getElementById("type_search0");
|
||||
const typeReplaceObject = document.getElementById("type_search1");
|
||||
const typeSearchLabelObject = document.querySelector('[for=type_search0]');
|
||||
const typeReplaceLabelObject = document.querySelector('[for=type_search1]');
|
||||
|
||||
// search buttons
|
||||
const startSearchButton = document.getElementById("start_search_button");
|
||||
const stopSearchButton = document.getElementById("stop_search_button");
|
||||
|
||||
// set the search settings objects
|
||||
const searchObject = document.getElementById("search_value");
|
||||
const replaceObject = document.getElementById("replace_value");
|
||||
const matchObject = document.getElementById("search_behaviour0");
|
||||
const wholeObject = document.getElementById("search_behaviour1");
|
||||
const regexObject = document.getElementById("search_behaviour2");
|
||||
const tableObject = document.getElementById("table_name");
|
||||
|
||||
// Do the search on key up of search or replace input elements
|
||||
searchObject.onkeyup = startSearch;
|
||||
|
||||
// when the made changes and there is replace value do search
|
||||
modeObject.onchange = startSearch;
|
||||
replaceObject.onkeyup = startSearch;
|
||||
|
||||
// Do the search on key up of search input elements
|
||||
matchObject.onchange = startSearch;
|
||||
wholeObject.onchange = startSearch;
|
||||
regexObject.onchange = startSearch;
|
||||
tableObject.onchange = startSearch;
|
||||
|
||||
// set the item notice area
|
||||
const itemNoticeObject = document.getElementById("item_notice_block");
|
||||
const itemEditButtonObject = document.getElementById("item_edit_button");
|
||||
const itemTableNameObject = document.getElementById("item_table_name");
|
||||
const itemRowIdObject = document.getElementById("item_row_id");
|
||||
const itemFieldNameObject = document.getElementById("item_field_name");
|
||||
const itemLineNumberObject = document.getElementById("item_line_number");
|
||||
|
||||
// set the update buttons
|
||||
const buttonUpdateItemObject = document.getElementById("item_button_update");
|
||||
const buttonUpdateAllObject = document.querySelectorAll(".update_all_block");
|
||||
|
||||
// get the editor
|
||||
var editorObject;
|
||||
|
||||
// set some global objects
|
||||
document.addEventListener('DOMContentLoaded', function () {
|
||||
// get the editor
|
||||
editorObject = Joomla.editors.instances['item_code'];
|
||||
});
|
||||
|
||||
// configurations of the table
|
||||
const tableConfigObject = {
|
||||
responsive: true,
|
||||
order: [[ 2, "asc" ]],
|
||||
select: true,
|
||||
paging: true,
|
||||
deferRender: true,
|
||||
lengthMenu: [5, 10, 20 ,50, 80, 100, 150, 200, 500, 1000, 1500, 2000],
|
||||
pageLength: 80,
|
||||
// pagingType: "scrolling", // NOT YET
|
||||
scrollY: 170,
|
||||
columnDefs: [
|
||||
{ 'targets': [ 0 ], 'visible': false, 'searchable': false },
|
||||
{ 'targets': [ 0, 1 ], type: 'html' },
|
||||
{ responsivePriority: 1, targets: 1 },
|
||||
{ responsivePriority: 2, targets: 2 },
|
||||
{ responsivePriority: 3, targets: 3 }
|
||||
],
|
||||
columns: [
|
||||
{
|
||||
data: 'edit'
|
||||
},
|
||||
{
|
||||
data: 'code'
|
||||
},
|
||||
{
|
||||
data: 'table'
|
||||
},
|
||||
{
|
||||
data: 'field'
|
||||
},
|
||||
{
|
||||
data: 'id',
|
||||
width: "15px",
|
||||
className: "small_column"
|
||||
},
|
||||
{
|
||||
data: 'line',
|
||||
width: "15px",
|
||||
className: "small_column"
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
// set some table object
|
||||
var tableSearchObject;
|
||||
var tableLengthObject;
|
||||
var tableActiveObject;
|
||||
|
||||
// The Result Table Code
|
||||
document.addEventListener('DOMContentLoaded', function () {
|
||||
|
||||
// init the table
|
||||
let searchResultsTable = new DataTable('#search_results_table', tableConfigObject);
|
||||
|
||||
searchResultsTable.on( 'select', function ( e, dt, type, indexes ) {
|
||||
if ( type === 'row' ) {
|
||||
// get the data from the row
|
||||
let data = searchResultsTable.rows( indexes ).data();
|
||||
|
||||
// get the item data
|
||||
let item_id = data[0].id;
|
||||
let item_table = data[0].table;
|
||||
let item_field = data[0].field;
|
||||
let item_line = data[0].line;
|
||||
|
||||
// set the active edit button
|
||||
editButtonSelected = data[0].edit;
|
||||
// set active row
|
||||
tableActiveObject = searchResultsTable.row( indexes );
|
||||
|
||||
// get selected item
|
||||
getSelectedItem(item_table, item_id, item_field, item_line);
|
||||
|
||||
// hide the search settings
|
||||
hideSearch();
|
||||
}
|
||||
});
|
||||
|
||||
searchResultsTable.on( 'deselect', function ( e, dt, type, indexes ) {
|
||||
if ( type === 'row' ) {
|
||||
clearSelectedItem(false);
|
||||
}
|
||||
});
|
||||
|
||||
// set the table search object
|
||||
tableSearchObject = document.getElementById("search_results_table_filter");
|
||||
tableLengthObject = document.getElementById("search_results_table_length");
|
||||
|
||||
showSearch();
|
||||
<?php if (strlen($this->urlvalues['search_value']) > 0): ?>
|
||||
startSearch(null, true);
|
||||
<?php endif; ?>
|
||||
});
|
||||
</script>
|
||||
<?php endif; ?>
|
||||
<?php else: ?>
|
||||
<h1><?php echo JText::_('COM_COMPONENTBUILDER_NO_ACCESS_GRANTED'); ?></h1>
|
||||
<?php endif; ?>
|
||||
|
@ -13,6 +13,9 @@
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
use Joomla\CMS\MVC\View\HtmlView;
|
||||
use Joomla\CMS\Filesystem\File;
|
||||
use VDM\Joomla\Componentbuilder\Search\Factory as SearchFactory;
|
||||
use Joomla\CMS\Form\Form;
|
||||
|
||||
/**
|
||||
* Componentbuilder Html View class for the Search
|
||||
@ -32,13 +35,52 @@ class ComponentbuilderViewSearch extends HtmlView
|
||||
$this->canDo = ComponentbuilderHelper::getActions('search');
|
||||
// Initialise variables.
|
||||
$this->item = $this->get('Item');
|
||||
$this->urlvalues = $this->get('UrlValues');
|
||||
if ($this->getLayout() !== 'modal')
|
||||
{
|
||||
// Include helper submenu
|
||||
ComponentbuilderHelper::addSubmenu('search');
|
||||
JHtmlSidebar::setAction('index.php?option=com_componentbuilder&view=search');
|
||||
$this->sidebar = JHtmlSidebar::render();
|
||||
}
|
||||
}
|
||||
|
||||
// get the needed form fields
|
||||
$this->form = $this->getDynamicForm();
|
||||
|
||||
// build our table headers
|
||||
$this->table_headers = array(
|
||||
'edit' => 'E',
|
||||
'code' => JText::_('COM_COMPONENTBUILDER_FOUND_TEXT'),
|
||||
'table' => JText::_('COM_COMPONENTBUILDER_TABLE'),
|
||||
'field' => JText::_('COM_COMPONENTBUILDER_FIELD'),
|
||||
'id' => JText::_('ID'),
|
||||
'line' => JText::_('COM_COMPONENTBUILDER_LINE')
|
||||
);
|
||||
|
||||
// set some JavaScript Language
|
||||
JText::script('COM_COMPONENTBUILDER_YOUR_ARE_ABOUT_TO_UPDATE_ROW');
|
||||
JText::script('COM_COMPONENTBUILDER_FIELD_IN_THE');
|
||||
JText::script('COM_COMPONENTBUILDER_TABLE');
|
||||
JText::script('COM_COMPONENTBUILDER_THIS_CAN_NOT_BE_UNDONE_ARE_YOU_SURE_YOU_WANT_TO_CONTINUE');
|
||||
JText::script('COM_COMPONENTBUILDER_YOUR_ARE_ABOUT_TO_UPDATE_BALLB_VALUES_THAT_CAN_BE_FOUND_IN_THE_DATABASE');
|
||||
JText::script('COM_COMPONENTBUILDER_YOU_WILL_REPLACE');
|
||||
JText::script('COM_COMPONENTBUILDER_WITH');
|
||||
JText::script('COM_COMPONENTBUILDER_THIS_CAN_NOT_BE_UNDONE_BYOU_HAVE_BEEN_WARNEDB');
|
||||
JText::script('COM_COMPONENTBUILDER_ARE_YOU_THEREFORE_ABSOLUTELY_SURE_YOU_WANT_TO_CONTINUE');
|
||||
JText::script('COM_COMPONENTBUILDER_THE_SEARCH_PROCESS_HAD_AN_ERROR_WITH_TABLE');
|
||||
JText::script('COM_COMPONENTBUILDER_THE_REPLACE_PROCESS_HAD_AN_ERROR_WITH_TABLE');
|
||||
JText::script('COM_COMPONENTBUILDER_REPLACE_PROCESS_COMPLETE');
|
||||
JText::script('COM_COMPONENTBUILDER_SEARCHING');
|
||||
JText::script('COM_COMPONENTBUILDER_TABLES_WITH');
|
||||
JText::script('COM_COMPONENTBUILDER_FIELDS_THAT_HAD');
|
||||
JText::script('COM_COMPONENTBUILDER_LINES');
|
||||
JText::script('COM_COMPONENTBUILDER_AND_FINISHED_THE_SEARCH_IN');
|
||||
JText::script('COM_COMPONENTBUILDER_SECONDS');
|
||||
JText::script('COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_DO_A_REVERSE_SEARCH');
|
||||
JText::script('COM_COMPONENTBUILDER_WOULD_YOU_LIKE_TO_REPEAT_THE_SAME_SEARCH');
|
||||
JText::script('COM_COMPONENTBUILDER_YES_UPDATE_ALL');
|
||||
JText::script('COM_COMPONENTBUILDER_NO');
|
||||
JText::script('COM_COMPONENTBUILDER_YES');
|
||||
|
||||
// We don't need toolbar in the modal window.
|
||||
if ($this->getLayout() !== 'modal')
|
||||
@ -59,6 +101,206 @@ class ComponentbuilderViewSearch extends HtmlView
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the dynamic build form fields needed on the page
|
||||
*
|
||||
* @return Form|null The array of form fields
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function getDynamicForm(): ?Form
|
||||
{
|
||||
if(ComponentbuilderHelper::checkArray($this->item) &&
|
||||
ComponentbuilderHelper::checkArray($this->item['tables']) &&
|
||||
ComponentbuilderHelper::checkArray($this->item['components']))
|
||||
{
|
||||
// start the form
|
||||
$form = new Form('Search');
|
||||
|
||||
$form->load('<form
|
||||
addrulepath="/administrator/components/com_componentbuilder/models/rules"
|
||||
addfieldpath="/administrator/components/com_componentbuilder/models/fields">
|
||||
<fieldset name="search"></fieldset>
|
||||
<fieldset name="settings"></fieldset>
|
||||
<fieldset name="view"></fieldset>
|
||||
</form>');
|
||||
|
||||
// Search Mode
|
||||
$attributes = [
|
||||
'type' => 'radio',
|
||||
'name' => 'type_search',
|
||||
'hiddenLabel' => true,
|
||||
'label' => 'COM_COMPONENTBUILDER_MODE',
|
||||
'class' => 'btn-group',
|
||||
'description' => 'COM_COMPONENTBUILDER_SEARCH_OR_SEARCH_AND_REPLACE',
|
||||
'default' => $this->urlvalues['type_search']];
|
||||
// set the mode options
|
||||
$options = [
|
||||
1 => 'COM_COMPONENTBUILDER_SEARCH',
|
||||
2 => 'COM_COMPONENTBUILDER_REPLACE',
|
||||
0 => 'COM_COMPONENTBUILDER_CLEAR'];
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'search');
|
||||
}
|
||||
|
||||
// search text attributes
|
||||
$attributes = [
|
||||
'type' => 'text',
|
||||
'name' => 'search_value',
|
||||
'hiddenLabel' => true,
|
||||
'label' => 'COM_COMPONENTBUILDER_SEARCH',
|
||||
'size' => 150,
|
||||
'maxlength' => 200,
|
||||
'description' => 'COM_COMPONENTBUILDER_HERE_YOU_CAN_ENTER_YOUR_SEARCH_TEXT',
|
||||
'filter' => 'RAW',
|
||||
'class' => 'search-value span11',
|
||||
'hint' => 'COM_COMPONENTBUILDER_ENTER_YOUR_SEARCH_TEXT',
|
||||
'autocomplete' => true,
|
||||
'default' => $this->urlvalues['search_value']];
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'search');
|
||||
}
|
||||
|
||||
// replace text attributes
|
||||
$attributes = [
|
||||
'type' => 'text',
|
||||
'name' => 'replace_value',
|
||||
'hiddenLabel' => true,
|
||||
'label' => 'COM_COMPONENTBUILDER_REPLACE',
|
||||
'size' => 150,
|
||||
'maxlength' => 200,
|
||||
'description' => 'COM_COMPONENTBUILDER_HERE_YOU_CAN_ENTER_THE_REPLACE_TEXT_THAT_YOU_WOULD_LIKE_TO_USE_AS_REPLACEMENT_FOR_THE_SEARCH_TEXT_FOUND',
|
||||
'filter' => 'RAW',
|
||||
'class' => 'replace-value span11',
|
||||
'hint' => 'COM_COMPONENTBUILDER_ENTER_YOUR_REPLACE_TEXT',
|
||||
'autocomplete' => true,
|
||||
'showon' => 'type_search:2',
|
||||
'default' => $this->urlvalues['replace_value']];
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'search');
|
||||
}
|
||||
|
||||
// Search Behaviour
|
||||
$default = [];
|
||||
if ($this->urlvalues['match_case'] == 1)
|
||||
{
|
||||
$default[] = 'match_case';
|
||||
}
|
||||
if ($this->urlvalues['whole_word'] == 1)
|
||||
{
|
||||
$default[] = 'whole_word';
|
||||
}
|
||||
if ($this->urlvalues['regex_search'] == 1)
|
||||
{
|
||||
$default[] = 'regex_search';
|
||||
}
|
||||
$attributes = [
|
||||
'type' => 'checkboxes',
|
||||
'name' => 'search_behaviour',
|
||||
'label' => 'COM_COMPONENTBUILDER_BEHAVIOUR',
|
||||
'description' => 'COM_COMPONENTBUILDER_SET_THE_SEARCH_BEHAVIOUR_HERE'];
|
||||
if (ComponentbuilderHelper::checkArray($default))
|
||||
{
|
||||
$attributes['default'] = implode(',', $default);
|
||||
}
|
||||
// set the mode options
|
||||
$options = [
|
||||
'match_case' => 'COM_COMPONENTBUILDER_MATCH_CASE',
|
||||
'whole_word' => 'COM_COMPONENTBUILDER_WHOLE_WORD',
|
||||
'regex_search' => 'COM_COMPONENTBUILDER_REGEX_SEARCH'];
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'settings');
|
||||
}
|
||||
|
||||
// component attributes
|
||||
$attributes = [
|
||||
'type' => 'list',
|
||||
'name' => 'component_id',
|
||||
'label' => 'COM_COMPONENTBUILDER_COMPONENTS_BR_SMALLDISABLED_SOONSMALL',
|
||||
'class' => 'list_class',
|
||||
'description' => 'COM_COMPONENTBUILDER_SELECT_THE_COMPONENT_TO_SEARCH',
|
||||
'required' => 'true',
|
||||
'disable' => 'true',
|
||||
'readonly' => 'true',
|
||||
'default' => -1];
|
||||
// start the component options
|
||||
$options = [];
|
||||
$options['-1'] = 'COM_COMPONENTBUILDER__SEARCH_ALL_';
|
||||
// load component options from array
|
||||
foreach($this->item['components'] as $component)
|
||||
{
|
||||
$options[(int) $component->id] = $this->escape($component->name);
|
||||
}
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'settings');
|
||||
}
|
||||
|
||||
// table attributes
|
||||
$attributes = [
|
||||
'type' => 'list',
|
||||
'name' => 'table_name',
|
||||
'label' => 'COM_COMPONENTBUILDER_TABLES',
|
||||
'class' => 'list_class',
|
||||
'description' => 'COM_COMPONENTBUILDER_SELECT_THE_TABLE_TO_SEARCH',
|
||||
'required' => 'true',
|
||||
'default' => $this->urlvalues['table_name']];
|
||||
// start the component options
|
||||
$options = [];
|
||||
$options['-1'] = 'COM_COMPONENTBUILDER__SEARCH_ALL_';
|
||||
// load table options from array
|
||||
foreach($this->item['tables'] as $table)
|
||||
{
|
||||
$options[$table] = $this->escape($table);
|
||||
}
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'settings');
|
||||
}
|
||||
|
||||
// editor attributes
|
||||
$attributes = [
|
||||
'type' => 'editor',
|
||||
'name' => 'item_code',
|
||||
'label' => 'COM_COMPONENTBUILDER_ITEM_CODE',
|
||||
'width' => '100%',
|
||||
'height' => '150px',
|
||||
'class' => 'item_code_editor',
|
||||
'syntax' => 'php',
|
||||
'buttons' => 'false',
|
||||
'filter' => 'raw',
|
||||
'editor' => 'codemirror|none'];
|
||||
// add to form
|
||||
$xml = ComponentbuilderHelper::getFieldXML($attributes, $options);
|
||||
if ($xml instanceof SimpleXMLElement)
|
||||
{
|
||||
$form->setField($xml, null, true, 'view');
|
||||
}
|
||||
|
||||
// return the form array
|
||||
return $form;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Prepares the document
|
||||
*/
|
||||
@ -72,6 +314,15 @@ class ComponentbuilderViewSearch extends HtmlView
|
||||
// Initialize the header checker.
|
||||
$HeaderCheck = new componentbuilderHeaderCheck;
|
||||
|
||||
// always load these files.
|
||||
$this->document->addStyleSheet(JURI::root(true) . "/media/com_componentbuilder/datatable/css/datatables.min.css", (ComponentbuilderHelper::jVersion()->isCompatible("3.8.0")) ? array("version" => "auto") : "text/css");
|
||||
$this->document->addScript(JURI::root(true) . "/media/com_componentbuilder/datatable/js/pdfmake.min.js", (ComponentbuilderHelper::jVersion()->isCompatible("3.8.0")) ? array("version" => "auto") : "text/javascript");
|
||||
$this->document->addScript(JURI::root(true) . "/media/com_componentbuilder/datatable/js/vfs_fonts.js", (ComponentbuilderHelper::jVersion()->isCompatible("3.8.0")) ? array("version" => "auto") : "text/javascript");
|
||||
$this->document->addScript(JURI::root(true) . "/media/com_componentbuilder/datatable/js/datatables.min.js", (ComponentbuilderHelper::jVersion()->isCompatible("3.8.0")) ? array("version" => "auto") : "text/javascript");
|
||||
|
||||
// Add View JavaScript File
|
||||
$this->document->addScript(JURI::root(true) . "/administrator/components/com_componentbuilder/assets/js/search.js", (ComponentbuilderHelper::jVersion()->isCompatible("3.8.0")) ? array("version" => "auto") : "text/javascript");
|
||||
|
||||
// Load uikit options.
|
||||
$uikit = $this->params->get('uikit_load');
|
||||
// Set script size.
|
||||
@ -89,6 +340,41 @@ class ComponentbuilderViewSearch extends HtmlView
|
||||
{
|
||||
JHtml::_('script', 'media/com_componentbuilder/uikit-v2/js/uikit'.$size.'.js', ['version' => 'auto']);
|
||||
}
|
||||
|
||||
// Load the script to find all uikit components needed.
|
||||
if ($uikit != 2)
|
||||
{
|
||||
// Set the default uikit components in this view.
|
||||
$uikitComp = array();
|
||||
$uikitComp[] = 'UIkit.notify';
|
||||
$uikitComp[] = 'uk-progress';
|
||||
}
|
||||
|
||||
// Load the needed uikit components in this view.
|
||||
if ($uikit != 2 && isset($uikitComp) && ComponentbuilderHelper::checkArray($uikitComp))
|
||||
{
|
||||
// load just in case.
|
||||
jimport('joomla.filesystem.file');
|
||||
// loading...
|
||||
foreach ($uikitComp as $class)
|
||||
{
|
||||
foreach (ComponentbuilderHelper::$uk_components[$class] as $name)
|
||||
{
|
||||
// check if the CSS file exists.
|
||||
if (File::exists(JPATH_ROOT.'/media/com_componentbuilder/uikit-v2/css/components/'.$name.$style.$size.'.css'))
|
||||
{
|
||||
// load the css.
|
||||
JHtml::_('stylesheet', 'media/com_componentbuilder/uikit-v2/css/components/'.$name.$style.$size.'.css', ['version' => 'auto']);
|
||||
}
|
||||
// check if the JavaScript file exists.
|
||||
if (File::exists(JPATH_ROOT.'/media/com_componentbuilder/uikit-v2/js/components/'.$name.$size.'.js'))
|
||||
{
|
||||
// load the js.
|
||||
JHtml::_('script', 'media/com_componentbuilder/uikit-v2/js/components/'.$name.$size.'.js', ['version' => 'auto'], ['type' => 'text/javascript', 'async' => 'async']);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// add the document default css file
|
||||
$this->document->addStyleSheet(JURI::root(true) .'/administrator/components/com_componentbuilder/assets/css/search.css', (ComponentbuilderHelper::jVersion()->isCompatible('3.8.0')) ? array('version' => 'auto') : 'text/css');
|
||||
}
|
||||
|
@ -1,15 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<extension type="component" version="4" method="upgrade">
|
||||
<name>COM_COMPONENTBUILDER</name>
|
||||
<creationDate>20th September, 2022</creationDate>
|
||||
<creationDate>27th February, 2023</creationDate>
|
||||
<author>Llewellyn van der Merwe</author>
|
||||
<authorEmail>joomla@vdm.io</authorEmail>
|
||||
<authorUrl>https://dev.vdm.io</authorUrl>
|
||||
<copyright>Copyright (C) 2015 Vast Development Method. All rights reserved.</copyright>
|
||||
<license>GNU General Public License version 2 or later; see LICENSE.txt</license>
|
||||
<version>3.1.8</version>
|
||||
<version>3.1.19</version>
|
||||
<description>< is highly advanced tool that is truly able to build extremely complex components in a fraction of the time.
|
||||
|
||||
@ -39,6 +39,7 @@ Whether you're a seasoned [Joomla](https://extensions.joomla.org/extension/compo
|
||||
<folder>js</folder>
|
||||
<folder>css</folder>
|
||||
<folder>images</folder>
|
||||
<folder>datatable</folder>
|
||||
<folder>uikit-v2</folder>
|
||||
<folder>footable-v3</folder>
|
||||
</media>
|
||||
@ -74,11 +75,11 @@ Whether you're a seasoned [Joomla](https://extensions.joomla.org/extension/compo
|
||||
<submenu>
|
||||
<!-- Instead of link you can specify individual link attributes -->
|
||||
<menu option="com_componentbuilder" view="compiler">COM_COMPONENTBUILDER_MENU_COMPILER</menu>
|
||||
<menu option="com_componentbuilder" view="search">COM_COMPONENTBUILDER_MENU_SEARCH</menu>
|
||||
<menu option="com_componentbuilder" view="joomla_components">COM_COMPONENTBUILDER_MENU_JOOMLA_COMPONENTS</menu>
|
||||
<menu option="com_componentbuilder" view="joomla_modules">COM_COMPONENTBUILDER_MENU_JOOMLA_MODULES</menu>
|
||||
<menu option="com_componentbuilder" view="joomla_plugins">COM_COMPONENTBUILDER_MENU_JOOMLA_PLUGINS</menu>
|
||||
<menu option="com_componentbuilder" view="powers">COM_COMPONENTBUILDER_MENU_POWERS</menu>
|
||||
<menu option="com_componentbuilder" view="search">COM_COMPONENTBUILDER_MENU_SEARCH</menu>
|
||||
<menu option="com_componentbuilder" view="admin_views">COM_COMPONENTBUILDER_MENU_ADMIN_VIEWS</menu>
|
||||
<menu option="com_componentbuilder" view="custom_admin_views">COM_COMPONENTBUILDER_MENU_CUSTOM_ADMIN_VIEWS</menu>
|
||||
<menu option="com_componentbuilder" view="site_views">COM_COMPONENTBUILDER_MENU_SITE_VIEWS</menu>
|
||||
|
@ -1097,10 +1097,28 @@
|
||||
<element>pkg_component_builder</element>
|
||||
<type>package</type>
|
||||
<client>site</client>
|
||||
<version>3.1.8</version>
|
||||
<version>3.1.12</version>
|
||||
<infourl title="Component Builder!">https://dev.vdm.io</infourl>
|
||||
<downloads>
|
||||
<downloadurl type="full" format="zip">https://git.vdm.dev/api/v1/repos/joomla/pkg-component-builder/archive/v3.1.8.zip</downloadurl>
|
||||
<downloadurl type="full" format="zip">https://git.vdm.dev/api/v1/repos/joomla/pkg-component-builder/archive/v3.1.12.zip</downloadurl>
|
||||
</downloads>
|
||||
<tags>
|
||||
<tag>stable</tag>
|
||||
</tags>
|
||||
<maintainer>Llewellyn van der Merwe</maintainer>
|
||||
<maintainerurl>https://dev.vdm.io</maintainerurl>
|
||||
<targetplatform name="joomla" version="3.*"/>
|
||||
</update>
|
||||
<update>
|
||||
<name>Component Builder</name>
|
||||
<description>Builds Complex Joomla Components</description>
|
||||
<element>pkg_component_builder</element>
|
||||
<type>package</type>
|
||||
<client>site</client>
|
||||
<version>3.1.19</version>
|
||||
<infourl title="Component Builder!">https://dev.vdm.io</infourl>
|
||||
<downloads>
|
||||
<downloadurl type="full" format="zip">https://git.vdm.dev/api/v1/repos/joomla/pkg-component-builder/archive/v3.1.19.zip</downloadurl>
|
||||
</downloads>
|
||||
<tags>
|
||||
<tag>stable</tag>
|
||||
|
@ -58,7 +58,7 @@ abstract class AbstractGiteaObject
|
||||
$this->options = $options ?: new Registry;
|
||||
$this->client = $client ?: (new HttpFactory)->getHttp($this->options);
|
||||
|
||||
$this->package = \get_class($this);
|
||||
$this->package = static::class;
|
||||
$this->package = substr($this->package, strrpos($this->package, '\\') + 1);
|
||||
}
|
||||
|
||||
@ -83,7 +83,7 @@ abstract class AbstractGiteaObject
|
||||
if ($this->options->get('access.token', false))
|
||||
{
|
||||
// Use oAuth authentication
|
||||
$headers = $this->client->getOption('headers', array());
|
||||
$headers = $this->client->getOption('headers', []);
|
||||
|
||||
if (!isset($headers['Authorization']))
|
||||
{
|
||||
@ -137,7 +137,7 @@ abstract class AbstractGiteaObject
|
||||
if ($response->code != $expectedCode)
|
||||
{
|
||||
// Decode the error response and throw an exception.
|
||||
$error = json_decode($response->body);
|
||||
$error = json_decode((string) $response->body);
|
||||
$message = isset($error->message) ? $error->message : 'Invalid response received from Gitea.';
|
||||
|
||||
throw new \DomainException($message, $response->code);
|
||||
@ -145,11 +145,11 @@ abstract class AbstractGiteaObject
|
||||
|
||||
if (JsonHelper::check($response->body))
|
||||
{
|
||||
$body = json_decode($response->body);
|
||||
$body = json_decode((string) $response->body);
|
||||
|
||||
if (isset($body->content_base64))
|
||||
{
|
||||
$body->content = base64_decode($body->content_base64);
|
||||
$body->content = base64_decode((string) $body->content_base64);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
@ -30,7 +30,7 @@ abstract class AbstractPackage extends AbstractGiteaObject
|
||||
{
|
||||
parent::__construct($options, $client);
|
||||
|
||||
$this->package = \get_class($this);
|
||||
$this->package = static::class;
|
||||
$this->package = substr($this->package, strrpos($this->package, '\\') + 1);
|
||||
}
|
||||
|
||||
|
@ -70,7 +70,7 @@ class Wiki extends AbstractPackage
|
||||
$path = '/markdown';
|
||||
|
||||
// Get headers
|
||||
$headers = $this->client->getOption('headers', array());
|
||||
$headers = $this->client->getOption('headers', []);
|
||||
|
||||
$headers['accept'] = 'text/html';
|
||||
$headers['Content-Type'] = 'application/json';
|
||||
|
@ -2,17 +2,17 @@
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 3rd September, 2022
|
||||
* @created 4th September, 2022
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
namespace VDM\Joomla\Componentbuilder;
|
||||
namespace VDM\Joomla\Componentbuilder\Abstraction;
|
||||
|
||||
|
||||
use Joomla\Registry\Registry;
|
||||
use Joomla\Registry\Registry as JoomlaRegistry;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\Input\Input;
|
||||
use VDM\Joomla\Utilities\Component\Helper;
|
||||
@ -20,11 +20,11 @@ use VDM\Joomla\Utilities\String\ClassfunctionHelper;
|
||||
|
||||
|
||||
/**
|
||||
* Configurations
|
||||
* Config
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract class BaseConfig extends Registry
|
||||
abstract class BaseConfig extends JoomlaRegistry
|
||||
{
|
||||
/**
|
||||
* Hold a JInput object for easier access to the input variables.
|
||||
@ -32,15 +32,15 @@ abstract class BaseConfig extends Registry
|
||||
* @var Input
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected $input;
|
||||
protected Input $input;
|
||||
|
||||
/**
|
||||
* The Params
|
||||
*
|
||||
* @var Registry
|
||||
* @var JoomlaRegistry
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Registry $params;
|
||||
protected JoomlaRegistry $params;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
@ -51,14 +51,11 @@ abstract class BaseConfig extends Registry
|
||||
* @throws \Exception
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function __construct(?Input $input = null, ?Registry $params = null)
|
||||
public function __construct(?Input $input = null, ?JoomlaRegistry $params = null)
|
||||
{
|
||||
$this->input = $input ?: Factory::getApplication()->input;
|
||||
$this->params = $params ?: Helper::getParams('com_componentbuilder');
|
||||
|
||||
// use underscore as the separator
|
||||
$this->separator = '_';
|
||||
|
||||
// Instantiate the internal data object.
|
||||
$this->data = new \stdClass();
|
||||
}
|
||||
@ -66,12 +63,12 @@ abstract class BaseConfig extends Registry
|
||||
/**
|
||||
* setting any config value
|
||||
*
|
||||
* @param String $key The value's key/path name
|
||||
* @param string $key The value's key/path name
|
||||
* @param mixed $value Optional default value, returned if the internal value is null.
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function __set($key, $value)
|
||||
public function __set(string $key, $value)
|
||||
{
|
||||
$this->set($key, $value);
|
||||
}
|
||||
@ -79,12 +76,12 @@ abstract class BaseConfig extends Registry
|
||||
/**
|
||||
* getting any valid value
|
||||
*
|
||||
* @param String $key The value's key/path name
|
||||
* @param string $key The value's key/path name
|
||||
*
|
||||
* @since 3.2.0
|
||||
* @throws \InvalidArgumentException If $key is not a valid function name.
|
||||
*/
|
||||
public function __get($key)
|
||||
public function __get(string $key)
|
||||
{
|
||||
// check if it has been set
|
||||
if (($value = $this->get($key, '__N0T_S3T_Y3T_')) !== '__N0T_S3T_Y3T_')
|
||||
@ -92,13 +89,13 @@ abstract class BaseConfig extends Registry
|
||||
return $value;
|
||||
}
|
||||
|
||||
throw new \InvalidArgumentException(sprintf('Argument %s could not be found as function [%s], or path.', $key, $method));
|
||||
throw new \InvalidArgumentException(sprintf('Argument %s could not be found as function or path.', $key));
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a config value.
|
||||
*
|
||||
* @param string $path Registry path (e.g. joomla.content.showauthor)
|
||||
* @param string $path Registry path (e.g. joomla_content_showauthor)
|
||||
* @param mixed $default Optional default value, returned if the internal value is null.
|
||||
*
|
||||
* @return mixed Value of entry or null
|
||||
@ -108,7 +105,7 @@ abstract class BaseConfig extends Registry
|
||||
public function get($path, $default = null)
|
||||
{
|
||||
// function name with no underscores
|
||||
$method = 'get' . ucfirst(ClassfunctionHelper::safe(str_replace('_', '', $path)));
|
||||
$method = 'get' . ucfirst((string) ClassfunctionHelper::safe(str_replace('_', '', $path)));
|
||||
|
||||
// check if it has been set
|
||||
if (($value = parent::get($path, '__N0T_S3T_Y3T_')) !== '__N0T_S3T_Y3T_')
|
||||
@ -117,7 +114,7 @@ abstract class BaseConfig extends Registry
|
||||
}
|
||||
elseif (method_exists($this, $method))
|
||||
{
|
||||
$value = $this->{$method}();
|
||||
$value = $this->{$method}($default);
|
||||
|
||||
$this->set($path, $value);
|
||||
|
||||
@ -126,6 +123,27 @@ abstract class BaseConfig extends Registry
|
||||
|
||||
return $default;
|
||||
}
|
||||
|
||||
/**
|
||||
* Append value to a path in registry of an array
|
||||
*
|
||||
* @param string $path Parent registry Path (e.g. joomla.content.showauthor)
|
||||
* @param mixed $value Value of entry
|
||||
*
|
||||
* @return mixed The value of the that has been set.
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function appendArray(string $path, $value)
|
||||
{
|
||||
// check if it does not exist
|
||||
if (!$this->exists($path))
|
||||
{
|
||||
$this->set($path, []);
|
||||
}
|
||||
|
||||
return $this->append($path, $value);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -0,0 +1,150 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 4th September, 2022
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
namespace VDM\Joomla\Componentbuilder\Abstraction;
|
||||
|
||||
|
||||
use Joomla\Registry\Registry as JoomlaRegistry;
|
||||
|
||||
|
||||
/**
|
||||
* Registry
|
||||
*
|
||||
* So we have full control over this class
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract class BaseRegistry extends JoomlaRegistry implements \JsonSerializable, \ArrayAccess, \IteratorAggregate, \Countable
|
||||
{
|
||||
/**
|
||||
* Method to iterate over any part of the registry
|
||||
*
|
||||
* @param string $path Registry path (e.g. joomla.content.showauthor)
|
||||
*
|
||||
* @return \ArrayIterator|null This object represented as an ArrayIterator.
|
||||
*
|
||||
* @since 3.4.0
|
||||
*/
|
||||
public function _(string $path): ?\ArrayIterator
|
||||
{
|
||||
$data = $this->extract($path);
|
||||
|
||||
if ($data === null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
return $data->getIterator();
|
||||
}
|
||||
|
||||
/**
|
||||
* Append value to a path in registry of an array
|
||||
*
|
||||
* @param string $path Parent registry Path (e.g. joomla.content.showauthor)
|
||||
* @param mixed $value Value of entry
|
||||
*
|
||||
* @return mixed The value of the that has been set.
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function appendArray(string $path, $value)
|
||||
{
|
||||
// check if it does not exist
|
||||
if (!$this->exists($path))
|
||||
{
|
||||
$this->set($path, []);
|
||||
}
|
||||
|
||||
return $this->append($path, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if a registry path exists and is an array
|
||||
*
|
||||
* @param string $path Registry path (e.g. joomla.content.showauthor)
|
||||
*
|
||||
* @return boolean
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function isArray(string $path): bool
|
||||
{
|
||||
// Return default value if path is empty
|
||||
if (empty($path)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// get the value
|
||||
if (($node = $this->get($path)) !== null
|
||||
&& is_array($node)
|
||||
&& $node !== [])
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if a registry path exists and is a string
|
||||
*
|
||||
* @param string $path Registry path (e.g. joomla.content.showauthor)
|
||||
*
|
||||
* @return boolean
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function isString(string $path): bool
|
||||
{
|
||||
// Return default value if path is empty
|
||||
if (empty($path)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// get the value
|
||||
if (($node = $this->get($path)) !== null
|
||||
&& is_string($node)
|
||||
&& strlen((string) $node) > 0)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if a registry path exists and is numeric
|
||||
*
|
||||
* @param string $path Registry path (e.g. joomla.content.showauthor)
|
||||
*
|
||||
* @return boolean
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function isNumeric(string $path): bool
|
||||
{
|
||||
// Return default value if path is empty
|
||||
if (empty($path)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// get the value
|
||||
if (($node = $this->get($path)) !== null
|
||||
&& is_numeric($node))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -0,0 +1,108 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 4th September, 2022
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
namespace VDM\Joomla\Componentbuilder\Abstraction;
|
||||
|
||||
|
||||
use Joomla\CMS\Factory as JoomlaFactory;
|
||||
use VDM\Joomla\Utilities\Component\Helper;
|
||||
|
||||
|
||||
/**
|
||||
* Database
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract class Database
|
||||
{
|
||||
/**
|
||||
* Database object to query local DB
|
||||
*
|
||||
* @var \JDatabaseDriver
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected \JDatabaseDriver $db;
|
||||
|
||||
/**
|
||||
* Core Component Table Name
|
||||
*
|
||||
* @var string
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected string $table;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param \JDatabaseDriver|null $db The database driver
|
||||
*
|
||||
* @throws \Exception
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function __construct(?\JDatabaseDriver $db = null)
|
||||
{
|
||||
$this->db = $db ?: JoomlaFactory::getDbo();
|
||||
|
||||
// set the component table
|
||||
$this->table = '#__' . Helper::getCode();
|
||||
}
|
||||
|
||||
/**
|
||||
* Set a value based on data type
|
||||
*
|
||||
* @param mixed $value The value to set
|
||||
*
|
||||
* @return mixed
|
||||
* @since 3.2.0
|
||||
**/
|
||||
protected function quote($value)
|
||||
{
|
||||
if (is_numeric($value))
|
||||
{
|
||||
if (filter_var($value, FILTER_VALIDATE_INT))
|
||||
{
|
||||
return (int) $value;
|
||||
}
|
||||
elseif (filter_var($value, FILTER_VALIDATE_FLOAT))
|
||||
{
|
||||
return (float) $value;
|
||||
}
|
||||
}
|
||||
elseif (is_bool($value))
|
||||
{
|
||||
return (int) $value;
|
||||
}
|
||||
|
||||
// default just escape it
|
||||
return $this->db->quote($value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set a table name, adding the
|
||||
* core component as needed
|
||||
*
|
||||
* @param string $table The table string
|
||||
*
|
||||
* @return string
|
||||
* @since 3.2.0
|
||||
**/
|
||||
protected function getTable(string $table): string
|
||||
{
|
||||
if (strpos($table, '#__') === false)
|
||||
{
|
||||
return $this->table . '_' . $table;
|
||||
}
|
||||
|
||||
return $table;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -0,0 +1,258 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 4th September, 2022
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
namespace VDM\Joomla\Componentbuilder\Abstraction;
|
||||
|
||||
|
||||
use VDM\Joomla\Componentbuilder\Interfaces\Mapperdoubleinterface;
|
||||
use VDM\Joomla\Componentbuilder\Interfaces\Mappersingleinterface;
|
||||
|
||||
|
||||
/**
|
||||
* Compiler Mapper
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract class Mapper implements Mapperdoubleinterface, Mappersingleinterface
|
||||
{
|
||||
|
||||
/**
|
||||
* The Content
|
||||
*
|
||||
* @var array
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public array $active = [];
|
||||
|
||||
/**
|
||||
* Set content
|
||||
*
|
||||
* @param string $key The main string key
|
||||
* @param mixed $value The values to set
|
||||
*
|
||||
* @return void
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function set(string $key, $value)
|
||||
{
|
||||
$this->active[$this->key($key)] = $value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get content
|
||||
*
|
||||
* @param string $key The main string key
|
||||
*
|
||||
* @return mixed
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function get(string $key)
|
||||
{
|
||||
return $this->active[$this->key($key)] ?? null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Does key exist
|
||||
*
|
||||
* @param string $key The main string key
|
||||
*
|
||||
* @return bool
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function exist(string $key): bool
|
||||
{
|
||||
if (isset($this->active[$this->key($key)]))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add content
|
||||
*
|
||||
* @param string $key The main string key
|
||||
* @param mixed $value The values to set
|
||||
*
|
||||
* @return void
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function add(string $key, $value)
|
||||
{
|
||||
if (isset($this->active[$this->key($key)]))
|
||||
{
|
||||
$this->active[$this->key($key)] .= $value;
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->active[$this->key($key)] = $value;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove content
|
||||
*
|
||||
* @param string $key The main string key
|
||||
*
|
||||
* @return void
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function remove(string $key)
|
||||
{
|
||||
unset($this->active[$this->key($key)]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Model the key
|
||||
*
|
||||
* @param string $key The key to model
|
||||
*
|
||||
* @return string
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract protected function key(string $key): string;
|
||||
|
||||
/**
|
||||
* The Dynamic Content
|
||||
*
|
||||
* @var array
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public array $_active = [];
|
||||
|
||||
/**
|
||||
* Set dynamic content
|
||||
*
|
||||
* @param string $firstKey The first key
|
||||
* @param string $secondKey The second key
|
||||
* @param mixed $value The values to set
|
||||
*
|
||||
* @return void
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function set_(string $firstKey, string $secondKey, $value)
|
||||
{
|
||||
$this->_active[$this->firstKey($firstKey)]
|
||||
[$this->secondKey($secondKey)] = $value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get dynamic content
|
||||
*
|
||||
* @param string $firstKey The first key
|
||||
* @param string|null $secondKey The second key
|
||||
*
|
||||
* @return mixed
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function get_(string $firstKey, ?string $secondKey = null)
|
||||
{
|
||||
if (is_string($secondKey))
|
||||
{
|
||||
return $this->_active[$this->firstKey($firstKey)]
|
||||
[$this->secondKey($secondKey)] ?? null;
|
||||
}
|
||||
return $this->_active[$this->firstKey($firstKey)] ?? null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Does keys exist
|
||||
*
|
||||
* @param string $firstKey The first key
|
||||
* @param string|null $secondKey The second key
|
||||
*
|
||||
* @return bool
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function exist_(string $firstKey, ?string $secondKey = null): bool
|
||||
{
|
||||
if (is_string($secondKey) && isset($this->_active[$this->firstKey($firstKey)]) &&
|
||||
isset($this->_active[$this->firstKey($firstKey)]
|
||||
[$this->secondKey($secondKey)]))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
elseif (is_null($secondKey) && isset($this->_active[$this->firstKey($firstKey)]))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add dynamic content
|
||||
*
|
||||
* @param string $firstKey The first key
|
||||
* @param string $secondKey The second key
|
||||
* @param mixed $value The values to set
|
||||
*
|
||||
* @return void
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function add_(string $firstKey, string $secondKey, $value)
|
||||
{
|
||||
if (isset($this->_active[$this->firstKey($firstKey)]) &&
|
||||
isset($this->_active[$this->firstKey($firstKey)]
|
||||
[$this->secondKey($secondKey)]))
|
||||
{
|
||||
$this->_active[$this->firstKey($firstKey)]
|
||||
[$this->secondKey($secondKey)] .= $value;
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->_active[$this->firstKey($firstKey)]
|
||||
[$this->secondKey($secondKey)] = $value;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove dynamic content
|
||||
*
|
||||
* @param string $firstKey The first key
|
||||
* @param string|null $secondKey The second key
|
||||
*
|
||||
* @return void
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function remove_(string $firstKey, ?string $secondKey = null)
|
||||
{
|
||||
if (is_string($secondKey))
|
||||
{
|
||||
unset($this->_active[$this->firstKey($firstKey)]
|
||||
[$this->secondKey($secondKey)]);
|
||||
}
|
||||
else
|
||||
{
|
||||
unset($this->_active[$this->firstKey($firstKey)]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Model the first key
|
||||
*
|
||||
* @param string $key The first key to model
|
||||
*
|
||||
* @return string
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract protected function firstKey(string $key): string;
|
||||
|
||||
/**
|
||||
* Model the second key
|
||||
*
|
||||
* @param string $key The second key to model
|
||||
*
|
||||
* @return string
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract protected function secondKey(string $key): string;
|
||||
}
|
||||
|
@ -0,0 +1,122 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 4th September, 2022
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
namespace VDM\Joomla\Componentbuilder\Abstraction;
|
||||
|
||||
|
||||
use VDM\Joomla\Componentbuilder\Interfaces\Mappersingleinterface;
|
||||
|
||||
|
||||
/**
|
||||
* Compiler Mapper Single
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract class MapperSingle implements Mappersingleinterface
|
||||
{
|
||||
|
||||
/**
|
||||
* The Content
|
||||
*
|
||||
* @var array
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public array $active = [];
|
||||
|
||||
/**
|
||||
* Set content
|
||||
*
|
||||
* @param string $key The main string key
|
||||
* @param mixed $value The values to set
|
||||
*
|
||||
* @return void
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function set(string $key, $value)
|
||||
{
|
||||
$this->active[$this->key($key)] = $value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get content
|
||||
*
|
||||
* @param string $key The main string key
|
||||
*
|
||||
* @return mixed
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function get(string $key)
|
||||
{
|
||||
return $this->active[$this->key($key)] ?? null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Does key exist
|
||||
*
|
||||
* @param string $key The main string key
|
||||
*
|
||||
* @return bool
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function exist(string $key): bool
|
||||
{
|
||||
if (isset($this->active[$this->key($key)]))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add content
|
||||
*
|
||||
* @param string $key The main string key
|
||||
* @param mixed $value The values to set
|
||||
*
|
||||
* @return void
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function add(string $key, $value)
|
||||
{
|
||||
if (isset($this->active[$this->key($key)]))
|
||||
{
|
||||
$this->active[$this->key($key)] .= $value;
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->active[$this->key($key)] = $value;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove content
|
||||
*
|
||||
* @param string $key The main string key
|
||||
*
|
||||
* @return void
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function remove(string $key)
|
||||
{
|
||||
unset($this->active[$this->key($key)]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Model the key
|
||||
*
|
||||
* @param string $key The key to model
|
||||
*
|
||||
* @return string
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract protected function key(string $key): string;
|
||||
}
|
||||
|
@ -2,25 +2,23 @@
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 3rd September, 2022
|
||||
* @created 4th September, 2022
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
namespace VDM\Joomla\Componentbuilder\Search;
|
||||
namespace VDM\Joomla\Componentbuilder\Abstraction;
|
||||
|
||||
|
||||
use VDM\Joomla\Utilities\StringHelper;
|
||||
use VDM\Joomla\Utilities\ArrayHelper;
|
||||
use VDM\Joomla\Componentbuilder\Search\Factory;
|
||||
use VDM\Joomla\Componentbuilder\Search\Config;
|
||||
use VDM\Joomla\Componentbuilder\Search\Table;
|
||||
use VDM\Joomla\Componentbuilder\Table;
|
||||
|
||||
|
||||
/**
|
||||
* Search Model
|
||||
* Our base Model
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
@ -34,14 +32,6 @@ abstract class Model
|
||||
*/
|
||||
protected array $last;
|
||||
|
||||
/**
|
||||
* Search Config
|
||||
*
|
||||
* @var Config
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Config $config;
|
||||
|
||||
/**
|
||||
* Search Table
|
||||
*
|
||||
@ -53,17 +43,28 @@ abstract class Model
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param Config|null $config The search config object.
|
||||
* @param Table|null $table The search table object.
|
||||
* @param Table $table The search table object.
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function __construct(?Config $config = null, ?Table $table = null)
|
||||
public function __construct(Table $table)
|
||||
{
|
||||
$this->config = $config ?: Factory::_('Config');
|
||||
$this->table = $table ?: Factory::_('Table');
|
||||
$this->table = $table;
|
||||
}
|
||||
|
||||
/**
|
||||
* Model the value
|
||||
* Example: $this->value(value, 'value_key', 'table_name');
|
||||
*
|
||||
* @param mixed $value The value to model
|
||||
* @param string $field The field key
|
||||
* @param string|null $table The table
|
||||
*
|
||||
* @return mixed
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract public function value($value, string $field, ?string $table = null);
|
||||
|
||||
/**
|
||||
* Model the values of an item
|
||||
* Example: $this->item('table_name', Object);
|
||||
@ -79,14 +80,14 @@ abstract class Model
|
||||
// set the table name
|
||||
if (empty($table))
|
||||
{
|
||||
$table = $this->config->table_name;
|
||||
$table = $this->getTable();
|
||||
}
|
||||
|
||||
// field counter
|
||||
$field_number = 0;
|
||||
|
||||
// check if this is a valid table
|
||||
if (($fields = $this->table->fields($table)) !== null)
|
||||
if (($fields = $this->getTableFields($table)) !== null)
|
||||
{
|
||||
foreach ($fields as $field)
|
||||
{
|
||||
@ -95,14 +96,13 @@ abstract class Model
|
||||
{
|
||||
$item->{$field} = $this->value($item->{$field}, $field, $table);
|
||||
|
||||
// remove empty values
|
||||
if (!StringHelper::check($item->{$field}) && !ArrayHelper::check($item->{$field}, true))
|
||||
if ($this->validate($item->{$field}))
|
||||
{
|
||||
unset($item->{$field});
|
||||
$field_number++;
|
||||
}
|
||||
else
|
||||
{
|
||||
$field_number++;
|
||||
unset($item->{$field});
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -135,7 +135,7 @@ abstract class Model
|
||||
// set the table name
|
||||
if (empty($table))
|
||||
{
|
||||
$table = $this->config->table_name;
|
||||
$table = $this->getTable();
|
||||
}
|
||||
|
||||
foreach ($items as $id => &$item)
|
||||
@ -175,7 +175,7 @@ abstract class Model
|
||||
// set the table name
|
||||
if (empty($table))
|
||||
{
|
||||
$table = $this->config->table_name;
|
||||
$table = $this->getTable();
|
||||
}
|
||||
|
||||
// check if this is a valid table
|
||||
@ -186,6 +186,48 @@ abstract class Model
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Validate the values (basic, override in child class)
|
||||
*
|
||||
* @param mixed $value The field value
|
||||
* @param string|null $field The field key
|
||||
* @param string|null $table The table
|
||||
*
|
||||
* @return bool
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected function validate(&$value, ?string $field = null, ?string $table = null): bool
|
||||
{
|
||||
// check values
|
||||
if (StringHelper::check($value) || ArrayHelper::check($value, true))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
// remove empty values
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the current active table's fields
|
||||
*
|
||||
* @param string $table The table
|
||||
*
|
||||
* @return array
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected function getTableFields(string $table): ?array
|
||||
{
|
||||
return $this->table->fields($table);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the current active table
|
||||
*
|
||||
* @return string
|
||||
* @since 3.2.0
|
||||
*/
|
||||
abstract protected function getTable(): string;
|
||||
|
||||
}
|
||||
|
@ -0,0 +1,545 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Component.Builder
|
||||
*
|
||||
* @created 4th September, 2022
|
||||
* @author Llewellyn van der Merwe <https://dev.vdm.io>
|
||||
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
|
||||
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
namespace VDM\Joomla\Componentbuilder\Compiler\Adminview;
|
||||
|
||||
|
||||
use Joomla\CMS\Factory;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Factory as Compiler;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Config;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Registry;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Interfaces\EventInterface;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Placeholder;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Customcode\Dispenser;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Customtabs;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Tabs;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Fields;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Historyadminview;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Permissions;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Conditions;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Relations;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Linkedviews;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Javascriptadminview;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Cssadminview;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Phpadminview;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Custombuttons;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Customimportscripts;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Ajaxadmin;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Customalias;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Sql;
|
||||
use VDM\Joomla\Componentbuilder\Compiler\Model\Mysqlsettings;
|
||||
use VDM\Joomla\Utilities\StringHelper;
|
||||
use VDM\Joomla\Utilities\JsonHelper;
|
||||
use VDM\Joomla\Utilities\ArrayHelper;
|
||||
|
||||
|
||||
/**
|
||||
* Admin View Data Class
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
class Data
|
||||
{
|
||||
/**
|
||||
* Admin views
|
||||
*
|
||||
* @var array
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected array $data;
|
||||
|
||||
/**
|
||||
* Compiler Config
|
||||
*
|
||||
* @var Config
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Config $config;
|
||||
|
||||
/**
|
||||
* The compiler registry
|
||||
*
|
||||
* @var Registry
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Registry $registry;
|
||||
|
||||
/**
|
||||
* Compiler Event
|
||||
*
|
||||
* @var EventInterface
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected EventInterface $event;
|
||||
|
||||
/**
|
||||
* Compiler Placeholder
|
||||
*
|
||||
* @var Placeholder
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Placeholder $placeholder;
|
||||
|
||||
/**
|
||||
* Compiler Customcode Dispenser
|
||||
*
|
||||
* @var Dispenser
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Dispenser $dispenser;
|
||||
|
||||
/**
|
||||
* The modelling customtabs
|
||||
*
|
||||
* @var Customtabs
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Customtabs $customtabs;
|
||||
|
||||
/**
|
||||
* The modelling tabs
|
||||
*
|
||||
* @var Tabs
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Tabs $tabs;
|
||||
|
||||
/**
|
||||
* The modelling fields
|
||||
*
|
||||
* @var Fields
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Fields $fields;
|
||||
|
||||
/**
|
||||
* The modelling admin view history
|
||||
*
|
||||
* @var Historyadminview
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Historyadminview $history;
|
||||
|
||||
/**
|
||||
* The modelling permissions
|
||||
*
|
||||
* @var Permissions
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Permissions $permissions;
|
||||
|
||||
/**
|
||||
* The modelling conditions
|
||||
*
|
||||
* @var Conditions
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Conditions $conditions;
|
||||
|
||||
/**
|
||||
* The modelling relations
|
||||
*
|
||||
* @var Relations
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Relations $relations;
|
||||
|
||||
/**
|
||||
* The modelling linked views
|
||||
*
|
||||
* @var Linkedviews
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Linkedviews $linkedviews;
|
||||
|
||||
/**
|
||||
* The modelling javascript
|
||||
*
|
||||
* @var Javascriptadminview
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Javascriptadminview $javascript;
|
||||
|
||||
/**
|
||||
* The modelling css
|
||||
*
|
||||
* @var Cssadminview
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Cssadminview $css;
|
||||
|
||||
/**
|
||||
* The modelling php admin view
|
||||
*
|
||||
* @var Phpadminview
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Phpadminview $php;
|
||||
|
||||
/**
|
||||
* The modelling custom buttons
|
||||
*
|
||||
* @var Custombuttons
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Custombuttons $custombuttons;
|
||||
|
||||
/**
|
||||
* The modelling custom import scripts
|
||||
*
|
||||
* @var Customimportscripts
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Customimportscripts $customimportscripts;
|
||||
|
||||
/**
|
||||
* The modelling ajax
|
||||
*
|
||||
* @var Ajaxadmin
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Ajaxadmin $ajax;
|
||||
|
||||
/**
|
||||
* The modelling custom alias
|
||||
*
|
||||
* @var Customalias
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Customalias $customalias;
|
||||
|
||||
/**
|
||||
* The modelling sql
|
||||
*
|
||||
* @var Sql
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Sql $sql;
|
||||
|
||||
/**
|
||||
* The modelling mysql settings
|
||||
*
|
||||
* @var Mysqlsettings
|
||||
* @since 3.2.0
|
||||
*/
|
||||
protected Mysqlsettings $mysqlsettings;
|
||||
|
||||
/**
|
||||
* Database object to query local DB
|
||||
*
|
||||
* @var \JDatabaseDriver
|
||||
* @since 3.2.0
|
||||
**/
|
||||
protected \JDatabaseDriver $db;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param Config|null $config The compiler config object.
|
||||
* @param Registry|null $registry The compiler registry object.
|
||||
* @param EventInterface|null $event The compiler event api object.
|
||||
* @param Placeholder|null $placeholder The compiler placeholder object.
|
||||
* @param Dispenser|null $dispenser The compiler customcode dispenser object.
|
||||
* @param Customtabs|null $customtabs The modelling customtabs object.
|
||||
* @param Tabs|null $tabs The modelling tabs object.
|
||||
* @param Fields|null $fields The modelling fields object.
|
||||
* @param Historyadminview|null $history The modelling admin view history object.
|
||||
* @param Permissions|null $permissions The modelling permissions object.
|
||||
* @param Conditions|null $conditions The modelling conditions object.
|
||||
* @param Relations|null $relations The modelling relations object.
|
||||
* @param Linkedviews|null $linkedviews The modelling linked views object.
|
||||
* @param Javascriptadminview|null $javascript The modelling javascript object.
|
||||
* @param Cssadminview|null $css The modelling css object.
|
||||
* @param Phpadminview|null $php The modelling php admin view object.
|
||||
* @param Custombuttons|null $custombuttons The modelling custom buttons object.
|
||||
* @param Customimportscripts|null $customimportscripts The modelling custom import scripts object.
|
||||
* @param Ajaxadmin|null $ajax The modelling ajax object.
|
||||
* @param Customalias|null $customalias The modelling custom alias object.
|
||||
* @param Sql|null $sql The modelling sql object.
|
||||
* @param Mysqlsettings|null $mysqlsettings The modelling mysql settings object.
|
||||
* @param \JDatabaseDriver|null $db The database object.
|
||||
*
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function __construct(?Config $config = null, ?Registry $registry = null,
|
||||
?EventInterface $event = null, ?Placeholder $placeholder = null, ?Dispenser $dispenser = null,
|
||||
?Customtabs $customtabs = null, ?Tabs $tabs = null, ?Fields $fields = null,
|
||||
?Historyadminview $history = null, ?Permissions $permissions = null,
|
||||
?Conditions $conditions = null, Relations $relations = null, ?Linkedviews $linkedviews = null,
|
||||
?Javascriptadminview $javascript = null, ?Cssadminview $css = null, ?Phpadminview $php = null,
|
||||
?Custombuttons $custombuttons = null, ?Customimportscripts $customimportscripts = null,
|
||||
?Ajaxadmin $ajax = null, ?Customalias $customalias = null, ?Sql $sql = null,
|
||||
?Mysqlsettings $mysqlsettings = null, ?\JDatabaseDriver $db = null)
|
||||
{
|
||||
$this->config = $config ?: Compiler::_('Config');
|
||||
$this->registry = $registry ?: Compiler::_('Registry');
|
||||
$this->event = $event ?: Compiler::_('Event');
|
||||
$this->placeholder = $placeholder ?: Compiler::_('Placeholder');
|
||||
$this->dispenser = $dispenser ?: Compiler::_('Customcode.Dispenser');
|
||||
$this->customtabs = $customtabs ?: Compiler::_('Model.Customtabs');
|
||||
$this->tabs = $tabs ?: Compiler::_('Model.Tabs');
|
||||
$this->fields = $fields ?: Compiler::_('Model.Fields');
|
||||
$this->history = $history ?: Compiler::_('Model.Historyadminview');
|
||||
$this->permissions = $permissions ?: Compiler::_('Model.Permissions');
|
||||
$this->conditions = $conditions ?: Compiler::_('Model.Conditions');
|
||||
$this->relations = $relations ?: Compiler::_('Model.Relations');
|
||||
$this->linkedviews = $linkedviews ?: Compiler::_('Model.Linkedviews');
|
||||
$this->javascript = $javascript ?: Compiler::_('Model.Javascriptadminview');
|
||||
$this->css = $css ?: Compiler::_('Model.Cssadminview');
|
||||
$this->php = $php ?: Compiler::_('Model.Phpadminview');
|
||||
$this->custombuttons = $custombuttons ?: Compiler::_('Model.Custombuttons');
|
||||
$this->customimportscripts = $customimportscripts ?: Compiler::_('Model.Customimportscripts');
|
||||
$this->ajax = $ajax ?: Compiler::_('Model.Ajaxadmin');
|
||||
$this->customalias = $customalias ?: Compiler::_('Model.Customalias');
|
||||
$this->sql = $sql ?: Compiler::_('Model.Sql');
|
||||
$this->mysqlsettings = $mysqlsettings ?: Compiler::_('Model.Mysqlsettings');
|
||||
$this->db = $db ?: Factory::getDbo();
|
||||
}
|
||||
|
||||
/**
|
||||
* Get Admin View Data
|
||||
*
|
||||
* @param int $id The view ID
|
||||
*
|
||||
* @return object|null The view data
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public function get(int $id): ?object
|
||||
{
|
||||
if (!isset($this->data[$id]))
|
||||
{
|
||||
// Create a new query object.
|
||||
$query = $this->db->getQuery(true);
|
||||
|
||||
$query->select('a.*');
|
||||
$query->select(
|
||||
$this->db->quoteName(
|
||||
array(
|
||||
'b.addfields',
|
||||
'b.id',
|
||||
'c.addconditions',
|
||||
'c.id',
|
||||
'r.addrelations',
|
||||
't.tabs'
|
||||
), array(
|
||||
'addfields',
|
||||
'addfields_id',
|
||||
'addconditions',
|
||||
'addconditions_id',
|
||||
'addrelations',
|
||||
'customtabs'
|
||||
)
|
||||
)
|
||||
);
|
||||
|
||||
$query->from('#__componentbuilder_admin_view AS a');
|
||||
$query->join(
|
||||
'LEFT',
|
||||
$this->db->quoteName('#__componentbuilder_admin_fields', 'b')
|
||||
. ' ON (' . $this->db->quoteName('a.id') . ' = '
|
||||
. $this->db->quoteName('b.admin_view') . ')'
|
||||
);
|
||||
|
||||
$query->join(
|
||||
'LEFT', $this->db->quoteName(
|
||||
'#__componentbuilder_admin_fields_conditions', 'c'
|
||||
) . ' ON (' . $this->db->quoteName('a.id') . ' = '
|
||||
. $this->db->quoteName('c.admin_view') . ')'
|
||||
);
|
||||
|
||||
$query->join(
|
||||
'LEFT', $this->db->quoteName(
|
||||
'#__componentbuilder_admin_fields_relations', 'r'
|
||||
) . ' ON (' . $this->db->quoteName('a.id') . ' = '
|
||||
. $this->db->quoteName('r.admin_view') . ')'
|
||||
);
|
||||
|
||||
$query->join(
|
||||
'LEFT', $this->db->quoteName(
|
||||
'#__componentbuilder_admin_custom_tabs', 't'
|
||||
) . ' ON (' . $this->db->quoteName('a.id') . ' = '
|
||||
. $this->db->quoteName('t.admin_view') . ')'
|
||||
);
|
||||
|
||||
$query->where($this->db->quoteName('a.id') . ' = ' . (int) $id);
|
||||
|
||||
// for plugin event TODO change event api signatures
|
||||
$component_context = $this->config->component_context;
|
||||
// Trigger Event: jcb_ce_onBeforeQueryViewData
|
||||
$this->event->trigger(
|
||||
'jcb_ce_onBeforeQueryViewData',
|
||||
array(&$component_context, &$id, &$query, &$this->db)
|
||||
);
|
||||
|
||||
// Reset the query using our newly populated query object.
|
||||
$this->db->setQuery($query);
|
||||
|
||||
// Load the results as a list of stdClass objects (see later for more options on retrieving data).
|
||||
$view = $this->db->loadObject();
|
||||
|
||||
// setup single view code names to use in storing the data
|
||||
$view->name_single_code = 'oops_hmm_' . $id;
|
||||
if (isset($view->name_single) && $view->name_single != 'null')
|
||||
{
|
||||
$view->name_single_code = StringHelper::safe(
|
||||
$view->name_single
|
||||
);
|
||||
}
|
||||
|
||||
// setup list view code name to use in storing the data
|
||||
$view->name_list_code = 'oops_hmmm_' . $id;
|
||||
if (isset($view->name_list) && $view->name_list != 'null')
|
||||
{
|
||||
$view->name_list_code = StringHelper::safe(
|
||||
$view->name_list
|
||||
);
|
||||
}
|
||||
|
||||
// check the length of the view name (+5 for com_ and _)
|
||||
$name_length = $this->config->component_code_name_length + strlen(
|
||||
(string) $view->name_single_code
|
||||
) + 5;
|
||||
// when the name is larger than 49 we need to add the assets' table name fix
|
||||
if ($name_length > 49)
|
||||
{
|
||||
$this->config->set('add_assets_table_name_fix', true);
|
||||
}
|
||||
|
||||
// setup token check
|
||||
if (!isset($this->dispenser->hub['token']))
|
||||
{
|
||||
$this->dispenser->hub['token'] = [];
|
||||
}
|
||||
$this->dispenser->hub['token'][$view->name_single_code] = false;
|
||||
$this->dispenser->hub['token'][$view->name_list_code] = false;
|
||||
|
||||
// set some placeholders
|
||||
$this->placeholder->set('view', $view->name_single_code);
|
||||
$this->placeholder->set('views', $view->name_list_code);
|
||||
$this->placeholder->set('View', StringHelper::safe(
|
||||
$view->name_single, 'F'
|
||||
));
|
||||
$this->placeholder->set('Views', StringHelper::safe(
|
||||
$view->name_list, 'F'
|
||||
));
|
||||
$this->placeholder->set('VIEW', StringHelper::safe(
|
||||
$view->name_single, 'U'
|
||||
));
|
||||
$this->placeholder->set('VIEWS', StringHelper::safe(
|
||||
$view->name_list, 'U'
|
||||
));
|
||||
|
||||
// for plugin event TODO change event api signatures
|
||||
$placeholders = $this->placeholder->active;
|
||||
$component_context = $this->config->component_context;
|
||||
|
||||
// Trigger Event: jcb_ce_onBeforeModelViewData
|
||||
$this->event->trigger(
|
||||
'jcb_ce_onBeforeModelViewData',
|
||||
array(&$component_context, &$view, &$placeholders)
|
||||
);
|
||||
unset($placeholders);
|
||||
|
||||
// add the tables
|
||||
$view->addtables = (isset($view->addtables)
|
||||
&& JsonHelper::check($view->addtables))
|
||||
? json_decode((string) $view->addtables, true) : null;
|
||||
if (ArrayHelper::check($view->addtables))
|
||||
{
|
||||
$view->tables = array_values($view->addtables);
|
||||
}
|
||||
unset($view->addtables);
|
||||
|
||||
// set custom tabs
|
||||
$this->customtabs->set($view);
|
||||
|
||||
// set the local tabs
|
||||
$this->tabs->set($view);
|
||||
|
||||
// set permissions
|
||||
$this->permissions->set($view);
|
||||
|
||||
// set fields
|
||||
$this->fields->set($view);
|
||||
|
||||
// build update SQL
|
||||
$this->history->set($view);
|
||||
|
||||
// set the conditions
|
||||
$this->conditions->set($view);
|
||||
|
||||
// set the relations
|
||||
$this->relations->set($view);
|
||||
|
||||
// set linked views
|
||||
$this->linkedviews->set($view);
|
||||
|
||||
// set the lang target
|
||||
$this->config->lang_target = 'admin';
|
||||
if ($this->registry->get('builder.site_edit_view.' . $id, false))
|
||||
{
|
||||
$this->config->lang_target = 'both';
|
||||
}
|
||||
|
||||
// set javascript
|
||||
$this->javascript->set($view);
|
||||
|
||||
// set css
|
||||
$this->css->set($view);
|
||||
|
||||
// set php
|
||||
$this->php->set($view);
|
||||
|
||||
// set custom buttons
|
||||
$this->custombuttons->set($view);
|
||||
|
||||
// set custom import scripts
|
||||
$this->customimportscripts->set($view);
|
||||
|
||||
// set Ajax for this view
|
||||
$this->ajax->set($view);
|
||||
|
||||
// activate alias builder
|
||||
$this->customalias->set($view);
|
||||
|
||||
// set sql
|
||||
$this->sql->set($view);
|
||||
|
||||
// set mySql Table Settings
|
||||
$this->mysqlsettings->set($view);
|
||||
|
||||
// for plugin event TODO change event api signatures
|
||||
$placeholders = $this->placeholder->active;
|
||||
|
||||
// Trigger Event: jcb_ce_onAfterModelViewData
|
||||
$this->event->trigger(
|
||||
'jcb_ce_onAfterModelViewData',
|
||||
array(&$component_context, &$view, &$placeholders)
|
||||
);
|
||||
|
||||
// clear placeholders
|
||||
$this->placeholder->remove('view');
|
||||
$this->placeholder->remove('views');
|
||||
$this->placeholder->remove('View');
|
||||
$this->placeholder->remove('Views');
|
||||
$this->placeholder->remove('VIEW');
|
||||
$this->placeholder->remove('VIEWS');
|
||||
|
||||
// store this view to class object
|
||||
$this->data[$id] = $view;
|
||||
}
|
||||
|
||||
// return the found view data
|
||||
return $this->data[$id];
|
||||
}
|
||||
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user