Mono Support Add blogs to each group (Closed)

Viewed 21817 time(s), 6 post(s), 9/12/2011 9:44:02 PM - by DavidGarcia
9/12/2011 9:44:27 PM
659 Reputation 84 Total posts

Hello everybody, first of all i would like to thank all the support staff for giving me the right answers to my kind of silly problems in the past days, really thank you very much.

Recently i've been working with the groups and i have some questions:

1- When you enter a group, i reach into a kind of style sheet with a tabbed panel (screenshoot) for each one of the groups, where is that style sheet located?
2- Can i add new panels to that control? i would like to add a blog section for each one of my groups, for example, or maybe a news section
3- if thats the case do i have to modificate the BD in order to do that?

That's all for the momet, thanks in advance.

1
9/13/2011 8:22:37 AM
15993 Reputation 2214 Total posts

Hi,

first of all thanks for the compliments we do our best to answer the support questions in a shortest time possible, so let me start by pointing you to the CSS style that you need for the tabbed panel etc.

1- When you enter a group, i reach into a kind of style sheet with a tabbed panel (screenshoot) for each one of the groups, where is that style sheet located?
You can find almost all of the style sheets in the /App_Themes/YourTheme(Default)/Default.css file. And as for the tabbed panel try to find the following styles and go from there:
.social-groups .tabs


2- Can i add new panels to that control? i would like to add a blog section for each one of my groups, for example, or maybe a news section
To add more tabs to the tabbed panel you need to inherit the /MonoX/ModuleGallery/SocialNetworking/Groups/GroupView.ascx control and add the mark-up custom tabs to your control, mark-up looks similar to this:
<div class="tabs">
    <ul class="tab" id="rowSwitch" runat="server">
        <li class="<%= InternalWorkingMode.Equals(SnGroupWorkingMode.Wall) ? "current" : String.Empty %>">
            <asp:HyperLink ID="lnkWall" runat="server" CausesValidation="false">
                <span id="labWall" runat="server">Wall</span></asp:HyperLink></li>
        <li class="<%= InternalWorkingMode.Equals(SnGroupWorkingMode.Photos) ? "current" : String.Empty %>">
            <asp:HyperLink ID="lnkPhotos" runat="server" CausesValidation="false">
                <span id="labPhotos" runat="server">Photos</span></asp:HyperLink></li>
        <li class="<%= InternalWorkingMode.Equals(SnGroupWorkingMode.DiscussionBoard) ? "current" : String.Empty %>">
            <asp:HyperLink ID="lnkDiscussion" runat="server" CausesValidation="false">
                <span id="labDiscussion" runat="server">Discussion board</span></asp:HyperLink></li>
    </ul>
</div>

You need to be aware of few things when you perform this kind of inheritance 
1. You need to switch the reference to your custom GroupView control in the GroupContainer
2. You need to manually handle the working mode which includes the new items added by you

3- if thats the case do i have to modificate the BD in order to do that?
I suppose you meant to ask if DB changes are required, well basically no, but you don't need to manually handle the case when Blog or any other module is shown in that group (e.g. you need to be sure that this Blog isn't show anywhere else except in this group, if this is the functionality you want). 

If you need anything else let us know.

Regards


2
9/21/2011 9:46:37 PM
659 Reputation 84 Total posts

Thanks for the response, but im not sure where to start, firstly i added the new <li></li> element like this:

<li><br><asp:HyperLink ID="lnkNoticias" runat="server" CausesValidation="false"><br><span id="labNoticias" runat="server">Noticias</span><br></asp:HyperLink><br></li>

it generates me obviously a non functional tab, now what i need to know is how to import or handle the working mode for example of the News.aspx, and create an element like this:

<MonoX:News runat="server" ID="snNoticias" Title="News" />

Also what changes do i have to make in the GroupView.ascx.cs, this comes to my mind because i was reading the code and found propierties like:

labWall.InnerText = Resources.SocialNetworkingResources.Groups_GroupView_LabelWall;
labPhotos.InnerText = Resources.SocialNetworkingResources.Groups_GroupView_LabelPhotos;
labDiscussion.InnerText = Resources.SocialNetworkingResources.Groups_GroupView_LabelDiscussion;

protected void Page_Load(object sender, EventArgs e)
{
switch (InternalWorkingMode)
{
case SnGroupWorkingMode.Photos:
snPhotos.Visible = true;
break;
case SnGroupWorkingMode.DiscussionBoard:
snDiscussion.Visible = true;
break;
case SnGroupWorkingMode.Wall:
snWallNotes.Visible = true;
break;
default:
snWallNotes.Visible = true;
break;
}


if (this.GroupId != Guid.Empty)
{
CheckUserPrivileges();
this.Page.Title = lblTitle.InnerText;
}
snWallNotes.GravatarRenderType = this.GravatarRenderType;
snPhotos.GravatarRenderType = this.GravatarRenderType;
snDiscussion.GravatarRenderType = this.GravatarRenderType;
}

Hope this will help to explain me better, ill be looking for your excellent support.

3
9/22/2011 7:31:58 AM
15993 Reputation 2214 Total posts

Hi,

I'll try to prepare a short sample that will guide you through this implementation. I'll get back to you soon with a code samples.

BTW: As I can see you have a source code so I believe you have a priority support, so can you please post your issues to your priority support forum ? Let me know for which client you are working for ?

Regards

4
9/22/2011 9:50:43 PM
659 Reputation 84 Total posts

Ok, i will be moving my post to my priority support forum, since i didn't know i had one i haven't post anything there yet.
I will be posting it under the name of roquemocan, thanks for everything!

5
9/23/2011 6:25:40 AM
15993 Reputation 2214 Total posts

Ok, I'm closing this topic and I'll get back to you on the priority support topic.

6
This is a demo site for MonoX. Please visit Mono Software for more info.