Skip to content

Commit

Permalink
Merge pull request #101 from 5pm-HDH/94-bug-retrieve-group-weekday
Browse files Browse the repository at this point in the history
94 bug retrieve group weekday
  • Loading branch information
DumbergerL authored Aug 29, 2022
2 parents 4ee5333 + e34bf30 commit 9b5452e
Show file tree
Hide file tree
Showing 30 changed files with 982 additions and 332 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- [Create UpdatableMode-Interface for type safety](https://github.com/5pm-HDH/churchtools-api/pull/93)
- [Status-Code handling and Exception-handling](https://github.com/5pm-HDH/churchtools-api/pull/99)
- [Refactor delete person](https://github.com/5pm-HDH/churchtools-api/pull/100)
- [Refactor FillWithData](https://github.com/5pm-HDH/churchtools-api/pull/101)

### Fixed

Expand Down
2 changes: 1 addition & 1 deletion docs/out/EventAPI.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
// Output: "2021-09-02 22:00:00"

var_dump( $christmasService->getChatStatus());
// Output: null
// Output: false

var_dump( $christmasService->getPermissions());
// Output: null
Expand Down
12 changes: 6 additions & 6 deletions src/Models/Appointment.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class Appointment
protected ?Calendar $calendar = null;
protected ?string $information = null;
protected ?string $link = null;
protected ?string $isInternal = null;
protected ?bool $isInternal = null;
protected ?string $startDate = null;
protected ?string $endDate = null;
protected ?string $allDay = null;
Expand All @@ -43,7 +43,7 @@ protected function fillArrayType(string $key, array $data): void
$this->meta = Meta::createModelFromData($data);
break;
default:
$this->{$key} = $data;
$this->fillDefault($key, $data);
}
}

Expand Down Expand Up @@ -174,18 +174,18 @@ public function setLink(?string $link): Appointment
}

/**
* @return string|null
* @return bool|null
*/
public function getIsInternal(): ?string
public function getIsInternal(): ?bool
{
return $this->isInternal;
}

/**
* @param string|null $isInternal
* @param bool|null $isInternal
* @return Appointment
*/
public function setIsInternal(?string $isInternal): Appointment
public function setIsInternal(?bool $isInternal): Appointment
{
$this->isInternal = $isInternal;
return $this;
Expand Down
22 changes: 11 additions & 11 deletions src/Models/Calendar.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ class Calendar
protected ?string $nameTranslated = null;
protected ?string $sortKey = null;
protected ?string $color = null;
protected ?string $isPublic = null;
protected ?string $isPrivate = null;
protected ?bool $isPublic = null;
protected ?bool $isPrivate = null;
protected ?string $randomUrl = null;
protected ?string $iCalSourceUrl = null;
protected ?string $campusId = null;
Expand All @@ -30,7 +30,7 @@ protected function fillArrayType(string $key, array $data): void
if ($key == "meta") {
$this->meta = Meta::createModelFromData($data);
} else {
$this->{$key} = $data;
$this->fillDefault($key, $data);
}
}

Expand Down Expand Up @@ -134,36 +134,36 @@ public function setColor(?string $color): Calendar
}

/**
* @return string|null
* @return bool|null
*/
public function getIsPublic(): ?string
public function getIsPublic(): ?bool
{
return $this->isPublic;
}

/**
* @param string|null $isPublic
* @param bool|null $isPublic
* @return Calendar
*/
public function setIsPublic(?string $isPublic): Calendar
public function setIsPublic(?bool $isPublic): Calendar
{
$this->isPublic = $isPublic;
return $this;
}

/**
* @return string|null
* @return bool|null
*/
public function getIsPrivate(): ?string
public function getIsPrivate(): ?bool
{
return $this->isPrivate;
}

/**
* @param string|null $isPrivate
* @param bool|null $isPrivate
* @return Calendar
*/
public function setIsPrivate(?string $isPrivate): Calendar
public function setIsPrivate(?bool $isPrivate): Calendar
{
$this->isPrivate = $isPrivate;
return $this;
Expand Down
12 changes: 6 additions & 6 deletions src/Models/Event.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class Event
protected ?string $description = null;
protected ?string $startDate = null;
protected ?string $endDate = null;
protected ?string $chatStatus = null;
protected ?bool $chatStatus = null;
protected ?array $permissions = null;
protected ?DomainAttributeModel $calendar = null;
protected ?EventAgenda $agenda = null;
Expand All @@ -36,7 +36,7 @@ protected function fillArrayType(string $key, array $data): void
$this->setCalendar(DomainAttributeModel::createModelFromData($data));
break;
default:
$this->{$key} = $data;
$this->fillDefault($key, $data);
}
}

Expand Down Expand Up @@ -166,18 +166,18 @@ public function setEndDate(?string $endDate): Event
}

/**
* @return string|null
* @return bool|null
*/
public function getChatStatus(): ?string
public function getChatStatus(): ?bool
{
return $this->chatStatus;
}

/**
* @param string|null $chatStatus
* @param bool|null $chatStatus
* @return Event
*/
public function setChatStatus(?string $chatStatus): Event
public function setChatStatus(?bool $chatStatus): Event
{
$this->chatStatus = $chatStatus;
return $this;
Expand Down
12 changes: 6 additions & 6 deletions src/Models/EventAgenda.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class EventAgenda
protected ?string $id = null;
protected ?string $name = null;
protected ?string $series = null;
protected ?string $isFinal = null;
protected ?bool $isFinal = null;
protected ?string $eventStartPosition = null;
protected ?string $calendarId = null;
protected ?string $total = null;
Expand All @@ -35,7 +35,7 @@ protected function fillArrayType(string $key, array $data): void
$this->setMeta(Meta::createModelFromData($data));
break;
default:
$this->{$key} = $data;
$this->fillDefault($key, $data);
}
}

Expand Down Expand Up @@ -135,18 +135,18 @@ public function setSeries(?string $series): EventAgenda
}

/**
* @return string|null
* @return bool|null
*/
public function getIsFinal(): ?string
public function getIsFinal(): ?bool
{
return $this->isFinal;
}

/**
* @param string|null $isFinal
* @param bool|null $isFinal
* @return EventAgenda
*/
public function setIsFinal(?string $isFinal): EventAgenda
public function setIsFinal(?bool $isFinal): EventAgenda
{
$this->isFinal = $isFinal;
return $this;
Expand Down
12 changes: 6 additions & 6 deletions src/Models/EventAgendaItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class EventAgendaItem
protected ?string $note = null;
protected ?string $duration = null;
protected ?string $start = null;
protected ?string $isBeforeEvent = null;
protected ?bool $isBeforeEvent = null;
protected ?array $responsible = null;
protected ?array $serviceGroupNotes = null;
protected ?Song $song = null;
Expand All @@ -34,7 +34,7 @@ protected function fillArrayType(string $key, array $data): void
$this->setMeta(Meta::createModelFromData($data));
break;
default:
$this->{$key} = $data;
$this->fillDefault($key, $data);
}
}

Expand Down Expand Up @@ -165,18 +165,18 @@ public function setStart(?string $start): EventAgendaItem
}

/**
* @return string|null
* @return bool|null
*/
public function getIsBeforeEvent(): ?string
public function getIsBeforeEvent(): ?bool
{
return $this->isBeforeEvent;
}

/**
* @param string|null $isBeforeEvent
* @param bool|null $isBeforeEvent
* @return EventAgendaItem
*/
public function setIsBeforeEvent(?string $isBeforeEvent): EventAgendaItem
public function setIsBeforeEvent(?bool $isBeforeEvent): EventAgendaItem
{
$this->isBeforeEvent = $isBeforeEvent;
return $this;
Expand Down
45 changes: 22 additions & 23 deletions src/Models/EventService.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@ class EventService
protected ?Person $person = null;
protected ?string $name = null;
protected ?string $serviceId = null;
protected ?string $agreed = null;
protected ?string $isValid = null;
protected ?bool $agreed = null;
protected ?bool $isValid = null;
protected ?string $requestedDate = null;
protected ?string $requesterPersonId = null;
protected ?Person $requesterPerson = null;
protected ?string $comment = null;
protected ?string $counter = null;
protected ?string $allowChat = null;
protected ?bool $allowChat = null;

protected function fillArrayType(string $key, array $data): void
{
Expand All @@ -39,7 +39,7 @@ protected function fillArrayType(string $key, array $data): void
$this->setRequesterPerson(Person::createModelFromData($personData));
break;
default:
$this->{$key} = $data;
$this->fillDefault($key, $data);
}
}

Expand Down Expand Up @@ -130,18 +130,18 @@ public function setPersonId(?string $personId): EventService
}

/**
* @return ?Person
* @return Person|null
*/
public function getPerson(): ?Person
{
return $this->person;
}

/**
* @param Person $person
* @param Person|null $person
* @return EventService
*/
public function setPerson(Person $person): EventService
public function setPerson(?Person $person): EventService
{
$this->person = $person;
return $this;
Expand Down Expand Up @@ -184,36 +184,36 @@ public function setServiceId(?string $serviceId): EventService
}

/**
* @return string|null
* @return bool|null
*/
public function getAgreed(): ?string
public function getAgreed(): ?bool
{
return $this->agreed;
}

/**
* @param string|null $agreed
* @param bool|null $agreed
* @return EventService
*/
public function setAgreed(?string $agreed): EventService
public function setAgreed(?bool $agreed): EventService
{
$this->agreed = $agreed;
return $this;
}

/**
* @return string|null
* @return bool|null
*/
public function getIsValid(): ?string
public function getIsValid(): ?bool
{
return $this->isValid;
}

/**
* @param string|null $isValid
* @param bool|null $isValid
* @return EventService
*/
public function setIsValid(?string $isValid): EventService
public function setIsValid(?bool $isValid): EventService
{
$this->isValid = $isValid;
return $this;
Expand Down Expand Up @@ -256,18 +256,18 @@ public function setRequesterPersonId(?string $requesterPersonId): EventService
}

/**
* @return ?Person
* @return Person|null
*/
public function getRequesterPerson(): ?Person
{
return $this->requesterPerson;
}

/**
* @param Person $requesterPerson
* @param Person|null $requesterPerson
* @return EventService
*/
public function setRequesterPerson(Person $requesterPerson): EventService
public function setRequesterPerson(?Person $requesterPerson): EventService
{
$this->requesterPerson = $requesterPerson;
return $this;
Expand Down Expand Up @@ -310,21 +310,20 @@ public function setCounter(?string $counter): EventService
}

/**
* @return string|null
* @return bool|null
*/
public function getAllowChat(): ?string
public function getAllowChat(): ?bool
{
return $this->allowChat;
}

/**
* @param string|null $allowChat
* @param bool|null $allowChat
* @return EventService
*/
public function setAllowChat(?string $allowChat): EventService
public function setAllowChat(?bool $allowChat): EventService
{
$this->allowChat = $allowChat;
return $this;
}

}
Loading

0 comments on commit 9b5452e

Please sign in to comment.