<?php

/*
 * LMS version 1.10.2 Roham
 *
 *  (C) Copyright 2001-2007 LMS Developers
 *
 *  Please, see the doc/AUTHORS for more information about authors!
 *
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License Version 2 as
 *  published by the Free Software Foundation.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
 *  USA.
 *
 *  $Id: cashimportcfg.php,v 1.8.2.1 2007/08/17 13:15:21 alec Exp $
 */

//$pattern = "/^([^ ]+)\|([^ ]+)[\s\t]+([^ ]+)\t([^ ]+)\t(.*)/";

$pattern = "/^([0-9]{1,16})\|([0-9]{8})\|(.{1,15})\|(.*)\s(.*)\|([0-9]{23})([0-9]{3})\|(.{0,140})/";

$pid = 7;	// customer ID position in expression
		// if zero - we try to search ID by regexp,
		// invoice number or customer name and forename in entire row
$pname = 5;	// name position 
$plastname = 4; // forename position 
$pvalue = 3;	// value position
$pcomment = 8;  // operation comment position
$pdate = 2;  	// date position

//$date_regexp = '/([0-9]{2})\.([0-9]{2})\.([0-9]{4})/'; // date format (dd.mm.yyyy)
$date_regexp = '/([0-9]{2})([0-9]{2})([0-9]{4})/';

$pday = 1;
$pmonth = 2;
$pyear = 3;
$invoice_regexp = '/.* (\d*)\/LMS\/([0-9]{4}).*/'; 	// format of invoice number
							// default %N/LMS/%Y
$pinvoice_number = 1; // position of invoice number in $invoice_regexp
$pinvoice_year = 2;   // year position in $invoice_regexp

$encoding = 'WINDOWS-1250';  // imported data encoding (for conversion)

$modvalue = FALSE;	// if operation's value is 1000.00, then
			// enabled $modvalue will modify it to 10.00

?>
