using Furion.DynamicApiController;
using Microsoft.AspNetCore.Mvc;
using Nirvana.Common;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Waste.Application.ResultInfos
{
    /// <summary>
    /// 投放记录
    /// </summary>
    public class ResultAppService:IDynamicApiController
    {
        private readonly IResultService _resultService;
        public ResultAppService(IResultService resultService)
        {
            _resultService = resultService;
        }
        /// <summary>
        /// 投放记录列表
        /// </summary>
        /// <param name="param"></param>
        /// <returns></returns>
        [HttpPost]
        public async Task<PageParms<ResultList>> GetListAsync(QueryParams param)
        {
            return await _resultService.GetListAsync(param);
        }
        /// <summary>
        /// 添加记录
        /// </summary>
        /// <param name="myPackage"></param>
        /// <returns></returns>
        public async Task<ResultInfo> InsertResultAsync(MyPackage myPackage)
        {
            return await _resultService.InsertResultAsync(myPackage);
        }
    }
}
