[OGo-Developer] OGo Invoice Application
Helge Hess
developer@opengroupware.org
Tue, 25 Dec 2007 23:19:56 +0100
On 25.12.2007, at 13:46, Sebastian Reitenbach wrote:
> the last days I again fiddled a bit around with the OGo Invoice
> application
> and actually got it working.
Why? Its really not worth the effort.
> 1. add a switch statement to sope-gdl11/PostgreSQL/NSNumber+PGVal.m
> checking
> for t_double.
>
> 2. exchange all t_double database field definitions in Misc/Invoice
> code
> with float. Float is implemented in NSNumber+PGVal.m to use atof(), so
> returning a double value.
>
> What would be the way to go?
Both double and float are completely inappropriate for storing
moneytary values. You need integer arithmetic. In Apple Foundation
this is done by NSDecimalNumber which is unsupported in
libFoundation ...
> Another question, when I am watching an article, or an article
> category,
> then there is a "switch to Skyrix..." and "switch to MDLink..."
> button.
> The button, company names, ... are hardcoded in the objective-c
> source of
> the Invoice application. Is there any good reason for that? If not,
> I'd go
> make it configurable, also the amount of companies at all.
Probably not. But then, the whole app is not worth the effort.
Greets,
Helge
--
Helge Hess
http://www.helgehess.eu/