Updated 013 dynamicGet (markdown)
parent
0e20d72114
commit
102b18ed37
@ -2,21 +2,23 @@
|
|||||||
|
|
||||||
### Sermon - Preacher Get Example
|
### Sermon - Preacher Get Example
|
||||||
|
|
||||||
We are still working with Sermon Distributor and is going to use Preacher, which is a 'get' that I already have set up as illustration. Here we have 'Back-end view' selected.[00:00:25](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h00m25s) For example: Let me select nothing. This is usually how it will look when you start. You would select this, (depending on which [00:00:39](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h00m39s) area of the back end you want to get the data from) you would select back end view. Which is the best way to do it.
|
We are still working with Sermon Distributor; we are going to use Preacher, a 'get' I've already set up as an illustration. Here we have 'Back-end view' selected. (See video.) [00:00:25](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h00m25s) For example: Select nothing. This is how it will usually look when you start. Select this, (depending on which area of the back end you want to get the data from) and select back end view. That is the best way to do it. [00:00:39](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h00m39s)
|
||||||
|
|
||||||
### Dynamic Get Source Selection
|
### Dynamic Get Source Selection
|
||||||
|
|
||||||
Then there is the Joomla database option which gives you the access to draw data from any other component installed that moment in the Joomla Website. [00:01:01](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h01m01s) If you select your Joomla database, you can select any database that is actually at that stage on your database installed. Which means that you can reach out to other components through this dynamic get. I'm not going to do that. [00:01:21](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h01m21s) In fact that's also an area which I haven't tested so well. You possibly might try to implement that and ran into some trouble. At this stage it is better instead, to use the 'Back-end view' option. [00:01:42](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h01m42s) The reason that the other option is there is because we certainly want that feature in the application while work is meanwhile been done to improve it. For most part, if not very complex mapping is done, like if you do a simple direct database fetch like 'cb_associations', you will be able to use this, there will not be any complications. [00:02:09](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h02m09s) What make it complex is these other linked or joint database structures. I haven't tested it yet as I have done with this back-end view. [00:02:32](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h02m32s)
|
The Joomla database option gives you the access to draw data from any other component installed that moment in the Joomla Website. [00:01:01](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h01m01s) If you select your Joomla database, you can select any database that is installed on your database at the stage. This means that you can reach out to other components through this dynamic get. [00:01:21](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h01m21s)
|
||||||
|
|
||||||
There is also the 'Custom' option to use Component Builder to write your PHP for you. At'custom Get' you can add custom PHP, that will add the methods data for you. This is a 'custom get' option where you write the code [00:02:55](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h02m55s) by hand. Where as this'Custom - dropdown' option writes the code for you. You need to select the Back-end view that you want to use. That Back-end view will be the view that you connect to your component. You need to type your name in here, and then select that package, and it will load [00:03:20](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h03m20s) all the field names, like 'a.id', 'a.asset', 'id', 'a.name', 'allias', and 'icon'.
|
This is an area that I haven't tested well yet. You might try to implement it and tun into some trouble. For now it is better to use the 'Back-end view' option. [00:01:42](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h01m42s) The other option is there is because we want the feature in the application even while we are still working to improve it. If not very complex mapping is done (for instance, if you do a simple direct database fetch like 'cb_associations') you will be able to use this and there won't be any complications. [00:02:09](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h02m09s) These other linked or joint database structures makes it complicated. [00:02:32](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h02m32s)
|
||||||
|
|
||||||
|
There is also the 'Custom' option, using Component Builder to write your PHP for you. At 'custom Get' you can add custom PHP, that will add the methods data for you. This is a 'custom get' option where you write the code by hand whereas this 'Custom - dropdown' option writes the code for you. (See video.) [00:02:55](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h02m55s) Select the Back-end view that you want to use; it will be the view that you connect to your component. Type your name in here, select the package, and it will load all the field names. [00:03:20](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h03m20s)
|
||||||
|
|
||||||
### Dynamic Get Preacher View
|
### Dynamic Get Preacher View
|
||||||
|
|
||||||
These are all the fields inside of this'Preacher' view. I will load it and I'll put this as 'asset_id'.(See video) It is suggested that you don't change that. You can take out a row. [00:03:50](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h03m50s) You can remove a row if it is not needed. What remains is all the data you might want. You will know that this would be the variable name of the data when this get is used. [00:04:13](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h04m13s) That is the basic part of setting up a Get.
|
These are the fields inside of the 'Preacher' view. Load it and place this as 'asset_id'.(See video) It is suggested that you don't change that. [00:03:50](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h03m50s) You can remove a row if it is not needed, but what remains is the data you might want. This would be the variable name of the data when the get is used. [00:04:13](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h04m13s)
|
||||||
|
|
||||||
### Get Types - Get Item/List Get Custom
|
### Get Types - Get Item/List Get Custom
|
||||||
|
|
||||||
There are four getTypes . The 'getitem' which will get one item from this 'preacher' table then there is 'getlistquery' which will get multiple items. [00:04:41](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h04m41s) Depending on how many items you want to get from the database, you would select either 'getitem' or 'getlist'. Then you get 'getcustom', and then there is 'getcustoms', plural. The difference between these four is that the 'getitem' is what you will use only once per [00:05:04](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h05m04s) view. <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
|
There are four getTypes: 'getitem' which will get one item from the 'preacher' table and 'getlistquery' which will get multiple items. [00:04:41](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h04m41s) (Depending on how many items you want to get from the database, select either 'getitem' or 'getlist'.) Then 'getcustom' and 'getcustoms', plural. The difference between these four is that you will only use the 'getitem' once per view. [00:05:04](https://www.youtube.com/watch?v=OPuCoxPW35s&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h05m04s)<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user