Merge pull request #18360 from colemanw/fixMultiInProfile
[civicrm-core.git] / CRM / Contact / Form / Task / Map / Event.php
1 <?php
2 /*
3 +--------------------------------------------------------------------+
4 | Copyright CiviCRM LLC. All rights reserved. |
5 | |
6 | This work is published under the GNU AGPLv3 license with some |
7 | permitted exceptions and without any warranty. For full license |
8 | and copyright information, see https://civicrm.org/licensing |
9 +--------------------------------------------------------------------+
10 */
11
12 /**
13 *
14 * @package CRM
15 * @copyright CiviCRM LLC https://civicrm.org/licensing
16 */
17
18 /**
19 * This class provides the functionality to map the address for group of contacts.
20 */
21 class CRM_Contact_Form_Task_Map_Event extends CRM_Contact_Form_Task_Map {
22
23 /**
24 * Build all the data structures needed to build the form.
25 */
26 public function preProcess() {
27 $ids = CRM_Utils_Request::retrieve('eid', 'Positive',
28 $this, TRUE
29 );
30 $lid = CRM_Utils_Request::retrieve('lid', 'Positive',
31 $this, FALSE
32 );
33 $type = 'Event';
34 self::createMapXML($ids, $lid, $this, TRUE, $type);
35 $this->assign('single', FALSE);
36 $this->assign('skipLocationType', TRUE);
37 $is_public = CRM_Core_DAO::getFieldValue('CRM_Event_DAO_Event', $ids, 'is_public');
38 if ($is_public == 0) {
39 CRM_Utils_System::addHTMLHead('<META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">');
40 }
41 }
42
43 /**
44 * Use the form name to create the tpl file name.
45 *
46 * @return string
47 */
48 public function getTemplateFileName() {
49 return 'CRM/Contact/Form/Task/Map.tpl';
50 }
51
52 }