Guest User

Untitled

a guest
Apr 12th, 2017
648
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import { Component, Optional, OnInit, Inject, Input, ViewChild } from '@angular/core';
  2. import { NgModel, NG_VALUE_ACCESSOR } from '@angular/forms';
  3.  
  4. import { SelectItem, MenuItem } from 'primeng/primeng';
  5.  
  6. // ------------------------------------------------
  7. // Award Number -- TextInput
  8. // ------------------------------------------------
  9.  
  10. @Component({
  11.   selector: 'award-number-input',
  12.   templateUrl: './award-number-input.component.html',
  13.   styleUrls: ['./award-number-input.component.scss'],
  14.   providers: [{
  15.     provide: NG_VALUE_ACCESSOR,
  16.     useExisting: AwardNumberInputComponent,
  17.     multi: true,
  18.   }],
  19. })
  20. export class AwardNumberInputComponent extends ValueAccessorBase<string> implements OnInit  {
  21.  
  22.   // Inputs and Views
  23.   @Input() public label: string;
  24.   @Input() public placeholder: string;
  25.   @ViewChild(NgModel) model: NgModel;
  26.  
  27.   // Globals
  28.   public identifier = `form-select-${identifier++}`;
  29.  
  30.   constructor() {
  31.     super();
  32.   }
  33.  
  34.   ngOnInit() {
  35.  
  36.   }
  37.  
  38. }
  39.  
  40. let identifier = 0;
Advertisement
Add Comment
Please, Sign In to add comment