USE [vote]
GO
/****** Object:  Table [dbo].[users_dept]    Script Date: 10/11/2016 23:12:38 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_portal_category_parentid]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_dept] DROP CONSTRAINT [DF_portal_category_parentid]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_portal_category_orderid]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_dept] DROP CONSTRAINT [DF_portal_category_orderid]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_portal_category_depth]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_dept] DROP CONSTRAINT [DF_portal_category_depth]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_hr_csscategory_path]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_dept] DROP CONSTRAINT [DF_hr_csscategory_path]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users_dept]') AND type in (N'U'))
DROP TABLE [dbo].[users_dept]
GO
/****** Object:  Table [dbo].[users_getpwd]    Script Date: 10/11/2016 23:12:38 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_users_getpwd_createdate]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_getpwd] DROP CONSTRAINT [DF_users_getpwd_createdate]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users_getpwd]') AND type in (N'U'))
DROP TABLE [dbo].[users_getpwd]
GO
/****** Object:  Table [dbo].[users_roles]    Script Date: 10/11/2016 23:12:38 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_users_roles_issystem]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_roles] DROP CONSTRAINT [DF_users_roles_issystem]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users_roles]') AND type in (N'U'))
DROP TABLE [dbo].[users_roles]
GO
/****** Object:  Table [dbo].[users_users]    Script Date: 10/11/2016 23:12:38 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_portal_users_createdate]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_users] DROP CONSTRAINT [DF_portal_users_createdate]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_portal_users_lastlogin]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_users] DROP CONSTRAINT [DF_portal_users_lastlogin]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_users_users_avtor]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_users] DROP CONSTRAINT [DF_users_users_avtor]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_users_users_logintime]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_users] DROP CONSTRAINT [DF_users_users_logintime]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_users_users_logintime_1]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_users] DROP CONSTRAINT [DF_users_users_logintime_1]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_users_users_ismgr]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_users] DROP CONSTRAINT [DF_users_users_ismgr]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_users_users_issec]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_users] DROP CONSTRAINT [DF_users_users_issec]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_users_users_isstaff]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[users_users] DROP CONSTRAINT [DF_users_users_isstaff]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users_users]') AND type in (N'U'))
DROP TABLE [dbo].[users_users]
GO
/****** Object:  Table [dbo].[users_usersinroles]    Script Date: 10/11/2016 23:12:37 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users_usersinroles]') AND type in (N'U'))
DROP TABLE [dbo].[users_usersinroles]
GO
/****** Object:  Table [dbo].[vote_candidate]    Script Date: 10/11/2016 23:12:37 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_po_Staff_Polling]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[vote_candidate] DROP CONSTRAINT [DF_po_Staff_Polling]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_po_Staff_Created]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[vote_candidate] DROP CONSTRAINT [DF_po_Staff_Created]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_candidate]') AND type in (N'U'))
DROP TABLE [dbo].[vote_candidate]
GO
/****** Object:  Table [dbo].[vote_category]    Script Date: 10/11/2016 23:12:37 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_category]') AND type in (N'U'))
DROP TABLE [dbo].[vote_category]
GO
/****** Object:  Table [dbo].[vote_comm]    Script Date: 10/11/2016 23:12:37 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_po_comm_ispass]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[vote_comm] DROP CONSTRAINT [DF_po_comm_ispass]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_comm]') AND type in (N'U'))
DROP TABLE [dbo].[vote_comm]
GO
/****** Object:  Table [dbo].[vote_ip_block]    Script Date: 10/11/2016 23:12:37 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_ip_block]') AND type in (N'U'))
DROP TABLE [dbo].[vote_ip_block]
GO
/****** Object:  Table [dbo].[vote_subject]    Script Date: 10/11/2016 23:12:37 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_po_config_enablecomm]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[vote_subject] DROP CONSTRAINT [DF_po_config_enablecomm]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_po_config_iscurrent]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[vote_subject] DROP CONSTRAINT [DF_po_config_iscurrent]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__vote_subj__maxpe__29572725]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[vote_subject] DROP CONSTRAINT [DF__vote_subj__maxpe__29572725]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_subject]') AND type in (N'U'))
DROP TABLE [dbo].[vote_subject]
GO
/****** Object:  Table [dbo].[vote_subjects_users]    Script Date: 10/11/2016 23:12:37 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_subjects_users]') AND type in (N'U'))
DROP TABLE [dbo].[vote_subjects_users]
GO
/****** Object:  Table [dbo].[vote_users]    Script Date: 10/11/2016 23:12:37 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_users]') AND type in (N'U'))
DROP TABLE [dbo].[vote_users]
GO
/****** Object:  Table [dbo].[vote_votingdetail]    Script Date: 10/11/2016 23:12:37 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_votingdetail]') AND type in (N'U'))
DROP TABLE [dbo].[vote_votingdetail]
GO
/****** Object:  Table [dbo].[vote_votingdetail]    Script Date: 10/11/2016 23:12:37 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_votingdetail]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[vote_votingdetail](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[candidateid] [int] NULL,
	[candidatename] [nvarchar](50) NULL,
	[votekey] [nvarchar](50) NULL,
	[username] [nvarchar](50) NULL,
	[staffcode] [nvarchar](50) NULL,
	[dept] [nvarchar](50) NULL,
	[votedate] [datetime] NULL,
	[voteip] [nvarchar](50) NULL,
	[sid] [int] NULL,
	[province] [nvarchar](50) NULL,
 CONSTRAINT [PK_po_voting] 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]
END
GO
SET IDENTITY_INSERT [dbo].[vote_votingdetail] ON
INSERT [dbo].[vote_votingdetail] ([id], [candidateid], [candidatename], [votekey], [username], [staffcode], [dept], [votedate], [voteip], [sid], [province]) VALUES (1, 17, N'杨幂', N'::1', NULL, NULL, NULL, CAST(0x0000A53401192322 AS DateTime), N'223.243.233.217', 3, N'安徽省芜湖市繁昌县电信')
INSERT [dbo].[vote_votingdetail] ([id], [candidateid], [candidatename], [votekey], [username], [staffcode], [dept], [votedate], [voteip], [sid], [province]) VALUES (2, 16, N'朴宰范', N'::1', NULL, NULL, NULL, CAST(0x0000A534013E9D2F AS DateTime), N'223.243.233.217', 3, N'安徽省芜湖市繁昌县电信')
INSERT [dbo].[vote_votingdetail] ([id], [candidateid], [candidatename], [votekey], [username], [staffcode], [dept], [votedate], [voteip], [sid], [province]) VALUES (3, 16, N'朴宰范', N'::1', NULL, NULL, NULL, CAST(0x0000A534013EA3D1 AS DateTime), N'223.243.233.217', 3, N'安徽省芜湖市繁昌县电信')
INSERT [dbo].[vote_votingdetail] ([id], [candidateid], [candidatename], [votekey], [username], [staffcode], [dept], [votedate], [voteip], [sid], [province]) VALUES (4, 16, N'朴宰范', N'::1', NULL, NULL, NULL, CAST(0x0000A534013F2447 AS DateTime), N'223.243.233.217', 3, N'安徽省芜湖市繁昌县电信')
INSERT [dbo].[vote_votingdetail] ([id], [candidateid], [candidatename], [votekey], [username], [staffcode], [dept], [votedate], [voteip], [sid], [province]) VALUES (5, 16, N'朴宰范', N'::1', NULL, NULL, NULL, CAST(0x0000A534013F28FF AS DateTime), N'223.243.233.217', 3, N'安徽省芜湖市繁昌县电信')
SET IDENTITY_INSERT [dbo].[vote_votingdetail] OFF
/****** Object:  Table [dbo].[vote_users]    Script Date: 10/11/2016 23:12:37 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_users]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[vote_users](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[username] [nvarchar](50) NULL,
	[staffcode] [nvarchar](50) NULL,
	[dept] [nvarchar](50) NULL,
	[pwd] [nvarchar](50) NULL,
 CONSTRAINT [PK_vote_users] 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]
END
GO
SET IDENTITY_INSERT [dbo].[vote_users] ON
INSERT [dbo].[vote_users] ([id], [username], [staffcode], [dept], [pwd]) VALUES (3, N'李万宝', N'123', N'IT', N'123')
INSERT [dbo].[vote_users] ([id], [username], [staffcode], [dept], [pwd]) VALUES (4, N'张颖', N'456', N'IT', N'456')
INSERT [dbo].[vote_users] ([id], [username], [staffcode], [dept], [pwd]) VALUES (5, N'李军', N'789', N'HR', N'789')
INSERT [dbo].[vote_users] ([id], [username], [staffcode], [dept], [pwd]) VALUES (6, N'李建', N'111', N'HR', N'111')
INSERT [dbo].[vote_users] ([id], [username], [staffcode], [dept], [pwd]) VALUES (8, N'李万宝', N'123456', N'李万宝', N'admin')
INSERT [dbo].[vote_users] ([id], [username], [staffcode], [dept], [pwd]) VALUES (9, N'admin2', N'123456', N'IT', N'123456')
SET IDENTITY_INSERT [dbo].[vote_users] OFF
/****** Object:  Table [dbo].[vote_subjects_users]    Script Date: 10/11/2016 23:12:37 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_subjects_users]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[vote_subjects_users](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[sid] [int] NULL,
	[uid] [int] NULL,
 CONSTRAINT [PK_vote_subjects_users] 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]
END
GO
SET IDENTITY_INSERT [dbo].[vote_subjects_users] ON
INSERT [dbo].[vote_subjects_users] ([id], [sid], [uid]) VALUES (1, 3, 5)
INSERT [dbo].[vote_subjects_users] ([id], [sid], [uid]) VALUES (2, 3, 6)
INSERT [dbo].[vote_subjects_users] ([id], [sid], [uid]) VALUES (3, 3, 3)
INSERT [dbo].[vote_subjects_users] ([id], [sid], [uid]) VALUES (4, 3, 4)
INSERT [dbo].[vote_subjects_users] ([id], [sid], [uid]) VALUES (5, 1, 5)
INSERT [dbo].[vote_subjects_users] ([id], [sid], [uid]) VALUES (6, 1, 6)
INSERT [dbo].[vote_subjects_users] ([id], [sid], [uid]) VALUES (7, 1, 3)
INSERT [dbo].[vote_subjects_users] ([id], [sid], [uid]) VALUES (8, 1, 4)
INSERT [dbo].[vote_subjects_users] ([id], [sid], [uid]) VALUES (9, 1, 9)
INSERT [dbo].[vote_subjects_users] ([id], [sid], [uid]) VALUES (10, 1, 8)
SET IDENTITY_INSERT [dbo].[vote_subjects_users] OFF
/****** Object:  Table [dbo].[vote_subject]    Script Date: 10/11/2016 23:12:37 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_subject]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[vote_subject](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[starttime] [datetime] NULL,
	[endtime] [datetime] NULL,
	[voteby] [nvarchar](50) NULL,
	[counts] [int] NULL,
	[votename] [nvarchar](500) NULL,
	[commset] [int] NULL CONSTRAINT [DF_po_config_enablecomm]  DEFAULT ((1)),
	[iscurrent] [int] NULL CONSTRAINT [DF_po_config_iscurrent]  DEFAULT ((0)),
	[catid] [int] NULL,
	[law] [nvarchar](500) NULL,
	[maxperperson] [int] NULL CONSTRAINT [DF__vote_subj__maxpe__29572725]  DEFAULT ((0)),
	[theme] [nvarchar](50) NULL,
 CONSTRAINT [PK_po_config] 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]
END
GO
SET IDENTITY_INSERT [dbo].[vote_subject] ON
INSERT [dbo].[vote_subject] ([id], [starttime], [endtime], [voteby], [counts], [votename], [commset], [iscurrent], [catid], [law], [maxperperson], [theme]) VALUES (1, CAST(0x0000A17400000000 AS DateTime), CAST(0x0000B9B500000000 AS DateTime), N'votebyusername', 5, N'2015我最喜爱的狗狗投票', 0, 0, 2, N'我最喜爱的宠物投票，从即日起到2030.1.1日。', 3, N'2')
INSERT [dbo].[vote_subject] ([id], [starttime], [endtime], [voteby], [counts], [votename], [commset], [iscurrent], [catid], [law], [maxperperson], [theme]) VALUES (3, CAST(0x0000A3C700000000 AS DateTime), CAST(0x0000BDA400000000 AS DateTime), N'cookie', 3, N'2020 启明星工作室十佳员工评选', 0, 1, 1, N'1.任何一个公司，其独特的个性都需要人文精神来支撑。
2.谁是2020年启明星公司十大员工评选？答案将由你决定，活动由各部门经理推荐候选人到人事部，最后由人事部统一发布。
3 人员列表以候选人姓氏/比划排序 
4.本次线上投票权重为40%，线下专家组评分权重为60%，两者合计最终得分结果为最终排名结果。
5.每台机器最多可以投票3次，同一候选人最多可以投2票。', 24, N'3')
SET IDENTITY_INSERT [dbo].[vote_subject] OFF
/****** Object:  Table [dbo].[vote_ip_block]    Script Date: 10/11/2016 23:12:37 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_ip_block]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[vote_ip_block](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[ip] [nvarchar](50) NULL,
	[sid] [int] NULL
) ON [PRIMARY]
END
GO
/****** Object:  Table [dbo].[vote_comm]    Script Date: 10/11/2016 23:12:37 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_comm]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[vote_comm](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[uid] [int] NULL,
	[ip] [nvarchar](50) NULL,
	[ipaddress] [nvarchar](50) NULL,
	[createdate] [datetime] NULL,
	[contents] [nvarchar](300) NULL,
	[nickname] [nvarchar](50) NULL,
	[ispass] [int] NULL CONSTRAINT [DF_po_comm_ispass]  DEFAULT ((1)),
 CONSTRAINT [PK_po_comm] 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]
END
GO
/****** Object:  Table [dbo].[vote_category]    Script Date: 10/11/2016 23:12:37 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_category]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[vote_category](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[name] [nvarchar](50) NULL,
	[orderid] [int] NULL,
 CONSTRAINT [PK_vote_category] 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]
END
GO
SET IDENTITY_INSERT [dbo].[vote_category] ON
INSERT [dbo].[vote_category] ([id], [name], [orderid]) VALUES (1, N'人物评选', 1)
INSERT [dbo].[vote_category] ([id], [name], [orderid]) VALUES (2, N'风景宠物', 2)
SET IDENTITY_INSERT [dbo].[vote_category] OFF
/****** Object:  Table [dbo].[vote_candidate]    Script Date: 10/11/2016 23:12:37 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[vote_candidate]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[vote_candidate](
	[ID] [int] IDENTITY(1,1) NOT NULL,
	[username] [nvarchar](50) NULL,
	[staffcode] [nvarchar](50) NULL,
	[intro] [nvarchar](4000) NULL,
	[Image_small] [nvarchar](255) NULL,
	[Image_big] [nvarchar](500) NULL,
	[Dept] [nvarchar](50) NULL,
	[Polling] [int] NULL CONSTRAINT [DF_po_Staff_Polling]  DEFAULT ((0)),
	[Created] [datetime] NULL CONSTRAINT [DF_po_Staff_Created]  DEFAULT (getdate()),
	[CreatedBy] [nvarchar](50) NULL,
	[orderid] [int] NULL,
	[sid] [int] NULL,
	[quickinfo] [nvarchar](1000) NULL,
 CONSTRAINT [PK_po_Staff] 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]
END
GO
SET IDENTITY_INSERT [dbo].[vote_candidate] ON
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (3, N'中国', N'11111', N'<p>测试数据</p>', N'/vote/uploads/2014-03/S20140316111108.jpg', N'/vote/uploads/2014-03/201403161111_2186242_145646002_2.jpg', N'财务部', 0, CAST(0x0000A2F0008F7E28 AS DateTime), NULL, 0, 2, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (4, N'蓝色', N'AB001', N'<p><strong>西施犬四肢</strong> <br />前肢：短，骨骼发达，肌肉丰满，前肢直，与宽阔的前胸保持一致。 肩部：结实，肩部向后伸展。 后躯：骨骼发达，肌肉丰满，从后面看两后肢直。覆盖有被毛显得腿粗壮。 大腿：圆，肌肉发达。 脚：圆，结实，脚垫厚，覆盖有大量的被毛显得脚大。</p>
<p><br /><strong>西施犬尾巴</strong> <br />尾巴：有长的羽毛状装饰毛，向背部卷曲。尾根部位置高。几乎与额头水平，使体态显得匀称。 <br />运动 步态自信流畅且轻快，前躯伸展，后躯有力。 </p>
<p><strong>西施犬失格条件</strong> <br />缺陷：任何与上述各点的背离均视为缺陷，任何身体或行为上明显表现失常之犬均为失格。</p>', N'/vote/uploads/2014-03/S20140316092829.jpg', N'/vote/uploads/2014-03/201403160928_6f4bb310eef5cbeaf6039edc.jpg', N'财务部', 0, CAST(0x0000A2F0009C7AAA AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (5, N'绿绿', N'LL002', N'<p><strong>苏牧尾巴</strong> <br />尾巴：长度适中，能延伸到飞节或更低。当它休息时，尾巴下垂，但尾巴尖向上扭曲或呈旋涡是这个品种的特点。当狗在运动时或兴奋时，尾巴欢快地举起，但不应该高过背平面。</p>
<p><br /><strong>苏牧步态/运动</strong> <br />坚实，当狗以慢速小跑，面对裁判走来时，可以观察到前肢很直，足爪在地面的落点非常近。肘部不向外翻，没有&ldquo;交叉&rdquo;步，步伐没有起伏、也没有踱步、更没有滚动式步态。从后面观察时，后腿直，足爪在地面的落点非常近。在中速小跑时，后腿提供了强大的驱动力。从侧面观察，步幅大，前肢的伸展非常顺畅而平滑，使背线保持水平和稳固。当速度增加后，柯利犬的足迹趋向于单一轨迹，就是说，前肢从肩部开始呈一直线，向身体中心线倾斜；后肢从臀部开始呈一直线，向身体中心线倾斜。作为牧羊犬，要求其步态中，能随意改变速度，并且有能力在几乎瞬间改变行进方向。</p>', N'/vote/uploads/2014-03/S20140316093033.jpg', N'/vote/uploads/2014-03/201403160930_2979-1109210K43621.jpg', N'财务部', 0, CAST(0x0000A2F0009CCCB4 AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (6, N'草草', N'CC003', N'<p>草草狗简介</p>', N'/vote/uploads/2014-03/S20140316093107.jpg', N'/vote/uploads/2014-03/201403160931_44723-1110010SF972.jpg', N'财务部', 0, CAST(0x0000A2F0009CF615 AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (7, N'旺旺', N'WW004', N'<p>狗狗简介</p>', N'/vote/uploads/2014-03/S20140316093139.jpg', N'/vote/uploads/2014-03/201403160931_128199_121339678000_2.jpg', N'规划部', 0, CAST(0x0000A2F0009D148A AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (8, N'白白', N'BB004', N'<p>白白简介</p>', N'/vote/uploads/2014-03/S20140316093205.jpg', N'/vote/uploads/2014-03/201403160932_1183576_134814048_2.jpg', N'规划部', 0, CAST(0x0000A2F0009D30C2 AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (9, N'头头', N'TT005', N'<p>狗狗简介</p>', N'/vote/uploads/2014-03/S20140316093229.jpg', N'/vote/uploads/2014-03/201403160932_2541676_084617022_2.jpg', N'信息部', 0, CAST(0x0000A2F0009D5342 AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (10, N'内内', N'NN558', N'<p>内内简介</p>', N'/vote/uploads/2014-03/S20140316093300.jpg', N'/vote/uploads/2014-03/201403160932_2550321_133739011387_2.jpg', N'规划部', 0, CAST(0x0000A2F0009D73EA AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (11, N'可可', N'KK083', N'<p>可可简介</p>', N'/vote/uploads/2014-03/S20140316093328.jpg', N'/vote/uploads/2014-03/201403160933_2550321_134056036914_2.jpg', N'人事部', 0, CAST(0x0000A2F0009D906B AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (12, N'冒冒', N'MM333', N'<p>毛毛简介</p>', N'/vote/uploads/2014-03/S20140316093358.jpg', N'/vote/uploads/2014-03/201403160933_3320946_203502039000_2.jpg', N'规划部', 0, CAST(0x0000A2F0009DBD0E AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (13, N'花花', N'HH555', N'<p>花花简介</p>', N'/vote/uploads/2014-03/S20140316093429.jpg', N'/vote/uploads/2014-03/201403160934_6646641_161639565191_2.jpg', N'环境部', 0, CAST(0x0000A2F0009DDF2D AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (14, N'绿白', N'LL333', N'<p>绿白简介</p>', N'/vote/uploads/2014-03/S20140316093508.jpg', N'/vote/uploads/2014-03/201403160935_20113756.jpg', N'规划部', 0, CAST(0x0000A2F0009E0BDC AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (15, N'金毛犬', N'ML444', N'<p>&nbsp;</p>
<p><strong>金毛寻回犬历史</strong> <br />19世纪，金毛寻回犬最初的名字是苏俄追踪犬，后来被加入佛乐寻猎物犬种，寻血猎犬种，水猎鹬犬种的基因。配种的结果产生了此天生具备猎物取回能力的金毛寻回犬，善于追踪及具有敏锐嗅觉的犬种。金毛寻回犬在1908年首次展出以后，深受人们的青睐，现在世界各地仍颇受欢迎</p>
<p><br /><strong>金毛寻回犬概览</strong> <br />概览：金毛寻回犬是一个漂亮、强健、体型匀称的犬种，金毛犬有中等长度的丰厚的金色羽状饰毛（被毛不应为红色），底毛浓密，外层被毛防水。金毛犬的头骨宽，口鼻尖端细，宽阔有力。金毛犬的牙齿剪状咬合，上门牙的内侧与下门牙接触。金毛犬的鼻镜呈黑色，眼睛黑褐色且眼缘较深，表情友善。金毛犬的耳朵中等大小且下垂，颈部和后躯肌肉发达，胸腔宽厚。尾巴长但不卷曲。金毛寻回犬的整体外型：浑身匀称，有力，活泼，行动稳健，表情友善,个性热情</p>
<p><br /><strong>金毛寻回犬性格</strong> <br />金毛寻回犬友善、可靠、可信赖。金毛寻回犬在自然境况下，对其它犬或人表现出喜争斗或敌意；天生胆怯、神经紧张，是与金毛的特质相悖的</p>
<p><br /><strong>金毛寻回犬气质</strong> <br />金毛寻回犬温顺、聪明、拥有天生的工作能力，性情温和，友善而自信</p>', N'/vote/uploads/2014-03/S20140316093549.jpg', N'/vote/uploads/2014-03/201403160935_20125810393516848.jpg', N'信息部', 0, CAST(0x0000A2F0009E7F81 AS DateTime), NULL, 0, 1, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (16, N'朴宰范', N'HG0001', N'<p><strong>朴宰范简介</strong></p>
<p>美籍韩裔，韩国最大艺人公司 SidusHQ旗下艺人。2008年以偶像组合2pm队长身份出道，2009年退队。2010年初与JYP解除合约，现为solo歌手、B-boy dancer、rapper、音乐制作人，songwriter, composer, model, choreographer。</p>
<p>&nbsp;</p>
<p><strong>主要事件</strong></p>
<p>2008年9月4日，在Mnet《M!Countdown》以歌曲〈10分满分的10分〉正式出道。</p>
<p>2010年3月因在youtube上传了自己改编歌词并且翻唱的B.O.B的《Nothing on you》，在不到24小时的时间内达到了200万的点击率，而一跃被国际认知，奠定了其在欧美的人气。</p>
<p>2010年6月，朴宰范重返韩国，独立担当自己专辑的作词作曲制作人，成为了韩国歌坛新一代实力派偶像歌手。</p>
<p>&nbsp;</p>', N'/vote/uploads/2014-03/S20140316095459.jpg', N'/vote/uploads/2014-03/201403160954_2011021718093739741_138895.jpg', N'人事部', 4, CAST(0x0000A2F000A3CF48 AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (17, N'杨幂', N'YM0002', N'<p>&nbsp;</p>
<p><strong>歌手简介</strong></p>
<p>中国女演员、歌手、电视剧制片人。出生于北京。毕业于北京电影学院表演系2005级本科班。[1]她曾获得第24届、第26届中国电视金鹰奖提名[2-3]，第17届上海电视节白玉兰奖两项提名，并且获得一项白玉兰奖[4-5]。</p>
<p>&nbsp;</p>
<p><strong>主要事件</strong></p>
<p>杨幂在拍片现场收养了一只被遗弃的小猫，并因此收到了善待动物组织亚洲分部授予的&ldquo;影响力&rdquo;奖。[120]</p>
<p>2010年4月20日，百度百科人物词条&ldquo;杨幂&rdquo;以近600万次的访问量获评&ldquo;最受欢迎人物词条&rdquo;，杨幂也因此获得&ldquo;百科女王&rdquo;称号。[121]</p>
<p>2010年11月10日，杨幂获得了佛教上师赠送的新名字&ldquo;紫曦&rdquo;。[122-123]</p>', N'/vote/uploads/2014-03/S20140316095643.jpg', N'/vote/uploads/2014-03/201403160956_14313-niBecc.jpg', N'财务部', 1, CAST(0x0000A2F000A457F7 AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (18, N'金秀贤', N'JX333', N'<p><strong>歌手简介</strong></p>
<p>金秀贤，1988年2月16日生于首尔，韩国演员。</p>
<p>&nbsp;</p>
<p><strong>主要事件</strong></p>
<p>2007年出演电视剧《泡菜奶酪微笑》进入演艺圈。</p>
<p>2009年因饰演《圣诞节会下雪吗》和《巨人》中主人公的少年时代而展露锋芒。</p>
<p>2011年首次在电视剧《Dream High》中担当主角，并在KBS演技大赏中独揽三奖。</p>
<p>2012年主演的电视剧《拥抱太阳的月亮》收视率达42.2%，荣获百想艺术大赏最佳男演员奖[1]；同年电影处女作《盗贼同盟》荣登韩国影史票房冠军，凭借此片获得韩国青龙电影奖人气明星奖[2]，</p>', N'/vote/uploads/2014-03/S20140316095837.jpg', N'/vote/uploads/2014-03/201403160958_f1.jpg', N'环境部', 0, CAST(0x0000A2F000A4B98F AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (19, N'刘亦菲', N'LJY003', N'<p><strong>歌手简介</strong></p>
<p>原名安风、刘茜美子，中国女演员、歌手，1987年8月25日出生于湖北省武汉市，毕业于北京电影学院2002级表演系本科班。</p>
<p><strong>主要事件</strong></p>
<p>出道后先后出演《金粉世家》、《天龙八部》、《仙剑奇侠传》人气大增并凭借《神雕侠侣》中的小龙女一角而受到广泛关注。</p>
<p>2006年，刘亦菲推出首张个人专辑《刘亦菲》。</p>
<p>2008年与成龙、李连杰等合作《功夫之王》成功进军好莱坞。之后主演的《新倩女幽魂》《鸿门宴》《四大名捕》《四大名捕2》《铜雀台》等多部电影均票房过亿。</p>', N'/vote/uploads/2014-03/S20140316095959.jpg', N'/vote/uploads/2014-03/201403160959_sy_2012021019181724906.jpg', N'环境部', 0, CAST(0x0000A2F000A549CB AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (20, N'李进', N'LJ444', N'<p>暂无介绍，测试数据</p>', N'/vote/uploads/2014-03/S20140316100159.jpg', N'/vote/uploads/2014-03/201403161001_27b922b4d7da5c2ebb63d1818102a55c.jpg', N'信息部', 0, CAST(0x0000A2F000A56D7A AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (21, N'李艳', N'LKD0999', N'<p>测试数据，仅供演示</p>', N'/vote/uploads/2014-03/S20140316100228.jpg', N'/vote/uploads/2014-03/201403161002_default.jpg', N'信息部', 0, CAST(0x0000A2F000A58F03 AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (22, N'李天', N'BK003', N'<p>测试数据，仅供演示</p>', N'/vote/uploads/2014-03/S20140316100257.jpg', N'/vote/uploads/2014-03/201403161002_20120304012618147.jpg', N'环境部', 0, CAST(0x0000A2F000A5AB23 AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (23, N'张兰', N'ZD555', N'<p>测试数据，仅供演示</p>', N'/vote/uploads/2014-03/S20140316100321.jpg', N'/vote/uploads/2014-03/201403161003_UT14S33DG8U9.jpg', N'环境部', 0, CAST(0x0000A2F000A5CDA9 AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (24, N'高云翔', N'FKK333', N'<p><strong>1.基本资料</strong></p>
<p>高云翔，1982年8月15日出生于天津，中国内地男演员，毕业于上海戏剧学院表演系本科。</p>
<p>2002年出演首部电视剧《壮志雄心》；2003年主演情感剧《平淡生活》男主角而受到关注；2011年主演电视剧《新玉观音》并凭借该剧获得华鼎奖传奇类题材电视剧最佳男演员[1]&nbsp; ；2013年主演电视剧《宫锁连城》和电影《毒战》。</p>
<p>2011年8月21日，高云翔和董璇在北京柏悦酒店幸福完婚。</p>
<p>参演电视剧《多情江山》，于2015年9月21日在浙江卫视中国蓝剧场播出。[2]&nbsp;</p>
<p>&nbsp;</p>
<p><strong>2.演艺经历</strong></p>
<p>2002年出演首部电视剧《壮志雄心》进入娱乐圈；2003年主演海岩小说改编的情感剧《平淡生活》中的拳击手周月。[3]&nbsp;</p>
<p>2007与孙俪、唐于鸿主演的电视剧《一世情缘》播出，高云翔饰演男一号飞行英雄唐腾；同年出演首部电影《我的美女老板》。[4-6]&nbsp;</p>
<p>2008年主演的家庭伦理剧《小家大事》播出，高云翔饰演大孝子朱大器，同年出演青春励志剧《生于80后》；2009年在《保姆妈妈》中饰演安子晨。[7-9]&nbsp;</p>
<p>2011年主演电视剧《新玉观音》并凭借该剧获得华鼎奖传奇类题材电视剧最佳男演员；2012年与妻子董璇合作主演都市爱情剧《婆婆也是妈》，担任男一号李伟大。[10-11]&nbsp;</p>
<p>2013年主演宫廷剧《宫锁连城》和动作悬疑电影《毒战》；同年出演自雪灵之小说《结缘》改编的电视剧《天地情缘》，饰演翥凤王朝的五皇子宗政凤璘。[12-15]&nbsp;</p>
<p>2015年高云翔参演古装宫廷剧《芈月传》，与孙俪合作，饰演义渠王翟骊一角。[16]&nbsp; 9月18日惊悚片《人皮拼图》在全国各大影院公映，影片男女主人公高云翔、熊乃瑾惊悚亮相[17]&nbsp; 。2015年9月21日，高云翔主演的《多情江山》登陆浙江卫视。[18]&nbsp;</p>
<p>3.更多图片</p>
<p><a href="/vote/uploads/2015-10/201510171148_2.jpg" target="_blank"> <img style="max-width: 700px;" src="/vote/uploads/2015-10/201510171148_2.jpg" alt="" /></a></p>
<p><a href="/vote/uploads/2015-10/201510171148_1.jpg" target="_blank"> <img style="max-width: 700px;" src="/vote/uploads/2015-10/201510171148_1.jpg" alt="" /></a></p>', N'/vote/uploads/2014-03/S20140316100402.jpg', N'/vote/uploads/2014-03/201403161003_12370327_m_12370329_245.jpg', N'规划部', 0, CAST(0x0000A2F000A6028D AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (25, N'王菲', N'RRRR4', N'<p>测试数据，仅供演示</p>', N'/vote/uploads/2014-03/S20140316100437.jpg', N'/vote/uploads/2014-03/201403161004_20110415182714-2102308958.jpg', N'规划部', 0, CAST(0x0000A2F000A61D24 AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (26, N'龙女', N'DD44', N'<p>测试数据，仅供演示</p>', N'/vote/uploads/2014-03/S20140316100513.jpg', N'/vote/uploads/2014-03/201403161005_A.jpg', N'财务部', 0, CAST(0x0000A2F000A649D4 AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (27, N'王军', N'FF44', N'<p>测试数据，仅供演示</p>', N'/vote/uploads/2014-03/S20140316100546.jpg', N'/vote/uploads/2014-03/201403161005_862804_141653038675_2.jpg', N'信息部', 0, CAST(0x0000A2F000A674DB AS DateTime), NULL, 0, 3, NULL)
INSERT [dbo].[vote_candidate] ([ID], [username], [staffcode], [intro], [Image_small], [Image_big], [Dept], [Polling], [Created], [CreatedBy], [orderid], [sid], [quickinfo]) VALUES (28, N'海南', N'DDK333', N'<p>测试数据</p>', N'/vote/uploads/2014-03/S20140316111420.jpg', N'/vote/uploads/2014-03/201403161114_20071029173437878_2.jpg', N'环境部', 0, CAST(0x0000A2F000B8DA90 AS DateTime), NULL, 0, 2, NULL)
SET IDENTITY_INSERT [dbo].[vote_candidate] OFF
/****** Object:  Table [dbo].[users_usersinroles]    Script Date: 10/11/2016 23:12:37 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users_usersinroles]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[users_usersinroles](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[uid] [int] NULL,
	[rolename] [nvarchar](50) NULL,
 CONSTRAINT [PK_portal_usersinroles] 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]
END
GO
SET IDENTITY_INSERT [dbo].[users_usersinroles] ON
INSERT [dbo].[users_usersinroles] ([id], [uid], [rolename]) VALUES (1, 1, N'Administrators')
SET IDENTITY_INSERT [dbo].[users_usersinroles] OFF
/****** Object:  Table [dbo].[users_users]    Script Date: 10/11/2016 23:12:38 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users_users]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[users_users](
	[uid] [int] IDENTITY(1,1) NOT NULL,
	[username] [nvarchar](256) NOT NULL,
	[adpath] [nvarchar](1024) NULL,
	[firstname] [nvarchar](50) NULL,
	[lastname] [nvarchar](50) NULL,
	[city] [nvarchar](256) NULL,
	[Office] [nvarchar](256) NULL,
	[Description] [nvarchar](1024) NULL,
	[Tel] [nvarchar](128) NULL,
	[fax] [nvarchar](128) NULL,
	[email] [nvarchar](256) NULL,
	[MailType] [nvarchar](128) NULL,
	[Title] [nvarchar](128) NULL,
	[Department] [nvarchar](128) NULL,
	[Company] [nvarchar](128) NULL,
	[Password] [nvarchar](128) NULL,
	[displayname] [nvarchar](128) NULL,
	[StaffCode] [nvarchar](128) NULL,
	[IsAccountActive] [int] NULL,
	[createdate] [datetime] NULL CONSTRAINT [DF_portal_users_createdate]  DEFAULT (getdate()),
	[lastlogin] [datetime] NULL CONSTRAINT [DF_portal_users_lastlogin]  DEFAULT (getdate()),
	[sex] [nvarchar](50) NULL,
	[avtor] [nvarchar](300) NULL CONSTRAINT [DF_users_users_avtor]  DEFAULT ('avtor.jpg'),
	[logintimes] [int] NULL CONSTRAINT [DF_users_users_logintime]  DEFAULT ((0)),
	[ip] [nvarchar](50) NULL,
	[logintime] [int] NULL CONSTRAINT [DF_users_users_logintime_1]  DEFAULT ((0)),
	[intro] [nvarchar](500) NULL,
	[ismgr] [int] NULL CONSTRAINT [DF_users_users_ismgr]  DEFAULT ((0)),
	[issec] [int] NULL CONSTRAINT [DF_users_users_issec]  DEFAULT ((0)),
	[isstaff] [int] NULL CONSTRAINT [DF_users_users_isstaff]  DEFAULT ((1)),
	[mobile] [nvarchar](50) NULL,
	[pinyin] [nvarchar](50) NULL,
 CONSTRAINT [PK_portal_users_1] PRIMARY KEY CLUSTERED 
(
	[uid] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]
END
GO
SET IDENTITY_INSERT [dbo].[users_users] ON
INSERT [dbo].[users_users] ([uid], [username], [adpath], [firstname], [lastname], [city], [Office], [Description], [Tel], [fax], [email], [MailType], [Title], [Department], [Company], [Password], [displayname], [StaffCode], [IsAccountActive], [createdate], [lastlogin], [sex], [avtor], [logintimes], [ip], [logintime], [intro], [ismgr], [issec], [isstaff], [mobile], [pinyin]) VALUES (1, N'admin', NULL, NULL, NULL, NULL, N'', NULL, N'', N'', N'admin@sohu.com', NULL, N'', N'', NULL, N'CE-0B-FD-15-05-9B-68-D6-76-88-88-4D-7A-3D-3E-8C', N'admin', N'', NULL, CAST(0x00009F96010E989A AS DateTime), CAST(0x0000A60C0131E3C3 AS DateTime), N'', N'avtor.jpg', 31, N'::1', 0, N'', 0, 0, 1, NULL, NULL)
SET IDENTITY_INSERT [dbo].[users_users] OFF
/****** Object:  Table [dbo].[users_roles]    Script Date: 10/11/2016 23:12:38 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users_roles]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[users_roles](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[rolename] [nvarchar](50) NULL,
	[issystem] [int] NULL CONSTRAINT [DF_users_roles_issystem]  DEFAULT ((0)),
	[roletype] [nvarchar](50) NULL,
 CONSTRAINT [PK_users_roles] 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]
END
GO
SET IDENTITY_INSERT [dbo].[users_roles] ON
INSERT [dbo].[users_roles] ([id], [rolename], [issystem], [roletype]) VALUES (1, N'Administrators', 1, N'')
SET IDENTITY_INSERT [dbo].[users_roles] OFF
/****** Object:  Table [dbo].[users_getpwd]    Script Date: 10/11/2016 23:12:38 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users_getpwd]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[users_getpwd](
	[id] [int] NOT NULL,
	[uid] [int] IDENTITY(1,1) NOT NULL,
	[display] [nvarchar](50) NULL,
	[createdate] [datetime] NULL CONSTRAINT [DF_users_getpwd_createdate]  DEFAULT (getdate()),
 CONSTRAINT [PK_users_getpwd] 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]
END
GO
/****** Object:  Table [dbo].[users_dept]    Script Date: 10/11/2016 23:12:38 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users_dept]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[users_dept](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[catname] [nvarchar](50) NULL,
	[parentid] [int] NULL CONSTRAINT [DF_portal_category_parentid]  DEFAULT ((0)),
	[orderid] [int] NULL CONSTRAINT [DF_portal_category_orderid]  DEFAULT ((0)),
	[depth] [int] NULL CONSTRAINT [DF_portal_category_depth]  DEFAULT ((1)),
	[note] [nvarchar](200) NULL,
	[path] [nvarchar](1000) NULL CONSTRAINT [DF_hr_csscategory_path]  DEFAULT (''),
	[types] [nvarchar](50) NULL,
 CONSTRAINT [PK_users_dept] 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]
END
GO
SET IDENTITY_INSERT [dbo].[users_dept] ON
INSERT [dbo].[users_dept] ([id], [catname], [parentid], [orderid], [depth], [note], [path], [types]) VALUES (1, N'人事部', 0, 1, 1, NULL, N'', NULL)
INSERT [dbo].[users_dept] ([id], [catname], [parentid], [orderid], [depth], [note], [path], [types]) VALUES (2, N'财务部', 0, 2, 1, NULL, N'', NULL)
INSERT [dbo].[users_dept] ([id], [catname], [parentid], [orderid], [depth], [note], [path], [types]) VALUES (3, N'环境部', 0, 3, 1, NULL, N'', NULL)
INSERT [dbo].[users_dept] ([id], [catname], [parentid], [orderid], [depth], [note], [path], [types]) VALUES (4, N'规划部', 0, 4, 1, NULL, N'', NULL)
INSERT [dbo].[users_dept] ([id], [catname], [parentid], [orderid], [depth], [note], [path], [types]) VALUES (5, N'信息部', 0, 5, 1, NULL, N'', NULL)
SET IDENTITY_INSERT [dbo].[users_dept] OFF
