Compare commits

..

9 Commits

Author SHA1 Message Date
jackchenyang 58021ed5db 12112 2024-05-18 10:12:33 +08:00
jackchenyang 1f159c4857 121 2024-05-18 10:12:09 +08:00
jackchenyang f6e8914747 111 2024-05-18 09:49:15 +08:00
jackchenyang 6187cd3f47 122121 2024-05-17 23:21:21 +08:00
jackchenyang fe82692030 1212 2024-05-17 20:54:18 +08:00
shecs 254653611f 112 2024-05-17 17:18:29 +08:00
jackchenyang c41a8f7903 112 2024-05-17 15:32:43 +08:00
jackchenyang a55c796eea Merge branch 'Feature_20240510' 2024-05-17 15:32:40 +08:00
jackchenyang 9ffacdb282 12 2024-05-17 15:32:35 +08:00
21 changed files with 377 additions and 561 deletions
+1
View File
@@ -5734,3 +5734,4 @@ HJGLPackFile/版本日志/HJGLDB_2024.05.02.sql
/CreateModel2017.bat
/DataBase/版本日志/HJGLDB_2024.05.12.sql
/HJGL/.vs/HJGL/v17/.suo
/HJGL/WebApi/ErrLog.txt
+2 -2
View File
@@ -25,9 +25,9 @@ REM --------------
@echo 设置.net控制台环境
@echo.
@call "%VS150%"
@call "%VS100COMNTOOLS%"vsvars32.bat
SqlMetal /views /server:. /database:HJGLDB_ZJBSF /code:%Model_ROOT%\Model.cs /namespace:Model
SqlMetal /views /server:.\SQL2016 /database:HJGLDB_ZJBSF /code:%Model_ROOT%\Model.cs /namespace:Model
@ECHO 完成
pause
@@ -0,0 +1,193 @@
USE [HJGLDB_ZJBSF]
GO
/****** Object: Table [dbo].[Email_Params] Script Date: 2024-5-17 15:35:13 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[Email_Params](
[ID] [varchar](50) NOT NULL,
[MailClassName] [varchar](100) NULL,
[MailClassID] [varchar](50) NOT NULL,
[CreateName] [varchar](100) NOT NULL,
[CreateTime] [datetime] NOT NULL,
[UpdateName] [nchar](10) NULL,
[UpdateTime] [datetime] NULL,
CONSTRAINT [PK_Email_Params] PRIMARY KEY CLUSTERED
(
[ID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY]
GO
/****** Object: Table [dbo].[Email_Pop] Script Date: 2024-5-17 15:35:13 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[Email_Pop](
[EmailID] [varchar](50) NOT NULL,
[EmailFwq] [varchar](50) NULL,
[EmailDk] [varchar](50) NULL,
[EmailYx] [varchar](50) NULL,
[EmailUsername] [varchar](50) NULL,
[EmailPass] [varchar](50) NULL,
[CreateTime] [varchar](50) NULL,
[CreateName] [varchar](50) NULL,
[UpdateTime] [varchar](50) NULL,
[UpdateName] [varchar](50) NULL,
CONSTRAINT [PK_Email_Pop] PRIMARY KEY CLUSTERED
(
[EmailID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY]
GO
/****** Object: Table [dbo].[Email_SendLog] Script Date: 2024-5-17 15:35:13 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[Email_SendLog](
[EmailId] [varchar](50) NOT NULL,
[EmailTile] [varchar](255) NULL,
[EmailContent] [text] NULL,
[EmailURL] [varchar](50) NULL,
[EmailName] [varchar](50) NULL,
[EmailStatus] [varchar](10) NULL,
[CreateTime] [datetime] NULL,
[CreateName] [varchar](50) NULL,
CONSTRAINT [PK_Email_Send] PRIMARY KEY CLUSTERED
(
[EmailId] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
/****** Object: Table [dbo].[Email_SendTemplate] Script Date: 2024-5-17 15:35:13 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[Email_SendTemplate](
[EmailId] [varchar](50) NOT NULL,
[EmailParamsID] [varchar](50) NOT NULL,
[EailTiaoJian] [varchar](500) NULL,
[EmailUserYN] [int] NULL,
[EmailTitle] [varchar](500) NULL,
[EmailContext] [text] NULL,
[CreateName] [varchar](500) NULL,
[CreateTime] [datetime] NULL,
[UpdateName] [varchar](500) NULL,
[UpdateTime] [datetime] NULL,
[EmailDesc] [varchar](500) NULL,
CONSTRAINT [PK_Email_SendTemplate] PRIMARY KEY CLUSTERED
(
[EmailId] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
/****** Object: Table [dbo].[Email_ToPeople] Script Date: 2024-5-17 15:35:13 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[Email_ToPeople](
[EmID] [varchar](50) NOT NULL,
[EmtempID] [varchar](50) NOT NULL,
[EmuserID] [varchar](50) NULL,
[EmuserName] [varchar](50) NULL,
[EmuaerEmailAddress] [varchar](100) NULL,
[EMPeopleType] [varchar](5) NULL,
CONSTRAINT [PK_Email_ToPeople] PRIMARY KEY CLUSTERED
(
[EmID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY]
GO
INSERT [dbo].[Email_Params] ([ID], [MailClassName], [MailClassID], [CreateName], [CreateTime], [UpdateName], [UpdateTime]) VALUES (N'1a800170-48e2-4b41-a2af-20258aa74907', N'监理审核', N'监理', N'管理员', CAST(N'2024-05-16T14:53:01.747' AS DateTime), N'管理员 ', CAST(N'2024-05-16T17:05:42.987' AS DateTime))
GO
INSERT [dbo].[Email_Params] ([ID], [MailClassName], [MailClassID], [CreateName], [CreateTime], [UpdateName], [UpdateTime]) VALUES (N'859e5eaf-6a9e-46a8-8eb1-f3ba61f3be79', N'管理公司审核', N'管理公司', N'管理员', CAST(N'2024-05-14T17:39:53.640' AS DateTime), N'管理员 ', CAST(N'2024-05-16T17:05:48.370' AS DateTime))
GO
INSERT [dbo].[Email_Pop] ([EmailID], [EmailFwq], [EmailDk], [EmailYx], [EmailUsername], [EmailPass], [CreateTime], [CreateName], [UpdateTime], [UpdateName]) VALUES (N'7EC5E991-B7A0-495A-90ED-2BE15370C959', N'smtp.163.com', N'25', N'Scs13965090560@163.com', N'scs', N'CLXGLMKBGQBEXSSW', N'2024-5-16 14:46:25', N'管理员', NULL, NULL)
GO
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'3cfa3bbf-e73a-494b-bb60-f682b52dad84', N'监理—点口未审核的焊口', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp;&nbsp;</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp; &nbsp;您有<span style="color:#ff0000">2105</span>条点口记录待审核!</p><p><br/></p>', N'jackchenyang@sina.cn', N'jackchenyang@sina.cn', N'发送成功', CAST(N'2024-05-17T14:32:14.573' AS DateTime), N'sys')
GO
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'3f61427f-2b6f-42cb-8028-27726807f8e8', N'测试再发送一个邮件', N'这是一个邮件内容,请查收!', N'408299694@qq.com', N'408299694@qq.com', N'发送成功', CAST(N'2024-05-16T14:51:03.117' AS DateTime), N'sys')
GO
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'632f4c12-08c6-4f19-88a1-5ed760486ae0', N'测试发邮件', N'这个是一个测试的发送邮件内容。。。。', N'874821510@qq.com', N'874821510@qq.com', N'发送失败', CAST(N'2024-05-16T14:45:45.350' AS DateTime), N'sys')
GO
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'6488713b-86f4-4dc2-989c-32152fe53727', N'管理公司—点口未审核的焊口', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp;&nbsp;</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp; &nbsp;您有<span style="color:#ff0000">2176</span>条点口记录待审核!</p><p><br style="text-wrap: wrap;"/></p><p><br/></p>', N'jackchenyang@sina.cn', N'jackchenyang@sina.cn', N'发送成功', CAST(N'2024-05-17T14:32:16.627' AS DateTime), N'sys')
GO
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'709cb7de-0564-4ab9-84e6-0b0b2f6732d8', N'测试再发送一个邮件', N'这是一个邮件内容,请查收!', N'874821510@qq.com', N'874821510@qq.com', N'发送成功', CAST(N'2024-05-16T14:51:03.113' AS DateTime), N'sys')
GO
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'9857506c-83a4-4b79-b09a-d6e061376f17', N'点口未审核的焊口', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp;&nbsp;</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp; &nbsp;您有<span style="color:#ff0000">2176</span>条点口记录待审核!</p><p><br style="text-wrap: wrap;"/></p><p><br/></p>', N'jackchenyang@sina.cn', N'jackchenyang@sina.cn', N'发送成功', CAST(N'2024-05-17T14:26:32.310' AS DateTime), N'sys')
GO
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'd349818c-9434-4ff9-ab73-c868c81de870', N'点口未审核的焊口', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp;&nbsp;</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp; &nbsp;您有<span style="color:#ff0000">2105</span>条点口记录待审核!</p><p><br/></p>', N'jackchenyang@sina.cn', N'jackchenyang@sina.cn', N'发送成功', CAST(N'2024-05-17T14:26:10.880' AS DateTime), N'sys')
GO
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'd8740146-2ce5-4582-baa0-45063e967f02', N'测试发邮件', N'这个是一个测试的发送邮件内容。。。。', N'874821510@qq.com', N'874821510@qq.com', N'发送成功', CAST(N'2024-05-16T14:46:31.487' AS DateTime), N'sys')
GO
INSERT [dbo].[Email_SendTemplate] ([EmailId], [EmailParamsID], [EailTiaoJian], [EmailUserYN], [EmailTitle], [EmailContext], [CreateName], [CreateTime], [UpdateName], [UpdateTime], [EmailDesc]) VALUES (N'1a605eaf-6e0a-49d2-a0db-9e1238b65e8a', N'监理', N'点口未审核的焊口', 1, N'监理点口审核', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp;&nbsp;</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp; &nbsp;您有<span style="color:#ff0000">{{totalCount}}</span>条点口记录待审核!</p><p><br/></p>', N'管理员', CAST(N'2024-05-16T17:04:30.020' AS DateTime), N'管理员', CAST(N'2024-05-17T14:16:54.980' AS DateTime), NULL)
GO
INSERT [dbo].[Email_SendTemplate] ([EmailId], [EmailParamsID], [EailTiaoJian], [EmailUserYN], [EmailTitle], [EmailContext], [CreateName], [CreateTime], [UpdateName], [UpdateTime], [EmailDesc]) VALUES (N'ad5201c3-0398-4316-a880-0a285e0f06fa', N'管理公司', N'点口未审核的焊口', 1, N'管理公司点口审核', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp;&nbsp;</p><p style="text-wrap: wrap;">&nbsp; &nbsp; &nbsp; &nbsp;您有<span style="color:#ff0000">{{totalCount}}</span>条点口记录待审核!</p><p><br style="text-wrap: wrap;"/></p><p><br/></p>', N'管理员', CAST(N'2024-05-16T14:54:15.743' AS DateTime), N'管理员', CAST(N'2024-05-17T14:16:58.267' AS DateTime), NULL)
GO
INSERT [dbo].[Email_ToPeople] ([EmID], [EmtempID], [EmuserID], [EmuserName], [EmuaerEmailAddress], [EMPeopleType]) VALUES (N'33e99721-b831-46f5-83b6-039be6a89050', N'1a605eaf-6e0a-49d2-a0db-9e1238b65e8a', N'29188391-731e-4645-ad09-c99c2a9fc6ce', N'李庆华', N'jackchenyang@sina.cn', N'0')
GO
INSERT [dbo].[Email_ToPeople] ([EmID], [EmtempID], [EmuserID], [EmuserName], [EmuaerEmailAddress], [EMPeopleType]) VALUES (N'6144c9f6-6e91-4e88-ae3a-fe9f99bc78af', N'ad5201c3-0398-4316-a880-0a285e0f06fa', N'29188391-731e-4645-ad09-c99c2a9fc6ce', N'李庆华', N'jackchenyang@sina.cn', N'0')
GO
INSERT [dbo].[Email_ToPeople] ([EmID], [EmtempID], [EmuserID], [EmuserName], [EmuaerEmailAddress], [EMPeopleType]) VALUES (N'd78fa8fb-b675-4264-8040-8a0cf3d9649d', N'1a605eaf-6e0a-49d2-a0db-9e1238b65e8a', N'18485804-501b-4123-9e9a-1afb3c53aed0', N'陈阳', N'874821510@qq.com', N'1')
GO
INSERT [dbo].[Email_ToPeople] ([EmID], [EmtempID], [EmuserID], [EmuserName], [EmuaerEmailAddress], [EMPeopleType]) VALUES (N'ff5fefa1-2ab8-4643-b3f7-b38fd049597a', N'ad5201c3-0398-4316-a880-0a285e0f06fa', N'18485804-501b-4123-9e9a-1afb3c53aed0', N'陈阳', N'874821510@qq.com', N'1')
GO
SET ANSI_PADDING ON
GO
/****** Object: Index [IX_Email_Params] Script Date: 2024-5-17 15:35:13 ******/
ALTER TABLE [dbo].[Email_Params] ADD CONSTRAINT [IX_Email_Params] UNIQUE NONCLUSTERED
(
[MailClassID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
GO
SET ANSI_PADDING ON
GO
/****** Object: Index [IX_Email_SendTemplate] Script Date: 2024-5-17 15:35:13 ******/
ALTER TABLE [dbo].[Email_SendTemplate] ADD CONSTRAINT [IX_Email_SendTemplate] UNIQUE NONCLUSTERED
(
[EmailParamsID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
GO
ALTER TABLE [dbo].[Email_Params] ADD CONSTRAINT [DF_Email_Params_CreateName] DEFAULT ('sys') FOR [CreateName]
GO
ALTER TABLE [dbo].[Email_Params] ADD CONSTRAINT [DF_Email_Params_CreateTime] DEFAULT (getdate()) FOR [CreateTime]
GO
ALTER TABLE [dbo].[Email_ToPeople] ADD CONSTRAINT [DF_Email_ToPeople_EMPeopleType] DEFAULT ((0)) FOR [EMPeopleType]
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'邮件分类名称' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_Params', @level2type=N'COLUMN',@level2name=N'MailClassName'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'邮件分类ID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_Params', @level2type=N'COLUMN',@level2name=N'MailClassID'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'参数MailClassID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_SendTemplate', @level2type=N'COLUMN',@level2name=N'EmailParamsID'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'内容条件说明' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_SendTemplate', @level2type=N'COLUMN',@level2name=N'EailTiaoJian'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'邮件标题' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_SendTemplate', @level2type=N'COLUMN',@level2name=N'EmailTitle'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'邮件具体内容' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_SendTemplate', @level2type=N'COLUMN',@level2name=N'EmailContext'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'备注' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_SendTemplate', @level2type=N'COLUMN',@level2name=N'EmailDesc'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'发送人类型 0-发送人 1-抄送人' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_ToPeople', @level2type=N'COLUMN',@level2name=N'EMPeopleType'
GO
--- 插入菜单
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'97143EDB-6A32-4BBA-9F49-E33E87912BC8', N'发送邮件', N'Send Email', N'Email_Send/Email_Send_Edit.aspx', 10, N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'2 ', NULL, 1)
GO
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'9E9DD8E3-D91B-4FD4-B922-2F5CC23D2745', N'邮件配置', N'Send Email Pop', N'Email_Send/Email_Pop_Edit.aspx', 20, N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'2 ', NULL, 1)
GO
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'发送邮件', N'Send Email', N'', 60, N'0', N'2 ', NULL, 1)
GO
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'F19A6438-C757-4BC2-ADC2-72AAF02089E5', N'邮件类型', N'Mail Parameters', N'Email_Send/Email_Params_List.aspx', 60, N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'2 ', NULL, 1)
GO
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'06EB7C08-6F6E-433B-91A7-579BFC435A0C', N'邮件模板设置', N'Send Email Template', N'Email_Send/Email_SendTemplate_List.aspx', 40, N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'2 ', NULL, 1)
GO
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'5941BE0C-C262-48C7-899F-F0BE5A779926', N'发送邮件日志', N'Send Email Log', N'Email_Send/Email_SendLog_List.aspx', 30, N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'2 ', NULL, 1)
GO
SELECT * FROM dbo.Sys_Menu WHERE MenuName LIKE '%邮件%'
Binary file not shown.
File diff suppressed because one or more lines are too long
-1
View File
@@ -161,7 +161,6 @@
<Compile Include="PublicInfo\FileControl\FileControl_DomesticStandardsService.cs" />
<Compile Include="PublicInfo\FileControl\FileControl_ForeignStandardsService.cs" />
<Compile Include="PublicInfo\WPQ\WPQListService.cs" />
<Compile Include="SendEmailService.cs" />
<Compile Include="SessionName.cs" />
<Compile Include="SoftRegeditService.cs" />
<Compile Include="SQLHelper.cs" />
+76 -61
View File
@@ -46,77 +46,92 @@ namespace FineUIPro.Web.common
mailFrom = ps.EmailYx;
}
MailMessage email = new MailMessage();
//MailAddress emailFrom = new MailAddress(mailFrom);
//MailMessage email = new MailMessage();
////MailAddress emailFrom = new MailAddress(mailFrom);
//发件人
email.From = new MailAddress(mailFrom, ps.EmailYx);//发件人地址
////发件人
//email.From = new MailAddress(mailFrom, ps.EmailYx);//发件人地址
//收件人
if (mailTo != null && mailTo.Length > 0)
{
foreach (string send in mailTo)
{
if (!String.IsNullOrEmpty(send))
{
email.To.Add(send);
}
}
}
////收件人
//if (mailTo != null && mailTo.Length > 0)
//{
// foreach (string send in mailTo)
// {
// if (!String.IsNullOrEmpty(send))
// {
// email.To.Add(send);
// }
// }
//}
//加抄送
if (mailCC != null && mailCC.Length > 0)
{
////加抄送
//if (mailCC != null && mailCC.Length > 0)
//{
foreach (string cc in mailCC)
{
if (!String.IsNullOrEmpty(cc))
{
email.CC.Add(cc);
}
}
}
// foreach (string cc in mailCC)
// {
// if (!String.IsNullOrEmpty(cc))
// {
// email.CC.Add(cc);
// }
// }
//}
//主题
email.Subject = mailSubject;
//内容
email.Body = mailBody;
//附件
if (!string.IsNullOrEmpty(mailAttch))
{
string[] attachments = mailAttch.Split(';');
foreach (string file in attachments)
{
System.Net.Mail.Attachment attach = new System.Net.Mail.Attachment(file, System.Net.Mime.MediaTypeNames.Application.Octet);
//为附件添加发送时间
System.Net.Mime.ContentDisposition disposition = attach.ContentDisposition;
disposition.CreationDate = System.IO.File.GetCreationTime(file);
disposition.ModificationDate = System.IO.File.GetLastWriteTime(file);
disposition.ReadDate = System.IO.File.GetLastAccessTime(file);
//添加附件
email.Attachments.Add(attach);
}
}
////主题
//email.Subject = mailSubject;
////内容
//email.Body = mailBody;
////附件
//if (!string.IsNullOrEmpty(mailAttch))
//{
// string[] attachments = mailAttch.Split(';');
// foreach (string file in attachments)
// {
// System.Net.Mail.Attachment attach = new System.Net.Mail.Attachment(file, System.Net.Mime.MediaTypeNames.Application.Octet);
// //为附件添加发送时间
// System.Net.Mime.ContentDisposition disposition = attach.ContentDisposition;
// disposition.CreationDate = System.IO.File.GetCreationTime(file);
// disposition.ModificationDate = System.IO.File.GetLastWriteTime(file);
// disposition.ReadDate = System.IO.File.GetLastAccessTime(file);
// //添加附件
// email.Attachments.Add(attach);
// }
//}
//优先级
email.Priority = (mailPriority == "High") ? System.Net.Mail.MailPriority.High : System.Net.Mail.MailPriority.Normal;
//内容编码、格式
email.BodyEncoding = System.Text.Encoding.UTF8;
email.IsBodyHtml = true;
//email.Priority = (mailPriority == "High") ? System.Net.Mail.MailPriority.High : System.Net.Mail.MailPriority.Normal;
////内容编码、格式
//email.BodyEncoding = System.Text.Encoding.UTF8;
//email.IsBodyHtml = true;
//SMTP服务器
System.Net.Mail.SmtpClient client = new System.Net.Mail.SmtpClient(ps.EmailFwq);
client.UseDefaultCredentials = true;
//验证(Credentials 凭证)
client.Credentials = new System.Net.NetworkCredential(mailFrom, ps.EmailPass);
//处理待发的电子邮件的方法 (Delivery 发送,传输)
client.DeliveryMethod = System.Net.Mail.SmtpDeliveryMethod.Network;
//System.Net.Mail.SmtpClient client = new System.Net.Mail.SmtpClient(ps.EmailFwq);
//client.EnableSsl = false;
//client.UseDefaultCredentials = true;
////验证(Credentials 凭证)
//client.Credentials = new System.Net.NetworkCredential(mailFrom, ps.EmailPass);
////处理待发的电子邮件的方法 (Delivery 发送,传输)
//client.DeliveryMethod = System.Net.Mail.SmtpDeliveryMethod.Network;
System.Web.Mail.MailMessage mail = new System.Web.Mail.MailMessage();
try
{
mail.From = ps.EmailYx;
mail.To = string.Join(",", mailTo);
mail.Subject = mailSubject;
mail.BodyFormat = System.Web.Mail.MailFormat.Html;
mail.Body =mailBody;
mail.Cc = string.Join(",", mailCC);
mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate", "1");
mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendusername", ps.EmailYx);
mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendpassword", ps.EmailPass);
mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpserverport",ps.EmailDk);
mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpusessl", "true");
System.Web.Mail.SmtpMail.SmtpServer = ps.EmailFwq;
System.Web.Mail.SmtpMail.Send(mail);
BLL.ErrLogInfo.WriteLog("开始发送邮件");
//发送邮件
client.Send(email);
//client.Send(email);
BLL.ErrLogInfo.WriteLog("发送中...");
if (mailTo != null && mailTo.Length > 0)
{
foreach (string send in mailTo)
@@ -140,6 +155,7 @@ namespace FineUIPro.Web.common
}
catch (Exception ex)
{
BLL.ErrLogInfo.WriteLog(ex, "发送邮件失败");
if (mailTo != null && mailTo.Length > 0)
{
List<Email_SendLog> ss = new List<Email_SendLog>();
@@ -155,6 +171,7 @@ namespace FineUIPro.Web.common
newSendEmail.EmailName = send;
newSendEmail.EmailStatus = "发送失败";
newSendEmail.CreateTime = DateTime.Now;
newSendEmail.ErrorMsg = ex.Message;
newSendEmail.CreateName = "sys";
BLL.Email_Send.Email_SendLogService.AddEmail_SendLog(newSendEmail);
}
@@ -166,8 +183,6 @@ namespace FineUIPro.Web.common
finally
{
//及时释放占用的资源
email.Attachments.Clear();
email.Attachments.Dispose();
}
}
-92
View File
@@ -1,92 +0,0 @@
using System;
using System.Collections;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Net;
using System.Net.Mail;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using BLL;
namespace BLL
{
public class SendEmailService
{
/// <summary>
///
/// </summary>
/// <param name="sender">发件人</param>
/// <param name="receiver">收件人</param>
/// <param name="title">标题</param>
/// <param name="content">内容</param>
/// <param name="FulPath">附件地址</param>
/// <param name="passWord">密码</param>
/// <returns></returns>
public static bool SendEmail(string sender, string receiver, string title, string content, string FulPath, string passWord)
{
bool IsSend = true;
MailMessage mailObject = new MailMessage();
string fromAddress = sender; //发件人
MailAddress mayAddress = new MailAddress(fromAddress);
mailObject.SubjectEncoding = System.Text.Encoding.UTF8;
mailObject.BodyEncoding = System.Text.Encoding.UTF8;
//设置邮件的收件人
string address = "";
string[] mailNames = (receiver + ";").Split(';');
foreach (string name in mailNames)
{
if (name != string.Empty)
{
if (name.IndexOf('<') > 0)
{
address = name.Substring(name.IndexOf('<') + 1).Replace('>', ' ');
}
else
{
address = name.Substring(name.IndexOf('<') + 1).Replace('>', ' ');
}
mailObject.To.Add(new MailAddress(address));//收件人
}
}
mailObject.From = mayAddress;
mailObject.Subject = title;// "标题";
mailObject.Body = content;//"内容";
mailObject.IsBodyHtml = false;
//设置邮件的附件,将在客户端选择的附件先上传到服务器保存一个,然后加入到mail中
//设置邮件的附件,将在客户端选择的附件先上传到服务器保存一个,然后加入到mail中
if (!String.IsNullOrEmpty(FulPath))
{
mailObject.Attachments.Add(new Attachment(FulPath));
mailObject.DeliveryNotificationOptions = DeliveryNotificationOptions.OnSuccess;
}
SmtpClient client;
client = new SmtpClient("smtp." + fromAddress.Substring(fromAddress.LastIndexOf("@") + 1));
client.DeliveryMethod = SmtpDeliveryMethod.PickupDirectoryFromIis;
client.Timeout = 60000;
client.UseDefaultCredentials = false;
client.Credentials = new System.Net.NetworkCredential(fromAddress, passWord);
client.DeliveryMethod = SmtpDeliveryMethod.Network;
try
{
client.Send(mailObject);
return IsSend;
}
catch (Exception ex)
{
ErrLogInfo.WriteLog(ex);
return !IsSend;
}
}
}
}
File diff suppressed because one or more lines are too long
@@ -149,7 +149,7 @@ namespace FineUIPro.Web.Email_Send
bool f = MailHelper.SendNetMail(pop, mailFrom, mailTo, mailSubject, mailBody, mailAttch, mailCode, mailPriority, mailCC, out resultMessage);
if (f == true)
{
ShowNotify("Send Successfully!", MessageBoxIcon.Success);
ShowNotify("发送成功!", MessageBoxIcon.Success);
}
else
{
+9
View File
@@ -4303,54 +4303,63 @@
</Compile>
<Compile Include="Email_Send\Email_Params_Edit.aspx.cs">
<DependentUpon>Email_Params_Edit.aspx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="Email_Send\Email_Params_Edit.aspx.designer.cs">
<DependentUpon>Email_Params_Edit.aspx</DependentUpon>
</Compile>
<Compile Include="Email_Send\Email_Params_List.aspx.cs">
<DependentUpon>Email_Params_List.aspx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="Email_Send\Email_Params_List.aspx.designer.cs">
<DependentUpon>Email_Params_List.aspx</DependentUpon>
</Compile>
<Compile Include="Email_Send\Email_Pop_Edit.aspx.cs">
<DependentUpon>Email_Pop_Edit.aspx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="Email_Send\Email_Pop_Edit.aspx.designer.cs">
<DependentUpon>Email_Pop_Edit.aspx</DependentUpon>
</Compile>
<Compile Include="Email_Send\Email_SendLog_List.aspx.cs">
<DependentUpon>Email_SendLog_List.aspx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="Email_Send\Email_SendLog_List.aspx.designer.cs">
<DependentUpon>Email_SendLog_List.aspx</DependentUpon>
</Compile>
<Compile Include="Email_Send\Email_SendTemplate_Edit.aspx.cs">
<DependentUpon>Email_SendTemplate_Edit.aspx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="Email_Send\Email_SendTemplate_Edit.aspx.designer.cs">
<DependentUpon>Email_SendTemplate_Edit.aspx</DependentUpon>
</Compile>
<Compile Include="Email_Send\Email_SendTemplate_List.aspx.cs">
<DependentUpon>Email_SendTemplate_List.aspx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="Email_Send\Email_SendTemplate_List.aspx.designer.cs">
<DependentUpon>Email_SendTemplate_List.aspx</DependentUpon>
</Compile>
<Compile Include="Email_Send\Email_Send_Edit.aspx.cs">
<DependentUpon>Email_Send_Edit.aspx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="Email_Send\Email_Send_Edit.aspx.designer.cs">
<DependentUpon>Email_Send_Edit.aspx</DependentUpon>
</Compile>
<Compile Include="Email_Send\SelectRoleControl.ascx.cs">
<DependentUpon>SelectRoleControl.ascx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="Email_Send\SelectRoleControl.ascx.designer.cs">
<DependentUpon>SelectRoleControl.ascx</DependentUpon>
</Compile>
<Compile Include="Email_Send\SelectUserControl.ascx.cs">
<DependentUpon>SelectUserControl.ascx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="Email_Send\SelectUserControl.ascx.designer.cs">
<DependentUpon>SelectUserControl.ascx</DependentUpon>
+1 -1
View File
@@ -14,7 +14,7 @@
providerName="System.Data.SqlClient" />-->
</connectionStrings>
<FineUIPro DebugMode="false" CustomTheme="Metro_Dark_Blue" EnableAnimation="true" JSLibrary="All"/>
<appSettings>
<appSettings>
<!--连接字符串-->
<!--<add key="ConnectionString" value="Server=.;Database=HJGLDB;Integrated Security=False; User ID=sa;Password=1111;MultipleActiveResultSets=true;Max Pool Size = 1000;Connect Timeout=1200"/>-->
<!--系统名称-->
+68 -44
View File
@@ -13428,6 +13428,8 @@ namespace Model
private string _CreateName;
private string _ErrorMsg;
#region
partial void OnLoaded();
partial void OnValidate(System.Data.Linq.ChangeAction action);
@@ -13448,6 +13450,8 @@ namespace Model
partial void OnCreateTimeChanged();
partial void OnCreateNameChanging(string value);
partial void OnCreateNameChanged();
partial void OnErrorMsgChanging(string value);
partial void OnErrorMsgChanged();
#endregion
public Email_SendLog()
@@ -13615,6 +13619,26 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ErrorMsg", DbType="NText", UpdateCheck=UpdateCheck.Never)]
public string ErrorMsg
{
get
{
return this._ErrorMsg;
}
set
{
if ((this._ErrorMsg != value))
{
this.OnErrorMsgChanging(value);
this.SendPropertyChanging();
this._ErrorMsg = value;
this.SendPropertyChanged("ErrorMsg");
this.OnErrorMsgChanged();
}
}
}
public event PropertyChangingEventHandler PropertyChanging;
public event PropertyChangedEventHandler PropertyChanged;
@@ -22553,7 +22577,7 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(50)")]
public string ProjectId
{
get
@@ -22732,10 +22756,10 @@ namespace Model
private int _Status;
private System.Nullable<System.DateTime> _CheckTime;
private string _ReportNo;
private System.Nullable<System.DateTime> _CheckTime;
private System.Nullable<System.DateTime> _ReportTime;
#region
@@ -22754,10 +22778,10 @@ namespace Model
partial void OnAcceptanceChanged();
partial void OnStatusChanging(int value);
partial void OnStatusChanged();
partial void OnCheckTimeChanging(System.Nullable<System.DateTime> value);
partial void OnCheckTimeChanged();
partial void OnReportNoChanging(string value);
partial void OnReportNoChanged();
partial void OnCheckTimeChanging(System.Nullable<System.DateTime> value);
partial void OnCheckTimeChanged();
partial void OnReportTimeChanging(System.Nullable<System.DateTime> value);
partial void OnReportTimeChanged();
#endregion
@@ -22867,7 +22891,7 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Status", DbType="Int NOT NULL")]
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="status", Storage="_Status", DbType="Int NOT NULL")]
public int Status
{
get
@@ -22887,26 +22911,6 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="checkTime", Storage="_CheckTime", DbType="DateTime")]
public System.Nullable<System.DateTime> CheckTime
{
get
{
return this._CheckTime;
}
set
{
if ((this._CheckTime != value))
{
this.OnCheckTimeChanging(value);
this.SendPropertyChanging();
this._CheckTime = value;
this.SendPropertyChanged("CheckTime");
this.OnCheckTimeChanged();
}
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="reportNo", Storage="_ReportNo", DbType="NVarChar(50)")]
public string ReportNo
{
@@ -22927,6 +22931,26 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="checkTime", Storage="_CheckTime", DbType="DateTime")]
public System.Nullable<System.DateTime> CheckTime
{
get
{
return this._CheckTime;
}
set
{
if ((this._CheckTime != value))
{
this.OnCheckTimeChanging(value);
this.SendPropertyChanging();
this._CheckTime = value;
this.SendPropertyChanged("CheckTime");
this.OnCheckTimeChanged();
}
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="reportTime", Storage="_ReportTime", DbType="DateTime")]
public System.Nullable<System.DateTime> ReportTime
{
@@ -38567,6 +38591,8 @@ namespace Model
private string _ProjectId;
private System.Nullable<bool> _IsPMI;
private string _PipelineCode;
private string _PipelineId;
@@ -38697,6 +38723,22 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="isPMI", Storage="_IsPMI", DbType="Bit")]
public System.Nullable<bool> IsPMI
{
get
{
return this._IsPMI;
}
set
{
if ((this._IsPMI != value))
{
this._IsPMI = value;
}
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PipelineCode", DbType="NVarChar(100)")]
public string PipelineCode
{
@@ -40705,8 +40747,6 @@ namespace Model
private string _PipingClassCode;
private string _PIPClassCode;
private string _WeldingDate;
private System.Nullable<bool> _IsCancel;
@@ -41815,22 +41855,6 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PIPClassCode", DbType="NVarChar(50)")]
public string PIPClassCode
{
get
{
return this._PIPClassCode;
}
set
{
if ((this._PIPClassCode != value))
{
this._PIPClassCode = value;
}
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WeldingDate", DbType="VarChar(100)")]
public string WeldingDate
{
File diff suppressed because one or more lines are too long
+18
View File
@@ -0,0 +1,18 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
namespace WebApi.Controllers
{
public class HomeController : Controller
{
public ActionResult Index()
{
ViewBag.Title = "Home Page";
return View();
}
}
}
@@ -30,5 +30,7 @@ namespace WebApi.Controllers
}
return model;
}
}
}
-44
View File
@@ -1,44 +0,0 @@
错误信息开始=====>
错误类型:NotSupportedException
错误信息:方法“Boolean IsNullOrEmpty(System.String)”不支持转换为 SQL。
错误堆栈:
在 System.Data.Linq.SqlClient.PostBindDotNetConverter.Visitor.TranslateStringStaticMethod(SqlMethodCall mc)
在 System.Data.Linq.SqlClient.PostBindDotNetConverter.Visitor.VisitMethodCall(SqlMethodCall mc)
在 System.Data.Linq.SqlClient.SqlVisitor.Visit(SqlNode node)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitExpression(SqlExpression exp)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitUnaryOperator(SqlUnary uo)
在 System.Data.Linq.SqlClient.SqlVisitor.Visit(SqlNode node)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitExpression(SqlExpression exp)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitBinaryOperator(SqlBinary bo)
在 System.Data.Linq.SqlClient.PostBindDotNetConverter.Visitor.VisitBinaryOperator(SqlBinary bo)
在 System.Data.Linq.SqlClient.SqlVisitor.Visit(SqlNode node)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitExpression(SqlExpression exp)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitBinaryOperator(SqlBinary bo)
在 System.Data.Linq.SqlClient.PostBindDotNetConverter.Visitor.VisitBinaryOperator(SqlBinary bo)
在 System.Data.Linq.SqlClient.SqlVisitor.Visit(SqlNode node)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitExpression(SqlExpression exp)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitSelectCore(SqlSelect select)
在 System.Data.Linq.SqlClient.PostBindDotNetConverter.Visitor.VisitSelect(SqlSelect select)
在 System.Data.Linq.SqlClient.SqlVisitor.Visit(SqlNode node)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitAlias(SqlAlias a)
在 System.Data.Linq.SqlClient.SqlVisitor.Visit(SqlNode node)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitSource(SqlSource source)
在 System.Data.Linq.SqlClient.SqlVisitor.VisitSelectCore(SqlSelect select)
在 System.Data.Linq.SqlClient.PostBindDotNetConverter.Visitor.VisitSelect(SqlSelect select)
在 System.Data.Linq.SqlClient.SqlVisitor.Visit(SqlNode node)
在 System.Data.Linq.SqlClient.SqlProvider.BuildQuery(ResultShape resultShape, Type resultType, SqlNode node, ReadOnlyCollection`1 parentParameters, SqlNodeAnnotations annotations)
在 System.Data.Linq.SqlClient.SqlProvider.BuildQuery(Expression query, SqlNodeAnnotations annotations)
在 System.Data.Linq.SqlClient.SqlProvider.System.Data.Linq.Provider.IProvider.Execute(Expression query)
在 System.Data.Linq.DataQuery`1.System.Collections.Generic.IEnumerable<T>.GetEnumerator()
在 System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
在 System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
在 BLL.Email_Send.Email_SendTemplateService.GetEmailByTemplateId(String templateId, String isCc) 位置 E:\湛江巴斯夫\Basf_TCC7\HJGL\BLL\SendEmail\Email_SendTemplateService.cs:行号 124
在 BLL.TaskScheduleService.GetNDEAuditEmailTemplate(Int32 type) 位置 E:\湛江巴斯夫\Basf_TCC7\HJGL\BLL\Schedule\TaskScheduleService.cs:行号 51
在 WebApi.Controllers.TaskController.GetNDEAuditEmailTemplate() 位置 E:\湛江巴斯夫\Basf_TCC7\HJGL\WebApi\Controllers\TaskController.cs:行号 19
出错时间:05/17/2024 11:16:43
The scheduled task failed to run the unaudited point-of-mail. Procedure
出错时间:05/17/2024 11:16:43
未检测到发送人邮箱,请先配置邮箱地址
未检测到发送人邮箱,请先配置邮箱地址
+2 -2
View File
@@ -10,7 +10,7 @@
<add key="ClientValidationEnabled" value="true"/>
<add key="UnobtrusiveJavaScriptEnabled" value="true"/>
<!--连接字符串-->
<add key="ConnectionString" value="Server=.;Database=HJGLDB_ZJBSF;Integrated Security=False;User ID=sa;Password=Sh@nghai9;MultipleActiveResultSets=true;Connect Timeout=1200"/>
<add key="ConnectionString" value="Server=.\sql2016;Database=HJGLDB_ZJBSF;Integrated Security=False;User ID=sa;Password=1111;MultipleActiveResultSets=true;Connect Timeout=1200"/>
<!--版本号-->
<add key="SystemVersion" value="WebApi_V2019-09-20-001"/>
<!--附件上传物理路径-->
@@ -27,7 +27,7 @@
</system.Web>
-->
<system.web>
<compilation debug="true" targetFramework="4.8"/>
<compilation debug="false" targetFramework="4.8"/>
<httpRuntime targetFramework="4.6.1"/>
</system.web>
<system.webServer>
+1
View File
@@ -157,6 +157,7 @@
<Compile Include="Areas\HelpPage\SampleGeneration\SampleDirection.cs" />
<Compile Include="Areas\HelpPage\SampleGeneration\TextSample.cs" />
<Compile Include="Areas\HelpPage\XmlDocumentationProvider.cs" />
<Compile Include="Controllers\HomeController.cs" />
<Compile Include="Controllers\TaskController.cs" />
<Compile Include="Global.asax.cs">
<DependentUpon>Global.asax</DependentUpon>
@@ -1,312 +0,0 @@
-- 管线焊工 增加是否 PMI处理
alter table Pipeline_WeldJoint add isPMI bit NULL
GO
update Pipeline_WeldJoint set isPMI=0
GO
ALTER VIEW [dbo].[View_Pipeline_WeldJoint]
AS
/************焊口信息视图*****************/
SELECT WeldJoint.WeldJointId,
WeldJoint.ProjectId,
WeldJoint.PipelineId,
WeldJoint.WeldJointCode,
dbo.Fun_GetParseInt(WeldJoint.WeldJointCode) AS ConvertWeldJoint,
WeldJoint.WeldTypeId,
WeldJoint.Material1Id,
WeldJoint.Material2Id,
WeldJoint.ANSISCH,
WeldJoint.Thickness,
WeldJoint.Dia,
WeldJoint.Size,
WeldJoint.JointAttribute,
WeldJoint.JointArea,
WeldJoint.WeldingMethodId,
WeldJoint.IsHotProess,
WeldJoint.WeldingLocationId,
WeldJoint.WeldMatId,
WeldJoint.WeldSilkId,
WeldJoint.GrooveTypeId,
WeldJoint.PipeSegment,
WeldJoint.PipeAssembly1Id,
WeldJoint.PipeAssembly2Id,
WeldJoint.PipeAssemblyCount,
WeldJoint.HeartNo1,
WeldJoint.HeartNo2,
WeldJoint.LastTemp,
WeldJoint.CellTemp,
WeldJoint.PrepareTemp,
WeldJoint.Electricity,
WeldJoint.SystemNumber,
WeldJoint.Remark,
WeldJoint.DoneDin,
WeldJoint.Voltage,
WeldJoint.TestPackageNo,
WeldJoint.WeldingDailyCode,
WeldJoint.WeldingDailyId,
WeldJoint.BackingWelderId,
WeldJoint.CoverWelderId,
WeldJoint.PipingClassId,
WeldJoint.Specification,
WeldJoint.CancelResult,
Project.ProjectCode,
Project.ProjectName,
Pipeline.PipelineCode,
Pipeline.InstallationId,
Pipeline.UnitId,
Pipeline.SingleNumber,
Pipeline.WorkAreaId,
WeldType.WeldTypeCode,
Material1.MaterialCode AS Material1Code,
Material2.MaterialCode AS Material2Code,
WeldingMethod.WeldingMethodCode,
WeldingLocation.WeldingLocationCode,
WeldMat.ConsumablesCode AS WeldMatCode,
--WeldSilk.ConsumablesCode AS WeldSilkCode,
'' AS WeldSilkCode,
GrooveType.GrooveTypeCode,
CASE WHEN WeldJoint.WeldingDailyId IS NULL THEN '' ELSE '' END AS Is_hjName,
CASE WHEN WeldJoint.IsHotProess=1 THEN '' ELSE '' END AS IsHotProessStr,
Components1.ComponentsCode AS ComponentsCode1,
Components2.ComponentsCode AS ComponentsCode2,
BackingWelder.WelderCode AS BackingWelderCode,
BackingWelder.WelderName AS BackingWelderName,
CoverWelder.WelderCode AS CoverWelderCode,
CoverWelder.WelderName AS CoverWelderName,
(CASE WHEN CoverWelder.WelderCode IS NOT NULL AND BackingWelder.WelderCode IS NOT NULL
THEN CoverWelder.WelderCode + '/' + BackingWelder.WelderCode
ELSE (ISNULL(CoverWelder.WelderCode,'') + ISNULL(BackingWelder.WelderCode,'')) END) AS WelderCode, --焊工
(CASE WHEN Material1.MaterialCode IS NOT NULL AND Material2.MaterialCode IS NOT NULL
THEN Material1.MaterialCode + '/' + Material2.MaterialCode
ELSE (ISNULL(Material1.MaterialCode,'') + ISNULL(Material2.MaterialCode,'')) END) AS MaterialCode, --材质
pipingClass.PipingClassCode,pip.PIPClassCode,
CONVERT(VARCHAR(100), WeldingDaily.WeldingDate, 23) AS WeldingDate,
WeldJoint.IsCancel,
WeldJoint.IsPMI,
WeldJoint.IsGoldJoint,
WeldJoint.WPQId,wps.WPQCode,
WeldJoint.DetectionType,
WeldJoint.PageNum
FROM Pipeline_WeldJoint AS WeldJoint
LEFT JOIN Base_Project AS Project ON Project.ProjectId=WeldJoint.ProjectId
LEFT JOIN Pipeline_Pipeline AS Pipeline ON Pipeline.PipelineId = WeldJoint.PipelineId
LEFT JOIN Base_WeldType AS WeldType ON WeldType.WeldTypeId=WeldJoint.WeldTypeId
LEFT JOIN Base_Material AS Material1 ON Material1.MaterialId = WeldJoint.Material1Id
LEFT JOIN Base_Material AS Material2 ON Material2.MaterialId = WeldJoint.Material2Id
LEFT JOIN Base_WeldingMethod AS WeldingMethod ON WeldingMethod.WeldingMethodId=WeldJoint.WeldingMethodId
LEFT JOIN Base_WeldingLocation AS WeldingLocation ON WeldingLocation.WeldingLocationId=WeldJoint.WeldingLocationId
LEFT JOIN Base_Consumables AS WeldMat ON WeldMat.ConsumablesId=WeldJoint.WeldMatId
--LEFT JOIN Base_Consumables AS WeldSilk ON WeldSilk.ConsumablesId=WeldJoint.WeldSilkId
LEFT JOIN Base_GrooveType AS GrooveType ON GrooveType.GrooveTypeId=WeldJoint.GrooveTypeId
LEFT JOIN Base_Components AS Components1 ON Components1.ComponentsId = WeldJoint.PipeAssembly1Id
LEFT JOIN Base_Components AS Components2 ON Components2.ComponentsId = WeldJoint.PipeAssembly2Id
LEFT JOIN Welder_Welder AS BackingWelder ON BackingWelder.WelderId=WeldJoint.BackingWelderId
LEFT JOIN Welder_Welder AS CoverWelder ON CoverWelder.WelderId=WeldJoint.CoverWelderId
LEFT JOIN Pipeline_WeldingDaily AS WeldingDaily ON WeldingDaily.WeldingDailyId=WeldJoint.WeldingDailyId
LEFT JOIN Base_PipingClass AS pipingClass ON pipingClass.PipingClassId=WeldJoint.PipingClassId
LEFT JOIN dbo.Base_PIPClass pip ON pip.PIPClassId = Pipeline.PIPClassId
LEFT JOIN dbo.WPQ_WPQList wps ON wps.WPQId=WeldJoint.WPQId
GO
ALTER PROC [dbo].[sp_rpt_JointComprehensive]
@projectId NVARCHAR(50),
@workAreaId NVARCHAR(50)=NULL,
@pipelineIds NVARCHAR(MAX) = NULL
AS
/**********焊口综合信息**********/
SELECT
weldJoint.WeldJointId,
weldJoint.ProjectId,
WorkArea.WorkAreaId,
WorkArea.WorkAreaCode,
weldJoint.SystemNumber,
weldJoint.TestPackageNo,
pipeline.SingleNumber,
pipeline.PipelineCode,
pipeline.DrawingsNum,
pipingClass.PipingClassCode,pip.PIPClassCode,
weldJoint.PageNum,
weldJoint.PipeSegment,--所属管段
weldJoint.WeldJointCode,
weldType.WeldTypeCode,
weldJoint.JointAttribute,
wl.WeldingLocationCode,
weldJoint.Dia,
weldJoint.Thickness,--壁厚
weldJoint.HeartNo1,
weldJoint.HeartNo2,
com1.ComponentsName AS PipeAssembly1,
com2.ComponentsName AS PipeAssembly2,
--material.MaterialCode,
mat1.MaterialCode AS MaterialCode1,
mat2.MaterialCode AS MaterialCode2,
cw.WelderCode AS CoverWelderCode,
fw.WelderCode AS BackingWelderCode,
WeldMethod.WeldingMethodName,
medium.MediumName,
weldingDaily.WeldingDate,
weldingDaily.WeldingDailyCode,
trust.TrustBatchCode,
--TrustBatchCode.DetectionRateCode,
--TrustBatchCode.AcceptLevel,
(CASE WHEN weldJoint.IsHotProess=1 THEN '' ELSE '' END) AS IsHotProess,
null as TrustBatchCode,
null as DetectionRateCode,
null as AcceptLevel,
nde.NDEDate AS CHT_CHECKDATE,
ndeItem.NDEReportNo,
CAST(CAST(ISNULL(weldJoint.Size,0) AS REAL) AS NVARCHAR(8)) AS JOT_Size,
WeldMaterialMat.ConsumablesCode AS WMT_MatCode,
WeldMaterialMat.ConsumablesName AS WMT_Matname,
weldJoint.WeldSilkId,
--WeldMaterialSilk.ConsumablesCode AS hsCode,
--WeldMaterialSilk.ConsumablesName AS hsname,
--WeldMaterialSilk.UserFlux,
weldJoint.Specification,
wps.WPQCode,ndttype.DetectionTypeCode,NULL AS HotReportCode,
(CASE WHEN (PointBatchItem.PointState='1' OR PointBatchItem.PointState='2')
THEN (CASE WHEN PointBatchItem.IsWelderFirst=1 THEN '是首三口' ELSE '' END) ELSE '' END) AS if_dk
FROM Pipeline_WeldJoint AS weldJoint
LEFT JOIN Pipeline_Pipeline AS pipeline ON pipeline.PipelineId = weldJoint.PipelineId
LEFT JOIN Project_WorkArea AS WorkArea ON WorkArea.WorkAreaId = pipeline.WorkAreaId
LEFT JOIN Base_Material AS mat1 ON mat1.MaterialId = weldJoint.Material1Id
LEFT JOIN Base_Material AS mat2 ON mat2.MaterialId = weldJoint.Material2Id
LEFT JOIN Base_WeldingMethod AS WeldMethod ON WeldMethod.WeldingMethodId = weldJoint.WeldingMethodId
LEFT JOIN dbo.Base_WeldType weldType ON weldType.WeldTypeId = weldJoint.WeldTypeId
LEFT JOIN dbo.Base_WeldingLocation wl ON wl.WeldingLocationId = weldJoint.WeldingLocationId
LEFT JOIN Base_Medium AS medium ON medium.MediumId = pipeline.MediumId
LEFT JOIN Base_Components com1 ON com1.ComponentsId=weldJoint.PipeAssembly1Id
LEFT JOIN Base_Components com2 ON com2.ComponentsId=weldJoint.PipeAssembly2Id
LEFT JOIN Base_PipingClass AS pipingClass ON pipingClass.PipingClassId=WeldJoint.PipingClassId
LEFT JOIN dbo.Base_PIPClass pip ON pip.PIPClassId = Pipeline.PIPClassId
LEFT JOIN Pipeline_WeldingDaily AS weldingDaily ON weldingDaily.WeldingDailyId = weldJoint.WeldingDailyId
LEFT JOIN dbo.WPQ_WPQList wps ON wps.WPQId = weldJoint.WPQId
left join Welder_Welder AS fw on weldJoint.BackingWelderId = fw.WelderId
left join Welder_Welder AS cw on weldJoint.CoverWelderId = cw.WelderId
LEFT JOIN Base_Consumables AS WeldMaterialMat ON WeldMaterialMat.ConsumablesId =weldJoint.WeldMatId
--LEFT JOIN Base_Consumables AS WeldMaterialSilk ON WeldMaterialSilk.ConsumablesId =weldJoint.WeldSilkId
LEFT JOIN Batch_PointBatchItem AS PointBatchItem ON PointBatchItem.WeldJointId =weldJoint.WeldJointId
LEFT JOIN dbo.Batch_PointBatch point ON point.PointBatchId = PointBatchItem.PointBatchId
LEFT JOIN dbo.Base_DetectionType ndttype ON ndttype.DetectionTypeId = point.DetectionTypeId
LEFT JOIN dbo.Batch_BatchTrustItem trustItem ON trustItem.PointBatchItemId = PointBatchItem.PointBatchItemId
LEFT JOIN dbo.Batch_BatchTrust trust ON trust.TrustBatchId = trustItem.TrustBatchId
LEFT JOIN dbo.Batch_NDEItem ndeItem ON ndeItem.TrustBatchItemId = trustItem.TrustBatchItemId
LEFT JOIN dbo.Batch_NDE nde ON nde.NDEID = ndeItem.NDEID
WHERE weldJoint.ProjectId=@projectId
AND(pipeline.WorkAreaId=@workAreaId OR @workAreaId IS NULL)
AND (CHARINDEX(weldJoint.PipelineId,@pipelineIds)>0 or @pipelineIds IS NULl)
--AND(pipeline.PipelineCode=@pipelineCode OR @pipelineCode IS NULl)
GO
UPDATE dbo.Template_Files SET title=REPLACE(title,cast(sortindex as nvarchar(50))+'-','')
GO
UPDATE dbo.Template_Files SET SortIndex=SortIndex+1 where SortIndex>24
GO
INSERT INTO [dbo].[Template_Files]([id],[title],[filePath],[SortIndex])
VALUES('95125974-3DD4-4E16-B4F0-A9D9C9A1406D','管道焊接接头PMI检测比例确认表','',25)
GO
-- PMI处理委托
create table PMI_Delegation
(
Id nvarchar(50) not null primary key,
DelegationNo nvarchar(50) not null,
DelegationDate datetime,
ProjectId nvarchar(50) not null,
InstallationId nvarchar(50),
UnitId nvarchar(50),
DetectionStandard nvarchar(50),
Tabler nvarchar(50),
Remark nvarchar(255),
CreatedTime datetime default getdate()
)
go
---- PMI处理委托 明细
create table PMI_DelegationDetails
(
Id nvarchar(50) not null primary key,
PMIId nvarchar(50) not null,
JointId nvarchar(50) not null,
QualityNo nvarchar(255),
Acceptance nvarchar(255),
Status int not null,
CreatedTime datetime default getdate()
)
go
-- 插入PMI委托菜单
insert into Sys_Menu values('A6FB44C3-0920-4F77-862F-D814FD5E5D23','PMI检测管理','PMI detection management','',21,0,3,NUll,1)
insert into Sys_Menu values(NEWID(),'PMI委托','PMI delegation','/WeldingProcess/PMI/PMIDelegation.aspx',1,'A6FB44C3-0920-4F77-862F-D814FD5E5D23',3,NULL,1)
insert into Sys_Menu values(NEWID(),'PMI检测录入','PMI detection entry','/WeldingProcess/PMI/PMIDetectionEntry.aspx',2,'A6FB44C3-0920-4F77-862F-D814FD5E5D23',3,NULL,1)
GO
/*******PMI委托明细视图***********/
USE [HJGLDB_ZJBSF]
GO
/****** Object: View [dbo].[View_PMI_DelegationDetails] Script Date: 2024-5-13 9:06:44 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
-- 增加报告编号
ALTER TABLE dbo.PMI_DelegationDetails ADD reportNo NVARCHAR(50)
-- 增加报告日期
ALTER TABLE dbo.PMI_DelegationDetails ADD reportTime datetime
GO
ALTER VIEW [dbo].[View_PMI_DelegationDetails]
AS
/********PMI处理明细********/
SELECT
TrustItem.Id,
TrustItem.Acceptance,
TrustItem.checkTime,
TrustItem.reportTime,
TrustItem.JointId as WeldJointId,
TrustItem.status,
TrustItem.QualityNo,
TrustItem.PMIId,
Trust.ProjectId,
Trust.DelegationNo,
Trust.DelegationDate,
ISNULL(TrustItem.reportNo,Trust.DelegationNo) as reportNo,
WeldJoint.WeldJointCode,
Pipeline.PipelineCode,
WeldJoint.Specification,
Material.MaterialCode,
Pipeline.WorkAreaId
FROM PMI_DelegationDetails AS TrustItem
LEFT JOIN PMI_Delegation AS Trust ON Trust.Id=TrustItem.PMIId
LEFT JOIN Pipeline_WeldJoint AS WeldJoint ON WeldJoint.WeldJointId=TrustItem.JointId
LEFT JOIN Pipeline_Pipeline AS Pipeline ON Pipeline.PipelineId=WeldJoint.PipelineId
LEFT JOIN Base_Material AS Material ON Material.MaterialId=WeldJoint.Material1Id
GO