Browse Source

Add OutOfStock button in Index

pull/66/head
enisn 5 years ago
parent
commit
a6f8dec06e
  1. 9
      apps/public-web/src/EShopOnAbp.PublicWeb/Pages/Index.cshtml
  2. 1
      shared/EShopOnAbp.Shared.Localization/Localization/EShopOnAbp/en.json
  3. 3
      shared/EShopOnAbp.Shared.Localization/Localization/EShopOnAbp/tr.json

9
apps/public-web/src/EShopOnAbp.PublicWeb/Pages/Index.cshtml

@ -49,7 +49,14 @@
</div>
<img src="@productImage"/>
<div class="row mt-5 ">
<abp-button class="add-basket-button" button-type="Warning" text="@buyText" data-product-id="@product.Id.ToString()"></abp-button>
@if(product.StockCount > 0)
{
<abp-button class="add-basket-button" button-type="Warning" text="@buyText" data-product-id="@product.Id.ToString()"></abp-button>
}
else
{
<abp-button disabled="true" class="add-basket-button" button-type="Warning" text="@L["Index:OutOfStock"]" />
}
<div class="info-section col" style="text-align: center">
<span class="product-price">@productPrice</span>
</div>

1
shared/EShopOnAbp.Shared.Localization/Localization/EShopOnAbp/en.json

@ -24,6 +24,7 @@
"CompletePurchase": "Complete purchase",
"CompleteOrder": "Complete order",
"Index:AddToBasket": "Add to basket",
"Index:OutOfStock": "Out of Stock",
"Payment:SelectAddress": "Select Address",
"Payment:PaymentMethod.paypal": "PayPal",
"Payment:PaymentMethod.demo": "Demo",

3
shared/EShopOnAbp.Shared.Localization/Localization/EShopOnAbp/tr.json

@ -12,7 +12,7 @@
"TotalSelected": "Seçilen Ürünler ({0})",
"OurProducts": "Ürünlerimiz",
"FreeCargo": "Ücretsiz Kargo",
"Purchase:GiftCards":"Hediye Çekleri",
"Purchase:GiftCards": "Hediye Çekleri",
"Purchase:CargoAndPackaging": "Kargo ve Paketleme",
"Purchase:Total": "Toplam",
"Purchase:OrderSummary": "Sipariş Özeti",
@ -24,6 +24,7 @@
"CompletePurchase": "Alışverişi tamamla",
"CompleteOrder": "Siparişi onayla",
"Index:AddToBasket": "Sepete ekle",
"Index:OutOfStock": "Şu anda mevcut değil",
"Payment:SelectAddress": "Adres Seçin",
"Payment:SelectPaymentMethod": "Ödeme Şeklini Seçin",
"OrderReceived:AcceptedOrder": "Siparişiniz alındı!",

Loading…
Cancel
Save