classMattermostLinkDB(DBBase):''' MattermostLinkDB Collection Struct: - ``_id``: User id. - ``code``: Random code for the user to verify in Mattermost. - ``data``: `dict` User info data from Mattermost. - ``create_at``: `timestamp` '''def__init__(self)->None:super().__init__('mattermost_link')defindex(self)->None:''' To make collection's index Indexs: - `data.user_id` - `data.user_name` '''self.create_index([('data.user_id',1),])self.create_index([('data.user_name',1),])
defindex(self)->None:''' To make collection's index Indexs: - `data.user_id` - `data.user_name` '''self.create_index([('data.user_id',1),])self.create_index([('data.user_name',1),])