Bug in the AppGiniFields inline command?

This sub-forum is for discussing all topics related to AppGini Helper JavaScript Library, provided by bizzworxx as a third-party AppGini plugin.
Post Reply
paulgai
Posts: 3
Joined: 2020-10-24 15:16
Contact:

Bug in the AppGiniFields inline command?

Post by paulgai » 2020-10-24 16:51

Hi,
I have a table with name Members and two fields, the field Name (Varchar) and the field Sex (Option Drop-down list with two choices, Male and Female). I use the following command in hooks/Member-dv.js file:

Code: Select all

$j(function(){  
     new AppGiniFields(["Name", "Sex"]).inline("Name", [6, 6]);
});
And I get the following result:
member.jpg
member.jpg (43.1 KiB) Viewed 1852 times
Is this a bug or I do something wrong?
Thank you.

User avatar
jsetzer
AppGini Super Hero
AppGini Super Hero
Posts: 1817
Joined: 2018-07-06 06:03
Location: Kiel, Germany
Contact:

Re: Bug in the AppGiniFields inline command?

Post by jsetzer » 2020-10-24 17:10

1) Which Version?
2) please check if you have initialized new AppGiniDetailView() more than once, for example in header-extras AND a 2nd time in TABLENAME-dv.js
You should initialize it once, only
3) any related warnings or errors in console?

If still problems, send zipped header-extras.php and your TN-dv.js by EMAIL (!) to appgini at bizzworxx dot de
Kind regards,
<js />

My AppGini Blog:
https://appgini.bizzworxx.de/blog

You can help us helping you:
Please always put code fragments inside [code]...[/code] blocks for better readability

AppGini 24.10 Revision 1579 + all AppGini Helper tools

paulgai
Posts: 3
Joined: 2020-10-24 15:16
Contact:

Re: Bug in the AppGiniFields inline command?

Post by paulgai » 2020-10-24 18:34

1) AppGini Version 5.84, AppGini Helper Javascript Library Version: 2020.04.30.7
2) I did not initialize new AppGiniDetailView(), I used only the above JavaScript code.
3) I do not get warnings or errors in console.
console.jpg
console.jpg (42.92 KiB) Viewed 1838 times
The problem seems to be related to the Drop-down list option field. I tried with two simple text fields and it works fine.
member2.jpg
member2.jpg (47.75 KiB) Viewed 1838 times
I emailed you the files.
Thank you

User avatar
jsetzer
AppGini Super Hero
AppGini Super Hero
Posts: 1817
Joined: 2018-07-06 06:03
Location: Kiel, Germany
Contact:

Re: Bug in the AppGiniFields inline command?

Post by jsetzer » 2020-10-25 10:12

I confirm this is a bug in current version.

Gonna fix it next week, hopefully.

And sorry @all for delay of upcoming 2020/10 version. I am trying to fix the bug reported here. It will take a few more days to finalize everything, test and publish the new version.
Kind regards,
<js />

My AppGini Blog:
https://appgini.bizzworxx.de/blog

You can help us helping you:
Please always put code fragments inside [code]...[/code] blocks for better readability

AppGini 24.10 Revision 1579 + all AppGini Helper tools

User avatar
jsetzer
AppGini Super Hero
AppGini Super Hero
Posts: 1817
Joined: 2018-07-06 06:03
Location: Kiel, Germany
Contact:

Re: Bug in the AppGiniFields inline command?

Post by jsetzer » 2020-10-25 11:03

Thanks for sending the files!

tl;dr

Code_QaUrGMz083.png
Code_QaUrGMz083.png (6.63 KiB) Viewed 1796 times

Solution
$j(function(){
new AppGiniFields(["Name", "Sex"]).inline("Name", [6, 6]);
});
The function call should NOT be inside document-ready.

see documentation here:
https://appgini.bizzworxx.de/products/j ... ne-fields/)

Just write the function call into your javascript file like this:

Code: Select all

// file: hooks/TABLENAME-dv.js
new AppGiniFields(["Name", "Sex"]).inline("Name", [6, 6]);

This gives pretty aligned controls and no duplicates:

chrome_L0DxatRnaO.png
chrome_L0DxatRnaO.png (7.48 KiB) Viewed 1796 times

Anyway, I am considering taking a closer look at this behavior, also in case others stumble upon the same problem.
Kind regards,
<js />

My AppGini Blog:
https://appgini.bizzworxx.de/blog

You can help us helping you:
Please always put code fragments inside [code]...[/code] blocks for better readability

AppGini 24.10 Revision 1579 + all AppGini Helper tools

paulgai
Posts: 3
Joined: 2020-10-24 15:16
Contact:

[SOLVED] Bug in the AppGiniFields inline command?

Post by paulgai » 2020-10-25 14:37

The problem solved.
Thanks!!

User avatar
jsetzer
AppGini Super Hero
AppGini Super Hero
Posts: 1817
Joined: 2018-07-06 06:03
Location: Kiel, Germany
Contact:

Re: Bug in the AppGiniFields inline command?

Post by jsetzer » 2020-12-18 14:12

Great! Glad it works as expected!
Kind regards,
<js />

My AppGini Blog:
https://appgini.bizzworxx.de/blog

You can help us helping you:
Please always put code fragments inside [code]...[/code] blocks for better readability

AppGini 24.10 Revision 1579 + all AppGini Helper tools

Post Reply