Source for file contactclass.php

Documentation is available at contactclass.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: contactclass.php,v 1.7 2005/01/07 03:48:22 jan Exp $
10 */
11
12 require_once('basicclass.php');
13
14 class contact extends basic {
15
16 function contact() {
17 $this->basic();
18 $this->addcolumn('companyid',0,UI_RELATION,'company');
19 $this->addcolumn('name',0,UI_STRING);
20 $this->addcolumn('binfile1',0,UI_BINFILE_THUMB);
21 $this->addcolumn('address1',0,UI_STRING);
22 $this->addcolumn('address2',0,UI_STRING);
23 $this->addcolumn('address3',0,UI_STRING);
24 $this->addcolumn('address4',0,UI_STRING);
25 $this->addcolumn('postalcode',0,UI_STRING);
26 $this->addcolumn('city',0,UI_STRING);
27 $this->addcolumn('state',0,UI_STRING);
28 $this->addcolumn('country',0,UI_STRING);
29 $this->addcolumn('telephone1',0,UI_STRING);
30 $this->addcolumn('telephone2',0,UI_STRING);
31 $this->addcolumn('telephone3',0,UI_STRING);
32 $this->addcolumn('telefax',0,UI_STRING);
33 $this->addcolumn('website',0,UI_STRING,'','');
34 $this->addcolumn('email1',0,UI_STRING,'','');
35 $this->addcolumn('email2',0,UI_STRING,'','');
36 $this->addcolumn('email3',0,UI_STRING,'','');
37 $this->addcolumn('timezone',0,UI_DECIMAL);
38 $this->addcolumn('birthday',0,UI_STRING);
39 $this->addcolumn('comment',0,UI_TEXT);
40
41 $this->removeview('createvariant');
42 }
43
44 function initLayout() {
45 basic::initLayout();
46 $this->byside3('postalcode','city', 'state');
47 $this->byside3('telephone1','telephone2','telephone3');
48 $this->addcolumnstyle('postalcode','width: 50px;');
49 $this->addcolumnstyle('city','width: 125px;');
50 $this->addcolumnstyle('state','width: 50px;');
51 $this->addcolumnstyle('telephone1','width: 75px;');
52 $this->addcolumnstyle('telephone2','width: 75px;');
53 $this->addcolumnstyle('telephone3','width: 75px;');
54 $this->addcolumnstyle('comment','width: 80%; height: 150px');
55 $this->addRelationDatatype('letter','objectid','contactid');
56 }
57
58 function stdListCol() {
59 $arr[] = 'name';
60 $arr[] = 'address1';
61 $arr[] = 'postalcode';
62 $arr[] = 'city';
63 $arr[] = 'telephone1';
64 $arr[] = 'email1';
65 $arr[] = 'changed';
66 return $arr;
67 }
68
69 }

Documentation generated on Thu, 9 Jun 2005 06:51:44 +0200 by phpDocumentor 1.2.3