Updated 5. Field Types (markdown)

Joseph Geller
2018-11-23 15:56:43 -06:00
parent b1d4c188f6
commit d3ec1c8058

@@ -1,16 +1,13 @@
# [Video](https://youtu.be/OhLzvThDXls?list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE)
If you have a good knowledge of the Joomla! API You will know it can build forms you can use in a component and it's done using an XML file. Joomla! Component Bolder builds the XML file and places it in a location a model, view and controller can access it from using the Joomla! API. JCB builds the fields which you define would use in a view using a view containing fields displayed by the component. These and other terms will be defined as we proceed. Let's start start with what is known as field types.
+ [01:05](https://youtu.be/OhLzvThDXls?list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=1m5s) **Field types** _Create Field Types Using basic joomla article to explain field types and their relationship within views_
There is always a field type needed if you are building a field. Use of field types can be seen when you create a Joomla! article. When you do the first thing you see is called a view. Scroll down a bit and you'll see a URL displaying the view View = article and it's called an article view.
If you have a good knowledge of the Joomla! API You will know it can build forms you can use in a component and it's done using an XML file. Joomla! Component Bolder builds the XML file and places it in a location a model, view and controller can access it from using the Joomla! API. JCB builds the fields which you define would use in a view using a view containing fields displayed by the component. These and other terms will be defined as we proceed. Let's start start with field types.
+ [01:57](https://youtu.be/OhLzvThDXls?list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=1m57s) **List view** _Difference between list view and edit view. Plural and single_
If you close this article view you'll see a list of articles created in the web site. You won't see any articles here if it's a blank website. The list of articles is also called a view. If you click on an row in the list you will see the edit or single view. Your components will usually have these two views in the admin area to list and edit your different data sets. Let's take a look at the views and the fields they display.
A field type is needed if you are building a field. Use of field types can be seen when you create a Joomla! article. When you do the first thing you see is called a view. Scroll down a bit and you'll see a URL displaying the view View = article and it's called an article view. If you close this article view you'll see a list of articles created in the web site. You won't see any articles here if it's a blank website. The list of articles is also called a view. If you click on an row in the list you will see the edit or single view. Your components will usually have these two views in the admin area to list and edit your different data sets. Let's take a look at the views and the fields they display.
The title is a text field type; the alias is also a text field type. The editor block is a text editor field. There are others like list, radio, tag, text, date, user, text-area, label. You will see these things are all in place in the application for you. Make use of each of these different types that can be applied to a field. All these fields live inside a view. That's an important concept to realize. All fields live in views. Now, you might not think that a list view has fields and you are partly right. It does more than just display these fields. Let's do a dummy test article here.
After adding some content, save and close the article so we at least have a list item. But that is also a field and if you click on search options all these are fields. So, your list also has certain fields which are inly available in the list view. This is also the place where we do most of our features for multiple items where opening one item does what's only required for one item. There is a table which is part of the list that Component Builder sets Up. The bucket list and edit views are built for you, based on the fields and input value mapped to them in your view. We will look at these other concepts more deeply but I need to have you understand from which angle we are coming. We will try and show you that inside of this article you will be creating fields, even put them into different tabs, which will have been rendered in a specific order by the Joomla! component after it's been compiled using Component Builder. That's using Joomla!'s Article Manager as sort of an example.
+ [05:45](https://youtu.be/OhLzvThDXls?list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=5m45s) **Compile error** _Remember to select correct options that suit your build._
We could just as well go into Component Builder Since it has the demo application. See a detailed explanation of the demo component and building a local developer environment to run it. After selecting the demo Compile, it displays a warning because we haven't set some options in the global settings. It doesn't mean that there's been an error in the compiling. It just means it couldn't move the file to the git repository. If we deselect some compile options and start again it doesn't give you the same warning. Click install and compiled component gets installed Into this Joomla site. It doesn't have any images because that we don't ship the images with the components. It's easy to use your own.