mirror of
				https://github.com/pierre42100/ComunicWeb
				synced 2025-11-04 04:04:20 +00:00 
			
		
		
		
	Declared update settings function
This commit is contained in:
		@@ -247,10 +247,10 @@ ComunicWeb.components.conversations.chatWindows = {
 | 
			
		||||
	 * @return {Boolean} True for a success
 | 
			
		||||
	 */
 | 
			
		||||
	submitUpdateForm: function(conversation){
 | 
			
		||||
		console.log(conversation);
 | 
			
		||||
 | 
			
		||||
		//Then, get informations about the input
 | 
			
		||||
		var newValues = {
 | 
			
		||||
			conversationID: conversation.infos.ID,
 | 
			
		||||
			following: conversation.settingsForm.followConversationInput.checked,
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
@@ -276,6 +276,9 @@ ComunicWeb.components.conversations.chatWindows = {
 | 
			
		||||
		conversation.settingsForm.createButton.disabled = "true";
 | 
			
		||||
 | 
			
		||||
		//Peform a request through the interface
 | 
			
		||||
		ComunicWeb.components.conversations.interface.updateSettings(newValues, function(result){
 | 
			
		||||
			console.log("Function callback !!!!!!!!!!!!!!", result);
 | 
			
		||||
		});
 | 
			
		||||
 | 
			
		||||
		//Success
 | 
			
		||||
		return true;
 | 
			
		||||
 
 | 
			
		||||
@@ -66,7 +66,7 @@ ComunicWeb.components.conversations.interface = {
 | 
			
		||||
	 * 
 | 
			
		||||
	 * @param {Object} infos Informations about the conversation to create
 | 
			
		||||
	 * * @info {Array} users A list of the members of the conversation
 | 
			
		||||
	 * * @info {Boolan} follow Defines if the current user wants to follow the conversation or not
 | 
			
		||||
	 * * @info {Boolean} follow Defines if the current user wants to follow the conversation or not
 | 
			
		||||
	 * * @info {Mixed} conversationName The name of the conversation
 | 
			
		||||
	 * @param {Function} afterCreate What to do once the conversation is created
 | 
			
		||||
	 * @return {Boolean} True for a success
 | 
			
		||||
@@ -99,6 +99,21 @@ ComunicWeb.components.conversations.interface = {
 | 
			
		||||
		return true;
 | 
			
		||||
	},
 | 
			
		||||
 | 
			
		||||
	/**
 | 
			
		||||
	 * Update conversation settings
 | 
			
		||||
	 * 
 | 
			
		||||
	 * @param {infos} infos Informations about the conversation to update
 | 
			
		||||
	 * @info {Integer} conversationID The ID of the conversation to update
 | 
			
		||||
	 * @info {Boolean} following Specify if the user is following the conversation or not
 | 
			
		||||
	 * @info {String} name Specify a new name for the conversation
 | 
			
		||||
	 * @info {array} members Specify the new list of members for the conversation
 | 
			
		||||
	 * @param {function} callback The function callback
 | 
			
		||||
	 * @return {Boolean} True for a success
 | 
			
		||||
	 */
 | 
			
		||||
	updateSettings: function(infos, callback){
 | 
			
		||||
		console.log("PLEASE IMPLEMENT ME ON NEXT DEVELOPPEMENT FUNCTION");
 | 
			
		||||
	},
 | 
			
		||||
 | 
			
		||||
	/**
 | 
			
		||||
	 * Get informations about a unique conversation
 | 
			
		||||
	 * 
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user