google-code-export / openesignforms

Automatically exported from code.google.com/p/openesignforms
1 stars 0 forks source link

Start transaction POST should auto-update same-name fields in documents #103

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Currently, when starting a transaction with a POST that includes various data 
fields, the programmer has to specify an initial value on every document in the 
package to set it based on that setting.  Currently, a field called 'ssn' needs 
to set its' initial value to ${transaction:ssn} to set it's value based on the 
posted data.

When the number of fields is small, this is not a big deal, but for large 
packages, such as HR, financial docs, etc., it can be tedious.  The reason such 
data is included in the POST is to set field values, so an easier mechanism is 
desired.

Original issue reported on code.google.com by yoz...@gmail.com on 19 Jun 2013 at 5:07

GoogleCodeExporter commented 9 years ago
We can update the start transaction logic to accommodate this in a secure 
fashion:

1) Manual mapping: If a field has an initial value, that will be honored over 
any automatic mapping.

2) Automatic mapping: If a field has the same name as the POSTed data, and the 
field is set to be editable for the first party, that field will have its value 
set from the POST data.

Original comment by yoz...@gmail.com on 19 Jun 2013 at 5:09

GoogleCodeExporter commented 9 years ago
Added to release 13.7.13.

When starting a transaction with initial POST data, if the field in the 
document has an initial value specified, it will be     used (as before), but now 
if no value is set and the field name matches the name of an initial POST 
param, it will be set to the value from the initial POST data.

Original comment by yoz...@gmail.com on 20 Jun 2013 at 10:11