try of readings status
This commit is contained in:
		@@ -52,8 +52,12 @@
 | 
			
		||||
                <div class="col-md-2">
 | 
			
		||||
                    <div class="form-group">
 | 
			
		||||
                        <label for="Inhalt">Status</label>
 | 
			
		||||
                        <input type="text" class="form-control" id="Status" required name="status"
 | 
			
		||||
                            [(ngModel)]="task.status">
 | 
			
		||||
                        <!-- <input type="text" class="form-control" id="Status" required name="status"
 | 
			
		||||
                            [(ngModel)]="task.status"> -->
 | 
			
		||||
                            <select class="form-control custom-select mr-sm-2" id="prio" required name="prio"
 | 
			
		||||
                            [(ngModel)]="task.priority">
 | 
			
		||||
                              <option *ngFor="let status of allStatus" value="low">{{status.title}}</option>
 | 
			
		||||
                            </select>
 | 
			
		||||
                    </div>
 | 
			
		||||
                    <div class="form-group">
 | 
			
		||||
                        <label for="Inhalt">Assigned User</label>
 | 
			
		||||
 
 | 
			
		||||
@@ -23,6 +23,7 @@ export class TaskFormComponent implements OnInit {
 | 
			
		||||
	public editing: Boolean;
 | 
			
		||||
	public userstoryId: string;
 | 
			
		||||
	public userstories: any[] = [];
 | 
			
		||||
	public allStatus: any[] = [];
 | 
			
		||||
 | 
			
		||||
	constructor(private backendService: BackendService, private activeModalService: NgbActiveModal) {
 | 
			
		||||
		this.getUserStories();
 | 
			
		||||
@@ -79,4 +80,14 @@ export class TaskFormComponent implements OnInit {
 | 
			
		||||
			}
 | 
			
		||||
		});
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	getTaskStatus() {
 | 
			
		||||
		this.backendService.getAllStatus().subscribe((response) => {
 | 
			
		||||
			if (response.status > 399) {
 | 
			
		||||
				alert('Fehler');
 | 
			
		||||
			} else {
 | 
			
		||||
				this.allStatus.push(...response.body);
 | 
			
		||||
			}
 | 
			
		||||
		});
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user