0

Help in setting up an accountability system

Hi all,

We are trying tset up an internal "accountability system" for our Ninox, and I might use some technical help to figure out what's the best way to implement it.

Basically there are a few "sensitive fields" that will be updated by members of the team, then manually validated by an admin.

Right now all the sensitive fields have a trigger - every time they are edited, another field called "Validated by admin" switches to No. The admin has then to check the values are correct, then change manually the "Validated by admin" field to yes.

The problem is that we're lacking a way for the admin to easily identify which fields were edited and need to be double-checked. Ideally, every time a sensitive field is edited two things would happen -> Validated by admin switches to No (this works), and the field is colored in red. I'm not so sure what's the best formula to accomplish this.

Right know we have: 'Validated by Admin' := "2" . This part works. I tried to add a color command color("red) but this doesn't really work. Would you have any suggestions on the code to use to accomplish this?

If you have alternative suggestions to implement a similar system in an easier way, I'd be more than happy to hear them as well. Many thanks in advance, your help's appreciated.

Best,
Giovanni

5 replies

null
    • Riccardo.1
    • 3 yrs ago
    • Reported - view

    Hey Giovanni

    you write that you have a few "sensitive field" per record. Does each of those fields have their own validation switch or do you use one for all of the sensitive fields? Unfortunatelly, I think text fields can't be colored but there is a workaround either by filtering in a new table view or a colored function fields using the "styled" function.

    • Giovanni_Zagarella
    • 3 yrs ago
    • Reported - view

    Hi Riccardo,

     

    Thanks for replying. Each sensitive field has its own validation switch / trigger for the Validated by Admin field - these fields are a mix of text + multiple choice + number + date.

     

    Could you please go a bit more into detail in the workarounds you're thinking of?

    • Riccardo.1
    • 3 yrs ago
    • Reported - view

    Sorry for my late answer. To my knowledge those field(text, m+c, number and date) can't be colored. As the goal is to faciliate the workflow for the admin to validate the changed field I personally would do the following: 

    1. function fields can get colored with the code "styled". To highlight the status of your sensitive fields I'd place a funtion next to your switch or sensitive field with the code:

    ---------

    if 'switch for the sensitive field' = true then 

    styled("","green","","check")

    else

    styled("","red","","x")

    end

    -----------

    2. make that function field as small as possible or the size you think is suitable. When an editor is making a change in a sensitive field the connected switch will go to "false" (which you already achieved) and the function field will turn red. This is for the visual effect within the record.

    3. In order to make it easier for the admin to filter the records for unvalidated fields - turn to the table overview, add another column (for example "Validation") to your table and put in the code:

    (I use 4 different types of fields as example)

    -----------

    let mytext:= if 'Validation switch text' = true then

    0

    else

    1

    end;

    let mymc:= if 'Validation switch mc" = true then

    0

    else

    1

    end;

    let mynumber:= if 'Validation switch number' = true then

    0

    else

    1

    end;

    let mydate:= if 'Validation switch date' = true then

    0

    else

    1

    end;

    if mytext + mymc + mynumber + mydate > 0 then

    styled("validation needed","red","","x")

    else

    styled("validation checked","green","","check")

    end

    ------------

    4. In the overview the admin will see in which records a sensitive field need to be validated. If just one sensitive field is not validated the column will turn red. I recommend to add another table view (for example called "admin") and filter the 'Validation' column with "validation needed" or with the text you used in the 'styled()' function. In this table view the admin can work off all the records that have unvalidated sensitive fields.

     

    I hope my suggestion helps even though it is not exactly what you wanted in the first place. The styled() function works : styled("text","color"text color", "icon"). So when I used the styled() the text in the quotation marks are just suggestions.

    • Riccardo.1
    • 3 yrs ago
    • Reported - view

    * it is supposed to mean: styled("text","color","text color","icon")

    • Giovanni_Zagarella
    • 3 yrs ago
    • Reported - view

    Thanks for the very insightful reply, Riccardo. I'll get to work ASAP to implement this and see how practical it is to do with our database. Your help is very appreciated!

     

    Best,
    Giovanni

Content aside

  • 3 yrs agoLast active
  • 5Replies
  • 588Views