You are viewing limited content. For full access, please sign in.

Question

Question

Variable Default Values and Dynamic Fields

asked on April 28, 2014 Show version history

Is there a away to set a variable default value for a drop-down list when using dynamic fields (in the Laserfiche Client), while still maintaining the ability to select other options from the list?

 

We currently have a dynamic field that we want to be able to set the default value for. The challenge is that the default value can change based on other fields in the template. While we can easily configure dynamic fields such that the selection of one field equals a different value for another field, doing so limits the available options for selection from the drop-down list. That is, only the default value is available for selection.

 

For example the two following columns are in the SQL table:

  • Field 1 - Customer Name
  • Field 2 - Customer Type

 

The possible values for each fields are...

  • Customer Names: Customer A, Customer B, Customer C
  • Customer Type: Prospect, Current, Former

 

Thus, our table might look like...

 

Customer A | Prospect

Customer B | Former

Customer C | Current

 

The problem we are having is if we want to change Customer A from Prospect to Current, we cannot because Current is not listed next to Customer A in the SQL table. If these fields were independent from each other, this would be simple; however, they are related, and it is critical that when someone chooses Customer A from the drop-down list, that the current Customer Type be defaulted to Prospect or whatever the current default for that customer should be.

 

Given this, is there a away to set a variable default value for a drop-down list when using dynamic fields, while still maintaining the ability to select other options from the list?

 

While brain storming this problem we thought about the possibility of generating a larger table with the default value being the first value in the list (for the second column), e.g.

 

Customer A | Prospect

Customer A | Current

Customer A | Former

Customer B | Former

Customer B | Prospect

Customer B | Current

Customer C | Current

Customer C | Prospect

Customer C | Former

 

However, we are not sure if the first row in the list will always be displayed first and we felt there had to be a less cumbersome way to do this. Would this work consistently, i.e. the first value would always be the default, and does anyone have a suggestion on a better way to do this? Thank you in advance!

0 0

Answer

SELECTED ANSWER
replied on April 29, 2014

One way you could solve this would be to use a third field and Workflow in order to update the desired field/the dynamic field database.

 

So you would end up with something like the following for fields:

Customer Name

Customer Type

Update Customer Type (this field would be a list field containing the different possible values of customer type)

 

When the "Update Customer Type" field was set, a workflow could kick off to set the Customer Type to the new value in the database, refresh the template field in Laserfiche, and then reset the Update field to blank.

0 0

Replies

replied on April 29, 2014

This is a great suggestion and I think it would be the cleanest option, as maintaining the table and keeping the correct order would be fairly cumbersome. Would it be possible to add this as a feature request for a future release? Perhaps some way to use the List field type while using dynamic fields to pull the default value. Or a way in the database, a prefix to a value or an additional column, to indicate to Laserfiche the default value.

 

Thanks for the consideration.

0 0
replied on April 29, 2014

I've added the "feature request" flag to this topic so that it can be reviewed as such. If anyone in Development has any follow-up questions for you about this particular functionality request they may post here for clarification.

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.