{"slug":"litesurveys","name":"LiteSurveys","description":"Learn from your site visitors using quick, popup surveys.","author":"Frank Corso","active_installs":0,"version":"2.1.1","wp_org_url":"https://wordpress.org/plugins/litesurveys/","is_closed":false,"cleanup":{"has_uninstall_hook":true,"drops_tables_on_uninstall":true,"deletes_options_on_uninstall":true},"tables":[{"table_name":"litesurveys_questions","full_table_name":"wp_litesurveys_questions","description":"Stores litesurveys questions data created by this plugin.","detection_method":"static","confidence":"high","columns":[],"create_sql":null},{"table_name":"litesurveys_responses","full_table_name":"wp_litesurveys_responses","description":"Stores litesurveys responses data created by this plugin.","detection_method":"static","confidence":"high","columns":[],"create_sql":null},{"table_name":"litesurveys_submissions","full_table_name":"wp_litesurveys_submissions","description":"Stores form submissions and user-entered data.","detection_method":"static","confidence":"high","columns":[],"create_sql":null},{"table_name":"litesurveys_surveys","full_table_name":"wp_litesurveys_surveys","description":"Stores litesurveys surveys data created by this plugin.","detection_method":"static","confidence":"high","columns":[{"name":"id","type":"bigint(20)","nullable":false,"primary_key":true},{"name":"name","type":"varchar(100)","nullable":false,"primary_key":false},{"name":"active","type":"tinyint(1)","nullable":true,"primary_key":false},{"name":"submit_message","type":"text","nullable":false,"primary_key":false},{"name":"targeting_settings","type":"json","nullable":true,"primary_key":false},{"name":"appearance_settings","type":"json","nullable":true,"primary_key":false},{"name":"created_at","type":"timestamp","nullable":true,"primary_key":false},{"name":"updated_at","type":"timestamp","nullable":true,"primary_key":false},{"name":"deleted_at","type":"timestamp","nullable":true,"primary_key":false},{"name":"survey_id","type":"bigint(20)","nullable":false,"primary_key":false},{"name":"type","type":"varchar(25)","nullable":false,"primary_key":false},{"name":"content","type":"varchar(100)","nullable":false,"primary_key":false},{"name":"answers","type":"json","nullable":true,"primary_key":false},{"name":"created_at","type":"timestamp","nullable":true,"primary_key":false},{"name":"updated_at","type":"timestamp","nullable":true,"primary_key":false},{"name":"deleted_at","type":"timestamp","nullable":true,"primary_key":false},{"name":"FOREIGN","type":"KEY","nullable":false,"primary_key":true},{"name":"survey_id","type":"bigint(20)","nullable":false,"primary_key":false},{"name":"page","type":"varchar(255)","nullable":true,"primary_key":false},{"name":"created_at","type":"timestamp","nullable":true,"primary_key":false},{"name":"deleted_at","type":"timestamp","nullable":true,"primary_key":false},{"name":"FOREIGN","type":"KEY","nullable":false,"primary_key":true},{"name":"submission_id","type":"bigint(20)","nullable":false,"primary_key":false},{"name":"question_id","type":"bigint(20)","nullable":false,"primary_key":false},{"name":"content","type":"text","nullable":false,"primary_key":false},{"name":"created_at","type":"timestamp","nullable":true,"primary_key":false},{"name":"deleted_at","type":"timestamp","nullable":true,"primary_key":false},{"name":"FOREIGN","type":"KEY","nullable":true,"primary_key":false},{"name":"FOREIGN","type":"KEY","nullable":true,"primary_key":false}],"create_sql":"CREATE TABLE IF NOT EXISTS wp_litesurveys_surveys ( id bigint(20) NOT NULL AUTO_INCREMENT, name varchar(100) NOT NULL, active tinyint(1) DEFAULT 0, submit_message text NOT NULL, targeting_settings json DEFAULT NULL, appearance_settings json DEFAULT NULL, created_at timestamp DEFAULT CURRENT_TIMESTAMP, updated_at timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, deleted_at timestamp NULL DEFAULT NULL, PRIMARY KEY (id) ) $charset_collate;\"; // Create questions table. $sql_questions = \"CREATE TABLE IF NOT EXISTS wp_litesurveys_questions ( id bigint(20) NOT NULL AUTO_INCREMENT, survey_id bigint(20) NOT NULL, type varchar(25) NOT NULL, content varchar(100) NOT NULL, answers json DEFAULT NULL, created_at timestamp DEFAULT CURRENT_TIMESTAMP, updated_at timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, deleted_at timestamp NULL DEFAULT NULL, PRIMARY KEY (id), FOREIGN KEY (survey_id) REFERENCES wp_litesurveys_surveys(id) ON DELETE CASCADE ) $charset_collate;\"; // Create submissions table. $sql_submissions = \"CREATE TABLE IF NOT EXISTS wp_litesurveys_submissions ( id bigint(20) NOT NULL AUTO_INCREMENT, survey_id bigint(20) NOT NULL, page varchar(255) DEFAULT NULL, created_at timestamp DEFAULT CURRENT_TIMESTAMP, deleted_at timestamp NULL DEFAULT NULL, PRIMARY KEY (id), FOREIGN KEY (survey_id) REFERENCES wp_litesurveys_surveys(id) ON DELETE CASCADE ) $charset_collate;\"; // Create responses table. $sql_responses = \"CREATE TABLE IF NOT EXISTS wp_litesurveys_responses ( id bigint(20) NOT NULL AUTO_INCREMENT, submission_id bigint(20) NOT NULL, question_id bigint(20) NOT NULL, content text NOT NULL, created_at timestamp DEFAULT CURRENT_TIMESTAMP, deleted_at timestamp NULL DEFAULT NULL, PRIMARY KEY (id), FOREIGN KEY (submission_id) REFERENCES wp_litesurveys_submissions(id) ON DELETE CASCADE, FOREIGN KEY (question_id) REFERENCES wp_litesurveys_questions(id) ON DELETE CASCADE ) $charset_collate;\"; require_once ABSPATH . 'wp-admin/includes/upgrade.php'; dbDelta( $sql_surveys );"}],"table_count":4}