mirror of
				https://github.com/pierre42100/ComunicWeb
				synced 2025-11-04 04:04:20 +00:00 
			
		
		
		
	Can update members list public settings
This commit is contained in:
		@@ -204,7 +204,7 @@ const GroupSettingsPage = {
 | 
				
			|||||||
		//Closed registration (required for secret groups)
 | 
							//Closed registration (required for secret groups)
 | 
				
			||||||
		var closedRegistration = createFormGroup({
 | 
							var closedRegistration = createFormGroup({
 | 
				
			||||||
			target: registrationLevelForm,
 | 
								target: registrationLevelForm,
 | 
				
			||||||
			label: "Closed registration (the only way to join the group is to be invited by a moderator)",
 | 
								label: tr("Closed registration (the only way to join the group is to be invited by a moderator)"),
 | 
				
			||||||
			name: "group-registration-level",
 | 
								name: "group-registration-level",
 | 
				
			||||||
			type: "radio",
 | 
								type: "radio",
 | 
				
			||||||
			value: "closed",
 | 
								value: "closed",
 | 
				
			||||||
@@ -253,6 +253,16 @@ const GroupSettingsPage = {
 | 
				
			|||||||
		});
 | 
							});
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							// Make the list of members of the group public
 | 
				
			||||||
 | 
							const isMembersListPublic = createFormGroup({
 | 
				
			||||||
 | 
								target: postsLevelsForm,
 | 
				
			||||||
 | 
								type: "checkbox",
 | 
				
			||||||
 | 
								label: tr("Make the list of members of the group public"),
 | 
				
			||||||
 | 
								checked: settings.is_members_list_public
 | 
				
			||||||
 | 
							});
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		//Group description
 | 
							//Group description
 | 
				
			||||||
@@ -305,6 +315,7 @@ const GroupSettingsPage = {
 | 
				
			|||||||
				visibility: visibilityForm.elements["group-visibility"].value,
 | 
									visibility: visibilityForm.elements["group-visibility"].value,
 | 
				
			||||||
				registration_level: registrationLevelForm.elements["group-registration-level"].value,
 | 
									registration_level: registrationLevelForm.elements["group-registration-level"].value,
 | 
				
			||||||
				posts_level: postsLevelsForm.elements["group-posts-level"].value,
 | 
									posts_level: postsLevelsForm.elements["group-posts-level"].value,
 | 
				
			||||||
 | 
									is_members_list_public: isMembersListPublic.checked,
 | 
				
			||||||
				description: groupDescription.value,
 | 
									description: groupDescription.value,
 | 
				
			||||||
				url: groupURL.value
 | 
									url: groupURL.value
 | 
				
			||||||
			};
 | 
								};
 | 
				
			||||||
@@ -313,7 +324,7 @@ const GroupSettingsPage = {
 | 
				
			|||||||
			submitButton.disabled = true;
 | 
								submitButton.disabled = true;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
			//Perform the request on the API
 | 
								//Perform the request on the API
 | 
				
			||||||
			ComunicWeb.components.groups.interface.setSettings(id, settings, function(result){
 | 
								GroupsInterface.setSettings(id, settings, function(result){
 | 
				
			||||||
 | 
					
 | 
				
			||||||
				//Unlock send button
 | 
									//Unlock send button
 | 
				
			||||||
				submitButton.disabled = false;
 | 
									submitButton.disabled = false;
 | 
				
			||||||
@@ -332,7 +343,7 @@ const GroupSettingsPage = {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		/**
 | 
							/**
 | 
				
			||||||
		 * Group account image
 | 
							 * Group image
 | 
				
			||||||
		 */
 | 
							 */
 | 
				
			||||||
		const groupLogoSettingsContainer = createElem2({
 | 
							const groupLogoSettingsContainer = createElem2({
 | 
				
			||||||
			appendTo: settingsPage,
 | 
								appendTo: settingsPage,
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										1
									
								
								assets/js/typings/Group.d.ts
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1
									
								
								assets/js/typings/Group.d.ts
									
									
									
									
										vendored
									
									
								
							@@ -5,6 +5,7 @@
 | 
				
			|||||||
 */
 | 
					 */
 | 
				
			||||||
 | 
					
 | 
				
			||||||
declare interface AdvancedGroupInfo extends Group {
 | 
					declare interface AdvancedGroupInfo extends Group {
 | 
				
			||||||
 | 
					    is_members_list_public: Boolean,
 | 
				
			||||||
    time_create: Number,
 | 
					    time_create: Number,
 | 
				
			||||||
    description: String,
 | 
					    description: String,
 | 
				
			||||||
    url: String,
 | 
					    url: String,
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user