Broker System for Supercredit
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

35 lines
928B

  1. import {UserExModel} from './userExModel';
  2. export class PayOutExModel{
  3. Id: number;
  4. Ts: Date;
  5. To: UserExModel;
  6. Prepared: UserExModel;
  7. Approved: UserExModel;
  8. Paid: UserExModel;
  9. PayDate: Date;
  10. PayAmount: number;
  11. Status: string;
  12. constructor( payload: Partial<PayOutExModel>) {
  13. this.Id = payload.Id || 0;
  14. if (payload.Ts){
  15. this.Ts = new Date( payload.Ts);
  16. }else{
  17. this.Ts = new Date('1800-01-01');
  18. }
  19. this.To = new UserExModel(payload.To);
  20. this.Prepared = new UserExModel(payload.Prepared);
  21. this.Approved = new UserExModel(payload.Approved);
  22. this.Paid = new UserExModel(payload.Paid);
  23. if (payload.PayDate) {
  24. this.PayDate = new Date(payload.PayDate);
  25. }else{
  26. this.PayDate = new Date('1800-01-01');
  27. }
  28. this.PayAmount = payload.PayAmount || 0;
  29. this.Status = payload.Status || '';
  30. }
  31. }