Compare commits
11 Commits
e463b91801
...
e91ff54207
| Author | SHA1 | Date | |
|---|---|---|---|
| e91ff54207 | |||
| e8fb79e36a | |||
|
|
1b885cc350 | ||
|
|
dedf55aca4 | ||
|
|
d2996857b1 | ||
|
|
ed801de814 | ||
|
|
fb38a956bd | ||
|
|
e29e4db0db | ||
|
|
b33fce844f | ||
|
|
baf1bae943 | ||
| 5907f586ce |
5
.gitignore
vendored
5
.gitignore
vendored
@@ -2,7 +2,7 @@
|
||||
## Ignore Visual Studio temporary files, build results, and
|
||||
## files generated by popular Visual Studio add-ons.
|
||||
##
|
||||
## Get latest from https://github.com/github/gitignore/blob/main/VisualStudio.gitignore
|
||||
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
|
||||
|
||||
# User-specific files
|
||||
*.rsuser
|
||||
@@ -146,9 +146,6 @@ _TeamCity*
|
||||
!.axoCover/settings.json
|
||||
|
||||
# Coverlet is a free, cross platform Code Coverage Tool
|
||||
coverage*.json
|
||||
coverage*.xml
|
||||
coverage*.info
|
||||
|
||||
# Visual Studio code coverage results
|
||||
*.coverage
|
||||
|
||||
16
api_v1/.gitignore
vendored
Normal file
16
api_v1/.gitignore
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
################################################################################
|
||||
# 此 .gitignore 文件已由 Microsoft(R) Visual Studio 自动创建。
|
||||
################################################################################
|
||||
/Appointment.Api/.vs
|
||||
/Appointment.Api/.vs/Appointment.Api
|
||||
/Appointment.Api/Appointment.Api/bin
|
||||
/Appointment.Api/Appointment.Api/log
|
||||
/Appointment.Api/Appointment.Api/obj
|
||||
/Appointment.Entity/bin
|
||||
/Appointment.Entity/obj
|
||||
/Appointment.IRepository/bin
|
||||
/Appointment.IRepository/obj
|
||||
/Appointment.Repository/bin
|
||||
/Appointment.Repository/obj
|
||||
/Appointment.Api/Appointment.Api/.config
|
||||
/.vs/Dee.OA
|
||||
43
api_v1/Appointment.Api/Appointment.Api.sln
Normal file
43
api_v1/Appointment.Api/Appointment.Api.sln
Normal file
@@ -0,0 +1,43 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 16
|
||||
VisualStudioVersion = 16.0.30711.63
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Appointment.Api", "Appointment.Api\Appointment.Api.csproj", "{D8C00CB0-D314-4D84-B865-ED50E8BBFB0F}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Appointment.Repository", "..\Appointment.Repository\Appointment.Repository.csproj", "{3F67A123-9CD3-41E3-AF2A-C5EA2DC6B63D}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Appointment.IRepository", "..\Appointment.IRepository\Appointment.IRepository.csproj", "{60B857A7-3AB0-4A5A-8271-FD0775F0A40A}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Appointment.Entity", "..\Appointment.Entity\Appointment.Entity.csproj", "{AB7CA6F6-403E-4E1F-B688-F581D66F4CC4}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Release|Any CPU = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{D8C00CB0-D314-4D84-B865-ED50E8BBFB0F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{D8C00CB0-D314-4D84-B865-ED50E8BBFB0F}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{D8C00CB0-D314-4D84-B865-ED50E8BBFB0F}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{D8C00CB0-D314-4D84-B865-ED50E8BBFB0F}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{3F67A123-9CD3-41E3-AF2A-C5EA2DC6B63D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{3F67A123-9CD3-41E3-AF2A-C5EA2DC6B63D}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{3F67A123-9CD3-41E3-AF2A-C5EA2DC6B63D}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{3F67A123-9CD3-41E3-AF2A-C5EA2DC6B63D}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{60B857A7-3AB0-4A5A-8271-FD0775F0A40A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{60B857A7-3AB0-4A5A-8271-FD0775F0A40A}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{60B857A7-3AB0-4A5A-8271-FD0775F0A40A}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{60B857A7-3AB0-4A5A-8271-FD0775F0A40A}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{AB7CA6F6-403E-4E1F-B688-F581D66F4CC4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{AB7CA6F6-403E-4E1F-B688-F581D66F4CC4}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{AB7CA6F6-403E-4E1F-B688-F581D66F4CC4}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{AB7CA6F6-403E-4E1F-B688-F581D66F4CC4}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {491C2436-66E3-43C6-817A-F1E718C28A3B}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
@@ -0,0 +1,39 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp3.1</TargetFramework>
|
||||
<UserSecretsId>6dceff68-1c1d-4ab3-9e5c-af79745ae1a1</UserSecretsId>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
|
||||
<NoWarn>1701;1702;1591</NoWarn>
|
||||
<DocumentationFile>Appointment.Api.xml</DocumentationFile>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Log4NetCore" Version="1.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.Logging.Log4Net.AspNetCore" Version="3.1.0" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore" Version="5.6.3" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore.Annotations" Version="5.6.3" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\Appointment.Entity\Appointment.Entity.csproj" />
|
||||
<ProjectReference Include="..\..\Appointment.IRepository\Appointment.IRepository.csproj" />
|
||||
<ProjectReference Include="..\..\Appointment.Repository\Appointment.Repository.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Content Update="log4net.Config">
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Update="Appointment.Api.xml">
|
||||
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
</Project>
|
||||
367
api_v1/Appointment.Api/Appointment.Api/Appointment.Api.xml
Normal file
367
api_v1/Appointment.Api/Appointment.Api/Appointment.Api.xml
Normal file
@@ -0,0 +1,367 @@
|
||||
<?xml version="1.0"?>
|
||||
<doc>
|
||||
<assembly>
|
||||
<name>Appointment.Api</name>
|
||||
</assembly>
|
||||
<members>
|
||||
<member name="T:Appointment.Api.Controllers.ApptAuditorController">
|
||||
<summary>
|
||||
预订审核节点接口
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptAuditorController.GroupList">
|
||||
<summary>
|
||||
获取所有组别
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptAuditorController.Add(Appointment.Entity.ApptAuditor)">
|
||||
<summary>
|
||||
审核流程 添加节点
|
||||
</summary>
|
||||
<param name="req">
|
||||
apptTypeId:审核类型;
|
||||
opGroup:角色代码;
|
||||
opDescript:角色名称;
|
||||
pid:前阶段审核主键,第一级审核填0;
|
||||
</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptAuditorController.Delete(Appointment.Entity.ApptAuditor)">
|
||||
<summary>
|
||||
核流程 删除
|
||||
</summary>
|
||||
<param name="req">
|
||||
id:要删除的节点;有子节点时不允许删除
|
||||
</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptAuditorController.GetModel(Appointment.Entity.ApptAuditor)">
|
||||
<summary>
|
||||
根据主键获取实体
|
||||
</summary>
|
||||
<param name="req">
|
||||
id:主键;
|
||||
</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptAuditorController.GetList(Appointment.Entity.ApptAuditor)">
|
||||
<summary>
|
||||
预订审核 审核列表
|
||||
</summary>
|
||||
<param name="req">
|
||||
id:大于0-指定主键;
|
||||
apptTypeId:大于0-指定审核类型;
|
||||
opGroup:不为空-指定组别代码;
|
||||
opDescript:不为空-指定组别名称;
|
||||
</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptAuditorController.Page(Appointment.Entity.CommPageReq)">
|
||||
<summary>
|
||||
预订审核 分页
|
||||
</summary>
|
||||
<param name="req">
|
||||
Keywords:角色名称模糊查询
|
||||
</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptAuditorController.AuditorLine(Appointment.Entity.ApptAuditor)">
|
||||
<summary>
|
||||
获取预订审核线状结构
|
||||
</summary>
|
||||
<param name="req">
|
||||
apptTypeId:审核类型;
|
||||
</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="T:Appointment.Api.Controllers.ApptController">
|
||||
<summary>
|
||||
预订接口
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.UsableMeeting(Appointment.Entity.MeetingReq)">
|
||||
<summary>
|
||||
根据时间段获取可使用的会议厅资源
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.UsableMeetingByDay(Appointment.Entity.UsableMeetingReq)">
|
||||
<summary>
|
||||
根据日期与场次获取可使用会议厅资源
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.UsableRoom(Appointment.Entity.UsableRoomReq)">
|
||||
<summary>
|
||||
获取可使用的房间资源
|
||||
</summary>
|
||||
<param name="req">启始时间(默认从昨天开始)</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.UsableRoomMin(Appointment.Entity.UsableRoomReq)">
|
||||
<summary>
|
||||
根据时间段获取房类最小可用数
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.RemarkList">
|
||||
<summary>
|
||||
获取备注列表项
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.Add(Appointment.Entity.ApptSummaryReq)">
|
||||
<summary>
|
||||
预订提交
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.ApptAudit(Appointment.Entity.ApptAuditReq)">
|
||||
<summary>
|
||||
预订审核
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.TransferAudit(Appointment.Entity.TransferAuditReq)">
|
||||
<summary>
|
||||
转审批
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.ApptSend(Appointment.Entity.ApptSendReq)">
|
||||
<summary>
|
||||
抄送
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.GetModel(Appointment.Entity.ApptSummaryReq)">
|
||||
<summary>
|
||||
根据主键获取实体
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.MyApptApplyPageReq(Appointment.Entity.MyApptApplyPageReq)">
|
||||
<summary>
|
||||
我发起的预订列表列表
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.MyPartakePage(Appointment.Entity.MyApptAuditPageReq)">
|
||||
<summary>
|
||||
获取我待审核的
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.AuditorLogTree(Appointment.Entity.CommIntReq)">
|
||||
<summary>
|
||||
获取预订审核记录表
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptController.Demo(Appointment.Entity.CommPageReq)">
|
||||
<summary>
|
||||
测试
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.AddSummary(Appointment.Entity.AddSummaryJncReq)">
|
||||
<summary>
|
||||
创建新的预订单
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.UpdateSummary(Appointment.Entity.UpdateSummaryReq)">
|
||||
<summary>
|
||||
修改暂订单
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.ApplyOrder(Appointment.Entity.ApplyOrderReq)">
|
||||
<summary>
|
||||
申请确定单
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.Cancel(Appointment.Entity.ApplyOrderReq)">
|
||||
<summary>
|
||||
取消OA单
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.AuditorSummary(Appointment.Entity.ApplyOrderReq)">
|
||||
<summary>
|
||||
确定单后续审批
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.RejectSummary(Appointment.Entity.ApplyOrderReq)">
|
||||
<summary>
|
||||
被驳回
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.ManualCopy(Appointment.Entity.ApptSendReq)">
|
||||
<summary>
|
||||
手动抄送
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.AddReply(Appointment.Entity.AddMsgReq)">
|
||||
<summary>
|
||||
信息回复
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.GetModel(Appointment.Entity.SummaryJncModelReq)">
|
||||
<summary>
|
||||
根据主键获取实体
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.SummaryPager(Appointment.Entity.SummaryJNCPageReq)">
|
||||
<summary>
|
||||
分页预订列表
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.AuditorLogTree(Appointment.Entity.SummaryJncModelReq)">
|
||||
<summary>
|
||||
获取审批流程
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.Disparity(Appointment.Entity.SummaryJncModelReq)">
|
||||
<summary>
|
||||
订单数据差距
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptJNCController.GetReplyPicList(Appointment.Entity.SummaryJncModelReq)">
|
||||
<summary>
|
||||
返回回复中的图片列表
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="T:Appointment.Api.Controllers.ApptTypeController">
|
||||
<summary>
|
||||
预订类型接口
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptTypeController.Add(Appointment.Entity.ApptTypeAddReq)">
|
||||
<summary>
|
||||
预订类型 添加
|
||||
</summary>
|
||||
<param name="req">status不填写</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptTypeController.Delete(Appointment.Entity.ApptType)">
|
||||
<summary>
|
||||
预订类型 删除
|
||||
</summary>
|
||||
<param name="req">根据id删除一条数据</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptTypeController.Update(Appointment.Entity.ApptType)">
|
||||
<summary>
|
||||
预订类型更新
|
||||
</summary>
|
||||
<param name="req">根据id更新ApptName、Remark</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptTypeController.GetModel(Appointment.Entity.ApptType)">
|
||||
<summary>
|
||||
预订类型获取实体
|
||||
</summary>
|
||||
<param name="req">根据id获取实体</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptTypeController.GetList(Appointment.Entity.ApptType)">
|
||||
<summary>
|
||||
预订类型列表
|
||||
</summary>
|
||||
<param name="req">
|
||||
Id:0-忽略,其他-指定;
|
||||
ApptName:根据类型名称模糊查询;
|
||||
</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.ApptTypeController.Page(Appointment.Entity.CommPageReq)">
|
||||
<summary>
|
||||
预订类型分页
|
||||
</summary>
|
||||
<param name="req">
|
||||
Keywords-根据类型名称模糊查询;
|
||||
</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="T:Appointment.Api.Controllers.UserController">
|
||||
<summary>
|
||||
登录接口
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.UserController.UserNameLogin(Appointment.Entity.UserLoginAccountReq)">
|
||||
<summary>
|
||||
管理人员 微信小程序授权登录
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.UserController.WxLogin(Appointment.Entity.UserLoginCodeReq)">
|
||||
<summary>
|
||||
管理人员微信小程序登录
|
||||
</summary>
|
||||
<param name="req">wx.login下的code</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.UserController.WxServiceSet(Appointment.Entity.WxServiceSetRes)">
|
||||
<summary>
|
||||
绑定微信服务号OpenId
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.UserController.GetUserAll(Appointment.Entity.BindUserReq)">
|
||||
<summary>
|
||||
获取所有用户
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.Controllers.UserController.GetBindUser(Appointment.Entity.BindUserReq)">
|
||||
<summary>
|
||||
获取已绑定小程序与公众号的用户列表(不包含本用户)
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.Api.SwaggerSetUp.AddSwaggerSetup(Microsoft.Extensions.DependencyInjection.IServiceCollection)">
|
||||
<summary>
|
||||
注册Swagger服务
|
||||
</summary>
|
||||
<param name="services"></param>
|
||||
</member>
|
||||
</members>
|
||||
</doc>
|
||||
@@ -0,0 +1,127 @@
|
||||
using Appointment.Entity;
|
||||
using Appointment.IRepository;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Appointment.Api.Controllers
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订审核节点接口
|
||||
/// </summary>
|
||||
[Route("api/[controller]")]
|
||||
[ApiController]
|
||||
public class ApptAuditorController : ControllerBase
|
||||
{
|
||||
IApptAuditorRepo _ApptAuditorRepo;
|
||||
IManagerGroup _ManagerGroup;
|
||||
public ApptAuditorController(IApptAuditorRepo apptAuditorRepo, IManagerGroup managerGroup)
|
||||
{
|
||||
_ApptAuditorRepo = apptAuditorRepo;
|
||||
_ManagerGroup = managerGroup;
|
||||
}
|
||||
|
||||
// ---- 组别
|
||||
|
||||
/// <summary>
|
||||
/// 获取所有组别
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[Route("GroupList")]
|
||||
[HttpPost]
|
||||
public ApiResult<List<UcGroup>> GroupList()
|
||||
{
|
||||
return _ManagerGroup.GetAll();
|
||||
}
|
||||
|
||||
// ---- 审核流程管理
|
||||
|
||||
/// <summary>
|
||||
/// 审核流程 添加节点
|
||||
/// </summary>
|
||||
/// <param name="req">
|
||||
/// apptTypeId:审核类型;
|
||||
/// opGroup:角色代码;
|
||||
/// opDescript:角色名称;
|
||||
/// pid:前阶段审核主键,第一级审核填0;
|
||||
/// </param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("Add")]
|
||||
public ApiResult<ApptAuditor> Add(ApptAuditor req)
|
||||
{
|
||||
return _ApptAuditorRepo.Add(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 核流程 删除
|
||||
/// </summary>
|
||||
/// <param name="req">
|
||||
/// id:要删除的节点;有子节点时不允许删除
|
||||
/// </param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("Delete")]
|
||||
public ApiResult Delete(ApptAuditor req)
|
||||
{
|
||||
return _ApptAuditorRepo.Delete(req.Id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键获取实体
|
||||
/// </summary>
|
||||
/// <param name="req">
|
||||
/// id:主键;
|
||||
/// </param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("GetModel")]
|
||||
public ApiResult<ApptAuditor> GetModel(ApptAuditor req)
|
||||
{
|
||||
return _ApptAuditorRepo.GetModel(req.Id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 预订审核 审核列表
|
||||
/// </summary>
|
||||
/// <param name="req">
|
||||
/// id:大于0-指定主键;
|
||||
/// apptTypeId:大于0-指定审核类型;
|
||||
/// opGroup:不为空-指定组别代码;
|
||||
/// opDescript:不为空-指定组别名称;
|
||||
/// </param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("GetList")]
|
||||
public ApiResult<List<ApptAuditor>> GetList(ApptAuditor req)
|
||||
{
|
||||
return _ApptAuditorRepo.GetList(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 预订审核 分页
|
||||
/// </summary>
|
||||
/// <param name="req">
|
||||
/// Keywords:角色名称模糊查询
|
||||
/// </param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("Page")]
|
||||
public ApiResult<PagerData<ApptAuditor>> Page(CommPageReq req)
|
||||
{
|
||||
return _ApptAuditorRepo.Page(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取预订审核线状结构
|
||||
/// </summary>
|
||||
/// <param name="req">
|
||||
/// apptTypeId:审核类型;
|
||||
/// </param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("AuditorLine")]
|
||||
public ApiResult<ApptAuditor> AuditorLine(ApptAuditor req)
|
||||
{
|
||||
return _ApptAuditorRepo.AuditorLine(req.ApptTypeId);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,185 @@
|
||||
using Appointment.Entity;
|
||||
using Appointment.IRepository;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Appointment.Api.Controllers
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订接口
|
||||
/// </summary>
|
||||
[Route("api/[controller]")]
|
||||
[ApiController]
|
||||
public class ApptController : ControllerBase
|
||||
{
|
||||
IApptRepo _ApptRepo;
|
||||
public ApptController(IApptRepo apptRepo)
|
||||
{
|
||||
_ApptRepo = apptRepo;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据时间段获取可使用的会议厅资源
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("UsableMeeting")]
|
||||
public ApiResult<List<MeetingRes>> UsableMeeting(MeetingReq req)
|
||||
{
|
||||
return _ApptRepo.UsableMeetingList(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据日期与场次获取可使用会议厅资源
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("UsableMeetingByDay")]
|
||||
public ApiResult<List<ResCode>> UsableMeetingByDay(UsableMeetingReq req)
|
||||
{
|
||||
return _ApptRepo.UsableMeeting(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取可使用的房间资源
|
||||
/// </summary>
|
||||
/// <param name="req">启始时间(默认从昨天开始)</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("UsableRoom")]
|
||||
public ApiResult<List<UsableRoomRes>> UsableRoom(UsableRoomReq req)
|
||||
{
|
||||
return _ApptRepo.UsableRoom(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据时间段获取房类最小可用数
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("UsableRoomMin")]
|
||||
public ApiResult<List<UsableRoomRes>> UsableRoomMin(UsableRoomReq req)
|
||||
{
|
||||
return _ApptRepo.UsableRoomMin(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取备注列表项
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[HttpPost("RemarkLis")]
|
||||
public ApiResult<List<string>> RemarkList()
|
||||
{
|
||||
return _ApptRepo.RemarkList();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 预订提交
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("Add")]
|
||||
public ApiResult Add(ApptSummaryReq req)
|
||||
{
|
||||
return _ApptRepo.Add(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 预订审核
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("ApptAudit")]
|
||||
public ApiResult ApptAudit(ApptAuditReq req)
|
||||
{
|
||||
return _ApptRepo.ApptAudit(req);
|
||||
}
|
||||
|
||||
[HttpPost("CancelAudit")]
|
||||
public ApiResult CancelAudit(ApptAuditReq req)
|
||||
{
|
||||
return _ApptRepo.CancelAudit(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 转审批
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("TransferAudit")]
|
||||
public ApiResult TransferAudit(TransferAuditReq req)
|
||||
{
|
||||
return _ApptRepo.TransferAudit(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 抄送
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("ApptSend")]
|
||||
public ApiResult ApptSend(ApptSendReq req)
|
||||
{
|
||||
return _ApptRepo.ApptSend(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键获取实体
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("GetModel")]
|
||||
public ApiResult<ApptSummaryReq> GetModel(ApptSummaryReq req)
|
||||
{
|
||||
return _ApptRepo.GetModel(req.Id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 我发起的预订列表列表
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("MyApptApplyPageReq")]
|
||||
public ApiResult<PagerData<ApptSummaryReq>> MyApptApplyPageReq(MyApptApplyPageReq req)
|
||||
{
|
||||
return _ApptRepo.MyApptApplyPageReq(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取我待审核的
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("MyPartakePage")]
|
||||
public ApiResult<PagerData<ApptSummaryReq>> MyPartakePage(MyApptAuditPageReq req)
|
||||
{
|
||||
return _ApptRepo.MyPartakePage(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取预订审核记录表
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("AuditorLogTree")]
|
||||
public ApiResult<AuditorLogTreeRes> AuditorLogTree(CommIntReq req)
|
||||
{
|
||||
return _ApptRepo.AuditorLogTree(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 测试
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("Demo")]
|
||||
public ApiResult Demo(CommPageReq req)
|
||||
{
|
||||
return _ApptRepo.Demo(req);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,171 @@
|
||||
using Appointment.Entity;
|
||||
using Appointment.IRepository;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Appointment.Api.Controllers
|
||||
{
|
||||
[Route("api/[controller]/[action]")]
|
||||
[ApiController]
|
||||
public class ApptJNCController : ControllerBase
|
||||
{
|
||||
IApptRepoJNC apptRepoJNC;
|
||||
|
||||
public ApptJNCController(IApptRepoJNC _apptRepoJNC)
|
||||
{
|
||||
apptRepoJNC = _apptRepoJNC;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 创建新的预订单
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public ApiResult<int> AddSummary(AddSummaryJncReq req)
|
||||
{
|
||||
return apptRepoJNC.AddApptSummary(req);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 修改暂订单
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public ApiResult<int> UpdateSummary(UpdateSummaryReq req)
|
||||
{
|
||||
return apptRepoJNC.UpdateSummary(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 申请确定单
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public async Task<ApiResult> ApplyOrder(ApplyOrderReq req)
|
||||
{
|
||||
return await apptRepoJNC.ApplyOrder(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 取消OA单
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public ApiResult Cancel(ApplyOrderReq req)
|
||||
{
|
||||
return apptRepoJNC.Cancel(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 确定单后续审批
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public async Task<ApiResult> AuditorSummary(ApplyOrderReq req)
|
||||
{
|
||||
return await apptRepoJNC.AuditorSummary(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 被驳回
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public async Task<ApiResult> RejectSummary(ApplyOrderReq req)
|
||||
{
|
||||
return await apptRepoJNC.RejectSummary(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 手动抄送
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public async Task<ApiResult> ManualCopy(ApptSendReq req)
|
||||
{
|
||||
return await apptRepoJNC.ManualCopy(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 信息回复
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public ApiResult AddReply(AddMsgReq req)
|
||||
{
|
||||
return apptRepoJNC.AddReply(req);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键获取实体
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public ApiResult<SummaryJncDetailRep> GetModel(SummaryJncModelReq req)
|
||||
{
|
||||
return apptRepoJNC.GetSummaryModel(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页预订列表
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public ApiResult<PagerData<SummaryJncDetailRep>> SummaryPager(SummaryJNCPageReq req)
|
||||
{
|
||||
return apptRepoJNC.ApptSummaryPager(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取审批流程
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public ApiResult<AuditorLogReq> AuditorLogTree(SummaryJncModelReq req)
|
||||
{
|
||||
return apptRepoJNC.AuditorLogTree(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 订单数据差距
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public ApiResult<List<DisparityReq>> Disparity(SummaryJncModelReq req)
|
||||
{
|
||||
return apptRepoJNC.Disparity(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 返回回复中的图片列表
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public ApiResult<List<string>> GetReplyPicList(SummaryJncModelReq req)
|
||||
{
|
||||
return apptRepoJNC.GetReplyPicList(req);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,97 @@
|
||||
using Appointment.Entity;
|
||||
using Appointment.IRepository;
|
||||
using Appointment.Repository;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Appointment.Api.Controllers
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订类型接口
|
||||
/// </summary>
|
||||
[Route("api/[controller]")]
|
||||
[ApiController]
|
||||
public class ApptTypeController : ControllerBase
|
||||
{
|
||||
IApptTypeRepo _ApptTypeRepo;
|
||||
public ApptTypeController(IApptTypeRepo apptTypeRepo)
|
||||
{
|
||||
_ApptTypeRepo = apptTypeRepo;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型 添加
|
||||
/// </summary>
|
||||
/// <param name="req">status不填写</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("Add")]
|
||||
public ApiResult<ApptType> Add(ApptTypeAddReq req)
|
||||
{
|
||||
return _ApptTypeRepo.Add(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型 删除
|
||||
/// </summary>
|
||||
/// <param name="req">根据id删除一条数据</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("Delete")]
|
||||
public ApiResult Delete(ApptType req)
|
||||
{
|
||||
return _ApptTypeRepo.Delete(req.Id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型更新
|
||||
/// </summary>
|
||||
/// <param name="req">根据id更新ApptName、Remark</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("Update")]
|
||||
public ApiResult<ApptType> Update(ApptType req)
|
||||
{
|
||||
return _ApptTypeRepo.Update(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型获取实体
|
||||
/// </summary>
|
||||
/// <param name="req">根据id获取实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("GetModel")]
|
||||
public ApiResult<ApptType> GetModel(ApptType req)
|
||||
{
|
||||
return _ApptTypeRepo.GetModel(req.Id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型列表
|
||||
/// </summary>
|
||||
/// <param name="req">
|
||||
/// Id:0-忽略,其他-指定;
|
||||
/// ApptName:根据类型名称模糊查询;
|
||||
/// </param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("GetList")]
|
||||
public ApiResult<List<ApptType>> GetList(ApptType req)
|
||||
{
|
||||
return _ApptTypeRepo.GetList(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型分页
|
||||
/// </summary>
|
||||
/// <param name="req">
|
||||
/// Keywords-根据类型名称模糊查询;
|
||||
/// </param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("Page")]
|
||||
public ApiResult<PagerData<ApptType>> Page(CommPageReq req)
|
||||
{
|
||||
return _ApptTypeRepo.Page(req);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
using Appointment.Entity;
|
||||
using Appointment.IRepository;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Net;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Appointment.Api.Controllers
|
||||
{
|
||||
[Route("api/[controller]")]
|
||||
[ApiController]
|
||||
public class DemoController : ControllerBase
|
||||
{
|
||||
private IApptRepo apptRepo;
|
||||
|
||||
public DemoController(IApptRepo _apptRepo)
|
||||
{
|
||||
apptRepo = _apptRepo;
|
||||
}
|
||||
|
||||
[HttpGet("show")]
|
||||
public IActionResult Show()
|
||||
{
|
||||
return Ok("ok");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,81 @@
|
||||
using Appointment.Entity;
|
||||
using Appointment.IRepository;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Newtonsoft.Json;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Appointment.Api.Controllers
|
||||
{
|
||||
/// <summary>
|
||||
/// 登录接口
|
||||
/// </summary>
|
||||
[Route("api/[controller]")]
|
||||
[ApiController]
|
||||
public class UserController : ControllerBase
|
||||
{
|
||||
IUserRepo _UserRepo;
|
||||
IApptRepo _ApptRepo;
|
||||
public UserController(IUserRepo userRepo, IApptRepo apptRep)
|
||||
{
|
||||
_UserRepo = userRepo;
|
||||
_ApptRepo = apptRep;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 管理人员 微信小程序授权登录
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("UserNameLogin")]
|
||||
public ApiResult<UserInfoRes> UserNameLogin(UserLoginAccountReq req)
|
||||
{
|
||||
return _UserRepo.UserNameLogin(req.UserName, req.UserPwd, req.Code, req.Hotelid);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 管理人员微信小程序登录
|
||||
/// </summary>
|
||||
/// <param name="req">wx.login下的code</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("WxLogin")]
|
||||
public ApiResult<UserInfoRes> WxLogin(UserLoginCodeReq req)
|
||||
{
|
||||
return _UserRepo.WxLogin(req.Code, req.Hotelid);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 绑定微信服务号OpenId
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("WxServiceSet")]
|
||||
public ApiResult WxServiceSet(WxServiceSetRes req)
|
||||
{
|
||||
return _UserRepo.WxServiceSet(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取所有用户
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[HttpPost("GetUserAll")]
|
||||
public ApiResult<List<LoginUserRes>> GetUserAll(BindUserReq req = null)
|
||||
{
|
||||
return _UserRepo.GetSendUserList(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取已绑定小程序与公众号的用户列表(不包含本用户)
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[HttpPost("GetTransferAudit")]
|
||||
public ApiResult<List<LoginUserRes>> GetBindUser(BindUserReq req)
|
||||
{
|
||||
return _UserRepo.GetTransferAuditUserList(req);
|
||||
}
|
||||
}
|
||||
}
|
||||
33
api_v1/Appointment.Api/Appointment.Api/Program.cs
Normal file
33
api_v1/Appointment.Api/Appointment.Api/Program.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Extensions.Hosting;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Appointment.Api
|
||||
{
|
||||
public class Program
|
||||
{
|
||||
public static void Main(string[] args)
|
||||
{
|
||||
CreateHostBuilder(args).Build().Run();
|
||||
}
|
||||
|
||||
public static IHostBuilder CreateHostBuilder(string[] args) =>
|
||||
Host.CreateDefaultBuilder(args)
|
||||
.ConfigureLogging((context, loggingBuilder) =>
|
||||
{
|
||||
loggingBuilder.AddFilter("System", LogLevel.Warning);
|
||||
loggingBuilder.AddFilter("Microsoft", LogLevel.Warning);
|
||||
loggingBuilder.AddLog4Net();
|
||||
})
|
||||
.ConfigureWebHostDefaults(webBuilder =>
|
||||
{
|
||||
// webBuilder.UseUrls("http://*:8082");
|
||||
webBuilder.UseStartup<Startup>();
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
{
|
||||
"iisSettings": {
|
||||
"windowsAuthentication": false,
|
||||
"anonymousAuthentication": true,
|
||||
"iisExpress": {
|
||||
"applicationUrl": "http://localhost:54928",
|
||||
"sslPort": 0
|
||||
}
|
||||
},
|
||||
"$schema": "http://json.schemastore.org/launchsettings.json",
|
||||
"profiles": {
|
||||
"IIS Express": {
|
||||
"commandName": "IISExpress",
|
||||
"launchBrowser": true,
|
||||
"launchUrl": "weatherforecast",
|
||||
"environmentVariables": {
|
||||
"ASPNETCORE_ENVIRONMENT": "Development"
|
||||
},
|
||||
"nativeDebugging": true
|
||||
},
|
||||
"Appointment.Api": {
|
||||
"commandName": "Project",
|
||||
"launchBrowser": true,
|
||||
"launchUrl": "weatherforecast",
|
||||
"environmentVariables": {
|
||||
"ASPNETCORE_ENVIRONMENT": "Development"
|
||||
},
|
||||
//"applicationUrl": "http://localhost:54928"
|
||||
"applicationUrl": "http://127.0.0.1:8062"
|
||||
}
|
||||
}
|
||||
}
|
||||
85
api_v1/Appointment.Api/Appointment.Api/Startup.cs
Normal file
85
api_v1/Appointment.Api/Appointment.Api/Startup.cs
Normal file
@@ -0,0 +1,85 @@
|
||||
using Appointment.Api.Utility;
|
||||
using Appointment.IRepository;
|
||||
using Appointment.Repository;
|
||||
using Microsoft.AspNetCore.Builder;
|
||||
using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Server.Kestrel.Core;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Hosting;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Appointment.Api
|
||||
{
|
||||
public class Startup
|
||||
{
|
||||
public Startup(IConfiguration configuration)
|
||||
{
|
||||
Configuration = configuration;
|
||||
}
|
||||
|
||||
public IConfiguration Configuration { get; }
|
||||
|
||||
// This method gets called by the runtime. Use this method to add services to the container.
|
||||
public void ConfigureServices(IServiceCollection services)
|
||||
{
|
||||
services.AddSwaggerSetup();
|
||||
|
||||
services.AddControllers(options =>
|
||||
{
|
||||
options.Filters.Add(typeof(CustomExceptionFilterAttribute));
|
||||
});
|
||||
|
||||
//
|
||||
services.AddTransient<IManagerGroup, ManagerGroup>();
|
||||
services.AddTransient<IApptTypeRepo, ApptTypeRepo>();
|
||||
services.AddTransient<IApptAuditorRepo, ApptAuditorRepo>();
|
||||
services.AddTransient<IApptRepo, ApptRepo>();
|
||||
services.AddTransient<IUserRepo, UserRepo>();
|
||||
services.AddTransient<IApptRepo, ApptRepo>();
|
||||
services.AddTransient<IApptLogRepo, ApptLogRepo>();
|
||||
services.AddTransient<IApptRepoJNC, ApptRepoJNC>();
|
||||
|
||||
}
|
||||
|
||||
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
|
||||
public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
|
||||
{
|
||||
// <20><><EFBFBD>û<EFBFBD><C3BB><EFBFBD>Http<74><70>ʾ<EFBFBD><CABE>Body<64><79><EFBFBD><EFBFBD>
|
||||
app.Use(next => new RequestDelegate(
|
||||
async context =>
|
||||
{
|
||||
context.Request.EnableBuffering();
|
||||
await next(context);
|
||||
}
|
||||
));
|
||||
|
||||
if (env.IsDevelopment())
|
||||
{
|
||||
app.UseDeveloperExceptionPage();
|
||||
}
|
||||
|
||||
app.UseSwagger();
|
||||
app.UseSwaggerUI(c =>
|
||||
{
|
||||
c.SwaggerEndpoint($"/swagger/V1/swagger.json", "Appointment.Api V1");
|
||||
c.RoutePrefix = "sw";
|
||||
});
|
||||
|
||||
app.UseRouting();
|
||||
|
||||
app.UseAuthorization();
|
||||
|
||||
app.UseEndpoints(endpoints =>
|
||||
{
|
||||
endpoints.MapControllers();
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Filters;
|
||||
using System;
|
||||
using System.Text;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using System.IO;
|
||||
using Appointment.Entity;
|
||||
|
||||
namespace Appointment.Api.Utility
|
||||
{
|
||||
public class CustomExceptionFilterAttribute : ExceptionFilterAttribute
|
||||
{
|
||||
private readonly log4net.ILog _logger = log4net.LogManager.GetLogger(typeof(CustomExceptionFilterAttribute));
|
||||
public override void OnException(ExceptionContext context)
|
||||
{
|
||||
// 异常未被处理
|
||||
if (!context.ExceptionHandled)
|
||||
{
|
||||
// 文本日志
|
||||
StringBuilder msg = new StringBuilder();
|
||||
msg.Append("出现异常:");
|
||||
msg.AppendFormat("请求地址:{0} ", context.HttpContext.Request.Path);
|
||||
string reqMethod = context.HttpContext.Request.Method;
|
||||
msg.AppendFormat("请求类型:{0}", reqMethod);
|
||||
|
||||
Dictionary<string, string> dict = new Dictionary<string, string>();
|
||||
if (reqMethod == "GET" && context.HttpContext.Request.Query.Count > 0)
|
||||
{
|
||||
msg.AppendFormat("请求参数:{0} ", context.HttpContext.Request.QueryString.ToString());
|
||||
}
|
||||
else if (reqMethod == "POST"
|
||||
&& context.HttpContext.Request.ContentType != null
|
||||
&& context.HttpContext.Request.ContentType.Contains("form-data")
|
||||
&& context.HttpContext.Request.ContentLength.Value > 0)
|
||||
{
|
||||
List<string> keys = context.HttpContext.Request.Form.Keys.ToList();
|
||||
if (keys.Count > 0)
|
||||
{
|
||||
msg.Append("请求参数:");
|
||||
foreach (var item in keys)
|
||||
{
|
||||
msg.AppendFormat("{0}={1},", item, context.HttpContext.Request.Form[item].ToString());
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (reqMethod == "POST"
|
||||
&& context.HttpContext.Request.ContentType != null
|
||||
&& context.HttpContext.Request.ContentType == "application/json"
|
||||
&& context.HttpContext.Request.ContentLength > 0)
|
||||
{
|
||||
context.HttpContext.Request.Body.Position = 0;
|
||||
StreamReader sr = new StreamReader(context.HttpContext.Request.Body);
|
||||
string body = sr.ReadToEndAsync().Result;
|
||||
msg.AppendFormat("请求参数:Body:{0} ", body);
|
||||
context.HttpContext.Request.Body.Position = 0;
|
||||
}
|
||||
_logger.Error(msg.ToString() + context.Exception);
|
||||
|
||||
// 返回前端
|
||||
DateTime now = DateTime.Now;
|
||||
context.Result = new JsonResult(ApiResult.Failed(context.Exception.Message, null));
|
||||
context.ExceptionHandled = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,48 @@
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.OpenApi.Models;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Appointment.Api
|
||||
{
|
||||
public static class SwaggerSetUp
|
||||
{
|
||||
/// <summary>
|
||||
/// 注册Swagger服务
|
||||
/// </summary>
|
||||
/// <param name="services"></param>
|
||||
public static void AddSwaggerSetup(this IServiceCollection services)
|
||||
{
|
||||
if (services == null) throw new ArgumentNullException(nameof(services));
|
||||
|
||||
var apiName = "Appointment.Api";
|
||||
|
||||
services.AddSwaggerGen(c =>
|
||||
{
|
||||
//
|
||||
c.SwaggerDoc("V1", new OpenApiInfo
|
||||
{
|
||||
// {ApiName} 定义成全局变量,方便修改
|
||||
Version = "V1",
|
||||
Title = $"{apiName} 接口文档",
|
||||
Description = $"{apiName} API V1",
|
||||
});
|
||||
//c.OrderActionsBy(o => o.RelativePath);
|
||||
|
||||
|
||||
var api = Path.Combine(AppContext.BaseDirectory, "Appointment.Api.xml");
|
||||
c.IncludeXmlComments(api, true);
|
||||
|
||||
var entity = Path.Combine(AppContext.BaseDirectory, "Appointment.Entity.xml");
|
||||
c.IncludeXmlComments(entity, true);
|
||||
|
||||
// 获取ReadMe项目实体的xml注释文件的目录
|
||||
var Irepository = Path.Combine(AppContext.BaseDirectory, "Appointment.IRepository.xml");
|
||||
c.IncludeXmlComments(Irepository);
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
10
api_v1/Appointment.Api/Appointment.Api/Utility/htmlpage.html
Normal file
10
api_v1/Appointment.Api/Appointment.Api/Utility/htmlpage.html
Normal file
@@ -0,0 +1,10 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<title></title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Logging": {
|
||||
"LogLevel": {
|
||||
"Default": "Information",
|
||||
"Microsoft": "Warning",
|
||||
"Microsoft.Hosting.Lifetime": "Information"
|
||||
}
|
||||
}
|
||||
}
|
||||
35
api_v1/Appointment.Api/Appointment.Api/appsettings.json
Normal file
35
api_v1/Appointment.Api/Appointment.Api/appsettings.json
Normal file
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"Logging": {
|
||||
"LogLevel": {
|
||||
"Default": "Information",
|
||||
"Microsoft": "Warning",
|
||||
"Microsoft.Hosting.Lifetime": "Information"
|
||||
}
|
||||
},
|
||||
"ConnectionString": "server=192.168.199.153;uid=sa;pwd=dlhis;database=hotel_jnc;",
|
||||
"NoPrefix": "JNCYXB", // 预定编号前缀
|
||||
"ApptType": "2", // 审核类型:1-默认模式,2-江南春模式
|
||||
"WeChat": { // 小程序
|
||||
"AppId": "wx7e511954cc1c23f7",
|
||||
"AppSecret": "9bef838143040d1972903089ab5429f3"
|
||||
},
|
||||
"AccessTokenMode": "2", // 获取AccessToken模式:1-爱住网获取,其他-本地获取
|
||||
"WeChatService": { // 服务号
|
||||
// 江南春
|
||||
//"AppId": "wx3f193488e04b2ed8",
|
||||
//"AppName": "江南春",
|
||||
//"AppSecret": "aaa88fba85e536c12ebc2e90915bdf46"
|
||||
"AppId": "wx2b6e92e9e0c6025f",
|
||||
"AppName": "香堤湾",
|
||||
"AppSecret": "1bbc7d71ea3154b803f438698d87c458"
|
||||
},
|
||||
"Hotelid": "oatest",
|
||||
"Kestrel": {
|
||||
"EndPoints": {
|
||||
"Http": {
|
||||
"Url": "http://0.0.0.0:8082"
|
||||
}
|
||||
}
|
||||
},
|
||||
"AllowedHosts": "*"
|
||||
}
|
||||
10
api_v1/Appointment.Api/Appointment.Api/htmlpage.html
Normal file
10
api_v1/Appointment.Api/Appointment.Api/htmlpage.html
Normal file
@@ -0,0 +1,10 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<title>启动</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
44
api_v1/Appointment.Api/Appointment.Api/log4net.Config
Normal file
44
api_v1/Appointment.Api/Appointment.Api/log4net.Config
Normal file
@@ -0,0 +1,44 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<log4net>
|
||||
<!-- Define some output appenders -->
|
||||
<appender name="rollingAppender" type="log4net.Appender.RollingFileAppender">
|
||||
<file value="log\log.txt" />
|
||||
<!--追加日志内容-->
|
||||
<appendToFile value="true" />
|
||||
|
||||
<!--防止多线程时不能写Log,官方说线程非安全-->
|
||||
<lockingModel type="log4net.Appender.FileAppender+MinimalLock" />
|
||||
|
||||
<!--可以为:Once|Size|Date|Composite-->
|
||||
<!--Composite为Size和Date的组合-->
|
||||
<rollingStyle value="Composite" />
|
||||
|
||||
<!--当备份文件时,为文件名加的后缀-->
|
||||
<datePattern value="yyyyMMdd.TXT" />
|
||||
|
||||
<!--日志最大个数,都是最新的-->
|
||||
<!--rollingStyle节点为Size时,只能有value个日志-->
|
||||
<!--rollingStyle节点为Composite时,每天有value个日志-->
|
||||
<maxSizeRollBackups value="20" />
|
||||
|
||||
<!--可用的单位:KB|MB|GB-->
|
||||
<maximumFileSize value="3MB" />
|
||||
|
||||
<!--置为true,当前最新日志文件名永远为file节中的名字-->
|
||||
<staticLogFileName value="true" />
|
||||
|
||||
<!--输出级别在INFO和ERROR之间的日志-->
|
||||
<filter type="log4net.Filter.LevelRangeFilter">
|
||||
<param name="LevelMin" value="ALL" />
|
||||
<param name="LevelMax" value="FATAL" />
|
||||
</filter>
|
||||
<layout type="log4net.Layout.PatternLayout">
|
||||
<conversionPattern value="%date [%thread] %-5level %logger - %message%newline"/>
|
||||
</layout>
|
||||
</appender>
|
||||
<root>
|
||||
<priority value="ALL"/>
|
||||
<level value="ALL"/>
|
||||
<appender-ref ref="rollingAppender" />
|
||||
</root>
|
||||
</log4net>
|
||||
39
api_v1/Appointment.Entity/Appointment.Entity.csproj
Normal file
39
api_v1/Appointment.Entity/Appointment.Entity.csproj
Normal file
@@ -0,0 +1,39 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp3.1</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
|
||||
<DocumentationFile>Appointment.Entity.xml</DocumentationFile>
|
||||
<NoWarn>1701;1702;1591</NoWarn>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Compile Remove="Request\ApptSummaryReq - 复制.cs" />
|
||||
<Compile Remove="Utility\ApiResult - 复制.cs" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Remove="Model\_data\迪联OA预定补丁%28含转审抄送).sql" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Log4NetCore" Version="1.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.Configuration" Version="3.1.7" />
|
||||
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="3.1.7" />
|
||||
<PackageReference Include="sqlSugarCore" Version="5.0.1.5" />
|
||||
<PackageReference Include="System.Drawing.Common" Version="5.0.2" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Folder Include="Model\_data\" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Update="Appointment.Entity.xml">
|
||||
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
3499
api_v1/Appointment.Entity/Appointment.Entity.xml
Normal file
3499
api_v1/Appointment.Entity/Appointment.Entity.xml
Normal file
File diff suppressed because it is too large
Load Diff
168
api_v1/Appointment.Entity/Enum/CommEnum.cs
Normal file
168
api_v1/Appointment.Entity/Enum/CommEnum.cs
Normal file
@@ -0,0 +1,168 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public enum EnumCommStatus
|
||||
{
|
||||
屏蔽 = 0,
|
||||
有效 = 1,
|
||||
}
|
||||
|
||||
public enum EnumAuditorStatus
|
||||
{
|
||||
全部 = 0,
|
||||
|
||||
// 常规流程
|
||||
|
||||
//保存 = 0,
|
||||
//待审核 = 1,
|
||||
审核中 = 2,
|
||||
审核通过 = 3,
|
||||
驳回 = 4,
|
||||
作废 = 5,
|
||||
取消 = 6,
|
||||
|
||||
|
||||
|
||||
|
||||
// 江南春模式
|
||||
|
||||
// ---- 以下为暂定单状态,一个单子必有其一
|
||||
|
||||
/// <summary>
|
||||
/// 暂订单
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 销售人员创建,
|
||||
/// 创建完成后,提示是保存还是提交
|
||||
/// </remarks>
|
||||
江南春模式暂订单 = 20,
|
||||
|
||||
/// <summary>
|
||||
/// 待审核的暂订单
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 暂订单提交之后,待生成确订单
|
||||
/// 只有待状态下的订单才能生成确定单
|
||||
/// </remarks>
|
||||
江南春模式暂订单审核中 = 21,
|
||||
|
||||
/// <summary>
|
||||
/// 暂订单已提交
|
||||
/// </summary>
|
||||
江南春模式暂订单已生成确定单 = 22,
|
||||
|
||||
江南春模式暂订单驳回 = 23,
|
||||
|
||||
// ---- 以下为确认单状态,
|
||||
|
||||
/// <summary>
|
||||
/// 预定处根据销售提示的暂定单编号 及订金生成
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 销售人员提供单号
|
||||
/// 客户交订金
|
||||
/// 预定处办理
|
||||
/// 占用资源
|
||||
/// </remarks>
|
||||
江南春模式确定单 = 30,
|
||||
|
||||
江南春模式销售申请OA单 = 31,
|
||||
|
||||
江南春模式销售经理审核中 = 32,
|
||||
|
||||
江南春模式财务经理审核中 = 33,
|
||||
|
||||
江南春模式财务总监审核中 = 34,
|
||||
|
||||
江南春模式总经理审核中 = 35,
|
||||
|
||||
江南春模式完成预定 = 36,
|
||||
|
||||
江南春模式历史单 = 37,
|
||||
|
||||
江南春模式确定单驳回 = 38,
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 江南春流程状态
|
||||
/// </summary>
|
||||
public enum EnumAuditorJncStatus
|
||||
{
|
||||
全部 = 0,
|
||||
|
||||
// ---- 江南春流程
|
||||
/// <summary>
|
||||
/// 销售员保存单
|
||||
/// </summary>
|
||||
暂订单 = 20,
|
||||
|
||||
/// <summary>
|
||||
/// 业务员已提交申请审核
|
||||
/// </summary>
|
||||
审核单申请 = 21,
|
||||
|
||||
/// <summary>
|
||||
/// 预定部已审核通过
|
||||
/// </summary>
|
||||
审核单预定部 = 22,
|
||||
|
||||
/// <summary>
|
||||
/// 销售经理已审核通过
|
||||
/// </summary>
|
||||
审核单销售经理 = 23,
|
||||
|
||||
/// <summary>
|
||||
/// 财务经理已审核通过
|
||||
/// </summary>
|
||||
审核单财务经理 = 24,
|
||||
|
||||
/// <summary>
|
||||
/// 财务总监已审核通过
|
||||
/// </summary>
|
||||
审核单财务总监 = 25,
|
||||
|
||||
/// <summary>
|
||||
/// 总经理已审核通过
|
||||
/// </summary>
|
||||
确定单 = 26,
|
||||
|
||||
/// <summary>
|
||||
/// 销售员已确定完成,已群发,自动抄送
|
||||
/// </summary>
|
||||
完成单 = 27,
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 审核被驳回的单子
|
||||
/// </summary>
|
||||
驳回单 = 30,
|
||||
|
||||
/// <summary>
|
||||
/// 预约被取消的单子
|
||||
/// </summary>
|
||||
取消单 = 31,
|
||||
|
||||
/// <summary>
|
||||
/// 订单占用资源时,原来的暂定单被归档
|
||||
/// </summary>
|
||||
归档暂定单 = 32,
|
||||
|
||||
/// <summary>
|
||||
/// 订单占用资源后,原来的单子被归档
|
||||
/// </summary>
|
||||
归档资源单 = 33,
|
||||
}
|
||||
|
||||
public enum EnumSysCodeClass
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订类型
|
||||
/// </summary>
|
||||
apptremark
|
||||
}
|
||||
}
|
||||
124
api_v1/Appointment.Entity/Model/ApptAuditLog.cs
Normal file
124
api_v1/Appointment.Entity/Model/ApptAuditLog.cs
Normal file
@@ -0,0 +1,124 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订审核记录表
|
||||
/// 抄送表
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("appt_audit_log")]
|
||||
public class ApptAuditLog
|
||||
{
|
||||
/// <summary>
|
||||
/// 递增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 类型:1-审核,2-抄送,3-消息回复
|
||||
/// </summary>
|
||||
public int Type { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
public DateTime CreateTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核人员/抄送接收人/回复操作人
|
||||
/// </summary>
|
||||
public string UserId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属预订主单
|
||||
/// 消息回复可为0
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "appt_id")]
|
||||
public int ApptId { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 审核状态(不适用抄送) :0-驳回,1-审核通过,2-转审批,3-抄送,10-江南春模式销售员重新提交,
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 2021-5-17 自动 手动抄送都改为3,以前
|
||||
/// 2021-10-9 新的江南春驳回状态为30
|
||||
/// 为消息回复类型时 数据为0
|
||||
/// </remarks>
|
||||
[SugarColumn(ColumnName = "auditor_status")]
|
||||
public int AuditorStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 图片
|
||||
/// </summary>
|
||||
public string Pic0 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 图片
|
||||
/// </summary>
|
||||
public string Pic1 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 图片
|
||||
/// </summary>
|
||||
public string Pic2 { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 图片
|
||||
/// </summary>
|
||||
public string Pic3 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 图片
|
||||
/// </summary>
|
||||
public string Pic4 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 抄送发起人
|
||||
/// </summary>
|
||||
public string Source { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 被手工回复的父结点
|
||||
/// </summary>
|
||||
public int PId { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 图片
|
||||
///// </summary>
|
||||
//public string Pic5 { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 图片
|
||||
///// </summary>
|
||||
//public string Pic6 { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 图片
|
||||
///// </summary>
|
||||
//public string Pic7 { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 图片
|
||||
///// </summary>
|
||||
//public string Pic8 { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 图片
|
||||
///// </summary>
|
||||
//public string Pic9 { get; set; }
|
||||
}
|
||||
}
|
||||
59
api_v1/Appointment.Entity/Model/ApptAuditor.cs
Normal file
59
api_v1/Appointment.Entity/Model/ApptAuditor.cs
Normal file
@@ -0,0 +1,59 @@
|
||||
using Appointment.Entity.ValidateAttribute;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订审核结构
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("appt_auditor")]
|
||||
public class ApptAuditor
|
||||
{
|
||||
/// <summary>
|
||||
/// 递增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审批类型[apptType.id]
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "Appt_type_id")]
|
||||
public int ApptTypeId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 角色代码[uc_groupRes.op_group]
|
||||
/// </summary>
|
||||
[StringLength(50, MinLength = 2, ErrorMessage = "角色代码必须为2~50个字符")]
|
||||
[SugarColumn(ColumnName = "op_group")]
|
||||
public string OpGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 角色名称[uc_groupRes.descript]
|
||||
/// </summary>
|
||||
[StringLength(50, MinLength = 2, ErrorMessage = "角色名称必须为2~50个字符")]
|
||||
[SugarColumn(ColumnName = "op_descript")]
|
||||
public string OpDescript { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属父级:0-首审,
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "pid")]
|
||||
public int Pid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否支持转审:0-不支持,1-支持(当转审之后,不再回到审批流程)
|
||||
/// </summary>
|
||||
public int Custom { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 子结点
|
||||
/// </summary>
|
||||
[SugarColumn(IsIgnore = true)]
|
||||
public ApptAuditor Child { get; set; }
|
||||
}
|
||||
}
|
||||
99
api_v1/Appointment.Entity/Model/ApptCatering.cs
Normal file
99
api_v1/Appointment.Entity/Model/ApptCatering.cs
Normal file
@@ -0,0 +1,99 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 餐饮预订明细实体
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("appt_catering")]
|
||||
public class ApptCatering
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int? Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// guid
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 同一个订单的的(暂订单、确认单)GUID相同
|
||||
/// </remarks>
|
||||
public string Guid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属预订主单
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "appt_id")]
|
||||
public int? ApptId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 餐饮入场日期
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "catering_time")]
|
||||
public DateTime CateringTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 场次 如上午、下午、晚上存储结果为"1,2,3",早为“1”
|
||||
/// </summary>
|
||||
public string Groups { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 餐厅名称
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 手输名称
|
||||
/// </remarks>
|
||||
[SugarColumn(ColumnName = "catering_room")]
|
||||
public string CateringRoom { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用餐地点
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "catering_code")]
|
||||
public string CateringCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用餐类型 0-桌数,1-人数
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "catering_type")]
|
||||
public int CateringType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 桌数或人数数量
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "catering_num")]
|
||||
public int CateringNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 每桌或每人单价
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "catering_price")]
|
||||
public decimal CateringPrice { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 餐饮-桌型
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "catering_table")]
|
||||
public string CateringTable { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 酒水
|
||||
/// </summary>
|
||||
public string Wine { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
}
|
||||
57
api_v1/Appointment.Entity/Model/ApptLog.cs
Normal file
57
api_v1/Appointment.Entity/Model/ApptLog.cs
Normal file
@@ -0,0 +1,57 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订日志表实体
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("appt_log")]
|
||||
public class ApptLog
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 数据表
|
||||
/// </summary>
|
||||
public string TableName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 表主键值
|
||||
/// </summary>
|
||||
public string KeyId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 原始数据
|
||||
/// </summary>
|
||||
public string OldData { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 新数据
|
||||
/// </summary>
|
||||
public string NewData { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
public DateTime CreateTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作人
|
||||
/// </summary>
|
||||
public string UserId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户类型:0-普通用户,1-管理人员
|
||||
/// </summary>
|
||||
public int SystemUser { get; set; }
|
||||
|
||||
}
|
||||
}
|
||||
97
api_v1/Appointment.Entity/Model/ApptMeeting.cs
Normal file
97
api_v1/Appointment.Entity/Model/ApptMeeting.cs
Normal file
@@ -0,0 +1,97 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 会议室预订明细实体
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("appt_meeting")]
|
||||
public class ApptMeeting
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int? Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// guid
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 同一个订单的的(暂订单、确认单)GUID相同
|
||||
/// </remarks>
|
||||
public string Guid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属预订主单
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "appt_id")]
|
||||
public int? ApptId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议入场时间
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "meeting_time")]
|
||||
public DateTime MeetingTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 场次,如上午、下午、晚上存储结果为"1,2,3",早为“1”
|
||||
/// </summary>
|
||||
public string Groups { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 会议厅名称(手输或根据类型选择自动填入),手输不占用资源
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "meeting_room")]
|
||||
public string MeetingRoom { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议厅代码(手输类型时为空,不占用资源)
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "meeting_code")]
|
||||
public string MeetingCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议室主席台位
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "meeting_rostrum")]
|
||||
public string MeetingRostrum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议室-台型(课桌)
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "meeting_shape")]
|
||||
public string MeetingShape { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 人数:0-待定,
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "meeting_num")]
|
||||
public int MeetingNum { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 单价
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "meeting_price")]
|
||||
public decimal MeetingPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 横幅内容
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "meeting_title")]
|
||||
public string MeetingTitle { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 议厅备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
}
|
||||
48
api_v1/Appointment.Entity/Model/ApptRemark.cs
Normal file
48
api_v1/Appointment.Entity/Model/ApptRemark.cs
Normal file
@@ -0,0 +1,48 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订备注扩展表
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("appt_remark")]
|
||||
public class ApptRemark
|
||||
{
|
||||
/// <summary>
|
||||
/// 递增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int? Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// guid
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 同一个订单的的(暂订单、确认单)GUID相同
|
||||
/// </remarks>
|
||||
public string Guid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订主键
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// appt_summary.id
|
||||
/// </remarks>
|
||||
[SugarColumn(ColumnName = "appt_id")]
|
||||
public int? ApptId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注分类
|
||||
/// </summary>
|
||||
public string Title { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注内容
|
||||
/// </summary>
|
||||
public string Info { get; set; }
|
||||
}
|
||||
}
|
||||
79
api_v1/Appointment.Entity/Model/ApptRemarkLog.cs
Normal file
79
api_v1/Appointment.Entity/Model/ApptRemarkLog.cs
Normal file
@@ -0,0 +1,79 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 操作展示日志
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("appt_remark_log")]
|
||||
public class ApptRemarkLog
|
||||
{
|
||||
/// <summary>
|
||||
/// 递增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作时间
|
||||
/// </summary>
|
||||
public DateTime CreateTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属父级
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 0-默认,
|
||||
/// 其他-对操作备注进行追加备注
|
||||
/// </remarks>
|
||||
public int Pid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订单主键
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// appt_summary.id
|
||||
/// </remarks>
|
||||
[SugarColumn(ColumnName = "appt_id")]
|
||||
public int ApptId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作人账号
|
||||
/// </summary>
|
||||
public string Account { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 操作人姓名
|
||||
/// </summary>
|
||||
public string UserName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 提交前状态
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "old_status")]
|
||||
public int OldStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 提交后状态
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "new_status")]
|
||||
public int NewStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注内容
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 变更的数据
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "update_data")]
|
||||
public string UpdateData { get; set; }
|
||||
}
|
||||
}
|
||||
104
api_v1/Appointment.Entity/Model/ApptRoom.cs
Normal file
104
api_v1/Appointment.Entity/Model/ApptRoom.cs
Normal file
@@ -0,0 +1,104 @@
|
||||
using Appointment.Entity.ValidateAttribute;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 客房预订明细表实体
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("appt_room")]
|
||||
public class ApptRoom
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int? Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// guid
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 同一个订单的的(暂订单、确认单)GUID相同
|
||||
/// </remarks>
|
||||
public string Guid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属预订主单
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "appt_id")]
|
||||
public int? ApptId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 抵达时间
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "room_in")]
|
||||
public DateTime RoomIn { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 离开时间
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "room_out")]
|
||||
public DateTime RoomOut { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 房型(手输或根据类型选择自动填入),手输不占用资源
|
||||
/// </summary>
|
||||
[StringLength(30, MinLength = 2, ErrorMessage = "房型必须为2~30个字符")]
|
||||
[SugarColumn(ColumnName = "room_group")]
|
||||
public string RoomGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 选择房间类型(手输类型时为空,不占用资源)
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "room_code")]
|
||||
public string RoomCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房间数量
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 不占用资源的可以为0
|
||||
/// </remarks>
|
||||
[SugarColumn(ColumnName = "room_num")]
|
||||
public int RoomNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房间单价
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "room_price")]
|
||||
public decimal RoomPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总早餐数:0-无早餐,
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "breakfast_num")]
|
||||
public int BreakfastNum { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 长途电话:0-关,1-开,
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "long_distance")]
|
||||
public int LongDistance { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客房吧:0-关,1-开,
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "min_shop")]
|
||||
public int MinShop { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客房备注
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "remark")]
|
||||
public string RoomRemark { get; set; }
|
||||
}
|
||||
}
|
||||
77
api_v1/Appointment.Entity/Model/ApptSpring.cs
Normal file
77
api_v1/Appointment.Entity/Model/ApptSpring.cs
Normal file
@@ -0,0 +1,77 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 温泉预订明细实体
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("appt_spring")]
|
||||
public class ApptSpring
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int? Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// guid
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 同一个订单的的(暂订单、确认单)GUID相同
|
||||
/// </remarks>
|
||||
public string Guid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属预订主单
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "appt_id")]
|
||||
public int? ApptId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 温泉_日期
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "spring_time")]
|
||||
public DateTime SpringTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总人数(自动计算):0-待定
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "people_num")]
|
||||
public int PeopleNum { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// spring_men
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "spring_men")]
|
||||
public int SpringMen { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 女性人数:0-待定
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "spring_women")]
|
||||
public int SpringWomen { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 二次消费
|
||||
/// </summary>
|
||||
public string Consume { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单价
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "spring_price")]
|
||||
public decimal SpringPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
}
|
||||
239
api_v1/Appointment.Entity/Model/ApptSummary.cs
Normal file
239
api_v1/Appointment.Entity/Model/ApptSummary.cs
Normal file
@@ -0,0 +1,239 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订主单
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("appt_summary")]
|
||||
public class ApptSummary
|
||||
{
|
||||
/// <summary>
|
||||
/// 递增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int? Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// guid
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 同一个订单的的(暂订单、确认单)GUID相同
|
||||
/// </remarks>
|
||||
public string Guid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属用户
|
||||
/// </summary>
|
||||
public string UserId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
public DateTime? CreateTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型[appt_type.id]
|
||||
/// 1- 默认模式,
|
||||
/// 2- 江南春模式,
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "appt_typeid")]
|
||||
public int? ApptTypeId { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 审核状态:见EnumAuditorStatus
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "auditor_status")]
|
||||
public int? AuditorStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 待审核角色id:0-无 appt_type
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 江南春模式=0
|
||||
/// </remarks>
|
||||
[SugarColumn(ColumnName = "auditor_id")]
|
||||
public int? AuditorId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 转审账号(当有转审时,将AuditorId=0)
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "transfer_audit")]
|
||||
public string TransferAudit { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 订单类型预留字段
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "appt_type")]
|
||||
public int? ApptType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 编号(生成确认单时产生)
|
||||
/// </summary>
|
||||
public string No { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 组织单位
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "buyer_name")]
|
||||
public string BuyerName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 公司地址
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "buyer_address")]
|
||||
public string BuyerAddress { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 订单名称
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "buyer_title")]
|
||||
public string BuyerTitle { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组织负责人
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "leader_name")]
|
||||
public string LeaderName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组织负责人电话
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "leader_mobile")]
|
||||
public string LeaderMobile { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 会议组房号
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "leader_room")]
|
||||
public string LeaderRoom { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 营销部跟单人(发起人)
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "sale_name")]
|
||||
public string SaleName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 营销部跟单电话
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "sale_mobile")]
|
||||
public string SaleMobile { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 营销总监 手工写
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "sale_director")]
|
||||
public string SaleDirector { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客房总备注
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "room_remark")]
|
||||
public string RoomRemark { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 会议室总备注
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "meeting_remark")]
|
||||
public string MeetingRemark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 餐饮总备注
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "catering_remark")]
|
||||
public string CateringRemark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 温泉总备注
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "spring_remark")]
|
||||
public string SpringRemark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 编辑之前的主键
|
||||
/// </summary>
|
||||
public int? Pid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 团队编号
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 2021-6-16 江南春模式有效
|
||||
/// </remarks>
|
||||
[SugarColumn(ColumnName = "grp_no")]
|
||||
public string GrpNo { get; set; }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 预定信息最小开始日期
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "start_day")]
|
||||
public DateTime StartDay { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预定信息最大结果日期
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "end_day")]
|
||||
public DateTime EndDay { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 申请OA单状态:0-未占用资源,1-已占用资源
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "apply_oa")]
|
||||
public int ApplyOA { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 为销售员再次编辑提交的时间,文件对比中使用该时间,显示什么时候改了内容
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "alter_time")]
|
||||
public DateTime AlterTime { get; set; }
|
||||
|
||||
// 关联表信息
|
||||
|
||||
/// <summary>
|
||||
/// 客房预订明细列表
|
||||
/// </summary>
|
||||
[SqlSugar.SugarColumn(IsIgnore = true)]
|
||||
public List<ApptRoom> ApptRoomList { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议室预订明细列表
|
||||
/// </summary>
|
||||
[SqlSugar.SugarColumn(IsIgnore = true)]
|
||||
public List<ApptMeeting> ApptMeetingList { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 餐饮预订明细列表
|
||||
/// </summary>
|
||||
[SqlSugar.SugarColumn(IsIgnore = true)]
|
||||
public List<ApptCatering> ApptCateringList { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 温泉预订明细列表
|
||||
/// </summary>
|
||||
[SqlSugar.SugarColumn(IsIgnore = true)]
|
||||
public List<ApptSpring> ApptSpringList { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 自定义备注
|
||||
/// </summary>
|
||||
[SqlSugar.SugarColumn(IsIgnore = true)]
|
||||
public List<ApptRemark> ApptRemarks { get; set; }
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
43
api_v1/Appointment.Entity/Model/ApptType.cs
Normal file
43
api_v1/Appointment.Entity/Model/ApptType.cs
Normal file
@@ -0,0 +1,43 @@
|
||||
using Appointment.Entity.ValidateAttribute;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 审核类型
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 建议:
|
||||
/// 根据ApptName(预订类型名称) 判断审核模式
|
||||
///
|
||||
/// ApptName:
|
||||
/// DefaultAuditProcess - 标准审核流程,最后一级审核通过后,占用资料,实现抄送,支持转审批(跳转审核流程);
|
||||
/// JNCcustom - 江南春模式,
|
||||
/// </remarks>
|
||||
[Serializable]
|
||||
[SugarTable("appt_type")]
|
||||
public class ApptType
|
||||
{
|
||||
/// <summary>
|
||||
/// 递增主键
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型名称
|
||||
/// </summary>
|
||||
[StringLength(30, MinLength = 2, ErrorMessage = "预订类型名称必须为2~30个字符")]
|
||||
[SugarColumn(ColumnName = "appt_name")]
|
||||
public string ApptName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注说明
|
||||
/// </summary>
|
||||
[StringMaxLength(200, ErrorMessage = "备注说明最大长度200个字符")]
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
}
|
||||
264
api_v1/Appointment.Entity/Model/GrpInfo.cs
Normal file
264
api_v1/Appointment.Entity/Model/GrpInfo.cs
Normal file
@@ -0,0 +1,264 @@
|
||||
using Appointment.Entity.ValidateAttribute;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 团队表实体
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("grpinfo")]
|
||||
public class GrpInfo
|
||||
{
|
||||
/// <summary>
|
||||
/// 团队账号
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true)]
|
||||
public string Accnt { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 状态:R-预订,I-在住
|
||||
/// </summary>
|
||||
public string Sta { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 团名
|
||||
/// </summary>
|
||||
public string Gname { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 团名(英文)首字母自动生成
|
||||
/// </summary>
|
||||
public string Ename { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 代号
|
||||
/// </summary>
|
||||
public string Code { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订号
|
||||
/// </summary>
|
||||
public string Resno { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 默认与Accnt一致
|
||||
/// </remarks>
|
||||
public string Grpno { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 来源
|
||||
/// </summary>
|
||||
public string Src { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 市场码
|
||||
/// </summary>
|
||||
public string Mkt { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 抵达时间
|
||||
/// </summary>
|
||||
public DateTime? Arr { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 离开时间
|
||||
/// </summary>
|
||||
public DateTime? Dep { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 国家
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 默认:CN
|
||||
/// </remarks>
|
||||
public string Country { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 籍贯编号
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 默认:null
|
||||
/// </remarks>
|
||||
public string Navite { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 地址
|
||||
/// </summary>
|
||||
public string Address { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 领队
|
||||
/// </summary>
|
||||
public string Leader { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 领队电话
|
||||
/// </summary>
|
||||
public string Phone { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 人数
|
||||
/// </summary>
|
||||
public int? Guests { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房数
|
||||
/// </summary>
|
||||
public int? Rooms { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单位号
|
||||
/// </summary>
|
||||
public string Cropsno { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单位名称
|
||||
/// </summary>
|
||||
public string Cropname { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 付款码
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 现金:9001
|
||||
/// </remarks>
|
||||
public string Paycode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注说明
|
||||
/// </summary>
|
||||
public string Ramark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
public DateTime? Sysdate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 更新次数
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_num")]
|
||||
public int? LogNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作账号
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_id")]
|
||||
public string LogId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 默认1
|
||||
/// </remarks>
|
||||
[SugarColumn(ColumnName = "log_shift")]
|
||||
public char LogShift { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作IP
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_ip")]
|
||||
public string LogIp { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 最后操作时间
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 默认为创建时间
|
||||
/// </remarks>
|
||||
[SugarColumn(ColumnName = "log_date")]
|
||||
public DateTime? LogDate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 默认:"团队"
|
||||
/// </remarks>
|
||||
public string Payroom { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 主账房
|
||||
/// </summary>
|
||||
public string Payaccnt { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// IVP
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 默认0
|
||||
/// </remarks>
|
||||
public string Vip { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 默认0
|
||||
/// </remarks>
|
||||
public string Sec { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 特殊要求代码
|
||||
/// </summary>
|
||||
public string Special { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 应收账号
|
||||
/// </summary>
|
||||
public string Araccnt { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 销售员编号
|
||||
/// </summary>
|
||||
public string Saleid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总消费
|
||||
/// </summary>
|
||||
public decimal? Charge { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public decimal? Credit { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 余额,合计余额
|
||||
/// </summary>
|
||||
public decimal? Balance { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public decimal? Ybalance { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public decimal? Accntnumb { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 允许POS账转入:T/F
|
||||
/// </summary>
|
||||
public char Flag { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房价码
|
||||
/// </summary>
|
||||
public string Rmcode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// package码
|
||||
/// </summary>
|
||||
public string Rmpackage { get; set; }
|
||||
}
|
||||
}
|
||||
59
api_v1/Appointment.Entity/Model/Mstinfo.cs
Normal file
59
api_v1/Appointment.Entity/Model/Mstinfo.cs
Normal file
@@ -0,0 +1,59 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 入住客户表
|
||||
/// </summary>
|
||||
[SugarTable("mstinfo")]
|
||||
public class Mstinfo
|
||||
{
|
||||
/// <summary>
|
||||
/// 入住信息的账号
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true)]
|
||||
public string Accnt { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 入住状态:R-预订, I-在住, O-结账, D-待删, H-历史,C-取消,
|
||||
/// </summary>
|
||||
public string Sta { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 系统时间
|
||||
/// </summary>
|
||||
public string SysDate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 宾客姓名
|
||||
/// </summary>
|
||||
public string Gname { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作管理员账号
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_id")]
|
||||
public string LogId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作管理员名称
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_name")]
|
||||
public string LogName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 班别
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_shift")]
|
||||
public string LogShift { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 日志操作IP
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_ip")]
|
||||
public string LogIp { get; set; }
|
||||
}
|
||||
}
|
||||
70
api_v1/Appointment.Entity/Model/RcancelLog.cs
Normal file
70
api_v1/Appointment.Entity/Model/RcancelLog.cs
Normal file
@@ -0,0 +1,70 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 取消预定单是,录入的取消信息
|
||||
/// </summary>
|
||||
[SugarTable("rcancel_log")]
|
||||
public class RcancelLog
|
||||
{
|
||||
/// <summary>
|
||||
/// 入住信息的账号
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true)]
|
||||
public string Accnt { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 订单操作次数,默认1
|
||||
/// </summary>
|
||||
public int Number { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 宾客姓名
|
||||
/// </summary>
|
||||
public string Gname { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作备注
|
||||
/// </summary>
|
||||
public string Reason { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作管理员账号
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_id")]
|
||||
public string LogId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作管理员名称
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_name")]
|
||||
public string LogName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 班别
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_shift")]
|
||||
public string LogShift { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 创建日志时间
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_date")]
|
||||
public DateTime LogDate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 日志操作IP
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "log_ip")]
|
||||
public string LogIp { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 系统时间
|
||||
/// </summary>
|
||||
public string SysDate { get; set; }
|
||||
}
|
||||
}
|
||||
52
api_v1/Appointment.Entity/Model/ResCode.cs
Normal file
52
api_v1/Appointment.Entity/Model/ResCode.cs
Normal file
@@ -0,0 +1,52 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 会议厅
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("res_code")]
|
||||
public class ResCode
|
||||
{
|
||||
/// <summary>
|
||||
/// 会议厅代码
|
||||
/// </summary>
|
||||
public string Code { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 代码:A-会议室,B-会议室设备,C-汽车,D-自行车.
|
||||
/// </summary>
|
||||
public string Sort { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 厅名称
|
||||
/// </summary>
|
||||
public string Descript1 { get; set; }
|
||||
|
||||
public string Descript2 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 状态:T-有效,
|
||||
/// </summary>
|
||||
public string Sta { get; set; }
|
||||
|
||||
public int Numbers { get; set; }
|
||||
|
||||
public string Pccode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 价格
|
||||
/// </summary>
|
||||
public decimal Price { get; set; }
|
||||
|
||||
public int Period { get; set; }
|
||||
|
||||
public string Remark { get; set; }
|
||||
|
||||
public int Sequence { get; set; }
|
||||
}
|
||||
}
|
||||
117
api_v1/Appointment.Entity/Model/ResInfo.cs
Normal file
117
api_v1/Appointment.Entity/Model/ResInfo.cs
Normal file
@@ -0,0 +1,117 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 会议室流水
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("res_info")]
|
||||
public class ResInfo
|
||||
{
|
||||
/// <summary>
|
||||
/// 会议室流水号
|
||||
/// </summary>
|
||||
public string No { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 状态:R-预订
|
||||
/// </summary>
|
||||
public string Sta { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 订单号
|
||||
/// </summary>
|
||||
public string Accnt { get; set; }
|
||||
|
||||
public string Accnt1 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议室代码[res_code.code]
|
||||
/// </summary>
|
||||
public string Rescode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 数量
|
||||
/// </summary>
|
||||
public int Numbers { get; set; }
|
||||
|
||||
public DateTime Bdate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 开始日期
|
||||
/// </summary>
|
||||
public DateTime? Stime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 结束日期
|
||||
/// </summary>
|
||||
public DateTime? Etime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 开始场次
|
||||
/// </summary>
|
||||
public int Sfield { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 结束场次
|
||||
/// </summary>
|
||||
public int Efield { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 开始时间
|
||||
/// </summary>
|
||||
public string Sfieldtime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 结束时间
|
||||
/// </summary>
|
||||
public string Efieldtime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会场备注
|
||||
/// </summary>
|
||||
public string Summary { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 价格
|
||||
/// </summary>
|
||||
public decimal Price0 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 价格
|
||||
/// </summary>
|
||||
public decimal Price { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否入账:T/F
|
||||
/// </summary>
|
||||
public string Paid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作账号
|
||||
/// </summary>
|
||||
public string Resby { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作人员姓名
|
||||
/// </summary>
|
||||
public string Resbyname { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作时间
|
||||
/// </summary>
|
||||
public DateTime? Reserved { get; set; }
|
||||
|
||||
public string Cby { get; set; }
|
||||
|
||||
public string Cbyname { get; set; }
|
||||
|
||||
public DateTime? Cbytime { get; set; }
|
||||
|
||||
public int Logmark { get; set; }
|
||||
}
|
||||
}
|
||||
116
api_v1/Appointment.Entity/Model/RoomType.cs
Normal file
116
api_v1/Appointment.Entity/Model/RoomType.cs
Normal file
@@ -0,0 +1,116 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 房类实体(部分)
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("room_type")]
|
||||
public class RoomType
|
||||
{
|
||||
/// <summary>
|
||||
/// 房类代码
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true)]
|
||||
public string Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房类中文描述(中文名称)
|
||||
/// </summary>
|
||||
public string Descript1 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房类英文描述
|
||||
/// </summary>
|
||||
public string Descript2 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 门市价
|
||||
/// </summary>
|
||||
public decimal Price0 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 优惠价
|
||||
/// </summary>
|
||||
public decimal Price { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 超预订
|
||||
/// </summary>
|
||||
public int Exceed { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总房数
|
||||
/// </summary>
|
||||
public int Total { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 钟点房起步时间
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "dayuse_base")]
|
||||
public decimal? DayuseBase { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 钟点房基本价
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "base_price")]
|
||||
public decimal? BasePrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 每小时单价
|
||||
/// </summary>
|
||||
public decimal? Hourly { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 钟点房最长时间
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "dayuse_top")]
|
||||
public decimal? DayuseTop { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 钟点房选项(可手动录入):T/F
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "dayuse_flag")]
|
||||
public string DayuseFlag { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 排序号(升序)
|
||||
/// </summary>
|
||||
public int? Sequence { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 大房类
|
||||
/// </summary>
|
||||
public string Stype { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客房打扫工作量
|
||||
/// </summary>
|
||||
public decimal? Mone1 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 中央预定最大可用房数
|
||||
/// </summary>
|
||||
public decimal? Mone2 { get; set; }
|
||||
|
||||
public string Char1 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房类描述
|
||||
/// </summary>
|
||||
public string Char2 { get; set; }
|
||||
|
||||
public DateTime? Date1 { get; set; }
|
||||
|
||||
public DateTime? Date2 { get; set; }
|
||||
|
||||
// <summary>
|
||||
// x7不存在
|
||||
// </summary>
|
||||
//public string Defpackage { get; set; }
|
||||
}
|
||||
}
|
||||
34
api_v1/Appointment.Entity/Model/Saleid.cs
Normal file
34
api_v1/Appointment.Entity/Model/Saleid.cs
Normal file
@@ -0,0 +1,34 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 销售人员表实体
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
public class Saleid
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public string Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 姓名
|
||||
/// </summary>
|
||||
public string Name { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 其他描述
|
||||
/// </summary>
|
||||
public string Descript { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 对应操作员,注意:uc_login也添加了Saleid,两种对应方式,有点重复了
|
||||
/// </summary>
|
||||
public string Op_id { get; set; }
|
||||
}
|
||||
}
|
||||
35
api_v1/Appointment.Entity/Model/SysCode.cs
Normal file
35
api_v1/Appointment.Entity/Model/SysCode.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 综合数据
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("sys_code")]
|
||||
public class SysCode
|
||||
{
|
||||
/// <summary>
|
||||
/// 类型
|
||||
/// </summary>
|
||||
public string Class { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 编号
|
||||
/// </summary>
|
||||
public string Id { get; set; }
|
||||
|
||||
public string Descript1 { get; set; }
|
||||
|
||||
public string Descript2 { get; set; }
|
||||
|
||||
public string Remark { get; set; }
|
||||
|
||||
public string System { get; set; }
|
||||
|
||||
public int Sequence { get; set; }
|
||||
}
|
||||
}
|
||||
33
api_v1/Appointment.Entity/Model/UcGroup.cs
Normal file
33
api_v1/Appointment.Entity/Model/UcGroup.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 用户组别
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("uc_group")]
|
||||
public class UcGroup
|
||||
{
|
||||
/// <summary>
|
||||
/// 代码
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "op_group")]
|
||||
public string OpGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 名称
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "descript")]
|
||||
public string Descript { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 描述
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "op_func")]
|
||||
public string OpFunc { get; set; }
|
||||
}
|
||||
}
|
||||
153
api_v1/Appointment.Entity/Model/UcLogin.cs
Normal file
153
api_v1/Appointment.Entity/Model/UcLogin.cs
Normal file
@@ -0,0 +1,153 @@
|
||||
using Appointment.Entity.ValidateAttribute;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 工作人员
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[SugarTable("uc_login")]
|
||||
public class UcLogin
|
||||
{
|
||||
/// <summary>
|
||||
/// 账号
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, ColumnName = "op_id")]
|
||||
public string OpId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 姓名
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, ColumnName = "op_name")]
|
||||
public string OpName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 密码
|
||||
/// </summary>
|
||||
public string Password { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组别
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true, ColumnName = "op_group")]
|
||||
public string OpGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 部门
|
||||
/// </summary>
|
||||
public string Deptno { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 账号锁定:T/F
|
||||
/// </summary>
|
||||
public string Locked { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 密码提示
|
||||
/// </summary>
|
||||
public string Question { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 提示答案
|
||||
/// </summary>
|
||||
public string Answer { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public int X { get; set; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public int Y { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public int Width { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public int Height { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string Winstate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string Tips { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 登录显示邮件提示
|
||||
/// </summary>
|
||||
public string Mail { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string Font { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string Text { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string Pop { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 员工工号
|
||||
/// </summary>
|
||||
public string Errinfo { get; set; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 手机号
|
||||
/// </summary>
|
||||
public string Mobile { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 微信小程序openid
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "wxopenId")]
|
||||
public string WxOpenId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户所属销售员
|
||||
/// </summary>
|
||||
public string Saleid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 授权服务号状态,用于消息推送
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "wx_service_id")]
|
||||
public string WxServiceId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// OA是否可做为被转审人
|
||||
/// </summary>
|
||||
public string Appttrans { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// OA是否可做为被抄送人
|
||||
/// </summary>
|
||||
public string Apptsend { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 部门备注自动发送以#隔离
|
||||
/// </summary>
|
||||
public string Autosendcond { get; set; }
|
||||
}
|
||||
}
|
||||
732
api_v1/Appointment.Entity/Model/_data/迪联OA预定补丁(含转审抄送).sql
Normal file
732
api_v1/Appointment.Entity/Model/_data/迪联OA预定补丁(含转审抄送).sql
Normal file
@@ -0,0 +1,732 @@
|
||||
|
||||
|
||||
-- <20><>Ա<EFBFBD><D4B1>
|
||||
if not exists (select 1 from syscolumns where name = 'wxopenid' and id = (select id from sysobjects where name = 'uc_login'))
|
||||
ALTER TABLE uc_login add wxopenid varchar(100) null -- <><CEA2>С<EFBFBD><D0A1><EFBFBD><EFBFBD>Ψһ<CEA8><D2BB><EFBFBD><EFBFBD>
|
||||
;
|
||||
if not exists (select 1 from syscolumns where name = 'wx_service_id' and id = (select id from sysobjects where name = 'uc_login'))
|
||||
ALTER TABLE uc_login add wx_service_id varchar(100) null -- <>ŷ<EFBFBD><C5B7><EFBFBD><EFBFBD><EFBFBD>Ψһ<CEA8><D2BB><EFBFBD><EFBFBD>֤
|
||||
;
|
||||
if not exists (select 1 from syscolumns where name = 'saleid' and id = (select id from sysobjects where name = 'uc_login'))
|
||||
ALTER TABLE uc_login add saleid varchar(4) null -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ա<EFBFBD><D4B1><EFBFBD><EFBFBD>
|
||||
;
|
||||
if not exists (select 1 from syscolumns where name = 'appttrans' and id = (select id from sysobjects where name = 'uc_login'))
|
||||
ALTER TABLE uc_login add appttrans char(1) null -- OA<4F>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><CEAA>ת<EFBFBD><D7AA><EFBFBD><EFBFBD>
|
||||
;
|
||||
if not exists (select 1 from syscolumns where name = 'apptsend' and id = (select id from sysobjects where name = 'uc_login'))
|
||||
ALTER TABLE uc_login add apptsend char(1) null -- OA<4F>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><CEAA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
;
|
||||
if not exists (select 1 from syscolumns where name = 'autosendcond' and id = (select id from sysobjects where name = 'uc_login'))
|
||||
ALTER TABLE uc_login add autosendcond varchar(500) null -- <20>Զ<EFBFBD><D4B6><EFBFBD><EFBFBD><EFBFBD> <20><>#<23><><EFBFBD><EFBFBD>
|
||||
;
|
||||
--Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
if object_id('appt_type') is null --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>жϣ<EFBFBD><EFBFBD><EFBFBD>SQL<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ǿ<EFBFBD><EFBFBD>Է<EFBFBD><EFBFBD><EFBFBD>ִ<EFBFBD>е<EFBFBD>
|
||||
CREATE TABLE appt_type( -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
[Id] [int] IDENTITY(1,1) PRIMARY key , --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֱ<EFBFBD><EFBFBD>д<EFBFBD><EFBFBD><EFBFBD>ֶκ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>У<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ӷȣ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>߿ɶ<EFBFBD><EFBFBD><EFBFBD>
|
||||
[appt_name] [varchar](30) NULL, -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
[remark] [varchar](200) NULL -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͱ<EFBFBD>ע
|
||||
)
|
||||
;
|
||||
if not exists (select 1 from appt_type) --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>жϣ<EFBFBD><EFBFBD><EFBFBD>SQL<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ǿ<EFBFBD><EFBFBD>Է<EFBFBD><EFBFBD><EFBFBD>ִ<EFBFBD>е<EFBFBD>
|
||||
INSERT INTO appt_type (appt_name,remark)VALUES('Ĭ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>','')
|
||||
;
|
||||
|
||||
--Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̱<EFBFBD>
|
||||
if object_id('appt_auditor') is null create table appt_auditor( -- Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
[id] [int] IDENTITY(1,1) PRIMARY key , -- <20><><EFBFBD><EFBFBD>
|
||||
[appt_type_id] [int] NULL, -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
[op_group] [varchar](30) NULL, -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<28><>Ϊ<EFBFBD><CEAA>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD>ɲ<EFBFBD><C9B2><EFBFBD>)
|
||||
[op_descript] [varchar](50) NULL, -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
[pid] [int] NULL, -- (ȫ<>¿ɸ<C2BF><C9B8><EFBFBD>Ϊoper_seq)<29><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˳<EFBFBD><CBB3>[<5B>ɲ<EFBFBD><C9B2><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:0-<2D>ײ㣬<D7B2><E3A3AC>ϵ<EFBFBD><CFB5>ǰ<EFBFBD><C7B0><EFBFBD><EFBFBD><EFBFBD><EFBFBD>]
|
||||
|
||||
[custom] int default(0) not null -- <20>Ƿ<EFBFBD>֧<EFBFBD><D6A7>ת<EFBFBD><D7AA><EFBFBD><EFBFBD>0-<2D><>֧<EFBFBD><D6A7>,1-֧<><D6A7>(<28><>ת<EFBFBD><D7AA>֮<EFBFBD><EFBFBD><F3A3ACB2>ٻص<D9BB><D8B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>)
|
||||
);
|
||||
if not exists (select 1 from sysobjects as t join syscolumns as c on t.id=c.id where t.name='appt_auditor' and c.name='rejectid')
|
||||
alter table appt_auditor add [rejectid] int default(1); -- <20><><EFBFBD>ػص<D8BB><D8B5>Ľڵ<C4BD>
|
||||
|
||||
|
||||
--Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
if object_id('appt_summary') is null
|
||||
CREATE TABLE appt_summary( --Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
[id] int IDENTITY(1,1) PRIMARY KEY --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[guid] nvarchar(50) not null --GUID
|
||||
,[userid] nvarchar(20) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>û<EFBFBD>
|
||||
,[createtime] datetime default getdate() NOT NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD><EFBFBD>
|
||||
,[appt_typeid] int NULL --Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>[appt_type.id]<EFBFBD><EFBFBD>0-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
,[auditor_status] int NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>״̬:0-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>,1-<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,2-<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,3-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͨ<EFBFBD><EFBFBD>(<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʽԤ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>),4-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>,
|
||||
,[auditor_id] int NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɫid:0-<EFBFBD><EFBFBD>
|
||||
,[transfer_audit] nvarchar(50) default('')
|
||||
,[appt_type] int default 0 not NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD>ֶ<EFBFBD>
|
||||
,[no] nvarchar(50) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
,[buyer_name] nvarchar(50) NULL --<EFBFBD><EFBFBD>֯<EFBFBD><EFBFBD>λ
|
||||
,[buyer_address] nvarchar(200) NULL --<EFBFBD><EFBFBD>˾<EFBFBD><EFBFBD>ַ
|
||||
,[buyer_title] nvarchar(100) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[leader_name] nvarchar(20) NULL --<EFBFBD><EFBFBD>֯<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[leader_mobile] nvarchar(20) NULL --<EFBFBD><EFBFBD>֯<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˵绰
|
||||
|
||||
,[leader_room] nvarchar(50) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>鷿<EFBFBD><EFBFBD>
|
||||
,[sale_name] nvarchar(20) NULL --Ӫ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[sale_mobile] nvarchar(20) NULL --Ӫ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>绰
|
||||
,[sale_director] nvarchar(20) NULL --Ӫ<EFBFBD><EFBFBD><EFBFBD>ܼ<EFBFBD>(<EFBFBD>ֹ<EFBFBD>д)<EFBFBD><EFBFBD>
|
||||
,[room_remark] nvarchar(200) NULL --<EFBFBD>ͷ<EFBFBD><EFBFBD>ܱ<EFBFBD>ע
|
||||
|
||||
,[meeting_remark] nvarchar(200) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ܱ<EFBFBD>ע
|
||||
,[catering_remark] nvarchar(200) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ܱ<EFBFBD>ע
|
||||
,[spring_remark] nvarchar(200) NULL --<EFBFBD><EFBFBD>Ȫ<EFBFBD>ܱ<EFBFBD>ע
|
||||
,[pid] int default(0) not null -- <20>༭ǰ<E0BCAD><C7B0><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,ԭʼ<D4AD><CABC><EFBFBD>ݴ<EFBFBD>appt_log<6F><67><EFBFBD>ж<EFBFBD>ȡ
|
||||
,[grp_no] nvarchar(100) null -- <20>Ŷӱ<C5B6><D3B1><EFBFBD>
|
||||
|
||||
,[start_day] datetime null -- Ԥ<><D4A4><EFBFBD><EFBFBD>Ϣ<EFBFBD><CFA2>С<EFBFBD><D0A1>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD>
|
||||
,[end_day] datetime null -- Ԥ<><D4A4><EFBFBD><EFBFBD>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[apply_oa] int default(0) -- <20><><EFBFBD><EFBFBD>OA<4F><41>״̬:0-δռ<CEB4><D5BC><EFBFBD><EFBFBD>Դ,1-ռ<><D5BC><EFBFBD><EFBFBD>Դ,2-<2D><><EFBFBD><EFBFBD>OA<4F><41>
|
||||
,[alter_time] datetime not null -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>
|
||||
)
|
||||
;
|
||||
|
||||
--<EFBFBD>ͷ<EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϸ<EFBFBD><EFBFBD>
|
||||
if object_id('appt_room') is null
|
||||
CREATE TABLE appt_room( -- <20>ͷ<EFBFBD>
|
||||
[id] int IDENTITY(1,1) PRIMARY KEY --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[guid] nvarchar(50) not null --GUID
|
||||
,[appt_id] int NOT NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[room_in] datetime NULL --<EFBFBD>ִ<EFBFBD>ʱ<EFBFBD><EFBFBD>
|
||||
,[room_out] datetime NULL --<EFBFBD>뿪ʱ<EFBFBD><EFBFBD>
|
||||
|
||||
,[room_group] nvarchar(50) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѡ<EFBFBD><EFBFBD><EFBFBD>Զ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>)<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>䲻ռ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Դ
|
||||
,[room_code] nvarchar(20) NULL--ѡ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱΪ<EFBFBD><EFBFBD>,<EFBFBD><EFBFBD>ռ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Դ)
|
||||
,[room_num] int NOT NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[room_price] money default 0 NOT NULL--<EFBFBD><EFBFBD><EFBFBD>䵥<EFBFBD><EFBFBD>
|
||||
,[breakfast_num] int NOT NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:0-<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,
|
||||
|
||||
,[long_distance] int NOT NULL--<EFBFBD><EFBFBD>;<EFBFBD>绰:0-<EFBFBD>أ<EFBFBD>1-<EFBFBD><EFBFBD>,
|
||||
,[min_shop] int NOT NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD>:0-<EFBFBD><EFBFBD>,1-<EFBFBD><EFBFBD>,
|
||||
,[remark] nvarchar(200) NULL --<EFBFBD>ͷ<EFBFBD><EFBFBD><EFBFBD>ע
|
||||
)
|
||||
;
|
||||
|
||||
--<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϸ<EFBFBD><EFBFBD>
|
||||
if object_id('appt_meeting') is null
|
||||
CREATE TABLE appt_meeting(
|
||||
[id] int IDENTITY(1,1) PRIMARY KEY --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[guid] nvarchar(50) not null --GUID
|
||||
,[appt_id] int NOT NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[meeting_time] datetime NULL-- <20><><EFBFBD><EFBFBD><EFBFBD>볡<EFBFBD><EBB3A1><EFBFBD><EFBFBD>
|
||||
,[groups] nvarchar(50) NOT NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>:1-<EFBFBD><EFBFBD>,2-<EFBFBD><EFBFBD>,3-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[meeting_room] nvarchar(50) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѡ<EFBFBD><EFBFBD><EFBFBD>Զ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>)<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>䲻ռ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Դ
|
||||
|
||||
,[meeting_code] nvarchar(20) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱΪ<EFBFBD><EFBFBD>,<EFBFBD><EFBFBD>ռ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Դ)
|
||||
,[meeting_rostrum] nvarchar(50) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϯ̨λ
|
||||
,[meeting_shape] nvarchar(50) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>-̨<EFBFBD><EFBFBD>(<EFBFBD><EFBFBD><EFBFBD><EFBFBD>)
|
||||
,[meeting_num] int NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>:0-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>,
|
||||
,[meeting_price] money default 0 not NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
,[meeting_title] nvarchar(50) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:<EFBFBD><EFBFBD>-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>,
|
||||
,[remark] nvarchar(200) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ע
|
||||
)
|
||||
;
|
||||
|
||||
--<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϸ<EFBFBD><EFBFBD>
|
||||
if object_id('appt_catering') is null
|
||||
CREATE TABLE appt_catering(
|
||||
[id] int IDENTITY(1,1) PRIMARY KEY --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[guid] nvarchar(50) not null --GUID
|
||||
,[appt_id] int NOT NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[catering_time] datetime NOT NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[groups] nvarchar(50) NOT NULL --<EFBFBD>ͱ<EFBFBD>:1-<EFBFBD><EFBFBD>,2-<EFBFBD><EFBFBD>,3-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[catering_room] nvarchar(50) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
,[catering_code] nvarchar(50) NULL--<EFBFBD>ò͵ص<EFBFBD>
|
||||
,[catering_type] int default 0 not null -- <20>ò<EFBFBD><C3B2><EFBFBD><EFBFBD><EFBFBD> 0-<2D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1-<2D><><EFBFBD><EFBFBD>
|
||||
,[catering_num] int default 1 not null -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[catering_price] money default 0 not NULL--ÿ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ÿ<EFBFBD>˵<EFBFBD><EFBFBD><EFBFBD>
|
||||
,[catering_table] nvarchar(50) NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD>-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
,[wine] nvarchar(50) NULL--<EFBFBD><EFBFBD>ˮ
|
||||
,[remark] nvarchar(200) NULL --<EFBFBD><EFBFBD>ע
|
||||
)
|
||||
;
|
||||
--<EFBFBD><EFBFBD>ȪԤ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϸ<EFBFBD><EFBFBD>
|
||||
if object_id('appt_spring') is null
|
||||
CREATE TABLE appt_spring(
|
||||
[id] int IDENTITY(1,1) PRIMARY KEY --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[guid] nvarchar(50) not null --GUID
|
||||
,[appt_id] int NOT NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[spring_time] datetime NULL --<EFBFBD><EFBFBD>Ȫ_<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[people_num] int NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<EFBFBD>Զ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>):0-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[spring_men] int NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:0-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
,[spring_women] int NULL--Ů<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:0-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[consume] nvarchar(50) NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[spring_price] money default 0 not NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[remark] nvarchar(200) NULL --<EFBFBD><EFBFBD>ע
|
||||
)
|
||||
;
|
||||
--Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ע<EFBFBD><EFBFBD>չ<EFBFBD><EFBFBD>
|
||||
if object_id('appt_remark') is null
|
||||
CREATE TABLE appt_remark(
|
||||
[id] int IDENTITY(1,1) PRIMARY KEY --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[guid] nvarchar(50) not null --GUID
|
||||
,[appt_id] int NOT NULL --Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ע
|
||||
,[title] nvarchar(50) NULL--<EFBFBD><EFBFBD>ע<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[info] nvarchar(500) NULL --<EFBFBD><EFBFBD>ע<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
)
|
||||
;
|
||||
-- Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>¼<EFBFBD><C2BC><EFBFBD><EFBFBD><EFBFBD>ͱ<EFBFBD>
|
||||
if object_id('appt_audit_log') is null
|
||||
CREATE TABLE appt_audit_log(
|
||||
[id] int IDENTITY(1,1) PRIMARY KEY --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[type] int NOT NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>:1-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>,2-<EFBFBD><EFBFBD><EFBFBD>ͣ<EFBFBD>
|
||||
,[createtime] datetime default getdate() NOT NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD><EFBFBD>
|
||||
,[userid] nvarchar(20) NOT NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ա/<EFBFBD><EFBFBD><EFBFBD>ͽ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[appt_id] int NOT NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
,[auditor_status] int NOT NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD>״̬:1-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͨ<EFBFBD><EFBFBD>,0-<EFBFBD><EFBFBD><EFBFBD><EFBFBD>,2-ת<EFBFBD><EFBFBD><EFBFBD><EFBFBD>,3-<EFBFBD>ֶ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Զ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[remark] nvarchar(200) NULL--<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ע
|
||||
,[pic0] nvarchar(max) -- ͼƬ0
|
||||
,[pic1] nvarchar(max) -- ͼƬ1
|
||||
,[pic2] nvarchar(max) -- ͼƬ2
|
||||
|
||||
,[pic3] nvarchar(max) -- ͼƬ3
|
||||
,[pic4] nvarchar(max) -- ͼƬ4
|
||||
,[source] nvarchar(20) NULL --<EFBFBD><EFBFBD><EFBFBD>ͷ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[pid] int not null default 0 -- <20><><EFBFBD>ظ<EFBFBD><D8B8>ĸ<EFBFBD><C4B8><EFBFBD><EFBFBD><EFBFBD>
|
||||
)
|
||||
;
|
||||
--<EFBFBD><EFBFBD>־<EFBFBD><EFBFBD>
|
||||
if object_id('appt_log') is null
|
||||
CREATE TABLE appt_log(
|
||||
[id] [int] IDENTITY(1,1) PRIMARY KEY, --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
[tableName] [varchar](100) NULL,-- <20><><EFBFBD>ݱ<EFBFBD>
|
||||
[keyId] [varchar](100) NULL, --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֵ
|
||||
[oldData] [varchar](2000) NULL, --ԭʼ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
[newData] [varchar](2000) NULL, --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
[createTime] [datetime] default getdate() NOT NULL, --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD><EFBFBD>
|
||||
[userId] [nvarchar](20) NULL, --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
[systemUser] [int] NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:0-<EFBFBD><EFBFBD>ͨ<EFBFBD>û<EFBFBD>,1-<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ա
|
||||
)
|
||||
;
|
||||
--<EFBFBD><EFBFBD><EFBFBD><EFBFBD>չʾ<EFBFBD><EFBFBD>־
|
||||
if object_id('appt_remark_log') is null
|
||||
CREATE TABLE appt_remark_log(
|
||||
[id] [int] IDENTITY(1,1) PRIMARY KEY --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[createTime] [datetime] default getdate() NOT NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD><EFBFBD>
|
||||
,[pid] [int] default(0) not null -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[appt_id] [int] NOT NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[account] [nvarchar](20) not null --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˺<EFBFBD>
|
||||
|
||||
,[username] [nvarchar](20) null --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[old_status] [int] not null -- <20>ύǰ״̬
|
||||
,[new_status] [int] not null -- <20>ύ<EFBFBD><E1BDBB>״̬
|
||||
,[remark] [varchar](2000) NULL --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˱<EFBFBD>ע<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
,[update_data] [varchar](2000) NULL, --<EFBFBD><EFBFBD><EFBFBD>ݱ仯
|
||||
)
|
||||
;
|
||||
|
||||
-- <20><><EFBFBD><EFBFBD><EFBFBD>ڶ<EFBFBD>ȡÿ<C8A1>տ<EFBFBD><D5BF>۷<EFBFBD><DBB7><EFBFBD>
|
||||
|
||||
if object_id('p_yyj_ota_type_rsv_tend') is not null
|
||||
drop proc p_yyj_ota_type_rsv_tend;
|
||||
|
||||
create proc p_yyj_ota_type_rsv_tend
|
||||
@rm_type varchar(255), -- <20><><EFBFBD>Ͳ<EFBFBD><CDB2><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Զ<EFBFBD>ѡ<EFBFBD><D1A1><EFBFBD><EFBFBD>#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>#BJ#DJ# , Ҳ<><D2B2><EFBFBD><EFBFBD><EFBFBD><EFBFBD> % <20><><EFBFBD><EFBFBD>ȫ<EFBFBD><C8AB><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
@s_time datetime, -- <20><>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD>
|
||||
@e_time datetime, -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
@tentative char(1) = 'T' -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ȷ<EFBFBD><C8B7> OTAĬ<41>ϴ<EFBFBD><CFB4><EFBFBD> T
|
||||
|
||||
as
|
||||
update room_type set sequence = 10 where sequence = 0
|
||||
select @s_time = convert(datetime, convert(char(10), @s_time, 111))
|
||||
select @e_time = convert(datetime, convert(char(10), @e_time, 111))
|
||||
|
||||
declare
|
||||
@result int
|
||||
-- ------------------------------------------------------------------------------------
|
||||
-- <20><><EFBFBD><EFBFBD>ֵ<EFBFBD><D6B5><EFBFBD><EFBFBD>
|
||||
-- ------------------------------------------------------------------------------------
|
||||
create table #inventory --<2D><><EFBFBD><EFBFBD><EFBFBD>̷<EFBFBD><CCB7><EFBFBD>ֵ
|
||||
(
|
||||
date datetime null, --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
type char(3) null, --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
sequence int null, --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
quan int null --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
)
|
||||
create table #tmp
|
||||
(
|
||||
type char(3) null,
|
||||
quan int null
|
||||
)
|
||||
|
||||
declare @type char(3),
|
||||
@tennum int
|
||||
|
||||
-- ƴ<>ַ<EFBFBD><D6B7><EFBFBD>
|
||||
if @rm_type='%'
|
||||
begin
|
||||
select @rm_type='#'
|
||||
select @type=isnull((select min(id) from room_type where id>''), '')
|
||||
while @type <> ''
|
||||
begin
|
||||
select @rm_type = @rm_type+substring(@type+space(3), 1, 3)+'#'
|
||||
select @type=isnull((select min(id) from room_type where id>@type ), '')
|
||||
end
|
||||
end
|
||||
else
|
||||
select @rm_type = '#'+@rm_type+'#' --ǿ<EFBFBD>Ƽ<EFBFBD><EFBFBD><EFBFBD>YYJ
|
||||
|
||||
|
||||
while @s_time <= @e_time
|
||||
begin
|
||||
|
||||
|
||||
-- <20><><EFBFBD>Ȳ<EFBFBD><C8B2><EFBFBD>Ԥ<EFBFBD><D4A4>
|
||||
if @tentative = 'T'
|
||||
begin
|
||||
|
||||
insert #inventory select @s_time, c.id, 0,
|
||||
quan=isnull((select sum(a.rooms) from rsvinfo a, mstinfo b
|
||||
where charindex('#'+substring(a.type+' ',1,3)+'#',@rm_type)>0 and a.begin_<>a.end_ and a.begin_<=@s_time and a.end_>@s_time and substring(a.accnt,1,1) <> 'G%'
|
||||
and a.accnt=b.accnt and (a.roomno is null or a.roomno='') and c.id = b.type
|
||||
and b.sta in ('R','I')
|
||||
),0) + (select isnull(count(distinct a.roomno),0) from rsvinfo a, mstinfo b
|
||||
where charindex('#'+substring(a.type+' ',1,3)+'#',@rm_type)>0 and a.begin_<>a.end_ and a.begin_<=@s_time and a.end_>@s_time and substring(a.accnt,1,1) <> 'G%'
|
||||
and a.accnt=b.accnt and a.roomno is not null and a.roomno<>'' and c.id = b.type
|
||||
and b.sta in ('R','I'))
|
||||
from room_type c where charindex('#'+substring(c.id+' ',1,3)+'#', @rm_type) > 0
|
||||
|
||||
end
|
||||
else
|
||||
begin
|
||||
delete #tmp
|
||||
insert #inventory select @s_time, c.id, 0,
|
||||
quan=isnull((select sum(a.rooms) from rsvinfo a, mstinfo b
|
||||
where charindex('#'+substring(a.type+' ',1,3)+'#',@rm_type)>0 and a.begin_<>a.end_ and a.begin_<=@s_time and a.end_>@s_time and substring(a.accnt,1,1) <> 'G%'
|
||||
and a.accnt=b.accnt and (a.roomno is null or a.roomno='') and c.id = b.type
|
||||
and b.sta in ('R','I') and b.resclass not in (select id from sys_code where class='resclass' and charindex('Tentative',remark)>0)
|
||||
),0) + (select isnull(count(distinct a.roomno),0) from rsvinfo a, mstinfo b
|
||||
where charindex('#'+substring(a.type+' ',1,3)+'#',@rm_type)>0 and a.begin_<>a.end_ and a.begin_<=@s_time and a.end_>@s_time and substring(a.accnt,1,1) <> 'G%'
|
||||
and a.accnt=b.accnt and a.roomno is not null and a.roomno<>'' and c.id = b.type
|
||||
and b.sta in ('R','I') and b.resclass not in (select id from sys_code where class='resclass' and charindex('Tentative',remark)>0))
|
||||
from room_type c where charindex('#'+substring(c.id+' ',1,3)+'#', @rm_type) > 0
|
||||
|
||||
end
|
||||
|
||||
-- modi by shr 2014.4.3
|
||||
update #inventory set #inventory.quan =(select isnull(count(c.roomno),0) from room_list c where #inventory.type=C.type and
|
||||
c.tag1 <> 'VR') - #inventory.quan where #inventory.date = @s_time and #inventory.type<>'TEN'
|
||||
|
||||
update #inventory set #inventory.quan = #inventory.quan - (select isnull(count(1),0) from room_oo b where b.sta='I' and b.type='OO'
|
||||
and b.bdate <= @s_time and b.edate > @s_time and b.rmtype = #inventory.type)
|
||||
where #inventory.date = @s_time and #inventory.type<>'TEN'
|
||||
|
||||
-- YYJ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ռ<EFBFBD><D5BC><EFBFBD><EFBFBD><EFBFBD>ӳ<EFBFBD>Ԥ<EFBFBD><D4A4><EFBFBD>ۼ<EFBFBD>
|
||||
if exists(select 1 from sys_option where catalog = 'reserver' and item = 'rsvtendovr' and rtrim(value)='T')
|
||||
update #inventory set #inventory.quan = #inventory.quan + (select isnull(sum(exceed),0) from room_type b where b.id = #inventory.type)
|
||||
where #inventory.date = @s_time and #inventory.type<>'TEN'
|
||||
|
||||
|
||||
|
||||
select @s_time = dateadd(day, 1, @s_time)
|
||||
end
|
||||
|
||||
|
||||
update #inventory set sequence = a.sequence from room_type a where rtrim(#inventory.type)=rtrim(a.id)
|
||||
select a.date,a.type,a.sequence,a.quan
|
||||
from #inventory a order by a.date, a.sequence
|
||||
|
||||
return 0
|
||||
;
|
||||
if object_id('p_yyj_grpadd_inter') is not null
|
||||
drop proc p_yyj_grpadd_inter ;
|
||||
|
||||
create proc p_yyj_grpadd_inter
|
||||
@gname varchar(50) , --<EFBFBD>Ŷ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
@leader char(20), --<EFBFBD><EFBFBD><EFBFBD>ӻ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>λ<EFBFBD><EFBFBD><EFBFBD>ϵ<EFBFBD><EFBFBD>
|
||||
@phone char(20), --<EFBFBD><EFBFBD><EFBFBD>ӵ绰
|
||||
@arr datetime , --<EFBFBD>ִ<EFBFBD>ʱ<EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>ں<EFBFBD>ʱ<EFBFBD>䣬<EFBFBD><EFBFBD>2019-01-17 18:00:00
|
||||
@dep datetime, --<EFBFBD>뿪ʱ<EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>ں<EFBFBD>ʱ<EFBFBD>䣬<EFBFBD><EFBFBD>2019-01-18 14:00:00
|
||||
@rooms integer, --<EFBFBD>Ŷ<EFBFBD><EFBFBD>ܹ<EFBFBD><EFBFBD>ķ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ע<EFBFBD><EFBFBD>ֻ<EFBFBD>DZ<EFBFBD>ע<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ռ<EFBFBD>÷<EFBFBD><EFBFBD>䣩
|
||||
@guests integer, --<EFBFBD>Ŷӵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ע<EFBFBD><EFBFBD>ֻ<EFBFBD>DZ<EFBFBD>ע<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ռ<EFBFBD>÷<EFBFBD><EFBFBD>䣩
|
||||
@remark varchar(255), --<EFBFBD>Ŷ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ע
|
||||
@log_id char(5), --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD>ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Աû<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ĺ<EFBFBD><EFBFBD>ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>д<EFBFBD><EFBFBD><EFBFBD>һ<EFBFBD><EFBFBD>ͨ<EFBFBD>õĹ<EFBFBD><EFBFBD><EFBFBD>
|
||||
@log_ip char(16), --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ի<EFBFBD><EFBFBD>߽ӿڵ<EFBFBD><EFBFBD>Ե<EFBFBD>IP<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ÿ<EFBFBD><EFBFBD>ַ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ַ<EFBFBD><EFBFBD><EFBFBD>
|
||||
@saleid char(4) --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD>ţ<EFBFBD><EFBFBD>ڵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>۲˵<EFBFBD><EFBFBD>¿<EFBFBD><EFBFBD>Դ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD>ã<EFBFBD><EFBFBD>鿴<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ա<EFBFBD>Ĺ<EFBFBD><EFBFBD>ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><EFBFBD><EFBFBD>ַ<EFBFBD><EFBFBD><EFBFBD>
|
||||
as
|
||||
|
||||
declare
|
||||
@resno char(10) ,
|
||||
@accnt varchar(10),
|
||||
@msg varchar(60),
|
||||
@ret integer ,
|
||||
@sysdate datetime,
|
||||
@newno char(10)
|
||||
|
||||
select @ret = 0
|
||||
select @msg = ''
|
||||
|
||||
if rtrim(isnull(@gname,'')) = ''
|
||||
select @msg = '<EFBFBD>Ŷ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ʋ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'
|
||||
if @arr = null or @dep= null
|
||||
select @msg = '<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD>䲻<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><EFBFBD>'
|
||||
if @rooms = null or @rooms=0
|
||||
select @rooms =1
|
||||
if @guests = null or @guests=0
|
||||
select @guests =1
|
||||
if datediff(dd,@arr,@dep)<1
|
||||
select @msg = '<EFBFBD>뿪<EFBFBD><EFBFBD><EFBFBD>ڱ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ס<EFBFBD><EFBFBD><EFBFBD><EFBFBD>'
|
||||
|
||||
if @msg <> ''
|
||||
begin
|
||||
select @ret = 1
|
||||
select @ret , @msg
|
||||
return @ret
|
||||
end
|
||||
|
||||
select @sysdate = sysdate from sys_data
|
||||
select @resno = no from sys_acctno where class ='reserve'
|
||||
select @accnt = no from sys_acctno where class ='group'
|
||||
|
||||
if exists (select 1 from grpinfo where accnt =@accnt)
|
||||
begin
|
||||
select @accnt = "G0" + right("00000" + convert(varchar(4),convert(integer,right(max(rtrim(accnt)),4))+1),5) from grpinfo
|
||||
end
|
||||
|
||||
insert grpinfo( accnt,sta, gname,src,mkt,arr,dep,country, leader,phone,guests,rooms,cropsno,cropname,paycode,
|
||||
ramark,sysdate,log_num,log_id,log_shift,log_ip,log_date,navite,address,payroom,ename,resno,
|
||||
grpno,payaccnt,code,vip,sec,special,araccnt,saleid)
|
||||
select @accnt,'R',@gname,'LOC','GRP',@arr,@dep,'CN',@leader,@phone,@guests,@rooms,'','','9001',
|
||||
@remark, @sysdate,0,@log_id,'1',@log_ip,getdate(),'','','<EFBFBD>Ŷ<EFBFBD>','',@resno,
|
||||
@accnt,@accnt,'G','0','0','','',@saleid
|
||||
|
||||
if exists (select 1 from grpinfo where accnt =@accnt)
|
||||
begin
|
||||
select @newno = "G0" + right("00000" + convert(varchar(4),convert(integer,(right(rtrim(@accnt),4))) + 1),5)
|
||||
update sys_acctno set no = @newno where class ='group'
|
||||
select @newno = "R0" + right("00000" + convert(varchar(4),convert(integer,(right(rtrim(@resno),4))) + 1),5)
|
||||
update sys_acctno set no =@newno where class ='reserve'
|
||||
end
|
||||
select @ret = 0
|
||||
select @msg = @accnt
|
||||
select @ret,@msg
|
||||
return @ret
|
||||
;
|
||||
|
||||
if object_id('p_yyj_grpmeet_inter') is not null
|
||||
drop proc p_yyj_grpmeet_inter;
|
||||
|
||||
create proc p_yyj_grpmeet_inter
|
||||
@accnt char(7), --<EFBFBD>Ŷ<EFBFBD><EFBFBD>˺ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ŷ<EFBFBD>ʱ<EFBFBD><EFBFBD><EFBFBD>ã<EFBFBD>
|
||||
@date datetime, --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ֻҪ<EFBFBD><EFBFBD><EFBFBD>ڲ<EFBFBD><EFBFBD><EFBFBD>Ҫʱ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
@rescode varchar(3), --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ұ<EFBFBD><EFBFBD><EFBFBD>,<EFBFBD><EFBFBD><EFBFBD>Դӵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>鿴<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>res_code<EFBFBD><EFBFBD>ȡ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>code<EFBFBD>ֶ<EFBFBD>
|
||||
@sfield integer, --<EFBFBD><EFBFBD><EFBFBD>Σ<EFBFBD> 0<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ȫ<EFBFBD><EFBFBD> 1<EFBFBD><EFBFBD><EFBFBD>糡 2<EFBFBD><EFBFBD><EFBFBD>糡 3<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
@price money, --<EFBFBD>۸<EFBFBD><EFBFBD>Դӵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>鿴<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>res_code<EFBFBD><EFBFBD>ȡprice<EFBFBD>ֶΣ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֶ<EFBFBD>ΪԤ<EFBFBD><EFBFBD><EFBFBD>ο<EFBFBD><EFBFBD>ۣ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>嶩<EFBFBD><EFBFBD><EFBFBD>۸<EFBFBD><EFBFBD>Ըò<EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><EFBFBD>
|
||||
@op_id char(5) --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD>ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Աû<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ĺ<EFBFBD><EFBFBD>ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>д<EFBFBD><EFBFBD><EFBFBD>һ<EFBFBD><EFBFBD>ͨ<EFBFBD>õĹ<EFBFBD><EFBFBD><EFBFBD>
|
||||
as
|
||||
|
||||
|
||||
declare
|
||||
@sysno char(6) ,
|
||||
@maxno integer ,
|
||||
@no char(10),
|
||||
@bdate datetime ,
|
||||
@op_name varchar(16),
|
||||
@sfieldtime varchar(5),
|
||||
@efieldtime varchar(5)
|
||||
|
||||
if not exists( select 1 from grpinfo where sta in ('I','R') and accnt = @accnt )
|
||||
begin
|
||||
select 1,'<EFBFBD>Ŷ<EFBFBD><EFBFBD>˺<EFBFBD> ' + @accnt + '<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ч״̬'
|
||||
return 1
|
||||
end
|
||||
if exists (select 1 from res_info where @date>=stime and @date<=etime and rescode = @rescode and (sfield = @sfield or sfield=0 or @sfield=0) and sta in ('R','O'))
|
||||
begin
|
||||
select 1,'<EFBFBD>û<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѱ<EFBFBD>Ԥ<EFBFBD><EFBFBD>!'
|
||||
return 1
|
||||
end
|
||||
select @op_name = op_name from uc_login where op_id = @op_id
|
||||
select @bdate = sysdate from sys_data
|
||||
select @sysno = convert ( char ( 6 ) , getdate ( ) , 12 ) from sys_data
|
||||
select @maxno = isnull ( max ( convert ( int , substring ( no , 7 , 4 ) ) ) , 0 ) + 1 from res_info where
|
||||
substring ( no , 1 , 6 ) =convert ( char ( 6 ) , getdate ( ) , 12 )
|
||||
select @no = @sysno + right('0000' + convert(varchar(4),@maxno),4)
|
||||
if @sfield = 0
|
||||
begin
|
||||
select @sfieldtime = '08:30'
|
||||
select @efieldtime = '22:30'
|
||||
end
|
||||
else if @sfield = 1
|
||||
begin
|
||||
select @sfieldtime = '08:30'
|
||||
select @efieldtime = '11:30'
|
||||
end
|
||||
else if @sfield = 2
|
||||
begin
|
||||
select @sfieldtime = '13:00'
|
||||
select @efieldtime = '17:30'
|
||||
end
|
||||
else if @sfield = 3
|
||||
begin
|
||||
select @sfieldtime = '19:30'
|
||||
select @efieldtime = '22:30'
|
||||
end
|
||||
|
||||
|
||||
|
||||
INSERT INTO res_info select
|
||||
@no,'R',@accnt,'',@rescode,1,@bdate,@date,@date,@sfield,@sfield,
|
||||
@sfieldtime,@efieldtime,NULL,@price,@price,'F',@op_id,@op_name,
|
||||
getdate(),NULL,NULL,NULL,0
|
||||
if @@rowcount = 1
|
||||
select 0,'<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD>ɹ<EFBFBD>!'
|
||||
else
|
||||
select 1,'<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD>ʧ<EFBFBD>ܣ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>!'
|
||||
return 0
|
||||
;
|
||||
|
||||
if object_id('p_yyj_gblock_inter') is not null
|
||||
drop proc p_yyj_gblock_inter ;
|
||||
create proc p_yyj_gblock_inter
|
||||
@log_id char(5), --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD>ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Աû<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ĺ<EFBFBD><EFBFBD>ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>д<EFBFBD><EFBFBD><EFBFBD>һ<EFBFBD><EFBFBD>ͨ<EFBFBD>õĹ<EFBFBD><EFBFBD>ţ<EFBFBD>
|
||||
@log_ip char(16), --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ի<EFBFBD><EFBFBD>߽ӿڵ<EFBFBD><EFBFBD>Ե<EFBFBD>IP<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ÿ<EFBFBD><EFBFBD>ַ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ַ<EFBFBD><EFBFBD><EFBFBD>
|
||||
@grpno char(7), --<EFBFBD>Ŷ<EFBFBD><EFBFBD>˺ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ŷ<EFBFBD>ʱ<EFBFBD><EFBFBD><EFBFBD>ã<EFBFBD>
|
||||
@arr datetime, --<EFBFBD>ִ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ֻҪ<EFBFBD><EFBFBD><EFBFBD>ڲ<EFBFBD><EFBFBD><EFBFBD>Ҫʱ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
@dep datetime, --<EFBFBD>뿪<EFBFBD><EFBFBD><EFBFBD><EFBFBD> ֻҪ<EFBFBD><EFBFBD><EFBFBD>ڲ<EFBFBD><EFBFBD><EFBFBD>Ҫʱ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
@type char(3), --<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>룬<EFBFBD><EFBFBD>BJ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>鿴<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƶ<EFBFBD>ϵͳ<EFBFBD>з<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
@rooms integer, --Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><EFBFBD>ʵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƶ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>᷵<EFBFBD>ش<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣ
|
||||
@price money, --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
@guests integer, -- һ<><D2BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ס<EFBFBD><D7A1><EFBFBD><EFBFBD><EFBFBD>ˣ<EFBFBD>Ĭ<EFBFBD><C4AC>Ϊ1
|
||||
@remark varchar(255), --<EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD>ı<EFBFBD>ע<EFBFBD><EFBFBD><EFBFBD>ŷ<EFBFBD>ʱ<EFBFBD><EFBFBD><EFBFBD>Կ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>˱<EFBFBD>ע
|
||||
@rmcode char(4) --<EFBFBD>밴<EFBFBD><EFBFBD>Ĭ<EFBFBD>ϵ<EFBFBD>RACK<EFBFBD><EFBFBD>д<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
as
|
||||
declare
|
||||
@ret integer,
|
||||
@accnt char(10),
|
||||
@resno char(10),
|
||||
@sysdate datetime,
|
||||
@price0 money,
|
||||
@log_name char(12),
|
||||
@mkt char(3),
|
||||
@src char(3),
|
||||
@gname varchar(50),
|
||||
@ename char(50),
|
||||
@country char(3),
|
||||
@vip char(2),
|
||||
@sec char(2),
|
||||
@cropsno char(7),
|
||||
@special varchar(50),
|
||||
@saleid char(4),
|
||||
@araccnt char(10),
|
||||
@msg varchar(60),
|
||||
@deptime varchar(8),
|
||||
@postopen char(1),
|
||||
@rmpackage varchar(50),
|
||||
@ooo integer,
|
||||
@blk integer,
|
||||
@avl integer
|
||||
|
||||
select @rmpackage = ''
|
||||
select @postopen = isnull(value,'') from sys_option where catalog = 'group' and item = 'postopen'
|
||||
if @postopen is null
|
||||
set @postopen = 'F'
|
||||
if charindex(@postopen,'TF') = 0
|
||||
set @postopen = 'F'
|
||||
|
||||
if not exists( select 1 from grpinfo where sta in ('I','R') and accnt = @grpno )
|
||||
begin
|
||||
select @ret=1, @msg = '<EFBFBD>Ŷ<EFBFBD><EFBFBD>˺<EFBFBD> ' + @grpno + '<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ч״̬'
|
||||
select @ret, @msg
|
||||
return @ret
|
||||
end
|
||||
select @ooo = 0
|
||||
select @blk=0
|
||||
select @avl=0
|
||||
exec p_xx_reserve_chkavail @type,@arr,@dep,'N',@ooo out ,@blk out ,@avl out,''
|
||||
if @avl is null or @avl<@rooms
|
||||
begin
|
||||
select @ret=@avl, @msg = '<EFBFBD>÷<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Դ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>'
|
||||
select @ret, @msg
|
||||
return @ret
|
||||
end
|
||||
|
||||
select @sysdate = sysdate from sys_data
|
||||
select @log_name = op_name from uc_login where op_id=@log_id
|
||||
select @src=src,@mkt=mkt,@gname=gname,@ename=ename,@country=country,@resno=rtrim(resno),@vip=vip,@sec=sec,
|
||||
@cropsno=cropsno,@special=special,@saleid=saleid,@araccnt=araccnt from grpinfo where accnt = @grpno
|
||||
if @resno is null
|
||||
exec p_xx_pub_getno 'RESE',@resno output
|
||||
|
||||
select @deptime = deptime from mkt_deptime where id = 'GRP' and isnull(flag,'') = 'T'
|
||||
if @deptime <> '' and @deptime is not null
|
||||
begin
|
||||
select @dep = convert(datetime,(rtrim(left(convert(varchar,@dep,120),10)) + ' ' + @deptime))
|
||||
end
|
||||
|
||||
select @price0 = price0 from room_type where id=@type
|
||||
exec p_xx_pub_getno 'ACCT',@accnt output
|
||||
|
||||
insert mstinfo(accnt,grpno,sta,src,mkt,sysdate,resno,arr,dep,type,roomno,price0,price,rooms,numbs,gname,ename,sex,
|
||||
vip,sec,cropsno,special,saleid,araccnt,country,rmcode,remark,log_id,log_name,log_shift,log_ip,log_date,logmark,res,restime,idcls,rmpackage,flag)
|
||||
select @accnt,@grpno,'R',@src,@mkt,@sysdate,@resno,@arr,@dep,@type,'',@price0,@price,@rooms,@guests,@gname,@ename,'M',
|
||||
@vip,@sec,@cropsno,@special,@saleid,@araccnt,@country,@rmcode,@remark,@log_id,@log_name,'1',@log_ip,getdate(),0,@log_id,getdate(),'01',@rmpackage,@postopen
|
||||
|
||||
|
||||
select @ret = 0, @msg = '<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD>ɹ<EFBFBD>'
|
||||
select @ret, @msg
|
||||
return @ret
|
||||
;
|
||||
|
||||
if object_id('p_xx_res_info_view3') is not null
|
||||
drop proc p_xx_res_info_view3 ;
|
||||
create proc p_xx_res_info_view3
|
||||
@startday datetime,
|
||||
@enddate datetime,
|
||||
@sort varchar(3),
|
||||
@accnt varchar(10) = '%'
|
||||
as
|
||||
|
||||
declare
|
||||
@rdate datetime,
|
||||
@accnt1 varchar(10)
|
||||
if exists(select 1 from mstinfo where accnt=@accnt)
|
||||
select @accnt1=grpno from mstinfo where accnt=@accnt
|
||||
select @rdate=@startday
|
||||
|
||||
CREATE TABLE #query (
|
||||
code varchar(6) not null,
|
||||
descript char(20) null,
|
||||
sort char(3) null,
|
||||
day11 char(2) null,
|
||||
day12 char(2) null,
|
||||
day13 char(2) null,
|
||||
day21 char(2) null,
|
||||
day22 char(2) null,
|
||||
day23 char(2) null,
|
||||
day31 char(2) null,
|
||||
day32 char(2) null,
|
||||
day33 char(2) null,
|
||||
day41 char(2) null,
|
||||
day42 char(2) null,
|
||||
day43 char(2) null,
|
||||
day51 char(2) null,
|
||||
day52 char(2) null,
|
||||
day53 char(2) null,
|
||||
day61 char(2) null,
|
||||
day62 char(2) null,
|
||||
day63 char(2) null,
|
||||
day71 char(2) null,
|
||||
day72 char(2) null,
|
||||
day73 char(2) null,
|
||||
day81 char(2) null,
|
||||
day82 char(2) null,
|
||||
day83 char(2) null,
|
||||
day91 char(2) null,
|
||||
day92 char(2) null,
|
||||
day93 char(2) null
|
||||
)
|
||||
|
||||
insert #query (code,descript,sort)
|
||||
select code,descript1,sort from res_code where sta='T' and sort like @sort
|
||||
|
||||
CREATE TABLE #tblav (
|
||||
rescode char(4) not null,
|
||||
bdate datetime not null,
|
||||
sfield int null,
|
||||
accnt varchar(10) null,
|
||||
accnt1 varchar(10) null,
|
||||
sta char(1) not null)
|
||||
insert #tblav(rescode,bdate,sfield,accnt,accnt1,sta)
|
||||
select rescode,stime,sfield,accnt,accnt1,min(sta) from res_info where sta in ('R','O')
|
||||
group by rescode,stime,sfield,accnt,accnt1
|
||||
order by rescode,stime,sfield,accnt,accnt1
|
||||
|
||||
update #tblav set sta='S' where accnt=@accnt or accnt1=@accnt1
|
||||
|
||||
select @rdate=dateadd(day,0,@startday)
|
||||
|
||||
update #query set #query.day11=b.sta + '0' from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=0
|
||||
|
||||
update #query set #query.day11=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=1
|
||||
update #query set #query.day12=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=2
|
||||
update #query set #query.day13=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=3
|
||||
|
||||
select @rdate=dateadd(day,1,@startday)
|
||||
update #query set #query.day21=b.sta + '0' from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=0
|
||||
|
||||
update #query set #query.day21=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=1
|
||||
update #query set #query.day22=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=2
|
||||
update #query set #query.day23=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=3
|
||||
|
||||
select @rdate=dateadd(day,2,@startday)
|
||||
update #query set #query.day31=b.sta + '0' from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=0
|
||||
update #query set #query.day31=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=1
|
||||
update #query set #query.day32=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=2
|
||||
update #query set #query.day33=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=3
|
||||
|
||||
select @rdate=dateadd(day,3,@startday)
|
||||
update #query set #query.day41=b.sta + '0' from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=0
|
||||
update #query set #query.day41=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=1
|
||||
update #query set #query.day42=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=2
|
||||
update #query set #query.day43=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=3
|
||||
|
||||
select @rdate=dateadd(day,4,@startday)
|
||||
update #query set #query.day51=b.sta + '0' from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=0
|
||||
update #query set #query.day51=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=1
|
||||
update #query set #query.day52=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=2
|
||||
update #query set #query.day53=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=3
|
||||
|
||||
select @rdate=dateadd(day,5,@startday)
|
||||
update #query set #query.day61=b.sta + '0' from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=0
|
||||
update #query set #query.day61=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=1
|
||||
update #query set #query.day62=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=2
|
||||
update #query set #query.day63=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=3
|
||||
|
||||
select @rdate=dateadd(day,6,@startday)
|
||||
update #query set #query.day71=b.sta + '0' from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=0
|
||||
update #query set #query.day71=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=1
|
||||
update #query set #query.day72=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=2
|
||||
update #query set #query.day73=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=3
|
||||
|
||||
select @rdate=dateadd(day,7,@startday)
|
||||
update #query set #query.day81=b.sta + '0' from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=0
|
||||
update #query set #query.day81=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=1
|
||||
update #query set #query.day82=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=2
|
||||
update #query set #query.day83=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=3
|
||||
|
||||
select @rdate=dateadd(day,8,@startday)
|
||||
update #query set #query.day91=b.sta + '0' from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=0
|
||||
update #query set #query.day91=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=1
|
||||
update #query set #query.day92=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=2
|
||||
update #query set #query.day93=b.sta from #tblav b where #query.code=b.rescode and datediff(dd,b.bdate,@rdate)=0 and b.sfield=3
|
||||
|
||||
select sort,code,descript,day11,day12,day13,day21,day22,day23,day31,day32,day33,day41,day42,day43,day51,day52,day53,
|
||||
day61,day62,day63,day71,day72,day73,day81,day82,day83,day91,day92,day93 from #query order by sort,code
|
||||
return 0
|
||||
;
|
||||
|
||||
-- ȡ<><C8A1><EFBFBD><EFBFBD>Դռ<D4B4>ô洢<C3B4><E6B4A2><EFBFBD><EFBFBD>
|
||||
if object_id('p_yyj_gblock_cancel') is not null
|
||||
drop proc p_yyj_gblock_cancel;
|
||||
|
||||
create proc p_yyj_gblock_cancel
|
||||
@accnt char(7), --<EFBFBD>Ŷ<EFBFBD><EFBFBD>˺ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ŷ<EFBFBD>ʱ<EFBFBD><EFBFBD><EFBFBD>ã<EFBFBD>
|
||||
@op_id char(5) --<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD>ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Աû<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ĺ<EFBFBD><EFBFBD>ţ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>д<EFBFBD><EFBFBD><EFBFBD>һ<EFBFBD><EFBFBD>ͨ<EFBFBD>õĹ<EFBFBD><EFBFBD><EFBFBD>
|
||||
as
|
||||
declare
|
||||
@op_name varchar(16),
|
||||
@sysdate datetime,
|
||||
@ret integer,
|
||||
@msg varchar(60)
|
||||
|
||||
--<EFBFBD>ù<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ȡ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ŷӵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ԥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Դ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>䡢<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
select @sysdate = sysdate from sys_data
|
||||
select @op_name = op_name from uc_login where op_id = @op_id
|
||||
update res_info set sta='C',cby = @op_id , cbyname = @op_name,cbytime=getdate(),logmark = logmark +1 where accnt = @accnt
|
||||
update mstinfo set sta='C',log_id =@op_id , log_shift ='1', log_date =getdate() ,log_name = @op_name,
|
||||
logmark = logmark+1 where grpno = @accnt
|
||||
select @ret = 0, @msg = '<EFBFBD><EFBFBD>Դȡ<EFBFBD><EFBFBD><EFBFBD>ɹ<EFBFBD>'
|
||||
select @ret, @msg
|
||||
return @ret
|
||||
;
|
||||
356
api_v1/Appointment.Entity/Request/ApptJNCReq.cs
Normal file
356
api_v1/Appointment.Entity/Request/ApptJNCReq.cs
Normal file
@@ -0,0 +1,356 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
#region 添加
|
||||
/// <summary>
|
||||
/// 创建订单入参
|
||||
/// </summary>
|
||||
public class AddSummaryJncReq : ApptSummary
|
||||
{
|
||||
/// <summary>
|
||||
/// [必填] 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDes { get; set; }
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 修改暂定单
|
||||
public class UpdateSummaryReq : ApptSummary
|
||||
{
|
||||
/// <summary>
|
||||
/// [必填] 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDes { get; set; }
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 申请确定单
|
||||
/// <summary>
|
||||
/// 申请确定单入参 | 预定部对预定单进行审批通过 | 其他部门审批通过 | 驳回
|
||||
/// </summary>
|
||||
public class ApplyOrderReq
|
||||
{
|
||||
/// <summary>
|
||||
/// [必填] 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDes { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// [必填] 预订单主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 申请确定单备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 申请确定单图片备注(最多5张)
|
||||
/// </summary>
|
||||
public List<string> RemarkPics { get; set; }
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 获取实体
|
||||
|
||||
/// <summary>
|
||||
/// 获取实体入参 | 订单对比 | 根据回复编号获取回复中的图片列表
|
||||
/// </summary>
|
||||
public class SummaryJncModelReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDes { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订单主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
}
|
||||
|
||||
|
||||
public class SummaryJncDetailRep : ApptSummary
|
||||
{
|
||||
public string UserName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 图标状态:0-未提交,1-审核中,2-通过,3-驳回;4-取消;
|
||||
/// </summary>
|
||||
public int IconStatus { get; set; }
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 分页
|
||||
|
||||
/// <summary>
|
||||
/// 分页入参
|
||||
/// </summary>
|
||||
public class SummaryJNCPageReq
|
||||
{
|
||||
/// <summary>
|
||||
/// [必填]客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDES { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 当前页从1开始(默认1)
|
||||
/// </summary>
|
||||
public int PageIndex { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 页大小(默认10)
|
||||
/// </summary>
|
||||
public int PageSize { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 查询标签
|
||||
/// </summary>
|
||||
public int Menu { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 开始日期(包含当日,默认全部)[格式 2021-06-24]
|
||||
/// </summary>
|
||||
public string StartDay { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 截止日期(包含当日,默认全部)[格式 2021-06-24]
|
||||
/// </summary>
|
||||
public string EndDay { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订单编号
|
||||
/// </summary>
|
||||
public string No { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 搜索
|
||||
/// </summary>
|
||||
public string KeyWord { get; set; }
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 生成确认单
|
||||
/// <summary>
|
||||
/// 生成确认单入参
|
||||
/// </summary>
|
||||
public class CreateOrderReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDes { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订单主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 审核订单
|
||||
public class CheckerOrderReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDes { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订单主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核状态:1-审核通过,2-驳回
|
||||
/// </summary>
|
||||
public int Status { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
/// 销售员修改确订单或驳回订单入参
|
||||
/// </summary>
|
||||
public class UpdateOrderBySaleReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDes { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订单主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
|
||||
public class AuditorLogReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 是否有审核权限:0-否,1-是,
|
||||
/// </summary>
|
||||
public int Authority { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否有修改权限:0-否,1-是,
|
||||
/// </summary>
|
||||
public int UpdateStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否可提交审核:0-不可,1-可以,
|
||||
/// </summary>
|
||||
public int SubmitStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否显示生成完成单:0-不显示,1-显示
|
||||
/// </summary>
|
||||
public int SumbitFinish { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 取消订单功能显示:0-不显示,1-显示
|
||||
/// </summary>
|
||||
public int SumbitCancel { get; set; }
|
||||
|
||||
public List<AuditorLogDataReq> AuditorLog { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 返回的日志记录
|
||||
/// </summary>
|
||||
public class AuditorLogDataReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 日志编号
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 标题
|
||||
/// </summary>
|
||||
public string Title { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 状态:1-已操作,2-待操作
|
||||
/// </summary>
|
||||
public int Status { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 修改信息
|
||||
/// </summary>
|
||||
public List<string> Info { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 图片
|
||||
/// </summary>
|
||||
public List<string> PicList { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 手动回复的信息列表
|
||||
/// </summary>
|
||||
public List<ReplyResp> ReplyList { get; set; }
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 手动回复信息 数据类型
|
||||
/// </summary>
|
||||
public class ReplyResp
|
||||
{
|
||||
/// <summary>
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
public DateTime CreateTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核人员/抄送接收人/回复操作人
|
||||
/// </summary>
|
||||
public string UserName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 回复信息内容的主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 图片数量
|
||||
/// </summary>
|
||||
public int PicNum { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 订单数据对比返回数据类型
|
||||
/// </summary>
|
||||
public class DisparityReq
|
||||
{
|
||||
public string Title { get; set; }
|
||||
|
||||
public DateTime Time { get; set; }
|
||||
|
||||
public List<string> Info { get; set; }
|
||||
}
|
||||
|
||||
public class CompareSummaryReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDes { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 订单的guid
|
||||
/// </summary>
|
||||
public string Guid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 状态:0-获取暂订单与最新确认单的对比,
|
||||
/// </summary>
|
||||
public int Status { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 信息回复 入参
|
||||
/// </summary>
|
||||
public class AddMsgReq
|
||||
{
|
||||
/// <summary>
|
||||
/// [必填] 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDes { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 被回复的主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 回复内容
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 图片
|
||||
/// </summary>
|
||||
public List<string> PicList { get; set; }
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
29
api_v1/Appointment.Entity/Request/ApptSendReq.cs
Normal file
29
api_v1/Appointment.Entity/Request/ApptSendReq.cs
Normal file
@@ -0,0 +1,29 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public class ApptSendReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 被抄送的预订主键
|
||||
/// </summary>
|
||||
public int ApptId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDES { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 抄送到账号
|
||||
/// </summary>
|
||||
public string[] ToUserAccounts { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 抄送备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
}
|
||||
380
api_v1/Appointment.Entity/Request/ApptSummaryReq - 复制.cs
Normal file
380
api_v1/Appointment.Entity/Request/ApptSummaryReq - 复制.cs
Normal file
@@ -0,0 +1,380 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订申请提交表单
|
||||
/// </summary>
|
||||
public class ApptSummaryReq1
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 客户端保存用户信息
|
||||
///// </summary>
|
||||
//public string AccountDES { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 组织单位
|
||||
///// </summary>
|
||||
//public string BuyerName { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 公司地址
|
||||
///// </summary>
|
||||
//public string BuyerAddress { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 会议名称
|
||||
///// </summary>
|
||||
//public string BuyerTitle { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 组织负责人
|
||||
///// </summary>
|
||||
//public string LeaderName { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 组织负责人电话
|
||||
///// </summary>
|
||||
//public string LeaderMobile { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 会议组房号
|
||||
///// </summary>
|
||||
//public string LeaderRoom { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 客房总备注
|
||||
///// </summary>
|
||||
//public string RoomRemark { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 议室总备注
|
||||
///// </summary>
|
||||
//public string MeetingRemark { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 餐饮总备注
|
||||
///// </summary>
|
||||
//public string CateringRemark { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 温泉总备注
|
||||
///// </summary>
|
||||
//public string SpringRemark { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 驳回备注
|
||||
///// </summary>
|
||||
//public string RebutRemark { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 会议室预订明细列表
|
||||
///// </summary>
|
||||
////public List<ApptMeetingReq1> ApptMeetingList { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 客房预订明细列表
|
||||
///// </summary>
|
||||
////public List<ApptRoomReq1> ApptRoomList { get; set; }
|
||||
|
||||
|
||||
///// <summary>
|
||||
///// 餐饮预订明细列表
|
||||
///// </summary>
|
||||
////public List<ApptCateringReq1> ApptCateringList { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 温泉预订明细列表
|
||||
///// </summary>
|
||||
////public List<ApptSpringReq1> ApptSpringList { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 其他备注
|
||||
///// </summary>
|
||||
////public List<RemarkReq1> Remarks { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 提交人
|
||||
///// </summary>
|
||||
//public string UserId { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 销售人员姓名
|
||||
///// </summary>
|
||||
//public string SaleName { get; set; }
|
||||
|
||||
|
||||
///// <summary>
|
||||
///// 销售人员姓名电话
|
||||
///// </summary>
|
||||
//public string SalePhone { get; set; }
|
||||
|
||||
|
||||
///// <summary>
|
||||
///// 审核状态:1-待审核,2-审核中,3-审核通过,4-驳回,
|
||||
///// </summary>
|
||||
//public int? AuditorStatus { get; set; }
|
||||
|
||||
///// <summary>
|
||||
///// 创建时间
|
||||
///// </summary>
|
||||
////public DateTime CreateTime { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 会议室预订明细
|
||||
/// </summary>
|
||||
public class ApptMeetingReq1
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议入场日期
|
||||
/// </summary>
|
||||
public DateTime? MeetingTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 场次:1-早,2-中,3-晚
|
||||
/// </summary>
|
||||
public int[] MeetingGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议厅名称(手输或根据类型选择自动填入),手输不占用资源
|
||||
/// </summary>
|
||||
public string MeetingRoom { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议厅代码(手输类型时为空,不占用资源)
|
||||
/// </summary>
|
||||
public string MeetingCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议室主席台位
|
||||
/// </summary>
|
||||
public string MeetingRostrum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议室-台型(课桌)
|
||||
/// </summary>
|
||||
public string MeetingShape { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 人数:0-待定,
|
||||
/// </summary>
|
||||
public int? MeetingNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单价
|
||||
/// </summary>
|
||||
public decimal? MeetingPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 横幅内容:
|
||||
/// </summary>
|
||||
public string MeetingTitle { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议厅备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 客房预订明细
|
||||
/// </summary>
|
||||
public class ApptRoomReq1
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 抵达时间
|
||||
/// </summary>
|
||||
public DateTime? RoomIn { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 离开时间
|
||||
/// </summary>
|
||||
public DateTime? RoomOut { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房型(手输或根据类型选择自动填入),手输不占用资源
|
||||
/// </summary>
|
||||
public string RoomGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 选择房间类型(手输类型时为空,不占用资源)
|
||||
/// </summary>
|
||||
public string RooomCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房间数量
|
||||
/// </summary>
|
||||
public int? RoomNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房间单价[当输入为0时,会根据房类代码获取优惠价]
|
||||
/// </summary>
|
||||
public decimal? RoomPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总早餐数:0-无早餐,
|
||||
/// </summary>
|
||||
public int? BreakfastNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 长途电话:0-关,1-开,
|
||||
/// </summary>
|
||||
public int? LongDistance { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房吧:0-关,1-开,
|
||||
/// </summary>
|
||||
public int? MinShop { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总温泉数:0-无,
|
||||
/// </summary>
|
||||
public int? SpringNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客房备注
|
||||
/// </summary>
|
||||
public string RoomRemark { get; set; }
|
||||
}
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 餐饮预订明细
|
||||
/// </summary>
|
||||
public class ApptCateringReq1
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用餐日期
|
||||
/// </summary>
|
||||
public DateTime? CateringTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 场次:1-早,2-中,3-晚
|
||||
/// </summary>
|
||||
public int[] CateringGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 餐厅名称(手输或根据类型选择自动填入),手输不占用资源
|
||||
/// </summary>
|
||||
public string CateringRoom { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用餐地点(手输类型时为空,不占用资源)
|
||||
/// </summary>
|
||||
public string CateringCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用餐类型 0-桌数,1-人数
|
||||
/// </summary>
|
||||
public int CateringType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 桌数或人数数量
|
||||
/// </summary>
|
||||
public int CateringNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 每桌或每人单价
|
||||
/// </summary>
|
||||
public decimal CateringPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 桌型
|
||||
/// </summary>
|
||||
public string CateringTable { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 酒水
|
||||
/// </summary>
|
||||
public string Wine { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 温泉预订明细
|
||||
/// </summary>
|
||||
public class ApptSpringReq1
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 温泉_日期
|
||||
/// </summary>
|
||||
public DateTime? SpringTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总人数(自动计算):0-待定
|
||||
/// </summary>
|
||||
public int? PeopleNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// spring_men
|
||||
/// </summary>
|
||||
public int? SpringMen { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 女性人数:0-待定
|
||||
/// </summary>
|
||||
public int? SpringWomen { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 二次消费
|
||||
/// </summary>
|
||||
public string Consume { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单价
|
||||
/// </summary>
|
||||
public decimal? SpringPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
|
||||
public class RemarkReq1
|
||||
{
|
||||
/// <summary>
|
||||
/// 备注名称
|
||||
/// </summary>
|
||||
public string RemarkName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注内容
|
||||
/// </summary>
|
||||
public string RemarkContent { get; set; }
|
||||
}
|
||||
}
|
||||
381
api_v1/Appointment.Entity/Request/ApptSummaryReq.cs
Normal file
381
api_v1/Appointment.Entity/Request/ApptSummaryReq.cs
Normal file
@@ -0,0 +1,381 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订申请提交表单
|
||||
/// </summary>
|
||||
public class ApptSummaryReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDES { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组织单位
|
||||
/// </summary>
|
||||
public string BuyerName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 公司地址
|
||||
/// </summary>
|
||||
public string BuyerAddress { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议名称
|
||||
/// </summary>
|
||||
public string BuyerTitle { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组织负责人
|
||||
/// </summary>
|
||||
public string LeaderName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组织负责人电话
|
||||
/// </summary>
|
||||
public string LeaderMobile { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议组房号
|
||||
/// </summary>
|
||||
public string LeaderRoom { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客房总备注
|
||||
/// </summary>
|
||||
public string RoomRemark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 议室总备注
|
||||
/// </summary>
|
||||
public string MeetingRemark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 餐饮总备注
|
||||
/// </summary>
|
||||
public string CateringRemark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 温泉总备注
|
||||
/// </summary>
|
||||
public string SpringRemark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 驳回备注
|
||||
/// </summary>
|
||||
public string RebutRemark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议室预订明细列表
|
||||
/// </summary>
|
||||
public List<ApptMeetingReq> ApptMeetingList { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客房预订明细列表
|
||||
/// </summary>
|
||||
public List<ApptRoomReq> ApptRoomList { get; set; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 餐饮预订明细列表
|
||||
/// </summary>
|
||||
public List<ApptCateringReq> ApptCateringList { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 温泉预订明细列表
|
||||
/// </summary>
|
||||
public List<ApptSpringReq> ApptSpringList { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 其他备注
|
||||
/// </summary>
|
||||
public List<RemarkReq> Remarks { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 提交人
|
||||
/// </summary>
|
||||
public string UserId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 销售人员姓名
|
||||
/// </summary>
|
||||
public string SaleName { get; set; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 销售人员姓名电话
|
||||
/// </summary>
|
||||
public string SalePhone { get; set; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 审核状态:1-待审核,2-审核中,3-审核通过,4-驳回,
|
||||
/// </summary>
|
||||
public int? AuditorStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
public DateTime CreateTime { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 会议室预订明细
|
||||
/// </summary>
|
||||
public class ApptMeetingReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议入场日期
|
||||
/// </summary>
|
||||
public DateTime? MeetingTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 场次:1-上午,2-下午,3-晚上
|
||||
/// </summary>
|
||||
public int[] MeetingGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议厅名称(手输或根据类型选择自动填入),手输不占用资源
|
||||
/// </summary>
|
||||
public string MeetingRoom { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议厅代码(手输类型时为空,不占用资源)
|
||||
/// </summary>
|
||||
public string MeetingCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议室主席台位
|
||||
/// </summary>
|
||||
public string MeetingRostrum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议室-台型(课桌)
|
||||
/// </summary>
|
||||
public string MeetingShape { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 人数:0-待定,
|
||||
/// </summary>
|
||||
public int? MeetingNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单价
|
||||
/// </summary>
|
||||
public decimal? MeetingPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 横幅内容:
|
||||
/// </summary>
|
||||
public string MeetingTitle { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 会议厅备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 客房预订明细
|
||||
/// </summary>
|
||||
public class ApptRoomReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 抵达时间
|
||||
/// </summary>
|
||||
public DateTime? RoomIn { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 离开时间
|
||||
/// </summary>
|
||||
public DateTime? RoomOut { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房型(手输或根据类型选择自动填入),手输不占用资源
|
||||
/// </summary>
|
||||
public string RoomGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 选择房间类型(手输类型时为空,不占用资源)
|
||||
/// </summary>
|
||||
public string RooomCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房间数量
|
||||
/// </summary>
|
||||
public int? RoomNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房间单价[当输入为0时,会根据房类代码获取优惠价]
|
||||
/// </summary>
|
||||
public decimal? RoomPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总早餐数:0-无早餐,
|
||||
/// </summary>
|
||||
public int? BreakfastNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 长途电话:0-关,1-开,
|
||||
/// </summary>
|
||||
public int? LongDistance { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房吧:0-关,1-开,
|
||||
/// </summary>
|
||||
public int? MinShop { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总温泉数:0-无,
|
||||
/// </summary>
|
||||
public int? SpringNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客房备注
|
||||
/// </summary>
|
||||
public string RoomRemark { get; set; }
|
||||
}
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 餐饮预订明细
|
||||
/// </summary>
|
||||
public class ApptCateringReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用餐日期
|
||||
/// </summary>
|
||||
public DateTime? CateringTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 晚上
|
||||
/// 场次:1-上午,2-下午,3-晚上
|
||||
/// </summary>
|
||||
public int[] CateringGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 餐厅名称(手输或根据类型选择自动填入),手输不占用资源
|
||||
/// </summary>
|
||||
public string CateringRoom { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用餐地点(手输类型时为空,不占用资源)
|
||||
/// </summary>
|
||||
public string CateringCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用餐类型 0-桌数,1-人数
|
||||
/// </summary>
|
||||
public int CateringType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 桌数或人数数量
|
||||
/// </summary>
|
||||
public int CateringNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 每桌或每人单价
|
||||
/// </summary>
|
||||
public decimal CateringPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 桌型
|
||||
/// </summary>
|
||||
public string CateringTable { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 酒水
|
||||
/// </summary>
|
||||
public string Wine { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 温泉预订明细
|
||||
/// </summary>
|
||||
public class ApptSpringReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 自增主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 温泉_日期
|
||||
/// </summary>
|
||||
public DateTime? SpringTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总人数(自动计算):0-待定
|
||||
/// </summary>
|
||||
public int? PeopleNum { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// spring_men
|
||||
/// </summary>
|
||||
public int? SpringMen { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 女性人数:0-待定
|
||||
/// </summary>
|
||||
public int? SpringWomen { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 二次消费
|
||||
/// </summary>
|
||||
public string Consume { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单价
|
||||
/// </summary>
|
||||
public decimal? SpringPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
|
||||
public class RemarkReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 备注名称
|
||||
/// </summary>
|
||||
public string RemarkName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注内容
|
||||
/// </summary>
|
||||
public string RemarkContent { get; set; }
|
||||
}
|
||||
}
|
||||
22
api_v1/Appointment.Entity/Request/ApptTypeAddReq.cs
Normal file
22
api_v1/Appointment.Entity/Request/ApptTypeAddReq.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订类型添加
|
||||
/// </summary>
|
||||
public class ApptTypeAddReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 类型名称
|
||||
/// </summary>
|
||||
public string ApptName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 备注说明
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
}
|
||||
19
api_v1/Appointment.Entity/Request/ApptUsableMeetingReq.cs
Normal file
19
api_v1/Appointment.Entity/Request/ApptUsableMeetingReq.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public class ApptUsableMeetingReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 启始时间(默认从昨天开始)
|
||||
/// </summary>
|
||||
public string Startday { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 截止时间(默认截止到3个月后)
|
||||
/// </summary>
|
||||
public string EndDay { get; set; }
|
||||
}
|
||||
}
|
||||
22
api_v1/Appointment.Entity/Request/AuditDeleteReq.cs
Normal file
22
api_v1/Appointment.Entity/Request/AuditDeleteReq.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 删除预订请求参数
|
||||
/// </summary>
|
||||
public class AuditDeleteReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 要删除的预订对应的主键
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 删除的类型:1-预订主单与详情,2-客房详情,3-会议详情,4-餐饮详情,5-温泉详情
|
||||
/// </summary>
|
||||
public int Type { get; set; }
|
||||
}
|
||||
}
|
||||
32
api_v1/Appointment.Entity/Request/AuditReq.cs
Normal file
32
api_v1/Appointment.Entity/Request/AuditReq.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订审核
|
||||
/// </summary>
|
||||
public class ApptAuditReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 要审核的主键
|
||||
/// </summary>
|
||||
public int ApptId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDES { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核状态:1-审核通过,0-驳回,
|
||||
/// </summary>
|
||||
public int AuditorStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核说明
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
}
|
||||
17
api_v1/Appointment.Entity/Request/BindUserReq.cs
Normal file
17
api_v1/Appointment.Entity/Request/BindUserReq.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 绑定用户
|
||||
/// </summary>
|
||||
public class BindUserReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 客户端保留用户信息
|
||||
/// </summary>
|
||||
public string AccountDES { get; set; }
|
||||
}
|
||||
}
|
||||
43
api_v1/Appointment.Entity/Request/CommReq.cs
Normal file
43
api_v1/Appointment.Entity/Request/CommReq.cs
Normal file
@@ -0,0 +1,43 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 日期时间
|
||||
/// </summary>
|
||||
public class CommDayReq
|
||||
{
|
||||
public DateTime Date { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// int型
|
||||
/// </summary>
|
||||
public class CommIntReq
|
||||
{
|
||||
public int? IntValue { get; set; }
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// id
|
||||
/// </summary>
|
||||
public class CommIntIdReq
|
||||
{
|
||||
public int Id { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页
|
||||
/// </summary>
|
||||
public class CommPageReq
|
||||
{
|
||||
public int PageIndex { get; set; }
|
||||
|
||||
public int PageSize { get; set; }
|
||||
|
||||
public string Keywords { get; set; }
|
||||
}
|
||||
}
|
||||
28
api_v1/Appointment.Entity/Request/MeetingReq.cs
Normal file
28
api_v1/Appointment.Entity/Request/MeetingReq.cs
Normal file
@@ -0,0 +1,28 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// 获取会议室资源
|
||||
/// </summary>
|
||||
public class MeetingReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 起始时间
|
||||
/// </summary>
|
||||
public DateTime StartDay { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 截止时间(包含当天)
|
||||
/// </summary>
|
||||
public DateTime EndDay { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客户端保留用户信息
|
||||
/// </summary>
|
||||
public string AccountDES { get; set; }
|
||||
}
|
||||
}
|
||||
35
api_v1/Appointment.Entity/Request/MyApptApplyPageReq.cs
Normal file
35
api_v1/Appointment.Entity/Request/MyApptApplyPageReq.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 我发起的预订
|
||||
/// </summary>
|
||||
public class MyApptApplyPageReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 当前页从1开始
|
||||
/// </summary>
|
||||
public int PageIndex { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 页大小
|
||||
/// </summary>
|
||||
public int PageSize { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDES { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核状态:null/0-全部,1-审订中,2-审核通过,3-驳回,6-取消
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// EnumAuditorStatus
|
||||
/// </remarks>
|
||||
public int? AuditorStatus { get; set; }
|
||||
}
|
||||
}
|
||||
35
api_v1/Appointment.Entity/Request/MyApptAuditPageReq.cs
Normal file
35
api_v1/Appointment.Entity/Request/MyApptAuditPageReq.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 与我有关的预订
|
||||
/// </summary>
|
||||
public class MyApptAuditPageReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 当前页从1开始
|
||||
/// </summary>
|
||||
public int PageIndex { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 页大小
|
||||
/// </summary>
|
||||
public int PageSize { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDES { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核状态:0-我的审核,1-待我审核,2-我抄送的,3-抄送给我的
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// EnumAuditorStatus
|
||||
/// </remarks>
|
||||
public int? AuditorStatus { get; set; }
|
||||
}
|
||||
}
|
||||
32
api_v1/Appointment.Entity/Request/TransferAuditReq.cs
Normal file
32
api_v1/Appointment.Entity/Request/TransferAuditReq.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 转审
|
||||
/// </summary>
|
||||
public class TransferAuditReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 要审核的主键
|
||||
/// </summary>
|
||||
public int ApptId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 客户端保存用户信息
|
||||
/// </summary>
|
||||
public string AccountDES { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 转审给哪个账号
|
||||
/// </summary>
|
||||
public string ToAccount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核说明
|
||||
/// </summary>
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
}
|
||||
28
api_v1/Appointment.Entity/Request/UsableMeetingReq.cs
Normal file
28
api_v1/Appointment.Entity/Request/UsableMeetingReq.cs
Normal file
@@ -0,0 +1,28 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// 根据日期与场次获取可用会议厅资源
|
||||
/// </summary>
|
||||
public class UsableMeetingReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 日期
|
||||
/// </summary>
|
||||
public DateTime Day { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 场次
|
||||
/// </summary>
|
||||
public int[] Groups { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 占用状态:0-默认,只返回未占用的,1-返回所有 由Numbers判断是否被占用
|
||||
/// </summary>
|
||||
public int Status { get; set; }
|
||||
}
|
||||
}
|
||||
22
api_v1/Appointment.Entity/Request/UsableRoomReq.cs
Normal file
22
api_v1/Appointment.Entity/Request/UsableRoomReq.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取客房资源
|
||||
/// </summary>
|
||||
public class UsableRoomReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 起始时间
|
||||
/// </summary>
|
||||
public DateTime StartDay { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 截止时间(包含当天)
|
||||
/// </summary>
|
||||
public DateTime EndDay { get; set; }
|
||||
}
|
||||
}
|
||||
32
api_v1/Appointment.Entity/Request/UserLoginAccountReq.cs
Normal file
32
api_v1/Appointment.Entity/Request/UserLoginAccountReq.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 账号密码登录入参
|
||||
/// </summary>
|
||||
public class UserLoginAccountReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 用户名
|
||||
/// </summary>
|
||||
public string UserName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 密码
|
||||
/// </summary>
|
||||
public string UserPwd { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 微信小程序wx.login下的code,实现首次授权
|
||||
/// </summary>
|
||||
public string Code { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 酒店id
|
||||
/// </summary>
|
||||
public string Hotelid { get; set; }
|
||||
}
|
||||
}
|
||||
22
api_v1/Appointment.Entity/Request/UserLoginCodeReq.cs
Normal file
22
api_v1/Appointment.Entity/Request/UserLoginCodeReq.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 微信Code登录
|
||||
/// </summary>
|
||||
public class UserLoginCodeReq
|
||||
{
|
||||
/// <summary>
|
||||
/// 微信Code登录
|
||||
/// </summary>
|
||||
public string Code { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 酒店id
|
||||
/// </summary>
|
||||
public string Hotelid { get; set; }
|
||||
}
|
||||
}
|
||||
68
api_v1/Appointment.Entity/Response/AuditorLogTreeRes.cs
Normal file
68
api_v1/Appointment.Entity/Response/AuditorLogTreeRes.cs
Normal file
@@ -0,0 +1,68 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 返回审批流程记录
|
||||
/// </summary>
|
||||
public class AuditorLogTreeRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订编号
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订申请时间
|
||||
/// </summary>
|
||||
public DateTime CreateTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 预订申请人姓名
|
||||
/// </summary>
|
||||
public string SaleName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 状态 EnumAuditorStatus
|
||||
/// </summary>
|
||||
public int AuditorStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 作废时产生的新单子名称
|
||||
/// </summary>
|
||||
public string NewName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审批流程
|
||||
/// </summary>
|
||||
public List<AudioLogRes> AudioLogList { get; set; }
|
||||
|
||||
}
|
||||
|
||||
public class AudioLogRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 编号
|
||||
/// </summary>
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
public DateTime? CreateTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 操作人员姓名
|
||||
/// </summary>
|
||||
public string UserName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 审核状态:0-驳回,1-审核通过,2-转审批,3-待审批
|
||||
/// </summary>
|
||||
public int Status { get; set; }
|
||||
|
||||
public string Remark { get; set; }
|
||||
}
|
||||
}
|
||||
61
api_v1/Appointment.Entity/Response/LoginUserRes.cs
Normal file
61
api_v1/Appointment.Entity/Response/LoginUserRes.cs
Normal file
@@ -0,0 +1,61 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 用户登录返回结果
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
public class LoginUserRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 用户账号
|
||||
/// </summary>
|
||||
public string UserAccount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户名称
|
||||
/// </summary>
|
||||
public string UserName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户组别
|
||||
/// </summary>
|
||||
public string UserGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 酒店id
|
||||
/// </summary>
|
||||
public string Hotelid { get; set; }
|
||||
}
|
||||
|
||||
public class UserInfoRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 绑定微信服务号状态:0-未绑定,1-绑定
|
||||
/// </summary>
|
||||
public int BindStatus { get; set; }
|
||||
|
||||
public string UserAccount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 明文小程序AppId
|
||||
/// </summary>
|
||||
public string Token { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户角色:0-全部;1-审核员;
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 预留:2-销售员
|
||||
/// </remarks>
|
||||
public int Role { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 加密后的用户信息
|
||||
/// </summary>
|
||||
public string AccountDES { get; set; }
|
||||
}
|
||||
}
|
||||
64
api_v1/Appointment.Entity/Response/MeetingRes.cs
Normal file
64
api_v1/Appointment.Entity/Response/MeetingRes.cs
Normal file
@@ -0,0 +1,64 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 会议室资源
|
||||
/// </summary>
|
||||
public class MeetingRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 资源代码
|
||||
/// </summary>
|
||||
public string Code { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 资源名称
|
||||
/// </summary>
|
||||
public string Descript { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 使用状态:R-预定的确定单:M-自己预定的确定单:T-暂定单
|
||||
/// </summary>
|
||||
public List<MeetingStatus> DayStatus { get; set; }
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 当天3场使用状态
|
||||
/// </summary>
|
||||
public class MeetingStatus
|
||||
{
|
||||
/// <summary>
|
||||
/// 日期
|
||||
/// </summary>
|
||||
public DateTime Day { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 状态:第1场,第2场,第3场 状态
|
||||
/// </summary>
|
||||
public string[] Status { get; set; }
|
||||
|
||||
public List<MeetingNum> MeetingNums { get; set; }
|
||||
}
|
||||
|
||||
public class MeetingNum
|
||||
{
|
||||
/// <summary>
|
||||
/// 场次状态:R-其他人预定单;M-我的预定单;I-占用;
|
||||
/// </summary>
|
||||
public string Group { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 暂订单数量
|
||||
/// </summary>
|
||||
public int Num { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 暂订单主键列表
|
||||
/// </summary>
|
||||
public List<int> SummaryList { get; set; }
|
||||
}
|
||||
}
|
||||
162
api_v1/Appointment.Entity/Response/P_xx_res_info_view3_Res.cs
Normal file
162
api_v1/Appointment.Entity/Response/P_xx_res_info_view3_Res.cs
Normal file
@@ -0,0 +1,162 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 存储过程返回数据
|
||||
/// </summary>
|
||||
public class P_xx_res_info_view3_Res
|
||||
{
|
||||
/// <summary>
|
||||
/// 资源类型代码:A-会议室,B-会议室设备,C-汽车,D-自行车.
|
||||
/// </summary>
|
||||
public string Sort { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 资源编码
|
||||
/// </summary>
|
||||
public string Code { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 资源名称
|
||||
/// </summary>
|
||||
public string Descript { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第一天 上午场
|
||||
/// </summary>
|
||||
public string Day11 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第一天 下午场
|
||||
/// </summary>
|
||||
public string Day12 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第一天 晚上场
|
||||
/// </summary>
|
||||
public string Day13 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第二天 上午场
|
||||
/// </summary>
|
||||
public string Day21 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第二天 下午场
|
||||
/// </summary>
|
||||
public string Day22 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第二天 晚上场
|
||||
/// </summary>
|
||||
public string Day23 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第三天 上午场
|
||||
/// </summary>
|
||||
public string Day31 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第三天 下午场
|
||||
/// </summary>
|
||||
public string Day32 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第三天 晚上场
|
||||
/// </summary>
|
||||
public string Day33 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第四天 上午场
|
||||
/// </summary>
|
||||
public string Day41 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第四天 下午场
|
||||
/// </summary>
|
||||
public string Day42 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第四天 晚上场
|
||||
/// </summary>
|
||||
public string Day43 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第五天 上午场
|
||||
/// </summary>
|
||||
public string Day51 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第五天 下午场
|
||||
/// </summary>
|
||||
public string Day52 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第五天 晚上场
|
||||
/// </summary>
|
||||
public string Day53 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第六天 上午场
|
||||
/// </summary>
|
||||
public string Day61 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第六天 下午场
|
||||
/// </summary>
|
||||
public string Day62 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第六天 晚上场
|
||||
/// </summary>
|
||||
public string Day63 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第七天 上午场
|
||||
/// </summary>
|
||||
public string Day71 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第七天 下午场
|
||||
/// </summary>
|
||||
public string Day72 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第七天 晚上场
|
||||
/// </summary>
|
||||
public string Day73 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第八天 上午场
|
||||
/// </summary>
|
||||
public string Day81 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第八天 下午场
|
||||
/// </summary>
|
||||
public string Day82 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第八天 晚上场
|
||||
/// </summary>
|
||||
public string Day83 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第九天 上午场
|
||||
/// </summary>
|
||||
public string Day91 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第九天 下午场
|
||||
/// </summary>
|
||||
public string Day92 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第九天 晚上场
|
||||
/// </summary>
|
||||
public string Day93 { get; set; }
|
||||
}
|
||||
}
|
||||
32
api_v1/Appointment.Entity/Response/Uc_groupRes.cs
Normal file
32
api_v1/Appointment.Entity/Response/Uc_groupRes.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 返回组别
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
public class Uc_groupRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 代码
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "op_group")]
|
||||
public string OpGroup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 名称
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "descript")]
|
||||
public string Descript { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 描述
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "op_func")]
|
||||
public string OpFunc { get; set; }
|
||||
}
|
||||
}
|
||||
23
api_v1/Appointment.Entity/Response/UsableMeetingMiddleRes.cs
Normal file
23
api_v1/Appointment.Entity/Response/UsableMeetingMiddleRes.cs
Normal file
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 会议厅中间转换
|
||||
/// </summary>
|
||||
public class UsableMeetingMiddleRes
|
||||
{
|
||||
public string MeetingName { get; set; }
|
||||
public string Code { get; set; }
|
||||
|
||||
public DateTime Stime { get; set; }
|
||||
|
||||
public string Sta { get; set; }
|
||||
|
||||
public int Sfield { get; set; }
|
||||
|
||||
public string Resby { get; set; }
|
||||
}
|
||||
}
|
||||
45
api_v1/Appointment.Entity/Response/UsableRoomRes.cs
Normal file
45
api_v1/Appointment.Entity/Response/UsableRoomRes.cs
Normal file
@@ -0,0 +1,45 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
[Serializable]
|
||||
public class UsableRoomRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 日期
|
||||
/// </summary>
|
||||
public DateTime? Date { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 房型
|
||||
/// </summary>
|
||||
public string Type { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 排序
|
||||
/// </summary>
|
||||
public int? Sequence { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 可卖数(可用数量)
|
||||
/// </summary>
|
||||
public int Quan { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 类型名称
|
||||
/// </summary>
|
||||
public string RoomName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 价格
|
||||
/// </summary>
|
||||
public decimal? RoomPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总房数
|
||||
/// </summary>
|
||||
public int? RoomTotal { get; set; }
|
||||
}
|
||||
}
|
||||
16
api_v1/Appointment.Entity/Response/WeChatLoginRes.cs
Normal file
16
api_v1/Appointment.Entity/Response/WeChatLoginRes.cs
Normal file
@@ -0,0 +1,16 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public class WeChatLoginRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 微信用户Openid
|
||||
/// </summary>
|
||||
public string Openid { get; set; }
|
||||
|
||||
public string Guid { get; set; }
|
||||
}
|
||||
}
|
||||
19
api_v1/Appointment.Entity/Response/WxServiceSetRes.cs
Normal file
19
api_v1/Appointment.Entity/Response/WxServiceSetRes.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public class WxServiceSetRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 用户信息
|
||||
/// </summary>
|
||||
public string UserAccount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 微信公共号Code
|
||||
/// </summary>
|
||||
public string Code { get; set; }
|
||||
}
|
||||
}
|
||||
541
api_v1/Appointment.Entity/Utility/AizhuhotelHelper.cs
Normal file
541
api_v1/Appointment.Entity/Utility/AizhuhotelHelper.cs
Normal file
@@ -0,0 +1,541 @@
|
||||
using Google.Protobuf.WellKnownTypes;
|
||||
using Newtonsoft.Json;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Net;
|
||||
using System.Net.Http;
|
||||
using System.Text;
|
||||
using System.Threading;
|
||||
using System.Xml.Linq;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public class AizhuhotelHelper
|
||||
{
|
||||
private static readonly log4net.ILog _logger = log4net.LogManager.GetLogger(typeof(AizhuhotelHelper));
|
||||
|
||||
// ---- 获取公众号 Access_token
|
||||
private class LoveInnGetAccessTokenRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 200-成功,400-出错,
|
||||
/// </summary>
|
||||
public int Code { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 返回信息:正确、错误都提示
|
||||
/// </summary>
|
||||
public string Message { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 信息
|
||||
/// </summary>
|
||||
public GetAccessTokenRes Data { get; set; }
|
||||
}
|
||||
|
||||
private class GetAccessTokenRes
|
||||
{
|
||||
public string Access_token { get; set; }
|
||||
|
||||
public int? Expires_in { get; set; }
|
||||
|
||||
public string Errcode { get; set; }
|
||||
|
||||
public string Errmsg { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 通过爱住接口获取Accesstoken
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public static ApiResult<string> AizhuhotelGetAccesstoken()
|
||||
{
|
||||
var url = "https://pay.aizhuhotel.com/dlwx/api/WD/LoveInnGetAccessToken";
|
||||
|
||||
string AppId = BaseConfig.App(new string[] { "WeChatService", "AppId" });
|
||||
if (string.IsNullOrWhiteSpace(AppId)) return ApiResult<string>.Failed("配置文件中未获取有效的消息推送AppId");
|
||||
string AppName = BaseConfig.App(new string[] { "WeChatService", "AppName" });
|
||||
if (string.IsNullOrWhiteSpace(AppName)) return ApiResult<string>.Failed("配置文件中未获取有效的消息推送AppName");
|
||||
string AppSecret = BaseConfig.App(new string[] { "WeChatService", "AppSecret" });
|
||||
if (string.IsNullOrWhiteSpace(AppSecret)) return ApiResult<string>.Failed("配置文件中未获取有效的消息推送AppSecret");
|
||||
|
||||
var json = JsonConvert.SerializeObject(new { AppId, AppName, AppSecret });
|
||||
|
||||
try
|
||||
{
|
||||
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(url);
|
||||
request.Proxy = null;
|
||||
request.Method = "POST";
|
||||
request.ContentType = "application/json";
|
||||
// request.Timeout = 10000;
|
||||
using (StreamWriter dataStream = new StreamWriter(request.GetRequestStream()))
|
||||
{
|
||||
dataStream.Write(json);
|
||||
dataStream.Close();
|
||||
}
|
||||
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
|
||||
if (response == null)
|
||||
{
|
||||
return ApiResult<string>.Failed("远程服务器没有响应!");
|
||||
}
|
||||
string encoding = response.ContentEncoding;
|
||||
if (encoding == null || encoding.Length < 1)
|
||||
{
|
||||
encoding = "UTF-8"; //默认编码
|
||||
}
|
||||
StreamReader reader = new StreamReader(response.GetResponseStream(), Encoding.GetEncoding(encoding));
|
||||
string retString = reader.ReadToEnd();
|
||||
|
||||
var res = JsonConvert.DeserializeObject<LoveInnGetAccessTokenRes>(retString);
|
||||
if (res.Code != 200) return ApiResult<string>.Failed(res.Message);
|
||||
if (res.Data == null) return ApiResult<string>.Failed("未获取到有效信息");
|
||||
return ApiResult<string>.Success(string.Empty, res.Data.Access_token);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
_logger.Debug(ex.ToString());
|
||||
return ApiResult<string>.Failed("http请求异常,异常信息:" + ex.Message);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ---- 通过微信服务器获取access_token
|
||||
|
||||
private static WxAccessTokenData accessCacheToken = null;
|
||||
|
||||
public class WxAccessTokenData
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取到的access_token
|
||||
/// </summary>
|
||||
public string Access_token { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取时间
|
||||
/// </summary>
|
||||
public DateTime GetDate { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 微信授权返回结果
|
||||
/// </summary>
|
||||
public class WxAuthorizationCodeRep
|
||||
{
|
||||
/// <summary>
|
||||
/// 网页授权接口调用凭证,注意:此access_token与基础支持的access_token不同
|
||||
/// </summary>
|
||||
public string Access_token { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// access_token接口调用凭证超时时间,单位(秒)
|
||||
/// 错误时不返回
|
||||
/// </summary>
|
||||
public int? Expires_in { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户刷新access_token
|
||||
/// </summary>
|
||||
public string Refresh_token { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户唯一标识
|
||||
/// </summary>
|
||||
public string Openid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户授权的作用域,使用逗号(,)分隔
|
||||
/// </summary>
|
||||
public string Scope { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 错误码:返回码
|
||||
/// 正确时不返回
|
||||
/// </summary>
|
||||
public int? Errcode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 错误信息
|
||||
/// </summary>
|
||||
public string Errmsg { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取服务号AccessToken
|
||||
/// </summary>
|
||||
/// <param name="forceUpdate">强制刷新</param>
|
||||
/// <returns></returns>
|
||||
public static ApiResult<string> GetAccessToken(bool forceUpdate = false)
|
||||
{
|
||||
try
|
||||
{
|
||||
string AppId = BaseConfig.App(new string[] { "WeChatService", "AppId" });
|
||||
if (string.IsNullOrWhiteSpace(AppId)) return ApiResult<string>.Failed("配置文件中未获取有效的服务号AppId");
|
||||
string AppSecret = BaseConfig.App(new string[] { "WeChatService", "AppSecret" });
|
||||
if (string.IsNullOrWhiteSpace(AppSecret)) return ApiResult<string>.Failed("配置文件中未获取有效的服务号AppSecret");
|
||||
|
||||
DateTime now = DateTime.Now;
|
||||
|
||||
if (forceUpdate == false && accessCacheToken != null && now.AddSeconds(-1 * 55 * 2) < accessCacheToken.GetDate)
|
||||
{
|
||||
return ApiResult<string>.Success(string.Empty, accessCacheToken.Access_token);
|
||||
}
|
||||
|
||||
var url = $"https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid={AppId}&secret={AppSecret}";
|
||||
using (var http = new HttpClient(new HttpClientHandler()))
|
||||
{
|
||||
var res = http.GetAsync(url).Result;
|
||||
if (res.StatusCode != HttpStatusCode.OK)
|
||||
{
|
||||
_logger.Error("获取公众号access_token失败,微信服务接口响应" + res.StatusCode.ToString());
|
||||
return ApiResult<string>.Failed("获取公众号access_token失败,微信服务接口响应" + res.StatusCode.ToString());
|
||||
}
|
||||
|
||||
var reContent = res.Content.ReadAsStringAsync().Result;
|
||||
if (!string.IsNullOrWhiteSpace(reContent))
|
||||
{
|
||||
var reToken = JsonConvert.DeserializeObject<WxAuthorizationCodeRep>(reContent);
|
||||
if (!string.IsNullOrEmpty(reToken.Access_token))
|
||||
{
|
||||
accessCacheToken = new WxAccessTokenData()
|
||||
{
|
||||
Access_token = reToken.Access_token,
|
||||
GetDate = now
|
||||
};
|
||||
return ApiResult<string>.Success(string.Empty, reToken.Access_token);
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
_logger.Error(reContent);
|
||||
}
|
||||
}
|
||||
return ApiResult<string>.Failed(string.Empty);
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
_logger.Error(ex.Message);
|
||||
return ApiResult<string>.Failed(ex.Message);
|
||||
}
|
||||
}
|
||||
|
||||
// ---- 获取用户Openid
|
||||
|
||||
private class WxServiceRes
|
||||
{
|
||||
public string Access_token { get; set; }
|
||||
|
||||
public int? Expires_in { get; set; }
|
||||
|
||||
public string Refresh_token { get; set; }
|
||||
|
||||
public string Openid { get; set; }
|
||||
|
||||
public string Errcode { get; set; }
|
||||
|
||||
public string Errmsg { get; set; }
|
||||
}
|
||||
|
||||
public static ApiResult<string> GetWxSericeOpenId(string code)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(code)) return ApiResult<string>.Failed("未获取到有效的code");
|
||||
string AppId = BaseConfig.App(new string[] { "WeChatService", "AppId" });
|
||||
if (string.IsNullOrWhiteSpace(AppId)) return ApiResult<string>.Failed("配置文件中未获取有效的消息推送AppId");
|
||||
string AppSecret = BaseConfig.App(new string[] { "WeChatService", "AppSecret" });
|
||||
if (string.IsNullOrWhiteSpace(AppSecret)) return ApiResult<string>.Failed("配置文件中未获取有效的消息推送AppSecret");
|
||||
|
||||
|
||||
string url = $"https://api.weixin.qq.com/sns/oauth2/access_token?appid={AppId}&secret={AppSecret}&code={code}&grant_type=authorization_code";
|
||||
using (var http = new HttpClient(new HttpClientHandler()))
|
||||
{
|
||||
var response = http.GetAsync(url).Result;
|
||||
if (response.StatusCode != HttpStatusCode.OK) return ApiResult<string>.Failed("微信接口无响应");
|
||||
|
||||
string res = response.Content.ReadAsStringAsync().Result;
|
||||
if (!string.IsNullOrWhiteSpace(res))
|
||||
{
|
||||
var wxServiceRes = JsonConvert.DeserializeObject<WxServiceRes>(res);
|
||||
if (!string.IsNullOrWhiteSpace(wxServiceRes.Openid))
|
||||
{
|
||||
return ApiResult<string>.Success(string.Empty, wxServiceRes.Openid);
|
||||
}
|
||||
else
|
||||
{
|
||||
_logger.Error(res);
|
||||
return ApiResult<string>.Failed(wxServiceRes.Errcode);
|
||||
}
|
||||
}
|
||||
return ApiResult<string>.Failed("返回空");
|
||||
}
|
||||
}
|
||||
|
||||
// ---- 发送消息模板
|
||||
|
||||
public static ApiResult SendTemplateMsg(string touser, string template_id, string url, string first, string remark, params object[] args)
|
||||
{
|
||||
try
|
||||
{
|
||||
string error = string.Empty;
|
||||
for (int i = 0; i < 3; i++)
|
||||
{
|
||||
error = string.Empty;
|
||||
var msg = WechatHelper.BuildTemlMsg(touser, template_id, url, first, remark, args);
|
||||
|
||||
string accessTokenMode = BaseConfig.App(new string[] { "AccessTokenMode" });
|
||||
if (string.IsNullOrWhiteSpace(accessTokenMode))
|
||||
{
|
||||
_logger.Error("配置文件中未获取有效的AccessTokenMode");
|
||||
return ApiResult.Failed("配置文件中未获取有效的AccessTokenMode");
|
||||
}
|
||||
|
||||
ApiResult<string> tokenResult = null;
|
||||
if (i == 0)
|
||||
{
|
||||
tokenResult = accessTokenMode == "1" ? AizhuhotelGetAccesstoken() : GetAccessToken();
|
||||
}
|
||||
else
|
||||
{
|
||||
tokenResult = accessTokenMode == "1" ? AizhuhotelGetAccesstoken() : GetAccessToken(true);
|
||||
}
|
||||
if (!tokenResult.IsSuccess)
|
||||
{
|
||||
error = "配置文件中未获取有效的AccessTokenMode";
|
||||
_logger.Error(error);
|
||||
continue;
|
||||
}
|
||||
|
||||
var postUrl = $"https://api.weixin.qq.com/cgi-bin/message/template/send?access_token={tokenResult.Info}";
|
||||
|
||||
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(postUrl);
|
||||
request.Proxy = null;
|
||||
request.Method = "POST";
|
||||
request.ContentType = "application/json";
|
||||
// request.Timeout = 10000;
|
||||
using (StreamWriter dataStream = new StreamWriter(request.GetRequestStream()))
|
||||
{
|
||||
dataStream.Write(msg);
|
||||
dataStream.Close();
|
||||
}
|
||||
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
|
||||
if (response == null)
|
||||
{
|
||||
error = "远程服务器没有响应!";
|
||||
_logger.Error(error);
|
||||
continue;
|
||||
}
|
||||
string encoding = response.ContentEncoding;
|
||||
if (encoding == null || encoding.Length < 1)
|
||||
{
|
||||
encoding = "UTF-8"; //默认编码
|
||||
}
|
||||
StreamReader reader = new StreamReader(response.GetResponseStream(), Encoding.GetEncoding(encoding));
|
||||
string retString = reader.ReadToEnd();
|
||||
|
||||
if (!string.IsNullOrWhiteSpace(retString))
|
||||
{
|
||||
var sendTemplateMsgRes = JsonConvert.DeserializeObject<SendTemplateMsgRes>(retString);
|
||||
if (sendTemplateMsgRes.Errmsg.ToLower() == "ok")
|
||||
{
|
||||
return ApiResult.Success(string.Empty);
|
||||
}
|
||||
else
|
||||
{
|
||||
error = $"接收者openid:{touser},错误代码{sendTemplateMsgRes.Errcode}";
|
||||
_logger.Error(error);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
return ApiResult.Failed(msg: "", info: error);
|
||||
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
_logger.Debug(ex.ToString());
|
||||
return ApiResult.Failed(msg: "", info: ex.Message);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 发送模板消息返回结果
|
||||
/// </summary>
|
||||
private class SendTemplateMsgRes
|
||||
{
|
||||
/// <summary>
|
||||
/// 返回代码,0-发送成功
|
||||
/// </summary>
|
||||
public int Errcode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 返回消息:"ok"-成功
|
||||
/// </summary>
|
||||
public string Errmsg { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 发送成功返回编号:失败不返回
|
||||
/// </summary>
|
||||
public long? Msgid { get; set; }
|
||||
}
|
||||
|
||||
public static void SendTemplateMsg(List<string> tousers, string template_id, string url, string first, string remark, params object[] args)
|
||||
{
|
||||
if (tousers == null || tousers.Count == 0) return;
|
||||
string accessTokenMode = BaseConfig.App(new string[] { "AccessTokenMode" });
|
||||
if (string.IsNullOrWhiteSpace(accessTokenMode))
|
||||
{
|
||||
_logger.Error("配置文件中未获取有效的AccessTokenMode");
|
||||
return;
|
||||
}
|
||||
|
||||
ApiResult<string> tokenResult = accessTokenMode == "1" ? AizhuhotelGetAccesstoken() : GetAccessToken();
|
||||
if (!tokenResult.IsSuccess)
|
||||
{
|
||||
_logger.Error(tokenResult.Msg);
|
||||
return;
|
||||
}
|
||||
|
||||
List<string> msgList = new List<string>();
|
||||
foreach (var touser in tousers)
|
||||
{
|
||||
msgList.Add(WechatHelper.BuildTemlMsg(touser, template_id, url, first, remark, args));
|
||||
}
|
||||
|
||||
int send = 0;
|
||||
_logger.Info($"发送推送消息,模板:{template_id}, 接收者openId:{string.Join(",", msgList)} 。");
|
||||
StringBuilder msg = new StringBuilder();
|
||||
foreach (var itemMsg in msgList)
|
||||
{
|
||||
for (int i = 0; i < 3; i++)
|
||||
{
|
||||
if (i > 0)
|
||||
{
|
||||
Thread.Sleep(100);
|
||||
tokenResult = accessTokenMode == "1" ? AizhuhotelGetAccesstoken() : GetAccessToken(true);
|
||||
if (!tokenResult.IsSuccess)
|
||||
{
|
||||
_logger.Error(tokenResult.Msg);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
var postUrl = $"https://api.weixin.qq.com/cgi-bin/message/template/send?access_token={tokenResult.Info}";
|
||||
|
||||
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(postUrl);
|
||||
request.Proxy = null;
|
||||
request.Method = "POST";
|
||||
request.ContentType = "application/json";
|
||||
// request.Timeout = 10000;
|
||||
using (StreamWriter dataStream = new StreamWriter(request.GetRequestStream()))
|
||||
{
|
||||
dataStream.Write(itemMsg);
|
||||
dataStream.Close();
|
||||
}
|
||||
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
|
||||
if (response == null)
|
||||
{
|
||||
_logger.Error("微信接口远程服务器没有响应");
|
||||
continue;
|
||||
}
|
||||
string encoding = response.ContentEncoding;
|
||||
if (encoding == null || encoding.Length < 1)
|
||||
{
|
||||
encoding = "UTF-8"; //默认编码
|
||||
}
|
||||
StreamReader reader = new StreamReader(response.GetResponseStream(), Encoding.GetEncoding(encoding));
|
||||
string retString = reader.ReadToEnd();
|
||||
_logger.Info("-->" + itemMsg + " response-->" + retString);
|
||||
|
||||
if (!string.IsNullOrWhiteSpace(retString))
|
||||
{
|
||||
var sendTemplateMsgRes = JsonConvert.DeserializeObject<SendTemplateMsgRes>(retString);
|
||||
if (sendTemplateMsgRes.Errmsg.ToLower() == "ok")
|
||||
{
|
||||
send += 1;
|
||||
break;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (msg.Length == 0) msg.AppendFormat("消息推送失败:消息模板{0}", template_id);
|
||||
msg.AppendFormat("接收者openid:{0},错误代码{1}", itemMsg, sendTemplateMsgRes.Errcode);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
Thread.Sleep(100);
|
||||
}
|
||||
if (msg.Length > 0) _logger.Error(msg.ToString());
|
||||
|
||||
}
|
||||
|
||||
public static ApiResult SendTempMsg(string msg)
|
||||
{
|
||||
try
|
||||
{
|
||||
string accessTokenMode = BaseConfig.App(new string[] { "AccessTokenMode" });
|
||||
if (string.IsNullOrWhiteSpace(accessTokenMode))
|
||||
{
|
||||
_logger.Error("配置文件中未获取有效的AccessTokenMode");
|
||||
return ApiResult.Failed("配置文件中未获取有效的AccessTokenMode");
|
||||
}
|
||||
|
||||
// 获取 AccessToken
|
||||
string access_token = string.Empty;
|
||||
for (int i = 0; i < 3; i++)
|
||||
{
|
||||
ApiResult<string> tokenResult = null;
|
||||
if (i == 0)
|
||||
{
|
||||
tokenResult = accessTokenMode == "1" ? AizhuhotelGetAccesstoken() : GetAccessToken();
|
||||
}
|
||||
else
|
||||
{
|
||||
tokenResult = accessTokenMode == "1" ? AizhuhotelGetAccesstoken() : GetAccessToken(true);
|
||||
}
|
||||
if (tokenResult.IsSuccess && !string.IsNullOrEmpty(tokenResult.Info))
|
||||
{
|
||||
access_token = tokenResult.Info;
|
||||
break;
|
||||
}
|
||||
Thread.Sleep(500);
|
||||
}
|
||||
if (string.IsNullOrWhiteSpace(access_token)) return ApiResult.Failed("未获取有效的AccessToken");
|
||||
|
||||
// 推送消息
|
||||
var postUrl = $"https://api.weixin.qq.com/cgi-bin/message/template/send?access_token={access_token}";
|
||||
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(postUrl);
|
||||
request.Proxy = null;
|
||||
request.Method = "POST";
|
||||
request.ContentType = "application/json";
|
||||
using (StreamWriter dataStream = new StreamWriter(request.GetRequestStream()))
|
||||
{
|
||||
dataStream.Write(msg);
|
||||
dataStream.Close();
|
||||
}
|
||||
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
|
||||
string encoding = response.ContentEncoding;
|
||||
if (encoding == null || encoding.Length < 1)
|
||||
{
|
||||
encoding = "UTF-8"; //默认编码
|
||||
}
|
||||
StreamReader reader = new StreamReader(response.GetResponseStream(), Encoding.GetEncoding(encoding));
|
||||
string retString = reader.ReadToEnd();
|
||||
_logger.Info("-->" + msg + " response-->" + retString);
|
||||
if (!string.IsNullOrWhiteSpace(retString))
|
||||
{
|
||||
var sendTemplateMsgRes = JsonConvert.DeserializeObject<SendTemplateMsgRes>(retString);
|
||||
if (sendTemplateMsgRes.Errmsg.ToLower() == "ok")
|
||||
{
|
||||
return ApiResult.Success(string.Empty);
|
||||
}
|
||||
}
|
||||
return ApiResult.Failed(msg: "", info: retString);
|
||||
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
_logger.Debug(ex.ToString());
|
||||
return ApiResult.Failed(msg: "", info: ex.Message);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
192
api_v1/Appointment.Entity/Utility/ApiResult.cs
Normal file
192
api_v1/Appointment.Entity/Utility/ApiResult.cs
Normal file
@@ -0,0 +1,192 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Net;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 接口返回数据标准
|
||||
/// </summary>
|
||||
public class ApiResult
|
||||
{
|
||||
/// <summary>
|
||||
/// 响应状态:true-成功执行,flase-响应异常
|
||||
/// </summary>
|
||||
public bool IsSuccess { get { return this.Code == (int)HttpStatusCode.OK; } }
|
||||
|
||||
/// <summary>
|
||||
/// 是否有效执行以IsSuccess为基准
|
||||
/// 200-有效执行,500-服务错误
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 此属性为定制化返回代码,例如登录成功并需要返回提示修改密码等相关类似的业务
|
||||
/// </remarks>
|
||||
public int Code { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 返回消息文本内容
|
||||
/// </summary>
|
||||
public string Msg { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 返回数据
|
||||
/// </summary>
|
||||
public object Info { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 构造函数
|
||||
/// </summary>
|
||||
/// <param name="code"></param>
|
||||
/// <param name="msg"></param>
|
||||
/// <param name="info"></param>
|
||||
public ApiResult(int code = (int)HttpStatusCode.OK, string msg = "操作成功", object info = null)
|
||||
{
|
||||
this.Code = code;
|
||||
this.Msg = msg;
|
||||
this.Info = info;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 成功执行
|
||||
/// </summary>
|
||||
/// <param name="msg"></param>
|
||||
/// <param name="info"></param>
|
||||
/// <returns></returns>
|
||||
public static ApiResult Success(string msg = "操作成功", object info = null)
|
||||
{
|
||||
return new ApiResult
|
||||
{
|
||||
Code = (int)HttpStatusCode.OK,
|
||||
Msg = msg,
|
||||
Info = info,
|
||||
};
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 执行错误
|
||||
/// </summary>
|
||||
/// <param name="msg"></param>
|
||||
/// <param name="code"></param>
|
||||
/// <param name="info"></param>
|
||||
/// <returns></returns>
|
||||
public static ApiResult Failed(string msg = "操作失败", object info = null, int code = (int)HttpStatusCode.InternalServerError)
|
||||
{
|
||||
return new ApiResult
|
||||
{
|
||||
Code = code,
|
||||
Msg = msg,
|
||||
Info = info,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 接口返回数据标准
|
||||
/// </summary>
|
||||
/// <typeparam name="T"></typeparam>
|
||||
public class ApiResult<T>
|
||||
{
|
||||
/// <summary>
|
||||
/// 响应状态:true-成功执行,flase-响应异常
|
||||
/// </summary>
|
||||
public bool IsSuccess { get { return this.Code == (int)HttpStatusCode.OK; } }
|
||||
|
||||
/// <summary>
|
||||
/// 是否有效执行以IsSuccess为基准
|
||||
/// 200-有效执行,500-服务错误
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 此属性为定制化返回代码,例如登录成功并需要返回提示修改密码等相关类似的业务
|
||||
/// </remarks>
|
||||
public int Code { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 返回消息文本内容
|
||||
/// </summary>
|
||||
public string Msg { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 返回数据
|
||||
/// </summary>
|
||||
public T Info { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 构造函数
|
||||
/// </summary>
|
||||
/// <param name="code"></param>
|
||||
/// <param name="msg"></param>
|
||||
/// <param name="info"></param>
|
||||
public ApiResult(int code = (int)HttpStatusCode.OK, string msg = "操作成功", T info = default)
|
||||
{
|
||||
this.Code = code;
|
||||
this.Msg = msg;
|
||||
this.Info = info;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 执行成功
|
||||
/// </summary>
|
||||
/// <param name="msg"></param>
|
||||
/// <param name="info"></param>
|
||||
/// <returns></returns>
|
||||
public static ApiResult<T> Success(string msg = "操作成功", T info = default)
|
||||
{
|
||||
return new ApiResult<T>
|
||||
{
|
||||
Code = (int)HttpStatusCode.OK,
|
||||
Msg = msg,
|
||||
Info = info,
|
||||
};
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 出现错误
|
||||
/// </summary>
|
||||
/// <param name="msg"></param>
|
||||
/// <param name="code"></param>
|
||||
/// <param name="info"></param>
|
||||
/// <returns></returns>
|
||||
public static ApiResult<T> Failed(string msg = "操作失败", int code = (int)HttpStatusCode.InternalServerError, T info = default)
|
||||
{
|
||||
return new ApiResult<T>
|
||||
{
|
||||
Code = code,
|
||||
Msg = msg,
|
||||
Info = info,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 公共Msg
|
||||
/// </summary>
|
||||
public class ApiResultMsg
|
||||
{
|
||||
/// <summary>
|
||||
/// 参数无效
|
||||
/// </summary>
|
||||
public string InvalidParameter { get { return $"参数[{_InvalidParameter}]无效!"; } set { _InvalidParameter = value; } }
|
||||
private string _InvalidParameter;
|
||||
|
||||
/// <summary>
|
||||
/// 缺少参数
|
||||
/// </summary>
|
||||
public static string NoParameter { get { return "缺少参数!"; } }
|
||||
|
||||
/// <summary>
|
||||
/// 没有权限
|
||||
/// </summary>
|
||||
public static string NoPower { get { return "没有权限,操作失败!"; } }
|
||||
|
||||
/// <summary>
|
||||
/// 没有数据
|
||||
/// </summary>
|
||||
public static string NoData { get { return "没有数据!"; } }
|
||||
|
||||
/// <summary>
|
||||
/// 数据不正确
|
||||
/// </summary>
|
||||
public static string ErrorData { get { return "数据不正确!"; } }
|
||||
}
|
||||
}
|
||||
119
api_v1/Appointment.Entity/Utility/BaseConfig.cs
Normal file
119
api_v1/Appointment.Entity/Utility/BaseConfig.cs
Normal file
@@ -0,0 +1,119 @@
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Extensions.Configuration.Json;
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public class BaseConfig
|
||||
{
|
||||
/// <summary>
|
||||
/// 缓存配置文件
|
||||
/// </summary>
|
||||
static IConfiguration configuration { get; set; }
|
||||
|
||||
static BaseConfig()
|
||||
{
|
||||
/* 当配置文件更新后,IConfiguration会自动更新,使用缓存为了双重保障 */
|
||||
DateTime now = DateTime.Now;
|
||||
if (validTime < now)
|
||||
{
|
||||
string path = "appsettings.json";
|
||||
var _newCreateTime = System.IO.File.GetCreationTime(path);
|
||||
if (_newCreateTime != createTime)
|
||||
{
|
||||
configuration = new ConfigurationBuilder()
|
||||
.Add(new JsonConfigurationSource
|
||||
{
|
||||
Path = path,
|
||||
Optional = false,
|
||||
ReloadOnChange = true
|
||||
}).Build();
|
||||
createTime = _newCreateTime;
|
||||
}
|
||||
validTime = now.AddSeconds(60);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 缓存配置文件创建时间
|
||||
/// </summary>
|
||||
static DateTime createTime;
|
||||
|
||||
/// <summary>
|
||||
/// 缓存配置文件失效时间
|
||||
/// </summary>
|
||||
static DateTime validTime;
|
||||
|
||||
/// <summary>
|
||||
/// 获取配置信息(必项)
|
||||
/// </summary>
|
||||
/// <param name="sections"></param>
|
||||
/// <returns>当不存在或为空是输出异常</returns>
|
||||
public static string App(params string[] sections)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (sections.Any())
|
||||
{
|
||||
string str = configuration[string.Join(":", sections)];
|
||||
if (!string.IsNullOrEmpty(str))
|
||||
{
|
||||
return str;
|
||||
}
|
||||
}
|
||||
throw new Exception($"没有在配置文件中的appSettings中找到{sections.Last()}的配置,请检查配置文件配置!");
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
throw new Exception(ex.Message);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取配置文件
|
||||
/// </summary>
|
||||
/// <param name="sections"></param>
|
||||
/// <param name="defaultValue">默认返回值</param>
|
||||
/// <returns>当不存在的配置项会返回null</returns>
|
||||
/// <remarks>
|
||||
/// 获取实例:
|
||||
/// BaseConfig.App(new string[] { "Logging" });
|
||||
/// BaseConfig.App(new string[] { "Logging", "LogLevel" });
|
||||
/// </remarks>
|
||||
public static string App(string[] sections, string defaultValue)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (sections.Any())
|
||||
{
|
||||
string stre = configuration[string.Join(":", sections)];
|
||||
|
||||
if (!string.IsNullOrEmpty(stre)) return stre;
|
||||
}
|
||||
return defaultValue;
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
return defaultValue;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 递归获取配置信息数组
|
||||
/// </summary>
|
||||
/// <typeparam name="T"></typeparam>
|
||||
/// <param name="sections"></param>
|
||||
/// <returns></returns>
|
||||
public static List<T> App<T>(params string[] sections)
|
||||
{
|
||||
List<T> list = new List<T>();
|
||||
configuration.Bind(string.Join(":", sections), list);
|
||||
return list;
|
||||
}
|
||||
}
|
||||
}
|
||||
109
api_v1/Appointment.Entity/Utility/CryptoHelper.cs
Normal file
109
api_v1/Appointment.Entity/Utility/CryptoHelper.cs
Normal file
@@ -0,0 +1,109 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Security.Cryptography;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public static class CryptoHelper
|
||||
{
|
||||
private static byte[] DESKeys = { 0x12, 0x34, 0x56, 0x78, 0x90, 0xAB, 0xCD, 0xEF };
|
||||
|
||||
/// <summary>
|
||||
/// MD5小写加密
|
||||
/// </summary>
|
||||
/// <param name="token">加密前字符串</param>
|
||||
/// <returns></returns>
|
||||
/// <remarks>
|
||||
/// 使用了UTF8格式
|
||||
/// </remarks>
|
||||
public static string Md5(string token)
|
||||
{
|
||||
StringBuilder strHash = new StringBuilder();
|
||||
System.Security.Cryptography.MD5CryptoServiceProvider md5 = new System.Security.Cryptography.MD5CryptoServiceProvider();
|
||||
byte[] bytHash;
|
||||
|
||||
bytHash = md5.ComputeHash(Encoding.UTF8.GetBytes(token));
|
||||
md5.Clear();
|
||||
for (int i = 0; i < bytHash.Length; i++)
|
||||
{
|
||||
strHash.Append(bytHash[i].ToString("x").PadLeft(2, '0'));
|
||||
}
|
||||
return strHash.ToString();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// MD5大写加密
|
||||
/// </summary>
|
||||
/// <param name="input"></param>
|
||||
/// <returns></returns>
|
||||
/// <remarks>
|
||||
/// 字符串转为ASCII再加密
|
||||
/// 与前面方法Md5()的区别是汉字加密后的结构不一致,
|
||||
/// </remarks>
|
||||
public static string Md5Hash(string input)
|
||||
{
|
||||
string strResult;
|
||||
using (var md51 = System.Security.Cryptography.MD5.Create())
|
||||
{
|
||||
var result = md51.ComputeHash(Encoding.ASCII.GetBytes(input));
|
||||
strResult = BitConverter.ToString(result);
|
||||
strResult = strResult.Replace("-", "");
|
||||
}
|
||||
return strResult;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// DES加密字符串
|
||||
/// </summary>
|
||||
/// <param name="encryptString">待加密的字符串</param>
|
||||
/// <param name="encryptKey">加密密钥,要求为8位</param>
|
||||
/// <returns>加密成功返回加密后的字符串,失败返回源串</returns>
|
||||
public static string DES_Encode(string encryptString, string encryptKey = "dlhisapi")
|
||||
{
|
||||
encryptKey = encryptKey.Substring(0, 8);
|
||||
encryptKey = encryptKey.PadRight(8, ' ');
|
||||
byte[] rgbKey = Encoding.UTF8.GetBytes(encryptKey.Substring(0, 8));
|
||||
byte[] rgbIV = DESKeys;
|
||||
byte[] inputByteArray = Encoding.UTF8.GetBytes(encryptString);
|
||||
DESCryptoServiceProvider dCSP = new DESCryptoServiceProvider();
|
||||
MemoryStream mStream = new MemoryStream();
|
||||
CryptoStream cStream = new CryptoStream(mStream, dCSP.CreateEncryptor(rgbKey, rgbIV), CryptoStreamMode.Write);
|
||||
cStream.Write(inputByteArray, 0, inputByteArray.Length);
|
||||
cStream.FlushFinalBlock();
|
||||
return Convert.ToBase64String(mStream.ToArray());
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// DES解密字符串
|
||||
/// </summary>
|
||||
/// <param name="decryptString">待解密的字符串</param>
|
||||
/// <param name="decryptKey">解密密钥,要求为8位,和加密密钥相同</param>
|
||||
/// <returns>解密成功返回解密后的字符串,失败返源串</returns>
|
||||
public static string DES_Decode(string decryptString, string decryptKey = "dlhisapi")
|
||||
{
|
||||
try
|
||||
{
|
||||
decryptKey = decryptKey.Substring(0, 8);
|
||||
decryptKey = decryptKey.PadRight(8, ' ');
|
||||
byte[] rgbKey = Encoding.UTF8.GetBytes(decryptKey);
|
||||
byte[] rgbIV = DESKeys;
|
||||
byte[] inputByteArray = Convert.FromBase64String(decryptString);
|
||||
DESCryptoServiceProvider DCSP = new DESCryptoServiceProvider();
|
||||
|
||||
MemoryStream mStream = new MemoryStream();
|
||||
CryptoStream cStream = new CryptoStream(mStream, DCSP.CreateDecryptor(rgbKey, rgbIV), CryptoStreamMode.Write);
|
||||
cStream.Write(inputByteArray, 0, inputByteArray.Length);
|
||||
cStream.FlushFinalBlock();
|
||||
return Encoding.UTF8.GetString(mStream.ToArray());
|
||||
}
|
||||
catch
|
||||
{
|
||||
return "";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
16
api_v1/Appointment.Entity/Utility/DateTimeHelper.cs
Normal file
16
api_v1/Appointment.Entity/Utility/DateTimeHelper.cs
Normal file
@@ -0,0 +1,16 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public static class DateTimeHelper
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取sql server最小时间
|
||||
/// </summary>
|
||||
public static DateTime MSSQLMinValue { get { return _MSSQLMinValue; }}
|
||||
private static DateTime _MSSQLMinValue = new DateTime(1753, 1, 1);
|
||||
|
||||
}
|
||||
}
|
||||
24
api_v1/Appointment.Entity/Utility/PagerData.cs
Normal file
24
api_v1/Appointment.Entity/Utility/PagerData.cs
Normal file
@@ -0,0 +1,24 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
/// <summary>
|
||||
/// 上下文分页类型
|
||||
/// </summary>
|
||||
/// <typeparam name="T"></typeparam>
|
||||
/// <remarks>
|
||||
/// Add:yuangb 2017-3-1
|
||||
/// </remarks>
|
||||
public class PagerData<T>
|
||||
{
|
||||
public int PageIndex { get; set; }
|
||||
|
||||
public int PageSize { get; set; }
|
||||
|
||||
public int Total { get; set; }
|
||||
|
||||
public List<T> Data { get; set; }
|
||||
}
|
||||
}
|
||||
111
api_v1/Appointment.Entity/Utility/PicHelper.cs
Normal file
111
api_v1/Appointment.Entity/Utility/PicHelper.cs
Normal file
@@ -0,0 +1,111 @@
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Drawing;
|
||||
using System.Drawing.Imaging;
|
||||
using System.IO;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public static class PicHelper
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取图片域名
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public static string GetPicDomain()
|
||||
{
|
||||
string value = string.Empty;
|
||||
using (System.IO.StreamReader file = System.IO.File.OpenText("appsettings.json"))
|
||||
{
|
||||
using JsonTextReader reader = new JsonTextReader(file);
|
||||
JObject o = (JObject)JToken.ReadFrom(reader);
|
||||
value = Convert.ToString(o["WebApiDomain"]);
|
||||
}
|
||||
if (string.IsNullOrWhiteSpace(value)) throw new Exception("配置信息中缺少WebApiDomain");
|
||||
return value;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取图片保存服务器完整路径
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public static string GetPicRootPath()
|
||||
{
|
||||
string value = string.Empty;
|
||||
using (System.IO.StreamReader file = System.IO.File.OpenText("appsettings.json"))
|
||||
{
|
||||
using JsonTextReader reader = new JsonTextReader(file);
|
||||
JObject o = (JObject)JToken.ReadFrom(reader);
|
||||
value = Convert.ToString(o["PicRootPath"]);
|
||||
}
|
||||
if (string.IsNullOrWhiteSpace(value)) throw new Exception("配置信息中缺少PicRootPath");
|
||||
return value;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 保存图片
|
||||
/// </summary>
|
||||
/// <param name="base64str">图片BASE64</param>
|
||||
/// <returns>NULL-保存图片异常,""-没有图片,其他-保存后的路径</returns>
|
||||
public static ApiResult<string> SavePic(string base64str)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(base64str)) return ApiResult<string>.Success(string.Empty);
|
||||
if (base64str.ToLower().IndexOf("imgfile") > 0) return ApiResult<string>.Success(base64str.Substring(base64str.ToLower().IndexOf("imgfile") - 1));
|
||||
|
||||
DateTime now = DateTime.Now;
|
||||
var rd = new Random().Next(100, 999);
|
||||
string filePath = $"/ImgFile/{now:yyyyMM}";
|
||||
string fileName = $"{now:yyyyMMddHHmmssfff}{rd}";
|
||||
base64str = base64str.Substring(base64str.IndexOf(",") + 1).Trim('\0');
|
||||
byte[] arr = Convert.FromBase64String(base64str);
|
||||
using (MemoryStream ms = new MemoryStream(arr))
|
||||
{
|
||||
if (!Directory.Exists(GetPicRootPath() + filePath)) Directory.CreateDirectory(GetPicRootPath() + filePath);
|
||||
Bitmap bmp = new Bitmap(ms);
|
||||
|
||||
ImageCodecInfo myImageCodecInfo = GetEnoderInfo(bmp.RawFormat.ToString().ToLower());
|
||||
if (bmp.RawFormat.ToString().ToLower().Contains("jpeg"))
|
||||
{
|
||||
fileName = $"{fileName}.jpg";
|
||||
myImageCodecInfo = GetEnoderInfo("png");
|
||||
}
|
||||
else
|
||||
{
|
||||
fileName = $"{fileName}.{bmp.RawFormat}";
|
||||
}
|
||||
|
||||
EncoderParameters destEncParams = new EncoderParameters(1);
|
||||
destEncParams.Param[0] = new EncoderParameter(System.Drawing.Imaging.Encoder.Quality, 100);
|
||||
|
||||
bmp.Save($"{GetPicRootPath()}{filePath}/{fileName}", myImageCodecInfo, destEncParams);
|
||||
ms.Close();
|
||||
}
|
||||
|
||||
return ApiResult<string>.Success($"{filePath}/{fileName}");
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return ApiResult<string>.Failed("保存图片失败,失败信息:" + ex.Message);
|
||||
}
|
||||
}
|
||||
|
||||
#region private
|
||||
private static ImageCodecInfo GetEnoderInfo(string mineType)
|
||||
{
|
||||
ImageCodecInfo[] myEncoders = ImageCodecInfo.GetImageEncoders();
|
||||
|
||||
foreach (System.Drawing.Imaging.ImageCodecInfo myEncoder in myEncoders)
|
||||
if (myEncoder.MimeType.Contains(mineType))
|
||||
return myEncoder;
|
||||
return null;
|
||||
}
|
||||
#endregion
|
||||
|
||||
}
|
||||
}
|
||||
44
api_v1/Appointment.Entity/Utility/RegexHelper.cs
Normal file
44
api_v1/Appointment.Entity/Utility/RegexHelper.cs
Normal file
@@ -0,0 +1,44 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Text.RegularExpressions;
|
||||
|
||||
namespace Appointment.Entity.Utility
|
||||
{
|
||||
/// <summary>
|
||||
/// 正则表达式
|
||||
/// </summary>
|
||||
public static class RegexHelper
|
||||
{
|
||||
/// <summary>
|
||||
/// 判断是否为手机号码
|
||||
/// </summary>
|
||||
/// <param name="value">字符串</param>
|
||||
/// <returns>True-是,False-否</returns>
|
||||
/// <remarks>
|
||||
/// Add:yuangb 2016-6-12
|
||||
/// </remarks>
|
||||
public static bool IsPhone(this string value)
|
||||
{
|
||||
value = value.Replace("+86", "");
|
||||
return Regex.IsMatch(value, @"^1[3-9]{1}[0-9]{9}$");
|
||||
}
|
||||
|
||||
public static TChild AutoCopy<TParent, TChild>(TParent parent) where TChild : TParent, new()
|
||||
{
|
||||
TChild child = new TChild();
|
||||
var ParentType = typeof(TParent);
|
||||
var Properties = ParentType.GetProperties();
|
||||
foreach (var Propertie in Properties)
|
||||
{
|
||||
//循环遍历属性
|
||||
if (Propertie.CanRead && Propertie.CanWrite)
|
||||
{
|
||||
//进行属性拷贝
|
||||
Propertie.SetValue(child, Propertie.GetValue(parent, null), null);
|
||||
}
|
||||
}
|
||||
return child;
|
||||
}
|
||||
}
|
||||
}
|
||||
150
api_v1/Appointment.Entity/Utility/StringHelper.cs
Normal file
150
api_v1/Appointment.Entity/Utility/StringHelper.cs
Normal file
@@ -0,0 +1,150 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Reflection;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public static class StringHelper
|
||||
{
|
||||
/// <summary>
|
||||
/// 去除对象字符串后面的空格
|
||||
/// </summary>
|
||||
/// <typeparam name="T"></typeparam>
|
||||
/// <param name="t"></param>
|
||||
/// <returns></returns>
|
||||
public static T Replace<T>(this T t)
|
||||
{
|
||||
string jsonStr = Newtonsoft.Json.JsonConvert.SerializeObject(t);
|
||||
while (true)
|
||||
{
|
||||
if (jsonStr.IndexOf(" \"") > -1)
|
||||
{
|
||||
jsonStr = jsonStr.Replace(" \"","\"");
|
||||
}
|
||||
else
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
return Newtonsoft.Json.JsonConvert.DeserializeObject<T>(jsonStr);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 得到一个汉字的拼音第一个字母,如果是一个英文字母则直接返回大写字母
|
||||
/// </summary>
|
||||
/// <param name="CnChar">单个汉字</param>
|
||||
/// <returns>单个大写字母</returns>
|
||||
public static string GetCharSpellCode(string CnChar)
|
||||
{
|
||||
long iCnChar;
|
||||
byte[] ZW = System.Text.Encoding.Default.GetBytes(CnChar);
|
||||
|
||||
//如果是字母,则直接返回首字母
|
||||
if (ZW.Length == 1)
|
||||
{
|
||||
return CnChar.ToUpper();
|
||||
}
|
||||
else
|
||||
{
|
||||
int i1 = (short)(ZW[0]);
|
||||
int i2 = (short)(ZW[1]);
|
||||
iCnChar = i1 * 256 + i2;
|
||||
}
|
||||
if ((iCnChar >= 45217) && (iCnChar <= 45252))
|
||||
{
|
||||
return "A";
|
||||
}
|
||||
else if ((iCnChar >= 45253) && (iCnChar <= 45760))
|
||||
{
|
||||
return "B";
|
||||
}
|
||||
else if ((iCnChar >= 45761) && (iCnChar <= 46317))
|
||||
{
|
||||
return "C";
|
||||
}
|
||||
else if ((iCnChar >= 46318) && (iCnChar <= 46825))
|
||||
{
|
||||
return "D";
|
||||
}
|
||||
else if ((iCnChar >= 46826) && (iCnChar <= 47009))
|
||||
{
|
||||
return "E";
|
||||
}
|
||||
else if ((iCnChar >= 47010) && (iCnChar <= 47296))
|
||||
{
|
||||
return "F";
|
||||
}
|
||||
else if ((iCnChar >= 47297) && (iCnChar <= 47613))
|
||||
{
|
||||
return "G";
|
||||
}
|
||||
else if ((iCnChar >= 47614) && (iCnChar <= 48118))
|
||||
{
|
||||
return "H";
|
||||
}
|
||||
else if ((iCnChar >= 48119) && (iCnChar <= 49061))
|
||||
{
|
||||
return "J";
|
||||
}
|
||||
else if ((iCnChar >= 49062) && (iCnChar <= 49323))
|
||||
{
|
||||
return "K";
|
||||
}
|
||||
else if ((iCnChar >= 49324) && (iCnChar <= 49895))
|
||||
{
|
||||
return "L";
|
||||
}
|
||||
else if ((iCnChar >= 49896) && (iCnChar <= 50370))
|
||||
{
|
||||
return "M";
|
||||
}
|
||||
else if ((iCnChar >= 50371) && (iCnChar <= 50613))
|
||||
{
|
||||
return "N";
|
||||
}
|
||||
else if ((iCnChar >= 50614) && (iCnChar <= 50621))
|
||||
{
|
||||
return "O";
|
||||
}
|
||||
else if ((iCnChar >= 50622) && (iCnChar <= 50905))
|
||||
{
|
||||
return "P";
|
||||
}
|
||||
else if ((iCnChar >= 50906) && (iCnChar <= 51386))
|
||||
{
|
||||
return "Q";
|
||||
}
|
||||
else if ((iCnChar >= 51387) && (iCnChar <= 51445))
|
||||
{
|
||||
return "R";
|
||||
}
|
||||
else if ((iCnChar >= 51446) && (iCnChar <= 52217))
|
||||
{
|
||||
return "S";
|
||||
}
|
||||
else if ((iCnChar >= 52218) && (iCnChar <= 52697))
|
||||
{
|
||||
return "T";
|
||||
}
|
||||
else if ((iCnChar >= 52698) && (iCnChar <= 52979))
|
||||
{
|
||||
return "W";
|
||||
}
|
||||
else if ((iCnChar >= 52980) && (iCnChar <= 53640))
|
||||
{
|
||||
return "X";
|
||||
}
|
||||
else if ((iCnChar >= 53689) && (iCnChar <= 54480))
|
||||
{
|
||||
return "Y";
|
||||
}
|
||||
else if ((iCnChar >= 54481) && (iCnChar <= 55289))
|
||||
{
|
||||
return "Z";
|
||||
}
|
||||
else
|
||||
return ("?");
|
||||
}
|
||||
}
|
||||
}
|
||||
126
api_v1/Appointment.Entity/Utility/WechatHelper.cs
Normal file
126
api_v1/Appointment.Entity/Utility/WechatHelper.cs
Normal file
@@ -0,0 +1,126 @@
|
||||
using Google.Protobuf.WellKnownTypes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Net;
|
||||
using System.Net.Http;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity
|
||||
{
|
||||
public class WechatHelper
|
||||
{
|
||||
private static HttpClient _HttpClient = null;
|
||||
static readonly log4net.ILog log = log4net.LogManager.GetLogger(typeof(WechatHelper));
|
||||
|
||||
static WechatHelper()
|
||||
{
|
||||
_HttpClient = new HttpClient(new HttpClientHandler());
|
||||
}
|
||||
|
||||
public object JsonConvert { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// 根据小程序登录code获取用户信息
|
||||
/// </summary>
|
||||
/// <param name="code"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<WeChatLoginRes> Code2Session(string code)
|
||||
{
|
||||
string appId = BaseConfig.App(new string[] { "WeChat", "AppId" });
|
||||
if (string.IsNullOrWhiteSpace(appId)) ApiResult<WeChatLoginRes>.Failed("缺少配置参数 [AppId]!");
|
||||
string appSecret = BaseConfig.App(new string[] { "WeChat", "AppSecret" });
|
||||
if (string.IsNullOrWhiteSpace(appSecret)) ApiResult<WeChatLoginRes>.Failed("缺少配置参数 [AppSecret]!");
|
||||
|
||||
if (string.IsNullOrWhiteSpace(code) || string.IsNullOrWhiteSpace(appId) || string.IsNullOrWhiteSpace(appSecret))
|
||||
{
|
||||
return ApiResult<WeChatLoginRes>.Failed("获取小程序配置信息出错");
|
||||
}
|
||||
|
||||
string url = $"https://api.weixin.qq.com/sns/jscode2session?appid={appId}&secret={appSecret}&js_code={code}&grant_type=authorization_code";
|
||||
|
||||
var res = _HttpClient.GetAsync(url).Result;
|
||||
if (res.StatusCode == HttpStatusCode.OK)
|
||||
{
|
||||
var result = Encoding.Default.GetString(res.Content.ReadAsByteArrayAsync().Result);
|
||||
log.Info($"jscode2session:{result}");
|
||||
if (string.IsNullOrWhiteSpace(result) || result.IndexOf("session_key") == -1)
|
||||
{
|
||||
return ApiResult<WeChatLoginRes>.Failed("调用微信接口失败,可能code已失效");
|
||||
}
|
||||
|
||||
var weChatDto = Newtonsoft.Json.JsonConvert.DeserializeObject<WeChatLoginRes>(result);
|
||||
|
||||
return ApiResult<WeChatLoginRes>.Success("", weChatDto);
|
||||
}
|
||||
else
|
||||
{
|
||||
return ApiResult<WeChatLoginRes>.Failed("调用微信接口失败");
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
|
||||
public class LoveInnGetAccessTokenReq
|
||||
{
|
||||
public string AppId { get; set; }
|
||||
|
||||
public string AppName { get; set; }
|
||||
|
||||
public string AppSecret { get; set; }
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 模版信息
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public static string BuildTemlMsg(string toUser, string tmplId, string url, string first, string remark, params object[] args)
|
||||
{
|
||||
string appId = BaseConfig.App(new string[] { "WeChat", "AppId" });
|
||||
if (string.IsNullOrWhiteSpace(appId)) ApiResult<WeChatLoginRes>.Failed("缺少配置参数 [AppId]!");
|
||||
|
||||
StringBuilder sbMsg = new StringBuilder();
|
||||
|
||||
sbMsg.Append("{");
|
||||
sbMsg.AppendFormat("\"touser\":\"{0}\",", toUser);
|
||||
sbMsg.AppendFormat("\"template_id\":\"{0}\",", tmplId);
|
||||
sbMsg.Append("\"miniprogram\":{");
|
||||
sbMsg.AppendFormat("\"appid\":\"{0}\",", appId);
|
||||
sbMsg.AppendFormat("\"pagepath\":\"{0}\"", url);
|
||||
sbMsg.Append("},");
|
||||
sbMsg.Append("\"topcolor\":\"#FF0000\",");
|
||||
sbMsg.Append("\"data\":");
|
||||
sbMsg.Append("{");
|
||||
|
||||
sbMsg.Append("\"first\":");
|
||||
sbMsg.Append("{");
|
||||
sbMsg.AppendFormat("\"value\":\"{0}\",", first);
|
||||
sbMsg.AppendFormat("\"color\":\"{0}\"", "#333333");
|
||||
sbMsg.Append("},");
|
||||
|
||||
for (int i = 0; i < args.Length; i++)
|
||||
{
|
||||
sbMsg.AppendFormat("\"keyword{0}\":", i + 1);
|
||||
sbMsg.Append("{");
|
||||
sbMsg.AppendFormat("\"value\":\"{0}\",", args[i]);
|
||||
sbMsg.AppendFormat("\"color\":\"{0}\"", "#333333");
|
||||
sbMsg.Append("},");
|
||||
}
|
||||
|
||||
sbMsg.Append("\"remark\":");
|
||||
sbMsg.Append("{");
|
||||
sbMsg.AppendFormat("\"value\":\"{0}\",", remark);
|
||||
sbMsg.AppendFormat("\"color\":\"{0}\"", "#333333");
|
||||
sbMsg.Append("}");
|
||||
|
||||
sbMsg.Append("}");
|
||||
sbMsg.Append("}");
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
return sbMsg.ToString();
|
||||
}
|
||||
}
|
||||
}
|
||||
116
api_v1/Appointment.Entity/ValidateAttribute/AttributeExtend.cs
Normal file
116
api_v1/Appointment.Entity/ValidateAttribute/AttributeExtend.cs
Normal file
@@ -0,0 +1,116 @@
|
||||
using Appointment.Entity.Utility;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Reflection;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity.ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 验证的执行
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Add:yuangb 2019-3-5
|
||||
/// </remarks>
|
||||
public static class AttributeExtend
|
||||
{
|
||||
/// <summary>
|
||||
/// 全部实体属性根据特性校验
|
||||
/// </summary>
|
||||
/// <typeparam name="T"></typeparam>
|
||||
/// <param name="t">验证的实体</param>
|
||||
/// <returns></returns>
|
||||
public static ApiResult Validate<T>(this T t) where T : class
|
||||
{
|
||||
List<string> validates = new List<string>();
|
||||
|
||||
Type type = t.GetType();
|
||||
foreach (PropertyInfo prop in type.GetProperties())
|
||||
{
|
||||
object oValue = prop.GetValue(t);
|
||||
|
||||
foreach (ValidateAttribute attr in prop.GetCustomAttributes(typeof(ValidateAttribute), true))
|
||||
{
|
||||
string msg = attr.Validate(oValue);
|
||||
if (!string.IsNullOrWhiteSpace(msg)) validates.Add(msg);
|
||||
}
|
||||
|
||||
// 2020-10-12 添加屏蔽HTML注入
|
||||
if (prop.PropertyType.Name == "String")
|
||||
{
|
||||
string sValue = (string)prop.GetValue(t);
|
||||
if (sValue != null && !string.IsNullOrEmpty(sValue))
|
||||
{
|
||||
var isIgnoreHtml = prop.GetCustomAttribute(typeof(IsIgnoreHtml), true);
|
||||
if (isIgnoreHtml == null)
|
||||
{
|
||||
sValue = sValue.Replace("<", "<").Replace(">", ">");
|
||||
prop.SetValue(t, sValue);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return validates.Count == 0 ? ApiResult.Success() : ApiResult.Failed(string.Join(",", validates));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 指定实体的属性名称,根据特性进行校验
|
||||
/// </summary>
|
||||
/// <typeparam name="T"></typeparam>
|
||||
/// <param name="t">验证的实体</param>
|
||||
/// <param name="list">实体的属性名称</param>
|
||||
/// <returns></returns>
|
||||
public static ApiResult Validate<T>(this T t, List<string> list) where T : class
|
||||
{
|
||||
List<string> validates = new List<string>();
|
||||
|
||||
Type type = t.GetType();
|
||||
foreach (PropertyInfo prop in type.GetProperties())
|
||||
{
|
||||
object oValue = prop.GetValue(t);
|
||||
|
||||
if (list.Contains(prop.Name))
|
||||
{
|
||||
foreach (ValidateAttribute attr in prop.GetCustomAttributes(typeof(ValidateAttribute), true))
|
||||
{
|
||||
|
||||
string msg = attr.Validate(oValue);
|
||||
if (!string.IsNullOrWhiteSpace(msg)) validates.Add(msg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return validates.Count == 0 ? ApiResult.Success() : ApiResult.Failed(string.Join(",", validates));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 使用委托,全部实体属性根据特性校验
|
||||
/// </summary>
|
||||
/// <typeparam name="T"></typeparam>
|
||||
/// <param name="t">验证的实体</param>
|
||||
/// <param name="func">一个ApiResult入参,一个ApiResult返回值的委托</param>
|
||||
/// <returns></returns>
|
||||
public static ApiResult Validate<T>(this T t, Func<ApiResult, ApiResult> func)
|
||||
{
|
||||
List<string> validates = new List<string>();
|
||||
|
||||
Type type = t.GetType();
|
||||
foreach (PropertyInfo prop in type.GetProperties())
|
||||
{
|
||||
object oValue = prop.GetValue(t);
|
||||
|
||||
foreach (ValidateAttribute attr in prop.GetCustomAttributes(typeof(ValidateAttribute), true))
|
||||
{
|
||||
string msg = attr.Validate(oValue);
|
||||
if (!string.IsNullOrWhiteSpace(msg))
|
||||
{
|
||||
validates.Add(msg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return validates.Count == 0 ? func.Invoke(ApiResult.Success()) : ApiResult.Failed(string.Join(",", validates));
|
||||
}
|
||||
}
|
||||
}
|
||||
20
api_v1/Appointment.Entity/ValidateAttribute/IsIgnoreHtml.cs
Normal file
20
api_v1/Appointment.Entity/ValidateAttribute/IsIgnoreHtml.cs
Normal file
@@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity.ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 忽略HTML标签
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Add:yuangb 2019-10-15
|
||||
/// </remarks>
|
||||
public class IsIgnoreHtml : ValidateAttribute
|
||||
{
|
||||
public override string Validate(object oValue)
|
||||
{
|
||||
return "";
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,52 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity.ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 整型数值值范围效验
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Add:yuangb 2019-3-11
|
||||
/// 使用格式:实体属性前加[IntValue(minValue: 1000, maxValue: 999999, ErrorMessage = "验证码长度不正确")]
|
||||
/// </remarks>
|
||||
public class LongValueAttribute : ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 报错提示
|
||||
/// </summary>
|
||||
public string ErrorMessage { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 最小值(包含)
|
||||
/// </summary>
|
||||
public long MinValue { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// 最大值(包含)
|
||||
/// </summary>
|
||||
public long MaxValue { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="minValue">最小值(包含)</param>
|
||||
/// <param name="maxValue">最大值(包含)</param>
|
||||
public LongValueAttribute(long minValue, long maxValue)
|
||||
{
|
||||
this.MinValue = minValue;
|
||||
this.MaxValue = maxValue;
|
||||
}
|
||||
|
||||
public override string Validate(object oValue)
|
||||
{
|
||||
if (oValue != null)
|
||||
{
|
||||
long lValue = Convert.ToInt64(oValue);
|
||||
if (lValue < MinValue || lValue > MaxValue) return ErrorMessage;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
using Appointment.Entity.Utility;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity.ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 手机格式校验
|
||||
/// 注意:当存在内容时才校验,如果为必填信息,请同时使用必填特性
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Add:yuangb 2019-3-11
|
||||
/// 使用格式:实体属性前加 [Phone(ErrorMessage = "手机号码不正确")]
|
||||
/// </remarks>
|
||||
public class PhoneAttribute : ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 报错提示信息
|
||||
/// </summary>
|
||||
public string ErrorMessage { get; set; }
|
||||
|
||||
public override string Validate(object oValue)
|
||||
{
|
||||
if (oValue != null && !string.IsNullOrWhiteSpace(oValue.ToString()))
|
||||
{
|
||||
string sPhone = oValue.ToString().Replace("+86", "");
|
||||
if (!sPhone.IsPhone()) return ErrorMessage;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity.ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 字符串长度校验特性
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Add:yuangb 2019-3-5
|
||||
/// 使用格式:实体属性前加[StringLength(50, MinLength = 2, ErrorMessage = "获取微信用户信息失败")]
|
||||
/// </remarks>
|
||||
public class StringLengthAttribute : ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 最小长度
|
||||
/// </summary>
|
||||
public int MinLength { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 报错提示
|
||||
/// </summary>
|
||||
public string ErrorMessage { get; set; }
|
||||
|
||||
private int _maxLength;
|
||||
|
||||
public StringLengthAttribute(int maxLength)
|
||||
{
|
||||
this._maxLength = maxLength;
|
||||
}
|
||||
|
||||
public override string Validate(object oValue)
|
||||
{
|
||||
if (oValue == null || string.IsNullOrWhiteSpace(oValue.ToString()) || oValue.ToString().Length > this._maxLength || oValue.ToString().Length < this.MinLength)
|
||||
{
|
||||
return ErrorMessage;
|
||||
}
|
||||
else
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity.ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 字符串最大长度
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Add:yuangb 2020-12-9
|
||||
/// 使用格式:实体属性前加 [StringMaxLength(200, ErrorMessage = "备注说明最大长度200个字符")]
|
||||
/// </remarks>
|
||||
public class StringMaxLengthAttribute : ValidateAttribute
|
||||
{
|
||||
private int _MaxLength = 0;
|
||||
|
||||
/// <summary>
|
||||
/// 报错提示
|
||||
/// </summary>
|
||||
public string ErrorMessage { get; set; }
|
||||
|
||||
public StringMaxLengthAttribute(int maxLength)
|
||||
{
|
||||
_MaxLength = maxLength;
|
||||
}
|
||||
|
||||
public override string Validate(object oValue)
|
||||
{
|
||||
if (oValue != null && oValue.ToString().Length > _MaxLength)
|
||||
{
|
||||
return ErrorMessage;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity.ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 必填项
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Add:yuangb 2019-3-11
|
||||
/// [StringRequired(ErrorMessage ="状态不能为空")]
|
||||
/// </remarks>
|
||||
public class StringRequiredAttribute : ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 报错提示信息
|
||||
/// </summary>
|
||||
public string ErrorMessage { get; set; }
|
||||
|
||||
public override string Validate(object oValue)
|
||||
{
|
||||
if (oValue == null || string.IsNullOrWhiteSpace(oValue.ToString()))
|
||||
{
|
||||
return ErrorMessage;
|
||||
}
|
||||
else
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.Entity.ValidateAttribute
|
||||
{
|
||||
/// <summary>
|
||||
/// 特性基类
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Add:yuangb 2019-3-5
|
||||
/// </remarks>
|
||||
public abstract class ValidateAttribute : Attribute
|
||||
{
|
||||
public abstract string Validate(object oValue);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp3.1</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
|
||||
<DocumentationFile>Appointment.IRepository.xml</DocumentationFile>
|
||||
<NoWarn>1701;1702;1591</NoWarn>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Appointment.Entity\Appointment.Entity.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Update="Appointment.IRepository.xml">
|
||||
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
342
api_v1/Appointment.IRepository/Appointment.IRepository.xml
Normal file
342
api_v1/Appointment.IRepository/Appointment.IRepository.xml
Normal file
@@ -0,0 +1,342 @@
|
||||
<?xml version="1.0"?>
|
||||
<doc>
|
||||
<assembly>
|
||||
<name>Appointment.IRepository</name>
|
||||
</assembly>
|
||||
<members>
|
||||
<member name="M:Appointment.IRepository.IApptAuditorRepo.Add(Appointment.Entity.ApptAuditor)">
|
||||
<summary>
|
||||
预订审核节点 添加
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptAuditorRepo.Delete(System.Int32)">
|
||||
<summary>
|
||||
预订审核节点 删除
|
||||
</summary>
|
||||
<param name="id"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptAuditorRepo.GetModel(System.Int32)">
|
||||
<summary>
|
||||
预订审核节点 根据主键获取实体
|
||||
</summary>
|
||||
<param name="id"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptAuditorRepo.GetList(Appointment.Entity.ApptAuditor)">
|
||||
<summary>
|
||||
预订审核节点 获取列表
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptAuditorRepo.Page(Appointment.Entity.CommPageReq)">
|
||||
<summary>
|
||||
预订审核节点 分页
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptAuditorRepo.AuditorLine(System.Int32)">
|
||||
<summary>
|
||||
获取预订审核线状结构
|
||||
</summary>
|
||||
<param name="apptTypeId"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptLogRepo.SetLog(System.String,System.String,System.String,System.String,System.String,System.Int32)">
|
||||
<summary>
|
||||
日志
|
||||
</summary>
|
||||
<param name="tableName">数据表</param>
|
||||
<param name="keyId">主键</param>
|
||||
<param name="oldData">原始数据</param>
|
||||
<param name="newData">新数据</param>
|
||||
<param name="userId">操作人员</param>
|
||||
<param name="systemUser">用户类型:0-普通用户,1-管理人员</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.UsableMeetingList(Appointment.Entity.MeetingReq)">
|
||||
<summary>
|
||||
根据时间段获取可使用的会议厅资源
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.UsableMeeting(Appointment.Entity.UsableMeetingReq)">
|
||||
<summary>
|
||||
根据日期与场次获取可使用会议厅资源
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.UsableRoom(Appointment.Entity.UsableRoomReq)">
|
||||
<summary>
|
||||
获取房间列表
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.UsableRoomMin(Appointment.Entity.UsableRoomReq)">
|
||||
<summary>
|
||||
据时间段获取房类最小可用数
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.RemarkList">
|
||||
<summary>
|
||||
获取自定义备注列表项
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.Add(Appointment.Entity.ApptSummaryReq)">
|
||||
<summary>
|
||||
添加预订
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.DeleteAppt(Appointment.Entity.AuditDeleteReq)">
|
||||
<summary>
|
||||
删除主单或详情
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.ApptAudit(Appointment.Entity.ApptAuditReq)">
|
||||
<summary>
|
||||
预订审核
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.CancelAudit(Appointment.Entity.ApptAuditReq)">
|
||||
<summary>
|
||||
取消预订
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.TransferAudit(Appointment.Entity.TransferAuditReq)">
|
||||
<summary>
|
||||
转审批
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.ApptSend(Appointment.Entity.ApptSendReq)">
|
||||
<summary>
|
||||
抄送操作
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.GetModel(System.Int32)">
|
||||
<summary>
|
||||
查询实体
|
||||
</summary>
|
||||
<param name="id">主键</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.MyApptApplyPageReq(Appointment.Entity.MyApptApplyPageReq)">
|
||||
<summary>
|
||||
获取我申请的预订信息
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.MyPartakePage(Appointment.Entity.MyApptAuditPageReq)">
|
||||
<summary>
|
||||
获取我的待审核的
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepo.AuditorLogTree(Appointment.Entity.CommIntReq)">
|
||||
<summary>
|
||||
获取预订审核记录表
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.AddApptSummary(Appointment.Entity.AddSummaryJncReq)">
|
||||
<summary>
|
||||
创建新的预订单
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.UpdateSummary(Appointment.Entity.UpdateSummaryReq)">
|
||||
<summary>
|
||||
修改暂订单
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.ApplyOrder(Appointment.Entity.ApplyOrderReq)">
|
||||
<summary>
|
||||
申请确定单
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.Cancel(Appointment.Entity.ApplyOrderReq)">
|
||||
<summary>
|
||||
取消OA单
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.AuditorSummary(Appointment.Entity.ApplyOrderReq)">
|
||||
<summary>
|
||||
审批通过确实单
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.RejectSummary(Appointment.Entity.ApplyOrderReq)">
|
||||
<summary>
|
||||
被驳回
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.ManualCopy(Appointment.Entity.ApptSendReq)">
|
||||
<summary>
|
||||
手动抄送
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.AddReply(Appointment.Entity.AddMsgReq)">
|
||||
<summary>
|
||||
信息回复
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.GetSummaryModel(Appointment.Entity.SummaryJncModelReq)">
|
||||
<summary>
|
||||
根据订单主键获取实体
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.ApptSummaryPager(Appointment.Entity.SummaryJNCPageReq)">
|
||||
<summary>
|
||||
分页预订列表
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.AuditorLogTree(Appointment.Entity.SummaryJncModelReq)">
|
||||
<summary>
|
||||
获取审批流程
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.Disparity(Appointment.Entity.SummaryJncModelReq)">
|
||||
<summary>
|
||||
订单数据差距
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptRepoJNC.GetReplyPicList(Appointment.Entity.SummaryJncModelReq)">
|
||||
<summary>
|
||||
返回回复中的图片列表
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptTypeRepo.Add(Appointment.Entity.ApptTypeAddReq)">
|
||||
<summary>
|
||||
预订类型添加
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptTypeRepo.Delete(System.Int32)">
|
||||
<summary>
|
||||
预订类型删除
|
||||
</summary>
|
||||
<param name="id"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptTypeRepo.Update(Appointment.Entity.ApptType)">
|
||||
<summary>
|
||||
预订类型更新
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptTypeRepo.GetModel(System.Int32)">
|
||||
<summary>
|
||||
预订类型获取实体
|
||||
</summary>
|
||||
<param name="id"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptTypeRepo.GetList(Appointment.Entity.ApptType)">
|
||||
<summary>
|
||||
预订类型列表
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IApptTypeRepo.Page(Appointment.Entity.CommPageReq)">
|
||||
<summary>
|
||||
预订类型分页
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IManagerGroup.GetAll">
|
||||
<summary>
|
||||
获取全部角色
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IUserRepo.UserNameLogin(System.String,System.String,System.String,System.String)">
|
||||
<summary>
|
||||
工号密码登录
|
||||
</summary>
|
||||
<param name="userName"></param>
|
||||
<param name="userPwd"></param>
|
||||
<param name="code"></param>
|
||||
<param name="hotelid">酒店id</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IUserRepo.WxLogin(System.String,System.String)">
|
||||
<summary>
|
||||
微信登录
|
||||
</summary>
|
||||
<param name="code"></param>
|
||||
<param name="hotelid">酒店id</param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IUserRepo.WxServiceSet(Appointment.Entity.WxServiceSetRes)">
|
||||
<summary>
|
||||
绑定微信服务号openid
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IUserRepo.GetSendUserList(Appointment.Entity.BindUserReq)">
|
||||
<summary>
|
||||
获取所有用户
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Appointment.IRepository.IUserRepo.GetTransferAuditUserList(Appointment.Entity.BindUserReq)">
|
||||
<summary>
|
||||
当前用户角色是否具有转审权限
|
||||
</summary>
|
||||
<param name="req"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
</members>
|
||||
</doc>
|
||||
52
api_v1/Appointment.IRepository/IApptAuditorRepo.cs
Normal file
52
api_v1/Appointment.IRepository/IApptAuditorRepo.cs
Normal file
@@ -0,0 +1,52 @@
|
||||
using Appointment.Entity;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.IRepository
|
||||
{
|
||||
public interface IApptAuditorRepo
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订审核节点 添加
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<ApptAuditor> Add(ApptAuditor req);
|
||||
|
||||
/// <summary>
|
||||
/// 预订审核节点 删除
|
||||
/// </summary>
|
||||
/// <param name="id"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult Delete(int id);
|
||||
|
||||
/// <summary>
|
||||
/// 预订审核节点 根据主键获取实体
|
||||
/// </summary>
|
||||
/// <param name="id"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<ApptAuditor> GetModel(int id);
|
||||
|
||||
/// <summary>
|
||||
/// 预订审核节点 获取列表
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<List<ApptAuditor>> GetList(ApptAuditor req);
|
||||
|
||||
/// <summary>
|
||||
/// 预订审核节点 分页
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<PagerData<ApptAuditor>> Page(CommPageReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 获取预订审核线状结构
|
||||
/// </summary>
|
||||
/// <param name="apptTypeId"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<ApptAuditor> AuditorLine(int apptTypeId);
|
||||
}
|
||||
}
|
||||
22
api_v1/Appointment.IRepository/IApptLogRepo.cs
Normal file
22
api_v1/Appointment.IRepository/IApptLogRepo.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using Appointment.Entity;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.IRepository
|
||||
{
|
||||
public interface IApptLogRepo
|
||||
{
|
||||
/// <summary>
|
||||
/// 日志
|
||||
/// </summary>
|
||||
/// <param name="tableName">数据表</param>
|
||||
/// <param name="keyId">主键</param>
|
||||
/// <param name="oldData">原始数据</param>
|
||||
/// <param name="newData">新数据</param>
|
||||
/// <param name="userId">操作人员</param>
|
||||
/// <param name="systemUser">用户类型:0-普通用户,1-管理人员</param>
|
||||
/// <returns></returns>
|
||||
ApiResult<int> SetLog(string tableName, string keyId, string oldData, string newData, string userId, int systemUser = 0);
|
||||
}
|
||||
}
|
||||
116
api_v1/Appointment.IRepository/IApptRepo.cs
Normal file
116
api_v1/Appointment.IRepository/IApptRepo.cs
Normal file
@@ -0,0 +1,116 @@
|
||||
using Appointment.Entity;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.IRepository
|
||||
{
|
||||
public interface IApptRepo
|
||||
{
|
||||
/// <summary>
|
||||
/// 根据时间段获取可使用的会议厅资源
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<List<MeetingRes>> UsableMeetingList(MeetingReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 根据日期与场次获取可使用会议厅资源
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<List<ResCode>> UsableMeeting(UsableMeetingReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 获取房间列表
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
ApiResult<List<UsableRoomRes>> UsableRoom(UsableRoomReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 据时间段获取房类最小可用数
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<List<UsableRoomRes>> UsableRoomMin(UsableRoomReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 获取自定义备注列表项
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
ApiResult<List<string>> RemarkList();
|
||||
|
||||
/// <summary>
|
||||
/// 添加预订
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult Add(ApptSummaryReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 删除主单或详情
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult DeleteAppt(AuditDeleteReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 预订审核
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult ApptAudit(ApptAuditReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 取消预订
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult CancelAudit(ApptAuditReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 转审批
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult TransferAudit(TransferAuditReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 抄送操作
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult ApptSend(ApptSendReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 查询实体
|
||||
/// </summary>
|
||||
/// <param name="id">主键</param>
|
||||
/// <returns></returns>
|
||||
ApiResult<ApptSummaryReq> GetModel(int id);
|
||||
|
||||
/// <summary>
|
||||
/// 获取我申请的预订信息
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<PagerData<ApptSummaryReq>> MyApptApplyPageReq(MyApptApplyPageReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 获取我的待审核的
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<PagerData<ApptSummaryReq>> MyPartakePage(MyApptAuditPageReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 获取预订审核记录表
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<AuditorLogTreeRes> AuditorLogTree(CommIntReq req);
|
||||
|
||||
public ApiResult Demo(CommPageReq req);
|
||||
}
|
||||
}
|
||||
104
api_v1/Appointment.IRepository/IApptRepoJNC.cs
Normal file
104
api_v1/Appointment.IRepository/IApptRepoJNC.cs
Normal file
@@ -0,0 +1,104 @@
|
||||
using Appointment.Entity;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Appointment.IRepository
|
||||
{
|
||||
public interface IApptRepoJNC
|
||||
{
|
||||
/// <summary>
|
||||
/// 创建新的预订单
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<int> AddApptSummary(AddSummaryJncReq req);
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 修改暂订单
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<int> UpdateSummary(UpdateSummaryReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 申请确定单
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
Task<ApiResult> ApplyOrder(ApplyOrderReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 取消OA单
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult Cancel(ApplyOrderReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 审批通过确实单
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
Task<ApiResult> AuditorSummary(ApplyOrderReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 被驳回
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
Task<ApiResult> RejectSummary(ApplyOrderReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 手动抄送
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
Task<ApiResult> ManualCopy(ApptSendReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 信息回复
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult AddReply(AddMsgReq req);
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 根据订单主键获取实体
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<SummaryJncDetailRep> GetSummaryModel(SummaryJncModelReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 分页预订列表
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<PagerData<SummaryJncDetailRep>> ApptSummaryPager(SummaryJNCPageReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 获取审批流程
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<AuditorLogReq> AuditorLogTree(SummaryJncModelReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 订单数据差距
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<List<DisparityReq>> Disparity(SummaryJncModelReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 返回回复中的图片列表
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public ApiResult<List<string>> GetReplyPicList(SummaryJncModelReq req);
|
||||
}
|
||||
}
|
||||
52
api_v1/Appointment.IRepository/IApptTypeRepo.cs
Normal file
52
api_v1/Appointment.IRepository/IApptTypeRepo.cs
Normal file
@@ -0,0 +1,52 @@
|
||||
using Appointment.Entity;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.IRepository
|
||||
{
|
||||
public interface IApptTypeRepo
|
||||
{
|
||||
/// <summary>
|
||||
/// 预订类型添加
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<ApptType> Add(ApptTypeAddReq req);
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型删除
|
||||
/// </summary>
|
||||
/// <param name="id"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult Delete(int id);
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型更新
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<ApptType> Update(ApptType req);
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型获取实体
|
||||
/// </summary>
|
||||
/// <param name="id"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<ApptType> GetModel(int id);
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型列表
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<List<ApptType>> GetList(ApptType req);
|
||||
|
||||
/// <summary>
|
||||
/// 预订类型分页
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<PagerData<ApptType>> Page(CommPageReq req);
|
||||
}
|
||||
}
|
||||
16
api_v1/Appointment.IRepository/IManageGroup.cs
Normal file
16
api_v1/Appointment.IRepository/IManageGroup.cs
Normal file
@@ -0,0 +1,16 @@
|
||||
using Appointment.Entity;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.IRepository
|
||||
{
|
||||
public interface IManagerGroup
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取全部角色
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
ApiResult<List<UcGroup>> GetAll();
|
||||
}
|
||||
}
|
||||
49
api_v1/Appointment.IRepository/IUserRepo.cs
Normal file
49
api_v1/Appointment.IRepository/IUserRepo.cs
Normal file
@@ -0,0 +1,49 @@
|
||||
using Appointment.Entity;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Appointment.IRepository
|
||||
{
|
||||
public interface IUserRepo
|
||||
{
|
||||
/// <summary>
|
||||
/// 工号密码登录
|
||||
/// </summary>
|
||||
/// <param name="userName"></param>
|
||||
/// <param name="userPwd"></param>
|
||||
/// <param name="code"></param>
|
||||
/// <param name="hotelid">酒店id</param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<UserInfoRes> UserNameLogin(string userName, string userPwd, string code, string hotelid);
|
||||
|
||||
/// <summary>
|
||||
/// 微信登录
|
||||
/// </summary>
|
||||
/// <param name="code"></param>
|
||||
/// <param name="hotelid">酒店id</param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<UserInfoRes> WxLogin(string code, string hotelid);
|
||||
|
||||
/// <summary>
|
||||
/// 绑定微信服务号openid
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult WxServiceSet(WxServiceSetRes req);
|
||||
|
||||
/// <summary>
|
||||
/// 获取所有用户
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
ApiResult<List<LoginUserRes>> GetSendUserList(BindUserReq req = null);
|
||||
|
||||
/// <summary>
|
||||
/// 当前用户角色是否具有转审权限
|
||||
/// </summary>
|
||||
/// <param name="req"></param>
|
||||
/// <returns></returns>
|
||||
public ApiResult<List<LoginUserRes>> GetTransferAuditUserList(BindUserReq req);
|
||||
}
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user