Browse Source

Merge remote-tracking branch 'origin/master'

jiangfeng 5 years ago
parent
commit
16f0476f53

File diff suppressed because it is too large
+ 0 - 0
hd/dist/shop/css/chunk-274b0620.089454a4.css


File diff suppressed because it is too large
+ 0 - 0
hd/dist/shop/css/chunk-36fb7920.9707ee3f.css


+ 1 - 1
hd/dist/shop/index.html

@@ -43,4 +43,4 @@
 			.once .sub-title {
 			.once .sub-title {
 				color: #ababab;
 				color: #ababab;
 				font-size: 12px;
 				font-size: 12px;
-			}</style><link href="/css/app.6f07e55a.css" rel="preload" as="style"><link href="/css/chunk-libs.2e1e87b5.css" rel="preload" as="style"><link href="/js/app.dbbacfa1.js" rel="preload" as="script"><link href="/js/chunk-libs.1c1e0cb4.js" rel="preload" as="script"><link href="/css/chunk-libs.2e1e87b5.css" rel="stylesheet"><link href="/css/app.6f07e55a.css" rel="stylesheet"></head><body><noscript></noscript><div id="app"><div class="once"><div class="container"><div class="title">正在加载资源</div><div class="sub-title">初次加载资源可能需要较多时间 请耐心等待</div></div><div class="footer"><a href="https://www.baidu.com/" target="_blank">花卉宝</a></div></div></div><script src="/cdn/vue/2.6.10/vue.min.js"></script><script src="/cdn/vue-router/3.1.3/vue-router.min.js"></script><script src="/cdn/vuex/3.1.1/vuex.min.js"></script><script src="/cdn/clipboard.js/2.0.4/clipboard.min.js"></script><script src="/cdn/axios/0.19.0-beta.1/axios.min.js"></script><script src="/cdn/nprogress/0.2.0/nprogress.min.js"></script><script src="/cdn/Mock.js/1.0.1-beta3/mock-min.js"></script><script src="/cdn/quill/2.0.0-dev.3/quill.min.js"></script><script src="/cdn/element-ui/2.13.0/index.js"></script><script src="/cdn/viewerjs/1.3.7/viewer.min.js"></script><script src="/cdn/echarts/4.4.0-rc.1/echarts.min.js"></script><script src="/cdn/npm/vue-echarts@4.0.2.js"></script><script src="/js/chunk-libs.1c1e0cb4.js"></script><script src="/js/app.dbbacfa1.js"></script></body></html>
+			}</style><link href="/css/app.6f07e55a.css" rel="preload" as="style"><link href="/css/chunk-libs.2e1e87b5.css" rel="preload" as="style"><link href="/js/app.6541a5f2.js" rel="preload" as="script"><link href="/js/chunk-libs.1c1e0cb4.js" rel="preload" as="script"><link href="/css/chunk-libs.2e1e87b5.css" rel="stylesheet"><link href="/css/app.6f07e55a.css" rel="stylesheet"></head><body><noscript></noscript><div id="app"><div class="once"><div class="container"><div class="title">正在加载资源</div><div class="sub-title">初次加载资源可能需要较多时间 请耐心等待</div></div><div class="footer"><a href="https://www.baidu.com/" target="_blank">花卉宝</a></div></div></div><script src="/cdn/vue/2.6.10/vue.min.js"></script><script src="/cdn/vue-router/3.1.3/vue-router.min.js"></script><script src="/cdn/vuex/3.1.1/vuex.min.js"></script><script src="/cdn/clipboard.js/2.0.4/clipboard.min.js"></script><script src="/cdn/axios/0.19.0-beta.1/axios.min.js"></script><script src="/cdn/nprogress/0.2.0/nprogress.min.js"></script><script src="/cdn/Mock.js/1.0.1-beta3/mock-min.js"></script><script src="/cdn/quill/2.0.0-dev.3/quill.min.js"></script><script src="/cdn/element-ui/2.13.0/index.js"></script><script src="/cdn/viewerjs/1.3.7/viewer.min.js"></script><script src="/cdn/echarts/4.4.0-rc.1/echarts.min.js"></script><script src="/cdn/npm/vue-echarts@4.0.2.js"></script><script src="/js/chunk-libs.1c1e0cb4.js"></script><script src="/js/app.6541a5f2.js"></script></body></html>

File diff suppressed because it is too large
+ 0 - 0
hd/dist/shop/js/app.6541a5f2.js


File diff suppressed because it is too large
+ 0 - 0
hd/dist/shop/js/chunk-053815d5.c6b22e3d.js


File diff suppressed because it is too large
+ 0 - 0
hd/dist/shop/js/chunk-274b0620.c369d3b4.js


File diff suppressed because it is too large
+ 0 - 0
hd/dist/shop/js/chunk-36fb7920.b03f6918.js


File diff suppressed because it is too large
+ 0 - 0
hd/dist/shop/js/chunk-b5e0bdb6.11e15cba.js


+ 1 - 1
hd/src/mock/userInfo.js

@@ -366,7 +366,7 @@ let menu = {
         {
         {
             id: '808',
             id: '808',
             parentId: '8',
             parentId: '8',
-            name: '广告列表',
+            name: '广告',
             type: 1,
             type: 1,
             icon: 'iconguanggao',
             icon: 'iconguanggao',
             orderNum: 8,
             orderNum: 8,

+ 2 - 6
hd/src/views/ad/list.vue

@@ -70,7 +70,7 @@
 					<el-form-item label="广告图名称" prop="adName">
 					<el-form-item label="广告图名称" prop="adName">
 						<el-input v-model="adForm.adName" placeholder="请输入名称" size="small"></el-input>
 						<el-input v-model="adForm.adName" placeholder="请输入名称" size="small"></el-input>
 					</el-form-item>
 					</el-form-item>
-					<el-form-item label="请选择时间">
+					<el-form-item label="有效时间段">
 						<el-col :span="11">
 						<el-col :span="11">
 							<el-form-item prop="startTime">
 							<el-form-item prop="startTime">
 								<el-date-picker
 								<el-date-picker
@@ -165,12 +165,8 @@ export default {
 			tabIndex: '0',
 			tabIndex: '0',
 			tabsData: [
 			tabsData: [
 				{
 				{
-					text: '商城首页轮播图',
+					text: '商城首页广告图',
 					key: '0'
 					key: '0'
-				},
-				{
-					text: '门店轮播图',
-					key: '1'
 				}
 				}
 			],
 			],
 			// 修改弹窗
 			// 修改弹窗

+ 12 - 8
mallApp/src/filters/constant.js

@@ -57,27 +57,27 @@ const _CONST_MAP = {
 	ORDER_STATUS: [
 	ORDER_STATUS: [
 		{
 		{
 			label: '待付款',
 			label: '待付款',
-			value: 0
-		},
-		{
-			label: '待配送',
 			value: 1
 			value: 1
 		},
 		},
 		{
 		{
-			label: '配送',
+			label: '待配送',
 			value: 2
 			value: 2
 		},
 		},
 		{
 		{
-			label: '待通知',
+			label: '配送中',
 			value: 3
 			value: 3
 		},
 		},
 		{
 		{
-			label: '已取消',
+			label: '已完成',
 			value: 4
 			value: 4
 		},
 		},
 		{
 		{
-			label: '已完成',
+			label: '已取消',
 			value: 5
 			value: 5
+		},
+		{
+			label: '已退款',
+			value: 6
 		}
 		}
 	],
 	],
 	// 配送状态
 	// 配送状态
@@ -89,6 +89,10 @@ const _CONST_MAP = {
 		{
 		{
 			label: '已接单',
 			label: '已接单',
 			value: 1
 			value: 1
+		},
+		{
+			label: '已送达',
+			value: 2
 		}
 		}
 	]
 	]
 }
 }

+ 5 - 4
mallApp/src/pages/order/detail.vue

@@ -46,14 +46,15 @@
             </div>
             </div>
             <div class="msg-list">
             <div class="msg-list">
               <div class="label">地址</div>
               <div class="label">地址</div>
-              <div class="value">{{ data.receiveFullAddress }}</div>
+              <div class="value">{{ data.fullAddress }}</div>
             </div>
             </div>
           </div>
           </div>
           <!--  -->
           <!--  -->
           <div class="order-msg-blo">
           <div class="order-msg-blo">
             <div class="msg-list">
             <div class="msg-list">
               <div class="label">送达时间</div>
               <div class="label">送达时间</div>
-              <div class="value">{{ data.reachDate ? data.reachDate+' '+reachPeriodInfo : '' }}</div>
+              <div v-if="data.reachDate == '0000-00-00'" class="value"></div>
+              <div v-else class="value">{{ data.reachDate ? data.reachDate+' '+reachPeriodInfo : '' }}</div>
             </div>
             </div>
             <div class="msg-list">
             <div class="msg-list">
               <div class="label">贺卡</div>
               <div class="label">贺卡</div>
@@ -65,7 +66,7 @@
             </div>
             </div>
             <div class="msg-list">
             <div class="msg-list">
               <div class="label">匿名派送</div>
               <div class="label">匿名派送</div>
-              <div class="value">{{ data.anonymity == 1 ? '是' : '--' }}</div>
+              <div class="value">{{ data.anonymity == 1 ? '是' : '' }}</div>
             </div>
             </div>
           </div>
           </div>
           <!--  -->
           <!--  -->
@@ -76,7 +77,7 @@
             </div>
             </div>
             <div class="msg-list">
             <div class="msg-list">
               <div class="label">时间</div>
               <div class="label">时间</div>
-              <div class="value">{{ data.addTime | formatTime }}</div>
+              <div class="value">{{ data.addTime}}</div>
             </div>
             </div>
             <div class="msg-list">
             <div class="msg-list">
               <div class="label">运费</div>
               <div class="label">运费</div>

+ 448 - 506
mallApp/src/pages/pay/index.vue

@@ -1,518 +1,460 @@
 <template>
 <template>
-  <div class="app-content pay-wrap">
-    <div class="delivery-wrap" v-if="!$util.isEmpty(orderShop)">
-      <div class="shop-logo-wrap" v-if="!$util.isEmpty(orderShop)">
-        <div class="logo-img">
-          <img :src="orderShop.merchant.smallLogoUrl | default_img" alt mode="widthFix" />
-        </div>
-      </div>
-      <div class="module-com pay-input-wrap">
-        <pay-input-module
-          :focus="inpFocus"
-          :num="amount"
-          @focusFn="focusFn"
-          @blurFn="blurFn"
-          @clickKey="clickKeyFn"
-        />
-        <div
-          class="balance"
-          v-if="!$util.isEmpty(shopUser) && shopUser.userAsset.balance && shopUser.userAsset.balance != '0.00'"
-        >
-          <span>账户余额 ¥</span>
-          <span class="app-size-30">{{ shopUser.userAsset.balance }}</span>
-        </div>
-      </div>
-      <!-- 查看更多 -->
-      <div class="view-more">
-        <div class="view-more-text">以下选填</div>
-      </div>
-      <!-- 查看更多 -->
-      <block v-if="tabIndex == 1">
-        <app-delivery-module ref="appDelivery" :anonymity="0" />
-      </block>
-      <!-- 可选优惠 -->
-      <div class="module-com discount-wrap" v-if="!$util.isEmpty(discountArr)">
-        <div class="module-tit">可选优惠</div>
-        <div class="module-det">
-          <app-coupon-sel ref="couponSel" :price="amount" :discountArr="['member', 'coupon']" />
-        </div>
-      </div>
-      <!-- 按钮 -->
-      <div class="btn-wrap">
-        <button
-          v-if="!$util.isEmpty(shopUser) && shopUser.userAsset.balance && shopUser.userAsset.balance != '0.00'"
-          class="button-com red"
-          @click="balancePayFn"
-        >余额支付</button>
-        <template v-if="isWxBrowser()">
-        <button class="button-com green" @click="wexinPayFn">微信支付</button>
-        <button class="button-com red" @click="showShare = true">支付宝支付</button>
-        </template>
-        <template v-else-if="isWxMiniapp()">
-        <button class="button-com green" @click="wexinPayFn">微信支付</button>
-        </template>
-        <template v-else>
-          <button class="button-com green" @click="wexinPayFn">微信支付</button>
-        <button class="button-com red" @click="aliPayFn">支付宝支付</button>
-        </template>
-      </div>
-    </div>
-    <!-- 支付密码弹窗 -->
-    <modal-module
-      :show="passwordModal"
-      @cancel="modalCancel"
-      @click="passwordModalClick"
-      :maskClosable="false"
-      title="支付密码"
-      padding="30rpx 30rpx"
-    >
-      <template v-slot:content>
-        <div class="app-modal-input-wrap">
-          <div class="inp-list-line">
-            <div class="line-input">
-              <input
-                type="password"
-                v-model="modalForm.payPassword"
-                :adjust-position="false"
-                class="inp-input"
-              />
-            </div>
-          </div>
-        </div>
-      </template>
-    </modal-module>
-    <!-- 阿里支付 -->
-    <div class="al-pay" v-html="aliPayHtml" ref="alipayWap"></div>
-    <!-- 未设置支付密码弹窗 -->
-    <alert-module
-      :show="setPassModal"
-      btnText="去设置"
-      btnColor="#FF2842"
-      padding="66rpx 24rpx 66rpx 24rpx"
-      @click="hideAlert"
-    >
-      <div class="go-login-module">
-        <div>请先设置支付密码!</div>
-      </div>
-    </alert-module>
-    <app-share-mask :show="showShare" @click="hideShare" text="打开浏览器支付" />
-  </div>
+	<div class="app-content pay-wrap">
+		<!-- 我要配送 -->
+		<!-- <block v-else> -->
+		<div class="delivery-wrap" v-if="!$util.isEmpty(orderShop)">
+			<div class="shop-logo-wrap" v-if="!$util.isEmpty(orderShop)">
+				<div class="logo-img">
+					<img :src="orderShop.merchant.smallLogoUrl | default_img" alt mode="widthFix" />
+				</div>
+			</div>
+			<div class="module-com pay-input-wrap">
+				<pay-input-module :focus="inpFocus" :num="amount" @focusFn="focusFn" @blurFn="blurFn" @clickKey="clickKeyFn" />
+				<div class="balance" v-if="!$util.isEmpty(shopUser) && shopUser.userAsset.balance && shopUser.userAsset.balance != '0.00'">
+					<span>账户余额 ¥</span>
+					<span class="app-size-30">{{ shopUser.userAsset.balance }}</span>
+				</div>
+			</div>
+			<!-- 查看更多 -->
+			<div class="view-more" :class="{'open' : tabIndex == 1}" @click="tabIndex = tabIndex == 0 ? 1 : 0">
+				<button type="primary" size="mini" plain="true">{{ tabIndex == 0 ? '点我填写收花人' : '收起' }}</button>
+			</div>
+			<!-- 查看更多 -->
+			<block v-if="tabIndex == 1">
+				<app-delivery-module ref="appDelivery" :anonymous="true" />
+			</block>
+			<!-- 可选优惠 -->
+			<div class="module-com discount-wrap" v-if="!$util.isEmpty(discountArr)">
+				<div class="module-tit">可选优惠</div>
+				<div class="module-det">
+					<app-coupon-sel ref="couponSel" :price="amount" :discountArr="['member', 'coupon']" />
+				</div>
+			</div>
+			<!-- 按钮 -->
+			<div class="btn-wrap">
+				<button v-if="!$util.isEmpty(shopUser) && shopUser.userAsset.balance && shopUser.userAsset.balance != '0.00'" class="button-com red" @click="balancePayFn">余额支付</button>
+				<button class="button-com green" v-if="isWxMiniapp()" @click="wexinPayFn">微信支付</button>
+				<button class="button-com red" v-else @click="aliPayFn">支付宝支付</button>
+			</div>
+		</div>
+		<!-- </block> -->
+		<!-- 支付密码弹窗 -->
+		<modal-module :show="passwordModal" @cancel="modalCancel" @click="passwordModalClick" :maskClosable="false" title="支付密码" padding="30rpx 30rpx">
+			<template v-slot:content>
+				<div class="app-modal-input-wrap">
+					<div class="inp-list-line">
+						<!-- <div class="line-label">支付密码</div> -->
+						<div class="line-input">
+							<input type="password" v-model="modalForm.payPassword" :adjust-position="false" class="inp-input" />
+						</div>
+					</div>
+				</div>
+			</template>
+		</modal-module>
+		<!-- 阿里支付 -->
+		<div class="al-pay" v-html="aliPayHtml" ref="alipayWap"></div>
+		<!-- 未设置支付密码弹窗 -->
+		<alert-module :show="setPassModal" btnText="去设置" btnColor="#FF2842" padding="66rpx 24rpx 66rpx 24rpx" @click="hideAlert">
+			<div class="go-login-module">
+				<div>暂未设置密码,去设置密码!</div>
+			</div>
+		</alert-module>
+	</div>
 </template>
 </template>
 
 
 <script>
 <script>
-import { mapGetters } from "vuex";
-import AppTabs from "@/components/plugin/tabs";
-import PayInputModule from "./components/pay-input";
-import AppDeliveryModule from "@/components/app-delivery";
-import wexinPay from "@/utils/pay/wxPay";
-import ModalModule from "@/components/plugin/modal";
-import AppCouponSel from "@/components/app-coupon-sel";
-import AlertModule from "@/components/plugin/alert";
-import AppShareMask from "@/components/module/app-share-mask";
-import { isLogin } from "@/utils/util";
-import { isWxBrowser, isWxMiniapp } from "@/utils/common";
-import { share } from "@/mixins";
-import { fastPay } from "@/api/pay";
-import { recharge } from "@/api/member";
-import { getShopUser } from "@/utils/auth";
-import { getOrderShop } from "@/utils/config";
-export default {
-  name: "pay",
-  components: {
-    AppTabs,
-    PayInputModule,
-    AppDeliveryModule,
-    ModalModule,
-    AppCouponSel,
-    AlertModule,
-    AppShareMask
-  },
-  mixins: [share],
-  data() {
-    return {
-      constant: this.$constant,
-      inpFocus: false,
-      // tab
-      tabIndex: 1,
-      tabs: [
-        {
-          name: "直接付款"
-        },
-        {
-          name: "我要配送"
-        }
-      ],
-      // 初始form
-      amount: "",
-      form: {
-        payWay: 0 // 0微信 1支付宝 2余额
-      },
-      // 支付相关 ============
-      aliPayHtml: "",
-      passwordModal: false,
-      modalForm: {
-        payPassword: ""
-      },
-      appendFrm: {
-        sendDistance: "", // 配送距离,根据腾讯js进行计算
-        receiveLat: "", // 收花人纬度
-        receiveLong: "" // 收花人经度
-      },
-      payCallData: null,
-      // 优惠折扣
-      discountArr: false,
-      // 未设置密码
-      setPassModal: false,
-      showShare:false
-    };
-  },
-  computed: {
-    ...mapGetters({ orderShop: "getOrderShop" }),
-    ...mapGetters({ shopUser: "getShopUser" })
-  },
-  onLoad(option) {
-    this.specialInit();
-  },
-  mounted() {},
-  methods: {
-    isWxBrowser: isWxBrowser,
-    isWxMiniapp: isWxMiniapp,
-    specialInit() {
-      // #ifdef H5
-      // 微信二次分享
-      let href = window.location.href;
-      if (href.indexOf("from=singlemessage") > 0) {
-        location.href = `${
-          this.$constant.formal
-        }/#/pages/pay/index${this.$util.parse(this.option)}`;
-        return false;
-      }
-      // #endif
-      if (this.option.pageType) {
-        this.tabIndex = parseInt(this.option.pageType);
-      }
-      getOrderShop().then(res => {
-        this.inpFocus = true;
-        uni.setNavigationBarTitle({
-          title: `您正在向【${res.shop.name}】付款`
-        });
-        //没有登陆不取优惠
-        if (isLogin()) {
-          this.$refs.couponSel._getUserDiscount().then(discountData => {
-            this.discountArr = discountData;
-          });
-        }
-      });
-      if (isLogin()) {
-        getShopUser(true).then(res => {
-          // 设置分享
-          let shareParams = {
-            // #ifdef H5
-            title: "点我付款",
-            desc: "享随机优惠,最高20元",
-            imgUrl: `${this.$constant.imgUrl}/retail/pay/wxSharePay.jpg`,
-            pagePath: `${this.$constant.formal}/#/pages/pay/index?account=${res.merchantId}&store=0&sourceType=3&fromType=2`,
-            // #endif
-            // #ifndef H5
-            title: "",
-            desc: "享随机优惠,最高20元",
-            imgUrl: `${this.$constant.imgUrl}/retail/pay/wxPay.png`,
-            pagePath: `/pages/pay/index?account=${res.merchantId}&store=0&sourceType=3&fromType=2`
-            // #endif
-          };
-          this.jweixinFn(shareParams);
-        });
-      }
-    },
-    _pay() {
-      if (!this.amount) {
-        this.$msg("请先输入金额!");
-        return false;
-      }
-      let params = {};
-      let host = null;
-      if (this.option.pageStatus == "recharge") {
-        params = {
-          amount: this.amount
-        };
-        host = recharge;
-      } else {
-        params = {
-          needSend: this.tabIndex == 0 ? "0" : "1",
-          prePrice: this.amount,
-          payWay: this.form.payWay,
-          payPassword: this.modalForm.payPassword
-        };
-        if (this.tabIndex == 1) {
-          let deliveryForm = this.$refs.appDelivery.form
-            ? this.$refs.appDelivery.form
-            : {};
-          let deliveryRegion = this.$refs.appDelivery.region
-            ? this.$refs.appDelivery.region
-            : {};
-          params = {
-            ...params,
-            ...deliveryForm,
-            ...deliveryRegion
-          };
-        }
-        if (this.option.store) {
-          params.store = this.option.store;
-        }
-        if (this.option.sourceType) {
-          params.sourceType = this.option.sourceType;
-        }
-        if (!this.$util.isEmpty(this.discountArr)) {
-          params.couponId = this.$refs.couponSel.couponId;
-        }
-        host = fastPay;
-      }
-      host(params).then(res => {
-        this.payCallData = res.data;
-        //错误返回判断
-        if (res.code == 0) {
-          this.$msg(res.msg);
-          return false;
-        }
+	import { mapGetters } from 'vuex'
+	import AppTabs from '@/components/plugin/tabs'
+	import PayInputModule from './components/pay-input'
+	import AppDeliveryModule from '@/components/app-delivery'
+	import wexinPay from '@/utils/pay/wxPay'
+	import ModalModule from '@/components/plugin/modal'
+	import AppCouponSel from '@/components/app-coupon-sel'
+	import AlertModule from '@/components/plugin/alert'
+	import { isLogin } from '@/utils/util'
+	import { isWxMiniapp } from '@/utils/common'
+	import { share } from '@/mixins'
+	import { fastPay } from '@/api/pay'
+	import { recharge } from '@/api/member'
+	import { getShopUser } from '@/utils/auth'
+	import { getOrderShop } from '@/utils/config'
+	export default {
+		name: 'pay',
+		components: {
+			AppTabs,
+			PayInputModule,
+			AppDeliveryModule,
+			ModalModule,
+			AppCouponSel,
+			AlertModule
+		},
+		mixins: [share],
+		data() {
+			return {
+				constant: this.$constant,
+				inpFocus: false,
+				// tab
+				tabIndex: 0,
+				tabs: [
+					{
+						name: '直接付款'
+					},
+					{
+						name: '我要配送'
+					}
+				],
+				// 初始form
+				amount: '',
+				form: {
+					payWay: 0 // 0微信 1支付宝 2余额
+				},
+				aliPayHtml: '',
+				passwordModal: false,
+				modalForm: {
+					payPassword: ''
+				},
+				appendFrm: {
+					sendDistance: '', // 配送距离,根据腾讯js进行计算
+					receiveLat: '', // 收花人纬度
+					receiveLong: '' // 收花人经度
+				},
+				payCallData: null,
+				// 优惠折扣
+				discountArr: false,
+				// 未设置密码
+				setPassModal: false
+			}
+		},
+		computed: {
+			...mapGetters({ orderShop: 'getOrderShop' }),
+			...mapGetters({ shopUser: 'getShopUser' })
+		},
+		onLoad(option) {
+			this.specialInit()
+		},
+		mounted() {},
+		methods: {
+			isWxMiniapp(){
+        		return isWxMiniapp()
+      		},
+			specialInit() {
+				// #ifdef H5
+				// 微信二次分享
+				let href = window.location.href
+				if (href.indexOf('from=singlemessage') > 0) {
+					location.href = `${this.$constant.formal}/#/pages/pay/index${this.$util.parse(this.option)}`
+					return false
+				}
+				// #endif
+				if (this.option.pageType) {
+					this.tabIndex = parseInt(this.option.pageType)
+				}
+				getOrderShop().then(res => {
+					this.inpFocus = true
+					uni.setNavigationBarTitle({
+						title: `您正在向【${res.shop.merchantName}】付款`
+					})
 
 
-        if (this.form.payWay == 0) {
-          wexinPay(res.data, this.paySuccess, this.payFail);
-        } else if (this.form.payWay == 1) {
-          this.aliPayHtml = res;
-          this.$nextTick(() => {
-            this.$refs.alipayWap.children[0].submit();
-          });
-        } else {
-          this.paySuccess();
-        }
-      });
-    },
-    // tab切换
-    tabChange(e) {
-      this.tabIndex = e.index;
-      this.inpFocus = true;
-    },
-    // 点击输入框
-    focusFn() {
-      this.inpFocus = true;
-    },
-    // 失焦
-    blurFn() {
-      this.inpFocus = false;
-    },
-    // 点击键盘
-    clickKeyFn(val) {
-      this.amount = val;
-    },
-    // 支付宝支付
-    aliPayFn() {
-      this.form.payWay = 1;
-      this._pay();
-    },
-    // 微信支付
-    wexinPayFn() {
-      this.form.payWay = 0;
-      this._pay();
-    },
-    // 暂未设置密码
-    hideAlert() {
-      this.$util.pageTo("/pages/user/password");
-    },
-    // 余额支付
-    balancePayFn() {
-      if (!this.$util.isEmpty(this.shopUser) && this.shopUser.hasPayPwd == 0) {
-        this.setPassModal = true;
-      } else {
-        this.form.payWay = 2;
-        this.passwordModal = true;
-      }
-    },
-    passwordModalClick(e) {
-      if (e.index === 0) {
-        this.modalCancel();
-      } else {
-        this._pay();
-      }
-    },
-    modalCancel() {
-      this.passwordModal = false;
-      this.modalForm.payPassword = "";
-    },
-    // 支付成功
-    paySuccess() {
-      // alert('支付成功!')
-      this.$util.pageTo({
-        url: "/pages/callback/index",
-        type: 2,
-        query: {
-          pageStatus: 3,
-          id: this.payCallData.orderId,
-          ...this.params
-        }
-      });
-    },
-    payFail() {
-      alert("支付失败!");
-    },
-    changeDelivery() {
-      this.tabIndex = this.tabIndex == 0 ? 1 : 0;
-      if (this.tabIndex === 1) {
-        this.inpFocus = false;
-      }
-    },
-    hideShare() {
-      this.showShare = false;
-    }
-  }
-};
+					this.$refs.couponSel._getUserDiscount().then(status => {
+						this.discountArr = status
+					})
+				})
+				if (isLogin()) {
+					getShopUser(true).then(res => {
+						console.log('shopUser', res)
+						// 设置分享
+						let shareParams = {
+							title: `点我付款`, // 分享标题
+							desc: '享随机优惠,最高20元', // 分享内容
+							imgUrl: `${this.$constant.imgUrl}/retail/pay.jpg`,
+							// #ifdef H5
+							pagePath: `${this.$constant.formal}/#/pages/pay/index?account=${res.merchantId}&store=0&sourceType=3`,
+							// #endif
+							// #ifndef H5
+							pagePath: `/pages/pay/index?account=${res.merchantId}&store=0&sourceType=3`
+							// #endif
+						}
+						this.jweixinFn(shareParams)
+					})
+				}
+			},
+			_pay() {
+				if (!this.amount) {
+					this.$msg('请先输入金额!')
+					return false
+				}
+				let params = {}
+				let host = null
+				if (this.option.pageStatus == 'recharge') {
+					params = {
+						amount: this.amount
+					}
+					host = recharge
+				} else {
+					params = {
+						needSend: this.tabIndex == 0 ? '0' : '1',
+						prePrice: this.amount,
+						payWay: this.form.payWay,
+						payPassword:this.modalForm.payPassword
+					}
+					if (this.tabIndex == 1) {
+						let deliveryForm = this.$refs.appDelivery.form ? this.$refs.appDelivery.form : {}
+						let deliveryRegion = this.$refs.appDelivery.region ? this.$refs.appDelivery.region : {}
+						params = {
+							...params,
+							...deliveryForm,
+							...deliveryRegion
+						}
+					}
+					if (this.option.store) {
+						params.store = this.option.store
+					}
+					if (this.option.sourceType) {
+						params.sourceType = this.option.sourceType
+					}
+					if (!this.$util.isEmpty(this.discountArr)) {
+						params.couponId = this.$refs.couponSel.couponId
+					}
+					host = fastPay
+				}
+				host(params).then(res => {
+					this.payCallData = res.data
+					//错误返回判断
+					if(res.code == 0){
+						this.$msg(res.msg)
+						return false
+					}
+					if (this.form.payWay == 0) {
+						wexinPay(res.data, this.paySuccess, this.payFail)
+					} else if (this.form.payWay == 1) {
+						this.aliPayHtml = res
+						this.$nextTick(() => {
+							this.$refs.alipayWap.children[0].submit()
+						})
+					} else {
+						this.paySuccess()
+					}
+				})
+			},
+			// tab切换
+			tabChange(e) {
+				this.tabIndex = e.index
+				this.inpFocus = true
+			},
+			// 点击输入框
+			focusFn() {
+				this.inpFocus = true
+			},
+			// 失焦
+			blurFn() {
+				this.inpFocus = false
+			},
+			// 点击键盘
+			clickKeyFn(val) {
+				this.amount = val
+			},
+			// 支付宝支付
+			aliPayFn() {
+				this.form.payWay = 1
+				this._pay()
+			},
+			// 微信支付
+			wexinPayFn() {
+				this.form.payWay = 0
+				this._pay()
+			},
+			// 暂未设置密码
+			hideAlert() {
+				this.$util.pageTo('/pages/user/password')
+			},
+			// 余额支付
+			balancePayFn() {
+				if (!this.$util.isEmpty(this.shopUser) && this.shopUser.hasPayPwd == 0) {
+					this.setPassModal = true
+				} else {
+					this.form.payWay = 2
+					this.passwordModal = true
+				}
+			},
+			passwordModalClick(e) {
+				if (e.index === 0) {
+					this.modalCancel()
+				} else {
+					this._pay()
+				}
+			},
+			modalCancel() {
+				this.passwordModal = false
+				this.modalForm.payPassword = ''
+			},
+			// 支付成功
+			paySuccess() {
+				this.$util.pageTo({
+					url: '/pages/callback/index',
+					type: 2,
+					query: {
+						pageStatus: 3,
+            orderSn:this.payCallData.orderSn,
+            totalPrice:this.payCallData.totalPrice,
+						id: this.payCallData.orderId,
+						...this.params
+					}
+				})
+			},
+			payFail() {
+				alert('支付失败!')
+			}
+		}
+	}
 </script>
 </script>
 
 
 <style lang="scss">
 <style lang="scss">
-.app-content {
-  min-height: calc(100vh - 20px);
-  padding-top: 20px;
-}
-.tabs-wrap {
-  position: fixed;
-  top: 0;
-  width: 100%;
-  height: 80px;
-  line-height: 80px;
-  text-align: center;
-  background-color: #fff;
-  font-size: 30px;
-  box-shadow: 4px 4px 10px #eee;
-}
+	.app-content {
+		min-height: calc(100vh - 20px);
+		padding-top: 20px;
+	}
+	.tabs-wrap {
+		position: fixed;
+		top: 0;
+		width: 100%;
+		height: 80px;
+		line-height: 80px;
+		text-align: center;
+		background-color: #fff;
+		font-size: 30px;
+		box-shadow: 4px 4px 10px #eee;
+	}
 
 
-.pay-wrap {
-  .logo-wrap {
-    padding-top: 70px;
-    padding-bottom: 60px;
-    text-align: center;
-    .logo-img {
-      width: 120px;
-      margin: 0 auto 20px;
-      border-radius: 50%;
-      img {
-        border-radius: 50%;
-      }
-    }
-  }
-  .pay-input-wrap {
-    background-color: #fff;
-    border-top-left-radius: 20px;
-    border-top-right-radius: 20px;
-    padding: 50px 80px 28px;
-    margin-bottom: 0 !important;
-    .balance {
-      margin-top: 30px;
-      color: $fontColor2;
-    }
-    .btn-wrap {
-      width: 100%;
-      margin-top: 64px;
-      .button-com {
-        display: block;
-        margin-bottom: 20px;
-        padding-top: 30px;
-        padding-bottom: 30px;
-      }
-    }
-  }
-}
+	.pay-wrap {
+		.logo-wrap {
+			padding-top: 70px;
+			padding-bottom: 60px;
+			text-align: center;
+			.logo-img {
+				width: 120px;
+				margin: 0 auto 20px;
+				border-radius: 50%;
+				img {
+					border-radius: 50%;
+				}
+			}
+		}
+		.pay-input-wrap {
+			background-color: #fff;
+			border-top-left-radius: 20px;
+			border-top-right-radius: 20px;
+			padding: 50px 80px 28px;
+			margin-bottom: 0 !important;
+			.balance {
+				margin-top: 30px;
+				color: $fontColor2;
+			}
+			.btn-wrap {
+				width: 100%;
+				margin-top: 64px;
+				.button-com {
+					display: block;
+					margin-bottom: 20px;
+					padding-top: 30px;
+					padding-bottom: 30px;
+				}
+			}
+		}
+	}
 
 
-// 我要配送
-.delivery-wrap {
-  .module-com {
-    margin-bottom: 20px;
-    background-color: #fff;
-    .module-tit {
-      padding: 20px 18px;
-      font-size: 28px;
-      font-weight: 600;
-      border-bottom: 1px solid $borderColor;
-    }
-    .module-det {
-      padding: 0 30px;
-    }
-  }
-  // 金额
-  .pay-input-wrap {
-    padding: 50px 36px 38px;
-    .balance {
-      margin-top: 30px;
-      color: $fontColor2;
-    }
-  }
-  .shop-logo-wrap {
-    padding-bottom: 20px;
-    @include disFlex(center, center);
-    .logo-img {
-      width: 120px;
-      border-radius: 50%;
-      margin: 10px auto;
-      // margin-right: 20px;
-      img {
-        border-radius: 50%;
-      }
-    }
-  }
-  // 可选优惠
-  .discount-wrap {
-    .module-det {
-      padding-top: 20px;
-      padding-bottom: 20px;
-    }
-  }
-  // 匿名派送
-  .none-name-delivery {
-    // padding-left: 30px;
-    padding: 26px 30px;
-    // margin-top: 40px;
-    margin-bottom: 20px;
-    background-color: #fff;
-    .none-name-text {
-      margin-left: 14px;
-      color: $fontColor2;
-    }
-  }
-  // 按钮
-  .btn-wrap {
-    width: calc(100% - 60px);
-    margin: 64px auto 0;
-    padding-bottom: 20px;
-    .button-com {
-      display: block;
-      margin-bottom: 20px;
-      padding-top: 30px;
-      padding-bottom: 30px;
-      &:last-child {
-        margin-bottom: 0;
-      }
-    }
-  }
+	// 我要配送
+	.delivery-wrap {
+		.module-com {
+			margin-bottom: 20px;
+			background-color: #fff;
+			.module-tit {
+				padding: 20px 18px;
+				font-size: 28px;
+				font-weight: 600;
+				border-bottom: 1px solid $borderColor;
+			}
+			.module-det {
+				padding: 0 30px;
+			}
+		}
+		// 金额
+		.pay-input-wrap {
+			padding: 50px 36px 38px;
+			.balance {
+				margin-top: 30px;
+				color: $fontColor2;
+			}
+		}
+		.shop-logo-wrap {
+			padding-bottom: 20px;
+			@include disFlex(center, center);
+			.logo-img {
+				width: 120px;
+				border-radius: 50%;
+				margin: 10px auto;
+				// margin-right: 20px;
+				img {
+					border-radius: 50%;
+				}
+			}
+		}
+		// 可选优惠
+		.discount-wrap {
+			.module-det {
+				padding-top: 20px;
+				padding-bottom: 20px;
+			}
+		}
+		// 匿名派送
+		.none-name-delivery {
+			// padding-left: 30px;
+			padding: 26px 30px;
+			// margin-top: 40px;
+			margin-bottom: 20px;
+			background-color: #fff;
+			.none-name-text {
+				margin-left: 14px;
+				color: $fontColor2;
+			}
+		}
+		// 按钮
+		.btn-wrap {
+			width: calc(100% - 60px);
+			margin: 64px auto 0;
+			padding-bottom: 20px;
+			.button-com {
+				display: block;
+				margin-bottom: 20px;
+				padding-top: 30px;
+				padding-bottom: 30px;
+				&:last-child {
+					margin-bottom: 0;
+				}
+			}
+		}
 
 
-  // 查看更多
-  .view-more {
-    width: 100%;
-    padding-bottom: 20px;
-    margin-bottom: 20px;
-    font-size: 28px;
-    @include disFlex(center, center);
-    background-color: #fff;
-    color: #cccccc;
-    .view-more-text {
-      margin-left: 0px;
-    }
-    i {
-      font-size: 30px;
-      font-weight: 600;
-    }
-    &.open {
-      i {
-        transform: rotate(180deg);
-      }
-    }
-  }
-}
+		// 查看更多
+		.view-more {
+			width: 100%;
+			// padding-top: 10px;
+			padding-bottom: 20px;
+			margin-bottom: 20px;
+			font-size: 28px;
+			@include disFlex(center, center);
+			background-color: #fff;
+			color: #3385ff;
+			.view-more-text {
+				margin-right: 14px;
+			}
+			i {
+				font-size: 30px;
+				font-weight: 600;
+			}
+			&.open {
+				i {
+					transform: rotate(180deg);
+				}
+			}
+		}
+	}
 </style>
 </style>

Some files were not shown because too many files changed in this diff