calendar
calendar copied to clipboard
Fix category selection
This PR sketches a possible solution to fixes #3939 and fixes #3802. However, there might be better/easier ways to fix this.
The underlying issue was a binding problem in the Multiselect controls: The bound data source (the event's categories) is changed in the selectValue
handler. As far as I understand, this causes rerendering inside the handler. That is why the selection does not complete and categories can be selected multiple times.
This is solved by having the Multiselect controls work on their own data (value
). The event's categories are synchronized on startup and upon selection/deselection.
However, this proposal needs more attention. The following problems need to be addressed:
- After opening an event, the category list is not collapsed, but squeezed in.
- See warnings in browsler log.
- See compile output.
Codecov Report
Merging #3944 (c17d609) into main (64a50a9) will decrease coverage by
0.06%
. The diff coverage is0.00%
.
:exclamation: Current head c17d609 differs from pull request most recent head 1370ae4. Consider uploading reports for the commit 1370ae4 to get more accurate results
@@ Coverage Diff @@
## main #3944 +/- ##
============================================
- Coverage 29.36% 29.29% -0.07%
+ Complexity 330 322 -8
============================================
Files 221 221
Lines 7721 7613 -108
Branches 1026 1010 -16
============================================
- Hits 2267 2230 -37
+ Misses 5454 5383 -71
Flag | Coverage Δ | |
---|---|---|
javascript | 20.69% <0.00%> (+0.21%) |
:arrow_up: |
php | 67.35% <ø> (-1.45%) |
:arrow_down: |
Flags with carried forward coverage won't be shown. Click here to find out more.
Impacted Files | Coverage Δ | |
---|---|---|
...nents/Editor/Properties/PropertySelectMultiple.vue | 0.00% <0.00%> (ø) |
|
...or/Properties/PropertySelectMultipleColoredTag.vue | 0.00% <0.00%> (ø) |
|
...apps/calendar/lib/Controller/BookingController.php | 34.48% <0.00%> (-21.08%) |
:arrow_down: |
...c/fullcalendar/eventSources/eventSourceFunction.js | 92.72% <0.00%> (-0.13%) |
:arrow_down: |
src/utils/router.js | 67.74% <0.00%> (ø) |
|
src/views/Calendar.vue | 0.00% <0.00%> (ø) |
|
src/views/Dashboard.vue | 0.00% <0.00%> (ø) |
|
src/views/EditSimple.vue | 0.00% <0.00%> (ø) |
|
src/mixins/EditorMixin.js | 0.00% <0.00%> (ø) |
|
src/views/EditSidebar.vue | 0.00% <0.00%> (ø) |
|
... and 89 more |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update 64a50a9...1370ae4. Read the comment docs.
After opening an event, the category list is not collapsed, but squeezed in.
Does somebody know how to fix this?
It's more of a glitch. After resizing the browser window, categories are properly collapsed.
The bug didn't come up with my changes, but existed before. This might be a good place to fix it, though.
I think it is worth reviewing this PR even without a fix for the cosmetic issue from my previous comment. It already fixes the functional limitations.
please update / rebase main branch please merge all commits all together
Done!
Please run npm run lint:fix
returned
/var/www/html/apps/calendar/node_modules/eslint-plugin-jsdoc/dist/iterateJsdoc.js:278
})() ?? jsdoc.source.findIndex(({
^
SyntaxError: Unexpected token '?'
However, I think I fixed the relevant linter complain manually (in-line v-if
).
/backport to stable3.4
Ready to merge from my perspective.
Ready to merge from my perspective.
Awesome. I'll have another look at the PR soon.
Hi, I can't understand this is not still merged.... We can't use category in calendar, this is a main feature of the tools. (https://github.com/nextcloud/calendar/issues/3802) This is really a mess for some Teams which think about leaving Nextcloud because of this kind of regression. I'm pretty sad :(
I'm well aware @Kayoku. Currently there are a bunch of high prio bugs we need to address. This is one of them: https://github.com/orgs/nextcloud/projects/61/views/9. We will have a look soon.
/backport to stable3.5
Thx you for this !
/backport to stable3.3