aboutsummaryrefslogtreecommitdiffstats
path: root/view
diff options
context:
space:
mode:
Diffstat (limited to 'view')
-rw-r--r--view/js/main.js14
-rw-r--r--view/theme/redbasic/js/redbasic.js3
-rw-r--r--view/tpl/cdav_calendar.tpl22
3 files changed, 18 insertions, 21 deletions
diff --git a/view/js/main.js b/view/js/main.js
index 5592fd63d..48159e6e8 100644
--- a/view/js/main.js
+++ b/view/js/main.js
@@ -1160,15 +1160,12 @@ function doreply(parent, ident, owner, hint) {
}
function doscroll(parent, hidden) {
- var back = $('.back-to-reply');
- if(back.length == 0) {
- var pos = Math.round($(window).scrollTop());
- }
- else {
- var pos = back.attr('href').replace(/\D/g,'')
- }
- back.remove();
var x = '#hide-comments-outer-' + hidden.toString();
+ var back = $('.back-to-reply');
+ if(back.length == 0)
+ var pos = $(window).scrollTop();
+ else
+ var pos = back.attr('href').replace(/[^\d|\.]/g,'');
if($(x).length !== 0) {
x = $(x).attr("onclick").replace(/\D/g,'');
var c = '#collapsed-comments-' + x;
@@ -1177,6 +1174,7 @@ function doscroll(parent, hidden) {
pos += $(c).height();
}
}
+ back.remove();
var id = $('[data-mid="' + parent + '"]');
$('html, body').animate({scrollTop:(id.offset().top) - 50}, 'slow');
$('<a href="javascript:doscrollback(' + pos + ');" class="back-to-reply" title="' + aStr['to_reply'] + '"><i class="fa fa-angle-double-down float-right">&nbsp;&nbsp;&nbsp;</i></a>').insertBefore('#wall-item-info-' + id.attr('id').replace(/\D/g,''));
diff --git a/view/theme/redbasic/js/redbasic.js b/view/theme/redbasic/js/redbasic.js
index b8e7946c2..8d3b795cc 100644
--- a/view/theme/redbasic/js/redbasic.js
+++ b/view/theme/redbasic/js/redbasic.js
@@ -21,8 +21,7 @@ $(document).ready(function() {
$('#left_aside_wrapper, #right_aside_wrapper').stick_in_parent({
offset_top: parseInt($('aside').css('padding-top')),
parent: 'main',
- spacer: '.aside_spacer',
- recalc_every: 10
+ spacer: '.aside_spacer'
});
}
diff --git a/view/tpl/cdav_calendar.tpl b/view/tpl/cdav_calendar.tpl
index 88a322339..22579227a 100644
--- a/view/tpl/cdav_calendar.tpl
+++ b/view/tpl/cdav_calendar.tpl
@@ -63,6 +63,11 @@ $(document).ready(function() {
event_uri = '';
$('#id_title').val('New event');
+ $('#id_title').attr('disabled', false);
+ $('#id_dtstart').attr('disabled', false);
+ $('#id_dtend').attr('disabled', false);
+ $('#id_description').attr('disabled', false);
+ $('#id_location').attr('disabled', false);
$('#calendar_select').val($("#calendar_select option:first").val()).attr('disabled', false);
$('#id_dtstart').val(info.date.toUTCString());
$('#id_dtend').val(dtend ? dtend.toUTCString() : '');
@@ -102,6 +107,11 @@ $(document).ready(function() {
$('.section-content-tools-wrapper, #event_form_wrapper').show();
$('#recurrence_warning').hide();
$('#id_title').focus().val('');
+ $('#id_title').attr('disabled', false);
+ $('#id_dtstart').attr('disabled', false);
+ $('#id_dtend').attr('disabled', false);
+ $('#id_description').attr('disabled', false);
+ $('#id_location').attr('disabled', false);
return false;
}
@@ -186,7 +196,6 @@ $(document).ready(function() {
'event_id': event_id,
'event_hash': event_uri,
'xchan': event_xchan,
- //'mid': mid,
'type': 'event',
'preview': 0,
'summary': event.title,
@@ -196,7 +205,6 @@ $(document).ready(function() {
'categories': event.extendedProps.categories,
'desc': event.extendedProps.description,
'location': event.extendedProps.location,
- //'submit': $('#event_submit').val()
})
.fail(function() {
info.revert();
@@ -234,7 +242,6 @@ $(document).ready(function() {
'event_id': event_id,
'event_hash': event_uri,
'xchan': event_xchan,
- //'mid': mid,
'type': 'event',
'preview': 0,
'summary': event.title,
@@ -244,7 +251,6 @@ $(document).ready(function() {
'categories': event.extendedProps.categories,
'desc': event.extendedProps.description,
'location': event.extendedProps.location,
- //'submit': $('#event_submit').val()
})
.fail(function() {
info.revert();
@@ -406,7 +412,6 @@ function on_submit() {
'event_id': event_id,
'event_hash': event_uri,
'xchan': event_xchan,
- //'mid': mid,
'type': 'event',
'preview': 0,
'summary': $('#id_title').val(),
@@ -416,7 +421,6 @@ function on_submit() {
'categories': $('#id_categories').val(),
'desc': $('#id_description').val(),
'location': $('#id_location').val(),
- //'submit': $('#event_submit').val(),
'contact_allow[]': contact_allow,
'group_allow[]': group_allow,
'contact_deny[]': contact_deny,
@@ -508,11 +512,7 @@ function on_more() {
}
function exportDate() {
- alert('not implemented');
- console.log('not implemented');
- //var moment = $('#events-calendar').fullCalendar('getDate');
- //var sT = 'events/' + moment.year() + '/' + (moment.month() + 1) + '/export';
- //window.location.href=sT;
+ window.location.href= 'channel_calendar/export';
}
</script>