2023-01-14 18:16:16 +08:00
|
|
|
|
using System;
|
2023-01-12 14:58:16 +08:00
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using System.Linq;
|
|
|
|
|
|
using System.Text;
|
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
using Yi.Framework.Application.Contracts.Student;
|
|
|
|
|
|
using Yi.Framework.Domain.Student;
|
2023-01-12 15:25:46 +08:00
|
|
|
|
using Yi.Framework.Domain.Student.IRepository;
|
2023-01-14 18:16:16 +08:00
|
|
|
|
using Microsoft.AspNetCore.Mvc;
|
|
|
|
|
|
using NET.AutoWebApi.Setting;
|
|
|
|
|
|
using Microsoft.AspNetCore.Http;
|
2023-01-15 14:32:43 +08:00
|
|
|
|
using Yi.Framework.Ddd.Services.Abstract;
|
|
|
|
|
|
using Yi.Framework.Application.Contracts.Student.Dtos;
|
|
|
|
|
|
using Yi.Framework.Domain.Student.Entities;
|
|
|
|
|
|
using Yi.Framework.Ddd.Services;
|
2023-01-17 22:47:15 +08:00
|
|
|
|
using Yi.Framework.Core.Attributes;
|
2023-01-12 14:58:16 +08:00
|
|
|
|
|
|
|
|
|
|
namespace Yi.Framework.Application.Student
|
|
|
|
|
|
{
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// 服务实现
|
|
|
|
|
|
/// </summary>
|
2023-01-17 22:47:15 +08:00
|
|
|
|
|
|
|
|
|
|
[AppService]
|
2023-01-15 14:32:43 +08:00
|
|
|
|
public class StudentService : CrudAppService<StudentEntity, StudentGetOutputDto, StudentGetListOutputDto, long, StudentGetListInputVo, StudentCreateInputVo, StudentUpdateInputVo>,
|
2023-01-17 22:47:15 +08:00
|
|
|
|
IStudentService,IAutoApiService
|
2023-01-12 14:58:16 +08:00
|
|
|
|
{
|
|
|
|
|
|
private readonly IStudentRepository _studentRepository;
|
|
|
|
|
|
private readonly StudentManager _studentManager;
|
2023-01-15 14:32:43 +08:00
|
|
|
|
public StudentService(IStudentRepository studentRepository, StudentManager studentManager)
|
2023-01-12 14:58:16 +08:00
|
|
|
|
{
|
|
|
|
|
|
_studentRepository = studentRepository;
|
|
|
|
|
|
_studentManager = studentManager;
|
|
|
|
|
|
}
|
2023-01-14 18:46:34 +08:00
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// 你好世界
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
/// <returns></returns>
|
2023-01-15 14:32:43 +08:00
|
|
|
|
public async Task<List<StudentGetListOutputDto>> PostShijie()
|
2023-01-12 14:58:16 +08:00
|
|
|
|
{
|
2023-01-16 23:05:01 +08:00
|
|
|
|
throw new NotImplementedException();
|
2023-01-15 14:32:43 +08:00
|
|
|
|
var entities = await _studentRepository.GetMyListAsync();
|
|
|
|
|
|
return await MapToGetListOutputDtosAsync(entities);
|
2023-01-12 14:58:16 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|