diff options
author | Robin Appelman <icewind@owncloud.com> | 2012-01-24 00:24:09 +0100 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2012-01-24 00:24:09 +0100 |
commit | cdfb252ceda6a9a97dd6473c472ed21a9948c8cf (patch) | |
tree | 099c7ecf348cb7360c2eb32a449249129399efcc /apps/calendar/js/calendar.js | |
parent | 7ea2923fa8805d91ee7d69dd19d10d450792bafe (diff) | |
parent | 456394d3ec03e2e0d582ded9db1c92d037d13d36 (diff) | |
download | nextcloud-server-cdfb252ceda6a9a97dd6473c472ed21a9948c8cf.tar.gz nextcloud-server-cdfb252ceda6a9a97dd6473c472ed21a9948c8cf.zip |
Merge branch 'master' of gitorious.org:owncloud/owncloud
Diffstat (limited to 'apps/calendar/js/calendar.js')
-rw-r--r-- | apps/calendar/js/calendar.js | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/apps/calendar/js/calendar.js b/apps/calendar/js/calendar.js index 228ea97c2da..afd1b692dd4 100644 --- a/apps/calendar/js/calendar.js +++ b/apps/calendar/js/calendar.js @@ -429,11 +429,17 @@ Calendar={ } }, submit:function(button, calendarid){ - var displayname = $("#displayname_"+calendarid).val(); + var displayname = $.trim($("#displayname_"+calendarid).val()); var active = $("#edit_active_"+calendarid+":checked").length; var description = $("#description_"+calendarid).val(); var calendarcolor = $("#calendarcolor_"+calendarid).val(); - + if(displayname == ''){ + $("#displayname_"+calendarid).css('background-color', '#FF2626'); + $("#displayname_"+calendarid).focus(function(){ + $("#displayname_"+calendarid).css('background-color', '#F8F8F8'); + }); + } + var url; if (calendarid == 'new'){ url = OC.filePath('calendar', 'ajax', 'createcalendar.php'); @@ -449,6 +455,11 @@ Calendar={ if (calendarid == 'new'){ $('#choosecalendar_dialog > table').append('<tr><td colspan="6"><a href="#" onclick="Calendar.UI.Calendar.newCalendar(this);"><input type="button" value="' + newcalendar + '"></a></td></tr>'); } + }else{ + $("#displayname_"+calendarid).css('background-color', '#FF2626'); + $("#displayname_"+calendarid).focus(function(){ + $("#displayname_"+calendarid).css('background-color', '#F8F8F8'); + }); } }, 'json'); }, @@ -677,6 +688,9 @@ $(document).ready(function(){ $('#calendar_holder').fullCalendar('option', 'aspectRatio', 1.35); } }, + columnFormat: { + week: 'ddd d. MMM' + }, selectable: true, selectHelper: true, select: Calendar.UI.newEvent, |