38 lines
1.1 KiB
C#
38 lines
1.1 KiB
C#
using JNPF.Common.Core.Manager;
|
|
using JNPF.DependencyInjection;
|
|
using JNPF.DynamicApiController;
|
|
using JNPF.VisualDev.Interfaces;
|
|
using Microsoft.AspNetCore.Mvc;
|
|
using SqlSugar;
|
|
using Tnb.BasicData.Entities;
|
|
using Tnb.BasicData.Interfaces;
|
|
|
|
namespace Tnb.BasicData
|
|
{
|
|
/// <summary>
|
|
/// 推送记录服务
|
|
/// </summary>
|
|
[ApiDescriptionSettings(Tag = ModuleConst.Tag, Area = ModuleConst.Area, Order = 1102)]
|
|
[Route("api/[area]/[controller]/[action]")]
|
|
public class BasPushRuleLogService : IBasPushRuleLogService, IDynamicApiController, ITransient
|
|
{
|
|
private readonly ISqlSugarRepository<BasPushRuleLog> _repository;
|
|
|
|
public BasPushRuleLogService(
|
|
ISqlSugarRepository<BasPushRuleLog> repository)
|
|
{
|
|
_repository = repository;
|
|
}
|
|
|
|
[HttpPost]
|
|
public async Task<dynamic> Stop(Dictionary<string, string> dic)
|
|
{
|
|
string id = dic["id"];
|
|
await _repository.UpdateAsync(x => new BasPushRuleLog()
|
|
{
|
|
is_push = 0,
|
|
}, x => x.biz_id == id);
|
|
return true;
|
|
}
|
|
}
|
|
} |