public static UpdateActivityRequest ToUpdateRpc(this ActivityContent content, string lang, string activityId) { return(new UpdateActivityRequest { ActivityId = activityId, Properties = content.Properties, Content = new Dictionary <string, AFContent> { { lang, new AFContent { Text = content.Text, Button = content.Button?.ToRpc(), Attachments = content.Attachments.ConvertAll(it => it.ToRpc()) } } } }); }
public static CreateActivityRequest ToRpc(this ActivityContent content, string lang, PostActivityTarget target) { return(new CreateActivityRequest { Target = target.Ids.ToRpc(), Properties = content.Properties, Content = new Dictionary <string, AFContent> { { lang, new AFContent { Text = content.Text, Button = content.Button?.ToRpc(), Attachments = content.Attachments.ConvertAll(it => it.ToRpc()) } } } }); }
public static void UpdateActivity(string id, ActivityContent content, Action <Activity> onSuccess, Action <GetSocialError> onFailure) { GetSocialFactory.Bridge.UpdateActivity(id, content, onSuccess, onFailure); }
public static void PostActivity(ActivityContent content, PostActivityTarget target, Action <Activity> onSuccess, Action <GetSocialError> onFailure) { GetSocialFactory.Bridge.PostActivity(content, target, onSuccess, onFailure); }
public void UpdateActivity(string id, ActivityContent content, Action <Activity> onSuccess, Action <GetSocialError> onFailure) { CallAsync("Communities.updateActivity", GSJson.Serialize(new UpdateActivityBody { Target = id, Content = content }), onSuccess, onFailure); }
public void PostActivity(ActivityContent content, PostActivityTarget target, Action <Activity> onSuccess, Action <GetSocialError> onFailure) { CallAsync("Communities.postActivity", GSJson.Serialize(new PostActivityBody { Target = target, Content = content }), onSuccess, onFailure); }