[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Importing parts and services

Hi Kaare,

Started a separate thread/subject so people may be triggered by the subject.
Actually, my list wasn't complete: this was fixed on April 11 and is part of beta5. Upgrading should help you out. The problem is that the initialization is in the global section of the code, however, with the code being pre-loaded (i.e. loaded outside of the context of one specific request), there *is* no locale since there's no user. So, the variable initialization has moved.

Oh, this is great! When I get the next available timeslot for testing (not much left after $work, @family and $business) I'll give it a whirl.

Actually, I already started to wonder how to import products. I guess the API is "find the product tables and write to the database", and that the products and prices are placed in the part* tables, right?

Yes, at the moment, the solution is to fill the parts table yourself. The parts table contains parts, services, labor and overhead. There's a comment in the schema when something is considered one or the other: https://github.com/ledgersmb/LedgerSMB/blob/master/sql/Pg-database.sql#L1525 ; the base prices of the parts/services are listed in that table. The "partstax" table contains a list of all taxes (=tax accounts) applicable for each part. Then there are the partscustomer and partsvendor tables which help to set up with customer/vendor specific prices for groups of/individual customers/vendors and groups of/individual parts (yes, that's 4 outcomes :-) ).

If you have further questions, don't hesitate to ask!

By the way, a "customer" or "vendor" is an "entity_credit_account" with either a "customer" or "vendor" role (class).




http://efficito.com -- Hosted accounting and ERP.
Robust and Flexible. No vendor lock-in.
Mobile security can be enabling, not merely restricting. Employees who
bring their own devices (BYOD) to work are irked by the imposition of MDM
restrictions. Mobile Device Manager Plus allows you to control only the
apps on BYO-devices by containerizing them, leaving personal data untouched!
Ledger-smb-devel mailing list