change(assist-stats): moved to ee
This commit is contained in:
parent
17a428fa39
commit
bd2bcd378b
5 changed files with 13 additions and 68 deletions
|
|
@ -128,11 +128,9 @@ CREATE TABLE IF NOT EXISTS public.assist_events
|
|||
project_id integer NOT NULL,
|
||||
session_id varchar NOT NULL,
|
||||
event_type varchar NOT NULL,
|
||||
event_state varchar NOT NULL,
|
||||
timestamp integer NOT NULL,
|
||||
user_id varchar,
|
||||
timestamp bigint NOT NULL,
|
||||
duration integer,
|
||||
agent_id varchar
|
||||
agent_id integer
|
||||
);
|
||||
|
||||
CREATE TABLE IF NOT EXISTS public.assist_events_aggregates
|
||||
|
|
|
|||
|
|
@ -977,11 +977,9 @@ $$
|
|||
project_id integer NOT NULL,
|
||||
session_id varchar NOT NULL,
|
||||
event_type varchar NOT NULL,
|
||||
event_state varchar NOT NULL,
|
||||
timestamp integer NOT NULL,
|
||||
user_id varchar,
|
||||
timestamp bigint NOT NULL,
|
||||
duration integer,
|
||||
agent_id varchar
|
||||
agent_id integer
|
||||
);
|
||||
|
||||
CREATE TABLE IF NOT EXISTS public.assist_events_aggregates
|
||||
|
|
|
|||
9
ee/scripts/schema/db/init_dbs/postgresql/postgresql.iml
Normal file
9
ee/scripts/schema/db/init_dbs/postgresql/postgresql.iml
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module type="WEB_MODULE" version="4">
|
||||
<component name="NewModuleRootManager" inherit-compiler-output="true">
|
||||
<exclude-output />
|
||||
<content url="file://$MODULE_DIR$" />
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
||||
|
|
@ -121,37 +121,6 @@ ALTER TABLE IF EXISTS events.clicks
|
|||
ALTER TABLE IF EXISTS public.metrics
|
||||
ADD COLUMN IF NOT EXISTS card_info jsonb NULL;
|
||||
|
||||
|
||||
CREATE TABLE IF NOT EXISTS public.assist_events
|
||||
(
|
||||
event_id varchar NOT NULL PRIMARY KEY,
|
||||
project_id integer NOT NULL,
|
||||
session_id varchar NOT NULL,
|
||||
event_type varchar NOT NULL,
|
||||
timestamp bigint NOT NULL,
|
||||
duration integer,
|
||||
agent_id integer
|
||||
);
|
||||
|
||||
CREATE TABLE IF NOT EXISTS public.assist_events_aggregates
|
||||
(
|
||||
timestamp BIGINT not null,
|
||||
project_id integer not null,
|
||||
agent_id integer not null,
|
||||
assist_avg BIGINT,
|
||||
call_avg BIGINT,
|
||||
control_avg BIGINT,
|
||||
assist_total BIGINT,
|
||||
call_total BIGINT,
|
||||
control_total BIGINT
|
||||
);
|
||||
|
||||
|
||||
CREATE TABLE IF NOT EXISTS public.assist_events_aggregates_logs
|
||||
(
|
||||
time BIGINT not null
|
||||
);
|
||||
|
||||
ALTER TABLE IF EXISTS public.users
|
||||
ADD COLUMN IF NOT EXISTS settings jsonb DEFAULT NULL;
|
||||
|
||||
|
|
|
|||
|
|
@ -1116,35 +1116,6 @@ $$
|
|||
CREATE INDEX swipes_timestamp_idx ON events_ios.swipes (timestamp);
|
||||
CREATE INDEX swipes_label_session_id_timestamp_idx ON events_ios.swipes (label, session_id, timestamp);
|
||||
|
||||
CREATE TABLE IF NOT EXISTS public.assist_events
|
||||
(
|
||||
event_id varchar NOT NULL PRIMARY KEY,
|
||||
project_id integer NOT NULL,
|
||||
session_id varchar NOT NULL,
|
||||
event_type varchar NOT NULL,
|
||||
timestamp bigint NOT NULL,
|
||||
duration integer,
|
||||
agent_id integer
|
||||
);
|
||||
|
||||
CREATE TABLE IF NOT EXISTS public.assist_events_aggregates
|
||||
(
|
||||
timestamp BIGINT not null,
|
||||
project_id integer not null,
|
||||
agent_id integer not null,
|
||||
assist_avg BIGINT,
|
||||
call_avg BIGINT,
|
||||
control_avg BIGINT,
|
||||
assist_total BIGINT,
|
||||
call_total BIGINT,
|
||||
control_total BIGINT
|
||||
);
|
||||
|
||||
CREATE TABLE IF NOT EXISTS public.assist_events_aggregates_logs
|
||||
(
|
||||
time BIGINT not null
|
||||
);
|
||||
|
||||
raise notice 'DB created';
|
||||
END IF;
|
||||
END;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue