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

feat(dav): implement personal absence settings #40767

Merged
merged 1 commit into from Nov 8, 2023

Conversation

st3iny
Copy link
Member

@st3iny st3iny commented Oct 4, 2023

Summary

The new absence form is hidden/disabled by default. It has to be manually enabled via the app config hide_absence_settings.

The help texts and descriptions might some need more work once the feature is fleshed out.

grafik

TODO

Checklist

apps/dav/lib/Db/Absence.php Fixed Show fixed Hide fixed
$this->initialState->provideInitialState('hide_absence', $hideAbsence);
if (!$hideAbsence) {
try {
$absence = $this->absenceMapper->findByUserId($this->userId);

Check notice

Code scanning / Psalm

PossiblyNullArgument Note

Argument 1 of OCA\DAV\Db\AbsenceMapper::findByUserId cannot be null, possibly null value provided
@skjnldsv skjnldsv mentioned this pull request Nov 1, 2023
@st3iny st3iny marked this pull request as ready for review November 1, 2023 20:57
@st3iny st3iny added 3. to review Waiting for reviews and removed 2. developing Work in progress labels Nov 1, 2023
Signed-off-by: Richard Steinmetz <richard@steinmetz.cloud>
@st3iny
Copy link
Member Author

st3iny commented Nov 7, 2023

Rebase round 2 to finally get green CI 🙃

Copy link
Contributor

@hamza221 hamza221 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested ✅

@ChristophWurst ChristophWurst merged commit 1d568a8 into master Nov 8, 2023
49 of 50 checks passed
@ChristophWurst ChristophWurst deleted the feat/dav/absence branch November 8, 2023 04:51
@nickvergessen
Copy link
Member

Could this be moved into an OCS endpoint so talk mobile clients could set the OOO as well?

@ChristophWurst
Copy link
Member

Good idea! #41458

lastDay: formatDateAsYMD(this.lastDay),
status: this.status,
message: this.message,
})
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should show success after this?

async clearAbsence() {
this.loading = true
try {
await axios.delete(generateUrl('/apps/dav/settings/absence'))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should show success after this?

@tflidd
Copy link
Contributor

tflidd commented Dec 11, 2023

For translation, I'm not 100% sure of the strings Long absence Message and Short absence status,

  • in case of an absence, there is a short status message and a long message (e.g. if you hover over it)
  • or is there a short-term absence with a status message, and a long-term absence (e.g. after >5 min) where it shows a different message)?

I tend to the first option, but in this case it would make sense to define the different kind of absence status like in other software (e.g. busy, away, available, ....)

@nickvergessen
Copy link
Member

The first one. the "Short" is set as "User status", the long one is shown in Mail and Talk close to the inputs iirc

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Out-of-office: Implement settings UI with persistence in database
5 participants