Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Sign in
Toggle navigation
L
laravel_training
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
TTS Tran Viet Anh
laravel_training
Commits
5d815c8e
Commit
5d815c8e
authored
Nov 16, 2022
by
TTS Tran Viet Anh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
nullable image
parent
36712d8e
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
2022_10_31_070520_create_posts_table.php
database/migrations/2022_10_31_070520_create_posts_table.php
+1
-1
2022_10_31_100202_create_post_categories_table.php
...ations/2022_10_31_100202_create_post_categories_table.php
+1
-1
No files found.
database/migrations/2022_10_31_070520_create_posts_table.php
View file @
5d815c8e
...
@@ -18,7 +18,7 @@ public function up()
...
@@ -18,7 +18,7 @@ public function up()
$table
->
id
();
$table
->
id
();
$table
->
string
(
'title'
);
$table
->
string
(
'title'
);
$table
->
text
(
'content'
)
->
nullable
()
->
default
(
null
);
$table
->
text
(
'content'
)
->
nullable
()
->
default
(
null
);
$table
->
string
(
'image'
);
$table
->
string
(
'image'
)
->
nullable
()
;
$table
->
unsignedInteger
(
'user_id'
);
$table
->
unsignedInteger
(
'user_id'
);
$table
->
unsignedInteger
(
'post_category_id'
);
$table
->
unsignedInteger
(
'post_category_id'
);
$table
->
date
(
'publish_date'
)
->
nullable
();
$table
->
date
(
'publish_date'
)
->
nullable
();
...
...
database/migrations/2022_10_31_100202_create_post_categories_table.php
View file @
5d815c8e
...
@@ -17,7 +17,7 @@ public function up()
...
@@ -17,7 +17,7 @@ public function up()
Schema
::
create
(
'post_categories'
,
function
(
Blueprint
$table
)
{
Schema
::
create
(
'post_categories'
,
function
(
Blueprint
$table
)
{
$table
->
id
();
$table
->
id
();
$table
->
string
(
'name'
);
$table
->
string
(
'name'
);
$table
->
string
(
'image'
);
$table
->
string
(
'image'
)
->
nullable
()
;
$table
->
unsignedInteger
(
'parent_id'
)
->
nullable
();
$table
->
unsignedInteger
(
'parent_id'
)
->
nullable
();
$table
->
unsignedTinyInteger
(
'status'
)
->
default
(
PostCategory
::
STATUS_ENABLED
);
$table
->
unsignedTinyInteger
(
'status'
)
->
default
(
PostCategory
::
STATUS_ENABLED
);
$table
->
unsignedInteger
(
'ordering'
);
$table
->
unsignedInteger
(
'ordering'
);
...
...
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