Updated 004 General Planning (markdown)

Amigo 2019-05-20 16:35:44 +02:00
parent ad92576890
commit c45440f116
1 changed files with 8 additions and 0 deletions

@ -2,12 +2,20 @@
When you want to build a component in Component Builder you need to be prepared. You would need to know what to build and what the database structure is that you want to set up. If you want a good understanding of the table and of the database and how to have it mapped, these are essential things you need to know. If you do not know that, I can give you pointers on some of the things you will need. At the same time, I will try to explain why you need to know these things.
### Use Demo Components How To Build. Back End Views Connected To Database.
We are using Sermon Distributor, which is a component that I have developed for Distributing Sermons. [00:00:58](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h00m58s) Use the demo component that are demonstrating how to build components. You need to know what you are going to call it. (This one is called Sermon Distributor.) You would need to know back end views.[00:01:19](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h01m19s) The back end views in Joomla must be tightly connected to the database. [00:01:37](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h01m37s)
### Purpose Of Conventions - Adds Up Implementation
By illustrating the best convention of implementation, Component Builder will allow you to break these conventions, but later you would regret doing so and possibly have to redo a lot of things. [00:01:51](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h01m51s) The purpose of these conventions are to add up implementation in other areas, like your custom field types and so forth.
### Back End Views Need To Be Set Up
When Sermon Distributor is going to be build, [00:02:20](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h02m20s) back end views need to be set up, because we want these features inside the component. That is the sermons. We have a list view [00:02:33](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h02m33s) of the sermons as well as an editing view of the sermons. They share a common database table [00:02:51](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h02m51s) although they represent two views: a list view and an edit view. [00:03:27](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h03m27s) The editable view is in relation to the back end connection of the database itself. The back end usually forms the connection to the database. The front end is more dynamic. These things will take quite a lot of explanation if you are new to coding, PHP, JavaScript and CSS. [00:04:21](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h04m21s)
### Drawing Data From Dynamic Get Feature In Component Builder.
The site views and custom back end views are mostly the same kind of implementation, both drawing their data from the Dynamic Get feature in Component Builder. Think of these three as working as a team, while the back end views stand as the database for these. You need to set these up first. Add them to all the necessary fields that will then be mapped to the database [00:05:16](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h05m16s) columns, which then through the Dynamic Get connect to formulate a data model. This can be reused in your custom back end and in your site views.
Back end views are very tightly connected to database structures. If you look at Component Builder itself, you have what is called components, and if you open one, it has fields in it. If you want to go to the database, [00:06:02](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m02s) and open Component Builder, you would see the fields there. All these names [00:06:31](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m31s) are actually mapping directly into the database. These names are alphabetical. They directly map to the database and is in a way editing the database through this view. When it comes to the components, your back end views are all being limited to this kind of structure, and is not a limitation on Component Builder's behalf. It is the way Joomla [00:07:13](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h07m13s) wants to implement it. Your class, your model, your controllers, and everything else behave correctly because of that implementation, even if it is a major limitation. If you want to go beyond that kind of infrastructure you would probably need to look at another way of using Component Builder. We only implemented it this way so that your back end views direct maps to the database. We know that from time to time there are back end views that do not have their own database, but rather take saved information in the database, either from other third-party components or even your own component, because we know that you would like to take that information and remodel it into a spreadsheet, [00:08:17](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h08m17s) a chart, or any other kind of way. We added this custom back end views which behave on the same dynamics as the site views. We are trying to give you the best of both worlds. First by being that strong tightening manage data sets, which relates directly to the view and the list view and so forth. Then at the same time giving the option of adding a custom back end view, which can be dynamic and in which you can do custom scripting. [00:09:08](https://www.youtube.com/watch?v=gEgwiVNj6N0&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h09m08s)