Advertisement
Guest User

Untitled

a guest
Aug 18th, 2019
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | None | 0 0
  1. export enum Category {
  2. NotDefined,
  3. RealTime,
  4. BackData,
  5. Testing,
  6. Simulated
  7. }
  8.  
  9. Type 'Category.Testing' is not comparable to type 'Category.BackData'
  10.  
  11. import { Category } from '@app/model/Enums.ts';
  12.  
  13. public async SubmitForm(): Promise<Boolean> {
  14. var category: Category;
  15. category = Category.BackData;
  16.  
  17. switch (category) {
  18. case (Category.Testing): {
  19. this.workRequest.RangeStart == 0.1;
  20. this.workRequest.RangeEnd == 0.3;
  21. this.workRequest.RangeStep = 0.1;
  22. }
  23. default: {
  24. this.workRequest.RangeStart == 0.00;
  25. this.workRequest.RangeEnd == 1.00;
  26. this.workRequest.RangeStep = 0.01;
  27. }
  28. }
  29.  
  30. if (category == Category.Testing) {
  31. this.workRequest.RangeStart == 0.1;
  32. this.workRequest.RangeEnd == 0.3;
  33. this.workRequest.RangeStep = 0.1;
  34. } else {
  35. this.workRequest.RangeStart == 0.00;
  36. this.workRequest.RangeEnd == 1.00;
  37. this.workRequest.RangeStep = 0.01;
  38. }
  39. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement