Document Version Button Issue

Hello,

Currently i'm trying to develop the document verification and approval app where users have their roles assign and can give access rights of the documents to other user also version maintaining is there.

I've created multiple table. which is Document master, Document Access, User Master etc
here in my document access table I've created one Virtual Column which type is "List" which contains the version list of policies like if xyz has many version such as 1.0, 1.1,2.0 etc so in my Document access table i'm showing policy versions for particular policy.

but with that it is showing me two buttons named "View" & "Add" which i don't want to show to users. cause the users who has no rights to Add can directly go through this and add the data. 

Any ideas on how to achieve this?
Are there perhaps any sample app and or other threads available that replicate what I would like to achieve?

Thanks for the help in advanced.

Solved Solved
0 3 209
1 ACCEPTED SOLUTION

Aurelien
Google Developer Expert
Google Developer Expert

Hi @Neel_Zaveri 

1) 1st possibility:

You would need to use a Slice with Read-only permission.

According to the user permission, you will show the "Related Documents" that allows the Add button, and if the user has no permission, you will display the "Related Documents_Read_On_Slice".

This requires the creation of a "twin" column of your Related Documents column. 

Steps are:

- create a slice, with update permission "read only"

- create a view with the RefRows() expression, and set the type identical to the default one, but change the Source table to point toward your slice

- use the Show_If column according to the user permission.

Here is a sample app I made for explaining purpose:

PF_Restrict_InlineAdd

2) 2nd possiblity:

Restrict directly on the Table settings the Update mode to ReadOnly, depending on the user profile:

Aurelien_0-1694498263228.png

Aurelien_1-1694498275270.png

 

For reference:

Control add, update, and delete operations - AppSheet Help

 

View solution in original post

3 REPLIES 3

Aurelien
Google Developer Expert
Google Developer Expert

Hi @Neel_Zaveri 

1) 1st possibility:

You would need to use a Slice with Read-only permission.

According to the user permission, you will show the "Related Documents" that allows the Add button, and if the user has no permission, you will display the "Related Documents_Read_On_Slice".

This requires the creation of a "twin" column of your Related Documents column. 

Steps are:

- create a slice, with update permission "read only"

- create a view with the RefRows() expression, and set the type identical to the default one, but change the Source table to point toward your slice

- use the Show_If column according to the user permission.

Here is a sample app I made for explaining purpose:

PF_Restrict_InlineAdd

2) 2nd possiblity:

Restrict directly on the Table settings the Update mode to ReadOnly, depending on the user profile:

Aurelien_0-1694498263228.png

Aurelien_1-1694498275270.png

 

For reference:

Control add, update, and delete operations - AppSheet Help

 

Thank You So Much @Aurelien  I really appreciate your help.

Another thing is, I've one Document Update table where i change the file with major and  minor change so for that i've created Bot. 

1. when change type is major -> version +1 -> trigger email to user (Adds Only)
2. when change type is minor -> version +0.1 -> trigger email to user (Adds Only)
3. when the data is added to this table i want to trigger an email to user.

so what happens is when any record is added to the table the 3rd bot is not working. and with that when i made any changes then it triggers 3 to 4 email. 

Please Guide me into this matter.
Thanks for the help in advanced.

Hi @Neel_Zaveri 

For your last question, I would suggest to create a new post as it is a whole different question ๐Ÿ™‚

Top Labels in this Space