﻿

----------------------Mostafa 2021-07-07---------------
CREATE TABLE [dbo].[OrientationsQuestion](
[OrientationQuestionCode] [int] IDENTITY(1,1) NOT NULL,
[QuestionTemplateCode] [int] NOT NULL,
[OrientationCode] [int] NOT NULL,
CONSTRAINT [PK_OrientationsQuestion] PRIMARY KEY CLUSTERED 
(
[OrientationQuestionCode] 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

ALTER TABLE [dbo].[OrientationsQuestion]  WITH CHECK ADD  CONSTRAINT [FK_dbo.OrientationsQuestion_Orientations] FOREIGN KEY([OrientationCode])
REFERENCES [dbo].[Orientations] ([OrientationCode])
GO

ALTER TABLE [dbo].[OrientationsQuestion] CHECK CONSTRAINT [FK_dbo.OrientationsQuestion_Orientations]
GO

ALTER TABLE [dbo].[OrientationsQuestion]  WITH CHECK ADD  CONSTRAINT [FK_OrientationsQuestion_Rec_QuestionTemplate] FOREIGN KEY([QuestionTemplateCode])
REFERENCES [dbo].[Rec_QuestionTemplate] ([QuestionTemplateCode])
GO

ALTER TABLE [dbo].[OrientationsQuestion] CHECK CONSTRAINT [FK_OrientationsQuestion_Rec_QuestionTemplate]
GO
---------------------End 2021-07-07------------------
---------------------Hammad 2021-07-10---------------
INSERT [dbo].[SystemMenu] ([SystemMenuCode], [Name], [Arabic_Name], [ParentID], [ControllerName], [ActionName], [ImageURL], [HTTPMethod], [Sequence], [IsVisible], [ShowInPrivilegePage])
 VALUES (547, N'Evaluation Curve', N'منحنى التقيم', 161, N'/Appraisal/EmployeeEvaluationCurve', N'Index', N'fa fa-thumb-tack', N'get', 17, 1, 1)
 Go

 INSERT [dbo].[SystemMenuModule] ([SystemMenuCode], [AppModuleCode]) VALUES (547, 8)
 Go
 INSERT [dbo].[SecurityPrivilege] ([ID], [DescriptionAR], [DescriptionEN], [SystemMenuCode], [PrivilegeType]) VALUES (10090, N' منحنى التقيم', N'Evaluation Curve', 547, 1)
INSERT [dbo].[SecurityPrivilege] ([ID], [DescriptionAR], [DescriptionEN], [SystemMenuCode], [PrivilegeType]) VALUES (10091, N'عرض  منحنى التقيم', N'View Evaluation Curve', 547, 2)
INSERT [dbo].[SecurityPrivilege] ([ID], [DescriptionAR], [DescriptionEN], [SystemMenuCode], [PrivilegeType]) VALUES (10092, N'إضافة منحنى التقيم', N'Save Evaluation Curve', 547, 2)
Go
---------------------End 2021-07-10---------------

---------------------Mostafa 2021-07-11---------------


INSERT [dbo].[SystemMenu] ([SystemMenuCode], [Name], [Arabic_Name], [ParentID], [ControllerName], [ActionName], [ImageURL], [HTTPMethod], [Sequence], [IsVisible], [ShowInPrivilegePage])
VALUES(548,N'Employees Groups',N'مجموعات الموظفين',27,N'/Personal/EmployeeGroup',N'Index','fa fa-thumb-tack',N'get',3,1,1)
Go

INSERT[dbo].[SystemMenuModule]( [SystemMenuCode], [AppModuleCode]) VALUES(548,2)
Go

INSERT[dbo].[SecurityPrivilege]([ID], [DescriptionAR], [DescriptionEN], [SystemMenuCode], [PrivilegeType]) VALUES(2226,N'مجموعات الموظفين',N'Employees Groups',548,1)

INSERT[dbo].[SecurityPrivilege]([ID], [DescriptionAR], [DescriptionEN], [SystemMenuCode], [PrivilegeType]) VALUES(2227,N'عرض مجموعات الموظفين',N'View Employees Groups',548,2)

INSERT[dbo].[SecurityPrivilege]([ID], [DescriptionAR], [DescriptionEN], [SystemMenuCode], [PrivilegeType]) VALUES(2228,N'إضافة مجموعات الموظفين',N'Add Employees Groups',548,2)

INSERT[dbo].[SecurityPrivilege]([ID], [DescriptionAR], [DescriptionEN], [SystemMenuCode], [PrivilegeType]) VALUES(2229,N'تعديل مجموعات الموظفين',N'Edit Employees Groups',548,2)

INSERT[dbo].[SecurityPrivilege]([ID], [DescriptionAR], [DescriptionEN], [SystemMenuCode], [PrivilegeType]) VALUES(2230,N'حذف مجموعات الموظفين',N'Delete Employees Groups',548,2)

INSERT[dbo].[SecurityPrivilege]([ID], [DescriptionAR], [DescriptionEN], [SystemMenuCode], [PrivilegeType]) VALUES(2231,N'حفظ مجموعات الموظفين',N'Save Employees Groups',548,2)
Go
CREATE TABLE [dbo].[EmployeeGroup](
	[EmployeeGroupCode] [int] IDENTITY(1,1) NOT NULL,
	[Name] [nvarchar](150) NULL,
	[Arabic_Name] [nvarchar](150) NULL,
	[IsDefault] [bit] NOT NULL,
	[CreatedBy] [int] NOT NULL,
	[CreationDate] [datetime] NOT NULL,
	[ModifiedBy] [int] NULL,
	[ModificationDate] [datetime] NULL,
 CONSTRAINT [PK_EmployeeGroup] PRIMARY KEY CLUSTERED 
(
	[EmployeeGroupCode] 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

---------------------End 2021-07-11---------------
---------------------Ali 2021-07-11---------------


ALTER TABLE dbo.SecurityUserBranch
	DROP CONSTRAINT FK_SecurityUserBranch_Branch
GO

---------------------End 2021-07-11---------------


