perf: 到期时间格式化

This commit is contained in:
kuaifan 2021-12-25 02:18:56 +08:00
parent abd87f3584
commit a32995abec
4 changed files with 4 additions and 4 deletions

View File

@ -666,7 +666,7 @@ export default {
const {nowTime} = this;
return function (date) {
let time = Math.round($A.Date(date).getTime() / 1000) - nowTime;
if (time < 86400 * 4 && time > 0 ) {
if (time < 86400 * 7 && time > 0 ) {
return this.formatSeconds(time);
} else if (time <= 0) {
return '-' + this.formatSeconds(time * -1);

View File

@ -590,7 +590,7 @@ export default {
const {nowTime} = this;
return function (date) {
let time = Math.round($A.Date(date).getTime() / 1000) - nowTime;
if (time < 86400 * 4 && time > 0 ) {
if (time < 86400 * 7 && time > 0 ) {
return this.formatSeconds(time);
} else if (time <= 0) {
return '-' + this.formatSeconds(time * -1);

View File

@ -199,7 +199,7 @@ export default {
const {nowTime} = this;
return function (date) {
let time = Math.round($A.Date(date).getTime() / 1000) - nowTime;
if (time < 86400 * 4 && time > 0 ) {
if (time < 86400 * 7 && time > 0 ) {
return this.formatSeconds(time);
} else if (time <= 0) {
return '-' + this.formatSeconds(time * -1);

View File

@ -177,7 +177,7 @@ export default {
const {nowTime} = this;
return function (date) {
let time = Math.round($A.Date(date).getTime() / 1000) - nowTime;
if (time < 86400 * 4 && time > 0 ) {
if (time < 86400 * 7 && time > 0 ) {
return this.formatSeconds(time);
} else if (time <= 0) {
return '-' + this.formatSeconds(time * -1);