添加excel模块
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
<?xml version="1.0"?>
|
||||
<doc>
|
||||
<assembly>
|
||||
<name>Yi.Framework.Application</name>
|
||||
</assembly>
|
||||
<members>
|
||||
<member name="T:Yi.Framework.Application.Student.StudentService">
|
||||
<summary>
|
||||
服务实现
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Yi.Framework.Application.Student.StudentService.PostShijie">
|
||||
<summary>
|
||||
你好世界
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
</members>
|
||||
</doc>
|
||||
@@ -0,0 +1,23 @@
|
||||
using AutoMapper;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Yi.Framework.Application.Contracts.Student.Dtos;
|
||||
using Yi.Framework.Domain.Student.Entities;
|
||||
|
||||
namespace Yi.Framework.Application.Student.MapperConfig
|
||||
{
|
||||
public class StudentProfile: Profile
|
||||
{
|
||||
public StudentProfile()
|
||||
{
|
||||
CreateMap<StudentGetListInputVo, StudentEntity>();
|
||||
CreateMap<StudentCreateInputVo, StudentEntity>();
|
||||
CreateMap<StudentUpdateInputVo, StudentEntity>();
|
||||
CreateMap<StudentEntity, StudentGetListOutputDto>();
|
||||
CreateMap<StudentEntity, StudentGetOutputDto>();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
using System;
|
||||
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;
|
||||
using Yi.Framework.Domain.Student.IRepository;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using NET.AutoWebApi.Setting;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Yi.Framework.Ddd.Services.Abstract;
|
||||
using Yi.Framework.Application.Contracts.Student.Dtos;
|
||||
using Yi.Framework.Domain.Student.Entities;
|
||||
using Yi.Framework.Ddd.Services;
|
||||
|
||||
namespace Yi.Framework.Application.Student
|
||||
{
|
||||
/// <summary>
|
||||
/// 服务实现
|
||||
/// </summary>
|
||||
public class StudentService : CrudAppService<StudentEntity, StudentGetOutputDto, StudentGetListOutputDto, long, StudentGetListInputVo, StudentCreateInputVo, StudentUpdateInputVo>,
|
||||
IStudentService, IAutoApiService
|
||||
{
|
||||
private readonly IStudentRepository _studentRepository;
|
||||
private readonly StudentManager _studentManager;
|
||||
public StudentService(IStudentRepository studentRepository, StudentManager studentManager)
|
||||
{
|
||||
_studentRepository = studentRepository;
|
||||
_studentManager = studentManager;
|
||||
}
|
||||
/// <summary>
|
||||
/// 你好世界
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public async Task<List<StudentGetListOutputDto>> PostShijie()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
var entities = await _studentRepository.GetMyListAsync();
|
||||
return await MapToGetListOutputDtosAsync(entities);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<GenerateDocumentationFile>True</GenerateDocumentationFile>
|
||||
<DocumentationFile>./ApplicationSwaggerDoc.xml</DocumentationFile>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Yi.Framework.Application.Contracts\Yi.Framework.Application.Contracts.csproj" />
|
||||
<ProjectReference Include="..\Yi.Framework.Domain\Yi.Framework.Domain.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
@@ -0,0 +1,26 @@
|
||||
using Microsoft.AspNetCore.Builder;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using StartupModules;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Yi.Framework.Application.Contracts.Student;
|
||||
using Yi.Framework.Application.Student;
|
||||
|
||||
namespace Yi.Framework.Application
|
||||
{
|
||||
public class YiFrameworkApplicationModule : IStartupModule
|
||||
{
|
||||
public void Configure(IApplicationBuilder app, ConfigureMiddlewareContext context)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public void ConfigureServices(IServiceCollection services, ConfigureServicesContext context)
|
||||
{
|
||||
services.AddTransient<IStudentService, StudentService>();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user