external setting of custom fields
I'm trying to update some custom fields based on data in another custom field. So I look up one custom field "order number" elsewhere in our database, and update another custom field "vehicle" with the vehicle that delivered it. I can see that the update has worked in table gemini_customfielddata but the update never appears on the web: I just get a blank. It makes no difference whether I update or insert.
I've spotted that the customfielddata column fielddata is preceded by 0| for some reason, but even if I include this no joy.
What am I doing wrong? Is any of this documented anywhere?
cpf_jg
· 1 |
|
Monday, October 22, 2012, 4:27:40 PM |
0
|
Which version of Gemini are you running? If you overwrite the data it should show, please check if there is no duplicate entries for the same issue for the same custom field id. |
||||
|
0
|
V5.1.1 on evaluation. No duplicates. Could it be connected with 0|? I can't see why this is added |
||||
|
0
|
Are you setting the data to a valid id followed by a pipe (1|)? |
||||
|
0
|
Possibly not; how would I know what a valid id is? |
||||
|
0
|
Back to the top! This really isn't behaving for me. If I change the data in the database (say from 0|ABCD to 0|EFGH) by updating table gemini_customfielddata, the corresponding field on the website is blank after refresh. But I can successfully change it back, and once again the field appears correctly filled on the website. Should I be doing a delete and insert instead of update? Is any of this documented anywhere, including the significance of 0| or 1|? |
||||
|
0
|
Got there myself in the end. The definition of the drop down in the custom field multi-select list doesn't so much just provide a list to choose from, it constrains the values in the web display. So if I change the values in the database to anything else, they won't display on the webpage. Equally, I guess that if I reduced or changed the options in the multiselect list (such as a list of today's orders instead of yesterday's), any existing different choices for that field would not display. This appears to be the case even when the field is being used as an information field rather than an updateable field, e.g. on the issues list. So to achieve what I wanted, I'll have to have 2 custom fields that appear the same to the user, and use one for that day's input selection choices and the other as the true data field in each record. Now all I need to do is copy the selection from one field to the other each time a new issue is created. |
||||
|