You are currently reviewing an older revision of this page.
TNEW's cart displays contribution objects based on configuration in LTR_TNEW_CONTRIB_TYPE. If you add a contribution to the cart using the API (either CLR procedures or via shared session), the contribution will not appear in the cart unless you tell TNEW which ID to use from the LTR_TNEW_CONTRIB_TYPE table.
TNEW stores this reference in order notes in the format c<contrib_type_id>_<contribution_ref_no>; .
c<contrib_type_id>_<contribution_ref_no>;
Example implementation code is provided for a precart SQL procedure:
DEC LARE @CC_cont_ref_no_LV int; -- After the contribution is added, populate the order notes field by appending the contrib type ID token. SEL ECT TOP 1 @CC_cont_ref_no_LV = ref_no FROM dbo.T_WEB_CONTRIBUTION WHERE order_no = @order_no ORDER BY ref_no DESC; UPD ATE dbo.T_WEB_ORDER SET notes = ISNULL(notes, '') + 'c' + CAST(@CC_ContribType AS varchar) + '_' + CAST(@CC_cont_ref_no_LV AS varchar) + '; ' WHERE order_no = @order_no;