From: skaill <sk...@ro...> - 2004-10-07 19:57:50
|
Comments within. Look for > to distinguish mine ... ----- Original Message -----=20 From: Daintrees=20 To: web...@li...=20 Sent: Thursday, October 07, 2004 3:23 PM Subject: Re: [Web-erp-developers] Thanks What is stored in the DB is English - kind of! But there is a longer = string that is displayed on screen in respect of the Select for Sales = Type, Stock Category etc.... so this is ok - I converted these strings. >Good, I was just helping to make sure. Most nights I commit something or other - so there is no harm in = updating your cvs regularly. > I was but since I wasn't doing much development for the last few = weeks it was a bigger cvs update this time. Comments within...... I think there may be an issue with the way the following has been = converted for Multilanguage in ConstructSQLForUserDefinedSalesReport... If ($ReportSpec["GroupByData2"] !=3D _('Not Used')) { I believe this field is filled in by whatever is in the database. = Not sure what puts it in the database but I'm think whatever does = probably puts it there in English. If so, it should only be converted = when being displayed, not when being tested in an IF condition. = Possibly whatever puts it in does translate it though... Here's another one in SalesAnalRepts... if ($_POST['GroupByData3']=3D=3D'Not Used' AND = $_POST['GroupByData4']!=3D'Not Used'){ I think I thought this through at the time I'll have another look. Testing of this variable in GLJournal.php may be incorrect in the = same way as GroupByData explained above. if ($_POST["JournalType"]=3D=3D_("Reversing")){ and The submit button for Accept is also translated so this should be ok = ... I think } elseif ($_POST['Process']=3D=3D_("Accept")){ //user hit submit a = new GL Analysis line into the journal Same here in GLProfit_Loss.php... if ((! isset($_POST["FromPeriod"]) AND ! isset($_POST["ToPeriod"])) = OR $_POST["SelectADifferentPeriod"]=3D=3D_("Select A Different = Period")){ and if ($_POST['Detail']=3D=3D_('Detailed')){ which is in more than one place. Possibly some still work because = here it is also translated on the submit form button but we agreed to = try to test for isset rather than get into testing translations when at = all possible. I think detailed is a select to it will always be set although = sometimes it'll be summary. Since the translation of detailed only has = one translation wherever it appears we can rely on the same translation = - it only appears in the .po file once. > Good, just checking again. In MailInventoryValuation the variable $DetailedReport is set to = 'Yes' but throughout it is $_POST['DetailedReport'] that is checked. = This may be incorrect. In MailSalesReport this does not look right but I guess could be = somehow such as returning value I guess... /*The Sales report to send */ $_GET['ReportID'] =3D 2; In PDFDeliveryDifferences.php, again, it tries to translate strings = before session.inc is run. I think there was varying opinion on whether = that would work when gettext was not installed on the server. I'm = thinking it won't. I have a susbstitute function in config.php now. >Ah, a substitute function that occurs previous to the translations = that arer right at the top of those scripts? Not sure the string in this sql statement in StockCostUpdate should = be translated. I know usually they should not be, only when they are = displayed... $SQL =3D "INSERT INTO GLTrans (Type, TypeNo, TranDate, PeriodNo, = Account, Narrative, Amount) VALUES (35, " . $CostUpdateNo . ", '" . = Date('Y-m-d') . "', " . $PeriodNo . ", " . $StockGLCode["AdjGLAct"] . ", = '" . $StockID . ' ' . _('cost was') . ' ' . $OldCost . ' ' . _('changed = to') . ' ' . $NewCost . ' x ' . _('Quantity on hand of') . ' ' . = $_POST['QOH'] . "', " . (-$ValueOfChange) . ")"; =20 Possibly because it is only a message. Yeah that's right they are displayed in the database as a message = and a message appropriate to the system is better. This does present a = problem when the system is used by several different language speakers. >Good. Yes, it does present a challenge I haven't really tackled. = Possibly messages should not be stored in the >database and instead = maybe a pointer in the database to a variable/array or whatever that can = be translated in the same >fashion as we are doing the rest. In Tax.php I'm thinking this is probably incorrect because it tests = if the amount is 0 but doesn't exit like it used to... if (ABS(round($TransTaxLeft,2))>0.01){ $WarningMessage[$MessageCounter] =3D _('The total tax on') . ' ' = . $DebtorTransRow['TypeName'] . ' ' . $DebtorTransRow['TransNo'] . ' ' . = _('of') . $LineItemsRow['LineTaxAmt'] . ' ' . _('as per the transaction = header record was not equal to the sum of the line items - there is a = data inconsistency of') . ' ' . $TransTaxLeft ; $MessageCounter++; } >??? I think the latest cvs may have the DatabaseName in config.php = incorrect. It says testsys instead of weberp. Yeah thats my much larger test database. >I figured someone had just left theirs which isn't a big issue but = thought I would point it out. The biggest source of problems because of translation I believe will = come from converting strings that are tested and incorrectly translating = and testing of Submit and Option. I think this is true .... we'll need a translation to fully debug = things. >Yep. Guess we should try to do another sweep asap that will = bringing the Multilanguage near to finished. I will commit to 10-20 = more but give me a few at a time or too discouraging! =20 Just hitting the issues proactively that I can find before others = encounter them at a less convenient time. What is this PrnMsg? Are we supposed to be using it and if so then = when and where? This is a Jesseism - it is in includes/MiscFunctions.php and just = formats and echo in the right colour etc depending on the message - I = have used echos and I guess it would be better to use this function to = ensure consistency throughout. >Ok, I will take note and try to use that PrnMsg function. Sounds = like a good idea. There will be times often when people will not want rounding = permanently fixed at 2. For instance, in an item price (price, not = amount) and several other reasons. The additional code for rounding is = a good idea, however there should be variables that can be set instead = of hard coding 2 in all these places. Item price should use a different = variable than Amount because item price is often set to 4 whereas Amount = is often set to 2. You have a bunch still allocated Steve... I am not on my development = machine I will dig out what you should have. Thanks for keeping us all = motiviated - its such a shame to have come this far - I believe we are = about half way - and not finish the job. The other upset for me is that = the foreign language speakers have not been involved in this whole push. >I believe I only have two outstanding. Those two are heavier ones = so I was hoping for more. This way I can pick off shorter ones when I = have less time. We will get it done ;) In the meantime all of the = scripts already done are kind of getting tested through some use which = is a good thing. >Yes, we could sure use more help. It is not much for several = people to take on 5 scripts but doing 20 or 30 between a >few people is = a much heavier load for each person. If anyone else can do it and has a = bit of time we will get this done >quicker. If you don't want a big = commitment just ask for 1 or 2 at a time. You can take a look at some = others already >done to quickly see what to do. I can always explain = too if you ask. At the same time I know some of the people will >be = better at translating but don't have the computer skills we do. That's = a good thing because it would be annoying if >everyone was just like = me...hahaha! Looks like the messages.po file is getting there with much more in = it :) We need to drive toward getting it ALL done. Please give me 5 = more files for translation, Phil... Steve Phil |