Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I needed the order subtotal without the '$' sign, but the problem was that the default implementation of [order-subtotal] was themed, so it was rendered like '$12.20'. I just needed the value, like '12.20'.
I tweaked the uc_order.module to add a [order-subtotal-value] token, which is the same as the [order-subtotal], but it just doesn't pass thru the theming routines in uc_price.
Attached is a patch.
Comment | File | Size | Author |
---|---|---|---|
#1 | uc_order.module-patch.txt | 1.86 KB | rich.yumul |
Comments
Comment #1
rich.yumul CreditAttribution: rich.yumul commentedComment #2
rich.yumul CreditAttribution: rich.yumul commentedComment #3
longwaveThis token was added by TR to 7.x in http://drupalcode.org/project/ubercart.git/commit/c7f75af
Comment #4
TR CreditAttribution: TR commentedIn D6 Ubercart we are using the suffix "-raw" to indicate unformatted values in tokens. So I added an [order-subtotal-raw] token and an [order-total-raw] token. As @longwave said, Ubercart 7.x-3.x already has these unformatted tokens.