Commit Graph

27 Commits

Author SHA1 Message Date
Vinoth Kannan fb89a23530
FEATURE: skip group invite if all members can see topic already. (#474)
We don't want to invite a group when all of its members are part of another group that is already allowed to the topic.
2023-05-27 22:29:38 +05:30
Vinoth Kannan f97da59dee
FIX: don't invite user when already a member of an allowed group. (#473)
Otherwise, when an allowed group member is assigned to the PM it invites the user (which is unnecessary) and creates a public small post for the invite.
2023-05-24 11:45:50 +05:30
Vinoth Kannan dcaadb75dc
FEATURE: invite user/group to PM if not a participant already. (#471)
When a group or user is assigned to a personal message, if they are not already a participant, invite them to the PM before assignment.
2023-05-22 14:48:08 +05:30
Krzysztof Kotlarek c036d030dc
FIX: reassign when assignment limit is fulfilled (#419)
Previously, when topic was already assigned 5 times, reassign was not possible. User had to first unassign topic and then assign to someone else.
2023-01-20 13:34:22 +11:00
Jan Cernik 896d0e3445
FIX: Broken posts when assigning a closed topic (#425)
The previous behavior was:
1. Assign a topic to someone
2. Close the topic with the setting unassign_on_close enabled
3. Assign the topic to the same user as before

This caused small broken or empty posts to be displayed.

This commit also introduces system specs
2023-01-17 08:09:35 -03:00
Penar Musaraj 4b8afc301a
FEATURE: Cleanup notifications when reassigning (#394)
If a topic is initially assigned to user A then reassigned to user B,
this change will make it so that notifications sent to user A are
removed. This matches the plugin's behaviour when unassigning a topic.
2022-11-24 10:42:19 -05:00
Bianca Nenciu 1dfbc84896
FIX: Count only active assignments when checking limits (#375)
Only 5 assignments can exist simultaneously for a topic or its post.
The code that counted the assignments did not ignore the inactive
assignments which made the limit check more strict than it should have
been.
2022-08-30 19:56:03 +03:00
Bianca Nenciu acb9025ede
FIX: Check if assignment has same user and details (#368)
The check existed, but its implementation was incorrect and it did not
work when the target was a post.
2022-08-18 18:16:20 +03:00
Osama Sayegh d9a750d306
DEV: Add assignment ID to assign notification data (#365)
This change makes it possible to associate an assign notification with the `assignments` record that creates the notification. It'll be needed for the assignments tab in the new experimental user menu, see https://github.com/discourse/discourse/pull/17379.
2022-08-11 06:43:49 +03:00
Rafael dos Santos Silva 7a2fde72c6
FEATURE: Assign Status (#363)
Adds a new plugin setting that when enabled adds a status field for every assignment. This setting defaults to off.

The possible status for an assignment are customizable via yet another new setting, and the first one on this list will be the default status for new assignments.

The status is not yet show anywhere except the assign modal and the small action posts in topics at the moment. Adding status to the assignment list for users and groups will be handled in the near future.


Co-authored-by: Penar Musaraj <pmusaraj@gmail.com>
2022-08-04 14:50:18 -03:00
Rafael dos Santos Silva 6116f26642 DEV: Apply syntax_tree formatting 2022-07-27 13:48:51 -03:00
Krzysztof Kotlarek 0b5f688451
FIX: ensure that assignee is participant of pm (#349)
We are already checking that assignee has access to the private message. However, admin still can be assigned as technically they have access.

We should ensure that assignee has direct access to the message.
2022-06-16 10:08:22 +10:00
Natalie Tay 43a3030707
FEATURE: Shows note in moderator post (#335) 2022-05-12 23:55:57 +08:00
Natalie Tay fbdfb7143b
DEV: Small refactors for future work (#332) 2022-05-11 14:03:54 +08:00
Natalie Tay b314882a6b
FEATURE: Show note in tooltip (#327) 2022-05-05 15:04:57 +08:00
Natalie Tay 1ac2dfbae2
FEATURE: Add assign note (#326) 2022-05-05 13:21:14 +08:00
jbrw 44dd73e151
FIX: Exclude inactive assigns from assigned_total count (#288)
If `SiteSetting.unassign_on_close` is enabled, an Assignment record can still exist, but be set to inactive, when a Topic is closed.

Inactivement Assignments should be ignored when comparing to the maximum number of assigned topics.
2022-01-31 15:26:58 -05:00
communiteq 43f93d9611
Fix: set these fields in condition below only (#273)
Co-authored-by: Richard <richard@communiteq.com>
2021-12-24 11:24:57 +11:00
Krzysztof Kotlarek 1a1dffc5e8
FEATURE: active flag for assignments (#264)
When topic is closed, we mark assignments as "inactive". Then when it is reopen and setting reassign_on_open is enabled, we bring back previous assignments.

We were already using custom fields for archive message and move to inbox. I changed custom fields solution to use active flag on Assignment model
2021-12-13 08:36:14 +01:00
Krzysztof Kotlarek 3eaefb60dd
FIX: dont allow assigning user to topic when post assigned (#259)
When post is already assigned to user/group then don't allow assigning a topic to that user/group.

Similarly, right now when topic is already assigned we are not allowing to assign a post that that user.
2021-12-06 06:09:04 +01:00
janzenisaac 5910fd5569
FIX: Refactor assign / reassign to combine logic (#250)
* Refactor and combine assign / reassign logic
2021-12-02 13:12:00 -06:00
janzenisaac 98103586b2
FEATURE: Reassign workflow (#231)
Build a new workflow that adds a dropdown in place of the old assign button with the ability to

Re-assign a new user / group to an assigned topic
Re-assign yourself to an assigned topic
Unassign a user / group from an assigned topic
2021-11-12 10:09:47 -06:00
Krzysztof Kotlarek 69dac06a82
FIX: correctly update UI when post is assigned/unassigned (#233)
Update topic title, first post and related post
2021-11-09 08:40:43 +11:00
Krzysztof Kotlarek 2d1f5668a5
FIX: rename action_code_href to action_code_path (#234)
We should use relative paths, therefore name change is necessary to avoid confusions. Post migration is added to fix existing data.
2021-11-08 14:32:21 +11:00
Krzysztof Kotlarek 22025b35b8
FEATURE: small post action with link to post (#232)
When a post is assigned/unassigned, we want small action to have a link to the specific post.
2021-11-08 08:25:13 +11:00
Krzysztof Kotlarek c396605d2f
FEATURE: assign to post (#224)
Ability to assign an individual post to a user or group
2021-11-01 09:27:13 +11:00
Krzysztof Kotlarek dc8f43fbb1
FEATURE: Assignment target is polymorphic (#218)
Change `topic_id` to polymorphic approach (In the next step we will allow assigning to individual post)

`topic_id` column is still used for efficient display of assigned users on topic list (to avoid scanning posts)
2021-10-14 09:22:29 +11:00