forked from Ivasoft/mattermost-mobile
[Gekidou] groups (#5593)
* Rename groups in channel/team to group channel/team * Redefine groups schema * Groups action and operator * Add group at mentions * fix uni test * Update types/database/models/servers/group.d.ts Co-authored-by: Avinash Lingaloo <avinashlng1080@gmail.com> Co-authored-by: Avinash Lingaloo <avinashlng1080@gmail.com>
This commit is contained in:
@@ -12,8 +12,8 @@ import {
|
||||
FileSchema,
|
||||
GroupMembershipSchema,
|
||||
GroupSchema,
|
||||
GroupsInChannelSchema,
|
||||
GroupsInTeamSchema,
|
||||
GroupsChannelSchema,
|
||||
GroupsTeamSchema,
|
||||
MyChannelSchema,
|
||||
MyChannelSettingsSchema,
|
||||
MyTeamSchema,
|
||||
@@ -45,8 +45,8 @@ export const serverSchema: AppSchema = appSchema({
|
||||
FileSchema,
|
||||
GroupMembershipSchema,
|
||||
GroupSchema,
|
||||
GroupsInChannelSchema,
|
||||
GroupsInTeamSchema,
|
||||
GroupsChannelSchema,
|
||||
GroupsTeamSchema,
|
||||
MyChannelSchema,
|
||||
MyChannelSettingsSchema,
|
||||
MyTeamSchema,
|
||||
|
||||
@@ -10,6 +10,8 @@ const {GROUP} = MM_TABLES.SERVER;
|
||||
export default tableSchema({
|
||||
name: GROUP,
|
||||
columns: [
|
||||
{name: 'allow_reference', type: 'boolean'},
|
||||
{name: 'delete_at', type: 'number'},
|
||||
{name: 'display_name', type: 'string'},
|
||||
{name: 'name', type: 'string'},
|
||||
],
|
||||
|
||||
@@ -5,10 +5,10 @@ import {tableSchema} from '@nozbe/watermelondb';
|
||||
|
||||
import {MM_TABLES} from '@constants/database';
|
||||
|
||||
const {GROUPS_IN_CHANNEL} = MM_TABLES.SERVER;
|
||||
const {GROUPS_CHANNEL} = MM_TABLES.SERVER;
|
||||
|
||||
export default tableSchema({
|
||||
name: GROUPS_IN_CHANNEL,
|
||||
name: GROUPS_CHANNEL,
|
||||
columns: [
|
||||
{name: 'channel_id', type: 'string', isIndexed: true},
|
||||
{name: 'group_id', type: 'string', isIndexed: true},
|
||||
@@ -5,10 +5,10 @@ import {tableSchema} from '@nozbe/watermelondb';
|
||||
|
||||
import {MM_TABLES} from '@constants/database';
|
||||
|
||||
const {GROUPS_IN_TEAM} = MM_TABLES.SERVER;
|
||||
const {GROUPS_TEAM} = MM_TABLES.SERVER;
|
||||
|
||||
export default tableSchema({
|
||||
name: GROUPS_IN_TEAM,
|
||||
name: GROUPS_TEAM,
|
||||
columns: [
|
||||
{name: 'group_id', type: 'string', isIndexed: true},
|
||||
{name: 'team_id', type: 'string', isIndexed: true},
|
||||
@@ -9,8 +9,8 @@ export {default as DraftSchema} from './draft';
|
||||
export {default as FileSchema} from './file';
|
||||
export {default as GroupMembershipSchema} from './group_membership';
|
||||
export {default as GroupSchema} from './group';
|
||||
export {default as GroupsInChannelSchema} from './groups_in_channel';
|
||||
export {default as GroupsInTeamSchema} from './groups_in_team';
|
||||
export {default as GroupsChannelSchema} from './groups_channel';
|
||||
export {default as GroupsTeamSchema} from './groups_team';
|
||||
export {default as MyChannelSchema} from './my_channel';
|
||||
export {default as MyChannelSettingsSchema} from './my_channel_settings';
|
||||
export {default as MyTeamSchema} from './my_team';
|
||||
|
||||
@@ -15,8 +15,8 @@ const {
|
||||
DRAFT,
|
||||
FILE,
|
||||
GROUP,
|
||||
GROUPS_IN_CHANNEL,
|
||||
GROUPS_IN_TEAM,
|
||||
GROUPS_CHANNEL,
|
||||
GROUPS_TEAM,
|
||||
GROUP_MEMBERSHIP,
|
||||
MY_CHANNEL,
|
||||
MY_CHANNEL_SETTINGS,
|
||||
@@ -248,16 +248,20 @@ describe('*** Test schema for SERVER database ***', () => {
|
||||
[GROUP]: {
|
||||
name: GROUP,
|
||||
columns: {
|
||||
allow_reference: {name: 'allow_reference', type: 'boolean'},
|
||||
delete_at: {name: 'delete_at', type: 'number'},
|
||||
display_name: {name: 'display_name', type: 'string'},
|
||||
name: {name: 'name', type: 'string'},
|
||||
},
|
||||
columnArray: [
|
||||
{name: 'allow_reference', type: 'boolean'},
|
||||
{name: 'delete_at', type: 'number'},
|
||||
{name: 'display_name', type: 'string'},
|
||||
{name: 'name', type: 'string'},
|
||||
],
|
||||
},
|
||||
[GROUPS_IN_CHANNEL]: {
|
||||
name: GROUPS_IN_CHANNEL,
|
||||
[GROUPS_CHANNEL]: {
|
||||
name: GROUPS_CHANNEL,
|
||||
columns: {
|
||||
channel_id: {name: 'channel_id', type: 'string', isIndexed: true},
|
||||
group_id: {name: 'group_id', type: 'string', isIndexed: true},
|
||||
@@ -271,8 +275,8 @@ describe('*** Test schema for SERVER database ***', () => {
|
||||
{name: 'timezone_count', type: 'number'},
|
||||
],
|
||||
},
|
||||
[GROUPS_IN_TEAM]: {
|
||||
name: GROUPS_IN_TEAM,
|
||||
[GROUPS_TEAM]: {
|
||||
name: GROUPS_TEAM,
|
||||
columns: {
|
||||
group_id: {name: 'group_id', type: 'string', isIndexed: true},
|
||||
team_id: {name: 'team_id', type: 'string', isIndexed: true},
|
||||
|
||||
Reference in New Issue
Block a user