Admin View Linked Fields "Admin Behavior - Default" and add content to Joomla administration, data not visible in view #607

Closed
opened 2020-10-16 10:04:11 +00:00 by Dragonfuri · 2 comments
Dragonfuri commented 2020-10-16 10:04:11 +00:00 (Migrated from github.com)

Hi,

I have found something within the Admin View Linked Fields "Admin Behavior - Default" and add content to Joomla administration, data not visible in view

Steps to reproduce the issue

  1. Create admin view
  2. Go to tab fields
  3. Click edit "Linked Fields"
  4. Add two fields and check the desired checkbox. But leave the "Admin Behavior" Default.
    image
  5. Save & Close
  6. Link the Admin View to the component
  7. now compile the component and install it.
  8. Try to create a movie or something
  9. If you now click save the movie is saved. Now click save and close.
    image

Expected result

Admin View
"Here are my thoughts: By leaving the "Admin Behavior" fields "Default". I excepted that it will select a default behavior for example "Show in All list Views" and automatically provide an order "Order in List views" I don't see any changes here, also not after looking at it when saved.
But within Joomla it is perfectly in good condition.

Add content to joomla
The movie be added to joomla and shown in the list view.

Actual result

No items created within joomla and not shown in the list view. Also not searchable within Joomla
image

Looking at the MySQL database the movies are added
image

System information (as much as possible)

  • OS Name & Version: Windows NT 10.0 build 18363 (Windows 10) AMD64
  • MySql Version: 8.0.21
  • Apache Version: Apache/2.4.46 (Win64) PHP/7.3.21
  • PHP Version: 7.3.21
  • Joomla Version: 3.9.22
  • JCB Version: Version: 2.11.6 :Beta Release Date: 6th October, 2020
  • Browser: Chrome, internet explorer, edge

Additional comments

Workaround
For the Admin Behavior fields, select an option for example; Show in All list Views. Don't use "Default"
image

Expected solutions
Change the "default" value to "select a behavior view"
or
Code needed to be looked at, as it is working almost as expected

I have followed the demo and the important instructions from YouTube. Also tried to built a movie database myself by testing component builder step by step. Also to get a better understanding and feeling of JCB.

Sorry noticed Pull request instructions later and entered an issue here. As i thought this was really an issue.

Hi, I have found something within the Admin View Linked Fields "Admin Behavior - Default" and add content to Joomla administration, data not visible in view ### Steps to reproduce the issue 1. Create admin view 2. Go to tab fields 3. Click edit "Linked Fields" 4. Add two fields and check the desired checkbox. But leave the "Admin Behavior" Default. ![image](https://user-images.githubusercontent.com/16516719/96241619-b8887000-0fa2-11eb-9a19-d90677dc45f7.png) 5. Save & Close 6. Link the Admin View to the component 7. now compile the component and install it. 8. Try to create a movie or something 9. If you now click save the movie is saved. Now click save and close. ![image](https://user-images.githubusercontent.com/16516719/96242831-3731dd00-0fa4-11eb-9140-76e1ab805197.png) ### Expected result **Admin View** "Here are my thoughts: By leaving the "Admin Behavior" fields "Default". I excepted that it will select a default behavior for example "Show in All list Views" and automatically provide an order "Order in List views" I don't see any changes here, also not after looking at it when saved. But within Joomla it is perfectly in good condition. **Add content to joomla** The movie be added to joomla and shown in the list view. ### Actual result No items created within joomla and not shown in the list view. Also not searchable within Joomla ![image](https://user-images.githubusercontent.com/16516719/96242873-42850880-0fa4-11eb-8875-556e937a327e.png) Looking at the MySQL database the movies are added ![image](https://user-images.githubusercontent.com/16516719/96243489-1c139d00-0fa5-11eb-87c9-68bbcb0830a4.png) ### System information (as much as possible) - OS Name & Version: Windows NT 10.0 build 18363 (Windows 10) AMD64 - MySql Version: 8.0.21 - Apache Version: Apache/2.4.46 (Win64) PHP/7.3.21 - PHP Version: 7.3.21 - Joomla Version: 3.9.22 - JCB Version: Version: 2.11.6 :Beta Release Date: 6th October, 2020 - Browser: Chrome, internet explorer, edge ### Additional comments **Workaround** For the Admin Behavior fields, select an option for example; Show in All list Views. **Don't use "Default"** ![image](https://user-images.githubusercontent.com/16516719/96244417-53cf1480-0fa6-11eb-83a1-9559bb4c33ec.png) **Expected solutions** Change the "default" value to "select a behavior view" or Code needed to be looked at, as it is working almost as expected I have followed the demo and the important instructions from YouTube. Also tried to built a movie database myself by testing component builder step by step. Also to get a better understanding and feeling of JCB. Sorry noticed Pull request instructions later and entered an issue here. As i thought this was really an issue.

I am not sure how to answer you, since it seems like we have a few wires crossed here, and I can't in a few words make sure we are on the same page.

The field in question only relates to list views, meaning:
image

The default behavior is that it does not get linked to any list view, but is in the database, so that is exactly why selecting none of the fields will cause issues. So if we where to rename it, it will be Not Displayed in any List view but add to database which is to long really... so Default seemed simple enough. That said, I can see the wisdom of saying what default means.. so let me see... all field are originally added with Default selected, so we could change the column name to be more descriptive, like.... ahaaa I have no idea.

But just changing the word Default to select a behavior view will make it even more confusing as the field deals with both list view linking, and database linking. The first four options (Default, Show in All List Views, Only in Admin List View, Only in Linked List Views) are all going to link the field to the database, but only the second, third, and forth options (Show in All List Views, Only in Admin List View, Only in Linked List Views) will add the field in a list view.

The first option (Show in All List Views) of the list views will make sure the field gets added to all list views that could be build. The second option (Only in Admin List View) of the list views will make sure the field gets added to only a normal list view like seen above. The third option (Only in Linked List Views) of the list views will make sure the field is only shown when this admin view is linked into another admin view, via the linking system of JCB.
image

But all five options (Default, Show in All List Views, Only in Admin List View, Only in Linked List Views, None DB) will add the field in the edit form view.
image

Yet the last option (None DB) will not add it to the database nor to any list views. But this is in fact the advance option, as JCB has at field level the option to set how a field should be modeled:
image
image

Then there is also the field relationships option:
image
image

This allows for you to customize the list views of fields to combine them in one column, or to add even more modeling on a field before display... really a powerful area.

So yes we can do more to explain what default means... But I tend to get to technical and find it hard to explain things without making a video seeing that we are often faced with a very great deal of issue all bearing on each other. Having written this up her made me think that JCB needs a lot of work to make it user focused... as it was originally intended for private use only.

After reading all this what are your first thoughts that comes to mind? and how will this help solve this issue?

I am not sure how to answer you, since it seems like we have a few wires crossed here, and I can't in a few words make sure we are on the same page. The field in question only relates to list views, meaning: ![image](https://user-images.githubusercontent.com/5607939/96355410-b416a100-10e1-11eb-82e1-9c0cc164ec13.png) The default behavior is that it does not get linked to any list view, but is in the database, so that is exactly why selecting none of the fields will cause issues. So if we where to rename it, it will be `Not Displayed in any List view but add to database` which is to long really... so `Default` seemed simple enough. That said, I can see the wisdom of saying what default means.. so let me see... all field are originally added with `Default` selected, so we could change the column name to be more descriptive, like.... ahaaa I have no idea. But just changing the word `Default` to `select a behavior view` will make it even more confusing as the field deals with both list view linking, and database linking. The first four options _(Default, Show in All List Views, Only in Admin List View, Only in Linked List Views)_ are all going to link the field to the database, but only the second, third, and forth options _(Show in All List Views, Only in Admin List View, Only in Linked List Views)_ will add the field in a list view. The first option _(Show in All List Views)_ of the list views will make sure the field gets added to all list views that could be build. The second option _(Only in Admin List View)_ of the list views will make sure the field gets added to only a normal list view like seen above. The third option _(Only in Linked List Views)_ of the list views will make sure the field is only shown when this admin view is linked into another admin view, via the linking system of JCB. ![image](https://user-images.githubusercontent.com/5607939/96355652-2b4d3480-10e4-11eb-97e4-e321b8d9c402.png) But all five options _(Default, Show in All List Views, Only in Admin List View, Only in Linked List Views, None DB)_ will add the field in the edit form view. ![image](https://user-images.githubusercontent.com/5607939/96355664-546dc500-10e4-11eb-9bf1-1a5ca2207d4d.png) Yet the last option _(None DB)_ will not add it to the database nor to any list views. But this is in fact the advance option, as JCB has at field level the option to set how a field should be modeled: ![image](https://user-images.githubusercontent.com/5607939/96355690-97c83380-10e4-11eb-869e-fdac6896a680.png) ![image](https://user-images.githubusercontent.com/5607939/96355693-9eef4180-10e4-11eb-9987-14d350a6f7d3.png) Then there is also the field relationships option: ![image](https://user-images.githubusercontent.com/5607939/96355700-bdedd380-10e4-11eb-9ed2-5c0e5bf22612.png) ![image](https://user-images.githubusercontent.com/5607939/96355702-c940ff00-10e4-11eb-9a86-b19e4308ae85.png) This allows for you to customize the list views of fields to combine them in one column, or to add even more modeling on a field before display... really a powerful area. So yes we can do more to explain what default means... But I tend to get to technical and find it hard to explain things without making a video seeing that we are often faced with a very great deal of issue all bearing on each other. Having written this up her made me think that JCB needs a lot of work to make it user focused... as it was originally intended for private use only. After reading all this what are your first thoughts that comes to mind? and how will this help solve this issue?

Let me know if you have any further questions.

Let me know if you have any further questions.
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: joomla/Component-Builder#607
No description provided.