Hello all, Something weird is happening in a...

expressions
(Miranda Lubarsky) #1

Hello all,

Something weird is happening in a form.

I have a form/spreadsheet called “Trellis Timesheets”.

I input a bunch of different show-if expressions so that depending on whether there are 1, 2, 3 or 4 employees working on the job, it will calculate the correct # of hours to charge to the client.

When I have the form open, it works correctly.

So it only shows the columns that calculate the price for 2 employees or whatever it may be.

However, once I save the form and look at the details in the regular table view, it shows all of the fields, including the ones I don’t want.

Then if I go to edit it again, it only shows the correct ones.

I’m really confused why it is doing this.

Any ideas?

Thanks so much! Miranda

(Steven Coile) #2

In UX > Options, is show-if configured to apply everywhere?

(Marc Dillon) #3

Maybe something to do with an initial value for the durations (time type columns?)? I had a similar thing happen on a multi-page form where there were date fields on multiple pages, which got filled out even when that page was never visited. Date columns automatically have an initial value of now(), not sure about time columns.

(Eloi George) #4

Are you intending to show them beforehand how much it will cost with x amount of employees?

If not, you really only have to have inputs for the # of employees and the duration.

The calculated cost will then be kept in only one column.

Then for display, you’d have a virtual column say

“Labor & Materials Price of [employees] Employee(s): [calc_price]”

(Miranda Lubarsky) #5

+Steve Coile No, next to “Apply show-if constraints universally” the button is OFF.

@Marc_Dillon This problem with columns that have type Duration and Decimal. @Eloi_George The method you describe does not work for me.

This is a timesheet, so we need to know which employees worked on each job.

We can’t just list the number of employees without knowing who they are.

All my calculations work, it’s just the show-if action that is not working in the table view.

It works when you are filling out the form.

(Steven Coile) #6

Try setting Apply show-if constraints universally to ON.

(Miranda Lubarsky) #7

+Steve Coile Thank you Steve!

That did the trick!! :slight_smile: