PluginProbe
CSS & JavaScript Toolbox / 8.0.2
CSS & JavaScript Toolbox v8.0.2
trunk 0.3 0.8 10 10.1 11 11.2 11.3 11.4 11.5 11.6 11.7 11.8 11.9 11.9.1 12 12.0 12.0.1 12.0.3 12.0.4 12.0.5 12.0.6 12.0.7 6.0 6.0.11 All 60 releases
css-javascript-toolbox / models / package / xml / definition / packagehelper.php

packagehelper.php in CSS & JavaScript Toolbox 8.0.2, at models/package/xml/definition/packagehelper.php

72 lines 1.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 *
4 */
5
6 /**
7 *
8 */
9 class CJT_Models_Package_Xml_Definition_PackageHelper {
10
11 /**
12 * put your comment there...
13 *
14 * @var mixed
15 */
16 protected $id;
17
18 /**
19 * put your comment there...
20 *
21 * @var mixed
22 */
23 protected $name;
24
25 /**
26 * put your comment there...
27 *
28 * @param mixed $packageId
29 * @return CJT_Models_Package_Xml_Definition_Package_Helper
30 */
31 public function __construct($id) {
32 $this->id = $id;
33 }
34
35 /**
36 * put your comment there...
37 *
38 * @param mixed $objectId
39 * @param mixed $objectType
40 * @param mixed $relType
41 */
42 public function associateObject($objectId, $objectType, $relType) {
43 // Initialize.
44 $tblPckObjects = CJTxTable::getInstance('package-objects');
45 // Add Block-Template-Link=>Package reference.
46 $tblPckObjects->setData(array(
47 'packageId' => $this->getId(),
48 'objectId' => $objectId,
49 'objectType' => $objectType,
50 'relType' => $relType,
51 ))->save();
52 // Chain.
53 return $this;
54 }
55
56 /**
57 * put your comment there...
58 *
59 */
60 public function getId() {
61 return $this->id;
62 }
63
64 /**
65 * put your comment there...
66 *
67 */
68 public function getName() {
69 return $this->name;
70 }
71
72 } // ENd class.