Updated 044 Hello World Component with Joomla Component Builder Creator Extended (markdown)
parent
1f04b9c4e3
commit
97cf900475
@ -135,25 +135,32 @@ The first field that we are going to create is a Text field, which we will call
|
|||||||
|
|
||||||
[00:22:19](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h22m19s)
|
[00:22:19](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h22m19s)
|
||||||
|
|
||||||
Now in regards to the Database, that is what these features are all about. Since Text Fields can differ, not all of them are going to be this size. It is up to you to decide what kind of Text Field this is going to be. A bit more knowledge about MySQL and Databases is necessary to effectively use this. [00:22:49](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h22m49s) If you do not know what would be the best for a Text Field or a Date Field, Google that or simply look at Joomla's own implementation. It has an article Manager, and you can go into its XML Database and look at what Database Values was used and just use the same whatever be the case.[00:23:14](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h23m14s) Because these values are all movable, and by setting them wrong, could break things. Having created our first field, we can reuse Name and maybe also Description. [00:24:23](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h24m23s) Those are part of the Demo Component. Since Fields can be linked into any Admin View and therefore belong to any Component, it does not matter if it is already linked to the Demo Component . Although, if it is changed, it will affect both Components.<<<<<<<<<<<<<<<
|
Now in regards to the Database, that is what these features are all about. Since Text Fields can differ, not all of them are going to be this size. It is up to you to decide what kind of Text Field this is going to be. A bit more knowledge about MySQL and Databases is necessary to effectively use this. [00:22:49](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h22m49s) If you do not know what would be the best for a Text Field or a Date Field, Google that or simply look at Joomla's own implementation. It has an article Manager, and you can go into its XML Database and look at what Database Values was used and just use the same whatever be the case.[00:23:14](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h23m14s) Because these values are all movable, and by setting them wrong, could break things. Having created our first field, we can reuse Name and maybe also Description. [00:24:23](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h24m23s) Those are part of the Demo Component. Since Fields can be linked into any Admin View and therefore belong to any Component, it does not matter if it is already linked to the Demo Component . Although, if it is changed, it will affect both Components.
|
||||||
|
|
||||||
### Creating a Admin View - Need To Do Some Preparations Before Doing Admin Views
|
### Creating a Admin View - Need To Do Some Preparations Before Doing Admin Views
|
||||||
|
|
||||||
[00:24:46](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h24m46s)
|
[00:24:46](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h24m46s)
|
||||||
|
|
||||||
Having created our Fieldtypes and also a Field, let's create an Admin View. Admin Views is the back end of the Component. There is a whole lot of tutorials around the web about Object Orientated Development to give some perspective into the; How should it work? What should be where? What should have its own classes? What should have it own tables? Where we going to put what? All this preparation should be done before coming to JCB. Once you have all that planned, only then it is possible to create Fields, create Admin Views, which is your Tables which can be linked to a Component. Once that has been done>>>>> [00:25:53](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h25m53s) you've laid the foundation of your application. You can start working on what will make it unique and special which is the front end.
|
Having created our Fieldtypes and also a Field, let's create an Admin View. Admin Views is the back end of the Component. There is a whole lot of tutorials around the web about Object Orientated Development to give some perspective into the; How should it work? What should be where? What should have its own classes? What should have it own tables? Where we going to put what? All this preparation should be done before coming to JCB. Once you have all that planned, only then it is possible to create Fields, create Admin Views, which is your Tables which can be linked to a Component. Once that has been done, the foundation is laid of your application. [00:25:53](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h25m53s) Now you can start to work on that which will make the front end unique.
|
||||||
|
|
||||||
### Creating Admin Views
|
### Creating Admin Views
|
||||||
|
|
||||||
[00:26:02](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h26m02s)
|
[00:26:02](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h26m02s)
|
||||||
|
|
||||||
First Admin View. The System Name is for you to identify the View. If there be more than one View with the name greetings. Let's say you've built quite a few components that deals with Hello World, [00:26:21](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h26m21s) and you got three or four different variations of greetings. You might want to say this is the first one. By doing that it's identifiable within the drop down list across your application of JCB. You'll see that when we would later select the greeting that the System Name is used in the drop down list.
|
First Admin View. The System Name is to identify the View. If there be more than one View with the name greetings. For example: If you have build quite a few components that deals with Hello World, and have three or four different variations of greetings and say this is the first one.(See video) [00:26:21](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h26m21s) By doing that it is identifiable within the drop down list across your application of JCB. It will be seen when the greeting is later selected, that the System Name is used in the drop down list.
|
||||||
|
|
||||||
### Name (single record), Name (list of records)
|
### Name (single record), Name (list of records)
|
||||||
|
|
||||||
[00:26:48](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h26m48s)
|
[00:26:48](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h26m48s)
|
||||||
|
|
||||||
We're going to have a single record and a list records. Single record is also what we understand as the Edit View. That's when you are looking at one record, and you are editing that record in the Admin area, that's the single record. That's also what will be used when you tweak JCB to add an Edit option to the Site area of your Website. Since JCB can do that for you [00:27:22](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h27m22s) on the fly, this single record would also affect the front end of your component in that case. Which we will show and demonstrate as we go along. I'm just going to call the single record Greeting and the list record Greetings.
|
There will be a 'Name(single record)' and a 'Name(list records)'. Single record is also the Edit View. That is when you are looking at one record, and are editing that record in the Admin area, that is the single record. That is also what will be used when you tweak JCB to add an Edit option to the Site area of your Website. [00:27:22](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h27m22s) Since JCB can do that on the fly, this single record would also affect the front end of your component in that case which will be demonstrated later on . I am going to call the single record 'Greeting' and the list record 'Greetings'. <<<<<<<<<<<<<<<<<<<<<<
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Type: Read And Write
|
### Type: Read And Write
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user