SET NOCOUNT ON;

/* Template表 */
SET IDENTITY_INSERT template ON
delete from template where pkId >= 45
insert into template (pkId,name,remark,code,previewTemplate,typeId)  values ( 45,'投稿模板','投稿模板','Contribute','Contribute.htm',2)
insert into template (pkId,name,remark,code,previewTemplate,typeId)  values ( 46,'投稿统计','投稿统计','contributeStat','contributeStat.htm',2)
insert into template (pkId,name,remark,code,previewTemplate,typeId)  values ( 47,'投稿排行','投稿排行','contributeTop','contributeTop.htm',2)
insert into template (pkId,name,remark,code,previewTemplate,typeId)  values ( 48,'最新投稿','最新投稿','latestContribute','latestContribute.htm',2)
insert into template(pkId,name,remark,code,previewTemplate,typeId) values(49,'游戏文字列表','游戏文字列表','gameTitleList','gameTitleList.htm',2)
insert into template(pkId,name,remark,code,previewTemplate,typeId) values(50,'游戏图片列表','游戏图片列表','gamePicList','gamePicList.htm',2)
insert into template(pkId,name,remark,code,previewTemplate,typeId) values(51,'最新游戏列表','最新游戏列表','latestGame','latestGame.htm',2)
insert into template(pkId,name,remark,code,previewTemplate,typeId) values(52,'游戏点击排名','游戏点击排名','gameTop','gameTop.htm',2)
insert into template(pkId,name,remark,code,previewTemplate,typeId) values(53,'游戏推荐','游戏推荐','gameList','gameList.htm',2)
insert into template(pkId,name,remark,code,previewTemplate,typeId) values(54,'历史上的今天','历史上的今天','todayInHistory','todayInHistory.htm',2)
insert into template(pkId,name,remark,code,previewTemplate,typeId) values(55,'历史上的今天查询','历史上的今天查询','searchTodayInHistory','searchTodayInHistory.htm',4)
insert into template(pkId,name,remark,code,previewTemplate,typeId) values(56,'历史上的今天小列表','历史上的今天小列表','todayInHistoryShort','todayInHistoryShort.htm',2)
insert into template(pkId,name,remark,code,previewTemplate,typeId) values(57,'历史上的今天图片','历史上的今天图片','todayInHistoryPic','todayInHistoryPic.htm',2)
SET IDENTITY_INSERT template OFF



/* Privilege表 */
SET IDENTITY_INSERT Privilege ON
delete from Privilege
insert into Privilege(pkId,name,nameRemark,accreditValue,accreditRemark,showType,itemEnglish,itemChinese) values(1,'canAuditNews','信息发布审核','0|1','禁止|允许','Select','forAuditing|audited','待审|通过')
insert into Privilege(pkId,name,nameRemark,accreditValue,accreditRemark,showType,itemEnglish,itemChinese) values(2,'canAuditContribute','角色','0|1','投稿人|审核员','Select','forAuditing|audited|notAudit|rejected|locked|onEdit','待审|通过|未审|退稿|锁定退稿|未投稿')
insert into Privilege(pkId,name,nameRemark,accreditValue,accreditRemark,showType,itemEnglish,itemChinese) values(3,'canSetRecommand','推荐','0|1','禁止|允许','Select','noRecomend|recommend','否|推荐')
insert into Privilege(pkId,name,nameRemark,accreditValue,accreditRemark,showType,itemEnglish,itemChinese) values(4,'canSetTop','固顶','0|1','禁止|允许','Select','noTop|top','取消|固顶')
insert into Privilege(pkId,name,nameRemark,accreditValue,accreditRemark,showType,itemEnglish,itemChinese) values(5,'canAdd','添加','0|1','禁止|允许','Select','','')
insert into Privilege(pkId,name,nameRemark,accreditValue,accreditRemark,showType,itemEnglish,itemChinese) values(6,'canEdit','修改','0|1','禁止|允许','Select','','')
insert into Privilege(pkId,name,nameRemark,accreditValue,accreditRemark,showType,itemEnglish,itemChinese) values(7,'canDelete','删除','0|1','禁止|允许','Select','','')
insert into Privilege(pkId,name,nameRemark,accreditValue,accreditRemark,showType,itemEnglish,itemChinese) values(8,'defaultPassed','默认审核','0|1','未审|已审','Select','','')
insert into Privilege(pkId,name,nameRemark,accreditValue,accreditRemark,showType,itemEnglish,itemChinese) values(9,'manageAll','管理所有','0|1','否|是','Select','','')
SET IDENTITY_INSERT Privilege OFF


/* templatePrivilege表 */
set identity_insert templatePrivilege on
delete from templatePrivilege
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 1,1,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 2,1,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 3,1,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 4,1,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 5,1,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 6,1,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 7,3,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 8,3,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 9,3,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 10,3,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 11,3,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 12,4,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 13,4,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 14,4,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 15,4,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 16,4,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 17,5,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 18,5,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 19,5,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 20,5,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 21,5,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 22,6,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 23,6,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 24,6,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 25,6,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 26,6,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 27,12,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 28,12,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 29,12,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 30,12,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 31,12,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 32,12,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 33,14,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 34,14,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 35,14,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 36,15,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 37,15,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 38,15,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 39,15,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 40,15,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 41,16,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 42,16,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 43,16,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 44,16,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 45,16,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 46,23,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 47,23,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 48,23,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 49,23,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 50,23,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 51,23,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 52,24,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 53,24,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 54,24,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 55,24,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 56,24,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 57,24,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 58,25,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 59,25,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 60,25,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 61,25,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 62,25,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 63,25,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 64,26,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 65,26,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 66,26,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 67,26,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 68,26,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 69,26,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 70,27,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 71,27,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 72,27,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 73,27,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 74,27,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 75,27,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 76,32,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 77,32,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 78,32,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 79,32,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 80,32,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 81,34,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 82,34,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 83,34,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 84,34,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 85,34,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 86,35,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 87,35,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 88,35,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 89,35,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 90,35,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 91,36,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 92,36,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 93,36,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 94,36,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 95,36,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 96,36,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 97,37,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 98,37,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 99,37,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 100,37,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 101,37,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 102,45,2)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 103,45,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 104,45,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 105,45,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 106,45,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 107,45,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 108,1,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 109,3,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 110,4,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 111,5,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 112,6,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 113,12,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 114,14,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 115,15,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 116,16,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 117,23,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 118,24,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 119,25,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 120,26,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 121,27,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 122,32,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 123,34,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 124,35,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 125,36,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 126,37,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 127,1,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 128,3,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 129,4,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 130,5,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 131,6,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 132,12,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 133,14,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 134,15,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 135,16,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 136,23,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 137,24,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 138,25,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 139,26,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 140,27,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 141,32,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 142,34,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 143,35,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 144,36,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 145,37,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 146,43,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 147,43,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 148,43,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 149,43,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 150,43,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 151,43,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 152,43,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 153,43,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 154,49,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 155,49,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 156,49,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 157,49,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 158,49,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 159,49,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 160,49,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 161,49,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 162,50,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 163,50,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 164,50,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 165,50,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 166,50,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 167,50,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 168,50,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 169,50,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 170,53,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 171,53,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 172,53,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 173,53,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 174,53,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 175,53,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 176,53,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 177,53,9)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 178,54,1)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 179,54,3)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 180,54,4)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 181,54,5)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 182,54,6)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 183,54,7)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 184,54,8)
insert into templatePrivilege (pkId,templateId,privilegeId)  values ( 185,54,9)
set identity_insert templatePrivilege off

/* siteOtherProperty表 */
SET IDENTITY_INSERT siteOtherProperty ON
delete from siteOtherProperty where pkId = 1
insert into siteOtherProperty(pkId,newsDefaultClick,showNewHours,showHotClick) values(1,50,24,100)
SET IDENTITY_INSERT siteOtherProperty OFF

/* menu添加下属单位投稿 */
SET IDENTITY_INSERT menu ON
delete from menu where pkId=-1
insert into menu(pkId, name, ordering, bigClassId, modeId, gradeId, gate, displayRoot, userIntercept, interceptNums) values (-1, '子站投稿', -1, -1, 1,1,0,1,0,0)
SET IDENTITY_INSERT menu OFF