make a button for a cloned form appear on a user home page

Questions related to using nuBuilder Forte.

make a button for a cloned form appear on a user home page

Unread postby zuppo » Sat Nov 28, 2020 1:40 am

Hi,
I cloned a form 'contacts' as I wanted to hide som fields of this table for a certain user level. I run into some problems:
1. I do see the cloned form amongst the other forms when browsing the forms table, but I don't find copied objects in the objects table. Should I copy them one by one?
2. I tried to create a new button by cloning the original run object, but the button isn't showing. I had to create an ID for this button manually. So I guess this is not really the correct way of creating it?
3. If I would be able to create this button, how can I make it show up at the home page of a certain user-level? Is it possible to create a home page that is not showing all the buttons of the "fast forms"
Any help appreciated!
zuppo
 
Posts: 12
Joined: Mon Nov 23, 2020 1:48 am

Re: make a button for a cloned form appear on a user home pa

Unread postby zuppo » Sat Nov 28, 2020 2:04 am

Oups!
I see (using the 'Arrange Objects' option on the Fast Forms Home page' ) now that the cloned button is showing, but is being hidden behind the original one. Silly me!
So that 's one problem less, but still I'm wondering if it 's the normal procedure to register the id-field 'manually?
Last edited by zuppo on Sat Nov 28, 2020 3:00 am, edited 1 time in total.
zuppo
 
Posts: 12
Joined: Mon Nov 23, 2020 1:48 am

Re: make a button for a cloned form appear on a user home pa

Unread postby Janusz » Sat Nov 28, 2020 2:34 am

Hi,
To clone the form with all objects you can use very good tool "cloner" from kev1n.
https://github.com/smalos/nuBuilder4-cloner
I was testing this and works really very well.
Otherwise you need to clone edit form objects manually.

to hide a button or any other object on the form you can use JS - for example:
Code: Select all
function getUser() {
   var nuUser = nuUserName();
   if (nuUser === null) { nuUser = "admin";}
   return nuUser;
}

>>>> the function getUser() - the best is to place it in header
>> and code belowe in JS custome code on the specific form

var usr=getUser();

if (!(usr=="admin" || usr=="Janusz"))
{nuHide('nuTab13');}

if (!(usr=="admin" || usr=="Janusz" || usr=="Renata"))
{nuHide('adm_links3');nuHide('adm_links4');}

But if you hide something with JS everyone knowing JS can make it visible - so depanding on case you need to protect additionaly data with php or with Access Level.
Regarding ID so for any object in nuBuilder you can assign any text_value - and the only condition is - it must be unique on the specific form (and not globally for objects)
If you like nuBuilder, please leave a review on SourceForge
Janusz
nuBuilder Team
 
Posts: 446
Joined: Fri Dec 28, 2018 10:11 pm
Location: Krakow, Poland
nuBuilder Version: 4.5

Re: make a button for a cloned form appear on a user home pa

Unread postby zuppo » Sat Nov 28, 2020 3:08 am

Thank you for your clear reponses. I had hoped that the different user group really could have their own home page 'out of the box'.
I will try your suggestions, though .. .
Grz!
Paul
zuppo
 
Posts: 12
Joined: Mon Nov 23, 2020 1:48 am

Re: make a button for a cloned form appear on a user home pa

Unread postby Janusz » Sat Nov 28, 2020 3:48 am

the starting page nuuserhome you can define as well depending on user or group - so to some extend you can get user specific starting page, you can hide tabs depanding on user - so practically it's not difficult to make it specific per user - but generally you create all options and hide them depanding on the user - at least what I am doing - but maybe there are other options which I do not know.
If you like nuBuilder, please leave a review on SourceForge
Janusz
nuBuilder Team
 
Posts: 446
Joined: Fri Dec 28, 2018 10:11 pm
Location: Krakow, Poland
nuBuilder Version: 4.5

Re: make a button for a cloned form appear on a user home pa

Unread postby zuppo » Sat Nov 28, 2020 4:08 am

Hi Janusz,
I would certainly be happy to know how I can do that. Is it een option to show only the 'Main' for instance? How can I do that?
I tried what you suggested in you first answer, that works. Glad that it does :-)
zuppo
 
Posts: 12
Joined: Mon Nov 23, 2020 1:48 am

Re: make a button for a cloned form appear on a user home pa

Unread postby Janusz » Sat Nov 28, 2020 5:16 am

Just short movie from one DB how you can hide objects or organize DB. What is typed in the console you can place in the JS custom code depending on the user.
https://drive.google.com/file/d/1J359wZ ... sp=sharing
(if you want to have not to much blurry you need to download and play after)
If you like nuBuilder, please leave a review on SourceForge
Janusz
nuBuilder Team
 
Posts: 446
Joined: Fri Dec 28, 2018 10:11 pm
Location: Krakow, Poland
nuBuilder Version: 4.5

Re: make a button for a cloned form appear on a user home pa

Unread postby zuppo » Sat Nov 28, 2020 10:33 pm

Finally I was able to solve it in the way I was hoping to do it. Maybe it will help other people struggling with this when posting my solution here ...

To make the table 'contacts' editable by a specific usergroup while only showing one button to that form, I
-Created a new launch form 'Aanmelder'
-Created a run button 'Aanmelders Home' pointing to that launchform (so that the admin can see and edit the launch form). Note that the ID on the RUN-tab must be set at -1
-Created a clone of the main 'Contacts' form '(contacten3) on the launch form 'Aanmelder'
-Created a run button showing on the Aanmelder launch form and pointing to that form
-Created a access level (test) adding the launch form and the contacten3 form

Thank you for pointing out the other 'hiding' possibility, Janusz. I got it to work and I 'm sure that it will certainly also prove to be usefull in the future!

AanmeldersHome.PNG
AanmeldersHome.PNG (15.16 KiB) Viewed 318 times


AanmelderHomepage.PNG
AanmelderHomepage.PNG (4.34 KiB) Viewed 318 times


Contactpersonen3Button.PNG
Contactpersonen3Button.PNG (12.36 KiB) Viewed 318 times


Acces level.PNG
Acces level.PNG (8.54 KiB) Viewed 318 times


Contectpersonen3.PNG
Contectpersonen3.PNG (9.77 KiB) Viewed 318 times
zuppo
 
Posts: 12
Joined: Mon Nov 23, 2020 1:48 am

Re: make a button for a cloned form appear on a user home pa

Unread postby apmuthu » Sat Jan 16, 2021 8:54 pm

@Janusz: Your video link is unreachable now.
Attachments
Cloned Form as Button on User Home.pdf
(171.69 KiB) Downloaded 21 times
apmuthu
 
Posts: 224
Joined: Sun Dec 06, 2020 3:20 pm
Location: Chennai, India, Singapore


Return to General

Who is online

Users browsing this forum: No registered users and 19 guests

cron