1
This commit is contained in:
21
iMES.WebApi/Controllers/Calendar/Cal_HolidayController.cs
Normal file
21
iMES.WebApi/Controllers/Calendar/Cal_HolidayController.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
*代码由框架生成,任何更改都可能导致被代码生成器覆盖
|
||||
*如果要增加方法请在当前目录下Partial文件夹Cal_HolidayController编写
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using iMES.Core.Controllers.Basic;
|
||||
using iMES.Entity.AttributeManager;
|
||||
using iMES.Calendar.IServices;
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
[Route("api/Cal_Holiday")]
|
||||
[PermissionTable(Name = "Cal_Holiday")]
|
||||
public partial class Cal_HolidayController : ApiBaseController<ICal_HolidayService>
|
||||
{
|
||||
public Cal_HolidayController(ICal_HolidayService service)
|
||||
: base(service)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
21
iMES.WebApi/Controllers/Calendar/Cal_PlanController.cs
Normal file
21
iMES.WebApi/Controllers/Calendar/Cal_PlanController.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
*代码由框架生成,任何更改都可能导致被代码生成器覆盖
|
||||
*如果要增加方法请在当前目录下Partial文件夹Cal_PlanController编写
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using iMES.Core.Controllers.Basic;
|
||||
using iMES.Entity.AttributeManager;
|
||||
using iMES.Calendar.IServices;
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
[Route("api/Cal_Plan")]
|
||||
[PermissionTable(Name = "Cal_Plan")]
|
||||
public partial class Cal_PlanController : ApiBaseController<ICal_PlanService>
|
||||
{
|
||||
public Cal_PlanController(ICal_PlanService service)
|
||||
: base(service)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
21
iMES.WebApi/Controllers/Calendar/Cal_PlanShiftController.cs
Normal file
21
iMES.WebApi/Controllers/Calendar/Cal_PlanShiftController.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
*代码由框架生成,任何更改都可能导致被代码生成器覆盖
|
||||
*如果要增加方法请在当前目录下Partial文件夹Cal_PlanShiftController编写
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using iMES.Core.Controllers.Basic;
|
||||
using iMES.Entity.AttributeManager;
|
||||
using iMES.Calendar.IServices;
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
[Route("api/Cal_PlanShift")]
|
||||
[PermissionTable(Name = "Cal_PlanShift")]
|
||||
public partial class Cal_PlanShiftController : ApiBaseController<ICal_PlanShiftService>
|
||||
{
|
||||
public Cal_PlanShiftController(ICal_PlanShiftService service)
|
||||
: base(service)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
21
iMES.WebApi/Controllers/Calendar/Cal_PlanTeamController.cs
Normal file
21
iMES.WebApi/Controllers/Calendar/Cal_PlanTeamController.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
*代码由框架生成,任何更改都可能导致被代码生成器覆盖
|
||||
*如果要增加方法请在当前目录下Partial文件夹Cal_PlanTeamController编写
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using iMES.Core.Controllers.Basic;
|
||||
using iMES.Entity.AttributeManager;
|
||||
using iMES.Calendar.IServices;
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
[Route("api/Cal_PlanTeam")]
|
||||
[PermissionTable(Name = "Cal_PlanTeam")]
|
||||
public partial class Cal_PlanTeamController : ApiBaseController<ICal_PlanTeamService>
|
||||
{
|
||||
public Cal_PlanTeamController(ICal_PlanTeamService service)
|
||||
: base(service)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
21
iMES.WebApi/Controllers/Calendar/Cal_TeamController.cs
Normal file
21
iMES.WebApi/Controllers/Calendar/Cal_TeamController.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
*代码由框架生成,任何更改都可能导致被代码生成器覆盖
|
||||
*如果要增加方法请在当前目录下Partial文件夹Cal_TeamController编写
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using iMES.Core.Controllers.Basic;
|
||||
using iMES.Entity.AttributeManager;
|
||||
using iMES.Calendar.IServices;
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
[Route("api/Cal_Team")]
|
||||
[PermissionTable(Name = "Cal_Team")]
|
||||
public partial class Cal_TeamController : ApiBaseController<ICal_TeamService>
|
||||
{
|
||||
public Cal_TeamController(ICal_TeamService service)
|
||||
: base(service)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
21
iMES.WebApi/Controllers/Calendar/Cal_TeamMemberController.cs
Normal file
21
iMES.WebApi/Controllers/Calendar/Cal_TeamMemberController.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
*代码由框架生成,任何更改都可能导致被代码生成器覆盖
|
||||
*如果要增加方法请在当前目录下Partial文件夹Cal_TeamMemberController编写
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using iMES.Core.Controllers.Basic;
|
||||
using iMES.Entity.AttributeManager;
|
||||
using iMES.Calendar.IServices;
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
[Route("api/Cal_TeamMember")]
|
||||
[PermissionTable(Name = "Cal_TeamMember")]
|
||||
public partial class Cal_TeamMemberController : ApiBaseController<ICal_TeamMemberService>
|
||||
{
|
||||
public Cal_TeamMemberController(ICal_TeamMemberService service)
|
||||
: base(service)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
21
iMES.WebApi/Controllers/Calendar/Cal_TeamShiftController.cs
Normal file
21
iMES.WebApi/Controllers/Calendar/Cal_TeamShiftController.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
*代码由框架生成,任何更改都可能导致被代码生成器覆盖
|
||||
*如果要增加方法请在当前目录下Partial文件夹Cal_TeamShiftController编写
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using iMES.Core.Controllers.Basic;
|
||||
using iMES.Entity.AttributeManager;
|
||||
using iMES.Calendar.IServices;
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
[Route("api/Cal_TeamShift")]
|
||||
[PermissionTable(Name = "Cal_TeamShift")]
|
||||
public partial class Cal_TeamShiftController : ApiBaseController<ICal_TeamShiftService>
|
||||
{
|
||||
public Cal_TeamShiftController(ICal_TeamShiftService service)
|
||||
: base(service)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
/*
|
||||
*接口编写处...
|
||||
*如果接口需要做Action的权限验证,请在Action上使用属性
|
||||
*如: [ApiActionPermission("Cal_Holiday",Enums.ActionPermissionOptions.Search)]
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using iMES.Entity.DomainModels;
|
||||
using iMES.Calendar.IServices;
|
||||
using iMES.Core.DBManager;
|
||||
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
public partial class Cal_HolidayController
|
||||
{
|
||||
private readonly ICal_HolidayService _service;//访问业务代码
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public Cal_HolidayController(
|
||||
ICal_HolidayService service,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(service)
|
||||
{
|
||||
_service = service;
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,56 @@
|
||||
/*
|
||||
*接口编写处...
|
||||
*如果接口需要做Action的权限验证,请在Action上使用属性
|
||||
*如: [ApiActionPermission("Cal_Plan",Enums.ActionPermissionOptions.Search)]
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using iMES.Entity.DomainModels;
|
||||
using iMES.Calendar.IServices;
|
||||
using iMES.Core.Filters;
|
||||
using iMES.Core.Enums;
|
||||
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
public partial class Cal_PlanController
|
||||
{
|
||||
private readonly ICal_PlanService _service;//访问业务代码
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public Cal_PlanController(
|
||||
ICal_PlanService service,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(service)
|
||||
{
|
||||
_service = service;
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
}
|
||||
/// <summary>
|
||||
/// 获取table1的数据
|
||||
/// </summary>
|
||||
/// <param name="loadData"></param>
|
||||
/// <returns></returns>
|
||||
[Route("getTable1Data"), HttpPost, ApiActionPermission("Cal_Plan", ActionPermissionOptions.Search)]
|
||||
public async Task<IActionResult> GetTable1Data([FromBody] PageDataOptions loadData)
|
||||
{
|
||||
return JsonNormal(await Service.GetTable1Data(loadData));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取table1的数据
|
||||
/// </summary>
|
||||
/// <param name="loadData"></param>
|
||||
/// <returns></returns>
|
||||
[Route("getTable2Data"), HttpPost, ApiActionPermission("Cal_Plan", ActionPermissionOptions.Search)]
|
||||
public async Task<IActionResult> GetTable2Data([FromBody] PageDataOptions loadData)
|
||||
{
|
||||
return JsonNormal(await Service.GetTable2Data(loadData));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
*接口编写处...
|
||||
*如果接口需要做Action的权限验证,请在Action上使用属性
|
||||
*如: [ApiActionPermission("Cal_PlanShift",Enums.ActionPermissionOptions.Search)]
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using iMES.Entity.DomainModels;
|
||||
using iMES.Calendar.IServices;
|
||||
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
public partial class Cal_PlanShiftController
|
||||
{
|
||||
private readonly ICal_PlanShiftService _service;//访问业务代码
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public Cal_PlanShiftController(
|
||||
ICal_PlanShiftService service,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(service)
|
||||
{
|
||||
_service = service;
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
*接口编写处...
|
||||
*如果接口需要做Action的权限验证,请在Action上使用属性
|
||||
*如: [ApiActionPermission("Cal_PlanTeam",Enums.ActionPermissionOptions.Search)]
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using iMES.Entity.DomainModels;
|
||||
using iMES.Calendar.IServices;
|
||||
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
public partial class Cal_PlanTeamController
|
||||
{
|
||||
private readonly ICal_PlanTeamService _service;//访问业务代码
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public Cal_PlanTeamController(
|
||||
ICal_PlanTeamService service,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(service)
|
||||
{
|
||||
_service = service;
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,58 @@
|
||||
/*
|
||||
*接口编写处...
|
||||
*如果接口需要做Action的权限验证,请在Action上使用属性
|
||||
*如: [ApiActionPermission("Cal_Team",Enums.ActionPermissionOptions.Search)]
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using iMES.Entity.DomainModels;
|
||||
using iMES.Calendar.IServices;
|
||||
using iMES.Calendar.IRepositories;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using iMES.Calendar.Services;
|
||||
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
public partial class Cal_TeamController
|
||||
{
|
||||
private readonly ICal_TeamService _service;//访问业务代码
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
private readonly ICal_TeamMemberRepository _teamMemberRepository;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public Cal_TeamController(
|
||||
ICal_TeamService service,
|
||||
IHttpContextAccessor httpContextAccessor,
|
||||
ICal_TeamMemberRepository teamMemberRepository
|
||||
)
|
||||
: base(service)
|
||||
{
|
||||
_service = service;
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
_teamMemberRepository = teamMemberRepository;
|
||||
}
|
||||
/// <summary>
|
||||
/// 获取班组下面的班组成员
|
||||
/// </summary>
|
||||
/// <param name="TeamId">班组主键</param>
|
||||
/// <returns></returns>
|
||||
[Route("getDetailRows"), HttpGet]
|
||||
public async Task<IActionResult> GetDetailRows(string TeamId)
|
||||
{
|
||||
var rows = await _teamMemberRepository.FindAsIQueryable(x => x.TeamId == new Guid(TeamId))
|
||||
.ToListAsync();
|
||||
return JsonNormal(rows);
|
||||
}
|
||||
[HttpPost, Route("getSelectorTeam")]
|
||||
public IActionResult getSelectorTeam([FromBody] PageDataOptions options)
|
||||
{
|
||||
//1.可以直接调用框架的GetPageData查询
|
||||
PageGridData<Cal_Team> data = Cal_TeamService.Instance.GetPageData(options);
|
||||
return JsonNormal(data);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
*接口编写处...
|
||||
*如果接口需要做Action的权限验证,请在Action上使用属性
|
||||
*如: [ApiActionPermission("Cal_TeamMember",Enums.ActionPermissionOptions.Search)]
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using iMES.Entity.DomainModels;
|
||||
using iMES.Calendar.IServices;
|
||||
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
public partial class Cal_TeamMemberController
|
||||
{
|
||||
private readonly ICal_TeamMemberService _service;//访问业务代码
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public Cal_TeamMemberController(
|
||||
ICal_TeamMemberService service,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(service)
|
||||
{
|
||||
_service = service;
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
*接口编写处...
|
||||
*如果接口需要做Action的权限验证,请在Action上使用属性
|
||||
*如: [ApiActionPermission("Cal_TeamShift",Enums.ActionPermissionOptions.Search)]
|
||||
*/
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using iMES.Entity.DomainModels;
|
||||
using iMES.Calendar.IServices;
|
||||
|
||||
namespace iMES.Calendar.Controllers
|
||||
{
|
||||
public partial class Cal_TeamShiftController
|
||||
{
|
||||
private readonly ICal_TeamShiftService _service;//访问业务代码
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public Cal_TeamShiftController(
|
||||
ICal_TeamShiftService service,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(service)
|
||||
{
|
||||
_service = service;
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user