FRONTEND-569. Responsive payments (#460)

* responsive payments

* fixes

* fixes
This commit is contained in:
Denis Ezhov 2021-05-17 19:34:40 +03:00 committed by GitHub
parent 41de27c609
commit 9d7cd451e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 17 additions and 20 deletions

View File

@ -5,15 +5,18 @@
(selectedChange)="dateRangeChange($event)"
></dsh-daterange-filter>
<dsh-invoices-filter
fxHide.lt-md
[selected]="filters.invoiceIDs"
(selectedChange)="invoiceSelectionChange($event)"
></dsh-invoices-filter>
<dsh-filter-shops
fxHide.lt-md
[shops]="shops$ | async"
[selected]="selectedShops$ | async"
(selectedChange)="shopSelectionChange($event)"
></dsh-filter-shops>
<dsh-card-bin-pan-filter
fxHide.lt-md
[binPan]="filters.binPan"
(filterChanged)="binPanChanged($event)"
></dsh-card-bin-pan-filter>

View File

@ -6,7 +6,7 @@
color="primary"
>
<dsh-row-header-label fxFlex>{{ t('amount') }}</dsh-row-header-label>
<dsh-row-header-label fxFlex>{{ t('status') }}</dsh-row-header-label>
<dsh-row-header-label fxFlex fxHide.lt-md>{{ t('status') }}</dsh-row-header-label>
<dsh-row-header-label fxFlex>{{ t('statusChanged') }}</dsh-row-header-label>
<dsh-row-header-label fxFlex fxHide.lt-md> {{ t('shop') }} </dsh-row-header-label>
</dsh-row>

View File

@ -4,7 +4,7 @@
<dsh-balance [amount]="payment.amount" [currency]="payment.currency"></dsh-balance>
</div>
</dsh-row-label>
<dsh-row-label fxFlex>
<dsh-row-label fxFlex fxHide.lt-md>
<dsh-payment-status [status]="payment.status"></dsh-payment-status>
</dsh-row-label>
<dsh-row-label fxFlex>{{ payment.statusChangedAt | date: 'dd MMMM yyyy, HH:mm' }}</dsh-row-label>

View File

@ -1,5 +1,5 @@
<ng-container *transloco="let t; scope: 'payment-details'; read: 'paymentDetails.invoiceDetails'">
<ng-container *ngIf="invoice; else loading">
<div *ngIf="invoice; else loading" fxLayout="column" fxLayoutGap="24px">
<div class="payment-invoice-info-title mat-title" fxLayout fxLayoutAlign="space-between center">
<div>
{{ t('title') }}
@ -17,7 +17,7 @@
</a>
</div>
<dsh-invoice-details [invoice]="invoice"></dsh-invoice-details>
</ng-container>
</div>
<ng-template #loading>
<div class="payment-invoice-info-title mat-title" fxLayout fxLayoutAlign="space-between center">
<div>

View File

@ -1,21 +1,15 @@
<ng-container *transloco="let t; scope: 'payment-details'; read: 'paymentDetails.details'">
<div fxLayout="column" fxLayoutGap="24px">
<div fxLayout="row">
<div class="payment-main-info-amount mat-body-1" fxFlex="33">
{{ payment.amount | toMajor | currency: payment.currency }}
</div>
<dsh-charge-amount fxFlex="33" [payment]="payment"></dsh-charge-amount>
<dsh-payment-fee *ngIf="payment.fee" fxFlex="33" [payment]="payment"> </dsh-payment-fee>
<div gdColumns="1fr" gdColumns.gt-md="1fr 1fr 1fr" gdGap="24px">
<div class="payment-main-info-amount mat-body-1">
{{ payment.amount | toMajor | currency: payment.currency }}
</div>
<div fxLayout="row">
<dsh-payment-status fxFlex="33" [status]="payment.status"> </dsh-payment-status>
<dsh-payment-tool fxFlex="33" [paymentToolDetails]="payer.paymentToolDetails"> </dsh-payment-tool>
<dsh-resource-payer *ngIf="resourcePayer" [payer]="resourcePayer"> </dsh-resource-payer>
</div>
<dsh-shop-name [shopName]="payment.shopID | shopDetails"></dsh-shop-name>
<dsh-details-item *ngIf="payment.error?.code" [title]="t('error')">
<dsh-charge-amount [payment]="payment"></dsh-charge-amount>
<dsh-payment-fee *ngIf="payment.fee" [payment]="payment"> </dsh-payment-fee>
<dsh-payment-status [status]="payment.status"> </dsh-payment-status>
<dsh-shop-name gdColumn="1/-1" [shopName]="payment.shopID | shopDetails"></dsh-shop-name>
<dsh-details-item gdColumn="1/-1" *ngIf="payment.error?.code" [title]="t('error')">
<div class="mat-body-1">{{ payment.error | paymentErrorMessage }}</div>
</dsh-details-item>
<dsh-additional-info *ngIf="additionalInfo as info" [info]="info"></dsh-additional-info>
<dsh-additional-info gdColumn="1/-1" *ngIf="additionalInfo as info" [info]="info"></dsh-additional-info>
</div>
</ng-container>

View File

@ -1,4 +1,4 @@
<div *transloco="let t; scope: 'payment-details'; read: 'paymentDetails.refunds'">
<div *transloco="let t; scope: 'payment-details'; read: 'paymentDetails.refunds'" fxLayout="column" fxLayoutGap="24px">
<div class="refunds-title mat-title" fxLayout fxLayoutAlign="space-between center">
<div>
{{ t('title') }}