scmiot
2022-11-24 adaa93acfbec0055a50d82912665bf4bc1e1e4fb
script/sql/update/postgres/update-4.2-4.3.sql
@@ -2,4 +2,18 @@
delete from sys_menu WHERE menu_id = 116;
update sys_config set config_key = 'sys.account.captchaEnabled' where config_id = 4
update sys_config set config_key = 'sys.account.captchaEnabled' where config_id = 4;
insert into sys_menu values('1050', '账户解锁', '501', '4', '#', '', '', '1', '0', 'F', '0', '0', 'monitor:logininfor:unlock',  '#', 'admin', now(), '', null, '');
insert into sys_role_menu values ('2', '1050');
-- 字符串自动转时间 避免框架时间查询报错问题
create or replace function cast_varchar_to_timestamp(varchar) returns timestamptz as $$
select to_timestamp($1, 'yyyy-mm-dd hh24:mi:ss');
$$ language sql strict ;
create cast (varchar as timestamptz) with function cast_varchar_to_timestamp as IMPLICIT;
insert into sys_dict_data values(29, 99, '其他',     '0',       'sys_oper_type',       '',   'info',    'N', '0', 'admin', now(), '', null, '其他操作');