Skip to content

Instantly share code, notes, and snippets.

@rhysgodfrey
rhysgodfrey / gist:7697bf9850eb37660df3
Created February 13, 2015 11:31
Zimbra Social Introduction - Demo 1 - User list Widget
#set($list = $core_v2_user.List("%{IncludeHidden = 'True', PageSize = 100 }"))
#foreach($user in $list)
#beforeall
<div>
#before
<div>
#each
$core_v2_ui.GetResizedImageHtml($user.AvatarUrl, 50, 50, "%{ }")
<span>$user.Username</span>
@rhysgodfrey
rhysgodfrey / gist:c940c991f6feb6fe422a
Created February 13, 2015 15:34
Zimbra Social Introduction - Demo 3 - Switch to Gravatar
#set($list = $core_v2_user.List("%{IncludeHidden = 'True', PageSize = 100 }"))
#foreach($user in $list)
#beforeall
<div>
#before
<div>
#each
<img src="$demo_v1_gravatar.Url($user.Id)" />
<span>$user.Username</span>
@rhysgodfrey
rhysgodfrey / ui.js
Created February 13, 2015 16:20
Zimbra Social Introduction - Demo 4 - Set Users Bio
#set($list = $core_v2_user.List("%{IncludeHidden = 'True', PageSize = 100 }"))
#foreach($user in $list)
#beforeall
<div>
#before
<div>
#each
<img src="$demo_v1_gravatar.Url($user.Id)" />
<span>$user.Username</span>
DECLARE @RC int
DECLARE @olderThanDays int
DECLARE @minRemainingPerUser int
SET @olderThanDays = 93
SET @minRemainingPerUser = 30
EXECUTE @RC = [Community61DEV].[dbo].[cs_Messaging_DeleteActivityMessages]
@olderThanDays
,@minRemainingPerUser
DECLARE @return_value int
EXEC @return_value = [dbo].[te_DistributedMonitor_Leases_Remove]
@OlderThanHours = 0
SELECT 'Return Value' = @return_value
GO
<job schedule="10 0 1 ? * SUN" type="Telligent.Evolution.CoreServices.Recommendations.UserRecommendationCalculationJob, Telligent.Evolution.Core">
<settings>
<add key="UserActivityCutoffInMonths" value="12" />
</settings>
</job>
@rhysgodfrey
rhysgodfrey / Tester.cs
Created August 16, 2015 16:54
Failed to Emit Module Example
public class Tester
{
public void GetForumThread()
{
var thread = PublicApi.ForumThreads.Get(123);
}
}
@rhysgodfrey
rhysgodfrey / Tester.cs
Created August 16, 2015 16:56
Failed to Emit Module - Workaround Example
public class Tester
{
public void GetForumThread()
{
var thread = PublicApi.ForumThreads.Get(123, null);
}
}
using Telligent.Evolution.Extensibility.Api.Version1;
using Telligent.Evolution.Extensibility.Content.Version1;
using Telligent.Evolution.Extensibility.Version1;
namespace RhysGodfrey.TelligentStoryExamples
{
public class BlogPostStoryType : Telligent.Evolution.Api.Plugins.ActivityStories.BlogPostStoryType, IActivityStoryType, IPlugin
{
string IActivityStoryType.GetViewHtml(IActivityStory story, Target target)
{
using System;
using Telligent.Evolution.Extensibility.Storage.Version1;
using Telligent.Evolution.Extensibility.UI.Version1;
using Telligent.Evolution.Extensibility.Version1;
namespace RhysGodfrey.TelligentGistExample
{
public class GistFileViewer : IPlugin, IFileViewer
{
public int DefaultOrderNumber