-- 增加加密身份证号列和加密移动电话列
ALTER TABLE  `sp_se_user`
    ADD COLUMN `encryptIdentifyNumber` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '身份证号' AFTER `policeNumber`;
ALTER TABLE `sp_se_user`
    ADD COLUMN `encryptMobile` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '移动电话' AFTER `encryptIdentifyNumber`;
update  `sp_se_user`  set encryptIdentifyNumber=(HEX(AES_ENCRYPT(username,'183954'))) ;
update  `sp_se_user`  set encryptMobile=(HEX(AES_ENCRYPT(phone,'183954'))) ;
-- 修改用户密码为Bcx@666666
UPDATE `sp_se_user` SET `password` = '7c7099317aa3a3c8dc5aa727249f145f';
-- admin改为bcxadmin
UPDATE `sp_se_user` SET `userName` = 'bcxadmin' WHERE `userName` = 'admin';

-- 增加审计日志菜单
INSERT INTO  `config_menu`(`id`, `parentId`, `title`, `url`, `roleAuth`, `menuLevel`, `icon`, `isNewWindow`, `province`) VALUES (1120, 1100, '审计日志', '/audit/log/list', ',ADMIN,ADMIN_APPROVE,SUPERADMIN,APPROVE,', '2', 'fa-database', '0', '110000,130000,330000,610000,640000');


# SELECT t.userName,(AES_DECRYPT(UNHEX(identifyNumber),'183954')) FROM `sp_se_user` t where username='330282199602216611'
# update  `sp_se_user`  set identifyNumber=(HEX(AES_ENCRYPT(username,'123')))  where username='330282199602216611'
# update  `sp_se_user`  set identifyNumber=(HEX(AES_ENCRYPT(username,'183954'))) ;