using Microsoft.AspNetCore.Mvc;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.CompilerServices;
using System.Text;
using System.Threading.Tasks;
using XF.Domain.Repository;

namespace Hotline.Settings;
public interface ISystemLogRepository : IRepository<SystemLog>
{
    /// <summary>
    /// 添加操作日志
    /// </summary>
    /// <param name="name">方法</param>
    /// <param name="executeParam">入参</param>
    /// <param name="executeUrl">地址</param>
    /// <param name="remark">备注</param>
    /// <param name="status">状态(0失败 1成功)</param>
    /// <returns></returns>
    void Add(string name, string executeParam = "", string remark = "", [CallerMemberName]string executeUrl = "", int status = 0, string ipUrl = "", string executeResult = "");

    void Add(string name, object executeParam = null, string remark = "", [CallerMemberName]string executeUrl = "", int status = 0, string ipUrl = "", string executeResult = "");

    Task UpdateResultAsync(string id, ObjectResult result);

    Task AddAsyncNoException(SystemLog entity);
}
