Source for file itemclass.php

Documentation is available at itemclass.php


1 <?php
2 /**
3 * @author Jan H. Andersen <jha@ipwsystems.dk>
4 * @author Martin R. Larsen <mrl@ipwsystems.dk>
5 * @copyright {@link http://www.ipwsystems.dk/ IPW Systems a.s}
6 * @license http://opensource.org/licenses/gpl-license.php GNU Public License
7 * @package METAjour
8 * @subpackage core
9 * $Id: itemclass.php,v 1.6 2005/01/07 03:50:13 jan Exp $
10 */
11
12 require_once('basicclass.php');
13
14 class item extends basic {
15
16 function item() {
17 $this->basic();
18 $this->addcolumn('name',0,UI_STRING);
19 $this->addcolumn('content1',0,UI_TEXT);
20 $this->addcolumn('content2',0,UI_TEXT);
21 $this->addcolumn('content3',0,UI_TEXT);
22 $this->addcolumn('price',0,UI_STRING,'','decimal|*|2');
23 $this->addcolumn('vatid',0,UI_RELATION,'vat');
24 $this->addcolumn('image1',0,UI_BINFILE);
25 $this->addcolumn('image2',0,UI_BINFILE);
26 $this->addcolumn('image3',0,UI_BINFILE);
27 $this->addcolumn('exstr1',0,UI_STRING);
28 $this->addcolumn('exstr2',0,UI_STRING);
29 $this->addcolumn('exstr3',0,UI_STRING);
30 $this->addcolumn('exstr4',0,UI_STRING);
31 $this->addcolumn('exstr5',0,UI_STRING);
32 $this->addcolumn('exstr6',0,UI_STRING);
33 $this->addcolumn('exstr7',0,UI_STRING);
34 $this->addcolumn('exstr8',0,UI_STRING);
35 }
36
37 function initLayout() {
38 parent::initLayout();
39 $this->addcolumnstyle('name','width: 100px;');
40 $this->addcolumnstyle('price','width: 100px;');
41 $this->addcolumnstyle('content1','width: 400px; height: 80px');
42 $this->addcolumnstyle('content2','width: 400px; height: 80px');
43 $this->addcolumnstyle('content3','width: 400px; height: 80px');
44 $this->clearRelationDatatypes();
45 $this->clearChildDatatypes();
46 $this->addChildDatatype('item');
47 }
48
49 function stdListCol() {
50 $result = array();
51 $result[] = 'name';
52 $result[] = 'content1';
53 $result[] = 'price';
54 $result[] = 'changed';
55 return $result;
56 }
57
58 }

Documentation generated on Thu, 9 Jun 2005 06:52:41 +0200 by phpDocumentor 1.2.3