mirror of
https://github.com/ent/ent.git
synced 2026-05-24 09:31:56 +03:00
doc: update repository path to ent/ent
This commit is contained in:
committed by
Ariel Mashraki
parent
d1a3b1985a
commit
d75fa8a01d
@@ -140,7 +140,7 @@ func main() {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/entcpkg).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/entcpkg).
|
||||
|
||||
|
||||
## Schema Description
|
||||
|
||||
@@ -71,7 +71,7 @@ The `schema/snapshot` option tells `entc` (ent codegen) to store a snapshot of t
|
||||
and use it to automatically solve merge conflicts when user's schema can't be built.
|
||||
|
||||
This option can be added to projects using the `--feature schema/snapshot` flag, but please see
|
||||
[facebook/ent/issues/852](https://entgo.io/ent/issues/852) to get more context about it.
|
||||
[ent/ent/issues/852](https://entgo.io/ent/issues/852) to get more context about it.
|
||||
|
||||
#### Schema Config
|
||||
|
||||
|
||||
@@ -612,4 +612,4 @@ Now when we have a graph with data, we can run a few queries on it:
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/start).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/start).
|
||||
|
||||
@@ -265,7 +265,7 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/privacyadmin).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/privacyadmin).
|
||||
|
||||
### Multi Tenancy
|
||||
|
||||
@@ -274,7 +274,7 @@ The helper packages `viewer` and `rule` (as mentioned above) also exist in this
|
||||
|
||||

|
||||
|
||||
Let's start building this application piece by piece. We begin by creating 3 different schemas (see the full code [here](https://github.com/facebook/ent/tree/master/examples/privacytenant/ent/schema)),
|
||||
Let's start building this application piece by piece. We begin by creating 3 different schemas (see the full code [here](https://github.com/ent/ent/tree/master/examples/privacytenant/ent/schema)),
|
||||
and since we want to share some logic between them, we create another [mixed-in schema](schema-mixin.md) and add it to all other schemas as follows:
|
||||
|
||||
```go
|
||||
@@ -563,6 +563,6 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/privacytenant).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/privacytenant).
|
||||
|
||||
Please note that this documentation is under active development.
|
||||
|
||||
@@ -252,7 +252,7 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/o2o2types).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/o2o2types).
|
||||
|
||||
## O2O Same Type
|
||||
|
||||
@@ -348,7 +348,7 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/o2orecur).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/o2orecur).
|
||||
|
||||
## O2O Bidirectional
|
||||
|
||||
@@ -422,7 +422,7 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/o2obidi).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/o2obidi).
|
||||
|
||||
## O2M Two Types
|
||||
|
||||
@@ -503,7 +503,7 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
return nil
|
||||
}
|
||||
```
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/o2m2types).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/o2m2types).
|
||||
|
||||
## O2M Same Type
|
||||
|
||||
@@ -612,7 +612,7 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/o2mrecur).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/o2mrecur).
|
||||
|
||||
## M2M Two Types
|
||||
|
||||
@@ -704,7 +704,7 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/m2m2types).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/m2m2types).
|
||||
|
||||
## M2M Same Type
|
||||
|
||||
@@ -797,7 +797,7 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/m2mrecur).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/m2mrecur).
|
||||
|
||||
|
||||
## M2M Bidirectional
|
||||
@@ -860,7 +860,7 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/m2mbidi).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/m2mbidi).
|
||||
|
||||
## Required
|
||||
|
||||
|
||||
@@ -147,7 +147,7 @@ func Do(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/edgeindex).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/edgeindex).
|
||||
|
||||
## Dialect Support
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ func rollback(tx *ent.Tx, err error) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/traversal).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/traversal).
|
||||
|
||||
## Transactional Client
|
||||
|
||||
@@ -88,7 +88,7 @@ func Gen(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/traversal).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/traversal).
|
||||
|
||||
## Best Practices
|
||||
|
||||
|
||||
@@ -213,4 +213,4 @@ func Traverse(ctx context.Context, client *ent.Client) error {
|
||||
}
|
||||
```
|
||||
|
||||
The full example exists in [GitHub](https://github.com/facebook/ent/tree/master/examples/traversal).
|
||||
The full example exists in [GitHub](https://github.com/ent/ent/tree/master/examples/traversal).
|
||||
|
||||
Reference in New Issue
Block a user