chore(analysis): analyze web folders; fix existing warnings

This commit is contained in:
Yegor Jbanov
2015-04-16 16:29:46 -07:00
parent f830cfca12
commit 3dc4df2ffa
17 changed files with 38 additions and 163 deletions

View File

@ -1,6 +1,5 @@
import {bootstrap, Component, View} from 'angular2/angular2';
import {MdGridList, MdGridTile} from 'angular2_material/src/components/grid_list/grid_list'
import {MdTheme} from 'angular2_material/src/core/theme'
import {UrlResolver} from 'angular2/src/services/url_resolver';
import {commonDemoSetup, DemoUrlResolver} from '../demo_common';
import {bind} from 'angular2/di';

View File

@ -39,7 +39,6 @@ class TodoApp {
var target = $event.target;
if(which === 13) {
todo.title = target.value;
this.todoStore.save(todo);
this.todoEdit = null;
} else if (which === 27) {
this.todoEdit = null;
@ -63,7 +62,6 @@ class TodoApp {
var isComplete = $event.target.checked;
this.todoStore.list.forEach((todo) => {
todo.completed = isComplete;
this.todoStore.save(todo);
});
}

View File

@ -2,9 +2,9 @@ import {ListWrapper} from 'angular2/src/facade/collection';
// base model for RecordStore
export class KeyModel {
_key: number;
constructor(key: number) {
this._key = key;
key:number;
constructor(k:number) {
this.key = k;
}
}
@ -45,7 +45,7 @@ export class Store {
}
add(record: KeyModel) {
this.list.push(record);
ListWrapper.push(this.list, record);
}
remove(record: KeyModel) {
@ -60,7 +60,7 @@ export class Store {
spliceOut(record: KeyModel) {
var i = this.indexFor(record);
if( i > -1 ) {
return this.list.splice(i, 1)[0];
return ListWrapper.splice(this.list, i, 1)[0];
}
return null;
}