69 lines
2.3 KiB
C#
69 lines
2.3 KiB
C#
|
using MyCode.Project.Domain.Message.Act.User;
|
|||
|
using MyCode.Project.Domain.Message.Request.Activity;
|
|||
|
using MyCode.Project.Domain.Message.Request.Member;
|
|||
|
using MyCode.Project.Domain.Message.Request.User;
|
|||
|
using MyCode.Project.Domain.Message.Response.CardCover;
|
|||
|
using MyCode.Project.Domain.Message.Response.Goods;
|
|||
|
using MyCode.Project.Domain.Message.Response.LiveVideo;
|
|||
|
using MyCode.Project.Domain.Message.Response.Member;
|
|||
|
using MyCode.Project.Domain.Message.Response.Wechat;
|
|||
|
using MyCode.Project.Infrastructure.Common;
|
|||
|
using MyCode.Project.Services;
|
|||
|
using System;
|
|||
|
using System.Collections.Generic;
|
|||
|
using System.Web.Http;
|
|||
|
|
|||
|
namespace MyCode.Project.WebApi.Areas.Member.Controllers
|
|||
|
{
|
|||
|
/// <summary>
|
|||
|
/// 直播间相关接口
|
|||
|
/// </summary>
|
|||
|
public class LiveVideoController : BaseMemberController
|
|||
|
{
|
|||
|
#region 初始化
|
|||
|
private readonly ILiveVideoService _liveVideoService;
|
|||
|
public LiveVideoController(ILiveVideoService liveVideoService)
|
|||
|
{
|
|||
|
_liveVideoService = liveVideoService;
|
|||
|
}
|
|||
|
#endregion
|
|||
|
|
|||
|
#region GetLiveInfo(获取当前最新的直播房间列表)
|
|||
|
/// <summary>
|
|||
|
/// 获取当前最新的直播房间列表
|
|||
|
/// </summary>
|
|||
|
[HttpGet]
|
|||
|
[AllowAnonymous]
|
|||
|
public List<Room_info> GetLiveInfo()
|
|||
|
{
|
|||
|
return _liveVideoService.GetLiveInfo();
|
|||
|
}
|
|||
|
#endregion
|
|||
|
|
|||
|
|
|||
|
#region SetMemberRelationshipFromLiveVideo(更新商城直播的会员关系链的方法)
|
|||
|
/// <summary>
|
|||
|
/// 更新商城直播的会员关系链的方法
|
|||
|
/// </summary>
|
|||
|
/// <param name="act"></param>
|
|||
|
[HttpPost]
|
|||
|
[AllowAnonymous]
|
|||
|
public string SetMemberRelationshipFromLiveVideo(LiveVideoMemberRelationshipAct act)
|
|||
|
{
|
|||
|
return _liveVideoService.SetMemberRelationshipFromLiveVideo(act);
|
|||
|
}
|
|||
|
#endregion
|
|||
|
|
|||
|
#region SetMemberRelationship(存储登录后自己进入直播间的会员关系链的方法)
|
|||
|
/// <summary>
|
|||
|
/// 存储登录后自己进入直播间的会员关系链的方法
|
|||
|
/// </summary>
|
|||
|
[HttpGet]
|
|||
|
public void SetMemberRelationship()
|
|||
|
{
|
|||
|
_liveVideoService.SetMemberRelationshipFromLiveVideo(this.CurrentLogin);
|
|||
|
}
|
|||
|
#endregion
|
|||
|
}
|
|||
|
}
|