Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add localization to Brazilian Portuguese #6

Open
wants to merge 54 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
9bbd549
Move files to root directory
dro123 Dec 30, 2012
4609562
Remove unneeded or duplicate files
dro123 Dec 30, 2012
cdf7754
Use the plugin name for controllers, views, helpers, etc.
dro123 Dec 30, 2012
5fcd41a
Update to Redmine >= 2.0 and add localization
dro123 Dec 30, 2012
9681a4b
Add plugin settings instead of hardcoding IDs
dro123 Dec 30, 2012
3c1bc29
Update README and bump version to 2.0.0
dro123 Dec 30, 2012
365ad19
Fix screenshot URL in README
dro123 Jan 1, 2013
2d49901
Add rake command to 'Install' in README
dro123 Jan 4, 2013
6e38dbf
Add localization for Simplified Chinese
archonwang Jan 5, 2013
86f1d9b
Use API key for AJAX request for non-public projects
dro123 Jan 8, 2013
64dca91
Use configured custom field ID for issue queries
dro123 Jan 16, 2013
d852780
Update README for cases where authentication is needed
dro123 Jan 17, 2013
3ca9c8f
Allow project managers to change all meetings
dro123 Apr 19, 2014
a38ceb3
Don't send notification mails on create/update
dro123 Apr 19, 2014
7df764e
Add an option to select categories for meetings
dro123 Apr 19, 2014
6f06248
Minor cleanups
dro123 Apr 20, 2014
1c52da1
Add an option to support multiple projects
dro123 Apr 20, 2014
01f0440
Add a default issue status to plugin settings
dro123 Apr 23, 2014
52fa5a3
URL encode meeting room and date filter in AJAX requests
dro123 Apr 23, 2014
d50bcff
Add an option to allow changing of bookings in the past
dro123 May 15, 2014
01cfa32
Add possibility to edit events directly with the mouse
dro123 May 15, 2014
f2c61ef
Limit access to projects based on the user rights and add per project…
dro123 May 15, 2014
987a36a
Add tracker status CSS class names
dro123 Nov 11, 2014
162825f
Add turkish localization file
dro123 Nov 12, 2014
79b2255
Add compatibility with rails >= 4
dro123 Apr 22, 2015
5795b6c
Mark redmine 3.x as supported in the docs
dro123 Apr 22, 2015
126681b
Fix compatibility with rails >= 4
dro123 Apr 23, 2015
3c4fe45
Create pt-br.yml
aceccarelli Jun 15, 2015
46990f4
Merge pull request #20 from aceccarelli/master
dro123 Jun 15, 2015
d1813fb
New libraries, documentation and new features
dro123 Sep 25, 2015
9e153e9
Fix db migrate file ending
dro123 Oct 28, 2015
0ecb33b
Russian translation
ddk85 Oct 29, 2015
bfb1542
Merge pull request #23 from ddk85/master
dro123 Oct 29, 2015
43740cc
Added author_url for easy search code from Redmine
ddk85 Oct 30, 2015
dc68887
Fix Russian translation
ddk85 Oct 30, 2015
6df90f8
Merge pull request #24 from ddk85/master
dro123 Oct 31, 2015
95e5c1a
Add an option to show weekends
dro123 Nov 27, 2015
f117379
Merge branch 'master' of github.com:dro123/redmine_meeting_room_calendar
dro123 Nov 27, 2015
73e0d3d
Respect redmines 'first day of week' setting
dro123 Dec 1, 2015
15a5e6e
Allow overlap
kostyfisik Dec 1, 2015
95abe93
update default value
kostyfisik Dec 1, 2015
9e8fbe6
update default value
kostyfisik Dec 2, 2015
0860ed9
Merge pull request #31 from kostyfisik/master
dro123 Dec 2, 2015
04649f3
Update to fullcalendar 2.9.1 and fix 'all' rooms query for redmine v<3.0
dro123 Oct 4, 2016
cf57070
Respect redmine date and time format settings
dro123 Oct 4, 2016
fc7a435
Add Italian translation
dro123 Jan 21, 2018
8d8f996
Updated the incorrect language identifier
shash66 Mar 27, 2018
2af056c
Merge pull request #47 from shash66/patch-1
dro123 Mar 28, 2018
ab54e52
rails 5.1+ & redmine 4.1 compatibility
vany-egorov Feb 13, 2020
e663093
Merge pull request #51 from x-redmine/release/4.1.x
dro123 Apr 9, 2020
0b1b9c5
Update 001_add_meeting_rooms_to_projects.rb
aescariom May 22, 2020
c639ccf
Merge pull request #52 from aescariom/master
dro123 May 23, 2020
4c4c822
add Japanese language
guskma Jun 24, 2020
d7556d0
Merge pull request #55 from guskma/lang-ja
dro123 Jun 27, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update to Redmine >= 2.0 and add localization
This updates the views to Rails >= 3 and adds
localizations for all texts/dates in English
and German.

Additionally this removes unneeded fields in
the 'create new' and 'update' meeting formular.

Fixed:
Loading more than 50 meetings.

Signed-off-by: Tobias Droste <[email protected]>
dro123 committed Dec 31, 2012
commit 5fcd41ae9a6514b048764889b993770458bec8f3
9 changes: 4 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -7,14 +7,15 @@ This Redmine plugin allows you to book and thence display meetings on a calendar
Requirements
------------

* Redmine 1.3.x or 1.4.x
* Redmine 2.x

Install
-------

Clone the plugin source code into your Redmine's plugin directory.

git clone https://github.com/QBurst/qbmeetingroomplugin.git
git clone https://github.com/dro123/redmine_meeting_room_calendar.git
(original code: git clone https://github.com/QBurst/qbmeetingroomplugin.git)

**NOTE:** Make sure the plugin directory is name `redmine_meeting_room_calendar`.

@@ -66,7 +67,5 @@ How it Works
* Besides booking, a meeting room can also be edited; only by the author of the room.
* The plug-in requires some details like project_id and tracker_id to be hard coded in meeting_calendars_controller.rb
* The custom_field values from the database needs to be hard coded in meeting_calendars_controller.rb
* The custom_field values from the rendered json needs to be hard coded in meeting_calendar.js
* In meeting_calendars_controller.rb, lines 6,8,11,13,15,25 and 40 needs hard coded values.
* In meetingcalendar.js, lines lines 52,54,56 and 58 needs hard coded values.
* In meeting_calendars_controller.rb, lines 7 - 11 needs hard coded values.
* In spite some hard coding, the plug-in will be an added asset for better project management.
131 changes: 91 additions & 40 deletions app/controllers/meeting_room_calendar_controller.rb
Original file line number Diff line number Diff line change
@@ -1,58 +1,109 @@
class MeetingRoomCalendarController < ApplicationController
unloadable
before_filter :require_login


def initialize
@project_id = "215" #Hard Coded project_id for Book Meeting Room Project
@tracker_id = '9' #Hard Coded tracker_id for Book Meeting Room Project
@custom_field = CustomField.all
@start_time = @custom_field[2].possible_values #Hard Coded custom field value for start times for Book Meeting Room Project
@end_time = @custom_field[3].possible_values #Hard Coded custom field value for end times for Book Meeting Room Project
@meeting_rooms=@custom_field[4].possible_values #Hard Coded custom field value for meeting rooms for Book Meeting Room Project
super()

@project_id = "215" #Hard Coded project_id for Book Meeting Room Project
@tracker_id = '9' #Hard Coded tracker_id for Book Meeting Room Project
@custom_field_id_room = 0 #Hard Coded
@custom_field_id_start = 0 #Hard Coded
@custom_field_id_end = 0 #Hard Coded

if check_settings()
@start_time = CustomField.find_by_id(@custom_field_id_start).possible_values
@end_time = CustomField.find_by_id(@custom_field_id_end).possible_values
@meeting_rooms = CustomField.find_by_id(@custom_field_id_room).possible_values
end
end

def index
@user = User.current.id
if !check_settings()
return
end

@project = Project.find_by_id(@project_id);
@user = User.current.id
@user_name = User.current.name
@user_last_name = User.current.name(:lastname_coma_firstname)
@assignable_users = @project.assignable_users.map { |user| [user.name, user.id] }
end

def create
recur_meeting = params[:recur].to_i
meeting_day = params[:custom_field_values]["6"]
meeting_date = Date.parse(meeting_day)

while recur_meeting > 0
week_day = meeting_date.wday # 0->Sunday, 6-> Saturday
if(week_day!=6 && week_day!=0)
@calendar_issue= Issue.new
@calendar_issue.project_id = @project_id
@calendar_issue.tracker_id = @tracker_id
@calendar_issue.priority_id =params[:priority_id]
@calendar_issue.subject =params[:subject]
@calendar_issue.status_id =params[:status_id]
@calendar_issue.author_id =params[:author_id]
custom_fields = params[:custom_field_values]
custom_fields['6'] = meeting_date.strftime("%Y-%m-%d")
@calendar_issue.custom_field_values=custom_fields
@calendar_issue.save!
else
recur_meeting +=1
end
meeting_date += 1
recur_meeting -=1
end
recur_meeting = params[:recur]
recur_type = params[:periodtype].to_i
recur_period = params[:period].to_i
meeting_day = params[:start_date]
meeting_date = Date.parse(meeting_day)

if (recur_meeting != "true")
recur_type = 1
recur_period = 1
end

while recur_period > 0
week_day = meeting_date.wday # 0->Sunday, 6-> Saturday
if(week_day!=6 && week_day!=0)
@calendar_issue= Issue.new
@calendar_issue.project_id = @project_id
@calendar_issue.tracker_id = @tracker_id
@calendar_issue.subject = params[:subject]
@calendar_issue.author_id = params[:author_id]
@calendar_issue.assigned_to_id = params[:assigned_to_id]
@calendar_issue.start_date = meeting_date
@calendar_issue.due_date = @calendar_issue.start_date
@calendar_issue.custom_field_values = params[:custom_field_values]
@calendar_issue.save!
else
recur_period +=1
end
meeting_date += recur_type
recur_period -=1
end
end

def update
@calendar_issue= Issue.new
meeting_day = params[:start_date]
meeting_date = Date.parse(meeting_day)

@calendar_issue = Issue.new
@calendar_issue.project_id = @project_id
@calendar_issue.tracker_id = @tracker_id
@calendar_issue= Issue.find(params[:event_id])
@calendar_issue.priority_id=params[:priority_id]
@calendar_issue.subject=params[:subject]
@calendar_issue.status_id=params[:status_id]
@calendar_issue.author_id=params[:author_id]
@calendar_issue.custom_field_values=params[:custom_field_values]
@calendar_issue = Issue.find(params[:event_id])
@calendar_issue.subject = params[:subject]
@calendar_issue.assigned_to_id = params[:assigned_to_id]
@calendar_issue.start_date = meeting_date
@calendar_issue.due_date = @calendar_issue.start_date
@calendar_issue.custom_field_values = params[:custom_field_values]
@calendar_issue.save!
end

def delete
@calendar_issue = Issue.find(params[:event_id])
begin
@calendar_issue.reload.destroy
rescue ::ActiveRecord::RecordNotFound # raised by #reload if issue no longer exists
# nothing to do, issue was already deleted (eg. by a parent)
end
end

def check_settings()
if @project_id == nil || @project_id.to_s == "0" || @project_id.to_s == ""
return false
end
if @tracker_id == nil || @tracker_id.to_s == "0" || @project_id.to_s == ""
return false
end
if @custom_field_id_room == nil || @custom_field_id_room.to_s == "0" || @custom_field_id_room.to_s == ""
return false
end
if @custom_field_id_start == nil || @custom_field_id_start.to_s == "0" || @custom_field_id_start.to_s == ""
return false
end
if @custom_field_id_end == nil || @custom_field_id_end.to_s == "0" || @custom_field_id_end.to_s == ""
return false
end

return true
end
end
Empty file.
108 changes: 74 additions & 34 deletions app/views/meeting_room_calendar/index.html.erb
Original file line number Diff line number Diff line change
@@ -1,58 +1,98 @@
<h2><%= l(:label_name) %></h2>

<%= stylesheet_link_tag 'fullcalendar',:plugin => 'redmine_meeting_room_calendar' %>
<%= stylesheet_link_tag 'jquery-ui-1.7.3.custom.css',:plugin => 'redmine_meeting_room_calendar' %>
<%= stylesheet_link_tag 'fullcalendar',:plugin => 'redmine_meeting_room_calendar',:media => 'print' %>
<%= stylesheet_link_tag 'meeting_calendar',:plugin => 'redmine_meeting_room_calendar' %>
<%= stylesheet_link_tag 'jquery.alerts.css',:plugin => 'redmine_meeting_room_calendar' %>

<script type="text/javascript">
var fieldIdRoom = "<%= @custom_field_id_room %>";
var fieldIdStart = "<%= @custom_field_id_start %>";
var fieldIdEnd = "<%= @custom_field_id_end %>";

var pluginName = "meeting_room_calendar";

var project_id = <%= @project_id %>;
var user_last_name = "<%= @user_last_name %>";

var langBookedBy = "<%= l(:label_booked_by) %>";
var langAssignedTo = "<%= l(:label_assigned_to) %>";
var langStartTime = "<%= l(:label_start_time) %>";
var langEndTime = "<%= l(:label_end_time) %>";
var langInfo = "<%= l(:label_info) %>";
var langAlert = "<%= l(:label_alert) %>";
var langWarningEditPast = "<%= l(:label_warning_edit_past) %>";
var langWarningCreatePast = "<%= l(:label_warning_create_past) %>";
var langWarningUpdatePast = "<%= l(:label_warning_update_past) %>";
var langWarningWeekend = "<%= l(:label_warning_weekend) %>";
var langWarningFieldsMandatory = "<%= l(:label_warning_fields_mandatory) %>";
var langUpdateEvent = "<%= l(:label_update_event) %>";
var langCreateEvent = "<%= l(:label_create_event) %>";
var langInvalidSubject = "<%= l(:label_invalid_subject) %>";
var langRoomAlreadyBooked = "<%= l(:label_room_already_booked) %>";
var langToday = "<%= l(:label_today) %>";
var langDay = "<%= l(:label_day) %>";
var langWeek = "<%= l(:label_week) %>";
var langMonth = "<%= l(:label_month) %>";

var langDateTimeTimeTitleFormatDay = "<%= l(:datetime_title_format_day) %>";
var langDateTimeTimeTitleFormatWeek = "<%= l(:datetime_title_format_week) %>";
var langDateTimeTimeTitleFormatMonth = "<%= l(:datetime_title_format_month) %>";
var langDateTimeTimeColumnFormatDay = "<%= l(:datetime_column_format_day) %>";
var langDateTimeTimeColumnFormatWeek = "<%= l(:datetime_column_format_week) %>";
var langDateTimeTimeColumnFormatMonth = "<%= l(:datetime_column_format_month) %>";
var langDateTimeTimeEntryFormatTime = "<%= l(:datetime_entry_format_time) %>";

var langDateTimeMin = "<%= l(:datetime_min) %>";
var langDateTimeMax = "<%= l(:datetime_max) %>";
var langDateTimeTimeFormat = "<%= l(:datetime_time_format) %>";
var langAbbrDayNames = <%= raw l(:abbr_day_names) %>;
var langDayNames = <%= raw l(:day_names) %>;
var langAbbrMonthNames = <%= raw l(:abbr_month_names) %>;
var langMonthNames = <%= raw l(:month_names) %>;
var langFirstDay = <%= raw l(:first_day) %>;
var langDateFormat = "<%= l(:date_format) %>";
</script>

<%= javascript_include_tag 'jquery-1.7.1.min.js' ,:plugin => 'redmine_meeting_room_calendar'%>
<%= javascript_include_tag 'jquery.qtip-1.0.0-rc3.min.js',:plugin => 'redmine_meeting_room_calendar'%>
<%= javascript_include_tag 'jquery-ui.min.js',:plugin => 'redmine_meeting_room_calendar' %>
<%= javascript_include_tag 'fullcalendar',:plugin => 'redmine_meeting_room_calendar'%>
<%= javascript_include_tag 'meetingcalendar',:plugin => 'redmine_meeting_room_calendar'%>
<%= javascript_include_tag 'jquery.alerts.js',:plugin => 'redmine_meeting_room_calendar'%>
<!-- setting the project id to the script file -->
<script type="text/javascript">
var project_id = <%= @project_id %>
</script>

<div style="padding-bottom:15px; width:540px">
Go To: <%= text_field_tag :datepicker %>
<%= l(:label_goto) %>: <%= text_field_tag :datepicker %>
<!-- Meeting Rooms List -->
Meeting Room
<%= l(:label_meeting_room) %>
<%= select_tag("meeting_rooms",options_for_select(@meeting_rooms)) %>
<div id="loading">&nbsp;</div>
</div>
<!-- fullcalendar target div -->
<div id='calendar'></div>
<div class="saveMeetingModal">
<div class="field">
<%=label_tag 'Subject'%><%= text_field_tag :subject,nil,:maxlength => 50 %>
</div>
<div class="field">
<%= l(:field_status) %><%= collection_select(:issue, :status_id, IssueStatus.find(1, 5, 9), :id, :name) %>
</div>
<div class="field">
<%= l(:field_priority) %><%= collection_select(:issue, :priority_id, IssuePriority.all, :id, :name) %>
</div>
<div class="field">
<%=label_tag 'Start Time'%><%= select_tag "start_time", options_for_select(@start_time) %>
</div>
<div class="field">
<%=label_tag 'End Time'%><%= select_tag "end_time", options_for_select(@end_time) %>
</div>
<div class="field">
<em style="font-size:9px">(All fields are mandatory)</em>
</div>
<div class="recurfield">
<%=label_tag 'Recur'%><%= check_box_tag 'recurCheckbox'%>
</div>
<div id ="recur_div">
<div class="field">
<label id ='recur1'> 1 Week <%= radio_button_tag 'Week', '5', :true %></label>&nbsp;&nbsp;
<label id ='recur2'> 2 Week <%= radio_button_tag 'Week', '10' %></label>
</div>
</div>
<%= submit_tag "Save", :type => 'button',:id=>"save_meeting" %>
<div class="formLayout">
<%= label_tag("meeting_date", l(:label_meeting_date)) %><%= text_field_tag("meeting_date") %><br/>
<%= label_tag(:subject, l(:label_subject)) %><%= text_field_tag :subject,@user_last_name,:maxlength => 50 %><br/>
<%= label_tag("start_time", l(:label_start_time)) %><%= select_tag "start_time", options_for_select(@start_time) %><br/>
<%= label_tag("end_time", l(:label_end_time)) %><%= select_tag "end_time", options_for_select(@end_time) %><br/>
<%= label_tag(:assigned_to_id, l(:label_assigne_to)) %> <%= select_tag :assigned_to_id, options_for_select(@assignable_users, @user) %><br/>
<div class="field">
<em style="font-size:9px"><%= l(:label_warning_fields_mandatory) %></em>
</div>
<div class="recurfield">
<%= label_tag('recurCheckbox', l(:label_recur)) %><%= check_box_tag 'recurCheckbox' %><br/>
<div id ="recur_div">
<label></label><%= select_tag "periodtype", options_for_select({l(:label_daily) => 1, l(:label_weekly) => 7, l(:label_biweekly) => 14}, 1) %><br/>
<label></label><%= text_field_tag "period",5,:maxlength => 2, :size => 3 %> <%= l(:label_count) %>
</div>
</div>
</div>
<%= submit_tag l(:label_save), :type => 'button',:id=>"save_meeting" %>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<%= submit_tag l(:label_delete), :type => 'button',:id=>"delete_meeting" %>
<%= hidden_field_tag :author_id, @user %>
<%= hidden_field_tag :user_name, @user_name %>
<%= hidden_field_tag :event_id, '' %>
<%= hidden_field_tag :issue_id, @issue_id %>
</div>
<% html_title(l(:label_name)) -%>
32 changes: 16 additions & 16 deletions assets/javascripts/fullcalendar.js
Original file line number Diff line number Diff line change
@@ -44,35 +44,35 @@ var defaults = {

// time formats
titleFormat: {
month: 'MMMM yyyy',
week: "MMM d[ yyyy]{ '&#8212;'[ MMM] d yyyy}",
day: 'dddd, MMM d, yyyy'
month: langDateTimeTimeTitleFormatMonth,
week: langDateTimeTimeTitleFormatWeek,
day: langDateTimeTimeTitleFormatDay
},
columnFormat: {
month: 'ddd',
week: 'ddd M/d',
day: 'dddd M/d'
month: langDateTimeTimeColumnFormatMonth,
week: langDateTimeTimeColumnFormatWeek,
day: langDateTimeTimeColumnFormatDay
},
timeFormat: { // for event elements
'': 'h(:mm)t' // default
'': langDateTimeTimeEntryFormatTime // default
},

// locale
isRTL: false,
firstDay: 0,
monthNames: ['January','February','March','April','May','June','July','August','September','October','November','December'],
monthNamesShort: ['Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec'],
dayNames: ['Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday'],
dayNamesShort: ['Sun','Mon','Tue','Wed','Thu','Fri','Sat'],
firstDay: langFirstDay,
monthNames: langMonthNames,
monthNamesShort: langAbbrMonthNames,
dayNames: langDayNames,
dayNamesShort: langAbbrDayNames,
buttonText: {
prev: '&nbsp;&#9668;&nbsp;',
next: '&nbsp;&#9658;&nbsp;',
prevYear: '&nbsp;&lt;&lt;&nbsp;',
nextYear: '&nbsp;&gt;&gt;&nbsp;',
today: 'today',
month: 'month',
week: 'week',
day: 'day'
today: langToday,
month: langMonth,
week: langWeek,
day: langDay
},

// jquery-ui theming
966 changes: 542 additions & 424 deletions assets/javascripts/meetingcalendar.js

Large diffs are not rendered by default.

56 changes: 56 additions & 0 deletions config/locales/de.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# German strings go here for Rails i18n
de:
label_name: "Besprechungszimmer"
label_meeting_date: "Datum"
label_booked_by: "Gebucht von"
label_assigned_to: "Zugewiesene an"
label_assigne_to: "Zuweisen an"
label_start_time: "Beginn"
label_end_time: "Ende"
label_info: "Info"
label_alert: "Warnung"
label_warning_edit_past: "Sie können keine Meetings in der Vergangenheit ändern"
label_warning_create_past: "Sie können keine Meetings in der Vergangenheit buchen"
label_warning_update_past: Sie können keine Meetings in die Vergangenheit buchen"
label_warning_weekend: "Am Wochenende können keine Räume gebucht werden"
label_warning_fields_mandatory: "Alle Eingabefelder sind Pflichtfelder"
label_update_event: "Buchung ändern"
label_create_event: "Buchung erstellen"
label_invalid_subject: "Bitte ein gültigen Titel angeben"
label_room_already_booked: "Besprechungszimmer bereits gebucht"
label_goto: "Gehe zu"
label_meeting_room: "Besprechungszimmer"
label_subject: "Titel"
label_recur: "Wiederkehrend"
label_save: "Speichern"
label_delete: "Löschen"
label_today: "Heute"
label_day: "Tag"
label_week: "Woche"
label_month: "Monat"
label_weekly: "Wöchentlich"
label_biweekly: "Zweiwöchentlich"
label_daily: "Täglich"
label_count: "mal"
label_missing_config: "Plugin nicht korrekt konfiguriert! Siehe Administration -> Plugins -> Konfiguration"
label_setting_project_id: "Projekt"
label_setting_tracker_id: "Tracker"
label_setting_custom_field_id_room: "Benutzerfeld 'Raum'"
label_setting_custom_field_id_start: "Benutzerfeld 'Start'"
label_setting_custom_field_id_end: "Benutzerfeld 'Ende'"
label_setting_show_project_menu: "Projektmenü anzeigen"

datetime_title_format_day: "dddd, d. MMM, yyyy"
datetime_title_format_week: "d. MMM[ yyyy]{ - d. MMM yyyy}"
datetime_title_format_month: "MMMM yyyy"
datetime_column_format_day: "ddd"
datetime_column_format_week: "ddd d.M"
datetime_column_format_month: "dddd d.M"
datetime_entry_format_time: "HH(:mm)"

day_names: "['Sonntag', 'Montag', 'Dienstag', 'Mittwoch', 'Donnerstag', 'Freitag', 'Samstag']"
abbr_day_names: "['So', 'Mo', 'Di', 'Mi', 'Do', 'Fr', 'Sa']"
month_names: "['Januar', 'Februar', 'März', 'April', 'Mai', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Dezember']"
abbr_month_names: "['Jan', 'Feb', 'Mär', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Okt', 'Nov', 'Dez']"
first_day: 1
date_format: "dd.mm.yy"
59 changes: 58 additions & 1 deletion config/locales/en.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,60 @@
# English strings go here for Rails i18n
en:
my_label: "My label"
label_name: "Meeting rooms"
label_meeting_date: "Date"
label_booked_by: "Booked by"
label_assigned_to: "Assigned to"
label_assigne_to: "Assign to"
label_start_time: "Start"
label_end_time: "End"
label_info: "Info"
label_alert: "Alert"
label_warning_edit_past: "You cannot edit past meetings"
label_warning_create_past: "You cannot book a meeting in past"
label_warning_update_past: "You cannot update meetings to past"
label_warning_weekend: "You can't book meetings on a weekend"
label_warning_fields_mandatory: "All fields are mandatory"
label_update_event: "Update an Event"
label_create_event: "Create an Event"
label_invalid_subject: "Please enter a valid subject"
label_room_already_booked: "Meeting room already booked"
label_goto: "Go to"
label_meeting_room: "Meeting room"
label_subject: "Subject"
label_recur: "Recur"
label_save: "Save"
label_delete: "Delete"
label_today: "Today"
label_day: "Day"
label_week: "Week"
label_month: "Month"
label_weekly: "Weekly"
label_biweekly: "Biweekly"
label_daily: "Daily"
label_count: "times"
label_missing_config: "Plugin not configured correctly! See Administration -> Plugins -> Configuration"
label_setting_project_id: "Project"
label_setting_tracker_id: "Tracker"
label_setting_custom_field_id_room: "Custom field 'Room'"
label_setting_custom_field_id_start: "Custom field 'Start'"
label_setting_custom_field_id_end: "Custom field 'End'"
label_setting_show_project_menu: "Show project menu"

datetime_title_format_day: "dddd, MMM d, yyyy"
datetime_title_format_week: "MMM d[ yyyy]{ -[ MMM] d yyyy}"
datetime_title_format_month: "MMMM yyyy"
datetime_column_format_day: "ddd"
datetime_column_format_week: "ddd M/d"
datetime_column_format_month: "dddd M/d"
datetime_entry_format_time: "h(:mm)t"

day_names: " ['Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday']"
abbr_day_names: "['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat']"
month_names: "['January','February','March','April','May','June','July','August','September','October','November','December']"
abbr_month_names: "['Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec']"
first_day: 0
date_format: "mm/dd/yy"

datetime_min: "6:00am"
datetime_max: "9:00pm"
datetime_time_format: "HH:mm"
12 changes: 7 additions & 5 deletions config/routes.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
ActionController::Routing::Routes.draw do |map|
# Plugin's routes
# See: http://guides.rubyonrails.org/routing.html

map.connect '/meeting_room_calendar', :controller => 'meeting_room_calendar', :action => 'index'
map.connect '/meeting_room_calendar/create', :controller => 'meeting_room_calendar', :action => 'create'
map.connect '/meeting_room_calendar/update', :controller => 'meeting_room_calendar', :action => 'update'
end
match 'meeting_room_calendar', :to => 'meeting_room_calendar#index'
match 'meeting_room_calendar/index', :to => 'meeting_room_calendar#index'
match 'meeting_room_calendar/create', :to => 'meeting_room_calendar#create'
match 'meeting_room_calendar/update', :to => 'meeting_room_calendar#update'
match 'meeting_room_calendar/delete', :to => 'meeting_room_calendar#delete'
8 changes: 3 additions & 5 deletions init.rb
Original file line number Diff line number Diff line change
@@ -5,12 +5,10 @@
author 'QBurst, Tobias Droste'
description 'This is a plugin for Redmine to see meeting rooms on a particular day on the calendar'
version '1.9.9'
url 'http://www.qburst.com'
author_url 'http://www.qburst.com/company/about'
requires_redmine :version_or_higher => '2.0.0'


permission :meeting_room_calendar, { :meeting_calendars => [:index] }, :public => true
menu :top_menu, :meeting_room_calendar, { :controller => 'meeting_room_calendar', :action => 'index' }, :caption => 'Book Meeting Room', :after => :help
permission :meeting_room_calendar, { :meeting_room_calendar => [:index] }, :public => true
menu :top_menu, :meeting_room_calendar, { :controller => 'meeting_room_calendar', :action => 'index' }, :caption => :label_name, :after => :help
end