Commit f34e4484 authored by dev0tion's avatar dev0tion

Group services and classes, add global service

parent 9d290484
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { Router } from '@angular/router'; import { Router } from '@angular/router';
import { ApiService } from './shared/api/api.service'; import { ApiService } from './shared/services/api.service';
@Component({ @Component({
selector: 'app-root', selector: 'app-root',
......
...@@ -11,7 +11,8 @@ import { AppRoutingModule } from './app-routing.module'; ...@@ -11,7 +11,8 @@ import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component'; import { AppComponent } from './app.component';
import { LoginComponent } from './login/login.component'; import { LoginComponent } from './login/login.component';
import { ApiService } from './shared/api/api.service'; import { ApiService } from './shared/services/api.service';
import { GlobalService } from './shared/services/global.service';
@NgModule({ @NgModule({
...@@ -28,7 +29,7 @@ import { ApiService } from './shared/api/api.service'; ...@@ -28,7 +29,7 @@ import { ApiService } from './shared/api/api.service';
AppComponent, AppComponent,
LoginComponent LoginComponent
], ],
providers: [ ApiService ], providers: [ ApiService, GlobalService ],
bootstrap: [ AppComponent ] bootstrap: [ AppComponent ]
}) })
......
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { Router } from '@angular/router'; import { Router } from '@angular/router';
import { ApiService } from '../shared/api/api.service'; import { ApiService } from '../shared/services/api.service';
import { WalletLoad } from '../shared/wallet-load'; import { WalletLoad } from '../shared/classes/wallet-load';
@Component({ @Component({
selector: 'app-login', selector: 'app-login',
......
import { Component, Injectable } from '@angular/core'; import { Component, Injectable } from '@angular/core';
import { ApiService } from '../../shared/api/api.service'; import { ApiService } from '../../shared/services/api.service';
import { WalletCreation } from '../../shared/wallet-creation'; import { WalletCreation } from '../../shared/classes/wallet-creation';
import { Mnemonic } from '../../shared/mnemonic'; import { Mnemonic } from '../../shared/classes/mnemonic';
@Component({ @Component({
selector: 'create-component', selector: 'create-component',
......
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { ApiService } from '../../shared/api/api.service' import { ApiService } from '../../shared/services/api.service'
import { WalletRecovery } from '../../shared/wallet-recovery' import { WalletRecovery } from '../../shared/classes/wallet-recovery'
@Component({ @Component({
selector: 'app-recover', selector: 'app-recover',
......
...@@ -4,10 +4,10 @@ import { Observable } from 'rxjs/Observable'; ...@@ -4,10 +4,10 @@ import { Observable } from 'rxjs/Observable';
import 'rxjs/add/operator/map'; import 'rxjs/add/operator/map';
import 'rxjs/add/operator/catch'; import 'rxjs/add/operator/catch';
import { WalletCreation } from '../wallet-creation'; import { WalletCreation } from '../classes/wallet-creation';
import { WalletRecovery } from '../wallet-recovery'; import { WalletRecovery } from '../classes/wallet-recovery';
import { WalletLoad } from '../wallet-load'; import { WalletLoad } from '../classes/wallet-load';
import { Mnemonic } from '../mnemonic'; import { Mnemonic } from '../classes/mnemonic';
/** /**
* For information on the API specification have a look at our Github: * For information on the API specification have a look at our Github:
......
import {Injectable} from "@angular/core";
@Injectable()
export class GlobalService {
constructor() {}
private walletPath: string;
getWalletPath(walletPath: string) {
return this.walletPath = walletPath;
}
setWalletPath(walletPath: string) {
this.walletPath = walletPath;
}
}
\ No newline at end of file
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { ApiService } from '../../shared/api/api.service' import { ApiService } from '../../shared/services/api.service'
@Component({ @Component({
selector: 'history-component', selector: 'history-component',
......
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { ApiService } from '../../shared/api/api.service'; import { ApiService } from '../../shared/services/api.service';
@Component({ @Component({
selector: 'dashboard-component', selector: 'dashboard-component',
......
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { ApiService } from '../../shared/api/api.service' import { ApiService } from '../../shared/services/api.service'
@Component({ @Component({
selector: 'receive-component', selector: 'receive-component',
......
import { Component } from '@angular/core'; import { Component } from '@angular/core';
import { ApiService } from '../../shared/api/api.service'; import { ApiService } from '../../shared/services/api.service';
@Component({ @Component({
selector: 'send-component', selector: 'send-component',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment