Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
ARC-Support
public projects
lou-server
Commits
3e1de366
Commit
3e1de366
authored
Oct 01, 2021
by
Maik Messerschmidt
Browse files
Added create_inputs migration.
parent
f011c28f
Changes
1
Hide whitespace changes
Inline
Side-by-side
database/migrations/2021_10_01_093029_create_inputs_table.php
0 → 100644
View file @
3e1de366
<?php
use
Illuminate\Database\Migrations\Migration
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Support\Facades\Schema
;
class
CreateInputsTable
extends
Migration
{
/**
* Run the migrations.
*
* @return void
*/
public
function
up
()
{
Schema
::
create
(
'inputs'
,
function
(
Blueprint
$table
)
{
$table
->
uuid
(
'id'
);
$table
->
timestamps
();
$table
->
string
(
'increments'
)
->
default
(
'auto'
)
->
comment
(
'How and when to increment the use count. auto: when requested, manual: by /used, never: never.'
);
$table
->
integer
(
'uses'
)
->
default
(
0
)
->
unsigned
()
->
comment
(
"How often this input was used."
);
$table
->
integer
(
'max_uses'
)
->
default
(
null
)
->
nullable
()
->
unsigned
()
->
comment
(
"How often this input can be used. Use NULL for inifinite often."
);
$table
->
boolean
(
'listed'
)
->
default
(
true
)
->
comment
(
"Whether this input should be available by /next or only by uuid."
);
$table
->
text
(
"data"
)
->
comment
(
"The actual input data."
);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public
function
down
()
{
Schema
::
dropIfExists
(
'inputs'
);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment