Skip to content

Commit

Permalink
Release 0.59.3 0.5.0 (RocketChat#166)
Browse files Browse the repository at this point in the history
* Fixed Issues 87, 88

* Feature/mrsimpson#23 title first message to new request (RocketChat#149)

* Request title and first message while creating new request
* Make titles of inputs and placeholders more consistent
* Fix display issues:

- Dropdown overlapped by input field
- In English, the width of the creation dialog was not 100%, thus input fields within too narrow

* Minor corrections with respect to error handling:

- Refactor error display to an own template
- Show error if selected expertise on request creation is invalid (not chosen from the dropdown)
- Fix positioning of "at" on members selection if invalid

* Fixes RocketChat#151 - Misspelled label "jetzt chaten" (RocketChat#152)

* Corrections to creation dialog (RocketChat#154)

* Corrections to creation dialog

- Propagate first message properly (fixes RocketChat#153)
- Change "Name" to "Title"
- get rid of flashing error message on auto-complete-confirmation with tab

* Corrections to creation dialog

- more robust error handling
- prevent flashing of validation errors

* Fix improper clearing of request title

* Invalid Expertise field highlight

* RocketChat#156 Prefill request creation form (RocketChat#157)

* fixes RocketChat#156

- Pass topic as URL param (URL encoded) as `topic` or `expertise` (same effect)
- Title is focused if expertise is passed

* Allow pre-filling of title and question as well.

This way, fixes mrsimpson#20 : The consumer (e. g. the wiki page) can create a simple form an pass the content as parameter

* - Use the copied current() instead of the internal value
```
FlowRouter.current
ƒ () {                                                                               // 248
  // We can't trust outside, that's why we clone this                                                        …
```
- refactor query-selectors => reuse

* use FlowRouter API properly

* Setting based permissions - downport (RocketChat#158)

* Allow maintenance of per-setting permissions

(cherry picked from commit eed869a)

* Implicitly assign and revoke setting group permissions

(cherry picked from commit 28b769b)

* Improve Display of setting permissions

(cherry picked from commit 8523456)

* Add path to permission title

(cherry picked from commit c87a30d)

* Permission to access setting permissions

(cherry picked from commit 48b1076)

* Adapt wording

(cherry picked from commit daccad8)

* UI-adaptation: Allow users with permission 'manage-selected-permissions' to see and change the affected settings.
However, this is not reactive: Once the permissions for a particular setting are changed, the user needs to log  off and on again before it becomes effective in the UI.
This is most probably a consequence of the CachedCollection. This collection needed to be changed on permission-change.
In the backend however, the permissions become effective immediately.

(cherry picked from commit 00e4bb5)

* Don't adapt sorting on the client side

(cherry picked from commit 9b71b62)

* Fix: Apply changed setting permissions reactively

(cherry picked from commit 293ad73)

* Move setting-based permissions to own collection

(cherry picked from commit 8f59f1c)

* Unify collections for setting and other permissions again into one

(cherry picked from commit 8d923c2)

* Get rid of frontend exceptions on changing selected settings

(cherry picked from commit a7fdc87)

* - Sort permissions by group
- Do not try to create permissions for hidden settings in higher-level-callbacks
- Remove `setting-permissions` collection - fully integrated into `permissions`

(cherry picked from commit f007231)

* Harmonize wording in German

(cherry picked from commit 5cf5df2)

* German language informalized (RocketChat#160)

* German language informalized - Liebe Deutsche, wir kennen euch nun besser. Wir wollen ab jetzt “Du” zu einander sagen 😉

* Update de.i18n.json

* Update de.i18n.json

* Update de.i18n.json

* Allow administration even if user has got only `edit-privileged-setting` but not `view-privileged-setting`

* Revert "Fixed Issues 87, 88 (livechat on mobile devices)" (RocketChat#164)

* Create configuration expert role on startup (RocketChat#159)

* Allow maintenance of per-setting permissions

(cherry picked from commit eed869a)

* Implicitly assign and revoke setting group permissions

(cherry picked from commit 28b769b)

* Improve Display of setting permissions

(cherry picked from commit 8523456)

* Add path to permission title

(cherry picked from commit c87a30d)

* Permission to access setting permissions

(cherry picked from commit 48b1076)

* Adapt wording

(cherry picked from commit daccad8)

* UI-adaptation: Allow users with permission 'manage-selected-permissions' to see and change the affected settings.
However, this is not reactive: Once the permissions for a particular setting are changed, the user needs to log  off and on again before it becomes effective in the UI.
This is most probably a consequence of the CachedCollection. This collection needed to be changed on permission-change.
In the backend however, the permissions become effective immediately.

(cherry picked from commit 00e4bb5)

* Don't adapt sorting on the client side

(cherry picked from commit 9b71b62)

* Fix: Apply changed setting permissions reactively

(cherry picked from commit 293ad73)

* Move setting-based permissions to own collection

(cherry picked from commit 8f59f1c)

* Unify collections for setting and other permissions again into one

(cherry picked from commit 8d923c2)

* Get rid of frontend exceptions on changing selected settings

(cherry picked from commit a7fdc87)

* - Sort permissions by group
- Do not try to create permissions for hidden settings in higher-level-callbacks
- Remove `setting-permissions` collection - fully integrated into `permissions`

(cherry picked from commit f007231)

* Harmonize wording in German

(cherry picked from commit 5cf5df2)

* add configuration package

* Add default role configuration on startup

* set default system language to DE

* Reduce capabilities of config expert and introduce minor admin

* Parted the roles for configuration and managing the rest

- Manager - well - manages the application, like a minor admin. Target is that this role is capable of doing everything which is necessary while *regularly* running the application
- Config-expert is allowed to customize the application (affecting all users' experience)

* Informal german language for our custom texts (RocketChat#165)

* German language informalized - Liebe Deutsche, wir kennen euch nun besser. Wir wollen ab jetzt “Du” zu einander sagen 😉

* German texts of custom enhancement informalized

* Bump version to 0.5.0

* Update HISTORY.md
  • Loading branch information
mrsimpson authored and ruKurz committed Dec 7, 2017
1 parent ee1dc14 commit c4f7b88
Show file tree
Hide file tree
Showing 42 changed files with 1,338 additions and 494 deletions.
1 change: 1 addition & 0 deletions .meteor/packages
Original file line number Diff line number Diff line change
Expand Up @@ -180,3 +180,4 @@ keepnox:perfect-scrollbar

assistify:help-request
assistify:ai
assistify:defaults
1 change: 1 addition & 0 deletions .meteor/versions
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ accounts-twitter@1.3.0
aldeed:simple-schema@1.5.3
allow-deny@1.0.9
assistify:ai@0.1.0
assistify:defaults@0.0.1
assistify:help-request@0.1.0
autoupdate@1.3.12
babel-compiler@6.20.0
Expand Down
12 changes: 11 additions & 1 deletion HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,17 @@
<a name="assistify-0.5.0"></a>
## Assistify-0.5.0 (2017-12-07)

### Enhancements
- You can add a title and the actual question to the request while creating it
- The request creation screen allows to pass url-parameters. This enables a very loosely coupled integration, e. g. into a [confluence-based wiki](https://github.com/assistify/confluence-integration)
- Roles can be authorized to change particular settings only. This allows you to customize Assistify with respect to colors, texts and more - given you've got the `config-expert` role!
- :de: Wir kennen euch nun besser. Wir wollen ab jetzt “Du” zu einander sagen, ok? 😉 :de:


<a name="assistify-0.4.4"></a>
## Assistify-0.4.4 (2017-11-10)

## Enhancements
### Enhancements
- Based on <a href="#0.59.3">Rocket.Chat 0.59.3</a>
- Provide more explanation texts for dialogs
- [#140](https://github.com/assistify/Rocket.Chat/issues/140) Provide more information for disabled users when trying to log-in
Expand Down
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,9 @@
"chat"
],
"scripts": {
"start": "meteor npm i && meteor",
"start": "meteor npm i && meteor run",
"debug": "meteor run --inspect",
"debug-brk": "meteor run --inspect-brk",
"lint": "eslint .",
"lint-fix": "eslint . --fix",
"stylelint": "stylelint packages/**/*.css",
Expand Down
8 changes: 8 additions & 0 deletions packages/assistify-defaults/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
This package is a convenience package which shall reduce the effort of manually configuring each Rocket.Chat instance.
In order to achieve this, it provides

- Settings
- Roles
- potentially also integrations, icons, ...

on startup.
19 changes: 19 additions & 0 deletions packages/assistify-defaults/package.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
Package.describe({
name: 'assistify:defaults',
version: '0.0.1',
// Brief, one-line summary of the package.
summary: 'Default configuration of Rocket.Chat for Assistify',
git: '',
documentation: 'README.md'
});

Package.onUse(function(api) {
api.use('ecmascript');
api.use('rocketchat:lib');
api.use('rocketchat:authorization');
api.use('assistify:help-request');
api.use('assistify:ai');

api.addFiles('server/config.js', 'server');
api.addFiles('server/roles.js', 'server');
});
8 changes: 8 additions & 0 deletions packages/assistify-defaults/server/config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
/* globals RocketChat */

Meteor.startup(() => {
const languageSetting = RocketChat.models.Settings.db.findOneById('Language');
if (!languageSetting.value && languageSetting.value === languageSetting.packageValue) {
RocketChat.models.Settings.db.updateValueById(languageSetting._id, 'en');
}
});
232 changes: 232 additions & 0 deletions packages/assistify-defaults/server/roles.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,232 @@
import {TAPi18n} from 'meteor/tap:i18n';

const CONFIGURATION_ROLE_NAME = 'config-expert';
const MANAGER_ROLE_NAME = 'manager';


const assignPermissions = function(role, permissions) {
permissions.forEach(permission => RocketChat.models.Permissions.addRole(permission, role));
};

const createConfigurationRole = function() {
RocketChat.models.Roles.createOrUpdate(CONFIGURATION_ROLE_NAME, 'Users', TAPi18n.__('Configuration_expert_description'));
const settingPermissions = [
'change-setting-Message_AllowSnippeting',
'change-setting-Message_AllowStarring',
'change-setting-Message_AllowPinning',
'change-setting-Markdown_Parser',
'change-setting-Livechat_AllowedDomainsList',
'change-setting-Livechat_open_inquiery_show_connecting',
'change-setting-Livechat_transcript_message',
'change-setting-Livechat_enable_transcript',
'change-setting-Livechat_enable_office_hours',
'change-setting-Livechat_show_queue_list_link',
'change-setting-Livechat_guest_pool_with_no_agents',
'change-setting-Livechat_Routing_Method',
'change-setting-Livechat_history_monitor_type',
'change-setting-Livechat_webhook_on_close',
'change-setting-Livechat_secret_token',
'change-setting-Livechat_webhookUrl',
'change-setting-Livechat_agent_leave_comment',
'change-setting-Livechat_agent_leave_action_timeout',
'change-setting-Livechat_agent_leave_action',
'change-setting-Livechat_Room_Count',
'change-setting-Livechat_guest_count',
'change-setting-Livechat_allow_switching_departments',
'change-setting-Livechat_registration_form',
'change-setting-Livechat_offline_success_message',
'change-setting-Livechat_offline_email',
'change-setting-Livechat_offline_message',
'change-setting-Livechat_offline_title_color',
'change-setting-Livechat_offline_title',
'change-setting-Livechat_offline_form_unavailable',
'change-setting-Livechat_validate_offline_email',
'change-setting-Livechat_display_offline_form',
'change-setting-Livechat_title_color',
'change-setting-Livechat_title',
'change-setting-Livechat_enabled',
'change-setting-Livechat',
'change-setting-Katex_Dollar_Syntax',
'change-setting-Katex_Parenthesis_Syntax',
'change-setting-Katex_Enabled',
'change-setting-Accounts_Iframe_api_method',
'change-setting-Accounts_Iframe_api_url',
'change-setting-Accounts_iframe_url',
'change-setting-Accounts_iframe_enabled',
'change-setting-AutoLinker_Phone',
'change-setting-AutoLinker_Email',
'change-setting-AutoLinker_UrlsRegExp',
'change-setting-AutoLinker_Urls_TLD',
'change-setting-AutoLinker_Urls_www',
'change-setting-AutoLinker_Urls_Scheme',
'change-setting-AutoLinker_StripPrefix',
'change-setting-AutoLinker',
'change-setting-IssueLinks_Template',
'change-setting-IssueLinks_Enabled',
'change-setting-InternalHubot_ScriptsToLoad',
'change-setting-InternalHubot_Username',
'change-setting-InternalHubot_Enabled',
'change-setting-InternalHubot',
'change-setting-HexColorPreview_Enabled',
'change-setting-theme-custom-css',
'change-setting-theme-color-rc-color-content',
'change-setting-theme-color-rc-color-primary-lightest',
'change-setting-theme-color-rc-color-primary-light-medium',
'change-setting-theme-color-rc-color-primary-light',
'change-setting-theme-color-rc-color-primary-dark',
'change-setting-theme-color-rc-color-primary-darkest',
'change-setting-theme-color-rc-color-primary',
'change-setting-theme-color-rc-color-button-primary-light',
'change-setting-theme-color-rc-color-button-primary',
'change-setting-theme-color-rc-color-success-light',
'change-setting-theme-color-rc-color-success',
'change-setting-theme-color-rc-color-alert-light',
'change-setting-theme-color-rc-color-alert',
'change-setting-theme-color-rc-color-error-light',
'change-setting-theme-color-rc-color-error',
'change-setting-Assets_safari_pinned',
'change-setting-Assets_tile_310_wide',
'change-setting-Assets_tile_310_square',
'change-setting-Assets_tile_150',
'change-setting-Assets_tile_144',
'change-setting-Assets_touchicon_180_pre',
'change-setting-Assets_touchicon_180',
'change-setting-Assets_favicon_512',
'change-setting-Assets_favicon_192',
'change-setting-Assets_favicon_32',
'change-setting-Assets_favicon_16',
'change-setting-Assets_favicon',
'change-setting-Assets_favicon_ico',
'change-setting-Assets_logo',
'change-setting-Assets_SvgFavicon_Enable',
'change-setting-Assets',
'change-setting-UI_Allow_room_names_with_special_chars',
'change-setting-UI_Unread_Counter_Style',
'change-setting-UI_Click_Direct_Message',
'change-setting-UI_Use_Real_Name',
'change-setting-UI_Use_Name_Avatar',
'change-setting-UI_Merge_Channels_Groups',
'change-setting-UI_DisplayRoles',
'change-setting-Layout_Global_Announcement',
'change-setting-Layout_Sidenav_Footer',
'change-setting-Layout_Home_Body',
'change-setting-Layout_Home_Title',
'change-setting-Layout',
'change-setting-Message_HideType_mute_unmute',
'change-setting-Message_HideType_au',
'change-setting-Message_HideType_ru',
'change-setting-Message_HideType_ul',
'change-setting-Message_HideType_uj',
'change-setting-Message_QuoteChainLimit',
'change-setting-API_EmbedIgnoredHosts',
'change-setting-API_EmbedDisabledFor',
'change-setting-API_EmbedCacheExpirationDays',
'change-setting-API_Embed',
'change-setting-Message_GroupingPeriod',
'change-setting-Message_SetNameToAliasEnabled',
'change-setting-Message_ShowFormattingTips',
'change-setting-Message_MaxAllowedSize',
'change-setting-Message_MaxAll',
'change-setting-Message_KeepHistory',
'change-setting-Message_BadWordsFilterList',
'change-setting-Message_AllowBadWordsFilter',
'change-setting-Message_ShowDeletedStatus',
'change-setting-Message_ShowEditedStatus',
'change-setting-Message_AlwaysSearchRegExp',
'change-setting-Message_AllowDeleting_BlockDeleteInMinutes',
'change-setting-Message_AllowDeleting',
'change-setting-Message_AllowEditing_BlockEditInMinutes',
'change-setting-Message_AllowEditing',
'change-setting-Message_Attachments_GroupAttach',
'change-setting-Message',
'change-setting-Verification_Email',
'change-setting-Verification_Email_Subject',
'change-setting-Verification_Customized',
'change-setting-Forgot_Password_Email',
'change-setting-Forgot_Password_Email_Subject',
'change-setting-Forgot_Password_Customized',
'change-setting-Accounts_UserAddedEmail',
'change-setting-Accounts_UserAddedEmailSubject',
'change-setting-Accounts_UserAddedEmail_Customized',
'change-setting-Accounts_Enrollment_Email',
'change-setting-Accounts_Enrollment_Email_Subject',
'change-setting-Accounts_Enrollment_Customized',
'change-setting-Invitation_HTML',
'change-setting-Invitation_Subject',
'change-setting-Invitation_Customized',
'change-setting-Email_Footer',
'change-setting-Email_Header',
'change-setting-Offline_Mention_All_Email',
'change-setting-Offline_Mention_Email',
'change-setting-Email',
'change-setting-Custom_Translations',
'change-setting-Notifications_Max_Room_Members',
'change-setting-Mobile_Notifications_Default_Alert',
'change-setting-Desktop_Notifications_Default_Alert',
'change-setting-Audio_Notifications_Default_Alert',
'change-setting-Audio_Notifications_Value',
'change-setting-Desktop_Notifications_Duration',
'change-setting-UTF8_Names_Slugify',
'change-setting-UTF8_Names_Validation',
'change-setting-Unread_Count_DM',
'change-setting-Unread_Count',
'change-setting-First_Channel_After_Login',
'change-setting-Favorite_Rooms',
'change-setting-Language',
'change-setting-General',
'change-setting-Accounts_BlockedUsernameList',
'change-setting-Accounts_BlockedDomainsList',
'change-setting-Accounts_AllowedDomainsList',
'change-setting-Accounts_ManuallyApproveNewUsers',
'change-setting-Accounts_EmailVerification',
'change-setting-Accounts'
];

assignPermissions(CONFIGURATION_ROLE_NAME,
settingPermissions.concat([
'manage-emoji',
'manage-own-integrations',
'manage-selected-settings'
]));
};

const createManagerRole = function() {
RocketChat.models.Roles.createOrUpdate(MANAGER_ROLE_NAME, 'Users', TAPi18n.__('Manager_description'));

const permissions = [
'add-user-to-any-c-room',
'archive-room',
'ban-user',
'bulk-register-user',
'create-user',
'delete-c',
// 'delete-d',
'delete-message',
// 'delete-p',
'edit-message',
'edit-other-user-active-status',
'edit-other-user-info',
'edit-other-user-password',
'manage-emoji',
'manage-own-integrations',
'manage-selected-settings',
'mute-user',
'post-readonly',
'remove-user',
'set-moderator',
'set-owner',
'set-readonly',
'set-react-when-readonly',
'unarchive-room',
'view-full-other-user-info',
'view-room-administration',
'view-user-administration'
];

assignPermissions(MANAGER_ROLE_NAME, permissions);
};

Meteor.startup(() => {
createConfigurationRole();
createManagerRole();
});
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ <h1 class="create-channel__title">{{_ "Expertises"}}</h1>
<div class="create-channel__inputs">
<div class="rc-input {{#if invalidChannel}}rc-input--error{{/if}}">
<label class="rc-input__label">
<div class="rc-input__title">{{_ "Expertise_title"}}</div>
<div class="rc-input__title">{{_ "Name"}}</div>
<div class="rc-input__wrapper">
<div class="rc-input__icon">
{{> icon block="rc-input__icon-svg" icon="flag" }}
Expand All @@ -17,17 +17,12 @@ <h1 class="create-channel__title">{{_ "Expertises"}}</h1>
</div>
</label>
{{#if inUse}}
<div class="rc-input__error">
<div class="rc-input__error-icon">
{{> icon block="rc-input__error-icon" icon="warning" classes="rc-input__error-icon-svg"}}
</div>
<div class="rc-input__error-message">{{_ "Channel_already_exist_static"}}</div>
</div>
{{> AssistifyCreateInputError text="Channel_already_exist_static"}}
{{/if}}
</div>
<div class="rc-input">
<label class="rc-input__label">
<div class="rc-input__title">{{_ "Choose_experts"}}</div>
<div class="rc-input__title">{{_ "Experts"}}</div>
<div class="rc-input__wrapper">
<div class="rc-input__icon">
{{> icon block="rc-input__icon-svg" icon="at"}}
Expand All @@ -36,18 +31,13 @@ <h1 class="create-channel__title">{{_ "Expertises"}}</h1>
{{#each user in selectedUsers}}
{{> tag user}}
{{/each}}
<input type="text" class="rc-tags__input {{#if invalidMembers}}rc-input--error{{/if}}" placeholder="{{_ "Experts"}}"
<input type="text" class="rc-tags__input {{#if invalidMembers}}rc-input--error{{/if}}" placeholder="{{_ "Choose_experts"}}"
name="experts" autocomplete="off"/>
</div>
{{#if invalidMembers}}
<div class="rc-input__error">
<div class="rc-input__error-icon">
{{> icon block="rc-input__error-icon" icon="warning" classes="rc-input__error-icon-svg"}}
</div>
<div class="rc-input__error-message">{{_ "Expertise_needs_experts"}}</div>
</div>
{{/if}}
</div>
{{#if invalidMembers}}
{{> AssistifyCreateInputError text="Expertise_needs_experts"}}
{{/if}}
{{#with config}}
{{#if autocomplete 'isShowing'}}
<div class="fadeInDown">
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<template name="AssistifyCreateInputError">
<div class="rc-input__error">
<div class="rc-input__error-icon">
{{> icon block="rc-input__error-icon" icon="warning" classes="rc-input__error-icon-svg"}}
</div>
<div class="rc-input__error-message">{{_ text}}</div>
</div>
</template>
Loading

0 comments on commit c4f7b88

Please sign in to comment.