Skip to content

Commit

Permalink
Merge branch 'release/3.3.4'
Browse files Browse the repository at this point in the history
  • Loading branch information
Damian committed Oct 20, 2015
2 parents ecc6ec5 + 9337dea commit d9f861f
Show file tree
Hide file tree
Showing 9 changed files with 41 additions and 6 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
3.3.4
Add content height (calendar height) as option for block

3.3.3
Add ICS calendar ; To call calendar use link:
http://DOMAIN/index.php/tools/packages/dsEventCalendar/event_calendar/ical.php?id=1
Expand Down
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,13 @@ If you choose "One day with time" event you can resize event for more days.

Version
----
3.3.3
3.3.4

Changelog
----
3.3.4
Add content height (calendar height) as option for block

3.3.3
Add ICS calendar ; To call calendar use link:
http://DOMAIN/index.php/tools/packages/dsEventCalendar/event_calendar/ical.php?id=1
Expand Down
3 changes: 2 additions & 1 deletion blocks/event_calendar/add.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
'langs' => $langs,
'calendarID' => null,
'lang' => null,
'types' => $types
'types' => $types,
'contentHeight' => null
));
?>
3 changes: 3 additions & 0 deletions blocks/event_calendar/controller.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ function save($data)
$args['calendarID'] = isset($data['calendarID']) ? intval($data['calendarID']) : 0;
$args['typeID'] = isset($data['typeID']) ? intval($data['typeID']) : 0;
$args['lang'] = isset($data['lang']) ? $data['lang'] : 'en-gb';
$args['contentHeight'] = isset($data['contentHeight']) ? $data['contentHeight'] : 'auto';
parent::save($args);
}

Expand All @@ -79,6 +80,7 @@ function add()
$this->set('calendars', $calendars);

$this->set('langs', $this->lang_list);
$this->set('lang','en-gb');

$dsEventCalendar = new \dsEventCalendar\dsEventCalendar();
$types = $dsEventCalendar->getEventTypesForBlock();
Expand All @@ -95,6 +97,7 @@ function edit()

$this->set('langs', $this->lang_list);
$this->set('lang',$this->lang);
$this->set('contentHeight',$this->contentHeight);

$dsEventCalendar = new \dsEventCalendar\dsEventCalendar();
$types = $dsEventCalendar->getEventTypesForBlock();
Expand Down
3 changes: 3 additions & 0 deletions blocks/event_calendar/db.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,8 @@
<field name="typeID" type="C" size="255">
<default value="0"/>
</field>
<field name="contentHeight" type="C" size="255">
<default value="0"/>
</field>
</table>
</schema>
3 changes: 2 additions & 1 deletion blocks/event_calendar/edit.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
'calendarID' => $calendarID,
'lang' => $lang,
'types' => $types,
'typeID' => $typeID
'typeID' => $typeID,
'contentHeight' => $contentHeight
));
?>
22 changes: 21 additions & 1 deletion blocks/event_calendar/form_setup_html.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@
<?php echo t('No calendar exist. Add from one from dashboard.') ?>
</div>
<?php else: ?>
<div style="margin-top: 10px;">
<div>
<h3>
Block settings:
</h3>
<fieldset>
<label for="calendarID"><?php echo t('Select calendar') ?></label>

Expand Down Expand Up @@ -48,5 +51,22 @@
</select>
</div>
</fieldset>
<h3 style="margin-top: 10px;">
Calendar settings:
</h3>

<fieldset>
<label for="contentHeight"><?php echo t("Will make the calendar's content area a pixel height - default auto (empty)") ?></label>


<div style="margin-top: 10px;">
<input
type="number"
name="contentHeight"
class="form-control"
id="contentHeight"
placeholder="auto"
value="<?php echo $contentHeight ?>">
</div>
</div>
<?php endif; ?>
3 changes: 2 additions & 1 deletion blocks/event_calendar/view.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,8 @@
eventLimit: parseInt(settings.eventsInDay)+1,
events: events,
lang: '<?php echo $lang; ?>',
firstDay: settings.startFrom
firstDay: settings.startFrom,
contentHeight: <?php echo $contentHeight == 'auto' || $contentHeight == '' ? "'auto'" : $contentHeight; ?>
});

$(".ds-event-modal .btn-close").on('click',function(){
Expand Down
2 changes: 1 addition & 1 deletion controller.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class Controller extends Package {

protected $pkgHandle = 'dsEventCalendar';
protected $appVersionRequired = '5.7.0.4';
protected $pkgVersion = '3.3.3';
protected $pkgVersion = '3.3.4';
protected $pkgAutoloaderRegistries = array(
'src/dsEventCalendar' => '\dsEventCalendar'
);
Expand Down

0 comments on commit d9f861f

Please sign in to comment.