[Advacs-discuss] Localisation structure in place

Oliver Elphick olly@lfix.co.uk
Mon, 16 Aug 2004 14:21:05 +0100


Following my discussions with Helmut, I have changed the database
schemas and Makefiles to put in place the localisation structure.

There are two classes of local data:

  1.  Data that varies with the country's laws
  2.  Data that varies by language

The Makefile in sql/GL must have the country and system language defined
(at the top of the Makefile).  Obviously, these must be already defined
in the directory structures under sql/national/GL.

Translators need to copy the directory structure sql/national/GL/GB/en
to sql/national/GL/[countrycode]/[languagecode] and then alter all the
texts in the new directory to the new language.  Things that alter with
the law must also be redefined, and may need new identifier codes. 
Obviously, these changes must be reflected in the texts.

I have defined some things at base level (in sql/GL).  If any of these
should change with local law, they would need to be moved into the
national hierarchy.

The views (with names ending _v) present text in the appropriate
language for the user.  Each user can recored his desired language in
the user_preference table; then a request to see one of those views will
return the text in that language.  If the user has not expressed a
preference, the system's base language will be used.  Several functions
are defined to achieve this.

I have also simplified the transaction/batch/line indexing from 4 tables
to 2.  Batch remains, but the batch number is no longer part of the
transaction primary key.  Transaction's primary key is now a SERIAL
field, and the document reference is a separate field, combined with an
adjustment number field, that enables corrections to be made to a
previously entered document.


sql/docs/GL/advacs.html is up to date, but sql/docs/GL/advacs.dia is
not.  I'm using postgresql-autodoc to generate these, and the dia
document is unusable in the form that it is produced; it must be
hand-edited.


-- 
Oliver Elphick                                          olly@lfix.co.uk
Isle of Wight                              http://www.lfix.co.uk/oliver
GPG: 1024D/A54310EA  92C8 39E7 280E 3631 3F0E  1EC0 5664 7A2F A543 10EA
                 ========================================
     "And whatsoever ye shall ask in my name, that will I 
      do, that the Father may be glorified in the Son."     
                                          John 14:13