Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
135 commits
Select commit Hold shift + click to select a range
4fe396e
Merge branch 'develop' into berta
4D44H May 1, 2017
8d86340
Merge branch 'develop' into berta
4D44H May 4, 2017
87c8098
Merge branch 'develop' into berta
4D44H May 4, 2017
a746a33
Merge branch 'develop' into berta
4D44H May 6, 2017
4dc0df3
Add temporary SWP login
4D44H Jun 23, 2017
ef72307
Merge remote-tracking branch 'origin/develop' into berta
P1tt187 Jun 25, 2017
09e75a6
[Icons] Change user icons for FREI, extern and ex-candidate
4D44H Jul 12, 2017
ba92926
Merge pull request #241 from ILSCeV/feature/userIconUpdate
4D44H Jul 15, 2017
22beb06
Merge branch 'develop' into berta
P1tt187 Aug 27, 2017
df19f44
fix css bugs in week view
P1tt187 Aug 27, 2017
945fbb0
Revert "fix css bugs in week view"
P1tt187 Aug 27, 2017
07f5aeb
rename css classes in week view
P1tt187 Aug 27, 2017
e030dc7
correct z-index for back-to-top
P1tt187 Aug 27, 2017
0323dde
Add whitespace below stats year/month selector
4D44H Aug 27, 2017
6cd047c
fix colors also for public events
P1tt187 Aug 27, 2017
a0f875e
Merge remote-tracking branch 'origin/develop' into berta
P1tt187 Aug 29, 2017
66d7d94
Merge remote-tracking branch 'origin/develop'
P1tt187 Aug 29, 2017
99cfd80
Update UpdateLara.php
P1tt187 Jan 25, 2018
b3f78a5
Merge tag '2.7.0' into berta
P1tt187 Jan 25, 2018
65bfa89
avoid errors when updating lara
P1tt187 Jan 25, 2018
38bed8a
in case bd club issn't already createt, create it
P1tt187 Jan 27, 2018
494ce24
remove syntax error
P1tt187 Jan 28, 2018
d05170b
fix import
P1tt187 Jan 28, 2018
933f455
search case sensitive for clubs
P1tt187 Jan 29, 2018
8bc7ace
make translation more clear
P1tt187 Jan 29, 2018
f02a6c3
don't show additional fields if not set
P1tt187 Jan 29, 2018
e1f95c5
make filter editable
P1tt187 Jan 29, 2018
12048aa
show additional fields only when they are set
P1tt187 Jan 29, 2018
f1d5e0f
make type comparable again
P1tt187 Jan 29, 2018
df46f4f
make facebook_done comparable
P1tt187 Jan 29, 2018
e9d759d
Update ClubEventController.php
P1tt187 Jan 31, 2018
49cb337
Add BD preview login
4D44H Jan 30, 2018
e4af177
add day view to main site
P1tt187 Feb 2, 2018
7160d4b
Merge remote-tracking branch 'origin/berta'
P1tt187 Feb 13, 2018
a9f1d61
Merge branch 'develop' into berta
P1tt187 Mar 14, 2018
e12162d
correct bug with shifttype and paginate
P1tt187 Mar 15, 2018
7209dab
fix check
P1tt187 Mar 15, 2018
46ad0e2
fix layout bugs
P1tt187 Mar 15, 2018
6c6ec62
fix button size
P1tt187 Mar 16, 2018
da66f78
fix layout
P1tt187 Mar 16, 2018
081fdc8
add padding
P1tt187 Mar 16, 2018
0c803c1
fix layout bug
P1tt187 Mar 16, 2018
d328f72
make price editable
P1tt187 Mar 28, 2018
2ec0cd0
Merge remote-tracking branch 'origin/berta'
P1tt187 Apr 2, 2018
eeb97c7
fix wrong section selected in create club event
P1tt187 Apr 5, 2018
756fd42
fix copy paste error
P1tt187 Apr 5, 2018
6ad4bd2
Lara v3.0.0 pre-release
P1tt187 Apr 13, 2018
24a4d70
correct duplicated import
P1tt187 Apr 13, 2018
3da1a1e
fix condition
P1tt187 Apr 14, 2018
c8e84c8
fix wrong return type
P1tt187 Apr 14, 2018
e989487
only set email, if it is set
P1tt187 Apr 14, 2018
f8e25d6
update email only if it changed
P1tt187 Apr 14, 2018
b3479cd
don't let a single error cause all errors
P1tt187 Apr 14, 2018
72a5a97
update email only if nobody has it already
P1tt187 Apr 14, 2018
901ccb7
add log info
P1tt187 Apr 14, 2018
c24cfa2
update the newest entrys first
P1tt187 Apr 14, 2018
9ff3cfb
update the newest entrys first
P1tt187 Apr 14, 2018
926a2ab
Add import for DB
stefanheyder Apr 15, 2018
cf471de
fix wrong filled names
P1tt187 Apr 16, 2018
a1fff08
edit formatting of log message
P1tt187 Apr 16, 2018
04772f2
fix wrong filled names
P1tt187 Apr 16, 2018
72d3c77
fix facebookneeded field not stored
P1tt187 Apr 20, 2018
40b21d2
fix facebookneeded field not stored
P1tt187 Apr 20, 2018
c939f6d
Fix create Club Event
stefanheyder Apr 24, 2018
d40871a
Fix status shorthand access
stefanheyder Apr 25, 2018
c2f85b0
Fix successfull authentication log
stefanheyder Apr 22, 2018
8656d61
Fix issue with empty person status
stefanheyder Apr 27, 2018
6c3531b
Fix own shift highlight in month view
stefanheyder Apr 27, 2018
b773f38
Rename name => nickname in UI
stefanheyder Apr 27, 2018
98fc67d
Fix BD status problems for veterans (EMs)
stefanheyder Apr 27, 2018
2261a19
Make users overview responsive
stefanheyder Apr 27, 2018
513a300
remove unused parameter in gate
P1tt187 Apr 28, 2018
55e0c37
Merge branch 'develop' into berta
P1tt187 Apr 28, 2018
d250156
Fix old "is" calls (now isAn)
stefanheyder Apr 29, 2018
f68eae6
Fix rights for deletion
stefanheyder Apr 29, 2018
0804d60
Merge branch 'develop' into berta
P1tt187 Apr 30, 2018
52d2226
add missing status
P1tt187 May 5, 2018
a27e5f7
add autofocus to login page
P1tt187 May 5, 2018
506d61d
fix errors in surveys
P1tt187 May 5, 2018
0f4f5fc
Merge branch 'develop' into berta
P1tt187 May 6, 2018
521df3e
Merge branch 'berta'
P1tt187 May 8, 2018
d9b8853
Merge branch 'develop' into berta
P1tt187 May 12, 2018
a047bab
Merge branch 'berta'
P1tt187 May 12, 2018
1883c0c
Merge branch 'develop' into berta
P1tt187 May 12, 2018
46aa36a
Merge branch 'berta'
P1tt187 May 12, 2018
b44d495
Merge branch 'develop' into berta
P1tt187 May 13, 2018
dc82370
Merge branch 'develop' into berta
P1tt187 May 13, 2018
f2eb67e
Merge branch 'berta'
P1tt187 May 15, 2018
0061816
Merge branch 'develop' into berta
P1tt187 May 15, 2018
953f6b5
Merge branch 'berta'
P1tt187 May 15, 2018
e5a56ae
Merge branch 'develop' into berta
P1tt187 May 17, 2018
dd1caa6
Merge branch 'berta'
P1tt187 May 17, 2018
fc4929b
fix copy paste bug
P1tt187 May 17, 2018
ee994c3
fix copy paste bug
P1tt187 May 17, 2018
79e7c8c
Merge branch 'develop' into berta
P1tt187 May 21, 2018
1f86750
Merge branch 'develop' into berta
P1tt187 May 22, 2018
5a1dce6
Merge branch 'develop' into berta
P1tt187 May 24, 2018
1830da4
Merge branch 'berta'
P1tt187 May 24, 2018
d5b5d0a
Fix guest privacy policy
stefanheyder May 28, 2018
fcdafc6
Fix guest privacy policy
stefanheyder May 28, 2018
571d8ba
Fix user status not transfered to person
stefanheyder May 29, 2018
bdd48d6
Fix user status not transfered to person
stefanheyder May 29, 2018
156e9d6
Fix person status in update method too
stefanheyder May 29, 2018
5ef8d41
Fix person status in update method too
stefanheyder May 29, 2018
489aa08
Fix/user created from person (#272)
stefanheyder May 29, 2018
366a7db
Fix logging in events (details + shifts)
stefanheyder May 28, 2018
3bba230
Add log message for synced bd-Events
stefanheyder May 28, 2018
bf217fa
log messages are caused by a select that gives duplicated results, ma…
P1tt187 May 24, 2018
3b09606
createFromPerson now adds to $person
stefanheyder May 27, 2018
6068e8a
Fix user created from event view
stefanheyder May 27, 2018
f669ccc
Fix statistics user access
stefanheyder May 27, 2018
4b7f2aa
Adapt migrations to new user() call
stefanheyder May 27, 2018
b8e6eba
Merge branch 'berta'
P1tt187 May 29, 2018
1761931
Merge branch 'develop' into berta
P1tt187 May 29, 2018
ffc06b7
Merge branch 'berta'
P1tt187 May 29, 2018
1f81eaa
add bi-Club translation
P1tt187 May 29, 2018
27cd0be
add bi-Club translation
P1tt187 May 29, 2018
a41615e
fix missing check
P1tt187 May 30, 2018
74d7133
fix missing check
P1tt187 May 30, 2018
ede3a48
fix npe
P1tt187 May 30, 2018
4ccc72b
fix npe
P1tt187 May 30, 2018
871e5d9
Merge branch 'develop' into berta
P1tt187 May 31, 2018
a9321d2
Merge branch 'berta'
P1tt187 May 31, 2018
9b789d8
fix npe
P1tt187 Jun 12, 2018
eb077a6
fix npe
P1tt187 Jun 12, 2018
9d82c8f
Merge branch 'develop' into berta
P1tt187 Jun 27, 2018
c5d79c5
remove debug output
P1tt187 Jun 30, 2018
8116679
Merge branch 'berta'
P1tt187 Jul 1, 2018
f2009a6
Merge branch 'develop' into berta
P1tt187 Jul 1, 2018
fb17b85
Merge branch 'berta'
P1tt187 Jul 1, 2018
235136a
Merge tag 'v3.1.10'
P1tt187 Jul 4, 2018
94dede3
fix private survey settings
P1tt187 Jul 4, 2018
6963ba8
Fix LDAP stacktrace
stefanheyder Jul 11, 2018
8a3724b
add custom name for month
Seriousness Aug 23, 2018
97cfa38
replace url with route
Seriousness Aug 23, 2018
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
6 changes: 3 additions & 3 deletions app/ClubEvent.php
Original file line number Diff line number Diff line change
Expand Up @@ -127,11 +127,11 @@ public function schedule()
*/
public function hasShift($person)
{
return $this->shifts ->contains(function(Shift $shift) use($person){
return $shift->person_id === $person->id;
return $this->shifts->contains(function(Shift $shift) use($person){
return $shift->person_id == $person->id;
});
}

/**
* @return \Illuminate\Database\Eloquent\Relations\HasManyThrough|Shift
*/
Expand Down
6 changes: 3 additions & 3 deletions app/Console/Commands/UpdateLara.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public function handle()

// log what you are doing
$this->info(''); // new line
$this->info('Executing "'.$step.'"...');
$this->info('Executing "' . $step . '"...');

// perform the instruction
passthru($step, $result);
Expand All @@ -115,8 +115,8 @@ public function handle()
// Inform the users
$this->info(''); // new line
$this->info(''); // new line
Log::info('Finished Lara update after '.($counterEnd - $counterStart).' seconds.');
$this->info('Finished Lara update after '.($counterEnd - $counterStart).' seconds.');
Log::info('Finished Lara update after ' . ($counterEnd - $counterStart) . ' seconds.');
$this->info('Finished Lara update after ' . ($counterEnd - $counterStart) . ' seconds.');

}
}
2 changes: 1 addition & 1 deletion app/Http/Controllers/ClubEventController.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
use Lara\ShiftType;
use Lara\Shift;
use Lara\Person;
use Lara\Section;
use Lara\Schedule;
use Lara\Section;
use Lara\Template;
use Lara\Utilities;
use Lara\utilities\RoleUtility;
Expand Down
7 changes: 4 additions & 3 deletions app/Http/Controllers/LoginController.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
use Lara\Section;
use Lara\User;
use Lara\utilities\RoleUtility;
use Lara\Utilities;
use Log;
use Session;

Expand Down Expand Up @@ -151,7 +152,8 @@ protected function attemptLoginViaLDAP()
try {
return $this->attemptLoginViaLDAPInternal();
} catch (\Exception $e) {
Log::error("ldap broken: " . $e->getMessage(), $e->getTrace());
Log::error(Input::get("username") . " tried to login via LDAP, but LDAP is not available.");
Utilities::error(trans("auth.ldap_down"));
return false;
}
}
Expand Down Expand Up @@ -452,8 +454,7 @@ protected function attemptLoginWithCredentials($request, $userIdentifier = 'emai
*/
protected function loginFailed()
{
Session::put('message', Config::get('messages_de.login-fail'));
Session::put('msgType', 'danger');
Utilities::error(Config::get('messages_de.login-fail'));

return redirect()->back();
}
Expand Down
7 changes: 6 additions & 1 deletion app/Http/Controllers/ShiftController.php
Original file line number Diff line number Diff line change
Expand Up @@ -517,7 +517,12 @@ private function onAdd($shift, $userName, $ldapId, $userClub)
*/
private function updateStatus($shift) {
if ( !is_null($shift->person_id) ) {
return Status::style($shift->person->prsn_status);

$person = $shift->person;
$club = $person->club;
$section = $club->section();

return Status::style($person->prsn_status, $section);
}
return ["status"=>"fa fa-question", "style"=>"color:lightgrey;", "title"=>"Dienst frei"];
}
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/TemplateController.php
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ private function createShifts($inputShifts, $amount)
$weight = $inputShifts["weight"][$i];

$position = $i;
$shift = ShiftController::createShiftsFromEditSchedule($id, $title, $type, $start, $end, $weight, $position);
$shift = ShiftController::createShiftsFromEditSchedule($id, $title, $type, $start, $end, $weight, $position,true);
if ($shift != null) {
array_push($results, $shift->id);
}
Expand Down
18 changes: 12 additions & 6 deletions app/Status.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,16 @@ class Status {
const CANDIDATE = 'candidate';
const MEMBER = 'member';
const VETERAN = 'veteran';
const RESIGNED = 'resigned';
const EXMEMBER = 'ex-member';
const EXCANDIDATE = 'ex-candidate';
const GUEST = 'guest';

const ALL = [
self::CANDIDATE,
self::MEMBER,
self::VETERAN,
self::RESIGNED,
self::EXMEMBER,
self::EXCANDIDATE,
];
Expand All @@ -40,19 +43,22 @@ public static function shortHand($status)
return self::SHORTHANDS[$status];
}

public static function style($status)
public static function style($status, $section = NULL)
{
if (!$section) {
$section = Section::query()->first();
}
switch ($status) {
case STATUS::CANDIDATE:
return ["status" => "fa fa-adjust", "style" => "color:yellowgreen;", "title" => "Kandidat"];
return ["status" => "fa fa-adjust", "style" => "color:yellowgreen;", "title" => self::localize($status, $section)];
case STATUS::VETERAN:
return ["status" => "fa fa-star", "style" => "color:gold;", "title" => "Veteran"];
return ["status" => "fa fa-star", "style" => "color:gold;", "title" => self::localize($status, $section)];
case STATUS::MEMBER:
return ["status" => "fa fa-circle", "style" => "color:forestgreen;", "title" => "Aktiv"];
return ["status" => "fa fa-circle", "style" => "color:forestgreen;", "title" => self::localize($status, $section)];
case STATUS::EXMEMBER:
return ["status" => "fa fa-star-o", "style" => "color:gold;", "title" => "ex-Mitglied"];
return ["status" => "fa fa-star-o", "style" => "color:gold;", "title" => self::localize($status, $section)];
case STATUS::EXCANDIDATE:
return ["status"=>"fa fa-circle", "style"=>"color:lightgrey;", "title"=>"ex-Kandidat"];
return ["status"=>"fa fa-circle", "style"=>"color:lightgrey;", "title" => self::localize($status, $section)];
default:
return ["status" => "fa fa-circle", "style" => "color:lightgrey;", "title" => "Extern"];
}
Expand Down
3 changes: 3 additions & 0 deletions app/User.php
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,9 @@ public static function createFromPerson(Person $person)
'person_id' => $person->id,
'status' => $newStatus
]);

$person->prsn_status = $newStatus;
$person->save();
RoleUtility::assignPrivileges(
$user, $person->club->section(),
RoleUtility::PRIVILEGE_MEMBER
Expand Down
12 changes: 8 additions & 4 deletions app/Utilities.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,14 +72,18 @@ static function getEventTypeTranslation($typeNumber){

static function error($message)
{
Session::put('message', $message);
Session::put('msgType', 'danger');
if (!Session::has('message')) {
Session::put('message', $message);
Session::put('msgType', 'danger');
}
}

static function success($message)
{
Session::put('message', $message);
Session::put('msgType', 'success');
if (!Session::has('message')) {
Session::put('message', $message);
Session::put('msgType', 'success');
}
}

}
3 changes: 2 additions & 1 deletion resources/lang/de/auth.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,6 @@
'status' => 'Status',
'password' => 'Passwort',
'confirmPassword' => 'Passwort bestätigen',
'register_submit' => 'Neuen Nutzer registrieren'
'register_submit' => 'Neuen Nutzer registrieren',
'ldap_down' => 'LDAP scheint nicht erreichbar zu sein, bitte melde dich mit deiner E-Mail Adresse an.',
];
3 changes: 2 additions & 1 deletion resources/lang/en/auth.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,6 @@
'status' => 'Status',
'password' => 'Password',
'confirmPassword' => 'Confirm password',
'register_submit' => 'Register new user'
'register_submit' => 'Register new user',
'ldap_down' => 'LDAP is down, please use your E-Mail for logging in.',
];
3 changes: 2 additions & 1 deletion resources/lang/pirate/auth.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,6 @@
'status' => 'Status',
'password' => 'Passwort',
'confirmPassword' => 'Passwort bestätigen',
'register_submit' => 'Neuen Nutzer registrieren'
'register_submit' => 'Neuen Nutzer registrieren',
'ldap_down' => 'LDAP scheint nicht erreichbar zu sein, bitte melde dich mit deiner E-Mail Adresse an.',
];
2 changes: 1 addition & 1 deletion resources/views/auth/register.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<div class="panel-body">
{{ Form::open(['class'=>"form-horizontal","method"=>"POST","route"=>'register']) }}
<div class="form-group{{ $errors->has('name') ? ' has-error' : '' }}">
<label for="name" class="col-md-4 control-label">Name</label>
<label for="name" class="col-md-4 control-label"> {{ trans('auth.nickname') }}</label>

<div class="col-md-6">
<input id="name" type="text" class="form-control" name="name" value="{{ old('name') }}" required autofocus>
Expand Down
13 changes: 10 additions & 3 deletions resources/views/monthView.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,23 @@
<div class="col-xs-12 col-md-12">
<div class="col-xs-12 col-md-5 btn-group no-padding">
<a class="btn btn-default hidden-print"
href="{{ Request::getBasePath() }}/calendar/{{ date("Y/m",
strtotime("previous month", $date['startStamp'])) }}">
href="{{route("calendar.month",
["year"=>date("Y",strtotime("previous month", $date['startStamp'])),
"month"=>date("m",strtotime("previous month", $date['startStamp']))]
)
}}">
&lt;&lt;
</a>

<span class="btn btn-lg disabled mobile72Width" style="text-align: center !important;">
{{ $date['monthName'] . " " . $date['year'] }}
</span>
<a class="btn btn-default hidden-print"
href="{{ Request::getBasePath() }}/calendar/{{ date("Y/m", strtotime("next month", $date['startStamp'])) }}">
href="{{route("calendar.month",
["year"=>date("Y",strtotime("next month", $date['startStamp'])),
"month"=>date("m",strtotime("next month", $date['startStamp']))]
)
}}">
&gt;&gt;
</a>
</div>
Expand Down
2 changes: 1 addition & 1 deletion resources/views/partials/navigation.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ class="dropdown-toggle"
@endis

{{-- LARA LOGS / section management or admins only --}}
@is(Roles::PRIVILEGE_CL, Roles::PRIVILEGE_ADMINISTRATOR)
@is(Roles::PRIVILEGE_ADMINISTRATOR)
<li><a href="{{ asset('/logs') }}">Logs</a></li>
<li role="separator" class="divider"></li>
@endis
Expand Down
8 changes: 5 additions & 3 deletions resources/views/partials/surveyForm.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,13 @@
<div>
<label class="label_checkboxitem" for="checkboxitemitem"></label>
<label><input type="checkbox" id="required1" value="1" name="is_private"
@if(Auth::user()->isAn(Roles::PRIVILEGE_MARKETING)) checked
disabled @endif class="input_checkboxitem"
@if(!Auth::user()->isAn(Roles::PRIVILEGE_MARKETING))
disabled checked @endif class="input_checkboxitem"
@if($survey->is_private) checked @endif> {{ trans('mainLang.showOnlyForLoggedInMember') }}
</label>
<input hidden type="checkbox" id="required1_hidden" name="is_private" value="1">
@if(!Auth::user()->isAn(Roles::PRIVILEGE_MARKETING))
<input hidden checked type="checkbox" id="required1_hidden" name="is_private" value="1">
@endif
</div>
<div>
<label class="label_checkboxitem" for="checkboxitemitem"></label>
Expand Down
2 changes: 1 addition & 1 deletion resources/views/user/edituser.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@

@canEditUser($user)
<div class="form-group {{ $errors->has('name') ? ' has-error' : '' }} input-group" >
<label class="control-label" for="userName"> Name </label>
<label class="control-label" for="userName"> {{ trans('auth.nickname') }} </label>
{{ Form::text('name',$user->name,['class'=>"form-control" ,'id'=>'userName','required'=>"",'autofocus'=>'']) }}
@if ($errors->has('name'))
<span class="help-block">
Expand Down
Loading