mirror of
https://gitlab.com/comunic/comunicapiv2
synced 2025-07-20 16:45:23 +00:00
Can change conversation name
This commit is contained in:
src
@@ -146,6 +146,25 @@ export class ConversationsHelper {
|
||||
}) == 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* Change the name of a conversation
|
||||
*
|
||||
* @param convID Target conversation
|
||||
* @param name New name for the conversation (empty name
|
||||
* to remove it)
|
||||
*/
|
||||
public static async SetName(convID: number, name: string) {
|
||||
await DatabaseHelper.UpdateRows({
|
||||
table: LIST_TABLE,
|
||||
where: {
|
||||
id: convID
|
||||
},
|
||||
set: {
|
||||
name: name
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Update following state of the conversation
|
||||
*
|
||||
|
Reference in New Issue
Block a user