From 2374f4ca4b0b064118cd6cc33f8315a60715c3d4 Mon Sep 17 00:00:00 2001
From: Sem
Date: Thu, 30 Aug 2012 04:01:58 +0200
Subject: Refactored edit form.
---
languages/en.php | 1 +
models/model.php | 1 -
views/default/event_calendar/css.php | 37 +++-------------
views/default/event_calendar/datetime_edit.php | 2 +-
.../default/event_calendar/repeat_form_element.php | 49 +++++++++-------------
views/default/event_calendar/share_section.php | 6 +--
views/default/forms/event_calendar/edit.php | 42 +++++++++----------
views/default/js/event_calendar/event_calendar.php | 4 +-
8 files changed, 52 insertions(+), 90 deletions(-)
diff --git a/languages/en.php b/languages/en.php
index 8e42580de..dfbe0cda4 100644
--- a/languages/en.php
+++ b/languages/en.php
@@ -291,6 +291,7 @@ You can manage calendar requests for this event here:
'event_calendar:calendar_label' => "Calendar",
'event_calendar:calendar_description' => "Calendar for this event.",
'event_calendar:are_you_sure' => "Are you sure about this change?",
+ 'event_calendar:basic:header' => "Basic info",
'event_calendar:schedule:header' => "Schedule",
'event_calendar:permissions:header' => "Permissions",
'event_calendar:read_access' => "Read access",
diff --git a/models/model.php b/models/model.php
index e7f823d4c..4668f005a 100644
--- a/models/model.php
+++ b/models/model.php
@@ -1541,7 +1541,6 @@ function event_calendar_get_page_content_edit($page_type,$guid,$start_date='') {
elgg_load_js('elgg.event_calendar');
$vars = array();
$vars['id'] = 'event-calendar-edit';
- $vars['name'] = 'event_calendar_edit';
// just in case a feature adds an image upload
$vars['enctype'] = 'multipart/form-data';
diff --git a/views/default/event_calendar/css.php b/views/default/event_calendar/css.php
index 9ef2ecfa1..00cfd6cbb 100644
--- a/views/default/event_calendar/css.php
+++ b/views/default/event_calendar/css.php
@@ -175,39 +175,12 @@ li.event-calendar-filter-menu-show-only {
margin-right: 10px;
}
-.event-calendar-medium-text {
- width: 500px !important;
-}
-
-.event-calendar-edit-form-block label {
- float: left;
- width: 90px;
- margin-top: 5px;
-}
-
-.event-calendar-long-text {
- width: 500px !important;
-}
-
-.event-calendar-edit-form-other-block .mceLayout {
- width: 500px !important;
-}
-
-.event-calendar-edit-form {
- background-color: #FFFFFF;
-}
-
-.event-calendar-edit-form-block {
- width: 90%;
- background-color: #DDDDDD;
- border-width:1px;
- border-style:solid;
- border-color:#bfbfbf;
- padding: 5px;
- margin-bottom: 10px;
- clear: both;
+fieldset > legend {
+ font-weight: bold;
+ font-size: 1.2em;
+ line-height: 1.1em;
+ padding-bottom: 5px;
}
-
.event-calendar-repeating-wrapper {
padding: 0;
margin-top: 5px;
diff --git a/views/default/event_calendar/datetime_edit.php b/views/default/event_calendar/datetime_edit.php
index 64af30f53..7abc3bb62 100644
--- a/views/default/event_calendar/datetime_edit.php
+++ b/views/default/event_calendar/datetime_edit.php
@@ -30,7 +30,7 @@ if ($event_calendar_times != 'no') {
$body .= elgg_view("input/timepicker",array('name' => 'end_time','value'=>$vars['end_time']));
$body .= '';
}
- $body .= '
';
+ $body .= '';
} else {
$body .= '