Compare commits
3 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
802e6f1f86 | ||
![]() |
8df64e5616 | ||
![]() |
c992731a78 |
@ -5,3 +5,6 @@ import oahttp from "@/utils/oahttp.js";
|
||||
*/
|
||||
export const noticeList = (data) => oahttp.get('/article/lists', data)
|
||||
export const noticeDetail = (data) => oahttp.get('/article/detail', data)
|
||||
|
||||
// 任务通知
|
||||
export const taskStartNoticeApi = (data) => oahttp.get('/task/taskStartNotice', data)
|
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<view class="c_card">
|
||||
<view class="f_card">
|
||||
<view class="item" @click="navTo('/subpkg/topUp/deposit')">
|
||||
<view class="item" @click="navTo('/subpkg/topUpDeposit/topUpDeposit')">
|
||||
<view>押金(元)</view>
|
||||
<view class="price" v-if="company.deposit">{{cCount(+company.deposit)}}</view>
|
||||
<view class="price" v-else>0.00</view>
|
||||
|
@ -95,6 +95,16 @@
|
||||
<text>任务金额 :</text>
|
||||
<text> {{ datas.money + "元" || "0.00" }} </text>
|
||||
</view>
|
||||
<view class="">
|
||||
<text>执行人 :</text>
|
||||
<text v-if="datas.director_uid != 0"> {{ datas.directorInfo.nickname}} </text>
|
||||
<text v-if="datas.director_uid == 0"> 指定人员 </text>
|
||||
</view>
|
||||
<!-- <view class="">
|
||||
<text>任务进度 :</text>
|
||||
<u-line-progress :percentage="30" :activeColor="taskProgressColor(30)"></u-line-progress>
|
||||
|
||||
</view> -->
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
@ -168,6 +178,14 @@
|
||||
},
|
||||
|
||||
methods: {
|
||||
taskProgressColor(value) {
|
||||
if (value < 100) return "#FF7C32"
|
||||
else {
|
||||
return '#1BA035'
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
navTo(url) {
|
||||
if (url) {
|
||||
uni.showLoading({
|
||||
|
@ -19,9 +19,9 @@ switch (env) {
|
||||
httpApiTwo = 'https://preview-logistics.lihaink.cn' //预上线
|
||||
break;
|
||||
case 'local':
|
||||
httpApi = 'http://192.168.1.20:8000' //预上线
|
||||
httpApiThree = 'http://192.168.1.20:8000' //预上线
|
||||
httpApiTwo = 'http://192.168.1.20:8000' //预上线
|
||||
httpApi = 'http://127.0.0.1:8000' //预上线
|
||||
httpApiThree = 'http://127.0.0.1:8000' //预上线
|
||||
httpApiTwo = 'http://127.0.0.1:8000' //预上线
|
||||
break;
|
||||
default:
|
||||
httpApi = 'https://ceshi-worker-task.lihaink.cn' //测试
|
||||
|
@ -3,8 +3,8 @@
|
||||
// "appid" : "__UNI__3A527D1",
|
||||
"appid": "__UNI__B5B1EDD",
|
||||
"description": "",
|
||||
"versionName": "1.3.3",
|
||||
"versionCode": 133,
|
||||
"versionName": "1.2.8",
|
||||
"versionCode": 128,
|
||||
"transformPx": false,
|
||||
/* 5+App特有相关 */
|
||||
"app-plus": {
|
||||
|
19
pages.json
19
pages.json
@ -438,25 +438,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
}, {
|
||||
"path": "topUp/deposit",
|
||||
"style": {
|
||||
"navigationBarTitleText": "押金充值",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationBarBackgroundColor": "#0122C7",
|
||||
"navigationBarTextStyle": "white",
|
||||
"app-plus": {
|
||||
"titleNView": {
|
||||
"buttons": [{
|
||||
"color": "#fff",
|
||||
"text": "充值记录",
|
||||
"fontSize": "15",
|
||||
"width": "90"
|
||||
}]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}, {
|
||||
"path": "contract/contract",
|
||||
"style": {
|
||||
|
@ -4,11 +4,8 @@
|
||||
<u-tabs :list="tabLists" @click="changeCurrent" lineColor='white' :scrollable="false" lineWidth='20'
|
||||
inactiveStyle='color:white' activeStyle="color:white"></u-tabs>
|
||||
</u-sticky>
|
||||
|
||||
<!-- {{typeTabLists}} -->
|
||||
|
||||
<u-tabs style="background-color: #fff;" :list="typeTabLists" @click="changeTypeCurrent" lineColor='#0022C7'
|
||||
lineWidth='40' inactiveStyle='color:#0022C7' activeStyle="color:#0022C7"></u-tabs>
|
||||
<u-tabs style="background-color: #fff;" :list="typeTabLists" @click="changeTypeCurrent" lineColor='#0022C7' lineWidth='40'
|
||||
inactiveStyle='color:#0022C7' activeStyle="color:#0022C7"></u-tabs>
|
||||
<view v-if="check_status==2||check_status==3" class="p_list">
|
||||
<block v-for="(item,index) in list" :key="index">
|
||||
<merchantAudit :datas="item"></merchantAudit>
|
||||
@ -22,13 +19,8 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
Toast
|
||||
} from '@/libs/uniApi.js'
|
||||
import {
|
||||
approveLists,
|
||||
approveTypes
|
||||
} from "@/api/approve.js"
|
||||
import { Toast } from '@/libs/uniApi.js'
|
||||
import { approveLists, approveTypes } from "@/api/approve.js"
|
||||
import merchantAudit from '@/components/merchantAudit/merchantAudit.vue'
|
||||
export default {
|
||||
components: {
|
||||
@ -36,7 +28,7 @@
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
tabLists: [{
|
||||
tabLists: [ {
|
||||
name: '审核中',
|
||||
id: 1
|
||||
}, {
|
||||
@ -48,7 +40,7 @@
|
||||
}, {
|
||||
name: '全部',
|
||||
id: 0
|
||||
}, ],
|
||||
},],
|
||||
typeTabLists: [],
|
||||
current: 0,
|
||||
currentID: 1, // 审核中,已通过,为通过,全部
|
||||
@ -71,18 +63,18 @@
|
||||
uni.$on('initMerchant', this.initList);
|
||||
},
|
||||
onShow() {
|
||||
if (this.typeTabLists.length > 0) {
|
||||
if(this.typeTabLists.length>0){
|
||||
this.loadConfig.page = 1;
|
||||
this.loadConfig.status = "loading";
|
||||
this.list = [];
|
||||
this.$u.sleep(200).then(() => {
|
||||
this.$u.sleep(200).then(()=>{
|
||||
this.loadList();
|
||||
})
|
||||
}
|
||||
},
|
||||
async onPullDownRefresh() {
|
||||
await this.initList();
|
||||
this.$u.sleep(200).then(() => {
|
||||
this.$u.sleep(200).then(()=>{
|
||||
uni.stopPullDownRefresh();
|
||||
})
|
||||
},
|
||||
@ -90,26 +82,26 @@
|
||||
this.loadList();
|
||||
},
|
||||
methods: {
|
||||
async initType() {
|
||||
async initType(){
|
||||
let res = await approveTypes();
|
||||
res.data.forEach((item) => {
|
||||
if (item.id != 1) this.typeTabLists.push({
|
||||
res.data.forEach((item)=>{
|
||||
if(item.id!=1) this.typeTabLists.push({
|
||||
id: item.id,
|
||||
name: item.title
|
||||
})
|
||||
})
|
||||
this.check_status = this.typeTabLists[0].id;
|
||||
this.$nextTick(() => {
|
||||
this.$nextTick(()=>{
|
||||
this.initList();
|
||||
})
|
||||
},
|
||||
async initList() {
|
||||
async initList(){
|
||||
this.loadConfig.page = 1;
|
||||
this.loadConfig.status = "loadmore";
|
||||
this.list = [];
|
||||
await this.loadList();
|
||||
},
|
||||
async loadList() {
|
||||
async loadList(){
|
||||
if (this.loadConfig.status == "nomore") return;
|
||||
this.loadConfig.status = "loading";
|
||||
let query = {
|
||||
@ -117,7 +109,7 @@
|
||||
page: this.loadConfig.page,
|
||||
limit: this.loadConfig.limit
|
||||
}
|
||||
this.currentID ? query.check_status = this.currentID : null;
|
||||
this.currentID?query.check_status=this.currentID:null;
|
||||
let res = await approveLists(query);
|
||||
this.loadConfig.status = "loadmore"
|
||||
if (res.data.lists.length < this.loadConfig.limit) {
|
||||
@ -145,8 +137,7 @@
|
||||
.all_box {
|
||||
padding-bottom: 21rpx;
|
||||
}
|
||||
|
||||
.p_list {
|
||||
.p_list{
|
||||
padding-top: 28rpx;
|
||||
}
|
||||
</style>
|
@ -76,8 +76,14 @@
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 任务通知 -->
|
||||
<view class="" style="width: 694.74rpx;margin: 0 auto;" v-if="taskNotice">
|
||||
<u-notice-bar :text="taskNotice" mode="closable" scrollable url="/pages/bar/bar"></u-notice-bar>
|
||||
</view>
|
||||
|
||||
<!-- 片区经理聊天 -->
|
||||
<view class="chat" @click="navTo('/subpkg/chatMang/index')" style="margin-top: 130rpx;">
|
||||
<view class="chat" @click="navTo('/subpkg/chatMang/index')" style="margin-top: 10rpx;">
|
||||
<view class="chat-l">
|
||||
<u--image shape="circle" :showLoading="true" :src="managerInfo.manager_avatar" width="91rpx"
|
||||
height="91rpx"></u--image>
|
||||
@ -188,7 +194,8 @@
|
||||
oaHomeData
|
||||
} from "@/static/server/server.js";
|
||||
import {
|
||||
noticeList
|
||||
noticeList,
|
||||
taskStartNoticeApi
|
||||
} from "@/api/notice.js";
|
||||
import {
|
||||
getAreaManagerApi
|
||||
@ -219,7 +226,7 @@
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
|
||||
taskNotice: '',
|
||||
brange: 0,
|
||||
options: {
|
||||
data: '',
|
||||
@ -270,6 +277,7 @@
|
||||
};
|
||||
},
|
||||
async onLoad() {
|
||||
this.getTaskNotice()
|
||||
// console.log('asdashg')
|
||||
if (uni.getStorageSync('USER_INFO')) {
|
||||
let userData = JSON.parse(uni.getStorageSync('USER_INFO'))
|
||||
@ -277,11 +285,12 @@
|
||||
this.initUserInfo(userData);
|
||||
// console.log(545)
|
||||
}
|
||||
console.log(7787878)
|
||||
await this.$onLaunched;
|
||||
this.is_captain = JSON.parse(uni.getStorageSync("USER_INFO") || '{}')?.is_captain
|
||||
this.options.data = bj;
|
||||
|
||||
|
||||
|
||||
//#ifdef APP-PLUS
|
||||
let that = this;
|
||||
jpushModule.addNotificationListener(function(result) {
|
||||
@ -330,7 +339,6 @@
|
||||
|
||||
let user_id = JSON.parse(uni.getStorageSync("USER_INFO")).id
|
||||
this.getOrderList();
|
||||
console.log("show")
|
||||
getAreaManagerApi({
|
||||
user_id
|
||||
}).then(res => {
|
||||
@ -399,7 +407,6 @@
|
||||
const route = '/pages/oaHome/oaHome';
|
||||
let arr = [];
|
||||
n.forEach((item) => {
|
||||
|
||||
if (item.paths.includes(route)) {
|
||||
arr = item.children;
|
||||
}
|
||||
@ -415,6 +422,14 @@
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
||||
// 任务通知
|
||||
async getTaskNotice() {
|
||||
let res = await taskStartNoticeApi()
|
||||
this.taskNotice = res.data?.template?.title ?
|
||||
`您的${res.data.template.title}任务即将于${res.data.template.cron_time}日开始` : ""
|
||||
},
|
||||
|
||||
// 通知
|
||||
noticeFn() {
|
||||
jpushModule.addNotificationListener(res => {
|
||||
@ -601,6 +616,9 @@
|
||||
await this.getOrderList();
|
||||
await this.$store.dispatch('initConfig');
|
||||
await this.getApproveList();
|
||||
await this.getTaskNotice();
|
||||
|
||||
|
||||
// this.getIndexList()
|
||||
uni.stopPullDownRefresh();
|
||||
},
|
||||
|
@ -48,11 +48,6 @@
|
||||
<view>详细地址:</view>
|
||||
<view>{{extend.address}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<view>公司性质:</view>
|
||||
<view>{{extend.is_company==1?"对公户":"个体户" }}</view>
|
||||
</view>
|
||||
|
||||
<view class="b_item">
|
||||
<view>公司名称:</view>
|
||||
<view>{{extend.company_name}}</view>
|
||||
@ -75,7 +70,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="body">
|
||||
<block v-for="(item, index) in extend.qualification" :key="">
|
||||
<block v-for="(item, index) in extend.qualification">
|
||||
<image @click="priview(item)" :src="item"></image>
|
||||
<view v-if="index<extend.qualification.length-1"
|
||||
style="border-top: 1px dashed #0022c7;margin: 28rpx 0;">
|
||||
@ -90,48 +85,20 @@
|
||||
<view>身份证明信息</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view class="body" v-if="extend.is_company==1">
|
||||
<view class="body">
|
||||
<view class="b_item">
|
||||
<view>公司名称: </view>
|
||||
<view>{{extend.company_name}}</view>
|
||||
</view>
|
||||
|
||||
<view class="b_item">
|
||||
<view>对公账号: </view>
|
||||
<view>{{extend.bank_code}}</view>
|
||||
</view>
|
||||
|
||||
<view class="b_item">
|
||||
<view>开户银行: </view>
|
||||
<view>{{extend.bank_username}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<view>开户网点: </view>
|
||||
<view>{{extend.bank_opening}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<view>开户凭证:</view>
|
||||
</view>
|
||||
<image @click="priview(extend.bank_front)" :src="extend.bank_front"></image>
|
||||
<!-- <view class="b_item">
|
||||
<view>对公账号: </view>
|
||||
<view>对公账号:</view>
|
||||
<view>{{extend.bank_code}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<view>开户行名称: </view>
|
||||
<view>开户行名称:</view>
|
||||
<view>{{extend.bank_username}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<view>开户行地址: </view>
|
||||
<view>{{extend.bank_opening}}</view>
|
||||
</view> -->
|
||||
<!-- <view class="b_item">
|
||||
<view>银行卡号:</view>
|
||||
<view>开户行地址:</view>
|
||||
<view>{{extend.bank_opening}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<!-- <view class="b_item">
|
||||
<view>银行卡正面:</view>
|
||||
</view>
|
||||
<image @click="priview(extend.bank_front)" :src="extend.bank_front"></image>
|
||||
@ -148,66 +115,6 @@
|
||||
</view>
|
||||
<image @click="priview(extend.cardno_back)" :src="extend.cardno_back"></image> -->
|
||||
</view>
|
||||
|
||||
|
||||
<view class="body" v-else>
|
||||
<view class="b_item">
|
||||
<view>持卡人: </view>
|
||||
<view>{{extend.master_name}}</view>
|
||||
</view>
|
||||
|
||||
<view class="b_item">
|
||||
<view>银行卡号: </view>
|
||||
<view>{{extend.bank_code}}</view>
|
||||
</view>
|
||||
|
||||
<view class="b_item">
|
||||
<view>开户银行: </view>
|
||||
<view>{{extend.bank_username}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<view>开户网点: </view>
|
||||
<view>{{extend.bank_opening}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<view>银行卡图片:</view>
|
||||
</view>
|
||||
<image @click="priview(extend.bank_front)" :src="extend.bank_front"></image>
|
||||
<!-- <view class="b_item">
|
||||
<view>对公账号: </view>
|
||||
<view>{{extend.bank_code}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<view>开户行名称: </view>
|
||||
<view>{{extend.bank_username}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<view>开户行地址: </view>
|
||||
<view>{{extend.bank_opening}}</view>
|
||||
</view> -->
|
||||
<!-- <view class="b_item">
|
||||
<view>银行卡号:</view>
|
||||
<view>{{extend.bank_opening}}</view>
|
||||
</view>
|
||||
<view class="b_item">
|
||||
<view>银行卡正面:</view>
|
||||
</view>
|
||||
<image @click="priview(extend.bank_front)" :src="extend.bank_front"></image>
|
||||
<view class="b_item">
|
||||
<view>银行卡反面:</view>
|
||||
</view>
|
||||
<image @click="priview(extend.bank_back)" :src="extend.bank_back"></image>
|
||||
<view class="b_item">
|
||||
<view>身份证正面:</view>
|
||||
</view>
|
||||
<image @click="priview(extend.cardno_front)" :src="extend.cardno_front"></image>
|
||||
<view class="b_item">
|
||||
<view>身份证反面:</view>
|
||||
</view>
|
||||
<image @click="priview(extend.cardno_back)" :src="extend.cardno_back"></image> -->
|
||||
</view>
|
||||
|
||||
|
||||
</view>
|
||||
</view>
|
||||
<block v-if="formData.check_status!=2&&formData.check_status!=3&&formData.check_status">
|
||||
|
@ -1,393 +0,0 @@
|
||||
<template>
|
||||
<view class="">
|
||||
<view class="info">
|
||||
<view class="bg"></view>
|
||||
<view class="card">
|
||||
<view class="title">充值信息</view>
|
||||
<view class="item">
|
||||
<text>充值账户</text>
|
||||
<text>{{$store.state.app.userInfo.company.company_name||''}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="price">
|
||||
<view class="title">充值金额</view>
|
||||
<view class="tab">
|
||||
<view v-if="task_id>0" class="item active" style="margin: 0;">{{this.payMoney.money}}元</view>
|
||||
<view v-else class="item" :class="index==changeMoney?'active':''" @click="changePrice(index)"
|
||||
v-for="(item, index) in priceList" :key="index">{{item}}</view>
|
||||
</view>
|
||||
<input v-if="priceList[changeMoney]=='自定义'" class="input" type="digit" placeholder="输入充值金额(元)"
|
||||
v-model="payMoney.money" />
|
||||
<button class="btn" @click="pay">充值</button>
|
||||
<button class="btn btn2" @click="navToRecord">充值记录</button>
|
||||
|
||||
|
||||
</view>
|
||||
<!-- <view class="tip">
|
||||
<view class="title">注意事项</view>
|
||||
<view class="text">充值后帐户的金额不能提现,可用于商城消费使用佣金导入账户之后不能再次导出、不可提现账户充值出现问题可联系商城客服,也可拨打商城客服热线<text @click="copyPhone('4008888888')">4008888888</text>
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
recharge,
|
||||
payWay,
|
||||
payPrepay,
|
||||
wechatJsConfig,
|
||||
payStatus
|
||||
} from "@/api/pay.js"
|
||||
import {
|
||||
userInfo
|
||||
} from "@/api/oaUser.js"
|
||||
import {
|
||||
Toast
|
||||
} from '@/libs/uniApi.js'
|
||||
import {
|
||||
taskShareholder
|
||||
} from "@/api/task.js"
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
priceList: ['10元', '50元', '100元', '500元', '1000元', '5000元', '10000元', '自定义'],
|
||||
changeMoney: -1,
|
||||
payMoney: {
|
||||
money: ''
|
||||
},
|
||||
payTimer: null,
|
||||
timeCount: 5,
|
||||
task_id: -1, //任务id,当为任务时,不可自选充值金额
|
||||
task: {},
|
||||
obj: "323",
|
||||
}
|
||||
},
|
||||
// 点击充值记录
|
||||
onNavigationBarButtonTap(res) {
|
||||
if (res.index === 0) {
|
||||
this.navToRecord();
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
if (options.task_id) {
|
||||
this.task_id = options.task_id;
|
||||
this.loadTask();
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
||||
aa() {
|
||||
return JSON.parse(this.obj)
|
||||
|
||||
},
|
||||
|
||||
changePrice(index) {
|
||||
if (this.changeMoney == index) this.changeMoney = -1;
|
||||
else this.changeMoney = index;
|
||||
if (this.priceList[index] == '自定义') this.payMoney.money = '';
|
||||
else this.payMoney.money = this.priceList[index].split('元')[0];
|
||||
},
|
||||
// 跳转充值记录
|
||||
navToRecord() {
|
||||
uni.navigateTo({
|
||||
url: '/subpkg/topUpList/topUpList'
|
||||
})
|
||||
},
|
||||
// 加载任务
|
||||
async loadTask() {
|
||||
uni.showLoading({
|
||||
title: '加载中',
|
||||
mask: true
|
||||
})
|
||||
let res = await taskShareholder({
|
||||
id: this.task_id
|
||||
});
|
||||
this.task = res.data;
|
||||
this.payMoney.money = res.data?.extend?.shareholder?.money;
|
||||
uni.hideLoading();
|
||||
},
|
||||
//充值
|
||||
pay() {
|
||||
if (!this.payMoney.money) return Toast('请先填写充值金额!')
|
||||
if (this.payMoney.money <= 0) return Toast('充值金额不能小于0!')
|
||||
if (this.payTimer == null) {
|
||||
this.goRecharge();
|
||||
this.payTimer = setInterval(() => {
|
||||
this.timeCount--;
|
||||
if (this.timeCount <= 0) {
|
||||
clearInterval(this.payTimer);
|
||||
this.payTimer = null;
|
||||
this.timeCount = 5;
|
||||
}
|
||||
}, 1000)
|
||||
} else Toast(this.timeCount + '秒后再支付!')
|
||||
},
|
||||
goRecharge() {
|
||||
let that = this
|
||||
// console.log(obj);
|
||||
uni.showLoading({
|
||||
title: '获取支付信息',
|
||||
success: async () => {
|
||||
let queryData = {
|
||||
money: this.payMoney.money,
|
||||
type: 300
|
||||
};
|
||||
if (this.task_id > 0) {
|
||||
queryData.task_id = this.task_id;
|
||||
}
|
||||
let {
|
||||
data
|
||||
} = await recharge(queryData);
|
||||
let res = await payWay({
|
||||
order_id: data.order_id,
|
||||
from: data.from,
|
||||
})
|
||||
// console.log(res);
|
||||
let res1 = await payPrepay({
|
||||
from: data.from,
|
||||
order_id: data.order_id,
|
||||
pay_way: res.data.lists[0].pay_way
|
||||
})
|
||||
// console.log(res1.data, res1.data.config.package.split('=')[1]);
|
||||
let obj = {
|
||||
"appid": res1.data.config
|
||||
.appId, // 微信开放平台 - 应用 - AppId,注意和微信小程序、公众号 AppId 可能不一致
|
||||
"noncestr": res1.data.config.nonceStr, // 随机字符串
|
||||
"package": res1.data.config.package, // 固定值
|
||||
"partnerid": res1.data.config.partnerid, // 微信支付商户号
|
||||
"prepayid": res1.data.config.package.split('=')[1], // 统一下单订单号
|
||||
"timestamp": res1.data.config.timestamp, // 时间戳(单位:秒)
|
||||
"sign": res1.data.config.paySign
|
||||
}
|
||||
|
||||
uni.getProvider({
|
||||
service: 'payment',
|
||||
success: (paymentList) => {
|
||||
// console.log(paymentList);
|
||||
uni.hideLoading();
|
||||
uni.showLoading({
|
||||
title: '微信支付中'
|
||||
})
|
||||
uni.requestPayment({
|
||||
provider: 'wxpay',
|
||||
// orderInfo: res1.data.config,
|
||||
orderInfo: obj,
|
||||
success: (e) => {
|
||||
// console.log('成功', e);
|
||||
uni.hideLoading();
|
||||
payStatus({
|
||||
order_id: data.order_id,
|
||||
from: data.from,
|
||||
}).then((status) => {
|
||||
uni.showToast({
|
||||
icon: status.data
|
||||
.pay_status ?
|
||||
'success' : 'none',
|
||||
title: status.data
|
||||
.pay_status ?
|
||||
'支付成功' : '支付失败'
|
||||
})
|
||||
if (this.task_id > 0) {
|
||||
uni.$emit('upBuyShare');
|
||||
uni.navigateBack();
|
||||
} else {
|
||||
userInfo().then(user => {
|
||||
this.$store.commit(
|
||||
'setUserInfo',
|
||||
user.data);
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
fail: (e) => {
|
||||
console.log(e);
|
||||
uni.hideLoading();
|
||||
uni.showToast({
|
||||
icon: 'error',
|
||||
title: '支付失败!'
|
||||
})
|
||||
},
|
||||
complete: () => {
|
||||
if (this.task_id <= 0) this.payMoney.money =
|
||||
'';
|
||||
},
|
||||
});
|
||||
}
|
||||
})
|
||||
},
|
||||
fail: (e) => {
|
||||
uni.showToast({
|
||||
icon: 'error',
|
||||
title: '请先安装微信'
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
onPullDownRefresh() {
|
||||
uni.stopPullDownRefresh()
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
page {
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
.info {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
position: relative;
|
||||
height: 250rpx;
|
||||
|
||||
.bg {
|
||||
background-color: $theme-oa-color;
|
||||
height: 170rpx;
|
||||
width: 100vw;
|
||||
border-radius: 0rpx 0rpx 28rpx 28rpx;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
|
||||
.card {
|
||||
width: 694rpx;
|
||||
min-height: 180rpx;
|
||||
background: #FFFFFF;
|
||||
margin-top: 38.55rpx;
|
||||
box-shadow: 0rpx 0rpx 18rpx 2rpx rgba(50, 116, 249, 0.1);
|
||||
border-radius: 14rpx 14rpx 14rpx 14rpx;
|
||||
opacity: 1;
|
||||
padding: 31.5rpx 28rpx;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-around;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
|
||||
.title {
|
||||
font-size: 32rpx;
|
||||
font-weight: 600;
|
||||
color: #333333;
|
||||
padding-bottom: 10rpx;
|
||||
}
|
||||
|
||||
.item {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 32rpx;
|
||||
font-weight: 400;
|
||||
color: #333333;
|
||||
|
||||
text:nth-child(1) {
|
||||
flex-shrink: 0;
|
||||
margin-right: 18rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.price {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 0 28rpx;
|
||||
margin-top: 50rpx;
|
||||
|
||||
.title {
|
||||
font-size: 32rpx;
|
||||
font-weight: 600;
|
||||
color: #333333;
|
||||
line-height: 39rpx;
|
||||
margin-bottom: 42rpx;
|
||||
}
|
||||
|
||||
.tab {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: left;
|
||||
width: 694rpx;
|
||||
|
||||
.item {
|
||||
width: 217rpx;
|
||||
height: 131rpx;
|
||||
margin: 0 auto;
|
||||
margin-bottom: 20rpx;
|
||||
border-radius: 7rpx 7rpx 7rpx 7rpx;
|
||||
border: 2rpx solid #F5F5F5;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
line-height: 32rpx;
|
||||
}
|
||||
|
||||
.active {
|
||||
border: 2rpx solid $theme-oa-color;
|
||||
color: $theme-oa-color;
|
||||
}
|
||||
}
|
||||
|
||||
.input {
|
||||
width: 100%;
|
||||
height: 112rpx;
|
||||
background: #F5F5F5;
|
||||
border-radius: 56rpx 56rpx 56rpx 56rpx;
|
||||
opacity: 1;
|
||||
padding: 0 45.56rpx;
|
||||
box-sizing: border-box;
|
||||
font-size: 28rpx;
|
||||
font-weight: 400;
|
||||
color: #333;
|
||||
line-height: 35rpx;
|
||||
}
|
||||
|
||||
.btn {
|
||||
width: 694rpx;
|
||||
height: 84rpx;
|
||||
margin-top: 73.6rpx;
|
||||
background: $theme-oa-color;
|
||||
box-shadow: 0rpx 14rpx 44rpx 2rpx #E9EFF5;
|
||||
border-radius: 42rpx 42rpx 42rpx 42rpx;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
font-size: 32rpx;
|
||||
font-weight: 400;
|
||||
color: #FFFFFF;
|
||||
}
|
||||
|
||||
.btn2 {
|
||||
background-color: #fff;
|
||||
color: #333;
|
||||
border: 1px solid #eee;
|
||||
}
|
||||
}
|
||||
|
||||
.tip {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 0 28rpx;
|
||||
margin-top: 84rpx;
|
||||
|
||||
.title {
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
color: $theme-oa-color;
|
||||
line-height: 32rpx;
|
||||
margin-bottom: 21rpx;
|
||||
}
|
||||
|
||||
.text {
|
||||
font-size: 28rpx;
|
||||
font-weight: 400;
|
||||
color: rgba(0, 0, 0, 0.6);
|
||||
line-height: 42rpx;
|
||||
-webkit-background-clip: text;
|
||||
}
|
||||
}
|
||||
</style>
|
@ -194,9 +194,7 @@
|
||||
padding: 8rpx;
|
||||
border: 5rpx solid #0122c7;
|
||||
border-radius: 10rpx;
|
||||
// background-color: rgba(#0122c7, 0.1);
|
||||
// background-color: rgba(#0122c7, 0.1);
|
||||
max-width: 80vw;
|
||||
background-color: rgba(#0122c7, 0.1);
|
||||
margin-right: 10rpx;
|
||||
margin-top: 10rpx;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user