forked from DebaucheryLibrarian/traxxx
Added database structure for piercings.
This commit is contained in:
parent
d29e296799
commit
689dbeefbd
|
@ -357,7 +357,7 @@ exports.up = knex => Promise.resolve()
|
||||||
// arms
|
// arms
|
||||||
{ slug: 'arm', name: 'arm' },
|
{ slug: 'arm', name: 'arm' },
|
||||||
{ slug: 'upper-arm', name: 'upper arm' },
|
{ slug: 'upper-arm', name: 'upper arm' },
|
||||||
{ slug: 'lower-arm', name: 'lower arm' },
|
{ slug: 'forearm', name: 'forearm' },
|
||||||
{ slug: 'elbow', name: 'elbow' },
|
{ slug: 'elbow', name: 'elbow' },
|
||||||
{ slug: 'inner-elbow', name: 'inner elbow' },
|
{ slug: 'inner-elbow', name: 'inner elbow' },
|
||||||
{ slug: 'outer-elbow', name: 'outer elbow' },
|
{ slug: 'outer-elbow', name: 'outer elbow' },
|
||||||
|
@ -408,7 +408,10 @@ exports.up = knex => Promise.resolve()
|
||||||
{ slug: 'leg', name: 'leg' },
|
{ slug: 'leg', name: 'leg' },
|
||||||
{ slug: 'groin', name: 'groin' },
|
{ slug: 'groin', name: 'groin' },
|
||||||
{ slug: 'upper-leg', name: 'upper leg' },
|
{ slug: 'upper-leg', name: 'upper leg' },
|
||||||
|
{ slug: 'thigh', name: 'thigh' },
|
||||||
{ slug: 'lower-leg', name: 'lower leg' },
|
{ slug: 'lower-leg', name: 'lower leg' },
|
||||||
|
{ slug: 'shin', name: 'shin' },
|
||||||
|
{ slug: 'calf', name: 'calf' },
|
||||||
{ slug: 'knee', name: 'knee' },
|
{ slug: 'knee', name: 'knee' },
|
||||||
{ slug: 'inner-knee', name: 'inner knee' },
|
{ slug: 'inner-knee', name: 'inner knee' },
|
||||||
// feet
|
// feet
|
||||||
|
@ -441,6 +444,25 @@ exports.up = knex => Promise.resolve()
|
||||||
table.datetime('created_at')
|
table.datetime('created_at')
|
||||||
.defaultTo(knex.fn.now());
|
.defaultTo(knex.fn.now());
|
||||||
}))
|
}))
|
||||||
|
.then(() => knex.schema.createTable('actors_piercings', (table) => {
|
||||||
|
table.increments('id');
|
||||||
|
|
||||||
|
table.integer('actor_id', 12)
|
||||||
|
.notNullable()
|
||||||
|
.references('id')
|
||||||
|
.inTable('actors');
|
||||||
|
|
||||||
|
table.string('body_slug', 20)
|
||||||
|
.references('slug')
|
||||||
|
.inTable('body');
|
||||||
|
|
||||||
|
table.enum('side', ['left', 'right', 'center', 'both']);
|
||||||
|
|
||||||
|
table.string('description');
|
||||||
|
|
||||||
|
table.datetime('created_at')
|
||||||
|
.defaultTo(knex.fn.now());
|
||||||
|
}))
|
||||||
.then(() => knex.schema.createTable('actors_avatars', (table) => {
|
.then(() => knex.schema.createTable('actors_avatars', (table) => {
|
||||||
table.integer('actor_id', 12)
|
table.integer('actor_id', 12)
|
||||||
.notNullable()
|
.notNullable()
|
||||||
|
@ -752,6 +774,7 @@ exports.down = knex => knex.raw(`
|
||||||
DROP TABLE IF EXISTS actors_social CASCADE;
|
DROP TABLE IF EXISTS actors_social CASCADE;
|
||||||
DROP TABLE IF EXISTS actors_profiles CASCADE;
|
DROP TABLE IF EXISTS actors_profiles CASCADE;
|
||||||
DROP TABLE IF EXISTS actors_tattoos CASCADE;
|
DROP TABLE IF EXISTS actors_tattoos CASCADE;
|
||||||
|
DROP TABLE IF EXISTS actors_piercings CASCADE;
|
||||||
DROP TABLE IF EXISTS body CASCADE;
|
DROP TABLE IF EXISTS body CASCADE;
|
||||||
|
|
||||||
DROP TABLE IF EXISTS sites_tags CASCADE;
|
DROP TABLE IF EXISTS sites_tags CASCADE;
|
||||||
|
|
Loading…
Reference in New Issue