4 * fill in any fifo basic entries that have not been processed..
5 * -- does not fill in values.. - just qty's
8 require_once 'ProcessBase.php';
10 class Pman_Xtuple_Fifo_ProcessGl extends Pman_Xtuple_Fifo_ProcessBase
13 static $cli_desc = "Post GL entries.";
15 static $permitError = false;
19 $ff = HTML_FlexyFramework::get();
21 die("run form cli only");
28 // set up the failure code..
29 PEAR::setErrorHandling(PEAR_ERROR_CALLBACK, array($this, 'onPearError'));
31 // we have to have a pointer to work out where we left off..
32 // this process can go by invdetail_id ASC..
33 $id = DB_DataObject::Factory('cohead');
35 $locs = $id->fetchAll('cohead_id', 'cohead_number');
40 foreach($locs as $cohead_id => $cohead_number) {
42 $id = DB_DataObject::Factory('invdetail');
43 echo "SELECT invfifo_apply_gl_cohead($cohead_id)\n";
44 $id->query("SELECT invfifo_apply_gl_cohead($cohead_id) as result");
48 echo "DONE $cohead_number - adjust: $res\n";
54 //if ($n > 50) { exit; }