From 9398e54ab0d847ab9eb153bf63c9892b7ed73907 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9Cwanyongkang=E2=80=9D?= <“937888580@qq.com”> Date: Tue, 13 Apr 2021 16:13:46 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9E=81=E5=AE=A2=E8=A5=BF=E7=93=9C=E6=9C=88?= =?UTF-8?q?=E5=8D=A1=E8=87=AA=E5=8A=A8=E4=BC=98=E6=83=A0=E5=88=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Host/Views.Mobile/Product/Index.cshtml | 7 +++++- Host/Views.Mobile/Product/ReBuyIndex.cshtml | 7 +++++- Host/Views.Mobile/Product/buy.cshtml | 14 +++++++++++- Host/Views/Product/Index.cshtml | 6 ++++- Host/Views/Product/ReBuyIndex.cshtml | 6 ++++- Host/Views/Product/buy.cshtml | 22 +++++++++++-------- Host/Views/Product/rebuy.cshtml | 14 +++++++----- .../Service/ProductOrderService.cs | 3 --- 8 files changed, 57 insertions(+), 22 deletions(-) diff --git a/Host/Views.Mobile/Product/Index.cshtml b/Host/Views.Mobile/Product/Index.cshtml index ebfa5c5..589cb60 100644 --- a/Host/Views.Mobile/Product/Index.cshtml +++ b/Host/Views.Mobile/Product/Index.cshtml @@ -267,7 +267,12 @@

@package.Profile

-

¥@package.Price

+ + @if((package.Id == 64||package.Id == 1004)&&package.Price<60){ +

¥60.00

+ } else { +

¥@package.Price

+ }

原价:@package.LinePrice 元

diff --git a/Host/Views.Mobile/Product/ReBuyIndex.cshtml b/Host/Views.Mobile/Product/ReBuyIndex.cshtml index ff08b37..9912977 100644 --- a/Host/Views.Mobile/Product/ReBuyIndex.cshtml +++ b/Host/Views.Mobile/Product/ReBuyIndex.cshtml @@ -125,7 +125,12 @@

@package.Profile

-

¥@package.Price

+ + @if((package.Id == 64||package.Id == 1004)&&package.Price<60){ +

¥60.00

+ } else { +

¥@package.Price

+ }

原价:@package.LinePrice 元

diff --git a/Host/Views.Mobile/Product/buy.cshtml b/Host/Views.Mobile/Product/buy.cshtml index e254afb..1b7f8af 100644 --- a/Host/Views.Mobile/Product/buy.cshtml +++ b/Host/Views.Mobile/Product/buy.cshtml @@ -94,7 +94,11 @@

@Model.Package.Profile

- ¥ @Model.Package.Price + @if(Model.Package.Price < 60 && (Model.Package.Id == 64||Model.Package.Id == 1004)){ + 60.00 + } else { + @Model.Package.Price + }
@@ -426,6 +430,10 @@ computed: { OneTotalAmount: function () { var total= this.OneBuyModel.Price * this.OneBuyModel.ConnectCount + //西瓜极客优惠券 + if((@(Model.Package.Id) == 64||@(Model.Package.Id) == 1004) && @(Model.Package.Price)<60){ + total = this.OneBuyModel.ConnectCount * 60.00 + } return total.toFixed(2); }, OnePayAmount: function () { @@ -436,6 +444,10 @@ }, MoreTotalAmount: function () { var total= this.MoreBuyModel.Price * this.MoreBuyModel.ConnectCount * this.MoreBuyModel.MaxPostfix; + //西瓜极客优惠券 + if((@(Model.Package.Id) == 64||@(Model.Package.Id) == 1004) && @(Model.Package.Price)<60){ + total = this.MoreBuyModel.ConnectCount * 60.00 * this.MoreBuyModel.MaxPostfix + } return total.toFixed(2); }, MorePayAmount: function () { diff --git a/Host/Views/Product/Index.cshtml b/Host/Views/Product/Index.cshtml index 40dd235..1a3b937 100644 --- a/Host/Views/Product/Index.cshtml +++ b/Host/Views/Product/Index.cshtml @@ -800,7 +800,11 @@
-

@package.Price

+ @if((package.Id == 64||package.Id == 1004)&&package.Price<60){ +

60.00

+ } else { +

@package.Price

+ }

原价:@package.LinePrice

@(Math.Round(package.Price/package.DayCount,2))元/天

diff --git a/Host/Views/Product/ReBuyIndex.cshtml b/Host/Views/Product/ReBuyIndex.cshtml index d2111b9..9c0e186 100644 --- a/Host/Views/Product/ReBuyIndex.cshtml +++ b/Host/Views/Product/ReBuyIndex.cshtml @@ -459,7 +459,11 @@
-

@package.Price

+ @if((package.Id == 64||package.Id == 1004)&&package.Price<60){ +

60.00

+ } else { +

@package.Price

+ }

原价:@package.LinePrice

@(Math.Round(package.Price/package.DayCount,2))元/天

diff --git a/Host/Views/Product/buy.cshtml b/Host/Views/Product/buy.cshtml index 4c3dbbb..7a61b6b 100644 --- a/Host/Views/Product/buy.cshtml +++ b/Host/Views/Product/buy.cshtml @@ -100,7 +100,11 @@
-

@Model.Package.Price

+ @if(Model.Package.Price < 60 && (Model.Package.Id == 64||Model.Package.Id == 1004)){ +

60.00

+ } else { +

@Model.Package.Price

+ }

*请务必选好所需商品,换货会产生费用

@@ -494,6 +498,10 @@ computed: { OneTotalAmount: function () { var total = this.OneBuyModel.Price * this.OneBuyModel.ConnectCount + //西瓜极客优惠券 + if((@(Model.Package.Id) == 64||@(Model.Package.Id) == 1004) && @(Model.Package.Price)<60){ + total = this.OneBuyModel.ConnectCount * 60.00 + } return total.toFixed(2); }, OnePayAmount: function () { @@ -501,14 +509,14 @@ var total = this.OneBuyModel.Price * this.OneBuyModel.ConnectCount - this.OneBuyModel.CouponAmount ; total = total < 0 ? 0 : total; - //西瓜极客优惠券 - if(@(Model.Package.Id) == 64||@(Model.Package.Id) == 1004){ - total -= this.OneBuyModel.ConnectCount * (this.OneBuyModel.Price - 52.8) - } return total.toFixed(2); }, MoreTotalAmount: function () { var total = this.MoreBuyModel.Price * this.MoreBuyModel.ConnectCount * this.MoreBuyModel.MaxPostfix; + //西瓜极客优惠券 + if((@(Model.Package.Id) == 64||@(Model.Package.Id) == 1004) && @(Model.Package.Price)<60){ + total = this.MoreBuyModel.ConnectCount * 60.00 * this.MoreBuyModel.MaxPostfix + } return total.toFixed(2); }, MorePayAmount: function () { @@ -516,10 +524,6 @@ var total = this.MoreBuyModel.Price * this.MoreBuyModel.ConnectCount * this.MoreBuyModel.MaxPostfix - this.MoreBuyModel.CouponAmount ; total = total < 0 ? 0 : total; - //西瓜极客优惠券 - if(@(Model.Package.Id) == 64||@(Model.Package.Id) == 1004){ - total -= this.MoreBuyModel.ConnectCount * (this.MoreBuyModel.Price - 52.8) * this.MoreBuyModel.MaxPostfix - } return total.toFixed(2); } }, diff --git a/Host/Views/Product/rebuy.cshtml b/Host/Views/Product/rebuy.cshtml index c8def72..93afcfb 100644 --- a/Host/Views/Product/rebuy.cshtml +++ b/Host/Views/Product/rebuy.cshtml @@ -81,7 +81,11 @@
-

@Model.Package.Price

+ @if(Model.Package.Price < 60 && (Model.Package.Id == 64||Model.Package.Id == 1004)){ +

60.00

+ } else { +

@Model.Package.Price

+ }

*请务必选好所需商品,换货会产生费用

@@ -273,6 +277,10 @@ TotalAmount: function () { var count = this.OneBuyModel.Account.split(',').length; var total = this.OneBuyModel.Price * this.OneBuyModel.ConnectCount * count; + //西瓜极客优惠券 + if((@(Model.Package.Id) == 64||@(Model.Package.Id) == 1004) && @(Model.Package.Price)<60){ + total = this.OneBuyModel.ConnectCount * 60.00 * count + } return total.toFixed(2); }, PayAmount: function () { @@ -280,10 +288,6 @@ var restAmout = this.OneBuyModel.UseAccountAmount == 1 ? this.RestAmount : 0; var total = this.OneBuyModel.Price * this.OneBuyModel.ConnectCount * count - this.OneBuyModel.CouponAmount ; total= total < 0 ? 0 : total; - //西瓜极客优惠券 - if(@(Model.Package.Id) == 64||@(Model.Package.Id) == 1004){ - total -= this.OneBuyModel.ConnectCount * (this.OneBuyModel.Price - 52.8) - } return total.toFixed(2); } }, diff --git a/Services/Hncore.Pass.Vpn/Service/ProductOrderService.cs b/Services/Hncore.Pass.Vpn/Service/ProductOrderService.cs index 1d9f466..c326849 100644 --- a/Services/Hncore.Pass.Vpn/Service/ProductOrderService.cs +++ b/Services/Hncore.Pass.Vpn/Service/ProductOrderService.cs @@ -258,9 +258,6 @@ FROM product_order where {where} GROUP BY Channel,ProductName order by Channel, var is_user_price = true; var price = packageEntity.Price; - if(packageEntity.Id == 64||packageEntity.Id==1004){ - price = 52.8M; - } var userPrice = await this.m_ProductUserPriceService.Query(true).FirstOrDefaultAsync(m => m.UserId == userId && m.PackageId == packageEntity.Id && m.Status == 1); if (userPrice != null && userPrice.UserPrice > 0) {