Is it possible to force a field to re-render in a snippet?
Here’s the use case:
We have two datetime fields, Out Date and In Date. The In Date shouldn’t be before the Out Date. We have a field renderer on In Date that prevents the user from selecting a date in the datepicker that is before the out date:
var field = argumentsm0], <br> value = argumentsm1];<br>skuid.ui.fieldRenderersefield.metadata.displaytype]tfield.mode](field,value);<br>if (field.mode==='edit'){ if (field.row.CheetahBMS__Out_Date__c !== undefined){ var dateInput = field.element.find('input.hasDatepicker'); dateInput.datepicker("option","defaultDate",skuid.time.parseSFDate( field.row.CheetahBMS__Out_Date__c )); dateInput.datepicker("option","minDate",skuid.time.parseSFDate( field.row.CheetahBMS__Out_Date__c )); dateInput.datepicker("refresh"); } }
This works when you just edit the In Date. However, if you edit the Out Date, it does not rerender the In Date and you are able to choose a date that is before the Out Date. My theory is I should be able to run a snippet when the Out Date is changed, rerendering the In Date, keeping the entire line in edit mode.
I’ve used this:
skuid.$C(‘progresstable’).render();
to rerender an entire table before, but I’m not sure how to re-render just a field.