[ic] ups_cache table IC 5.4 [solved?]

Randy Just randyjust at justcomp.com
Wed Jan 25 00:35:30 EST 2006


Don't know if this helps, but we round-up the shipping weight in 
shipping.asc like
the following:

crit    [calc interpolate=1]$tmp1=([item-list][item_field 
weight]*[item_quantity]+[/item-list]0);return int(($tmp1)+.99);[/calc]

At 02:16 PM 1/24/2006, you wrote:


>>If there is a better solutions I would appreciate any insight.
>
>How about this one: (Talking to self?)
>
>Suggested change to QueryUPS.pm
>
>sub calculate {
>         my ($mode, $weight, $row, $opt, $tagopt, $extra) = @_;
>
>+ my $tmp_weight;
>
>+ $tmp_weight = int($weight);
>+ if ($tmp_weight < $weight) {
>+ $weight = $tmp_weight + 1;
>+ }
>
>         $opt->{service}         ||= $opt->{table};
>
>
>Any thoughts on why this shouldn't be incorporated into the routine 
>that uses the freight cache tables, namely QueryUPS.pm???
>
>Is there a reason to cache actual cart weights instead of rounding 
>them up to the next lb?
>As mentioned before, the demo on icdevgroup.org product file has all 
>item weights already rounded to the exact pound. I find this would 
>not normally be the case in most businesses. (At least ones that 
>concentrate on selling multiple items)
>
>Thoughts?
>Steve
>
>_______________________________________________
>interchange-users mailing list
>interchange-users at icdevgroup.org
>http://www.icdevgroup.org/mailman/listinfo/interchange-users

Phone: 209-365-6179 * Fax: 209-365-7851 * e-mail: randyjust at justcomp.com



More information about the interchange-users mailing list