Page 1 of 1
label spacing bug
Posted: 2020-08-05 20:54
by SkayyHH
Hello,
a little bug report. Labels have a different spacing for look-ups than for lists.
http://managersystem.de/!/2020-08-05_224351.png
Best regards, Kai
Re: label spacing bug
Posted: 2020-08-05 21:24
by jsetzer
Hi,
question: is this a multi-column layout according to the docs here?
https://appgini.bizzworxx.de/products/j ... mn-layout/
If yes, I am wondering where the left-aligned labels come from, ...

- chrome_xCbPbqiNVM.png (64.84 KiB) Viewed 5832 times
... as the default multi-column-layout does NOT wrap labels on medium or large displays:

- chrome_Y0mrRZJWIV.png (29.76 KiB) Viewed 5832 times
Howewer, you can check the css style and adjust bottom margin the way you like. But I guess this is not a problem of label-margin but a problem of different control-heights.

- chrome_fGBF9hXRJx.png (238.73 KiB) Viewed 5832 times
Aditionally, there was another thread related to layout here:
viewtopic.php?f=13&t=3515&p=12669&hilit=layout#p12669
Maybe this helps.
And there is a how-to which might also help:
https://appgini.bizzworxx.de/appgini/ho ... -inlining/
Regards,
Jan
Re: label spacing bug
Posted: 2020-08-05 21:34
by SkayyHH
Hello Jan,
thanks very much. Yes, i tried .wrapLabels(); in multi-column-layout

- what works.
It would work with the dropdown fix, but then the field has a delay in loading the page.
Please have also a look at text fields in tabs (html). they have no height.
It would also be great if I could not just put fields above or below tabs, but both at the same time.
Best regards, Kai
Re: label spacing bug
Posted: 2020-08-16 19:25
by jsetzer
It would also be great if I could not just put fields above or below tabs, but both at the same time.
The custom tabs have a unique id.
Code: Select all
<div id="appginihelper-detailview-tabs" ...
...
<div>
So you can use jQuery to move whatever you like above, below or inside the tabs.
Helpful jQuery functions
- insertBefore()
- insertAfter()
- prependTo()
- appendTo()
Regards,
Jan
Re: label spacing bug
Posted: 2020-08-29 05:44
by SkayyHH
Hello Jan,
thanks very much. I
Unfortunately I can't do it.
Is it correct that way?
Code: Select all
dv.getTabs (). setPosition (TabPosition.Top);
dv.getField ("status"). insertBefore (). appginihelper-detailview-tabs ();
Thanks very much, Kai
Re: label spacing bug
Posted: 2020-08-29 11:51
by jsetzer
[...] use jQuery [...]
No, using jQuery for moving elements around is not a built-in AppGini Helper JS function.
Helpful jQuery functions
There are many examples for fetching elements by their selector and moving them before of after other elements.
Attention
In AppGini hooks you have to replace "$" by "$j"
Re: label spacing bug
Posted: 2020-08-29 12:18
by jsetzer
Quick and dirty example...
Before

- chrome_q22y6qvguh.png (21.78 KiB) Viewed 5719 times
Code
Code: Select all
// file: hooks/TABLENAME-dv.js
let field_tag = $j("#tag").closest(".form-group");
let field_status_icon = $j("#status_icon").closest(".form-group");
let target = $j("#appginihelper-detailview-tabs");
field_tag.insertBefore(target);
field_status_icon.insertAfter(target);
After

- chrome_3xdCk0OyAu.png (14.79 KiB) Viewed 5719 times
Re: label spacing bug
Posted: 2020-08-30 18:17
by SkayyHH
Thank you very much!
Best regards, Kai
SOLVED: label spacing bug
Posted: 2020-08-30 19:24
by SkayyHH
Another question.
Can i combine that with a layout 6/6? I need two fields in two columns before the tabs.
It would be great for future updates of your scripts if i could set fields before and after tabs
Thanks very much, Kai
Re: label spacing bug
Posted: 2020-08-30 19:35
by jsetzer
As mentioned before, you can use jQuery to move any element.
I recommend reading about jQuery selectors:
This will give you the power to find and then move around any element you want.
SOLVED: label spacing bug
Posted: 2020-08-30 19:39
by SkayyHH
OK. thank you very much. I'll find out for myself with this help.
But unfortunately it doesn't work in connection with your script .dropdown (). Fix (); as it seems.
Best regards, Kai
SOLVED: label spacing bug
Posted: 2020-08-30 19:46
by SkayyHH
Sorry. Will work. my mistake.
Thanks Kai