Applying a Gift Certificate with a User Event Scri...
# suitescript
d
Applying a Gift Certificate with a User Event Script doesn't seem to be applying the amount to the order until after I enter EDIT mode of the record. Any ideas how I can apply the GC amount in the UE?
Copy code
_order.selectNewLine({
                        sublistId:'giftcertredemption'
                    });
                    _order.setCurrentSublistValue({
                        sublistId: 'giftcertredemption',
                        fieldId: 'authcode',
                        value: _giftCertificates[_authCodeId].id,
                        ignoreFieldChange: true
                    });
                    _order.setCurrentSublistValue({
                        sublistId: 'giftcertredemption',
                        fieldId: 'authcodeapplied',
                        value: _amtToApply,
                        ignoreFieldChange: true
                    });
                    _order.commitLine({
                        sublistId: 'giftcertredemption'
                        // ,ignoreRecalc: false
                    });