(888) 685-3101 ext. 2

Mobile Client
Today we needed to make a picklist field multiselect in the Saleslogix mobile client. Unfortunately this appears to be broken in Mobile 3.0.3. To work around this we had to override two functions in the picklist field’s definition on the edit form. Hopefully this will save somebody else a little time.

The functions in question are formatValue and textRenderer.
{
name: 'Type',
property: 'Type',
type: 'picklist',
label: 'type',
picklist: 'Contact Type',
singleSelect: false,
maxTextLength: 64,
formatValue: function(values) {
var a = [];
for (key in values)
a.push(values[key].data.text);
return a.join(",");
},
textRenderer: function(values) {
if (values.constructor.name == "String")
return values;
var a = [];
for (key in values)
a.push(values[key].data.text);
return a.join(",");
},
validator: validator.exceedsMaxTextLength
}

Share This