From 9b3e474023b49a58478b2063a708194f227dc3ae Mon Sep 17 00:00:00 2001 From: huangdeliang Date: Fri, 12 Mar 2021 09:33:04 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=88=907=E5=A4=A9=E4=BD=93?= =?UTF-8?q?=E9=AA=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- stdiet-ui/src/components/RecipesPlanDrawer/index.vue | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/stdiet-ui/src/components/RecipesPlanDrawer/index.vue b/stdiet-ui/src/components/RecipesPlanDrawer/index.vue index 67decb0d7..54c7537f4 100644 --- a/stdiet-ui/src/components/RecipesPlanDrawer/index.vue +++ b/stdiet-ui/src/components/RecipesPlanDrawer/index.vue @@ -44,7 +44,7 @@ v-if="fansChannel === 1" @click="createOneDay" > - 生成1天体验计划 + 生成7天体验计划 @@ -140,6 +140,7 @@ import { listRecipesPlanByCusId } from "@/api/custom/recipesPlan"; import { addRecipesPlan } from "@/api/custom/recipesPlan"; import PlanPauseDrawer from "./PlanPauseDrawer"; import VueQr from "vue-qr"; +import dayjs from "dayjs"; const logo = require("@/assets/logo/logo_b.png"); export default { name: "RecipesPlanDrawer", @@ -167,7 +168,7 @@ export default { }, fanPickerOptions: { disabledDate(time) { - return time.getTime() < Date.now(); + return time.getTime() < Date.now() - 24 * 60 * 60 * 1000; }, }, }; @@ -240,9 +241,9 @@ export default { addRecipesPlan({ cusId: id, startNumDay: 1, - endNumDay: 1, + endNumDay: 7, startDate: this.form.startDate, - endDate: this.form.startDate, + endDate: dayjs(this.form.startDate).add(6, "day").format("YYYY-MM-DD"), }) .then((res) => { if (res.code === 200) {