fengxiang
2017-12-27 3ab77260db42470b71a470e0fee3d38c1945408d
恢复默认 server_bash_url
4 files modified
18 ■■■■■ changed files
src/app/core/entity/grid.ts 6 ●●●● patch | view | raw | blame | history
src/app/core/enum/types.enum.ts 2 ●●● patch | view | raw | blame | history
src/app/routes/devices/version/version.component.ts 4 ●●●● patch | view | raw | blame | history
src/app/routes/devices/version/version.service.ts 6 ●●●●● patch | view | raw | blame | history
src/app/core/entity/grid.ts
@@ -38,11 +38,11 @@
    
    checkAll(value: boolean) {
        this.data.forEach(
            row => {row.checked = value;}
        )
            row => {row.checked = value; }
        );
        this.refreshStatus();
    }
    getData():any[]{
    getData(): any [] {
        return this.data;
    }
    initData(pageData: {data?: any[], total?: number}) {
src/app/core/enum/types.enum.ts
@@ -1,3 +1,3 @@
export enum Types {
    Date,json
    Date, json
}
src/app/routes/devices/version/version.component.ts
@@ -66,7 +66,7 @@
  ngOnInit() {
    this.initPage();
    this.queryTextStream
    .debounceTime(1000)
    .debounceTime(500)
    .distinctUntilChanged()
    .subscribe(queryText => {
        this.load();
@@ -81,7 +81,7 @@
    }
    this.versionService.getPagingList(this.grid, this.queryMap.value).subscribe(
       (res: PageBean) => {
            if (res.total > 0 && res.data != null) {
            if (res != null && res.data != null) {
              this.grid.initData(res);
              this.grid.refreshStatus();
            }
src/app/routes/devices/version/version.service.ts
@@ -25,8 +25,10 @@
  constructor(private http: _HttpClient) { }
   public getPagingList(page: PageBean, queryText: string): Observable<PageBean> {
    const example = new ExampleService();
    example.or().andLike({name: 'name', value: '%' + queryText + '%'});
    example.or().andEqualTo({name: 'version', value: queryText});
    if (queryText != null && queryText !== '') {
      example.or().andLike({name: 'name', value: '%' + queryText + '%'});
      example.or().andEqualTo({name: 'version', value: queryText});
    }
    const param: PageBean = {pageSize: page.pageSize, pageIndex: page.pageIndex, queryParams: example.getSqlParam()};
    return this.http.get(this.urls.edit, param);
  }