Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add database section #4

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Add database section
  • Loading branch information
marcomessa committed Mar 6, 2021
commit a4c9e5e70a4ddd50dc06a086b0cdf53c0dcd4d4f
9 changes: 7 additions & 2 deletions _docs/database-attachments.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Database attachments

---
title: Database Attachments
navTitle: Attachments
category: Database
order: 6
layout: default
---
- [File attachments](#file-attachments)
- [Creating new attachments](#creating-attachments)
- [Viewing attachments](#viewing-attachments)
Expand Down
8 changes: 7 additions & 1 deletion _docs/database-basics.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
# Database: Getting Started
---
title: Database Basic Usage
navTitle: Basic Usage
category: Database
order: 1
layout: default
---

- [Introduction](#introduction)
- [Configuration](#configuration)
Expand Down
8 changes: 7 additions & 1 deletion _docs/database-behaviors.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
# Database Behaviors
---
title: Database Behaviors
navTitle: Behaviors
category: Database
order: 11
layout: default
---

- [Purgeable](#purgeable)
- [Sortable](#sortable)
Expand Down
9 changes: 7 additions & 2 deletions _docs/database-collection.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Database Collection

---
title: Database Collections
navTitle: Collections
category: Database
order: 7
layout: default
---
- [Introduction](#introduction)
- [Available methods](#available-methods)
- [Custom collections](#custom-collections)
Expand Down
9 changes: 7 additions & 2 deletions _docs/database-model.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Active Record Model

---
title: Database Models
navTitle: Models
category: Database
order: 4
layout: default
---
- [Introduction](#introduction)
- [Defining models](#defining-models)
- [Supported properties](#standard-properties)
Expand Down
9 changes: 7 additions & 2 deletions _docs/database-mutators.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Model Mutators

---
title: Model Mutators
navTitle: Mutators
category: Database
order: 8
layout: default
---
- [Introduction](#introduction)
- [Accessors & mutators](#accessors-and-mutators)
- [Date mutators](#date-mutators)
Expand Down
9 changes: 7 additions & 2 deletions _docs/database-query.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Database Queries

---
title: Database Queries
navTitle: Queries
category: Database
order: 3
layout: default
---
- [Introduction](#introduction)
- [Retrieving results](#retrieving-results)
- [Chunking results](#chunking-results)
Expand Down
8 changes: 7 additions & 1 deletion _docs/database-relations.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
# Database Relationships
---
title: Database Relationships
navTitle: Relationships
category: Database
order: 5
layout: default
---

- [Introduction](#introduction)
- [Defining relationships](#defining-relationships)
Expand Down
9 changes: 7 additions & 2 deletions _docs/database-serialization.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Model Serialization

---
title: Model Serialization
navTitle: Serialization
category: Database
order: 9
layout: default
---
- [Introduction](#introduction)
- [Basic usage](#basic-usage)
- [Hiding attributes from JSON](#hiding-attributes-from-json)
Expand Down
9 changes: 7 additions & 2 deletions _docs/database-structure.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Database structure and seeding

---
title: Database Structure and Seeding
navTitle: Structure
category: Database
order: 2
layout: default
---
- [Introduction](#introduction)
- [Migration structure](#migration-structure)
- [Creating tables](#creating-tables)
Expand Down
13 changes: 9 additions & 4 deletions _docs/database-traits.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Database Traits

---
title: Database Traits
navTitle: Traits
category: Database
order: 10
layout: default
---
- [Hashable](#hashable)
- [Purgeable](#purgeable)
- [Encryptable](#encryptable)
Expand Down Expand Up @@ -215,7 +220,7 @@ Collections of models that use this trait will return the type of `Winter\Storm\

In order to render all levels of items and their children, you can use recursive processing

{% macro renderChildren(item) %}
{% raw %}{% macro renderChildren(item) %}
{% import _self as SELF %}
{% if item.children is not empty %}
<ul>
Expand All @@ -227,7 +232,7 @@ In order to render all levels of items and their children, you can use recursive
{% endmacro %}

{% import _self as SELF %}
{{ SELF.renderChildren(category) | raw }}
{{ SELF.renderChildren(category) | raw }}{% endraw %}

<a name="nested-tree"></a>
## Nested Tree
Expand Down