update pay function
This commit is contained in:
@@ -668,8 +668,8 @@ export default function SubscriptionContentNew() {
|
||||
</Text>
|
||||
</HStack>
|
||||
<Text color="#D4AF37" fontSize="md" fontWeight="bold">
|
||||
{user.end_date
|
||||
? new Date(user.end_date).toLocaleDateString('zh-CN', {
|
||||
{user.subscription_end_date
|
||||
? new Date(user.subscription_end_date).toLocaleDateString('zh-CN', {
|
||||
year: 'numeric',
|
||||
month: 'long',
|
||||
day: 'numeric'
|
||||
@@ -679,8 +679,8 @@ export default function SubscriptionContentNew() {
|
||||
</Text>
|
||||
</Flex>
|
||||
|
||||
{user.end_date && (() => {
|
||||
const endDate = new Date(user.end_date);
|
||||
{user.subscription_end_date && (() => {
|
||||
const endDate = new Date(user.subscription_end_date);
|
||||
const today = new Date();
|
||||
const daysLeft = Math.ceil((endDate.getTime() - today.getTime()) / (1000 * 60 * 60 * 24));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user