mattermost-mobile/app/database/default/models/servers.ts
Avinash Lingaloo 661904fbaf
MM-33224 [v2] Data Operator Team section (#5272)
* MM_33224 : Team [IN PROGRESS]

* MM_33224 : Updating test for Team schema after addition of update_at column

* MM_33224 : Team Entity - Completed

* MM_33224 - TeamChannelHistory - Completed

* MM_33224 : Removing duplicates RawValues before processing them

* MM-33224 : TeamSearchHistory - Completed

* MM-33224 : Slash Command - Completed

* MM-33224 : My Team - Completed

* MM-33227 [v2] Data Operator Channel section (#5277)

* MM_33227 : Channel[IN PROGRESS]

* MM_33227 : Channel - Completed

* MM-33227 : MyChannelSettings - Completed

* MM-33227 : ChannelInfo - Completed

* MM-33227 :  MyChannel - Completed

* MM-33227 : Added expected results in handlers' test

* MM_33227 : Renamed RawApp and RawServers fields

* MM_33227 : Cleaning up Role

* MM_33227 : Cleaning TOS

* MM-33227 : Cleaning up Group comparator

* MM-33227 : Updated JSDoc

* MM-33227 : Fixed 'comparators' to comparator in JSDoc

Co-authored-by: Avinash Lingaloo <>

Co-authored-by: Avinash Lingaloo <>
2021-04-09 10:08:32 +04:00

33 lines
1.1 KiB
TypeScript

// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import {Model} from '@nozbe/watermelondb';
import {field} from '@nozbe/watermelondb/decorators';
import {MM_TABLES} from '@constants/database';
const {SERVERS} = MM_TABLES.DEFAULT;
/**
* The Server model will help us to identify the various servers a user will log in; in the context of
* multi-server support system. The db_path field will hold the App-Groups file-path
*/
export default class Servers extends Model {
/** table (entity name) : servers */
static table = SERVERS;
/** db_path : The file path where the database is stored */
@field('db_path') dbPath!: string;
/** display_name : The server display name */
@field('display_name') displayName!: string;
/** mention_count : The number of mention on this server */
@field('mention_count') mentionCount!: number;
/** unread_count : The number of unread messages on this server */
@field('unread_count') unreadCount!: number;
/** url : The online address for the Mattermost server */
@field('url') url!: string;
}