You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -112,7 +113,17 @@ Will return the following JSON:
112
113
113
114
#### Alias (`AS`) syntax is supported too
114
115
115
-
Changing the previous API endpoint to `/api/child?columns=id,name,parent_id.name as parent_name,parent_id.company_id.name as parent_company_name` or `/api/child?columns=id,name,parent_id.name parent_name,parent_id.company_id.name parent_company_name` will return the aliased fields instead:
Copy file name to clipboardExpand all lines: postgres-rest-actix/src/lib.rs
+8-8
Original file line number
Diff line number
Diff line change
@@ -11,7 +11,7 @@
11
11
//!
12
12
//! ```no_run
13
13
//! use actix_web::{App, HttpServer};
14
-
//! use rust_postgres_rest_actix::{Config};
14
+
//! use postgres_rest_actix::{Config};
15
15
//! use tokio_postgres::tls::NoTls;
16
16
//! # use std::thread;
17
17
//!
@@ -46,7 +46,7 @@
46
46
///
47
47
/// ```no_run
48
48
/// use actix_web::{App, HttpServer, web};
49
-
/// use rust_postgres_rest_actix::{Config, endpoints};
49
+
/// use postgres_rest_actix::{Config, endpoints};
50
50
/// use tokio_postgres::tls::NoTls;
51
51
///
52
52
/// fn main() {
@@ -87,7 +87,7 @@ use endpoints::{
87
87
};
88
88
89
89
pubuse error::Error;
90
-
userust_postgres_rest::ConfigasInnerConfig;
90
+
usepostgres_rest::ConfigasInnerConfig;
91
91
92
92
use actix_web::{web,Scope};
93
93
use futures::future::Future;
@@ -98,7 +98,7 @@ use tokio_postgres::{
98
98
99
99
/// Configures and creates the REST API `Scope`.
100
100
/// ```no_run
101
-
/// use rust_postgres_rest_actix::Config;
101
+
/// use postgres_rest_actix::Config;
102
102
/// use tokio_postgres::NoTls;
103
103
///
104
104
/// let config = Config::new("postgresql://[email protected]:5432/postgres", NoTls);
@@ -129,7 +129,7 @@ where
129
129
{
130
130
/// Creates a Config object with default values. `db_url` must be [Postgres-formatted](https://www.postgresql.org/docs/current/libpq-connect.html#id-1.7.3.8.3.6).
131
131
/// ```
132
-
/// use rust_postgres_rest_actix::Config;
132
+
/// use postgres_rest_actix::Config;
133
133
/// use tokio_postgres::NoTls;
134
134
///
135
135
/// let config = Config::new("postgresql://[email protected]:5432/postgres", NoTls);
0 commit comments