Added Manticore migration and meta text field.
This commit is contained in:
35
migrations/20240125011700_manticore.js
Normal file
35
migrations/20240125011700_manticore.js
Normal file
@@ -0,0 +1,35 @@
|
||||
const config = require('config');
|
||||
const manticore = require('manticoresearch');
|
||||
|
||||
const mantiClient = new manticore.ApiClient();
|
||||
|
||||
mantiClient.basePath = `http://${config.database.manticore.host}:${config.database.manticore.httpPort}`;
|
||||
|
||||
const utilsApi = new manticore.UtilsApi(mantiClient);
|
||||
|
||||
exports.up = async () => {
|
||||
await utilsApi.sql(`create table scenes (
|
||||
id int,
|
||||
title text,
|
||||
entry_id text,
|
||||
channel_id int,
|
||||
channel_name text,
|
||||
channel_slug text,
|
||||
network_id int,
|
||||
network_name text,
|
||||
network_slug text,
|
||||
actor_ids multi,
|
||||
actors text,
|
||||
tag_ids multi,
|
||||
tags text,
|
||||
meta text,
|
||||
date timestamp,
|
||||
created_at timestamp,
|
||||
effective_date timestamp,
|
||||
stashed int
|
||||
)`);
|
||||
};
|
||||
|
||||
exports.down = async () => {
|
||||
await utilsApi.sql('drop table scenes');
|
||||
};
|
||||
Reference in New Issue
Block a user