[AngularFire 2] Joins in Firebase】的更多相关文章

Lets see how to query Firebase. First thing, when we do query, 'index' will always help, for both SQL and NoSQL. In Firebase, we can also set index on props, for example we want to set an 'index' on 'courses' --> 'url' prop, we will use 'url' to loca…
Basic angularFire options: $save, $add and $remove. The way connect firebase: var app = angular.module('app', ['firebase']); var ref = new Firebase(FIREBASE_URI); //create an item storage var items = $firebase(ref); Example: <!DOCTYPE html> <html…
In this lesson we are going to learn how to use AngularFire 2 to query objects, and read them from the Firebase realtime database. const course$: FirebaseObjectObservable<any> = af.database.object('courses/-KT0LsbuhHZGr5F4v7OV'); course$.subscribe((…
import { NgModule } from '@angular/core'; import { AuthService } from './auth.service'; import { AngularFireAuthModule } from 'angularfire2/auth'; import { AngularFirestoreModule } from 'angularfire2/firestore'; @NgModule({ imports: [ AngularFireAuth…
The upload class will be used in the service layer. Notice it has a constructor for file attribute, which has a type of File. This will allows us to initialize new uploads with a JavaScript File object. You will see why this is important in the next…
The idea: This post we are going to learn how to build a Firebase Forage with object related database. Form the pic we can see that there are two object: users and items. This helps to orginzie the data structure better. The way to do this is followi…
Using $firebaseSimpleLogin service. Here we use three methods for login, logout, register and getCurrentUser. Be sure to open the Email and Password configuration on Forge: login.tmpl.html <div class="container" ng-controller="LoginCtrl&…
Config AngularFire, we need database and auth module from firebase. import {NgModule} from '@angular/core'; import {CommonModule} from '@angular/common'; import {RouterModule, Routes} from '@angular/router'; import {AngularFireModule, FirebaseAppConf…
In this lesson we are going to use AngularFire 2 for the first time. We are going to configure the AngularFire 2 module, inject the AngularFire service in our service layer and use it do our first Firebase query: we are going to retrieve a list of ob…
N多年之前,刚刚接触SQL的时候,就被多表查询中的各种内连接,外连接,左外连接,右外连接等各式各样的连接弄的晕头转向. 更坑的是书上看到的各种表连接还有两种不同的写法, 比如对于表A,表B的查询 1,内连接两种写法: select * from A, B where A.id = B.id; select * from A join B on A.id = B.id; 2,右外连接写法: select * from A, B where A.id(+) = B.id; select * from…