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

pos screen does not update



Hello all,
My problem is all about the POS module.  It started with a post I made some time ago, and there was a good deal of information provided.  thanks for that.  I have now obtained a receipt printer and a cash drawer, and am trying to get the POS module working correctly with it.
I have put quite a bit of time into this, fiddling with pos.conf.pl, ledgersmb.conf and bin/pos.pl, as well as a number of other things.  I also created way to many invoices, and finally got to a point where I couldn't keep track of what I had done to create errors that were showing up, so I have now restored an original copy of pos.conf.pl and bin/pos.pl, and restored the database back to the beginning of the process.  Here I go again.

What I have done so far:
- in ledgersmb.conf, I have modified the printer section as follows:
   [printers]
   # Available printers
   #Laser      = lpr -Plaser
   #Epson      = lpr -PEpson
   Star     = lpr -P Receipt-1
   This creates a 'Star' option to print from in POS=>sale and AR=>invoice.
- I have changed near the top of the bin/pos.pl file from USD to CAD to avoid the exchange rate field (matching the system).
- I have commented all lines in pos.conf.pl $pos_config{'pd_*'}.  On the assumption that pd is pole display, and since I have no pole display, it seems reasonable to comment them out.

What works as expected:
- from command line, the command lpr -P Receipt-1 /home/bob/test.txt prints and opens the cash drawer.
- under AR=>sales invoice I can enter one or more items into an invoice, and the print button prints and opens the cash drawer, though the invoice does not fit onto the paper in width.
- under AR=>sales invoice, entering items and posting them affects inventory
- under POS=>sale, entering part of a description, pressing 'update,' then 'print and post,' I get some open transaction information, and inventory is affected, though I get an error (see below).

What does not work; 
- under POS=>sale, entering part of a description, pressing 'update,' then 'print and post,' though inventory is affected correctly, I get an error at the top of the page:
  Attempt to free unreferenced scalar: SV 0x949c508, Perl interpreter: 0x8170008 at bin/pos.pl line 966.
  Content-Type: text/html; charset=utf-8

- under POS=>sale, entering part of a description and entering an amount in the 'Amount' field, pressing 'update,' then 'print and post,' I get the following error:
Attempt to free unreferenced scalar: SV 0x94a1718, Perl interpreter: 0x8170008 at bin/pos.pl line 966.
DBD::Pg::st execute failed: ERROR: null value in column "chart_id" violates not-null constraint at LedgerSMB/IS.pm line 1306.
Error!
INSERT INTO acc_trans
(trans_id, chart_id, amount,
transdate, source, memo, cleared)
VALUES (?, (SELECT id FROM chart
WHERE accno = ?),
?, ?, ?, ?, ?)
ERROR: null value in column "chart_id" violates not-null constraint
Inventory is not affected when this error happens, however the invoice number does auto-increment.

What I have tried:
- creating a Chart of Accounts entry for account 1300
- creating a Chart of Accounts entry for account 1300.2 (as per a post I found on the net that says the default schematics is 1300.[employeenumber].  I have a feeling that maybe I have the definition of account incorrect in this context.)

I have been trying to figure it, but between following code and trying to interpret the database calls, progress is beyond slow for me.  I suspect there is a configuration in the POS module  somewhere that I am missing, since things seem to work ok in AR.  I am not scared of documentation, but I have looked over all the relevant stuff I have found so far (the wiki being down at the moment), and I have come up blank.  If someone could offer a nudge in the right direction, I would really appreciate it...


Bob Miller
334-7117/633-3760
http://computerisms.ca
..hidden..
Network, Internet, Server,
and Open Source Solutions