Skip to content

Commit

Permalink
#199 fix error input component (#1353)
Browse files Browse the repository at this point in the history
* #199 change branch

* #199 remove input component in dashboard creation
  • Loading branch information
eltriny authored and ufoscw committed Jan 31, 2019
1 parent f1e433b commit 9032504
Show file tree
Hide file tree
Showing 9 changed files with 13 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@ export class InputComponent implements OnInit, OnDestroy {

@Input() public inputClass: string = ''; // Input Element 클래스

@Input() public autoFocus: boolean = true; // 자동으로 focus 여부

@Input() public optionalClass: string = ''; // 추가적인 스타일 적용을 위한 클래스

@Input() public optionalStyle: string = ''; // 추가적인 스타일 적용을 위한 스타일
Expand Down Expand Up @@ -145,7 +147,7 @@ export class InputComponent implements OnInit, OnDestroy {

this._safelyDetectChanges();

setTimeout( () => {
this.autoFocus && setTimeout( () => {
inputNativeElm.focus();
}, 400 );
} // function - ngAfterViewInit
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,8 @@
<!-- edit -->
<div class="ddp-wrap-edit2" [class.ddp-error]="isInvalidName">
<label class="ddp-label-type">{{'msg.comm.ui.name' | translate}}</label>
<component-input
[value]="dashboard.name"
[inputClass]="'ddp-input-type'"
[maxLen]="50"
[placeHolder]="'msg.comm.ui.create.name' | translate"
(inputFocus)="isInvalidName=false"
(changeValue)="dashboard.name = $event"></component-input>
<input type="text" class="ddp-input-type" placeholder="{{'msg.comm.ui.create.name' | translate}}"
[(ngModel)]="dashboard.name" (focus)="isInvalidName=false" maxlength="50" />
<!-- error -->
<span class="ddp-ui-error">{{errMsgName}}</span>
<!-- error -->
Expand All @@ -71,13 +66,8 @@
<!-- edit -->
<div class="ddp-wrap-edit2" [class.ddp-error]="isInvalidDesc">
<label class="ddp-label-type">{{'msg.comm.ui.description' | translate}}</label>
<component-input
[value]="dashboard.description"
[inputClass]="'ddp-input-type'"
[maxLen]="150"
[placeHolder]="'msg.comm.ui.create.desc' | translate"
(inputFocus)="isInvalidDesc=false"
(changeValue)="dashboard.description = $event"></component-input>
<input type="text" class="ddp-input-type" placeholder="{{'msg.comm.ui.create.desc' | translate}}"
[(ngModel)]="dashboard.description" (focus)="isInvalidDesc=false" maxlength="150" />
<!-- error -->
<span class="ddp-ui-error">{{errMsgDesc}}</span>
<!-- error -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
<div class="ddp-filter-search ddp-fright">
<div class="ddp-form-filter-search">
<component-input
[autoFocus]="false"
[value]="searchKeyword"
[placeHolder]="'msg.storage.ph.connection.search' | translate"
(changeValue)="onChangedSearchKeyword($event)">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
<div class="ddp-filter-search ddp-fright">
<div class="ddp-form-filter-search">
<component-input
[autoFocus]="false"
[value]="searchKeyword"
[placeHolder]="'msg.storage.ph.source.search' | translate"
(changeValue)="onChangedSearchKeyword($event)">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,7 @@ export class GnbComponent extends AbstractComponent implements OnInit, OnDestroy
}).catch((err) => this.commonExceptionHandler(err));
// check stageDB enable
this.storageService.checkEnableStageDB().then((result) => {
console.log(result);
}).catch((err) => this.commonExceptionHandler(err));

}

// Destroy
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
<div class="ddp-form-search ddp-fleft">
<em class="ddp-icon-search"></em>
<component-input
[autoFocus]="false"
[compType]="'search'"
[value]="searchText"
[placeHolder]="'msg.metadata.cat.ui.ph.search' | translate"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
<div class="ddp-form-search ddp-fleft">
<em class="ddp-icon-search"></em>
<component-input
[autoFocus]="false"
[compType]="'search'"
[value]="searchText"
[placeHolder]="'msg.metadata.ui.codetable.search.ph' | translate"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
<div class="ddp-form-search ddp-fleft">
<em class="ddp-icon-search"></em>
<component-input
[autoFocus]="false"
[compType]="'search'"
[value]="searchText"
[placeHolder]="'msg.metadata.ui.dictionary.search.ph' | translate"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@
<div class="ddp-form-search ddp-fleft">
<em class="ddp-icon-search"></em>
<component-input
[autoFocus]="false"
[compType]="'search'"
[value]="listSearchText"
[placeHolder]="'msg.metadata.md.ui.search.ph' | translate"
Expand Down

0 comments on commit 9032504

Please sign in to comment.