Latest zammad compatibility
This commit is contained in:
parent
99b92fe4ce
commit
40c14ece94
13 changed files with 157 additions and 121 deletions
|
|
@ -98,7 +98,7 @@ class ProfileNotification extends App.ControllerSubContent
|
|||
groups = _.sortBy(groups, (item) -> return item.name)
|
||||
|
||||
for sound in @sounds
|
||||
sound.selected = sound.file is App.OnlineNotification.soundFile() ? true : false
|
||||
sound.selected = sound.file is App.OnlineNotification.soundFile()
|
||||
|
||||
signal_notification_enabled = App.Config.get('signal_notification_enabled')
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
<!-- Copyright (C) 2012-2025 Zammad Foundation, https://zammad-foundation.org/ -->
|
||||
<!-- Copyright (C) 2012-2026 Zammad Foundation, https://zammad-foundation.org/ -->
|
||||
<!-- CDR Link Extension: Adds Signal notification channel support -->
|
||||
|
||||
<script setup lang="ts">
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
// Copyright (C) 2012-2025 Zammad Foundation, https://zammad-foundation.org/
|
||||
// Copyright (C) 2012-2026 Zammad Foundation, https://zammad-foundation.org/
|
||||
// CDR Link Extension: Adds Signal notification channel support
|
||||
|
||||
export enum NotificationMatrixRowKey {
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
<!-- Copyright (C) 2012-2025 Zammad Foundation, https://zammad-foundation.org/ -->
|
||||
<!-- Copyright (C) 2012-2026 Zammad Foundation, https://zammad-foundation.org/ -->
|
||||
<!-- CDR Link Extension: Adds Signal notification phone number field -->
|
||||
|
||||
<script setup lang="ts">
|
||||
import { isEqual } from 'lodash-es'
|
||||
import { storeToRefs } from 'pinia'
|
||||
import { computed, ref, watch } from 'vue'
|
||||
import { computed, ref, watch, toRef } from 'vue'
|
||||
|
||||
import {
|
||||
NotificationTypes,
|
||||
|
|
@ -40,7 +40,7 @@ interface ExtendedNotificationFormData extends NotificationFormData {
|
|||
|
||||
const { breadcrumbItems } = useBreadcrumb(__('Notifications'))
|
||||
|
||||
const { user } = storeToRefs(useSessionStore())
|
||||
const user = toRef(useSessionStore(), 'user')
|
||||
|
||||
// CDR Link: Get application config for signal notification setting
|
||||
const { config } = storeToRefs(useApplicationStore())
|
||||
|
|
@ -322,7 +322,7 @@ const onResetToDefaultSettings = async () => {
|
|||
:disabled="loading"
|
||||
@click="onResetToDefaultSettings"
|
||||
>
|
||||
{{ $t('Reset to Default Settings') }}
|
||||
{{ $t('Reset to default settings') }}
|
||||
</CommonButton>
|
||||
<CommonButton
|
||||
size="medium"
|
||||
|
|
@ -330,7 +330,7 @@ const onResetToDefaultSettings = async () => {
|
|||
variant="submit"
|
||||
:disabled="loading"
|
||||
>
|
||||
{{ $t('Save Notifications') }}
|
||||
{{ $t('Save notifications') }}
|
||||
</CommonButton>
|
||||
</div>
|
||||
</template>
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
<!-- Copyright (C) 2012-2025 Zammad Foundation, https://zammad-foundation.org/ -->
|
||||
<!-- Copyright (C) 2012-2026 Zammad Foundation, https://zammad-foundation.org/ -->
|
||||
|
||||
<script setup lang="ts">
|
||||
import { useActiveElement, useLocalStorage, useWindowSize } from '@vueuse/core'
|
||||
|
|
|
|||
|
|
@ -40,10 +40,6 @@ class Channel
|
|||
@signal.from_article(article)
|
||||
end
|
||||
|
||||
def self.streamable?
|
||||
false
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def check_external_credential(options)
|
||||
|
|
|
|||
|
|
@ -33,10 +33,6 @@ class Channel::Driver::CdrWhatsapp
|
|||
@whatsapp.from_article(article)
|
||||
end
|
||||
|
||||
def self.streamable?
|
||||
false
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def check_external_credential(options)
|
||||
|
|
|
|||
|
|
@ -8,20 +8,12 @@ class AddOpensearchNavigation < ActiveRecord::Migration[5.2]
|
|||
# Add permission for accessing OpenSearch dashboards
|
||||
Permission.create_if_not_exists(
|
||||
name: 'user_preferences.opensearch',
|
||||
note: 'Access to OpenSearch Dashboards',
|
||||
description: 'Access to OpenSearch Dashboards',
|
||||
preferences: {}
|
||||
)
|
||||
|
||||
# Create a navigation entry for OpenSearch
|
||||
# This will add a menu item in the sidebar
|
||||
NavBar.create_if_not_exists(
|
||||
name: 'OpenSearch',
|
||||
link: '/opensearch',
|
||||
prio: 2600, # Position in menu (after Dashboard=1400, Tickets=2000, Stats=2500)
|
||||
permission: ['user_preferences.opensearch'],
|
||||
parent: '',
|
||||
active: true
|
||||
)
|
||||
# NavBar was removed in Zammad 7.x; navigation is handled via the desktop UI router.
|
||||
# Legacy NavBar.create_if_not_exists call removed.
|
||||
|
||||
# Grant permission to admin and agent roles
|
||||
%w[Admin Agent].each do |role_name|
|
||||
|
|
@ -31,18 +23,14 @@ class AddOpensearchNavigation < ActiveRecord::Migration[5.2]
|
|||
role.permission_grant('user_preferences.opensearch')
|
||||
end
|
||||
|
||||
Rails.logger.info 'OpenSearch navigation menu item created successfully'
|
||||
Rails.logger.info 'OpenSearch navigation permission created successfully'
|
||||
end
|
||||
|
||||
def self.down
|
||||
# Remove navigation entry
|
||||
navbar = NavBar.find_by(name: 'OpenSearch')
|
||||
navbar&.destroy
|
||||
|
||||
# Remove permission
|
||||
permission = Permission.find_by(name: 'user_preferences.opensearch')
|
||||
permission&.destroy
|
||||
|
||||
Rails.logger.info 'OpenSearch navigation menu item removed'
|
||||
Rails.logger.info 'OpenSearch navigation permission removed'
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue