add_subgroups_to_user_group and remove_subgroups_from_user_group
are already inside outer db transactions. This commit explicitly
adds 'savepoint=False' to avoid creating savepoints.
This commit adds 'savepoint=False' to the transaction.atomic
decorators of do_change_plan_type as we don't intend to create
savepoints when the function is called inside an outer transaction.
This commit adds 'durable=True' to the outermost transaction
in 'remote_server_post_analytics'.
It also adds 'savepoint=False' to inner transaction.atomic
decorator to avoid creating savepoint.
This is as a part of our plan to explicitly mark all the
transaction.atomic decorators with either 'savepoint=False' or
'durable=True' as required.
* 'savepoint=True' is used in special cases.
This commit adds 'durable=True' to the outermost transaction
in 'delete_message_backend'.
It also adds 'savepoint=False' to inner transaction.atomic
decorator to avoid creating savepoint.
This is as a part of our plan to explicitly mark all the
transaction.atomic decorators with either 'savepoint=False' or
'durable=True' as required.
* 'savepoint=True' is used in special cases.
This commit adds 'durable=True' to the outermost transactions
of the following functions:
* do_create_multiuse_invite_link
* do_revoke_user_invite
* do_revoke_multi_use_invite
* sync_ldap_user_data
* do_reactivate_remote_server
* do_deactivate_remote_server
* bulk_handle_digest_email
* handle_customer_migration_from_server_to_realm
* add_reaction
* remove_reaction
* deactivate_user_group
It helps to avoid creating unintended savepoints in the future.
This is as a part of our plan to explicitly mark all the
transaction.atomic decorators with either 'savepoint=False' or
'durable=True' as required.
* 'savepoint=True' is used in special cases.
This commit adds 'durable=True' to the outermost transaction
in 'do_invite_users'.
It also adds 'savepoint=False' to inner transaction.atomic
decorators to avoid creating savepoints.
Move the redundant code for hiding spinners and re-enabling buttons into
a common `hide_spinner` function inside `loading.ts`. This reduces
duplication between `hide_button_spinner` and `hide_dialog_spinner`.
Fixes#26691.
Consolidate the repeated logic for showing spinners into a shared
`show_spinner` function in `loading.ts`. This eliminates code
duplication between `show_button_spinner` and `show_dialog_spinner`,
streamlining spinner initialization and button disabling.
Fixes part of #26691.
Note about the documentation: There are currently two "Save changes"
buttons on the Airbyte "Notifications" settings page, so the
instructions specify which one to use for clarity.
Expands the "No organization found" page to include a link to the
"Find your accounts" page.
Also adjusts the layout of the page for the longer text by adding
the "find-account-page-container" class for the textbox width.
Fixes#30116.
Updates "Find your accounts" page to display a relevant message for
self-hosted servers, with no changes to the Zulip Cloud version of
the page.
Fixes part of #30116.
Moves and renames `set_expires_on_text` to settings_components.ts,
so that it can be used in other modals with user set time inputs
that show a formatted string of that time input.
Updates invite_user_modal.hbs for the class names used in the new
shared helper function.
Co-authored-by: Ujjawal Modi <umodi2003@gmail.com>
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
Refactors the `valid_to` function to return the correct formatted
string for all cases (custom and preset) of invitation expiration
input values.
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
Moves `set_custom_time_inputs_visibility` function to
settings_components.ts so that it can be reused in
other modals with user set custom time inputs.
Updates user_invite_modal.hbs to use the class name
in the new shared helper function.
Co-authored-by: Ujjawal Modi <umodi2003@gmail.com>
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
Adds general class names in invite_user_modal.hbs for custom time
the input and unit so that these elements more easily be extended
for use in other modals with a user specified custom time.
Updates the listener in invite.ts that was using the removed
"custom-expiration-time" class to instead use the id for the
input and unit div, "custom-invite-expiration-time".
Corresponding updates have been made to the relevant CSS files to
ensure consistent styling and future scalability.
Co-authored-by: Ujjawal Modi <umodi2003@gmail.com>
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
For all users, we want to display "Ctrl" for the "Ctrl" "[" keyboard
shortcuts that match the "Esc" Vim keybinding behavior.
We use the "data-mac-key" attribute to override the default mapping
of "Ctrl" to "Cmd" for Mac users in the documentation of these
keyboard shortcuts.
Fixes#20107.
Currently, the GitHub webhook sends activity from both public and private
repositories, which could lead to unintended disclosure of sensitive
information from private repositories.
This commit introduces a ignore_private_repositories parameter to the
webhook URL. When set to true, the webhook ignore processing activity from
private repositories, ensuring that such activities are not posted to
Zulip streams. By default, if the parameter is omitted or set to false,
activities from both public and private repositories are processed
normally. This provides users with the flexibility to control the
visibility of private repository activities without altering the default
behavior.
More importantly, this introduces a cleaner mechanism for individual
incoming webhooks to declare support for settings not common to all
webhook integrations.
Fixes#31638.
During account creation when a user opted to import settings
from an existing account, the "Mark visibility_policy_banner as
read" step was raising integrity error.
It is because 'copy_onboarding_steps' is already executed earlier
in the 'do_create_user' codeflow. If the source profile had already
marked 'visibility_policy_banner' as read, we were facing integrity
error.
This commit fixes the bug.
This makes sure that the "Add" button in members panel is
not enabled if the pill input is empty, in two cases - when
the members panel is opened and also when the members panel
is live-updated due to change in permission.
We now have a grey-ish background color for the pill container
with opacity also reduced like we do for the disabled select
elements in settings.
Needed to adjust the selectors so that the CSS for disabled
state correctly overrides the CSS for enabled state.
We show "0 members" text when a group has no direct members but
has subgroups which are all empty.
The behavior for when a group has neither direct members nor
subgroups is same where we show "This group has no members".
Previously, errors were returned using Zulip's default format,
which did not match Slack's expected response structure.
This change ensures that errors in the Slack incoming webhook handler
return JSON responses in Slack's expected format: {ok: false, error:
"error string"}.
Fixes: #31878.
Unfortunately, because this migration has already been run for many
installations, we need to ship another copy of the migration.
It should be a noop when repeated.
This commit updates code to just use permission settings
list from server_supported_permission_settings data
instead of calling create_realm_group_setting_widget
individually for each setting.
Also, updated the code to create dropdown widgets to check
if only system groups are allowed or not for a setting
instead of using a hardcoded list.