源文件
59
jeepay-ui-uapp-cashier/App.vue
Normal file
@@ -0,0 +1,59 @@
|
||||
<script>
|
||||
import appConfig from '@/config/appConfig.js';
|
||||
import { setToken, setPageType, setLiteToken, getExtStoreId } from '@/util/jeepayTokenUtil.js';
|
||||
|
||||
export default {
|
||||
onLaunch: function (options) {
|
||||
// #ifdef MP-WEIXIN
|
||||
getExtStoreId();
|
||||
// #endif
|
||||
setPageType();
|
||||
|
||||
if(appConfig.currentPageType == 'alipayLite'){
|
||||
uni.setStorageSync('alipayLiteRoute', JSON.stringify(options.query)) // 改变存储
|
||||
}
|
||||
},
|
||||
onLoad: function (options) {
|
||||
|
||||
if(appConfig.currentPageType == 'alipayLite'){
|
||||
uni.setStorageSync('alipayLiteRoute', JSON.stringify(options.query)) // 改变存储
|
||||
}
|
||||
},
|
||||
onShow: function (options) {
|
||||
// uni.showToast({title:"刷新:" +JSON.stringify(options.query),icon:'none',duration:3000})
|
||||
if(appConfig.currentPageType == 'alipayLite'){
|
||||
uni.setStorageSync('alipayLiteRoute', JSON.stringify(options.query)) // 改变存储
|
||||
}
|
||||
|
||||
// #ifdef MP-WEIXIN
|
||||
getExtStoreId();
|
||||
// #endif
|
||||
// 每次小程序打开前台页面,都需要此设置才能渲染顶部颜色
|
||||
setPageType();
|
||||
|
||||
if (appConfig.currentPageType == appConfig.PAGE_TYPE_ENUM.WECHAT_LITE) {
|
||||
appConfig.scene = options.scene;
|
||||
}
|
||||
|
||||
// onLaunch == > 迁移到 onShow ( 在onLaunch 存在: 第一次 app调起支付宝小程序没有问题, 第二次提示状态不正确(token为旧的) )
|
||||
if (appConfig.currentPageType == appConfig.PAGE_TYPE_ENUM.ALIPAY_LITE) {
|
||||
let query = options.query || {};
|
||||
if (options.referrerInfo && options.referrerInfo.extraData) {
|
||||
query = Object.assign(query, options.referrerInfo.extraData);
|
||||
}
|
||||
|
||||
if (query.qrCode) {
|
||||
setLiteToken(query.qrCode);
|
||||
}
|
||||
}
|
||||
},
|
||||
onHide: function () {
|
||||
console.log('App Hide');
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
/*每个页面公共css */
|
||||
@import './static/css/public.css';
|
||||
</style>
|
||||
1
jeepay-ui-uapp-cashier/alipayjsapi.js
Normal file
123
jeepay-ui-uapp-cashier/components/JTableList/JTableList.vue
Normal file
@@ -0,0 +1,123 @@
|
||||
<template>
|
||||
<scroll-view
|
||||
class="table-list"
|
||||
scroll-y
|
||||
:style="{ '--height': height }"
|
||||
@scrolltolower="addNext"
|
||||
@refresherrefresh="openRefresh"
|
||||
:refresher-enabled="refresh"
|
||||
:refresher-triggered="vdata.isRefresh"
|
||||
>
|
||||
<template v-for="(record, i) in vdata.allData" :key="i">
|
||||
<slot name="tableBody" :record="record" :index="i" />
|
||||
</template>
|
||||
<view class="list-null" v-if="!vdata.apiResData.hasNext && showListNull">暂无更多数据</view>
|
||||
</scroll-view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref, reactive, onMounted } from 'vue'
|
||||
import { onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
|
||||
|
||||
// 定义传入属性
|
||||
const props = defineProps({
|
||||
reqTableDataFunc: { type: Function, default: () => {} },
|
||||
searchData: { type: Object, default: () => {} }, // 搜索条件参数
|
||||
pageSize: { type: Number, default: 10 }, // 默认每页条数
|
||||
initData: { type: Boolean, default: true }, // 初始化列表数据, 默认true
|
||||
showListNull: { type: Boolean, default: true }, //是否显示缺省 默认显示
|
||||
height: { type: String, default: '88rpx' }, // 高度 这里的高度 为 外部使用高度 scroll-view 高度 为 100vh - 传入高度
|
||||
refresh: { type: Boolean, default: false }, //是否开启下拉刷新 默认不开启
|
||||
})
|
||||
|
||||
const vdata = reactive({
|
||||
allData: [], // app与web不同, app是每次查询到数据会拼接到后面
|
||||
|
||||
// 接口返回的数据
|
||||
apiResData: { total: 0, records: [] },
|
||||
|
||||
// 分页参数
|
||||
iPage: { pageNumber: 1, pageSize: props.pageSize },
|
||||
|
||||
// 下拉刷新开启状态
|
||||
isRefresh: false,
|
||||
})
|
||||
|
||||
onMounted(() => {
|
||||
//初始化表数据
|
||||
props.initData ? refTable(true) : undefined
|
||||
})
|
||||
|
||||
// 查询表格数据
|
||||
function refTable(isToFirst = false) {
|
||||
if (isToFirst) {
|
||||
// 重新搜索, 第一页。
|
||||
vdata.iPage.pageNumber = 1
|
||||
vdata.allData = [] //清空数据
|
||||
}
|
||||
|
||||
// 更新检索数据
|
||||
return props.reqTableDataFunc(Object.assign({}, vdata.iPage, props.searchData)).then(({ bizData }) => {
|
||||
Object.assign(vdata.apiResData, bizData) // 列表数据更新
|
||||
|
||||
if (bizData.records) {
|
||||
bizData.records.forEach((r) => vdata.allData.push(r))
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
/** 追加下一页数据 **/
|
||||
function addNext() {
|
||||
// console.log('加载下一页')
|
||||
// 包含下一页
|
||||
if (vdata.apiResData.hasNext) {
|
||||
vdata.iPage.pageNumber++
|
||||
refTable(false)
|
||||
}
|
||||
}
|
||||
|
||||
// 下拉刷新
|
||||
const openRefresh = () => {
|
||||
vdata.isRefresh = true
|
||||
refTable(true).then(() => {
|
||||
setTimeout(() => {
|
||||
vdata.isRefresh = false
|
||||
}, 300)
|
||||
})
|
||||
}
|
||||
|
||||
// 将表格事件暴露出去 https://www.jianshu.com/p/39d14c25c987
|
||||
defineExpose({ refTable, addNext })
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.table-list {
|
||||
// height: calc(75vh - var(--height));
|
||||
}
|
||||
.list-null {
|
||||
position: relative;
|
||||
|
||||
line-height: 110rpx;
|
||||
text-align: center;
|
||||
font-size: 26rpx;
|
||||
color: #a6a6a6;
|
||||
&::after,
|
||||
&::before {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
|
||||
width: 30%;
|
||||
height: 2rpx;
|
||||
background-color: #ededed;
|
||||
transform: translateY(-50%);
|
||||
}
|
||||
&::after {
|
||||
left: 40rpx;
|
||||
}
|
||||
&::before {
|
||||
right: 40rpx;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,359 @@
|
||||
<!--
|
||||
组件作用: 弹层, 列表支持 单选, 多选。
|
||||
|
||||
使用方法:
|
||||
|
||||
<JeepayPopupListSelect ref="jeepayPopupListSelect" :reqTableDataFunc="reqTableDataFunc" :fields="{ key: 'articleId', left: 'articleId', right: 'title'}"/>
|
||||
jeepayPopupListSelect.value.open().then((selected) => {
|
||||
console.log(selected);
|
||||
jeepayPopupListSelect.value.close() //自行关闭
|
||||
})
|
||||
|
||||
@author terrfly
|
||||
@site https://www.jeequan.com
|
||||
@date 2022/11/26 16:24
|
||||
-->
|
||||
<template>
|
||||
<uni-popup ref="popupRef" type="bottom" @maskClick="close" @change="change" mask-background-color="rgba(0,0,0,.5)" :safe-area="false">
|
||||
<view class="card-wrapper">
|
||||
<view class="selected-title" v-if="title">
|
||||
{{ title }}
|
||||
</view>
|
||||
<view v-if="props.searchInputName" class="input-search">
|
||||
<uni-easyinput
|
||||
v-model="vdata.searchData[props.searchInputName]"
|
||||
prefixIcon="search"
|
||||
:inputBorder="false"
|
||||
:clearable="false"
|
||||
:styles="{
|
||||
backgroundColor: 'transparent',
|
||||
}"
|
||||
type="text"
|
||||
placeholder="搜索"
|
||||
placeholderStyle=" color: rgba(0,0,0,0.85);font-size: 30rpx;"
|
||||
/>
|
||||
<view class="search-button" @tap="searchFunc">搜索</view>
|
||||
</view>
|
||||
|
||||
<!-- 数据渲染 -->
|
||||
<JTableList ref="jeepayTableListRef" :reqTableDataFunc="reqTableDataFuncWrapper" :searchData="vdata.searchData" :initData="false" height='406rpx'>
|
||||
<template #tableBody="{ record }">
|
||||
<view class="store" @tap="selectFunc(record)">
|
||||
<template v-if="isCheckbox">
|
||||
<view class="more-selected" :class="{ 'more-disabled': record.hasDirector, 'more-active': hasSelected(record) }">
|
||||
<image :src="record.hasDirector ? '/static/iconImg/icon-disable.svg' : '/static/iconImg/icon-check.svg'" mode="scaleToFill" />
|
||||
</view>
|
||||
</template>
|
||||
<view v-else :class="{ 'store-dot-def': true, 'active-dot': hasSelected(record) }"></view>
|
||||
<slot name="content" :record="record">
|
||||
<view class="store-inner-slot">
|
||||
<view class="left">
|
||||
<text>{{ record[props.fields.left] }}</text>
|
||||
</view>
|
||||
<view class="right">{{ record[props.fields.right] }}</view>
|
||||
</view>
|
||||
</slot>
|
||||
</view>
|
||||
</template>
|
||||
</JTableList>
|
||||
|
||||
<!-- <button v-if="vdata.hasNext" @tap="jeepayTableListRef.addNext()">下一页</button> -->
|
||||
|
||||
<view class="footer-wrapper">
|
||||
<view class="footer-main">
|
||||
<view class="footer-button">
|
||||
<view class="flex-center" hover-class="touch-button" @tap="close">取消</view>
|
||||
<view @tap="confirmFunc" class="confirm flex-center" hover-class="touch-button">确认</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</uni-popup>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { inject, nextTick, reactive, ref, render, watch } from 'vue'
|
||||
|
||||
const jeepayTableListRef = ref()
|
||||
|
||||
// 定义组件参数
|
||||
const props = defineProps({
|
||||
configMode: { type: String, default: ''}, // 搜索时仅展示商户号
|
||||
// 请求业务数据, 参数可自行控制。
|
||||
reqTableDataFunc: { type: Function, default: () => {} },
|
||||
|
||||
// 搜索输入框的name , 不传入则不显示搜索。
|
||||
searchInputName: { type: String },
|
||||
|
||||
// 约定的字段 , 若不合适请通过插槽自行插入。
|
||||
fields: { type: Object, default: { key: 'id', left: 'left', right: 'right' } },
|
||||
|
||||
// 是否多选框, 默认单选。
|
||||
isCheckbox: { type: Boolean, default: false },
|
||||
// 标题有则显示无则隐藏
|
||||
title: [String, Number],
|
||||
})
|
||||
let changePageMetaOverflowFunc = inject('changePageMetaOverflowFunc')
|
||||
const emits = defineEmits(['confirm'])
|
||||
|
||||
const popupRef = ref()
|
||||
|
||||
console.log(props,'propsprops')
|
||||
const vdata = reactive({
|
||||
searchData: {}, //当前页的搜索条件
|
||||
|
||||
hasNext: false, // 是否包含下一页数据
|
||||
|
||||
selectedList: [], // 选择的值
|
||||
|
||||
promiseObject: {},
|
||||
})
|
||||
|
||||
// 点击搜索
|
||||
function searchFunc() {
|
||||
jeepayTableListRef.value.refTable(true)
|
||||
}
|
||||
|
||||
/** reqTableDataFunc 处理函数 */
|
||||
function reqTableDataFuncWrapper(params) {
|
||||
return props.reqTableDataFunc(params).then(({ bizData }) => {
|
||||
vdata.hasNext = bizData.hasNext // 是否包含下一页
|
||||
return Promise.resolve({ bizData })
|
||||
})
|
||||
}
|
||||
|
||||
// 是否选中
|
||||
function hasSelected(record) {
|
||||
return vdata.selectedList.filter((r) => r[props.fields.key] == record[props.fields.key]).length > 0
|
||||
}
|
||||
|
||||
/** 选择函数 **/
|
||||
function selectFunc(record) {
|
||||
// 判断是否已存在
|
||||
if (hasSelected(record)) {
|
||||
// 多选需删除
|
||||
if (props.isCheckbox) {
|
||||
vdata.selectedList.splice(
|
||||
vdata.selectedList.findIndex((r) => r[props.fields.key] == record[props.fields.key]),
|
||||
1
|
||||
)
|
||||
}
|
||||
|
||||
// 单选无需操作
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// 多选直接添加
|
||||
if (props.isCheckbox) {
|
||||
if (record.hasDirector) return //如果被其他店长绑定 禁止选中
|
||||
return vdata.selectedList.push(record)
|
||||
} else {
|
||||
// 单选
|
||||
|
||||
return (vdata.selectedList = [record])
|
||||
}
|
||||
}
|
||||
|
||||
// 点击确定事件
|
||||
function confirmFunc() {
|
||||
// 多选
|
||||
if (props.isCheckbox) {
|
||||
emits('confirm', vdata.selectedList)
|
||||
return vdata.promiseObject.resolve(vdata.selectedList)
|
||||
}
|
||||
|
||||
// 单选 仅返回第一个即可。
|
||||
emits('confirm', vdata.selectedList.length > 0 ? vdata.selectedList[0] : null)
|
||||
vdata.promiseObject.resolve(vdata.selectedList.length > 0 ? vdata.selectedList[0] : null)
|
||||
}
|
||||
|
||||
// 显示弹层, 并且返回一个promise
|
||||
// promise.then(selected)
|
||||
// 注意: 此Promise 只会回调一次, 如需要验证是否选中正确, 需要使用@confirm事件。
|
||||
// 如果对拿到的值不做校验,获取到然后关闭。 那么可以直接使用.then() 然后立马关闭弹层。
|
||||
function open(defaultVal) {
|
||||
console.log(111111111111111)
|
||||
// 清空数据
|
||||
vdata.selectedList = []
|
||||
vdata.searchData[props.searchInputName] = ''
|
||||
|
||||
// 默认选中。
|
||||
if (defaultVal) {
|
||||
if (Array.isArray(defaultVal)) {
|
||||
vdata.selectedList = defaultVal
|
||||
} else {
|
||||
vdata.selectedList = [defaultVal]
|
||||
}
|
||||
}
|
||||
|
||||
popupRef.value.open()
|
||||
|
||||
nextTick(() => {
|
||||
jeepayTableListRef.value.refTable(true)
|
||||
uni.hideTabBar() // 可能报错, 在nextTick中, 不影响其他业务。
|
||||
})
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
vdata.promiseObject.resolve = resolve
|
||||
vdata.promiseObject.reject = reject
|
||||
})
|
||||
}
|
||||
|
||||
// 关闭弹层
|
||||
function close() {
|
||||
popupRef.value.close()
|
||||
uni.showTabBar()
|
||||
}
|
||||
const change = (e) => {
|
||||
if (changePageMetaOverflowFunc) {
|
||||
changePageMetaOverflowFunc(!e.show)
|
||||
}
|
||||
}
|
||||
// 将表格事件暴露出去 https://www.jianshu.com/p/39d14c25c987
|
||||
defineExpose({ open, close })
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.card-wrapper {
|
||||
border-radius: 32rpx 32rpx 0 0;
|
||||
background-color: #fff;
|
||||
overflow: hidden;
|
||||
min-height: 70vh;
|
||||
max-height: 80vh;
|
||||
overflow-y: auto;
|
||||
.selected-title {
|
||||
height: 110rpx;
|
||||
line-height: 110rpx;
|
||||
text-align: center;
|
||||
font-size: 30rpx;
|
||||
font-weight: 500;
|
||||
border-bottom: 1rpx solid #ededed;
|
||||
}
|
||||
.input-search {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding-left: 10rpx;
|
||||
margin: 30rpx;
|
||||
border-radius: 10rpx;
|
||||
background-color: #f7f7f7;
|
||||
.search-button {
|
||||
padding: 24rpx 30rpx;
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
color: #2980fd;
|
||||
}
|
||||
}
|
||||
.store {
|
||||
position: relative;
|
||||
display: flex;
|
||||
justify-content: flex-start;
|
||||
align-items: center;
|
||||
padding: 0 40rpx;
|
||||
height: 120rpx;
|
||||
font-size: 30rpx;
|
||||
.more-selected {
|
||||
width: 36rpx;
|
||||
height: 36rpx;
|
||||
border-radius: 6rpx;
|
||||
margin-right: 20rpx;
|
||||
border: 2rpx solid rgba(217, 217, 217, 1);
|
||||
image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
.more-disabled {
|
||||
background-color: #f7f7f7;
|
||||
}
|
||||
.more-active {
|
||||
background-color: #2980fd;
|
||||
}
|
||||
.store-dot-def {
|
||||
position: relative;
|
||||
margin-right: 20rpx;
|
||||
width: 36rpx;
|
||||
height: 36rpx;
|
||||
background-color: #d7d8d9;
|
||||
border-radius: 50%;
|
||||
&::after {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
width: 50%;
|
||||
height: 50%;
|
||||
border-radius: 50%;
|
||||
background-color: #fff;
|
||||
}
|
||||
}
|
||||
.active-dot {
|
||||
background-color: #2980fd;
|
||||
}
|
||||
|
||||
.store-inner-slot {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
width: 100%;
|
||||
|
||||
.left {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.right {
|
||||
color: #999999;
|
||||
}
|
||||
}
|
||||
}
|
||||
.all-store::after {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 40rpx;
|
||||
right: 40rpx;
|
||||
height: 1rpx;
|
||||
background-color: #ededed;
|
||||
}
|
||||
.footer-wrapper {
|
||||
height: 186rpx;
|
||||
.footer-main {
|
||||
position: fixed;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
border-top: 1rpx solid #ededed;
|
||||
.tips {
|
||||
margin: 20rpx;
|
||||
text-align: center;
|
||||
font-size: 27rpx;
|
||||
color: #a6a6a6;
|
||||
}
|
||||
.footer-button {
|
||||
padding: 0 30rpx;
|
||||
margin-top: 30rpx;
|
||||
padding-bottom: 30rpx;
|
||||
display: flex;
|
||||
|
||||
justify-content: space-between;
|
||||
view {
|
||||
width: 330rpx;
|
||||
height: 110rpx;
|
||||
font-size: 33rpx;
|
||||
font-weight: 500;
|
||||
color: rgba(0, 0, 0, 0.5);
|
||||
border-radius: 20rpx;
|
||||
background-color: #f7f7f7;
|
||||
}
|
||||
.confirm {
|
||||
color: #fff;
|
||||
background: $jeepay-bg-primary;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,393 @@
|
||||
<!--
|
||||
组件作用: 弹层, 列表支持 单选, 多选。
|
||||
|
||||
使用方法:
|
||||
|
||||
<JeepayPopupListSelect ref="jeepayPopupListSelect" :reqTableDataFunc="reqTableDataFunc" :fields="{ key: 'articleId', left: 'articleId', right: 'title'}"/>
|
||||
jeepayPopupListSelect.value.open().then((selected) => {
|
||||
console.log(selected);
|
||||
jeepayPopupListSelect.value.close() //自行关闭
|
||||
})
|
||||
|
||||
@author terrfly
|
||||
@site https://www.jeequan.com
|
||||
@date 2022/11/26 16:24
|
||||
-->
|
||||
<template>
|
||||
<uni-popup ref="popupRef" type="bottom" @maskClick="close" @change="change" mask-background-color="rgba(0,0,0,.5)" :safe-area="false">
|
||||
<view class="card-wrapper">
|
||||
<view class="selected-title" v-if="title">
|
||||
{{ title }}
|
||||
</view>
|
||||
<view v-if="props.searchInputName" class="input-search">
|
||||
<uni-easyinput
|
||||
v-model="vdata.searchData[props.searchInputName]"
|
||||
prefixIcon="search"
|
||||
:inputBorder="false"
|
||||
:clearable="false"
|
||||
:styles="{
|
||||
backgroundColor: 'transparent',
|
||||
}"
|
||||
type="text"
|
||||
placeholder="搜索"
|
||||
placeholderStyle=" color: rgba(0,0,0,0.85);font-size: 30rpx;"
|
||||
/>
|
||||
<view class="search-button" @tap="searchFunc">搜索</view>
|
||||
</view>
|
||||
|
||||
<!-- 数据渲染 -->
|
||||
<JTableList ref="jeepayTableListRef" :reqTableDataFunc="reqTableDataFuncWrapper" :searchData="vdata.searchData" :initData="false" >
|
||||
|
||||
|
||||
<template #tableBody="{ record }">
|
||||
<view class="store" @tap="selectFunc(record)" >
|
||||
<slot name="content" :record="record">
|
||||
<view class="store-inner-slot">
|
||||
<view class="left">
|
||||
<image mode="scaleToFill" class="left-img" :src="record[props.fields.img]" />
|
||||
|
||||
<text class="left-text">{{ record[props.fields.left] }} <text v-if="record[props.fields.right] == 2" class="left-price">(可用{{ record[props.fields.price] }}元)</text></text>
|
||||
</view>
|
||||
<!-- <view class="right">{{ record[props.fields.right] }}</view> -->
|
||||
</view>
|
||||
</slot>
|
||||
<view class="more-selected" >
|
||||
<image :src="hasSelected(record) ? '/static/payIcon/success.svg' : '/static/payIcon/unselected.svg'" mode="scaleToFill" />
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
</JTableList>
|
||||
|
||||
<!-- <button v-if="vdata.hasNext" @tap="jeepayTableListRef.addNext()">下一页</button> -->
|
||||
|
||||
<view class="footer-wrapper">
|
||||
<view class="footer-main">
|
||||
<view class="footer-button">
|
||||
<!-- <view class="flex-center" hover-class="touch-button" @tap="close">取消</view> -->
|
||||
<view @tap="confirmFunc" class="confirm flex-center" hover-class="touch-button">确认</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</uni-popup>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { inject, nextTick, reactive, ref, render, watch } from 'vue'
|
||||
|
||||
const jeepayTableListRef = ref()
|
||||
|
||||
// 定义组件参数
|
||||
const props = defineProps({
|
||||
configMode: { type: String, default: ''}, // 搜索时仅展示商户号
|
||||
// 请求业务数据, 参数可自行控制。
|
||||
reqTableDataFunc: { type: Function, default: () => {} },
|
||||
|
||||
// 搜索输入框的name , 不传入则不显示搜索。
|
||||
searchInputName: { type: String },
|
||||
|
||||
// 约定的字段 , 若不合适请通过插槽自行插入。
|
||||
fields: { type: Object, default: { key: 'id', left: 'left', right: 'right' } },
|
||||
|
||||
// 是否多选框, 默认单选。
|
||||
isCheckbox: { type: Boolean, default: false },
|
||||
// 标题有则显示无则隐藏
|
||||
title: [String, Number],
|
||||
})
|
||||
let changePageMetaOverflowFunc = inject('changePageMetaOverflowFunc')
|
||||
const emits = defineEmits(['confirm'])
|
||||
|
||||
const popupRef = ref()
|
||||
|
||||
console.log(props,'propsprops')
|
||||
const vdata = reactive({
|
||||
searchData: {}, //当前页的搜索条件
|
||||
|
||||
hasNext: false, // 是否包含下一页数据
|
||||
|
||||
selectedList: [], // 选择的值
|
||||
|
||||
promiseObject: {},
|
||||
})
|
||||
|
||||
// 点击搜索
|
||||
function searchFunc() {
|
||||
jeepayTableListRef.value.refTable(true)
|
||||
}
|
||||
|
||||
/** reqTableDataFunc 处理函数 */
|
||||
function reqTableDataFuncWrapper(params) {
|
||||
return props.reqTableDataFunc(params).then(({ bizData }) => {
|
||||
vdata.hasNext = bizData.hasNext // 是否包含下一页
|
||||
return Promise.resolve({ bizData })
|
||||
})
|
||||
}
|
||||
|
||||
// 是否选中
|
||||
function hasSelected(record) {
|
||||
return vdata.selectedList.filter((r) => r[props.fields.key] == record[props.fields.key]).length > 0
|
||||
}
|
||||
|
||||
/** 选择函数 **/
|
||||
function selectFunc(record) {
|
||||
// 判断是否已存在
|
||||
if (hasSelected(record)) {
|
||||
// 多选需删除
|
||||
if (props.isCheckbox) {
|
||||
vdata.selectedList.splice(
|
||||
vdata.selectedList.findIndex((r) => r[props.fields.key] == record[props.fields.key]),
|
||||
1
|
||||
)
|
||||
}
|
||||
|
||||
// 单选无需操作
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// 多选直接添加
|
||||
if (props.isCheckbox) {
|
||||
if (record.hasDirector) return //如果被其他店长绑定 禁止选中
|
||||
return vdata.selectedList.push(record)
|
||||
} else {
|
||||
// 单选
|
||||
|
||||
return (vdata.selectedList = [record])
|
||||
}
|
||||
}
|
||||
|
||||
// 点击确定事件
|
||||
function confirmFunc() {
|
||||
// 多选
|
||||
if (props.isCheckbox) {
|
||||
emits('confirm', vdata.selectedList)
|
||||
return vdata.promiseObject.resolve(vdata.selectedList)
|
||||
}
|
||||
|
||||
// 单选 仅返回第一个即可。
|
||||
emits('confirm', vdata.selectedList.length > 0 ? vdata.selectedList[0] : null)
|
||||
vdata.promiseObject.resolve(vdata.selectedList.length > 0 ? vdata.selectedList[0] : null)
|
||||
}
|
||||
|
||||
// 显示弹层, 并且返回一个promise
|
||||
// promise.then(selected)
|
||||
// 注意: 此Promise 只会回调一次, 如需要验证是否选中正确, 需要使用@confirm事件。
|
||||
// 如果对拿到的值不做校验,获取到然后关闭。 那么可以直接使用.then() 然后立马关闭弹层。
|
||||
function open(defaultVal) {
|
||||
// 清空数据
|
||||
vdata.selectedList = []
|
||||
vdata.searchData[props.searchInputName] = ''
|
||||
|
||||
// 默认选中。
|
||||
if (defaultVal) {
|
||||
if (Array.isArray(defaultVal)) {
|
||||
vdata.selectedList = defaultVal
|
||||
} else {
|
||||
vdata.selectedList = [defaultVal]
|
||||
}
|
||||
}
|
||||
|
||||
popupRef.value.open()
|
||||
|
||||
nextTick(() => {
|
||||
jeepayTableListRef.value.refTable(true)
|
||||
uni.hideTabBar() // 可能报错, 在nextTick中, 不影响其他业务。
|
||||
})
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
vdata.promiseObject.resolve = resolve
|
||||
vdata.promiseObject.reject = reject
|
||||
})
|
||||
}
|
||||
|
||||
// 关闭弹层
|
||||
function close() {
|
||||
popupRef.value.close()
|
||||
uni.showTabBar()
|
||||
}
|
||||
const change = (e) => {
|
||||
if (changePageMetaOverflowFunc) {
|
||||
changePageMetaOverflowFunc(!e.show)
|
||||
}
|
||||
}
|
||||
// 将表格事件暴露出去 https://www.jianshu.com/p/39d14c25c987
|
||||
defineExpose({ open, close })
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.card-wrapper {
|
||||
border-radius: 20rpx 20rpx 0 0;
|
||||
background-color: #fff;
|
||||
overflow: hidden;
|
||||
min-height: 70vh;
|
||||
max-height: 80vh;
|
||||
overflow-y: auto;
|
||||
.selected-title {
|
||||
height: 110rpx;
|
||||
line-height: 110rpx;
|
||||
text-align: center;
|
||||
font-size: 30rpx;
|
||||
font-weight: 500;
|
||||
border-bottom: 1rpx solid #ededed;
|
||||
}
|
||||
.input-search {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding-left: 10rpx;
|
||||
margin: 30rpx;
|
||||
border-radius: 10rpx;
|
||||
background-color: #f7f7f7;
|
||||
.search-button {
|
||||
padding: 24rpx 30rpx;
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
color: #2980fd;
|
||||
}
|
||||
}
|
||||
.store {
|
||||
position: relative;
|
||||
margin: 30rpx 20rpx;
|
||||
border-radius: 10rpx;
|
||||
background-color: #f7f7f7;
|
||||
display: flex;
|
||||
justify-content: flex-start;
|
||||
align-items: center;
|
||||
padding: 0 40rpx;
|
||||
// height: 120rpx;
|
||||
font-size: 30rpx;
|
||||
// border-bottom: 1px solid #f4f4f4;
|
||||
.more-selected {
|
||||
width: 60rpx;
|
||||
height: 60rpx;
|
||||
// border-radius: 50%;
|
||||
// margin-right: 20rpx;
|
||||
// border: 2rpx solid rgba(217, 217, 217, 1);
|
||||
image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
.more-disabled {
|
||||
background-color: #f7f7f7;
|
||||
}
|
||||
.more-active {
|
||||
// background-color: #2980fd;
|
||||
}
|
||||
.store-dot-def {
|
||||
position: relative;
|
||||
margin-right: 20rpx;
|
||||
width: 36rpx;
|
||||
height: 36rpx;
|
||||
background-color: #d7d8d9;
|
||||
border-radius: 50%;
|
||||
&::after {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
width: 50%;
|
||||
height: 50%;
|
||||
border-radius: 50%;
|
||||
background-color: #fff;
|
||||
}
|
||||
}
|
||||
.active-dot {
|
||||
// background-color: #2980fd;
|
||||
background-image: url("/static/img/selfcashier-icon-check.svg");
|
||||
}
|
||||
|
||||
.store-inner-slot {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
width: 100%;
|
||||
padding: 34rpx 0;
|
||||
.left {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.right {
|
||||
color: #999999;
|
||||
}
|
||||
}
|
||||
}
|
||||
.all-store::after {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 40rpx;
|
||||
right: 40rpx;
|
||||
height: 1rpx;
|
||||
background-color: #ededed;
|
||||
}
|
||||
.footer-wrapper {
|
||||
height: 186rpx;
|
||||
.footer-main {
|
||||
position: fixed;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
// border-top: 1rpx solid #ededed;
|
||||
.tips {
|
||||
margin: 20rpx;
|
||||
text-align: center;
|
||||
font-size: 27rpx;
|
||||
color: #a6a6a6;
|
||||
}
|
||||
.footer-button {
|
||||
padding: 0 30rpx;
|
||||
margin-top: 30rpx;
|
||||
padding-bottom: 30rpx;
|
||||
display: flex;
|
||||
|
||||
justify-content: space-between;
|
||||
view {
|
||||
text-align: center;
|
||||
padding: 20rpx 0px;
|
||||
font-size: 50rpx;
|
||||
width: 100%;
|
||||
// height: 110rpx;
|
||||
font-size: 33rpx;
|
||||
font-weight: 500;
|
||||
color: rgba(0, 0, 0, 0.5);
|
||||
border-radius: 20rpx;
|
||||
background-color: #f7f7f7;
|
||||
}
|
||||
.confirm {
|
||||
color: #fff;
|
||||
background: #2980fd;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.left-img{
|
||||
width: 50rpx;
|
||||
height: 50rpx;
|
||||
margin-right: 12rpx;
|
||||
margin-right: 6rpx;
|
||||
}
|
||||
.left-text{
|
||||
|
||||
font-family: PingFang SC-Regular;
|
||||
font-size: 32rpx;
|
||||
font-weight: 400;
|
||||
.left-price{
|
||||
color: #8F97A9;
|
||||
font-size: 24rpx;
|
||||
};
|
||||
}
|
||||
.selected-title{
|
||||
border-bottom: none !important;
|
||||
font-weight: 600 !important;
|
||||
font-size: 32rpx !important;
|
||||
text-align: left !important;
|
||||
margin-left: 32rpx;
|
||||
}
|
||||
:deep(.table-list){
|
||||
height:none !important;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,119 @@
|
||||
<!--
|
||||
Jeepay 表格列表, 支持 下滑, 上滑刷新。
|
||||
|
||||
业务页面最好也监听下 触底函数, 否则H5无法监听到。
|
||||
import { onReachBottom } from '@dcloudio/uni-app'
|
||||
onReachBottom(() => { })
|
||||
|
||||
|
||||
@author terrfly
|
||||
@site https://www.jeequan.com
|
||||
@date 2022/11/16 15:55
|
||||
-->
|
||||
<template>
|
||||
<view>
|
||||
<template v-for="(record, i) in vdata.allData" :key="i">
|
||||
<slot name="tableBody" :record="record" :index="i" />
|
||||
</template>
|
||||
</view>
|
||||
<view class="list-null" v-if="!vdata.apiResData.hasNext && showListNull">暂无更多数据</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref, reactive, onMounted } from 'vue'
|
||||
import { onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
|
||||
|
||||
// 定义传入属性
|
||||
const props = defineProps({
|
||||
reqTableDataFunc: { type: Function, default: () => {} },
|
||||
searchData: { type: Object, default: () => {} }, // 搜索条件参数
|
||||
pageSize: { type: Number, default: 10 }, // 默认每页条数
|
||||
initData: { type: Boolean, default: true }, // 初始化列表数据, 默认true
|
||||
showListNull: { type: Boolean, default: true }, //是否显示缺省 默认显示
|
||||
})
|
||||
|
||||
const vdata = reactive({
|
||||
allData: [], // app与web不同, app是每次查询到数据会拼接到后面
|
||||
|
||||
// 接口返回的数据
|
||||
apiResData: { total: 0, records: [] },
|
||||
|
||||
// 分页参数
|
||||
iPage: { pageNumber: 1, pageSize: props.pageSize },
|
||||
})
|
||||
|
||||
onMounted(() => {
|
||||
//初始化表数据
|
||||
props.initData ? refTable(true) : undefined
|
||||
})
|
||||
|
||||
// 查询表格数据
|
||||
function refTable(isToFirst = false) {
|
||||
if (isToFirst) {
|
||||
// 重新搜索, 第一页。
|
||||
vdata.iPage.pageNumber = 1
|
||||
vdata.allData = [] //清空数据
|
||||
}
|
||||
|
||||
// 更新检索数据
|
||||
return props.reqTableDataFunc(Object.assign({}, vdata.iPage, props.searchData)).then(({ bizData }) => {
|
||||
Object.assign(vdata.apiResData, bizData) // 列表数据更新
|
||||
if (bizData.records) {
|
||||
vdata.allData.push(...bizData.records) // 利用展开语法代替forEach
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
/** 追加下一页数据 **/
|
||||
function addNext() {
|
||||
// 包含下一页
|
||||
if (vdata.apiResData.hasNext) {
|
||||
vdata.iPage.pageNumber++
|
||||
refTable(false)
|
||||
}
|
||||
}
|
||||
|
||||
// 下拉刷新
|
||||
onPullDownRefresh(() => {
|
||||
refTable(true).then(() => {
|
||||
uni.stopPullDownRefresh()
|
||||
})
|
||||
})
|
||||
|
||||
// 监听,触底事件。 查询下一页
|
||||
onReachBottom(() => {
|
||||
addNext()
|
||||
})
|
||||
|
||||
// 将表格事件暴露出去 https://www.jianshu.com/p/39d14c25c987
|
||||
defineExpose({ refTable, addNext })
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.list-null {
|
||||
position: relative;
|
||||
|
||||
line-height: 110rpx;
|
||||
text-align: center;
|
||||
font-size: 26rpx;
|
||||
color: #a6a6a6;
|
||||
&::after,
|
||||
&::before {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
|
||||
width: 30%;
|
||||
height: 2rpx;
|
||||
background-color: #ededed;
|
||||
transform: translateY(-50%);
|
||||
}
|
||||
&::after {
|
||||
left: 40rpx;
|
||||
}
|
||||
&::before {
|
||||
right: 40rpx;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
151
jeepay-ui-uapp-cashier/components/jq-keyboard/jq-keyboard.vue
Normal file
@@ -0,0 +1,151 @@
|
||||
<template>
|
||||
<view class="jq-keyboard">
|
||||
<view class="left">
|
||||
<view v-for="(item,index) in vdata.number" :key="index" @tap="change(item)"
|
||||
class="common" hover-class="hover-but" hover-start-time="10" hover-stay-time="60">
|
||||
{{ item }}
|
||||
</view>
|
||||
<view @tap="change('.')" class="common" hover-class="hover-but" hover-start-time="10" hover-stay-time="60">.</view>
|
||||
<view @tap="change('0')" class="common zero" hover-class="hover-but" hover-start-time="10" hover-stay-time="60">0</view>
|
||||
</view>
|
||||
<view class="right">
|
||||
<view class="common del" hover-class="hover-but" hover-start-time="10" hover-stay-time="60" @tap="del">
|
||||
<image src="/static/img/del.svg"></image>
|
||||
</view>
|
||||
<view class="common del" hover-class="hover-but" hover-start-time="10" hover-stay-time="60" @tap="clear">C</view>
|
||||
<view
|
||||
class="common pay"
|
||||
hover-class="hover-but"
|
||||
hover-start-time="10" hover-stay-time="60"
|
||||
:style="{'backgroundColor': props.primaryColor}"
|
||||
@tap="pay">
|
||||
付款
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { reactive, onMounted } from 'vue'
|
||||
|
||||
const props = defineProps({
|
||||
primaryColor: {
|
||||
type: String,
|
||||
default: '#FFFFFF'
|
||||
}
|
||||
})
|
||||
const vdata = reactive({
|
||||
number: ['1', '2', '3', '4', '5', '6', '7', '8', '9'],
|
||||
value: '0'
|
||||
})
|
||||
const emit = defineEmits(['change', 'pay'])
|
||||
|
||||
function change(k) {
|
||||
|
||||
let currentVal = vdata.value
|
||||
if(currentVal === '0' && k != '.') {
|
||||
currentVal = k
|
||||
}else {
|
||||
currentVal += k;
|
||||
}
|
||||
|
||||
if(!matchNum(currentVal)) {
|
||||
return
|
||||
}
|
||||
vdata.value = currentVal
|
||||
|
||||
uni.vibrateShort()
|
||||
emit('change', vdata.value)
|
||||
}
|
||||
function del() {
|
||||
|
||||
let currentVal = vdata.value
|
||||
if(!currentVal || currentVal.length <= 1) {
|
||||
vdata.value = '0'
|
||||
}else {
|
||||
vdata.value = vdata.value.substring(0, currentVal.length - 1)
|
||||
}
|
||||
|
||||
uni.vibrateShort()
|
||||
emit('change', vdata.value)
|
||||
}
|
||||
function clear() {
|
||||
|
||||
vdata.value = '0'
|
||||
|
||||
uni.vibrateShort()
|
||||
emit('change', vdata.value)
|
||||
}
|
||||
function matchNum(currentVal) {
|
||||
const pattern = /^(([1-9]{1}\d{0,5})|(0{1}))(\.\d{0,2})?$/
|
||||
return pattern.test(currentVal)
|
||||
}
|
||||
function pay() {
|
||||
|
||||
uni.vibrateShort()
|
||||
emit('pay')
|
||||
}
|
||||
function setValue(value) {
|
||||
vdata.value = value
|
||||
}
|
||||
|
||||
defineExpose({ setValue })
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.jq-keyboard {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
padding: 0 5rpx;
|
||||
box-sizing: border-box;
|
||||
|
||||
.left {
|
||||
width: 75%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-around;
|
||||
}
|
||||
.right {
|
||||
width: 25%;
|
||||
margin-left: 5rpx;
|
||||
margin-right: 5rpx;
|
||||
}
|
||||
}
|
||||
.common {
|
||||
width: calc(100%/3 - 10rpx);
|
||||
height: 150rpx;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
box-sizing: border-box;
|
||||
margin-bottom: 10rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 10rpx;
|
||||
font-size: 55rpx;
|
||||
letter-spacing: 0.04em;
|
||||
color: $uni-text-color;
|
||||
}
|
||||
.zero {
|
||||
width: calc(100%/3*2 - 10rpx);
|
||||
}
|
||||
.del {
|
||||
width: 100%;
|
||||
image {
|
||||
width: 51rpx;
|
||||
height: 37rpx;
|
||||
pointer-events: none;
|
||||
}
|
||||
}
|
||||
.pay {
|
||||
width: 100%;
|
||||
height: 310rpx;
|
||||
font-size: 36rpx;
|
||||
color: $uni-text-color-inverse;
|
||||
}
|
||||
.hover-but {
|
||||
filter: brightness(80%);
|
||||
}
|
||||
</style>
|
||||
153
jeepay-ui-uapp-cashier/components/syb-keyboard/syb-keyboard.vue
Normal file
@@ -0,0 +1,153 @@
|
||||
<template>
|
||||
<view class="jq-keyboard">
|
||||
<view class="left">
|
||||
<view v-for="(item,index) in vdata.number" :key="index" @tap="change(item)"
|
||||
class="common" hover-class="hover-but" hover-start-time="10" hover-stay-time="60">
|
||||
{{ item }}
|
||||
</view>
|
||||
<view @tap="change('.')" class="common" hover-class="hover-but" hover-start-time="10" hover-stay-time="60">.</view>
|
||||
<view @tap="change('0')" class="common zero" hover-class="hover-but" hover-start-time="10" hover-stay-time="60">0</view>
|
||||
</view>
|
||||
<view class="right">
|
||||
<view class="common del" hover-class="hover-but" hover-start-time="10" hover-stay-time="60" @tap="del">
|
||||
<image src="/static/img/del.svg"></image>
|
||||
</view>
|
||||
<view class="common del" style="display: none;" hover-class="hover-but" hover-start-time="10" hover-stay-time="60" @tap="clear">C</view>
|
||||
<view
|
||||
class="common pay"
|
||||
hover-class="hover-but"
|
||||
hover-start-time="10" hover-stay-time="60"
|
||||
:style="{'backgroundColor': '#387CE7'}"
|
||||
@tap="pay">
|
||||
<div>付</div>
|
||||
<div>款</div>
|
||||
</view>
|
||||
<!-- :style="{'backgroundColor': props.primaryColor}" -->
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { reactive, onMounted } from 'vue'
|
||||
|
||||
const props = defineProps({
|
||||
primaryColor: {
|
||||
type: String,
|
||||
default: '#FFFFFF'
|
||||
}
|
||||
})
|
||||
const vdata = reactive({
|
||||
number: ['1', '2', '3', '4', '5', '6', '7', '8', '9'],
|
||||
value: '0'
|
||||
})
|
||||
const emit = defineEmits(['change', 'pay'])
|
||||
|
||||
function change(k) {
|
||||
|
||||
let currentVal = vdata.value
|
||||
if(currentVal === '0' && k != '.') {
|
||||
currentVal = k
|
||||
}else {
|
||||
currentVal += k;
|
||||
}
|
||||
|
||||
if(!matchNum(currentVal)) {
|
||||
return
|
||||
}
|
||||
vdata.value = currentVal
|
||||
|
||||
uni.vibrateShort()
|
||||
emit('change', vdata.value)
|
||||
}
|
||||
function del() {
|
||||
|
||||
let currentVal = vdata.value
|
||||
if(!currentVal || currentVal.length <= 1) {
|
||||
vdata.value = '0'
|
||||
}else {
|
||||
vdata.value = vdata.value.substring(0, currentVal.length - 1)
|
||||
}
|
||||
|
||||
uni.vibrateShort()
|
||||
emit('change', vdata.value)
|
||||
}
|
||||
function clear() {
|
||||
|
||||
vdata.value = '0'
|
||||
|
||||
uni.vibrateShort()
|
||||
emit('change', vdata.value)
|
||||
}
|
||||
function matchNum(currentVal) {
|
||||
const pattern = /^(([1-9]{1}\d{0,5})|(0{1}))(\.\d{0,2})?$/
|
||||
return pattern.test(currentVal)
|
||||
}
|
||||
function pay() {
|
||||
|
||||
uni.vibrateShort()
|
||||
emit('pay')
|
||||
}
|
||||
function setValue(value) {
|
||||
vdata.value = value
|
||||
}
|
||||
|
||||
defineExpose({ setValue })
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.jq-keyboard {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
padding: 0 5rpx;
|
||||
box-sizing: border-box;
|
||||
|
||||
.left {
|
||||
width: 75%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-around;
|
||||
}
|
||||
.right {
|
||||
width: 25%;
|
||||
margin-left: 5rpx;
|
||||
margin-right: 5rpx;
|
||||
}
|
||||
}
|
||||
.common {
|
||||
width: calc(100%/3 - 10rpx);
|
||||
height: 24%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
box-sizing: border-box;
|
||||
margin-bottom: 10rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 10rpx;
|
||||
font-size: 55rpx;
|
||||
letter-spacing: 0.04em;
|
||||
color: $uni-text-color;
|
||||
}
|
||||
.zero {
|
||||
width: calc(100%/3*2 - 10rpx);
|
||||
}
|
||||
.del {
|
||||
width: 100%;
|
||||
image {
|
||||
width: 51rpx;
|
||||
height: 37rpx;
|
||||
pointer-events: none;
|
||||
}
|
||||
}
|
||||
.pay {
|
||||
width: 100%;
|
||||
height: 406rpx;
|
||||
font-size: 36rpx;
|
||||
color: $uni-text-color-inverse;
|
||||
}
|
||||
.hover-but {
|
||||
filter: brightness(80%);
|
||||
}
|
||||
</style>
|
||||
48
jeepay-ui-uapp-cashier/config/appConfig.js
Normal file
@@ -0,0 +1,48 @@
|
||||
const appConfig = {
|
||||
|
||||
// 项目名称
|
||||
appName: '收银台',
|
||||
|
||||
// token取值key
|
||||
tokenKey: 'tk',
|
||||
|
||||
// token值
|
||||
tokenValue: '',
|
||||
|
||||
// channelUserId
|
||||
channelUserId: '',
|
||||
// channelUserId
|
||||
channelUniId: '',
|
||||
// 定义页面类型枚举值: 微信小程序 - wechatLite、 支付宝小程序 alipayLite、 微信H5 wechatH5, 支付宝H5 alipayH5
|
||||
PAGE_TYPE_ENUM: {
|
||||
WECHAT_LITE: 'wechatLite',
|
||||
ALIPAY_LITE: 'alipayLite',
|
||||
WECHAT_H5: 'wechatH5',
|
||||
ALIPAY_H5: 'alipayH5',
|
||||
YSFPAY_H5: 'ysfpayH5',
|
||||
OTHER_H5: 'otherH5',
|
||||
},
|
||||
|
||||
// 当前页面类型: 微信小程序 - wechatLite、 支付宝小程序 alipayLite、 微信H5 wechatH5, 支付宝H5 alipayH5
|
||||
currentPageType: '',
|
||||
|
||||
// 场景值,一般存储小程序被打开的场景值
|
||||
scene: '',
|
||||
|
||||
// 环境变量相关
|
||||
env: {},
|
||||
|
||||
// ISV小程序设置为: 0, 商户自己编译的小程序请配置为: 1
|
||||
isUseSubmchAccount: 0,
|
||||
// 会员的base url
|
||||
memberBaseUrl: '',
|
||||
// 是否开启红包
|
||||
redPacketIsOpen: false,
|
||||
redbalance:0,
|
||||
marketingConfig: {},
|
||||
video:null,
|
||||
payH5:{}
|
||||
|
||||
}
|
||||
|
||||
export default appConfig;
|
||||
50
jeepay-ui-uapp-cashier/config/theme.js
Normal file
@@ -0,0 +1,50 @@
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
|
||||
const model = {
|
||||
|
||||
changeColors: function() {
|
||||
if (appConfig.currentPageType == appConfig.PAGE_TYPE_ENUM.WECHAT_LITE
|
||||
|| appConfig.currentPageType == appConfig.PAGE_TYPE_ENUM.WECHAT_H5) {
|
||||
initWxpay()
|
||||
return '#1678FF'
|
||||
} else if (appConfig.currentPageType == appConfig.PAGE_TYPE_ENUM.ALIPAY_LITE
|
||||
|| appConfig.currentPageType == appConfig.PAGE_TYPE_ENUM.ALIPAY_H5) {
|
||||
initAlipay()
|
||||
return '#1678FF'
|
||||
} else if (appConfig.currentPageType == appConfig.PAGE_TYPE_ENUM.YSFPAY_H5) {
|
||||
initYsfpay()
|
||||
return '#1678FF'
|
||||
} else {
|
||||
initWxpay()
|
||||
return '#1678FF'
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// 初始化微信相关
|
||||
function initWxpay() {
|
||||
uni.setNavigationBarColor({
|
||||
frontColor: '#000000',
|
||||
// backgroundColor: '#07C160'
|
||||
backgroundColor: '#ffffff'
|
||||
})
|
||||
}
|
||||
|
||||
// 初始化支付宝相关
|
||||
function initAlipay() {
|
||||
uni.setNavigationBarColor({
|
||||
frontColor: '#000000',
|
||||
backgroundColor: '#ffffff'
|
||||
})
|
||||
}
|
||||
|
||||
// 初始化云闪付相关
|
||||
function initYsfpay() {
|
||||
uni.setNavigationBarColor({
|
||||
frontColor: '#000000',
|
||||
backgroundColor: '#ffffff'
|
||||
})
|
||||
}
|
||||
|
||||
export default model
|
||||
27
jeepay-ui-uapp-cashier/env/config.js
vendored
Normal file
@@ -0,0 +1,27 @@
|
||||
/**
|
||||
* ENV 的封装
|
||||
* 由于uniapp 无法设置.env等打包属性,实现线上,线下多版本配置属性的无缝切换。
|
||||
* process.env.NODE_ENV 将在打包环境通过编译器进行替换, 线上打包后无法获取到 process对象。 所以将配置属性统一封装到appConfig中。
|
||||
*
|
||||
* @author terrfly
|
||||
* @site https://www.jeequan.com
|
||||
* @date 2021/12/16 17:57
|
||||
*/
|
||||
|
||||
|
||||
import appConfig from '@/config/appConfig.js';
|
||||
import development from '@/env/env.development.js';
|
||||
import production from '@/env/env.production.js';
|
||||
|
||||
// 引入变量
|
||||
const envConfig = {development: development, production : production}
|
||||
|
||||
// 获取当前环境变量
|
||||
const currentEnv = envConfig[process.env.NODE_ENV]
|
||||
|
||||
// 设置全局env配置项目
|
||||
appConfig.env = currentEnv
|
||||
|
||||
export default this
|
||||
|
||||
|
||||
6
jeepay-ui-uapp-cashier/env/env.development.js
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
export default {
|
||||
'JEEPAY_PAY_BASE_URL': 'https://pay.rscygroup.com' //支付网关URL
|
||||
// 'JEEPAY_PAY_BASE_URL': 'http://192.168.1.45:9216' //支付网关URL
|
||||
// 'JEEPAY_PAY_BASE_URL': 'https://pay.rscygroup.com' //支付网关URL
|
||||
// 'JEEPAY_PAY_BASE_URL': 'https://pay.qilinshuzi.com' //支付网关URL
|
||||
}
|
||||
6
jeepay-ui-uapp-cashier/env/env.production.js
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
export default {
|
||||
'JEEPAY_PAY_BASE_URL': 'https://pay.rscygroup.com' //支付网关URL
|
||||
// 'JEEPAY_PAY_BASE_URL': 'http://192.168.1.8:9216' //支付网关URL
|
||||
// 'JEEPAY_PAY_BASE_URL': 'https://pay.rscygroup.com' //支付网关URL
|
||||
// 'JEEPAY_PAY_BASE_URL': 'https://pay.qilinshuzi.com' //支付网关URL
|
||||
}
|
||||
10
jeepay-ui-uapp-cashier/ext.json
Normal file
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"extEnable": true,
|
||||
"extAppid":"wx9af938d44d21e5d6",
|
||||
"directCommit": false,
|
||||
"ext": {
|
||||
"name": "wechat"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
92
jeepay-ui-uapp-cashier/http/apiManager.js
Normal file
@@ -0,0 +1,92 @@
|
||||
/**
|
||||
* api接口管理, 全部以$开头
|
||||
* @author terrfly
|
||||
* @site https://www.jeequan.com
|
||||
* @date 2021/12/17 09:57
|
||||
*/
|
||||
|
||||
|
||||
import http from '@/http/http.js'
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
|
||||
/** 获取获取用户ID的跳转URL */
|
||||
export function $getRedirectUrl (data) {
|
||||
return http.req('/api/cashier/redirectUrl', data, 'POST')
|
||||
}
|
||||
|
||||
/** 获取url **/
|
||||
export function $getChannelUserId (data) {
|
||||
return http.req('/api/cashier/channelUserId', data, 'POST')
|
||||
}
|
||||
|
||||
/** 调起支付接口, 获取支付数据包 **/
|
||||
export function $getPayPackage (amount, buyerRemark, mbrId, mbrTel,calcDiscount='') {
|
||||
|
||||
let data = { amount: amount, buyerRemark: buyerRemark, channelUserId: appConfig.channelUserId, mbrId, mbrTel,discount:calcDiscount }
|
||||
|
||||
// 是否 子商户小程序 调起
|
||||
data.isUseSubmchAccount = appConfig.isUseSubmchAccount
|
||||
return http.req('/api/cashier/pay', data, 'POST')
|
||||
}
|
||||
|
||||
/** 调起支付接口, 获取订单信息 **/
|
||||
export function $getPayOrderInfo () {
|
||||
return http.req('/api/cashier/payOrderInfo', null, 'POST')
|
||||
}
|
||||
|
||||
/** 取消支付时 语音播报提示 **/
|
||||
export function $payCancelBoardCast (payOrderId) {
|
||||
let data = { payOrderId: payOrderId }
|
||||
return http.req('/api/cashier/payCancelBoardCast', data, 'POST')
|
||||
}
|
||||
|
||||
/** 调起支付后,返回内容上报服务器 **/
|
||||
export function $payEventBoardCast (payOrderId, resData) {
|
||||
let data = { payOrderId: payOrderId, resData: resData }
|
||||
return http.req('/api/cashier/payEventBoardCast', data, 'POST')
|
||||
}
|
||||
|
||||
/** 支付成功后,获取广告 **/
|
||||
export function $getAdvert (data=null) {
|
||||
return http.req('/api/advert', data, 'GET')
|
||||
}
|
||||
// 查询是否开启会员模块 此接口 会返回 会员接口的baseURL
|
||||
export function $getIsMemberPower () {
|
||||
let data = { channelUserId: appConfig.channelUserId }
|
||||
return http.req('/api/cashier/memberConfig', data, 'GET')
|
||||
}
|
||||
|
||||
// 查询平台营销功能
|
||||
export function $getMarketingConfig (configKey,storeId='') {
|
||||
let data = { channelUserId: appConfig.channelUserId,configKey:configKey,storeId:storeId }
|
||||
return http.req('/api/cashier/config', data, 'GET')
|
||||
}
|
||||
|
||||
|
||||
// 计算营销红包实付金额
|
||||
export function $getCalcDiscount (amount,storeId = '') {
|
||||
let data = { channelUserId: appConfig.channelUserId,amount:amount,storeId:storeId }
|
||||
return http.req('/api/cashier/calcDiscount', data, 'GET')
|
||||
}
|
||||
|
||||
|
||||
// 支付成功后获取优惠详情
|
||||
export function $getDiscountDetail (payOrderId) {
|
||||
return http.req('/api/cashier/getDiscountDetail/'+payOrderId, 'GET')
|
||||
}
|
||||
|
||||
/** Api调起支付接口, 获取支付数据包 **/
|
||||
export function $getApiPay (amount, code,buyerRemark='') {
|
||||
|
||||
let data = { amount: amount,code:code,channelUserId:appConfig.channelUserId,auth_code:code, buyerRemark: buyerRemark }
|
||||
|
||||
// 是否 子商户小程序 调起
|
||||
data.isUseSubmchAccount = appConfig.isUseSubmchAccount
|
||||
return http.req('/api/cashier/pay', data, 'POST')
|
||||
}
|
||||
|
||||
|
||||
/** 交易轮训支付请求门店 **/
|
||||
export function $payApiDoRoute (amount, remark) {
|
||||
return http.req('/api/cashier/doRoute', { amount: amount, remark: remark }, 'POST')
|
||||
}
|
||||
30
jeepay-ui-uapp-cashier/http/apiMember.js
Normal file
@@ -0,0 +1,30 @@
|
||||
|
||||
import http from '@/http/http.js'
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
|
||||
|
||||
// 获取充值规则
|
||||
export function $apiMembers (data = { method: 'mch.mbr.recharge.rule' }) {
|
||||
return http.req(undefined, data, "POST", { url: appConfig.memberBaseUrl + '/api/anon/member' })
|
||||
}
|
||||
// 获取会员信息
|
||||
export function $getMemberInfo () {
|
||||
return http.req(undefined, {}, 'GET', { url: appConfig.memberBaseUrl + '/api/member' })
|
||||
}
|
||||
// 会员充值接口
|
||||
export function $recharge (data) {
|
||||
return http.req(undefined, data, 'POST', { url: appConfig.memberBaseUrl + '/api/member/recharge' })
|
||||
}
|
||||
// 会员卡支付
|
||||
export function $payRemberCard (amount, remark) {
|
||||
return http.req(undefined, { amount, remark }, "POST", { url: appConfig.memberBaseUrl + '/api/member/pay' })
|
||||
}
|
||||
// 查询会员充值记录
|
||||
export function $getMemberRechargeRecord (params) {
|
||||
return http.req(undefined, params, 'GET', { url: appConfig.memberBaseUrl + '/api/member/rechargeRecord' })
|
||||
}
|
||||
|
||||
// 查询会员消费记录
|
||||
export function $getConsumeRecod (params) {
|
||||
return http.req(undefined, params, 'GET', { url: appConfig.memberBaseUrl + '/api/member/accountHistory' })
|
||||
}
|
||||
102
jeepay-ui-uapp-cashier/http/http.js
Normal file
@@ -0,0 +1,102 @@
|
||||
/**
|
||||
* HTTP的封装, 基于uni.request
|
||||
* 包括: 通用响应结果的处理 和 业务的增删改查函数
|
||||
*
|
||||
* @author terrfly
|
||||
* @site https://www.jeequan.com
|
||||
* @date 2021/12/16 18:35
|
||||
*/
|
||||
|
||||
// 导入全局属性
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
import {toErrPageFunc} from '@/util/toErrorPageUtil.js'
|
||||
import storageManage from '@/util/storageManage.js'
|
||||
|
||||
|
||||
function req(uri, data, method = "GET", extParams = {}){
|
||||
|
||||
// 放置token
|
||||
let headerObject = {}
|
||||
headerObject[appConfig.tokenKey] = appConfig.tokenValue
|
||||
headerObject.pageType = appConfig.currentPageType
|
||||
headerObject.iToken = storageManage.iToken()
|
||||
|
||||
// 麒麟
|
||||
// let iToken = 'Q8240202142732831';
|
||||
|
||||
//收银呗
|
||||
// let iToken = 'Q8240510155041616';
|
||||
|
||||
// headerObject[appConfig.tokenKey] = iToken
|
||||
// headerObject.pageType = appConfig.currentPageType
|
||||
// headerObject.iToken = iToken
|
||||
|
||||
return uni.request(
|
||||
Object.assign({
|
||||
url: appConfig.env.JEEPAY_PAY_BASE_URL + uri,
|
||||
data: data,
|
||||
method: method,
|
||||
header: headerObject
|
||||
}, extParams)).then((httpData) => {
|
||||
|
||||
// 从http响应数据中解构响应数据 [ 响应码、 bodyData ]
|
||||
let { statusCode, data } = httpData
|
||||
|
||||
// 避免混淆重新命名
|
||||
let bodyData = data
|
||||
|
||||
// http响应码不正确
|
||||
if(statusCode != 200){
|
||||
return Promise.reject(bodyData) // 跳转到catch函数
|
||||
}
|
||||
|
||||
// 业务响应异常
|
||||
if(bodyData.code != 0){
|
||||
|
||||
toErrPageFunc(bodyData.msg)
|
||||
return Promise.reject(bodyData.msg)
|
||||
}
|
||||
|
||||
// 构造请求成功的响应数据
|
||||
return Promise.resolve({ bizData: bodyData.data, data: data })
|
||||
|
||||
}).catch( res => {
|
||||
return Promise.reject(res)
|
||||
});
|
||||
}
|
||||
|
||||
// 通用list
|
||||
function list(uri, params){
|
||||
return req(uri, params, 'GET')
|
||||
}
|
||||
|
||||
// 通用add
|
||||
function add(uri, data){
|
||||
return req(uri, data, 'POST')
|
||||
}
|
||||
|
||||
// 通用 根据ID获取
|
||||
function getById(uri, bizId){
|
||||
return req(`${uri}/${bizId}`, {}, 'GET')
|
||||
}
|
||||
|
||||
// 通用 更新
|
||||
function updateById(uri, bizId, data){
|
||||
return req(`${uri}/${bizId}`, data, 'PUT')
|
||||
}
|
||||
|
||||
// 通用 删除
|
||||
function delById(uri, bizId){
|
||||
return req(`${uri}/${bizId}`, {}, 'DELETE')
|
||||
}
|
||||
|
||||
|
||||
|
||||
export default {
|
||||
req : req,
|
||||
list: list,
|
||||
add: add,
|
||||
getById: getById,
|
||||
updateById: updateById,
|
||||
delById: delById
|
||||
}
|
||||
27
jeepay-ui-uapp-cashier/index.html
Normal file
@@ -0,0 +1,27 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0" />
|
||||
<title></title>
|
||||
<!--preload-links-->
|
||||
<!--app-context-->
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="app"><!--app-html--></div>
|
||||
<script type="module" src="/main.js"></script>
|
||||
<script>
|
||||
// 生成当前时间的时间戳
|
||||
document.write('<script src="/index.js?v='+Math.random()+'"><\/script>');
|
||||
</script>
|
||||
|
||||
<!-- <script>
|
||||
|
||||
// 支持多服务商码牌地址
|
||||
if(/^\/cashier\/(.+)\/pages\/hub\/(default|h5|lite)\/$/.test(window.location.pathname)){
|
||||
window.location.href= '/cashier/pages/hub/' + window.location.pathname.split('/pages/hub/').slice(-1)[0] + window.location.search
|
||||
}
|
||||
</script> -->
|
||||
</body>
|
||||
</html>
|
||||
22
jeepay-ui-uapp-cashier/index.js
Normal file
@@ -0,0 +1,22 @@
|
||||
console.log(window.location,'windowlocationwindowlocation')
|
||||
console.log(window.location.pathname.split('/pages/hub/'),'46541651651651615')
|
||||
let pathname = window.location.pathname.split('/pages/hub/').slice(-1)[0]
|
||||
let pathnameList = pathname.split("/")
|
||||
let pathnameString = window.location.pathname
|
||||
console.log(pathnameList[1],'pathnameString')
|
||||
if (pathnameList.length >= 2) {
|
||||
let parameterToRemove = pathnameList[1]
|
||||
pathnameString = pathnameString.replace(parameterToRemove, "");
|
||||
}
|
||||
console.log(pathnameString,'pathnameStringpathnameString')
|
||||
|
||||
// 支持多服务商码牌地址
|
||||
if(/^\/cashier\/(.+)\/pages\/hub\/(default|h5|lite)\/$\//.test(window.location.pathname)){
|
||||
console.log(pathnameList,'windowlocationwindowlocation')
|
||||
window.location.href= '/cashier/pages/hub/' + pathnameList[0] + window.location.search
|
||||
}
|
||||
|
||||
if(/\/pages\/hub\/(default|h5|lite)\/$/.test(pathnameString)){
|
||||
console.log(pathnameList,'windowlocationwindowlocation')
|
||||
window.location.href= '/cashier/pages/hub/' + pathnameList[0] + window.location.search
|
||||
}
|
||||
20
jeepay-ui-uapp-cashier/main.js
Normal file
@@ -0,0 +1,20 @@
|
||||
// 引入主文件
|
||||
import App from './App'
|
||||
|
||||
// 设置env配置文件
|
||||
import '@/env/config.js'
|
||||
|
||||
// 全局配置项
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
|
||||
// 引入vue3的创建函数
|
||||
import { createApp } from 'vue'
|
||||
|
||||
// 创建全局app
|
||||
const app = createApp(App)
|
||||
|
||||
// 设置全局配置参数
|
||||
app.config.globalProperties.appConfig = appConfig
|
||||
|
||||
// 挂载事件
|
||||
app.mount('#app')
|
||||
118
jeepay-ui-uapp-cashier/manifest.json
Normal file
@@ -0,0 +1,118 @@
|
||||
{
|
||||
"name" : "聚合收银台",
|
||||
"appid" : "__UNI__71D61A3",
|
||||
"description" : "聚合收银台",
|
||||
"versionName" : "1.0.0",
|
||||
"versionCode" : "100",
|
||||
"transformPx" : false,
|
||||
/* 5+App特有相关 */
|
||||
"app-plus" : {
|
||||
"usingComponents" : true,
|
||||
"nvueStyleCompiler" : "uni-app",
|
||||
"compilerVersion" : 3,
|
||||
"splashscreen" : {
|
||||
"alwaysShowBeforeRender" : true,
|
||||
"waiting" : true,
|
||||
"autoclose" : true,
|
||||
"delay" : 0
|
||||
},
|
||||
/* 模块配置 */
|
||||
"modules" : {},
|
||||
/* 应用发布信息 */
|
||||
"distribute" : {
|
||||
/* android打包配置 */
|
||||
"android" : {
|
||||
"permissions" : [
|
||||
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
|
||||
"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CAMERA\"/>",
|
||||
"<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
|
||||
"<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
|
||||
"<uses-feature android:name=\"android.hardware.camera\"/>",
|
||||
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
|
||||
]
|
||||
},
|
||||
/* ios打包配置 */
|
||||
"ios" : {},
|
||||
/* SDK配置 */
|
||||
"sdkConfigs" : {},
|
||||
"icons" : {
|
||||
"android" : {
|
||||
"hdpi" : "unpackage/res/icons/72x72.png",
|
||||
"xhdpi" : "unpackage/res/icons/96x96.png",
|
||||
"xxhdpi" : "unpackage/res/icons/144x144.png",
|
||||
"xxxhdpi" : "unpackage/res/icons/192x192.png"
|
||||
},
|
||||
"ios" : {
|
||||
"appstore" : "unpackage/res/icons/1024x1024.png",
|
||||
"ipad" : {
|
||||
"app" : "unpackage/res/icons/76x76.png",
|
||||
"app@2x" : "unpackage/res/icons/152x152.png",
|
||||
"notification" : "unpackage/res/icons/20x20.png",
|
||||
"notification@2x" : "unpackage/res/icons/40x40.png",
|
||||
"proapp@2x" : "unpackage/res/icons/167x167.png",
|
||||
"settings" : "unpackage/res/icons/29x29.png",
|
||||
"settings@2x" : "unpackage/res/icons/58x58.png",
|
||||
"spotlight" : "unpackage/res/icons/40x40.png",
|
||||
"spotlight@2x" : "unpackage/res/icons/80x80.png"
|
||||
},
|
||||
"iphone" : {
|
||||
"app@2x" : "unpackage/res/icons/120x120.png",
|
||||
"app@3x" : "unpackage/res/icons/180x180.png",
|
||||
"notification@2x" : "unpackage/res/icons/40x40.png",
|
||||
"notification@3x" : "unpackage/res/icons/60x60.png",
|
||||
"settings@2x" : "unpackage/res/icons/58x58.png",
|
||||
"settings@3x" : "unpackage/res/icons/87x87.png",
|
||||
"spotlight@2x" : "unpackage/res/icons/80x80.png",
|
||||
"spotlight@3x" : "unpackage/res/icons/120x120.png"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
/* 快应用特有相关 */
|
||||
"quickapp" : {},
|
||||
/* 小程序特有相关 */
|
||||
"mp-weixin" : {
|
||||
"appid" : "wx9af938d44d21e5d6",
|
||||
"setting" : {
|
||||
"urlCheck" : true,
|
||||
"postcss" : true,
|
||||
"es6" : true,
|
||||
"minified" : true
|
||||
},
|
||||
"usingComponents" : true
|
||||
},
|
||||
"mp-alipay" : {
|
||||
"usingComponents" : true,
|
||||
"appid" : "2021004128648214"
|
||||
},
|
||||
"mp-baidu" : {
|
||||
"usingComponents" : true
|
||||
},
|
||||
"mp-toutiao" : {
|
||||
"usingComponents" : true,
|
||||
"appid" : "2021004130689363"
|
||||
},
|
||||
"uniStatistics" : {
|
||||
"enable" : false
|
||||
},
|
||||
"vueVersion" : "3",
|
||||
"h5" : {
|
||||
"router" : {
|
||||
"mode" : "history",
|
||||
"base" : "/cashier"
|
||||
},
|
||||
"sdkConfigs" : {
|
||||
"maps" : {}
|
||||
}
|
||||
}
|
||||
}
|
||||
29
jeepay-ui-uapp-cashier/package-lock.json
generated
Normal file
@@ -0,0 +1,29 @@
|
||||
{
|
||||
"name": "jeepay-ui-uapp-cashier",
|
||||
"version": "1.0.0",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "jeepay-ui-uapp-cashier",
|
||||
"version": "1.0.0",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"js-base64": "^3.7.5"
|
||||
}
|
||||
},
|
||||
"node_modules/js-base64": {
|
||||
"version": "3.7.5",
|
||||
"resolved": "https://registry.npmmirror.com/js-base64/-/js-base64-3.7.5.tgz",
|
||||
"integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==",
|
||||
"license": "BSD-3-Clause"
|
||||
}
|
||||
},
|
||||
"dependencies": {
|
||||
"js-base64": {
|
||||
"version": "3.7.5",
|
||||
"resolved": "https://registry.npmmirror.com/js-base64/-/js-base64-3.7.5.tgz",
|
||||
"integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA=="
|
||||
}
|
||||
}
|
||||
}
|
||||
15
jeepay-ui-uapp-cashier/package.json
Normal file
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"name": "jeepay-ui-uapp-cashier",
|
||||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"main": "main.js",
|
||||
"scripts": {
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"keywords": [],
|
||||
"author": "",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"js-base64": "^3.7.5"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,194 @@
|
||||
<template>
|
||||
<uni-popup ref="popup" type="bottom" :safe-area="false">
|
||||
<view class="sms-wrapper" :style="{ '--v-primary': calcThemeColor() }">
|
||||
<view class="s-title">绑定手机号</view>
|
||||
<view class="phone-input">
|
||||
<image src="/static/vipImg/phone.svg"></image>
|
||||
<input type="number" maxlength="11" style="background: transparent;" v-model="vdata.phoneNumber"
|
||||
placeholder="请输入手机号">
|
||||
</view>
|
||||
<view class="code-wrapper">
|
||||
<view class="code-input">
|
||||
<image src="/static/vipImg/secure-icon.svg"></image>
|
||||
<input type="number" maxlength="6" style="background: transparent;" v-model="vdata.code"
|
||||
placeholder="请输入验证码">
|
||||
</view>
|
||||
<view class="send-sms" hover-class="hover-but" hover-stay-time="200" @tap="sendSMS"
|
||||
v-if="vdata.timeNumber <= 0">
|
||||
发送短信
|
||||
</view>
|
||||
<view class="send-sms" style="color: #ff624fff;font-size: 26rpx;" v-else>{{ vdata.timeNumber }}S后可重新发送
|
||||
</view>
|
||||
</view>
|
||||
<view class="confirm-but" hover-class="hover-but" hover-stay-time="200" @tap="confirm">确认绑定</view>
|
||||
</view>
|
||||
</uni-popup>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref, reactive } from "vue"
|
||||
import { $apiMembers } from "@/http/apiMember"
|
||||
// import { Base64 } from 'js-base64'
|
||||
import storageManage from '@/util/storageManage.js'
|
||||
import appConfig from "@/config/appConfig"
|
||||
import { calcThemeColor } from "@/util/member.js"
|
||||
const emits = defineEmits('success')
|
||||
const vdata = reactive({
|
||||
timeNumber: 0
|
||||
})
|
||||
const popup = ref(null)
|
||||
const open = () => popup.value.open()
|
||||
const close = () => popup.value.close()
|
||||
const sendSMS = () => {
|
||||
uni.showLoading({
|
||||
title: '请稍等',
|
||||
mask: true
|
||||
})
|
||||
validate().then(res => {
|
||||
$apiMembers({
|
||||
method: 'mbr.tel.send.sms.code',
|
||||
mbrTel: Base64.encode(vdata.phoneNumber)
|
||||
}).then(res => {
|
||||
tips('验证码发送成功')
|
||||
countDown()
|
||||
uni.hideLoading()
|
||||
})
|
||||
})
|
||||
}
|
||||
const confirm = () => {
|
||||
validate(true).then(res => {
|
||||
$apiMembers({
|
||||
method: 'mbr.tel.bind',
|
||||
mbrTel: Base64.encode(vdata.phoneNumber),
|
||||
code: Base64.encode(vdata.code),
|
||||
channelUesrId: Base64.encode(appConfig.channelUserId)
|
||||
}).then(({
|
||||
bizData
|
||||
}) => {
|
||||
storageManage.iToken(bizData)
|
||||
emits('success', bizData)
|
||||
uni.$emit('updateMemberInfos')
|
||||
tips('绑定成功')
|
||||
close()
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
function validate (code) {
|
||||
return new Promise((res, rej) => {
|
||||
if (!vdata.phoneNumber) return rej(tips('请输入手机号'))
|
||||
if (vdata.phoneNumber.length < 11) return rej(tips('手机号格式不正确'))
|
||||
if (code) {
|
||||
if (!vdata.code) return rej(tips('请输入验证码'))
|
||||
if (vdata.code.length < 6) return rej(tips('验证码格式不正确'))
|
||||
}
|
||||
res()
|
||||
})
|
||||
}
|
||||
|
||||
function tips (text) {
|
||||
uni.showToast({ title: text, icon: 'none', mask: true })
|
||||
}
|
||||
|
||||
function countDown () {
|
||||
vdata.timeNumber = 60
|
||||
let inter = setInterval(() => {
|
||||
vdata.timeNumber--
|
||||
if (vdata.timeNumber <= 0) {
|
||||
clearInterval(inter)
|
||||
}
|
||||
}, 1000)
|
||||
}
|
||||
|
||||
defineExpose({
|
||||
open,
|
||||
close
|
||||
})
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.sms-wrapper {
|
||||
margin-top: 100rpx;
|
||||
width: 100vw;
|
||||
height: 900rpx;
|
||||
min-height: 500rpx;
|
||||
background-color: #fff;
|
||||
border-radius: 50rpx 50rpx 0 0;
|
||||
border: .1rpx solid #fff;
|
||||
box-sizing: border-box;
|
||||
padding: 50rpx;
|
||||
|
||||
.s-title {
|
||||
color: #4d4d4dff;
|
||||
font-size: 30rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.code-input,
|
||||
.phone-input {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding: 0 30rpx;
|
||||
margin-top: 40rpx;
|
||||
height: 110rpx;
|
||||
border-radius: 20rpx;
|
||||
background: #f7f7f7ff;
|
||||
|
||||
image {
|
||||
width: 36rpx;
|
||||
height: 36rpx;
|
||||
}
|
||||
|
||||
input {
|
||||
margin-left: 10rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.phone-input {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
input {
|
||||
margin-left: 20rpx;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.code-input {
|
||||
justify-content: space-between;
|
||||
margin-top: 30rpx;
|
||||
|
||||
input {
|
||||
margin-left: 10rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.confirm-but {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin: 200rpx 0 50rpx;
|
||||
height: 110rpx;
|
||||
background: linear-gradient(270deg, #ff6756ff 0%, #f99364ff 100%);
|
||||
color: #fff;
|
||||
border-radius: 20rpx;
|
||||
}
|
||||
|
||||
.code-wrapper {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.send-sms {
|
||||
margin-left: 20rpx;
|
||||
transform: translateY(20rpx);
|
||||
color: var(--v-primary);
|
||||
font-size: 32rpx;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.hover-but {
|
||||
opacity: .5;
|
||||
}
|
||||
</style>
|
||||
609
jeepay-ui-uapp-cashier/pageMember/memberInfo/memberInfo.vue
Normal file
@@ -0,0 +1,609 @@
|
||||
<template>
|
||||
<view class="page-wrapper">
|
||||
<view class="re-header" :style="{ '--v-primary': calcThemeColor() }">
|
||||
<view class="re-h-main" :class="{ 'no-member-mian': !vdata.isMemebr }">
|
||||
<image src="/static/vipImg/member-bg.svg" mode="aspectFill" class="img-bg" />
|
||||
<view class="user-info">
|
||||
<view class="user-photo">
|
||||
<image class="vip-header" src="/static/vipImg/header-top.svg" v-if="vdata.mbrName"
|
||||
mode="scaleToFill" />
|
||||
<image class="no-vip" :src="vdata.avatarUrl ? vdata.avatarUrl : '/static/vipImg/no-vip.svg'"
|
||||
mode="scaleToFill" />
|
||||
</view>
|
||||
<view class="user-wrapper" :class="{ 'user-wrapper-no-momber': !vdata.isMemebr }">
|
||||
<view class="user-name" v-if="vdata.isMemebr">{{ vdata.mbrName || '会员名称' }}</view>
|
||||
<view class="user-phone" v-if="vdata.isMemebr">{{ vdata.mbrTel }}</view>
|
||||
<view v-if="!vdata.isMemebr">未注册</view>
|
||||
<view class="reg-phone" v-if="!vdata.isMemebr" hover-class="hover-but" hover-stay-time="200"
|
||||
@tap="refBindPhone.open()">
|
||||
手机号注册
|
||||
<image src="/static/vipImg/arrow-white.svg" mode="scaleToFill" />
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="bin-info" v-if="vdata.isMemebr">
|
||||
<view class="bind-stat">{{ parseFloat((vdata.balance / 100).toFixed(2)) }}</view>
|
||||
<view class="bind-info">我的余额(元)</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 充值消费记录 -->
|
||||
<view class="re-con" @tap="toRecord">
|
||||
<view class="left">
|
||||
<image src="/static/img/note-icon.svg" style="width: 40rpx; height: 40rpx;"></image>
|
||||
<text>查看充值/消费记录</text>
|
||||
</view>
|
||||
<view class="right">
|
||||
<image src="/static/vipImg/arrow-black.svg" style="width: 40rpx; height: 40rpx;"></image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="sub-title">充值优惠(元)</view>
|
||||
<view class="re-rule-wrapper">
|
||||
|
||||
<block v-for=" v in amountRules " :key="v.ruleId">
|
||||
<view class="re-r-item" :class="{ 'pay-amount-selected': vdata.selectedId == v.ruleId }"
|
||||
@tap="calcAmount(v.ruleId)">
|
||||
<image src="/static/vipImg/selected-re-icon.svg" mode="aspectFill"
|
||||
v-if="vdata.selectedId == v.ruleId" />
|
||||
<view class="ite-top">
|
||||
<text class="pay-icon">¥</text>{{ parseFloat((v.rechargeAmount / 100).toFixed(2)) }}
|
||||
</view>
|
||||
<view class="ite-bot">
|
||||
<text class="icon-give flex-center">赠</text>
|
||||
<text class="pay-amount">¥{{ parseFloat((v.giveAmount / 100).toFixed(2)) }}</text>
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
|
||||
<view class="re-r-item re-r-custom" :class="{ 'pay-amount-selected': vdata.selectedId == 'custom' }"
|
||||
v-if="vdata.memberCustomAmountState == 1" @tap="calcAmount('custom')">
|
||||
<image src="/static/vipImg/selected-re-icon.svg" mode="aspectFill" v-if="vdata.selectedId == 'custom'" />
|
||||
<view class="ite-top ite-top-custom-title">
|
||||
自定义
|
||||
</view>
|
||||
<view class="ite-bot ite-bot-input">
|
||||
<input type="digit" placeholder="请输入自定充值义金额" v-model="vdata.rechargeAmount"
|
||||
placeholder-style="color:#00000059" style="background: transparent;"
|
||||
@input="() => vdata.entryAmount = vdata.rechargeAmount">
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view class="re-confirm-but" v-if="vdata.isMemebr">
|
||||
<view class="real-amount">实际到账:<text>¥{{ vdata.entryAmount }}</text></view>
|
||||
<view class="confirm" hover-class="hover-but" hover-stay-time="200" @tap="confirm">确认充值</view>
|
||||
</view>
|
||||
<view class="line"></view>
|
||||
<view class="sub-title">适用门店</view>
|
||||
<view class="store-wrapper">
|
||||
<block v-for="(v, i) in storeList " :key="i">
|
||||
<view class="store-item">{{ v.storeName }}</view>
|
||||
</block>
|
||||
</view>
|
||||
</view>
|
||||
<BindPhone ref="refBindPhone" @success="getMemberInfo" />
|
||||
</template>
|
||||
<script setup>
|
||||
import { onLoad, onPullDownRefresh, onUnload } from '@dcloudio/uni-app'
|
||||
import { ref, reactive } from "vue"
|
||||
import { $apiMembers, $getMemberInfo, $recharge } from "@/http/apiMember"
|
||||
import BindPhone from "./components/BindPhone.vue"
|
||||
import paywayCallFunc from '@/pages/payway/payway.js'
|
||||
import appConfig from "@/config/appConfig"
|
||||
import { calcThemeColor } from "@/util/member.js"
|
||||
import storageManage from '@/util/storageManage.js'
|
||||
// import { Base64 } from 'js-base64'
|
||||
|
||||
onLoad(() => {
|
||||
uni.setNavigationBarColor({
|
||||
frontColor: '#ffffff',
|
||||
backgroundColor: '#212327'
|
||||
})
|
||||
|
||||
// 查询是否注册会员
|
||||
$apiMembers({ method: 'mbr.info', channelUesrId: Base64.encode(appConfig.channelUserId) }).then(({ bizData }) => {
|
||||
if (bizData) {
|
||||
storageManage.iToken(bizData)
|
||||
getMemberInfo() //存储token 查询会员信息
|
||||
vdata.isMemebr = true
|
||||
} else {
|
||||
vdata.isMemebr = false
|
||||
}
|
||||
})
|
||||
getRules()
|
||||
})
|
||||
|
||||
const vdata = reactive({
|
||||
rechargeAmount: '',
|
||||
entryAmount: ''
|
||||
})
|
||||
const amountRules = reactive([])
|
||||
const storeList = reactive([])
|
||||
const refBindPhone = ref(null)
|
||||
const refInput = ref(null)
|
||||
const openPopup = () => {
|
||||
refBindPhone.value.open()
|
||||
}
|
||||
|
||||
// 获取会员信息
|
||||
const getMemberInfo = () => {
|
||||
$getMemberInfo().then(({ bizData }) => {
|
||||
Object.assign(vdata, bizData)
|
||||
vdata.isMemebr = true
|
||||
getRules()
|
||||
}).catch(er => {
|
||||
uni.stopPullDownRefresh()
|
||||
})
|
||||
}
|
||||
// 查询会员充值规则
|
||||
const getRules = () => {
|
||||
$apiMembers().then(({ bizData }) => {
|
||||
getStore()
|
||||
vdata.memberCustomAmountState = bizData.memberCustomAmountState
|
||||
Object.assign(amountRules, bizData.records)
|
||||
if (bizData.length > 0) calcAmount(bizData[0].ruleId)
|
||||
|
||||
}).catch(er => {
|
||||
uni.stopPullDownRefresh()
|
||||
})
|
||||
}
|
||||
const calcAmount = (id) => {
|
||||
if (id == 'custom') {
|
||||
vdata.selectedId = id
|
||||
vdata.rechargeAmount = ''
|
||||
vdata.entryAmount = ''
|
||||
return
|
||||
}
|
||||
|
||||
vdata.selectedId = id
|
||||
const data = amountRules.find(v => v.ruleId == id)
|
||||
vdata.entryAmount = ((data.giveAmount + data.rechargeAmount) / 100).toFixed(2)
|
||||
vdata.rechargeAmount = ''
|
||||
}
|
||||
// 手机号注册弹窗
|
||||
const bindPhoneOpen = () => {
|
||||
refBindPhone.value.open()
|
||||
}
|
||||
const REG_AMOUNT = /^([0-9]{1}|^[1-9]{1}\d{1,15})(\.\d{1,2})?$/
|
||||
|
||||
// 确认充值
|
||||
const confirm = () => {
|
||||
// 请求参数
|
||||
let reqParams = {}
|
||||
|
||||
// 判断 是自定义 还 会员规则 充值
|
||||
if (vdata.selectedId == 'custom') {
|
||||
if (vdata.rechargeAmount <= 0) {
|
||||
return uni.showToast({ title: '充值金额应大于0', icon: 'none' })
|
||||
}
|
||||
|
||||
reqParams.rechargeAmount = vdata.rechargeAmount
|
||||
if (!REG_AMOUNT.test(reqParams.rechargeAmount)) {
|
||||
return uni.showToast({ title: '充值金额错误 请输入正确金额', icon: 'none' })
|
||||
}
|
||||
} else {
|
||||
reqParams.rechargeRuleId = vdata.selectedId
|
||||
if (!reqParams.rechargeRuleId) {
|
||||
return uni.showToast({ title: '请选择充值金额', icon: 'none' })
|
||||
}
|
||||
}
|
||||
|
||||
$recharge(reqParams).then(({ bizData }) => {
|
||||
if (bizData.orderState != 1) { //订单不是支付中,说明订单异常
|
||||
return toErrPageFunc(bizData.errMsg);
|
||||
}
|
||||
if (bizData.payUrl) {
|
||||
location.href = bizData.payUrl;
|
||||
return false;
|
||||
}
|
||||
if (['alipayH5', 'alipayLite'].includes(appConfig.currentPageType)) {
|
||||
bizData = JSON.parse(bizData.payData)
|
||||
} else {
|
||||
bizData.payInfo = bizData.payData
|
||||
}
|
||||
|
||||
// 以下为调起 jsapi的函数: 分为: H5 和 各端小程序
|
||||
let thisPaywayCallFunc = paywayCallFunc()[appConfig.currentPageType];
|
||||
thisPaywayCallFunc(bizData, { amount: bizData.payAmount, fun: paySuccess })
|
||||
})
|
||||
}
|
||||
|
||||
// 支付成功回调函数
|
||||
function paySuccess () {
|
||||
uni.$emit('updateMemberInfos')
|
||||
uni.navigateBack()
|
||||
}
|
||||
|
||||
// 获取适用的门店
|
||||
const getStore = () => {
|
||||
$apiMembers({
|
||||
method: 'mch.mbr.recharge.rule.store'
|
||||
}).then(({
|
||||
bizData
|
||||
}) => {
|
||||
Object.assign(storeList, bizData)
|
||||
uni.stopPullDownRefresh()
|
||||
}).catch(er => {
|
||||
uni.stopPullDownRefresh()
|
||||
})
|
||||
}
|
||||
const toRecord = () => {
|
||||
uni.navigateTo({
|
||||
url: '/pageMember/memberRecord/memberRecord'
|
||||
})
|
||||
}
|
||||
onPullDownRefresh(() => {
|
||||
getMemberInfo()
|
||||
})
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.flex-center {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.page-wrapper {
|
||||
min-height: 100vh;
|
||||
background-color: #fff;
|
||||
|
||||
.sub-title {
|
||||
margin: 50rpx;
|
||||
margin-bottom: 0;
|
||||
color: #4d4d4dff;
|
||||
font-size: 30rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
}
|
||||
|
||||
.re-header {
|
||||
padding: .1rpx;
|
||||
padding-bottom: 0;
|
||||
padding-top: 50rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: #212327;
|
||||
|
||||
.re-h-main {
|
||||
padding: .1rpx;
|
||||
position: relative;
|
||||
z-index: 10;
|
||||
margin: 0 50rpx;
|
||||
border-radius: 32rpx 32rpx 0 0;
|
||||
overflow: hidden;
|
||||
background: linear-gradient(90deg, #fff7ccff 0%, #ffbe4dff 100%);
|
||||
|
||||
.img-bg {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.user-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin: 30rpx;
|
||||
padding-bottom: 30rpx;
|
||||
border-bottom: 1rpx solid #0000000f;
|
||||
|
||||
.user-name {
|
||||
color: #694e2cff;
|
||||
font-size: 30rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.user-phone {
|
||||
margin-top: 6rpx;
|
||||
color: #997a3dff;
|
||||
font-size: 25rpx;
|
||||
}
|
||||
|
||||
.user-photo {
|
||||
position: relative;
|
||||
margin-right: 30rpx;
|
||||
width: 80rpx;
|
||||
height: 80rpx;
|
||||
border-radius: 50%;
|
||||
background-color: #ccc;
|
||||
|
||||
image {
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.vip-header {
|
||||
position: absolute;
|
||||
top: -50rpx;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
width: 80rpx;
|
||||
height: 80rpx;
|
||||
}
|
||||
|
||||
.no-vip {
|
||||
width: 80rpx;
|
||||
height: 80rpx;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
.bin-info {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
.bind-stat {
|
||||
text-align: center;
|
||||
color: #212327ff;
|
||||
font-size: 60rpx;
|
||||
font-weight: 500;
|
||||
|
||||
}
|
||||
|
||||
.bind-info {
|
||||
margin-top: 10rpx;
|
||||
margin-bottom: 30rpx;
|
||||
color: #997a3dff;
|
||||
font-size: 23rpx
|
||||
}
|
||||
|
||||
.to-recharge {
|
||||
font-size: 26rpx;
|
||||
border: 2rpx solid #999;
|
||||
padding: 8rpx 20rpx;
|
||||
color: #313133;
|
||||
border-radius: 10rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.bind-phone {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
font-size: 28rpx;
|
||||
margin: 0 30rpx;
|
||||
margin-top: 100rpx;
|
||||
padding: 30rpx 0;
|
||||
border-bottom: 1rpx solid #ccc;
|
||||
|
||||
image {
|
||||
margin-right: 10rpx;
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
}
|
||||
|
||||
.bind-left {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.bind-right {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 160rpx;
|
||||
height: 60rpx;
|
||||
border: 5rpx solid var(--v-primary);
|
||||
color: var(--v-primary);
|
||||
font-weight: 600;
|
||||
border-radius: 10rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.re-rule-wrapper {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
padding: 10rpx;
|
||||
|
||||
.re-r-item {
|
||||
margin: 15rpx;
|
||||
padding: 20rpx;
|
||||
min-width: 216rpx;
|
||||
height: 163rpx;
|
||||
box-sizing: border-box;
|
||||
background: linear-gradient(270deg, rgb(255, 94, 77, 0.1) 0%, rgb(255, 153, 102, 0.1) 100%);
|
||||
border-radius: 26rpx;
|
||||
|
||||
.ite-top {
|
||||
margin-bottom: 10rpx;
|
||||
color: #ff624fff;
|
||||
font-size: 40rpx;
|
||||
font-weight: 500;
|
||||
|
||||
.pay-icon {
|
||||
color: #ff624fff;
|
||||
font-size: 25rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
}
|
||||
|
||||
.ite-bot {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
min-width: 176rpx;
|
||||
height: 60rpx;
|
||||
color: #fff;
|
||||
border-radius: 12rpx;
|
||||
font-size: 24rpx;
|
||||
background: linear-gradient(270deg, rgb(255, 103, 86) 0%, rgb(249, 147, 100) 100%);
|
||||
|
||||
.icon-give {
|
||||
flex-shrink: 0;
|
||||
margin-right: 10rpx;
|
||||
width: 60rpx;
|
||||
height: 60rpx;
|
||||
border-radius: 12rpx;
|
||||
background: #ffffff26;
|
||||
}
|
||||
|
||||
.pay-amount {
|
||||
margin-right: 15rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.re-r-custom {
|
||||
width: 453rpx;
|
||||
|
||||
.ite-top-custom-title {
|
||||
margin-bottom: 20rpx;
|
||||
font-size: 25rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.ite-bot-input {
|
||||
padding-top: 15rpx;
|
||||
width: 100%;
|
||||
border-top: 1rpx solid rgba(0, 0, 0, 0.06);
|
||||
background: transparent;
|
||||
color: #FF624F;
|
||||
font-size: 24rpx;
|
||||
font-weight: 400;
|
||||
|
||||
input {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
.re-confirm-but {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
color: #fff;
|
||||
margin: 30rpx;
|
||||
height: 110rpx;
|
||||
background: #212327ff;
|
||||
border-radius: 20rpx;
|
||||
|
||||
|
||||
.real-amount {
|
||||
margin-left: 30rpx;
|
||||
color: #ffffffff;
|
||||
font-size: 25rpx;
|
||||
|
||||
text {
|
||||
color: #FFC766;
|
||||
}
|
||||
}
|
||||
|
||||
.confirm {
|
||||
width: 260rpx;
|
||||
height: 100%;
|
||||
background: linear-gradient(270deg, #ff6756ff 0%, #f99364ff 100%);
|
||||
border-radius: 20rpx;
|
||||
text-align: center;
|
||||
line-height: 110rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.line {
|
||||
margin: 50rpx 30rpx;
|
||||
height: 1rpx;
|
||||
background: #f2f2f2ff;
|
||||
}
|
||||
|
||||
.store-wrapper {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
padding: 10rpx;
|
||||
|
||||
.store-item {
|
||||
margin: 20rpx;
|
||||
padding: 10rpx 30rpx;
|
||||
background: #f7f7f7ff;
|
||||
border-radius: 12rpx;
|
||||
color: #212327ff;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.reg-phone {
|
||||
position: relative;
|
||||
z-index: 10;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 250rpx;
|
||||
height: 90rpx;
|
||||
border-radius: 12rpx;
|
||||
background: linear-gradient(270deg, #ff6756ff 0%, #f99364ff 100%);
|
||||
color: #fff;
|
||||
|
||||
image {
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
}
|
||||
}
|
||||
|
||||
// 选中后的样式
|
||||
.pay-amount-selected {
|
||||
position: relative;
|
||||
padding: 15rpx !important;
|
||||
border: 5rpx solid #FF5F4D;
|
||||
border-radius: 26rpx 5rpx 26rpx 26rpx;
|
||||
|
||||
image {
|
||||
position: absolute;
|
||||
top: -5rpx;
|
||||
right: -5rpx;
|
||||
z-index: 10;
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
}
|
||||
}
|
||||
|
||||
// 充值消费记录
|
||||
.re-con {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin: 0 auto;
|
||||
width: 690rpx;
|
||||
height: 110rpx;
|
||||
border-bottom: 1rpx solid rgba(0, 0, 0, 0.06);
|
||||
background: rgb(255, 255, 255);
|
||||
|
||||
.left {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
image {
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
|
||||
text {
|
||||
color: rgb(51, 51, 51);
|
||||
font-size: 30rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 非会员 样式
|
||||
.user-wrapper-no-momber {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.no-member-mian {
|
||||
height: 150rpx;
|
||||
}
|
||||
|
||||
.hover-but {
|
||||
opacity: 0.5 !important;
|
||||
}
|
||||
</style>
|
||||
197
jeepay-ui-uapp-cashier/pageMember/memberRecord/memberRecord.vue
Normal file
@@ -0,0 +1,197 @@
|
||||
<template>
|
||||
<view class="header-selected">
|
||||
<view :class="{ 'selected-style': pageData.rechargeOrConsume == 'recharge' }" @tap="headerChange('recharge')">充值记录
|
||||
</view>
|
||||
<view :class="{ 'selected-style': pageData.rechargeOrConsume == 'consume' }" @tap="headerChange('consume')">消费记录
|
||||
</view>
|
||||
</view>
|
||||
<view style="height: 110rpx;"></view>
|
||||
<!-- 充值记录 -->
|
||||
<block v-if="pageData.rechargeOrConsume == 'recharge'" v-for="(v, i) in pageData.pageDataList" :key="i">
|
||||
<view class="re-card">
|
||||
<view class="re-amount">
|
||||
<text class="unit">¥</text>
|
||||
{{ (v.entryAmount / 100).toFixed(2) }}
|
||||
</view>
|
||||
<view class="item">
|
||||
<view class="title">实付金额</view>
|
||||
<view class="desc">{{ (v.payAmount / 100).toFixed(2) }}元</view>
|
||||
</view>
|
||||
<view class="item">
|
||||
<view class="title">赠送金额</view>
|
||||
<view class="desc">{{ (v.giveAmount / 100).toFixed(2) }}元</view>
|
||||
</view>
|
||||
<view class="item">
|
||||
<view class="title">充值时间</view>
|
||||
<view class="desc">{{ v.createdAt }}</view>
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
<!-- 消费记录 -->
|
||||
<block v-if="pageData.rechargeOrConsume == 'consume'" v-for="(v, i) in pageData.pageDataList" :key="i">
|
||||
<view class="re-card">
|
||||
<view class="re-amount">
|
||||
<text class="unit">¥</text>
|
||||
{{ (Math.abs(v.changeAmount) / 100).toFixed(2) }}
|
||||
</view>
|
||||
<view class="item">
|
||||
<view class="title">消费商户</view>
|
||||
<view class="desc">{{ v.mchName }}</view>
|
||||
</view>
|
||||
<view class="item">
|
||||
<view class="title">消费时间</view>
|
||||
<view class="desc">{{ v.createdAt }}</view>
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
<view class="list-null" v-if="!pageData.hasNext">暂无更多数据</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref, reactive } from "vue"
|
||||
import { onReachBottom } from '@dcloudio/uni-app'
|
||||
import { $getMemberRechargeRecord, $getConsumeRecod } from "@/http/apiMember"
|
||||
const pageData = reactive({
|
||||
rechargeOrConsume: 'recharge',
|
||||
pageDataList: [],
|
||||
hasNext: true
|
||||
})
|
||||
const params = {
|
||||
pageNumber: 1,
|
||||
pageSize: 10
|
||||
}
|
||||
function getMemberRechargeRecord () {
|
||||
$getMemberRechargeRecord(params).then(({ bizData }) => {
|
||||
pageData.hasNext = bizData.hasNext
|
||||
pageData.pageDataList.push(...bizData.records)
|
||||
})
|
||||
}
|
||||
getMemberRechargeRecord()
|
||||
function getConsumeRecod () {
|
||||
params.bizType = 3
|
||||
$getConsumeRecod(params).then(({ bizData }) => {
|
||||
pageData.hasNext = bizData.hasNext
|
||||
pageData.pageDataList.push(...bizData.records)
|
||||
})
|
||||
}
|
||||
function headerChange (val) {
|
||||
pageData.rechargeOrConsume = val
|
||||
pageData.pageDataList = []
|
||||
params.pageNumber = 1
|
||||
pageData.hasNext = true
|
||||
val == 'recharge' ? getMemberRechargeRecord() : getConsumeRecod()
|
||||
}
|
||||
// 触底加载
|
||||
onReachBottom(() => {
|
||||
if (!pageData.hasNext) return
|
||||
params.pageNumber++
|
||||
pageData.rechargeOrConsume == 'recharge' ? getMemberRechargeRecord() : getConsumeRecod()
|
||||
})
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.header-selected {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
display: flex;
|
||||
height: 110rpx;
|
||||
background-color: #fff;
|
||||
|
||||
view {
|
||||
position: relative;
|
||||
flex: 0 0 50%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
color: rgb(128, 128, 128);
|
||||
font-size: 30rpx;
|
||||
font-weight: 500;
|
||||
transition: .3s ease-out;
|
||||
}
|
||||
|
||||
.selected-style {
|
||||
color: rgb(255, 95, 77);
|
||||
transition: .3s ease-out;
|
||||
|
||||
&::after {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
width: 36rpx;
|
||||
height: 6rpx;
|
||||
background: rgb(255, 95, 77);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.re-card {
|
||||
margin: 20rpx auto;
|
||||
padding: 0 30rpx;
|
||||
padding-bottom: 30rpx;
|
||||
box-sizing: border-box;
|
||||
width: 710rpx;
|
||||
border-radius: 10rpx;
|
||||
background-color: #fff;
|
||||
|
||||
.re-amount {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 20rpx;
|
||||
height: 100rpx;
|
||||
border-bottom: 1rpx solid rgba(0, 0, 0, 0.06);
|
||||
font-size: 30rpx;
|
||||
font-weight: 500;
|
||||
|
||||
.unit {
|
||||
font-size: 20rpx;
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
|
||||
.item {
|
||||
display: flex;
|
||||
margin: 15rpx 0;
|
||||
font-size: 26rpx;
|
||||
|
||||
.title {
|
||||
margin-right: 30rpx;
|
||||
color: rgb(128, 128, 128);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.list-null {
|
||||
position: relative;
|
||||
|
||||
line-height: 110rpx;
|
||||
text-align: center;
|
||||
font-size: 26rpx;
|
||||
color: #a6a6a6;
|
||||
|
||||
&::after,
|
||||
&::before {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
|
||||
width: 30%;
|
||||
height: 2rpx;
|
||||
background-color: #ededed;
|
||||
transform: translateY(-50%);
|
||||
}
|
||||
|
||||
&::after {
|
||||
left: 40rpx;
|
||||
}
|
||||
|
||||
&::before {
|
||||
right: 40rpx;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,93 @@
|
||||
<template>
|
||||
<uni-popup ref="popup" type="center">
|
||||
<view class="c-wrapper" :style="{ '--v-primary': calcThemeColor() }">
|
||||
<view class="c-title">会员余额支付</view>
|
||||
<view class="c-amount">
|
||||
<text>金额</text>
|
||||
¥{{ vdata.amount }}
|
||||
</view>
|
||||
<view class="but-wrapper">
|
||||
<view class="cancel" @tap="close">取消</view>
|
||||
<view class="confirm" @tap="confirm">确认支付</view>
|
||||
</view>
|
||||
</view>
|
||||
</uni-popup>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref, reactive } from "vue"
|
||||
import { calcThemeColor } from "@/util/member.js"
|
||||
const vdata = reactive({})
|
||||
const popup = ref(null)
|
||||
const emits = defineEmits(['pay'])
|
||||
const open = (amount) => {
|
||||
vdata.amount = amount
|
||||
popup.value.open()
|
||||
}
|
||||
const close = () => popup.value.close()
|
||||
const confirm = () => {
|
||||
emits('pay')
|
||||
}
|
||||
defineExpose({ open, close })
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.c-wrapper {
|
||||
width: 650rpx;
|
||||
height: 508rpx;
|
||||
padding: 30rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: #fff;
|
||||
border-radius: 20rpx;
|
||||
|
||||
.c-title {
|
||||
margin: 50rpx 0 70rpx 0;
|
||||
font-weight: bold;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.remarks-content {
|
||||
margin: 30rpx 0;
|
||||
}
|
||||
|
||||
.c-amount {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-direction: column;
|
||||
color: #000000ff;
|
||||
font-size: 50rpx;
|
||||
font-weight: 500;
|
||||
|
||||
text {
|
||||
margin-bottom: 20rpx;
|
||||
color: #808080ff;
|
||||
font-size: 30rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.but-wrapper {
|
||||
display: flex;
|
||||
margin-top: 50rpx;
|
||||
justify-content: space-between;
|
||||
view {
|
||||
flex: 0 0 45%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
height: 90rpx;
|
||||
color: #fff;
|
||||
border-radius: 15rpx;
|
||||
}
|
||||
|
||||
.cancel {
|
||||
color: #808080ff;
|
||||
}
|
||||
.confirm {
|
||||
width: 350rpx;
|
||||
height: 110rpx;
|
||||
border-radius: 20rpx;
|
||||
background-color: var(--v-primary);
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,231 @@
|
||||
<template>
|
||||
<view class="key-wrapper" :style="{ '--v-primary': calcThemeColor() }">
|
||||
<view class="key-re">
|
||||
<text @tap="emits('remarks')">添加备注</text>
|
||||
<view class="openOrClose" v-if="!isFixedFlag" @tap="vdata.openOrClose = !vdata.openOrClose">
|
||||
<text>{{ vdata.openOrClose ? '收起' : '展开' }}</text>
|
||||
<image src="/static/vipImg/openOrclose-key.svg" mode="aspectFill" :class="{ 'close-key': !vdata.openOrClose }">
|
||||
</image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="pay-but" hover-class="hover-pay" hover-start-time="10" hover-stay-time="60" :style="{ height: vdata.openOrClose ? '0' : '110rpx' }" v-if="!vdata.openOrClose && !isFixedFlag"
|
||||
@tap="emits('pay')">付款</view>
|
||||
<view class="key-mian"
|
||||
:style="{ maxHeight: vdata.openOrClose ? '800rpx' : '0', paddingBottom: vdata.openOrClose ? '50rpx' : '0' }"
|
||||
v-if="!isFixedFlag">
|
||||
<view class="key-left">
|
||||
<block v-for="(v, i) in keyList" :key="i">
|
||||
<view class="k-l-item flex-center" hover-class="hover-but" hover-start-time="10" hover-stay-time="60"
|
||||
:class="{ 'zero': v.val == '0' }" @tap="changeKey(v.val)"> {{ v.val }}</view>
|
||||
</block>
|
||||
</view>
|
||||
<view class="key-right">
|
||||
<view class="key-r-del flex-center" hover-class="hover-but" hover-start-time="10" hover-stay-time="60" @tap="deletedNumber">
|
||||
<image src="/static/vipImg/icon-del.svg" mode="aspectFill" class="mch-header"></image>
|
||||
</view>
|
||||
<view class="key-r-pay flex-center" hover-class="hover-pay" hover-start-time="10" hover-stay-time="60" @tap="emits('pay')">付款</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="fixed-wrapper" v-else>
|
||||
<view class="fixed-but flex-center" hover-class="hover-pay" hover-start-time="10" hover-stay-time="60" @tap="emits('pay')">确认支付</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
<script setup>
|
||||
import { ref, reactive } from "vue"
|
||||
import { calcThemeColor } from "@/util/member.js"
|
||||
const props = defineProps({
|
||||
value: {
|
||||
type: String,
|
||||
default: ''
|
||||
},
|
||||
isFixedFlag: { type: Boolean, default: false }
|
||||
})
|
||||
const vdata = reactive({
|
||||
openOrClose: false
|
||||
})
|
||||
const emits = defineEmits(['update:value', 'pay', 'remarks'])
|
||||
const keyList = [
|
||||
{ val: '1', pos: 'l' },
|
||||
{ val: '2', pos: 'l' },
|
||||
{ val: '3', pos: 'l' },
|
||||
{ val: '4', pos: 'l' },
|
||||
{ val: '5', pos: 'l' },
|
||||
{ val: '6', pos: 'l' },
|
||||
{ val: '7', pos: 'l' },
|
||||
{ val: '8', pos: 'l' },
|
||||
{ val: '9', pos: 'l' },
|
||||
{ val: '0', pos: 'l' },
|
||||
{ val: '.', pos: 'l' },
|
||||
]
|
||||
const changeKey = (val) => {
|
||||
// 禁止 输入长度 大于10位
|
||||
if(props.value.length > 10) return false
|
||||
// 如果值已经是0并且按下不是小数点 直接替换值
|
||||
if (props.value.toString().length == 1 && props.value == 0 && val != '.') return emits('update:value', val)
|
||||
// 只能包含一个小数点
|
||||
if (props.value.toString().includes('.') && val == '.') return
|
||||
// 限制小数点位数
|
||||
if (props.value.toString().includes('.') && props.value.split('.')[1].length >= props.point) return
|
||||
// 长度只有 一位 并且按下结果是小数点 直接 return
|
||||
if (props.value.toString().length == 1 && props.value == 0 && val != '.') return
|
||||
// 如果 清空后直接按下小数点 直接 return
|
||||
if ((props.value === '' || props.value == undefined) && val == '.') return emits('update:value', '0' + val)
|
||||
if (props.value.includes('.') && props.value.split('.')[1].length >= 2) return
|
||||
emitsParent(val)
|
||||
}
|
||||
const deletedNumber = () => {
|
||||
emits('update:value', props.value.slice(0, props.value.length - 1))
|
||||
}
|
||||
// 错误提示
|
||||
function tips (title) {
|
||||
uni.showToast({
|
||||
title,
|
||||
icon: 'none'
|
||||
})
|
||||
}
|
||||
// 向父级传递消息
|
||||
function emitsParent (v) {
|
||||
return emits('update:value', props.value + v)
|
||||
}
|
||||
function openKeyBoard () {
|
||||
if (!vdata.openOrClose) return vdata.openOrClose = true
|
||||
}
|
||||
defineExpose({ openKeyBoard })
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.key-re {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 0 40rpx;
|
||||
color: #1f7099ff;
|
||||
font-size: 25rpx;
|
||||
height: 90rpx;
|
||||
background-color: #fff;
|
||||
border-top: 1rpx solid #e6e6e6ff;
|
||||
border-bottom: 1rpx solid #e6e6e6ff;
|
||||
|
||||
.openOrClose {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
image {
|
||||
width: 50rpx;
|
||||
height: 50rpx;
|
||||
transform: rotate(180deg);
|
||||
transition: 0.3s ease-in-out;
|
||||
}
|
||||
|
||||
.close-key {
|
||||
transform: rotate(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.flex-center {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
border-radius: 10rpx;
|
||||
}
|
||||
|
||||
.key-mian {
|
||||
display: flex;
|
||||
padding: 0 5rpx;
|
||||
padding-top: 10rpx;
|
||||
padding-bottom: 50rpx;
|
||||
max-height: 0;
|
||||
border-top: 1rpx solid #0000001a;
|
||||
background: #f7f7f7ff;
|
||||
color: #000000ff;
|
||||
font-size: 40rpx;
|
||||
font-weight: 500;
|
||||
transition: max-height 0.3s ease-out;
|
||||
overflow: hidden;
|
||||
|
||||
.key-left {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
|
||||
.k-l-item {
|
||||
margin: 8rpx;
|
||||
width: 168rpx;
|
||||
height: 90rpx;
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
.zero {
|
||||
width: 350rpx;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.key-right {
|
||||
.key-r-del {
|
||||
margin: 5rpx;
|
||||
width: 168rpx;
|
||||
height: 90rpx;
|
||||
background-color: #fff;
|
||||
|
||||
image {
|
||||
width: 38rpx;
|
||||
height: 30rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.key-r-pay {
|
||||
margin: 5rpx;
|
||||
margin-top: 20rpx;
|
||||
width: 168rpx;
|
||||
height: 302rpx;
|
||||
color: #fff;
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
background-color: var(--v-primary);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.fixed-wrapper {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: flex-end;
|
||||
width: 100%;
|
||||
height: 200rpx;
|
||||
|
||||
.fixed-but {
|
||||
margin: 30rpx;
|
||||
margin-bottom: 70rpx;
|
||||
width: 100%;
|
||||
height: 110rpx;
|
||||
color: #fff;
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
border-radius: 20rpx;
|
||||
background-color: var(--v-primary);
|
||||
}
|
||||
}
|
||||
|
||||
.pay-but {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin: 15rpx auto;
|
||||
width: 719rpx;
|
||||
height: 110rpx;
|
||||
border-radius: 10rpx;
|
||||
color: #fff;
|
||||
background-color: var(--v-primary);
|
||||
transition: height 0.3s ease-in-out;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.hover-but {
|
||||
filter: brightness(80%);
|
||||
}
|
||||
.hover-pay{
|
||||
opacity: .5;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,71 @@
|
||||
<template>
|
||||
<uni-popup ref="popup" type="center">
|
||||
<view class="c-wrapper" :style="{ '--v-primary': calcThemeColor() }">
|
||||
<view class="c-title">添加支付备注</view>
|
||||
<view class="remarks-content">
|
||||
<textarea class="remarks-input" v-model="pageData.remarkText" placeholder="请输入备注信息" @input="inputChange" maxlength="120" />
|
||||
</view>
|
||||
<view class="conf-but" @tap="close">确认</view>
|
||||
</view>
|
||||
</uni-popup>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref,reactive } from "vue"
|
||||
import { calcThemeColor } from "@/util/member.js"
|
||||
const props = defineProps({
|
||||
value: ''
|
||||
})
|
||||
const emits = defineEmits(['update:value'])
|
||||
const pageData = reactive({
|
||||
remarkText: props.value
|
||||
})
|
||||
const popup = ref(null)
|
||||
const open = (amount) => {
|
||||
popup.value.open()
|
||||
}
|
||||
const close = () => popup.value.close()
|
||||
const inputChange = (e) => {
|
||||
emits('update:value', e.detail.value)
|
||||
}
|
||||
defineExpose({ open })
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.c-wrapper {
|
||||
width: calc(100vw - 60rpx);
|
||||
padding: 30rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: #fff;
|
||||
border-radius: 20rpx;
|
||||
|
||||
.c-title {
|
||||
margin-bottom: 30rpx;
|
||||
font-weight: bold;
|
||||
text-align: center;
|
||||
|
||||
}
|
||||
|
||||
.remarks-content {
|
||||
width: 100%;
|
||||
min-height: 160rpx;
|
||||
|
||||
.remarks-input {
|
||||
width: 100%;
|
||||
height: 100rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.conf-but {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin: 0 30rpx;
|
||||
margin-top: 30rpx;
|
||||
height: 90rpx;
|
||||
background-color: var(--v-primary);
|
||||
border-radius: 15rpx;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
527
jeepay-ui-uapp-cashier/pageMember/payMember/payMember.vue
Normal file
@@ -0,0 +1,527 @@
|
||||
<template>
|
||||
<view class="page-weapper" :style="{ '--v-primary': calcThemeColor(), '--bg-color': calcThemeColor('bgColor') }">
|
||||
<view class="header">
|
||||
<view class="mch-info">
|
||||
<view @tap="advancedFunc">付款给:{{ vdata.mchInfo.mchName }}</view>
|
||||
<view class="mch-img-box">
|
||||
<image :src="vdata.mchInfo.storeLogo" mode="aspectFill" class="mch-header"></image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="sub-title">付款金额</view>
|
||||
<view class="pay-wrapper" @tap="refKey.openKeyBoard()">
|
||||
<view class="pay-amount"
|
||||
:style="{ color: vdata.amount ? '' : '#ccccccff', fontSize: vdata.amount ? '100rpx' : '' }">
|
||||
{{ vdata.amount || '请输入付款金额' }}
|
||||
<text class="pay-icon">元</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="sub-title">支付方式</view>
|
||||
<view class="pay-select">
|
||||
<view class="pay-info">
|
||||
<image :src="calcThemeColor('imgUrl')" mode="aspectFill" class="pay-img"></image>
|
||||
<text>{{ vdata.pageTypeInfo?.title }}</text>
|
||||
</view>
|
||||
<view class="radio" :class="{ 'radio-selected': vdata.paySelected == vdata.pageTypeInfo.value }"
|
||||
@tap="vdata.paySelected = vdata.pageTypeInfo.value">
|
||||
<image src="/static/vipImg/selected-icon.svg" mode="aspectFill"
|
||||
v-if="vdata.paySelected == vdata.pageTypeInfo.value"></image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="surplus-wrapper">
|
||||
<view class="member-top">
|
||||
<view class="member-info">
|
||||
<image src="/static/vipImg/member-icon.svg" mode="aspectFill" class="member-icon"></image>
|
||||
<text>会员支付</text>
|
||||
</view>
|
||||
<view class="radio" :class="{ 'radio-selected': vdata.paySelected == 'member' }" @tap="() => {
|
||||
if (!vdata.mbrName) return
|
||||
vdata.paySelected = 'member'
|
||||
}">
|
||||
<image src="/static/vipImg/close-mereber.svg" mode="aspectFill" v-if="!vdata.mbrName"></image>
|
||||
<image src="/static/vipImg/selected-icon.svg" mode="aspectFill"
|
||||
v-if="vdata.paySelected == 'member'"></image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="balance-wrapper" @tap="toRech">
|
||||
<view class="ba-left" v-if="vdata.mbrName">可用余额:<text>¥{{ (vdata.balance / 100).toFixed(2) }}</text>
|
||||
</view>
|
||||
<view class="ba-left" style="color:#835511;" v-else> 您还未注册会员 </view>
|
||||
<view class="ba-right" hover-class="hover-but" hover-stay-time="200">
|
||||
<text>{{ vdata.mbrName ? '去充值' : '去注册' }}</text>
|
||||
<image src="/static/vipImg/icon-arrow.svg" mode="aspectFill"></image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 充值优惠部分 -->
|
||||
<view class="member-pref" v-if="amountRules.length">
|
||||
<view class="sub-title">现充值立享</view>
|
||||
<view style="padding-top: 11rpx;">
|
||||
<block v-for="v in amountRules" :key="v.ruleId">
|
||||
<view class="pref-info">
|
||||
<view class="pref-title">充值</view>
|
||||
<text>¥{{ parseFloat((v.rechargeAmount / 100).toFixed(2)) }}</text>
|
||||
<view class="pref-title">到账</view>
|
||||
<text>¥{{ parseFloat(((v.rechargeAmount + v.giveAmount) / 100).toFixed(2)) }}</text>
|
||||
</view>
|
||||
</block>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="footer-keyboard">
|
||||
<Keyboard ref="refKey" v-model:value="vdata.amount" :isFixedFlag="vdata.mchInfo.fixedFlag" @pay="payMember"
|
||||
@remarks="refRemarks.open()" />
|
||||
</view>
|
||||
</view>
|
||||
<ConfirmPay ref="refConfPay" @pay="confirmMemberPay" />
|
||||
<Remarks ref="refRemarks" v-model:value="vdata.buyerRemark" />
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { onLoad, onPullDownRefresh, onUnload } from '@dcloudio/uni-app'
|
||||
import { ref, reactive } from "vue"
|
||||
import { $apiMembers, $payRemberCard, $getMemberInfo, } from "@/http/apiMember.js"
|
||||
import { toErrPageFunc } from '@/util/toErrorPageUtil.js'
|
||||
import { $getPayPackage, $getAdvert } from "@/http/apiManager.js"
|
||||
import storageManage from '@/util/storageManage.js'
|
||||
import appConfig from "@/config/appConfig"
|
||||
import paywayCallFunc from '@/pages/payway/payway.js'
|
||||
import Remarks from "./components/Remarks.vue"
|
||||
import Keyboard from "./components/Keyboard.vue"
|
||||
import ConfirmPay from "./components/ConfirmPay.vue"
|
||||
// import { Base64 } from 'js-base64'
|
||||
import { calcThemeColor } from "@/util/member.js"
|
||||
onLoad(() => {
|
||||
uni.setNavigationBarColor({
|
||||
frontColor: '#ffffff',
|
||||
backgroundColor: calcThemeColor()
|
||||
})
|
||||
// 查询会员信息 token
|
||||
$apiMembers({ method: 'mbr.info', channelUesrId: Base64.encode(appConfig.channelUserId) }).then(({ bizData }) => {
|
||||
if (bizData) {
|
||||
storageManage.iToken(bizData)
|
||||
getMemberInfo() //存储token 查询会员信息
|
||||
}
|
||||
getMchInfos()
|
||||
})
|
||||
uni.$on('updateMemberInfos', () => {
|
||||
console.log('接收页面通讯');
|
||||
getMemberInfo()
|
||||
})
|
||||
getRules()
|
||||
})
|
||||
onUnload(() => {
|
||||
uni.$off('updateMemberInfos')
|
||||
})
|
||||
const refConfPay = ref(null)
|
||||
const refRemarks = ref(null)
|
||||
const refKey = ref(null)
|
||||
const amountRules = reactive([])
|
||||
const vdata = reactive({
|
||||
amount: '',
|
||||
paySelected: '',
|
||||
pageTypeInfo: {},
|
||||
payOrderInfo: {},
|
||||
mchInfo: {},
|
||||
clearStorageFlag: 0, //显示清空缓存的提示
|
||||
})
|
||||
const pageType = {
|
||||
wechatLite: { title: '微信支付', value: 'wechatLite' },
|
||||
alipayLite: { title: '支付宝支付', value: 'alipayLite' },
|
||||
wechatH5: { title: '微信支付', value: 'wechatH5' },
|
||||
alipayH5: { title: '支付宝支付', value: 'alipayH5' },
|
||||
ysfpayH5: { title: '云闪付', value: 'ysfpayH5' },
|
||||
otherH5: { title: '银联', value: 'otherH5' }
|
||||
}
|
||||
vdata.pageTypeInfo = pageType[appConfig.currentPageType]
|
||||
vdata.paySelected = appConfig.currentPageType
|
||||
const toRech = () => uni.navigateTo({ url: '/pageMember/memberInfo/memberInfo' })
|
||||
// 获取商户信息 门店头像
|
||||
const getMchInfos = () => {
|
||||
$apiMembers({ method: 'mch.info' }).then(({ bizData }) => {
|
||||
if (bizData.fixedFlag) {
|
||||
vdata.amount = (bizData.amount / 100).toFixed(2)
|
||||
}
|
||||
vdata.mchInfo = bizData || {}
|
||||
})
|
||||
}
|
||||
const payMember = () => {
|
||||
if (vdata.amount <= 0) {
|
||||
return uni.showToast({
|
||||
title: '金额必须大于0',
|
||||
icon: 'none'
|
||||
})
|
||||
}
|
||||
// 非会员支付 直接拉起支付
|
||||
if (vdata.paySelected != 'member') return pay()
|
||||
if (vdata.amount > (vdata.balance / 100)) return uni.showToast({ title: '会员余额不足请前去充值', icon: 'none' })
|
||||
refConfPay.value.open(vdata.amount, vdata.buyerRemark)
|
||||
}
|
||||
// 发起支付
|
||||
function pay () {
|
||||
vdata.payOrderInfo.amount = vdata.amount
|
||||
uni.showLoading({
|
||||
title: '请稍等...',
|
||||
mask: true
|
||||
})
|
||||
$getPayPackage(vdata.amount, vdata.buyerRemark, vdata.mbrId || '', vdata.mbrTel || '').then(({ bizData }) => {
|
||||
uni.hideLoading()
|
||||
//订单创建异常
|
||||
if (bizData.code != '0') {
|
||||
return toErrPageFunc(bizData.msg);
|
||||
}
|
||||
|
||||
// 订单响应结果
|
||||
let orderRes = bizData.data;
|
||||
|
||||
if (orderRes.orderState != 1) { //订单不是支付中,说明订单异常
|
||||
return toErrPageFunc(orderRes.errMsg);
|
||||
}
|
||||
|
||||
if (orderRes.payUrl) {
|
||||
location.href = orderRes.payUrl;
|
||||
return false;
|
||||
}
|
||||
|
||||
// 以下为调起 jsapi的函数: 分为: H5 和 各端小程序
|
||||
let thisPaywayCallFunc = paywayCallFunc()[appConfig.currentPageType];
|
||||
thisPaywayCallFunc(orderRes, vdata.payOrderInfo);
|
||||
}).catch(() => {
|
||||
uni.hideLoading()
|
||||
})
|
||||
|
||||
}
|
||||
// 获取会员信息
|
||||
const getMemberInfo = () => {
|
||||
$getMemberInfo().then(({ bizData }) => {
|
||||
console.log('接收页面通讯', bizData);
|
||||
vdata.balance = bizData.balance
|
||||
vdata.mbrName = bizData.mbrName
|
||||
vdata.mbrId = bizData.mbrId
|
||||
vdata.mbrTel = bizData.mbrTel
|
||||
})
|
||||
}
|
||||
// 查询会员充值规则
|
||||
const getRules = () => {
|
||||
$apiMembers().then(({ bizData }) => {
|
||||
console.log(bizData.records);
|
||||
amountRules.push(...bizData.records)
|
||||
})
|
||||
}
|
||||
const closePage = {
|
||||
wechatH5: () => window.WeixinJSBridge.call('closeWindow'),
|
||||
alipayH5: () => window.AlipayJSBridge.call('closeWebview'),
|
||||
ysfpayH5: () => { window.WeixinJSBridge.call('closeWindow'); window.AlipayJSBridge.call('closeWebview') },
|
||||
otherH5: () => { window.WeixinJSBridge.call('closeWindow'); window.AlipayJSBridge.call('closeWebview') }
|
||||
}
|
||||
// 会员支付
|
||||
const confirmMemberPay = () => {
|
||||
$payRemberCard(vdata.amount, vdata.buyerRemark).then(res => {
|
||||
uni.showToast({ title: '支付成功' })
|
||||
refConfPay.value.close()
|
||||
if (appConfig.currentPageType.includes('H5')) {
|
||||
// 查询是否开启点金计划 如果开启点金计划 window.open() 打开新页面
|
||||
$getAdvert({ appPlace: 4 }).then(({ bizData }) => {
|
||||
if (bizData && bizData.linkUrl) {
|
||||
uni.reLaunch({ url: '/pages/H5/H5?url=' + bizData.linkUrl })
|
||||
return false
|
||||
}
|
||||
return closePage[appConfig.currentPageType]()
|
||||
})
|
||||
return false
|
||||
}
|
||||
uni.navigateTo({ url: '/pages/paySuccess/paySuccess?amount=' + vdata.amount + '&member=true' })
|
||||
vdata.amount = '0'
|
||||
vdata.buyerRemark = ''
|
||||
getMemberInfo()
|
||||
})
|
||||
}
|
||||
|
||||
// 高级功能模块的显示
|
||||
function advancedFunc () {
|
||||
vdata.clearStorageFlag = vdata.clearStorageFlag + 1
|
||||
if (vdata.clearStorageFlag >= 10) {
|
||||
vdata.clearStorageFlag = 0
|
||||
// 目前仅清空缓存
|
||||
uni.showModal({
|
||||
title: '确认清除缓存?',
|
||||
success: function (r) {
|
||||
if (r.confirm) {
|
||||
uni.clearStorageSync()
|
||||
return uni.showToast({ title: '已清空' })
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.sub-title {
|
||||
margin: 50rpx;
|
||||
margin-bottom: 20rpx;
|
||||
color: #4d4d4dff;
|
||||
font-size: 25rpx;
|
||||
}
|
||||
|
||||
.radio {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
border: 2rpx solid #00000026;
|
||||
border-radius: 50%;
|
||||
overflow: hidden;
|
||||
|
||||
image {
|
||||
width: 16rpx;
|
||||
height: 12rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.radio-selected {
|
||||
background-color: var(--v-primary);
|
||||
}
|
||||
|
||||
.page-weapper {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
height: 100vh;
|
||||
background-color: #fff;
|
||||
border-radius: 50rpx 50rpx 0 0;
|
||||
|
||||
.header {
|
||||
position: relative;
|
||||
overflow-y: auto;
|
||||
|
||||
&::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
z-index: -1;
|
||||
height: 40rpx;
|
||||
background-color: var(--v-primary);
|
||||
}
|
||||
|
||||
.mch-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin: 50rpx;
|
||||
color: #000000ff;
|
||||
font-size: 30rpx;
|
||||
|
||||
.mch-img-box {
|
||||
border: 1rpx solid #0000000f;
|
||||
|
||||
image {
|
||||
width: 72rpx;
|
||||
height: 72rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.pay-amount {
|
||||
display: flex;
|
||||
align-items: flex-end;
|
||||
justify-content: space-between;
|
||||
margin: 0 50rpx;
|
||||
margin-bottom: 67rpx;
|
||||
font-size: 50rpx;
|
||||
color: var(--v-primary);
|
||||
height: 110rpx;
|
||||
|
||||
.pay-icon {
|
||||
align-self: flex-end;
|
||||
color: #808080ff;
|
||||
font-size: 50rpx;
|
||||
vertical-align: bottom;
|
||||
}
|
||||
}
|
||||
|
||||
.pay-select {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding: 0 30rpx;
|
||||
margin: 0 35rpx;
|
||||
margin-top: 20rpx;
|
||||
height: 100rpx;
|
||||
background: #52cc701a;
|
||||
border-radius: 20rpx;
|
||||
|
||||
.pay-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
image {
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
|
||||
}
|
||||
|
||||
text {
|
||||
margin-left: 20rpx;
|
||||
color: #4d4d4dff;
|
||||
font-size: 30rpx;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
.surplus-wrapper {
|
||||
margin: 20rpx 35rpx;
|
||||
padding: 30rpx;
|
||||
padding-right: 0;
|
||||
border-radius: 20rpx;
|
||||
background: #ffbe4c1a;
|
||||
|
||||
.member-top {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
padding-right: 30rpx;
|
||||
|
||||
.member-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
image {
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
}
|
||||
|
||||
text {
|
||||
margin-left: 20rpx;
|
||||
color: #4d4d4dff;
|
||||
font-size: 30rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
text {
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.to-recharge {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
height: 50rpx;
|
||||
width: 120rpx;
|
||||
background-color: var(--v-primary);
|
||||
color: #fff;
|
||||
border-radius: 10rpx;
|
||||
margin-left: 30rpx;
|
||||
font-size: 26rpx;
|
||||
}
|
||||
|
||||
.balance-wrapper {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-left: 60rpx;
|
||||
margin-top: 30rpx;
|
||||
padding-top: 15rpx;
|
||||
height: 70rpx;
|
||||
border-top: 1rpx solid #0000000f;
|
||||
|
||||
.ba-left {
|
||||
color: #835511ff;
|
||||
font-size: 25rpx;
|
||||
font-weight: 400;
|
||||
|
||||
text {
|
||||
color: #ff8000ff;
|
||||
font-size: 25rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
}
|
||||
|
||||
.ba-right {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
color: #1f7099ff;
|
||||
font-size: 25rpx;
|
||||
|
||||
image {
|
||||
margin-right: 30rpx;
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.Prepaid {
|
||||
margin-left: 60rpx;
|
||||
}
|
||||
|
||||
.rec-info {
|
||||
display: flex;
|
||||
margin: 50rpx 60rpx;
|
||||
font-size: 28rpx;
|
||||
color: #ccc;
|
||||
|
||||
.info-list {
|
||||
margin-left: 30rpx;
|
||||
color: var(--v-primary);
|
||||
|
||||
.l-item {
|
||||
margin-bottom: 15rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.pay-remarks {
|
||||
position: absolute;
|
||||
top: -80rpx;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
color: var(--v-primary);
|
||||
}
|
||||
|
||||
.footer-keyboard {
|
||||
flex-shrink: 0;
|
||||
position: relative;
|
||||
}
|
||||
}
|
||||
|
||||
.pay-wrapper {
|
||||
height: 100rpx;
|
||||
}
|
||||
|
||||
.member-pref {
|
||||
display: flex;
|
||||
|
||||
.sub-title {
|
||||
margin-top: 39rpx;
|
||||
}
|
||||
|
||||
.pref-info {
|
||||
display: flex;
|
||||
margin: 28rpx 0;
|
||||
font-size: 24rpx;
|
||||
|
||||
view {
|
||||
color: #4c4c4cff;
|
||||
}
|
||||
|
||||
text {
|
||||
margin-left: 10rpx;
|
||||
margin-right: 30rpx;
|
||||
color: #ff624fff;
|
||||
font-weight: 500;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.hover-but {
|
||||
opacity: .5;
|
||||
}
|
||||
</style>
|
||||
152
jeepay-ui-uapp-cashier/pages.json
Normal file
@@ -0,0 +1,152 @@
|
||||
/**
|
||||
* 2021-12-16: 目前uniapp vue3版本暂时没有可用的vueRouter组件, 无法使用动态路由, 暂时只能使用参数传值的方式导入TOKEN。
|
||||
* //TODO 后期支持了router可以采用 history模式 + path动态参数。
|
||||
*
|
||||
**/
|
||||
{
|
||||
"pages": [ //pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages
|
||||
{
|
||||
"path": "pages/index/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "收银台"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/hub/lite"
|
||||
},
|
||||
{
|
||||
"path": "pages/hub/default",
|
||||
"style": {
|
||||
"navigationBarTitleText": "跳转中"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/hub/h5",
|
||||
"style": {
|
||||
"navigationBarTitleText": "跳转中"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/error/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "提示"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/payway/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "收银台",
|
||||
"navigationBarBackgroundColor": "#FFFFFF"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/oauth2/callback",
|
||||
"style": {
|
||||
"navigationBarTitleText": "跳转中"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/paySuccess/paySuccess",
|
||||
"style": {
|
||||
"navigationBarTitleText": "提示"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/paySuccess/redSuccess",
|
||||
"style": {
|
||||
"navigationBarTitleText": "提示",
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/pay/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "收银台"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/pay/lite",
|
||||
"style": {
|
||||
"navigationBarTitleText": "收银台"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/pay/result",
|
||||
"style": {
|
||||
"navigationBarTitleText": "收银台"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/payment/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "收银台"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/payment/lite",
|
||||
"style": {
|
||||
"navigationBarTitleText": "收银台"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/payment/result",
|
||||
"style": {
|
||||
"navigationBarTitleText": "收银台"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/H5/H5",
|
||||
"style": {
|
||||
"navigationStyle": "custom",
|
||||
"mp-alipay": {
|
||||
"transparentTitle": "always",
|
||||
"titlePenetrate": "YES",
|
||||
"defaultTitle": " "
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
, {
|
||||
"path": "pages/route/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "交易支付",
|
||||
"enablePullDownRefresh": false
|
||||
}
|
||||
|
||||
}
|
||||
],
|
||||
"subPackages": [{
|
||||
"root": "pageMember",
|
||||
"pages": [{
|
||||
"path": "payMember/payMember",
|
||||
"style": {
|
||||
"navigationBarTitleText": "快捷支付"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "memberInfo/memberInfo",
|
||||
"style": {
|
||||
"navigationBarTitleText": "会员中心",
|
||||
"enablePullDownRefresh": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "memberRecord/memberRecord",
|
||||
"style": {
|
||||
"navigationBarTitleText": "充值/消费记录",
|
||||
"navigationBarTextStyle": "black",
|
||||
"navigationBarBackgroundColor": "#fff"
|
||||
}
|
||||
}
|
||||
]
|
||||
}],
|
||||
"globalStyle": {
|
||||
// #ifdef H5
|
||||
"navigationStyle": "custom",
|
||||
// #endif
|
||||
"navigationBarTitleText": " ",
|
||||
"navigationBarTextStyle": "white",
|
||||
"navigationBarBackgroundColor": "#F5F7FA",
|
||||
"backgroundColor": "#F5F7FA"
|
||||
}
|
||||
}
|
||||
25
jeepay-ui-uapp-cashier/pages/H5/H5.vue
Normal file
@@ -0,0 +1,25 @@
|
||||
<template>
|
||||
<web-view :src="src" update-title />
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import { ref } from 'vue'
|
||||
const src = ref('')
|
||||
onLoad((options) => {
|
||||
src.value = options.url
|
||||
// #ifdef H5 || MP-WEIXIN
|
||||
uni.setNavigationBarTitle({
|
||||
title: ' '
|
||||
})
|
||||
// #endif
|
||||
// 条件编译 支付宝
|
||||
// #ifdef H5 || MP-ALIPAY
|
||||
my.setNavigationBar({
|
||||
title: ' '
|
||||
})
|
||||
// #endif
|
||||
})
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped></style>
|
||||
58
jeepay-ui-uapp-cashier/pages/error/index.vue
Normal file
@@ -0,0 +1,58 @@
|
||||
<template>
|
||||
<view class="error">
|
||||
<image src="/static/img/fail.svg" class="error-icon"></image>
|
||||
<text class="error-err">提示</text>
|
||||
<view class="error-msg" v-if="errorInfo">
|
||||
<view class="msg">{{errorInfo}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import theme from '@/config/theme.js'
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import { ref } from 'vue'
|
||||
|
||||
let errorInfo = ref('')
|
||||
|
||||
onLoad((params) => {
|
||||
theme.changeColors()
|
||||
errorInfo.value = params.errInfo;
|
||||
})
|
||||
|
||||
|
||||
</script>
|
||||
<style lang="scss">
|
||||
.error {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
}
|
||||
.error-icon {
|
||||
padding-top: 200rpx;
|
||||
width: 240rpx;
|
||||
height: 166rpx;
|
||||
}
|
||||
.error-err {
|
||||
padding-top: 50rpx;
|
||||
font-size: 34rpx;
|
||||
font-weight: 600;
|
||||
color: #242526;
|
||||
}
|
||||
.error-msg {
|
||||
width: 75%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
padding-top: 70rpx;
|
||||
color: #999999;
|
||||
word-wrap:break-word;
|
||||
text-align: center;
|
||||
.msg {
|
||||
width: 100%;
|
||||
line-height: 42rpx;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
27
jeepay-ui-uapp-cashier/pages/hub/default.vue
Normal file
@@ -0,0 +1,27 @@
|
||||
<template>
|
||||
<view></view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import navigateUtil from '@/util/navigateUtil.js'
|
||||
|
||||
onLoad( (toPageParams) => {
|
||||
|
||||
// #ifdef H5
|
||||
navigateUtil.to('/pages/hub/h5', toPageParams)
|
||||
// #endif
|
||||
|
||||
// #ifdef MP-WEIXIN || MP-ALIPAY
|
||||
navigateUtil.to('/pages/hub/lite', toPageParams)
|
||||
// #endif
|
||||
|
||||
} )
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
</style>
|
||||
42
jeepay-ui-uapp-cashier/pages/hub/h5.vue
Normal file
@@ -0,0 +1,42 @@
|
||||
<template>
|
||||
<view></view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
import { setToken } from '@/util/jeepayTokenUtil.js'
|
||||
import { $getRedirectUrl } from '@/http/apiManager.js'
|
||||
import navigateUtil from '@/util/navigateUtil.js'
|
||||
import storageManage from '@/util/storageManage.js'
|
||||
import { onMounted } from 'vue'
|
||||
import { navigateTo } from "@/util/member.js"
|
||||
|
||||
// uniapp 的钩子事件(同步), 一般用作获取到页面传参
|
||||
// 通用放置token & 如果获取异常 将跳转到错误页面;
|
||||
onLoad( (toPageParams) => setToken(toPageParams) )
|
||||
|
||||
// vue的挂载钩子
|
||||
onMounted( (opt) => {
|
||||
$getRedirectUrl().then( ({bizData}) => {
|
||||
// 如果缓存包含该渠道用户ID, 那么直接跳转。
|
||||
if(bizData.channelUserIdCacheKey && storageManage.channelUserId(bizData.channelUserIdCacheKey)){
|
||||
navigateTo(storageManage.channelUserId(bizData.channelUserIdCacheKey))
|
||||
return false
|
||||
}
|
||||
// 需要重定向
|
||||
if(bizData.redirectFlag){
|
||||
location.href = bizData.redirectUrl
|
||||
return false;
|
||||
}else{ // 无需获取
|
||||
navigateUtil.redirectTo('/pages/payway/index') // 跳转到输入金额 页面;
|
||||
}
|
||||
|
||||
})
|
||||
})
|
||||
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
</style>
|
||||
124
jeepay-ui-uapp-cashier/pages/hub/lite.vue
Normal file
@@ -0,0 +1,124 @@
|
||||
<template>
|
||||
<view>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { onLoad, onShow } from '@dcloudio/uni-app'
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
import { setToken, setPageType, setLiteToken } from '@/util/jeepayTokenUtil.js'
|
||||
import { reactive } from 'vue'
|
||||
import { $getChannelUserId } from '@/http/apiManager.js'
|
||||
import { toErrPageFunc } from '@/util/toErrorPageUtil.js'
|
||||
import storageManage from '@/util/storageManage.js'
|
||||
// import { Base64 } from 'js-base64'
|
||||
import { navigateTo } from "@/util/member.js"
|
||||
onLoad((options) => {
|
||||
|
||||
setPageType()
|
||||
|
||||
if (appConfig.currentPageType == appConfig.PAGE_TYPE_ENUM.WECHAT_LITE) {
|
||||
getWxParams(options)
|
||||
} else if (appConfig.currentPageType == appConfig.PAGE_TYPE_ENUM.ALIPAY_LITE) {
|
||||
getAliParams(options)
|
||||
}
|
||||
})
|
||||
|
||||
// 微信登录
|
||||
function getWxParams(options) {
|
||||
|
||||
let query = options.q || ''
|
||||
setLiteToken(decodeURIComponent(query))
|
||||
|
||||
uni.showLoading({title: '加载中...'})
|
||||
|
||||
// 获取openId
|
||||
wx.login({
|
||||
success(res) {
|
||||
commonGetChannelUserIdFunc(appConfig.PAGE_TYPE_ENUM.WECHAT_LITE, res.code, { 'code': res.code })
|
||||
},
|
||||
fail() {
|
||||
uni.hideLoading()
|
||||
toErrPageFunc('登录失败')
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
// 支付宝登录
|
||||
function getAliParams(options) {
|
||||
|
||||
// 首页扫码进入
|
||||
if (options && options.isNeedParseQrc) {
|
||||
let query = options.q || ''
|
||||
setLiteToken(decodeURIComponent(query))
|
||||
}
|
||||
|
||||
uni.showLoading({title: '加载中...'})
|
||||
|
||||
my.getAuthCode({
|
||||
success: (res) => {
|
||||
commonGetChannelUserIdFunc(appConfig.PAGE_TYPE_ENUM.ALIPAY_LITE, res.authCode, { 'auth_code': res.authCode })
|
||||
},
|
||||
fail: (res) => {
|
||||
uni.hideLoading()
|
||||
toErrPageFunc('登录失败')
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
function commonGetChannelUserIdFunc(pageType, authCode, reqParams){
|
||||
|
||||
if (authCode) {
|
||||
|
||||
// 缓存KEY: jeepayChannelUserId_pageType
|
||||
// 此处不再查询后端的缓存KEY, 不同小程序之间做了隔离, 与浏览器有区别。 所以此处不需要根据appID做区分。
|
||||
// 此小程序内, 获取到的只能是此服务商该小程序APPID的openID
|
||||
let channelUserIdCacheKey = 'jeepayChannelUserId_' + pageType;
|
||||
// let jeepayChannelUniIdKey = 'jeepayChannelUniId_' + pageType;
|
||||
// 存在缓存
|
||||
if(storageManage.channelUserId(channelUserIdCacheKey)){
|
||||
navigateTo(storageManage.channelUserId(channelUserIdCacheKey))
|
||||
uni.hideLoading()
|
||||
return
|
||||
}
|
||||
// 传输是否为特约商户的小程序账号
|
||||
if(reqParams){
|
||||
reqParams.isUseSubmchAccount = appConfig.isUseSubmchAccount
|
||||
}
|
||||
// 以下为不存在缓存数据
|
||||
$getChannelUserId(reqParams).then(({ bizData }) => {
|
||||
console.log('channelUserId',bizData);
|
||||
// 放置 userID缓存。
|
||||
if(bizData){
|
||||
storageManage.channelUserId(channelUserIdCacheKey, bizData)
|
||||
}
|
||||
navigateTo(bizData)
|
||||
uni.hideLoading()
|
||||
|
||||
}).catch(err => {
|
||||
uni.hideLoading()
|
||||
console.log(err);
|
||||
})
|
||||
} else {
|
||||
uni.hideLoading()
|
||||
return toErrPageFunc('登录失败')
|
||||
}
|
||||
}
|
||||
// 跳转至收银台
|
||||
function setChannelUserIdAndToPaywayPage() {
|
||||
uni.redirectTo({
|
||||
url: '/pages/payway/index',
|
||||
success() {
|
||||
uni.hideLoading()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
</style>
|
||||
137
jeepay-ui-uapp-cashier/pages/index/index.vue
Normal file
@@ -0,0 +1,137 @@
|
||||
<template>
|
||||
<view class="content" style="background: url('/static/syb_bg.png') no-repeat;background-size: 100%;">
|
||||
<button class="scan-btn fixed-box" hover-class="scan-btn-hover" :style="{'backgroundColor': vdata.primaryColor}" @click="scanQrcFunc">扫码买单</button>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup >
|
||||
import { reactive } from 'vue'
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import theme from '@/config/theme.js'
|
||||
import navigateUtil from '@/util/navigateUtil.js'
|
||||
import {toErrPageFunc} from '@/util/toErrorPageUtil.js'
|
||||
|
||||
const vdata = reactive({
|
||||
primaryColor: ''
|
||||
})
|
||||
|
||||
onLoad(() => {
|
||||
vdata.primaryColor = theme.changeColors()
|
||||
})
|
||||
|
||||
function scanQrcFunc() {
|
||||
uni.scanCode({
|
||||
success({ result }) {
|
||||
if (result.includes("pages/hub/lite") || result.includes("pages/hub/default")) {
|
||||
navigateUtil.to('/pages/hub/lite', { q: result, isNeedParseQrc: true })
|
||||
}else {
|
||||
return toErrPageFunc('不支持的二维码类型!');
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
const toPayMember =()=> navigateUtil.to('/pages/payway/index')
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.content {
|
||||
// background:;
|
||||
background-size: cover;
|
||||
height: 100vh;
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
// background: #ffffff;
|
||||
// background-size: auto;
|
||||
|
||||
.content-top-bg {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
height: 212rpx;
|
||||
border-radius: 0 0 30rpx 30rpx;
|
||||
z-index: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.tips {
|
||||
position: relative;
|
||||
width: 650rpx;
|
||||
margin-top: 20rpx;
|
||||
border-radius: 30rpx;
|
||||
background: #fff;
|
||||
z-index: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
padding: 70rpx 0;
|
||||
|
||||
.tips-title {
|
||||
font-weight: bold;
|
||||
font-size: 33rpx;
|
||||
letter-spacing: 0.04em;
|
||||
}
|
||||
.tips-image {
|
||||
height: 150rpx;
|
||||
width: 150rpx;
|
||||
padding-top: 100rpx;
|
||||
}
|
||||
image {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
.tips-content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
padding-top: 70rpx;
|
||||
font-size: 27rpx;
|
||||
letter-spacing: 0.04em;
|
||||
line-height: 51rpx;
|
||||
text-align: center;
|
||||
color: #000;
|
||||
}
|
||||
}
|
||||
.scan-btn {
|
||||
width: 80%;
|
||||
margin-top: 100rpx;
|
||||
border-radius: 10rpx;
|
||||
color: #fff;
|
||||
}
|
||||
.scan-btn-hover {
|
||||
color: #fff;
|
||||
opacity: 0.8;
|
||||
}
|
||||
.payment-no-keyboard {
|
||||
width: 500rpx;
|
||||
height: 120rpx;
|
||||
position: fixed;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 240rpx;
|
||||
margin: 0 auto;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
font-size: 36rpx;
|
||||
color: $uni-text-color-inverse;
|
||||
border-radius: 8rpx;
|
||||
}
|
||||
.fixed-box {
|
||||
position: fixed !important;
|
||||
bottom: 0 !important;
|
||||
left: 0 !important;
|
||||
width: 90% !important;
|
||||
// background-color: #07C160 !important;
|
||||
background-color: #1678FF !important;
|
||||
padding: 3px !important;
|
||||
margin-left: 5%;
|
||||
margin-bottom: 5%;
|
||||
border-radius: 10px;
|
||||
}
|
||||
</style>
|
||||
141
jeepay-ui-uapp-cashier/pages/index/index_back.vue
Normal file
@@ -0,0 +1,141 @@
|
||||
<template>
|
||||
<view class="content">
|
||||
<view class="content-top-bg" :style="{'backgroundColor': vdata.primaryColor}"></view>
|
||||
<view class="tips">
|
||||
<view class="tips-title" :style="{'color': vdata.primaryColor}">欢迎使用Jeepay收银台</view>
|
||||
<view class="tips-image"><image src="/static/img/scan.svg"></image></view>
|
||||
<!-- #ifdef H5 -->
|
||||
<view class="tips-content">
|
||||
<text>请使用手机</text>
|
||||
<text>扫描Jeepay收款码进入</text>
|
||||
</view>
|
||||
<!-- #endif -->
|
||||
|
||||
<!-- #ifdef MP-ALIPAY || MP-WEIXIN -->
|
||||
<button class="scan-btn" hover-class="scan-btn-hover" :style="{'backgroundColor': vdata.primaryColor}" @click="scanQrcFunc">扫码买单</button>
|
||||
<!-- #endif -->
|
||||
</view>
|
||||
<!-- <view
|
||||
v-if="appConfig.currentPageType != appConfig.PAGE_TYPE_ENUM.OTHER_H5"
|
||||
class="payment-no-keyboard"
|
||||
:style="{'backgroundColor': vdata.primaryColor}"
|
||||
@tap="pay">
|
||||
跳转至测试付款页
|
||||
</view> -->
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup >
|
||||
import { reactive } from 'vue'
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import theme from '@/config/theme.js'
|
||||
import navigateUtil from '@/util/navigateUtil.js'
|
||||
import {toErrPageFunc} from '@/util/toErrorPageUtil.js'
|
||||
|
||||
const vdata = reactive({
|
||||
primaryColor: ''
|
||||
})
|
||||
|
||||
onLoad(() => {
|
||||
vdata.primaryColor = theme.changeColors()
|
||||
})
|
||||
|
||||
function scanQrcFunc() {
|
||||
uni.scanCode({
|
||||
success({ result }) {
|
||||
if (result.includes("pages/hub/lite") || result.includes("pages/hub/default")) {
|
||||
navigateUtil.to('/pages/hub/lite', { q: result, isNeedParseQrc: true })
|
||||
}else {
|
||||
return toErrPageFunc('不支持的二维码类型!');
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
const toPayMember =()=> navigateUtil.to('/pages/payway/index')
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.content {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
.content-top-bg {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
height: 212rpx;
|
||||
border-radius: 0 0 30rpx 30rpx;
|
||||
z-index: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.tips {
|
||||
position: relative;
|
||||
width: 650rpx;
|
||||
margin-top: 20rpx;
|
||||
border-radius: 30rpx;
|
||||
background: #fff;
|
||||
z-index: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
padding: 70rpx 0;
|
||||
|
||||
.tips-title {
|
||||
font-weight: bold;
|
||||
font-size: 33rpx;
|
||||
letter-spacing: 0.04em;
|
||||
}
|
||||
.tips-image {
|
||||
height: 150rpx;
|
||||
width: 150rpx;
|
||||
padding-top: 100rpx;
|
||||
}
|
||||
image {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
.tips-content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
padding-top: 70rpx;
|
||||
font-size: 27rpx;
|
||||
letter-spacing: 0.04em;
|
||||
line-height: 51rpx;
|
||||
text-align: center;
|
||||
color: #000;
|
||||
}
|
||||
}
|
||||
.scan-btn {
|
||||
width: 80%;
|
||||
margin-top: 100rpx;
|
||||
border-radius: 10rpx;
|
||||
color: #fff;
|
||||
}
|
||||
.scan-btn-hover {
|
||||
color: #fff;
|
||||
opacity: 0.8;
|
||||
}
|
||||
.payment-no-keyboard {
|
||||
width: 500rpx;
|
||||
height: 120rpx;
|
||||
position: fixed;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 240rpx;
|
||||
margin: 0 auto;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
font-size: 36rpx;
|
||||
color: $uni-text-color-inverse;
|
||||
border-radius: 8rpx;
|
||||
}
|
||||
</style>
|
||||
73
jeepay-ui-uapp-cashier/pages/oauth2/callback.vue
Normal file
@@ -0,0 +1,73 @@
|
||||
<template>
|
||||
<view>
|
||||
<p style="font-size:16px; text-align: center;" @tap="bugbugbug">正在跳转...</p>
|
||||
<view v-if="vdata.showBizData">
|
||||
<p style="font-size:12px; text-align: center;">bizData:{{ vdata.bizData }}</p>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
import { setToken } from '@/util/jeepayTokenUtil.js'
|
||||
import { $getChannelUserId } from '@/http/apiManager.js'
|
||||
import storageManage from '@/util/storageManage.js'
|
||||
import { navigateTo } from "@/util/member.js"
|
||||
import { onMounted, reactive } from 'vue'
|
||||
|
||||
const vdata = reactive({
|
||||
showBizData:false,
|
||||
bizData: {}
|
||||
})
|
||||
|
||||
// uniapp 的钩子事件(同步), 一般用作获取到页面传参
|
||||
// 通用放置token & 如果获取异常 将跳转到错误页面;
|
||||
onLoad( (toPageParams) => setToken(toPageParams) )
|
||||
|
||||
// vue mounted 钩子事件
|
||||
onMounted( () => {
|
||||
|
||||
// 获取userId
|
||||
|
||||
$getChannelUserId(Object.assign({jeepayResType: 'channelUserJSON'}, searchToObject())).then( ({bizData}) => {
|
||||
appConfig.channelUserId = bizData.channelUserId;
|
||||
|
||||
// 保存到localStorage
|
||||
if(bizData.channelUserIdCacheKey){
|
||||
storageManage.channelUserId(bizData.channelUserIdCacheKey, bizData.channelUserId)
|
||||
}
|
||||
navigateTo(bizData.channelUserId)
|
||||
|
||||
vdata.bizData = bizData
|
||||
})
|
||||
})
|
||||
|
||||
function searchToObject() {
|
||||
|
||||
if(!window.location.search){
|
||||
return {};
|
||||
}
|
||||
|
||||
var pairs = window.location.search.substring(1).split("&"),
|
||||
result = {},
|
||||
pair,
|
||||
i;
|
||||
for ( i in pairs ) {
|
||||
if ( pairs[i] === "" ) continue;
|
||||
pair = pairs[i].split("=");
|
||||
result[ decodeURIComponent( pair[0] ) ] = decodeURIComponent( pair[1] );
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
function bugbugbug() {
|
||||
vdata.showBizData = true
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
|
||||
<style>
|
||||
</style>
|
||||
1138
jeepay-ui-uapp-cashier/pages/pay/index.vue
Normal file
1119
jeepay-ui-uapp-cashier/pages/pay/lite.vue
Normal file
146
jeepay-ui-uapp-cashier/pages/pay/result.vue
Normal file
@@ -0,0 +1,146 @@
|
||||
<!-- 支付结果页 -->
|
||||
<template>
|
||||
<view class="success-page">
|
||||
|
||||
<view class="success-box u-flex-col u-row-center u-col-center">
|
||||
<view><image class="pay-img" :src="payImg[payState]" mode=""></image></view>
|
||||
<view><text class="notice">{{ payText[payState] }}</text></view>
|
||||
<view><text class="pay-money" v-if="payState === 'success' && orderDetail.total_fee">¥{{ orderDetail.total_fee }}</text></view>
|
||||
<view class="btn-box u-flex u-row-between" v-if="showModal == 'app'">
|
||||
<button class="u-reset-button base-btn" open-type="launchApp" app-parameter="wechat" binderror="launchAppError" >返回APP </button>
|
||||
</view>
|
||||
|
||||
<view class="btn-box u-flex u-row-between" v-if="showModal == 'xcx'">
|
||||
<button class="u-reset-button base-btn" @click="getLos()" >返回 </button>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { mapMutations, mapActions, mapState, mapGetters } from 'vuex';
|
||||
let payTimer = null;
|
||||
const payCount = 5;
|
||||
export default {
|
||||
components: {},
|
||||
data() {
|
||||
return {
|
||||
showModal: 'h5',
|
||||
messageType: '',
|
||||
templateIds: [],
|
||||
wxOpenTags: '',
|
||||
orderDetail: {}, //订单详情
|
||||
orderType: '', //订单类型
|
||||
payText: {
|
||||
fail: '支付失败',
|
||||
success: '支付成功',
|
||||
paying: '查询中...'
|
||||
},
|
||||
payImg: {
|
||||
fail: '/static/syb/order_pay_fail.gif',
|
||||
success: '/static/syb/order_pay_success.gif',
|
||||
paying:'/static/syb/order_paying.gif'
|
||||
},
|
||||
payState: '' //支付状态
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(['subscribeMessageIdsMap'])
|
||||
},
|
||||
onLoad(opt) {
|
||||
var that = this;
|
||||
that.payState = opt.pay_state
|
||||
that.showModal = opt.show_modal
|
||||
console.log(that.showModal,'that.showModal')
|
||||
},
|
||||
methods: {
|
||||
...mapActions(['getCartList']),
|
||||
getLos(){
|
||||
wx.navigateBackMiniProgram({
|
||||
extraData: {
|
||||
name: '半屏小程序返回',
|
||||
status: this.payState
|
||||
},
|
||||
success(res) {
|
||||
// 返回成功
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scopeds>
|
||||
.success-box {
|
||||
text-align: center;
|
||||
background: #fff;
|
||||
width: 750rpx;
|
||||
padding: 40rpx 0;
|
||||
|
||||
.pay-img {
|
||||
width: 130rpx;
|
||||
height: 130rpx;
|
||||
}
|
||||
|
||||
.notice {
|
||||
font-size: 30rpx;
|
||||
|
||||
font-weight: bold;
|
||||
color: rgba(51, 51, 51, 1);
|
||||
line-height: 30rpx;
|
||||
margin-top: 30rpx;
|
||||
}
|
||||
|
||||
.pay-money {
|
||||
font-size: 36rpx;
|
||||
color: #ff3000;
|
||||
font-weight: 600;
|
||||
margin-top: 20rpx;
|
||||
}
|
||||
|
||||
.btn-box {
|
||||
margin-top: 30rpx;
|
||||
// width: 660rpx;
|
||||
|
||||
.base-btn {
|
||||
width: 320rpx;
|
||||
line-height: 70rpx;
|
||||
background: rgba(255, 255, 255, 1);
|
||||
border: 1rpx solid rgba(223, 223, 223, 0.5);
|
||||
border-radius: 35rpx;
|
||||
font-size: 28rpx;
|
||||
|
||||
font-weight: 400;
|
||||
color: rgba(153, 153, 153, 1);
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.again-pay {
|
||||
width: 320rpx;
|
||||
line-height: 70rpx;
|
||||
background: linear-gradient(90deg, rgba(233, 180, 97, 1), rgba(238, 204, 137, 1));
|
||||
box-shadow: 0px 7rpx 6rpx 0px rgba(229, 138, 0, 0.22);
|
||||
border-radius: 35rpx;
|
||||
font-size: 28rpx;
|
||||
|
||||
font-weight: 400;
|
||||
color: rgba(255, 255, 255, 0.8);
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.hot-box {
|
||||
background: #fff;
|
||||
padding: 20rpx;
|
||||
margin-top: 20rpx;
|
||||
|
||||
.hot-title {
|
||||
font-size: 30rpx;
|
||||
|
||||
font-weight: 500;
|
||||
color: rgba(51, 51, 51, 1);
|
||||
height: 80rpx;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
175
jeepay-ui-uapp-cashier/pages/paySuccess/paySuccess.vue
Normal file
@@ -0,0 +1,175 @@
|
||||
<template>
|
||||
<view class="pay-result">
|
||||
<image src="/static/img/success.svg" class="pay-result-icon"></image>
|
||||
<text class="pay-result-err">支付成功</text>
|
||||
<text style="margin-top: 30rpx ; color:#00000059 ;">{{ vdata.member?'会员支付':'普通支付' }}</text>
|
||||
<view class="pay-result-amount">
|
||||
<text class="pay-result-amount-text">金额:<text style="color: #FC0100;">¥</text></text>
|
||||
<text class="pay-result-amount-value">{{ doubleToThousands(vdata.amount) }}</text>
|
||||
</view>
|
||||
|
||||
<view class="ad-wrapper" v-if="vdata.advertUrl" @tap="toH5">
|
||||
<image mode="aspectFill" :src="vdata.advertUrl"></image>
|
||||
</view>
|
||||
<!-- #ifdef MP-WEIXIN -->
|
||||
<button v-if="appConfig.scene == 1069" class="back-btn" :style="{'backgroundColor': vdata.primaryColor || '#F1F1F1'}" open-type="launchApp" :app-parameter="'success'" @error="launchAppError">完 成</button>
|
||||
<button v-else-if="appConfig.scene == 1037" class="back-btn" :style="{'backgroundColor': vdata.primaryColor || '#F1F1F1'}" @click="backMiniFunc">完 成</button>
|
||||
<navigator v-else open-type="exit" target="miniProgram" class="back-btn" :style="{'backgroundColor': vdata.primaryColor || '#F1F1F1'}">完 成</navigator>
|
||||
<!-- #endif -->
|
||||
<!-- #ifdef MP-ALIPAY -->
|
||||
<navigator open-type="exit" target="miniProgram" class="back-btn" :style="{'backgroundColor': vdata.primaryColor || '#F1F1F1'}">完 成</navigator>
|
||||
<!-- #endif -->
|
||||
<!-- #ifndef MP-WEIXIN || MP-ALIPAY -->
|
||||
<view class="back-btn" :style="{'backgroundColor': vdata.primaryColor || '#F1F1F1'}" @click="back">完 成</view>
|
||||
<!-- #endif -->
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { doubleToThousands } from '@/util/amount.js'
|
||||
import { onLoad,onUnload } from '@dcloudio/uni-app'
|
||||
import { reactive } from 'vue'
|
||||
import { $getAdvert } from '@/http/apiManager.js'
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
import theme from '@/config/theme.js'
|
||||
|
||||
const vdata = reactive({
|
||||
amount: '0', // 订单金额
|
||||
payOrderId: '', // 订单号
|
||||
doubleToThousands: doubleToThousands(),
|
||||
primaryColor: '',
|
||||
advertUrl: ''
|
||||
})
|
||||
|
||||
onLoad((params) => {
|
||||
console.log(appConfig.video,'appConfigvideo')
|
||||
vdata.amount = params.amount
|
||||
vdata.primaryColor = theme.changeColors()
|
||||
vdata.member = params.member
|
||||
|
||||
if (params.payOrderId) {
|
||||
vdata.payOrderId = params.payOrderId
|
||||
}
|
||||
sphGet()
|
||||
|
||||
$getAdvert().then(({bizData}) => {
|
||||
if(bizData) {
|
||||
vdata.advertUrl = bizData.imgUrl || ''
|
||||
vdata.linkUrl = bizData.linkUrl || ''
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log(err);
|
||||
})
|
||||
})
|
||||
//视频号数据
|
||||
function sphGet(){
|
||||
if(appConfig.currentPageType == 'alipayLite' || appConfig.currentPageType == 'alipayH5' || appConfig.video == undefined || appConfig.video == null){
|
||||
|
||||
}else{alipayLite
|
||||
uni.openChannelsActivity({
|
||||
finderUserName: appConfig.video.uniqueId,//视频号ID
|
||||
feedId: appConfig.video.exportId,//视频ID
|
||||
complete (res) {
|
||||
console.log(res)
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
}
|
||||
function back() {
|
||||
uni.navigateBack()
|
||||
}
|
||||
function backMiniFunc() {
|
||||
uni.navigateBackMiniProgram({
|
||||
extraData: {
|
||||
'amount': vdata.amount,
|
||||
'payOrderId': vdata.payOrderId
|
||||
},
|
||||
success(res) {
|
||||
console.log('返回成功')
|
||||
}
|
||||
})
|
||||
}
|
||||
const toH5 = ()=>{
|
||||
if(!vdata.linkUrl) return
|
||||
uni.navigateTo({
|
||||
url: '/pages/H5/H5?url='+ vdata.linkUrl
|
||||
})
|
||||
}
|
||||
onUnload(()=>{
|
||||
console.log('页面卸载');
|
||||
uni.$emit('onRechargeSuccess',true)
|
||||
})
|
||||
</script>
|
||||
<style lang="scss">
|
||||
.pay-result {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
}
|
||||
.pay-result-icon {
|
||||
padding-top: 120rpx;
|
||||
width: 240rpx;
|
||||
height: 166rpx;
|
||||
}
|
||||
.pay-result-err {
|
||||
// padding-top: 30rpx;
|
||||
font-size: 34rpx;
|
||||
font-weight: 600;
|
||||
color: #242526;
|
||||
}
|
||||
.pay-result-msg {
|
||||
width: 75%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
padding-top: 70rpx;
|
||||
color: #999999;
|
||||
|
||||
.msg {
|
||||
line-height: 42rpx;
|
||||
}
|
||||
}
|
||||
.pay-result-amount {
|
||||
padding-top: 34rpx;
|
||||
|
||||
.pay-result-amount-text{
|
||||
font-size: 28rpx;
|
||||
font-family: HiraginoSansGB-W3, HiraginoSansGB;
|
||||
color: #303132;
|
||||
}
|
||||
.pay-result-amount-value {
|
||||
font-size: 36rpx;
|
||||
font-family: HiraginoSansGB-W3, HiraginoSansGB;
|
||||
font-weight: 600;
|
||||
color: #FC0100;
|
||||
}
|
||||
}
|
||||
.back-btn {
|
||||
position: fixed;
|
||||
bottom: 260rpx;
|
||||
width: 350rpx;
|
||||
height: 80rpx;
|
||||
border-radius: 6rpx 6rpx 6rpx 6rpx;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
color: #FFFFFF;
|
||||
}
|
||||
.ad-wrapper{
|
||||
margin: 50rpx auto;
|
||||
margin-top: 100rpx;
|
||||
width: 700rpx;
|
||||
min-height: 380rpx;
|
||||
display: flex;
|
||||
border-radius: 10rpx;
|
||||
justify-content: center;
|
||||
overflow: hidden;
|
||||
image {
|
||||
width: 100%;
|
||||
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
167
jeepay-ui-uapp-cashier/pages/paySuccess/redSuccess.vue
Normal file
@@ -0,0 +1,167 @@
|
||||
<template>
|
||||
<view class="page-view" :style="{'background-image': `url(${vdata.sysBgUrl})`}" >
|
||||
<view class="page-text-title" @click="goToPreviousPage()">
|
||||
<view> <返回 </view>
|
||||
</view>
|
||||
<view class="page-view-weapper" :style="{'background-image': `url(${vdata.sysBgUrl2})`}">
|
||||
<view class="price-box">
|
||||
<text class="price-ico">¥</text>
|
||||
<text class="price-text">{{vdata.rewardAmt}}</text>
|
||||
</view>
|
||||
<view class="order-text">
|
||||
<view class="order-text-box">
|
||||
<text class="price-ico">订单金额</text>
|
||||
<text class="price-text">¥{{vdata.transAmt}}</text>
|
||||
</view>
|
||||
<view class="order-text-box">
|
||||
<text class="price-ico">红包抵扣</text>
|
||||
<text class="price-text">¥{{vdata.changeAmt}}</text>
|
||||
</view>
|
||||
<view class="order-text-box order-text-box-price">
|
||||
<text class="price-ico">实际支付</text>
|
||||
<text class="price-text">¥{{vdata.findAmt}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
<script setup>
|
||||
import { doubleToThousands } from '@/util/amount.js'
|
||||
import { onLoad,onUnload } from '@dcloudio/uni-app'
|
||||
import { reactive } from 'vue'
|
||||
import { $getAdvert,$getMarketingConfig,$getDiscountDetail } from '@/http/apiManager.js'
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
import theme from '@/config/theme.js'
|
||||
|
||||
const vdata = reactive({
|
||||
amount: '0', // 订单金额
|
||||
payOrderId: '', // 订单号
|
||||
doubleToThousands: doubleToThousands(),
|
||||
primaryColor: '',
|
||||
advertUrl: '',
|
||||
sysBgUrl:"",
|
||||
sysBgUrl2:"",
|
||||
rewardAmt:0,
|
||||
transAmt:0,
|
||||
changeAmt:0,
|
||||
findAmt:0,
|
||||
})
|
||||
|
||||
onLoad((params) => {
|
||||
//获取平台红包功能
|
||||
// getMarketingConfig();
|
||||
// vdata.amount = params.amount
|
||||
vdata.primaryColor = theme.changeColors()
|
||||
// vdata.member = params.member
|
||||
console.log(params,'paramsparamsparams')
|
||||
|
||||
if (params.payOrderId) {
|
||||
vdata.payOrderId = params.payOrderId
|
||||
}
|
||||
vdata.sysBgUrl = appConfig.marketingConfig.sysBgUrl
|
||||
vdata.sysBgUrl2 = appConfig.marketingConfig.sysBgUrl2
|
||||
|
||||
$getDiscountDetail(vdata.payOrderId).then(({bizData}) => {
|
||||
|
||||
//订单金额
|
||||
vdata.transAmt = (bizData.order.amount/100).toFixed(2)
|
||||
//红包抵扣
|
||||
vdata.changeAmt = (bizData.order.discountAmt/100).toFixed(2)
|
||||
//实际支付
|
||||
vdata.findAmt = (bizData.order.findAmt/100).toFixed(2)
|
||||
if(bizData.redPacketInfo){
|
||||
//红包奖励
|
||||
vdata.rewardAmt = (bizData.redPacketInfo.rewardAmt/100).toFixed(2)
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log(err);
|
||||
})
|
||||
})
|
||||
function back() {
|
||||
uni.navigateBack()
|
||||
}
|
||||
function getMarketingConfig(){
|
||||
$getMarketingConfig('marketingConfig').then(({bizData}) => {
|
||||
vdata.sysBgUrl = bizData.marketingConfig.sysBgUrl
|
||||
// console.log(vdata.sysBgUrl,'vdata.sysBgUrl')
|
||||
vdata.sysBgUrl2 = bizData.marketingConfig.sysBgUrl2
|
||||
})
|
||||
}
|
||||
// 点击按钮时触发的事件处理函数
|
||||
function goToPreviousPage() {
|
||||
uni.navigateTo({
|
||||
url: '/pages/payway/index'
|
||||
})
|
||||
}
|
||||
onUnload(()=>{
|
||||
console.log('页面卸载');
|
||||
uni.$emit('onRechargeSuccess',true)
|
||||
})
|
||||
</script>
|
||||
<style lang="scss">
|
||||
.page-text-title{
|
||||
position: absolute;
|
||||
color: #090909;
|
||||
font-family: 600;
|
||||
font-size: 36rpx;
|
||||
width: 100%;
|
||||
top: 5%;
|
||||
left: 5%;
|
||||
}
|
||||
//https://syb-jq-public.oss-cn-hangzhou.aliyuncs.com/oem/5999e9eb-6839-4608-869c-f6f39cef7bc1.png
|
||||
// https://syb-jq-public.oss-cn-hangzhou.aliyuncs.com/oem/a86ccec4-ed2a-46bc-b5b5-bb42b9e8939d.png
|
||||
// https://syb-jq-public.oss-cn-hangzhou.aliyuncs.com/oem/eecc2da4-9e9e-4ee2-a206-900e38298224.png
|
||||
.page-view{
|
||||
// background-image: url('https://syb-jq-public.oss-cn-hangzhou.aliyuncs.com/oem/a86ccec4-ed2a-46bc-b5b5-bb42b9e8939d.png') ;
|
||||
background-size: cover;
|
||||
height: 100vh;
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
.page-view-weapper{
|
||||
// background-image: url('https://syb-jq-public.oss-cn-hangzhou.aliyuncs.com/oem/eecc2da4-9e9e-4ee2-a206-900e38298224.png') ;
|
||||
// background-image: url('https://syb-jq-public.oss-cn-hangzhou.aliyuncs.com/oem/ae73fd83-89dc-4b47-838e-6d67b150f7ee.png') ;
|
||||
background-size: cover;
|
||||
height: 50vh;
|
||||
width: 50vh;
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
z-index: 9999;
|
||||
top: 30px;
|
||||
}
|
||||
.price-box{
|
||||
// margin-top: 10%;
|
||||
position: absolute;
|
||||
top: 10%;
|
||||
background: linear-gradient(to right, #FF7300, #FF312B); /* 设置线性渐变色 */
|
||||
-webkit-background-clip: text; /* 使用文本作为背景剪辑 */
|
||||
color: transparent; /* 隐藏实际文本颜色 */
|
||||
.price-ico{
|
||||
font-size: 100rpx;
|
||||
font-weight: 600;
|
||||
}
|
||||
.price-text{
|
||||
font-size: 140rpx;
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
.order-text{
|
||||
margin-top: 8%;
|
||||
.order-text-box{
|
||||
font-size: 35rpx;
|
||||
color: #CD5E18;
|
||||
text{
|
||||
padding: 20rpx 100rpx;
|
||||
}
|
||||
}
|
||||
.order-text-box-price{
|
||||
color: #9F4A14;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
1292
jeepay-ui-uapp-cashier/pages/payment/index.vue
Normal file
1119
jeepay-ui-uapp-cashier/pages/payment/lite.vue
Normal file
146
jeepay-ui-uapp-cashier/pages/payment/result.vue
Normal file
@@ -0,0 +1,146 @@
|
||||
<!-- 支付结果页 -->
|
||||
<template>
|
||||
<view class="success-page">
|
||||
|
||||
<view class="success-box u-flex-col u-row-center u-col-center">
|
||||
<view><image class="pay-img" :src="payImg[payState]" mode=""></image></view>
|
||||
<view><text class="notice">{{ payText[payState] }}</text></view>
|
||||
<view><text class="pay-money" v-if="payState === 'success' && orderDetail.total_fee">¥{{ orderDetail.total_fee }}</text></view>
|
||||
<view class="btn-box u-flex u-row-between" v-if="showModal == 'app'">
|
||||
<button class="u-reset-button base-btn" open-type="launchApp" app-parameter="wechat" binderror="launchAppError" >返回APP </button>
|
||||
</view>
|
||||
|
||||
<view class="btn-box u-flex u-row-between" v-if="showModal == 'xcx'">
|
||||
<button class="u-reset-button base-btn" @click="getLos()" >返回 </button>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { mapMutations, mapActions, mapState, mapGetters } from 'vuex';
|
||||
let payTimer = null;
|
||||
const payCount = 5;
|
||||
export default {
|
||||
components: {},
|
||||
data() {
|
||||
return {
|
||||
showModal: 'h5',
|
||||
messageType: '',
|
||||
templateIds: [],
|
||||
wxOpenTags: '',
|
||||
orderDetail: {}, //订单详情
|
||||
orderType: '', //订单类型
|
||||
payText: {
|
||||
fail: '支付失败',
|
||||
success: '支付成功',
|
||||
paying: '查询中...'
|
||||
},
|
||||
payImg: {
|
||||
fail: '/static/syb/order_pay_fail.gif',
|
||||
success: '/static/syb/order_pay_success.gif',
|
||||
paying:'/static/syb/order_paying.gif'
|
||||
},
|
||||
payState: '' //支付状态
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(['subscribeMessageIdsMap'])
|
||||
},
|
||||
onLoad(opt) {
|
||||
var that = this;
|
||||
that.payState = opt.pay_state
|
||||
that.showModal = opt.show_modal
|
||||
console.log(that.showModal,'that.showModal')
|
||||
},
|
||||
methods: {
|
||||
...mapActions(['getCartList']),
|
||||
getLos(){
|
||||
wx.navigateBackMiniProgram({
|
||||
extraData: {
|
||||
name: '半屏小程序返回',
|
||||
status: this.payState
|
||||
},
|
||||
success(res) {
|
||||
// 返回成功
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scopeds>
|
||||
.success-box {
|
||||
text-align: center;
|
||||
background: #fff;
|
||||
width: 750rpx;
|
||||
padding: 40rpx 0;
|
||||
|
||||
.pay-img {
|
||||
width: 130rpx;
|
||||
height: 130rpx;
|
||||
}
|
||||
|
||||
.notice {
|
||||
font-size: 30rpx;
|
||||
|
||||
font-weight: bold;
|
||||
color: rgba(51, 51, 51, 1);
|
||||
line-height: 30rpx;
|
||||
margin-top: 30rpx;
|
||||
}
|
||||
|
||||
.pay-money {
|
||||
font-size: 36rpx;
|
||||
color: #ff3000;
|
||||
font-weight: 600;
|
||||
margin-top: 20rpx;
|
||||
}
|
||||
|
||||
.btn-box {
|
||||
margin-top: 30rpx;
|
||||
// width: 660rpx;
|
||||
|
||||
.base-btn {
|
||||
width: 320rpx;
|
||||
line-height: 70rpx;
|
||||
background: rgba(255, 255, 255, 1);
|
||||
border: 1rpx solid rgba(223, 223, 223, 0.5);
|
||||
border-radius: 35rpx;
|
||||
font-size: 28rpx;
|
||||
|
||||
font-weight: 400;
|
||||
color: rgba(153, 153, 153, 1);
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.again-pay {
|
||||
width: 320rpx;
|
||||
line-height: 70rpx;
|
||||
background: linear-gradient(90deg, rgba(233, 180, 97, 1), rgba(238, 204, 137, 1));
|
||||
box-shadow: 0px 7rpx 6rpx 0px rgba(229, 138, 0, 0.22);
|
||||
border-radius: 35rpx;
|
||||
font-size: 28rpx;
|
||||
|
||||
font-weight: 400;
|
||||
color: rgba(255, 255, 255, 0.8);
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.hot-box {
|
||||
background: #fff;
|
||||
padding: 20rpx;
|
||||
margin-top: 20rpx;
|
||||
|
||||
.hot-title {
|
||||
font-size: 30rpx;
|
||||
|
||||
font-weight: 500;
|
||||
color: rgba(51, 51, 51, 1);
|
||||
height: 80rpx;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
209
jeepay-ui-uapp-cashier/pages/payway/components/SelectedPay.vue
Normal file
@@ -0,0 +1,209 @@
|
||||
<template>
|
||||
<uni-popup ref="popup" type="bottom" :safe-area="false" >
|
||||
|
||||
<view class="list-wrapper">
|
||||
<view class="list-top">
|
||||
<text>支付方式</text>
|
||||
</view>
|
||||
<view class="store" >
|
||||
<view class="store-inner-slot" v-for="(item,i) in props.list" @tap="selectFunc(item,i)" >
|
||||
<view class="left">
|
||||
<image class="left-img" :src="item.img" mode="scaleToFill" />
|
||||
<text class="left-text">
|
||||
{{item.name}}
|
||||
<text class="left-price" v-if="item.value == 5">(可用{{ item.price}}元)</text>
|
||||
</text>
|
||||
</view>
|
||||
<view class="more-selected">
|
||||
<image :src="item.checked ? '/static/img/success.png' : '/static/img/unselected.png'" mode="scaleToFill" />
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="footer-wrapper">
|
||||
<view class="footer-main">
|
||||
<view class="footer-button">
|
||||
<!-- <view class="flex-center" hover-class="touch-button" @tap="close">取消</view> -->
|
||||
<view @tap="confirmFunc" class="confirm flex-center" hover-class="touch-button">确认</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</uni-popup>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref } from "vue";
|
||||
const props = defineProps({
|
||||
list: {
|
||||
type: Array,
|
||||
},
|
||||
});
|
||||
const emits = defineEmits(["choiceValue"]);
|
||||
const popup = ref();
|
||||
console.log(props.list,'propspropspropsprops')
|
||||
const open = () => {
|
||||
popup.value.open();
|
||||
};
|
||||
// const searchText = ref("");
|
||||
// const filerBank = () => {
|
||||
// return props.list.filter((v) => v[props.value].includes(searchText.value));
|
||||
// };
|
||||
const choice = (val) => {
|
||||
popup.value.close();
|
||||
};
|
||||
function selectFunc(item,i){
|
||||
var list = props.list
|
||||
list.forEach((item,key)=>{
|
||||
if(key == i){
|
||||
item.checked = true
|
||||
}else{
|
||||
item.checked = false
|
||||
}
|
||||
})
|
||||
emits("choiceValue", i);
|
||||
props.list = list
|
||||
}
|
||||
|
||||
function confirmFunc(){
|
||||
emits("choiceValue", null,1);
|
||||
}
|
||||
defineExpose({ open });
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
|
||||
.list-wrapper {
|
||||
// display: flex;
|
||||
// flex-direction: column;
|
||||
border-radius: 16rpx 16rpx 0 0;
|
||||
background-color: #fafafa;
|
||||
max-height: 1000rpx;
|
||||
padding: 30rpx;
|
||||
position: relative;
|
||||
bottom: 0;
|
||||
.search-input {
|
||||
input {
|
||||
border-bottom: 1px solid #ccc;
|
||||
text-indent: 1rem;
|
||||
padding: 10rpx 0;
|
||||
}
|
||||
}
|
||||
.list-mian {
|
||||
flex: 1;
|
||||
overflow-y: scroll;
|
||||
margin-top: 20rpx;
|
||||
.list-item {
|
||||
margin: 10rpx 0;
|
||||
padding: 10rpx;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
.store-inner-slot {
|
||||
position: relative;
|
||||
margin: 20rpx -10rpx;
|
||||
background-color: #fff;
|
||||
align-items: center;
|
||||
// padding: 0 40rpx;
|
||||
// height: 120rpx;
|
||||
font-size: 30rpx;
|
||||
border-radius: 10rpx;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
padding: 24rpx;
|
||||
.left {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.right {
|
||||
color: #999999;
|
||||
}
|
||||
}
|
||||
|
||||
.left-img{
|
||||
width: 50rpx;
|
||||
height: 50rpx;
|
||||
margin-right: 6rpx;
|
||||
margin-top: 6rpx;
|
||||
}
|
||||
.left-text{
|
||||
|
||||
font-family: PingFang SC-Regular;
|
||||
font-size: 32rpx;
|
||||
font-weight: 400;
|
||||
.left-price{
|
||||
color: #8F97A9;
|
||||
font-size: 24rpx;
|
||||
};
|
||||
}
|
||||
.more-selected {
|
||||
width: 60rpx;
|
||||
height: 60rpx;
|
||||
// border-radius: 50%;
|
||||
// margin-right: 20rpx;
|
||||
// border: 2rpx solid rgba(217, 217, 217, 1);
|
||||
image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
// .store {
|
||||
// position: relative;
|
||||
// margin: 20rpx;
|
||||
// border-radius: 20rpx;
|
||||
// background-color: #fafafa;
|
||||
// display: flex;
|
||||
// justify-content: flex-start;
|
||||
// align-items: center;
|
||||
// padding: 0 40rpx;
|
||||
// // height: 120rpx;
|
||||
// font-size: 30rpx;
|
||||
// }
|
||||
|
||||
.footer-wrapper {
|
||||
// height: 186rpx;
|
||||
margin-top: 150rpx;
|
||||
.footer-main {
|
||||
position: fixed;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
// border-top: 1rpx solid #ededed;
|
||||
.tips {
|
||||
margin: 20rpx;
|
||||
text-align: center;
|
||||
font-size: 27rpx;
|
||||
color: #a6a6a6;
|
||||
}
|
||||
.footer-button {
|
||||
padding: 0 30rpx;
|
||||
margin-top: 30rpx;
|
||||
padding-bottom: 30rpx;
|
||||
display: flex;
|
||||
|
||||
justify-content: space-between;
|
||||
view {
|
||||
text-align: center;
|
||||
padding: 20rpx 0px;
|
||||
font-size: 50rpx;
|
||||
width: 100%;
|
||||
// height: 110rpx;
|
||||
font-size: 33rpx;
|
||||
font-weight: 500;
|
||||
color: rgba(0, 0, 0, 0.5);
|
||||
border-radius: 20rpx;
|
||||
background-color: #f7f7f7;
|
||||
}
|
||||
.confirm {
|
||||
color: #fff;
|
||||
background: #2980fd;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.list-top{
|
||||
margin-bottom: 40rpx;
|
||||
font-weight: 600;
|
||||
}
|
||||
</style>
|
||||
899
jeepay-ui-uapp-cashier/pages/payway/index.vue
Normal file
@@ -0,0 +1,899 @@
|
||||
<template>
|
||||
<view class="content">
|
||||
<!-- <view class="content-top-bg" :style="{'backgroundColor': vdata.primaryColor}"></view> -->
|
||||
<view class="payment">
|
||||
<view class="payment-mchName" @tap="advancedFunc">
|
||||
<view style="display: contents;">
|
||||
<image src="/static/img/store.svg" mode="scaleToFill" class="payment-mchName-img" />
|
||||
<view style="display: grid;margin-left: 16rpx;">
|
||||
<text class="payment-mchName1">{{ vdata.payOrderInfo.mchName }}</text>
|
||||
<view class="payment-mchName2">
|
||||
<text class="payment-mchName2-text1">门店</text>
|
||||
<text class="payment-mchName2-text2">{{vdata.payOrderInfo.storeName}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="payment-divider"></view>
|
||||
<view class="payment-amountTips">
|
||||
<view class="desc1 ">付款金额:</view>
|
||||
<view class="desc2 " v-if="!vdata.buyerRemark" @tap="showRemarkModel"><span v-if="vdata.isForceReamrk" style='color: #FF0000;'>*</span>添加备注</view>
|
||||
<text class="desc2 buyer-remark" v-else @tap="showRemarkModel">
|
||||
{{ vdata.buyerRemark }}
|
||||
<text :style="{ 'padding-left': '6rpx'}">修改</text>
|
||||
</text>
|
||||
</view>
|
||||
<view class="payment-amount" >
|
||||
<text class="payment-amount-rmb">¥</text>
|
||||
<text class="payment-amount-value">{{ doubleToThousands(vdata.amount) }}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="payment-amountTips-price" >
|
||||
<!-- -->
|
||||
<view class="desc3">
|
||||
<view v-if="vdata.redPacketIsOpen">
|
||||
<text class="desc3-text1" >红包</text><text class="desc3-text2">可用余额:¥{{(appConfig.redbalance / 100).toFixed(2)}} </text>
|
||||
</view>
|
||||
</view>
|
||||
<!-- <view class="desc4" ><text class="desc4-text1" >实付金额</text><text class="desc4-text2">¥{{doubleToThousands(vdata.originAmount) }}</text></view> -->
|
||||
|
||||
<!-- <view class="payment-text-amount txt">实付金额:<text></text></view> -->
|
||||
</view>
|
||||
|
||||
<!-- <view class="pay-div-type">
|
||||
<radio-group @change="radioChange" style="width: 100%;">
|
||||
<view class="radio-group-box" style="display: flex;" v-if="appConfig.pageType == 'wechatLite'" >
|
||||
<view class="radio-group-name " >
|
||||
<img src="https://syb-jq-public.oss-cn-hangzhou.aliyuncs.com/oem/6e4f3ca5-a334-4af4-a57c-63fca61c95d7.svg" alt="">
|
||||
<text class="radio-group-name1">微信</text>
|
||||
</view>
|
||||
<view class="radio-group-radio " >
|
||||
<radio color="#1678FF" value="1" :checked="1 == vdata.current" />
|
||||
</view>
|
||||
</view>
|
||||
<view class="radio-group-box" style="display: flex;" v-if="appConfig.pageType == 'alipayLite'">
|
||||
<view class="radio-group-name " >
|
||||
<img src="https://syb-jq-public.oss-cn-hangzhou.aliyuncs.com/oem/0e4f0b6a-e96e-45bf-a5bb-127c64c3396a.svg" alt="">
|
||||
<text class="radio-group-name1">支付宝</text>
|
||||
</view>
|
||||
<view class="radio-group-radio " >
|
||||
<radio color="#1678FF" value="2" :checked="2 == vdata.current" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="radio-group-box" style="display: flex;" v-if="appConfig.redPacketIsOpen" >
|
||||
<view class="radio-group-name " >
|
||||
<img src="https://syb-jq-public.oss-cn-hangzhou.aliyuncs.com/notice/d3be6339-5abe-415b-981c-3568ebd66f57.png" alt="">
|
||||
<text class="radio-group-name1">红包</text>
|
||||
<text class="radio-group-name-price" >(可用{{appConfig.redbalance}}元)</text>
|
||||
</view>
|
||||
<view class="radio-group-radio " >
|
||||
<radio color="#1678FF" value="3" :checked="3 == vdata.current" />
|
||||
</view>
|
||||
</view>
|
||||
</radio-group>
|
||||
</view> -->
|
||||
|
||||
<!-- v-if="!vdata.payOrderInfo['fixedFlag']" -->
|
||||
<view class="payment-keyboard" >
|
||||
<!-- <text class="buyer-remark" v-if="!vdata.buyerRemark" @tap="showRemarkModel">添加备注</text> -->
|
||||
<!-- <text class="buyer-remark" v-else @tap="showRemarkModel">
|
||||
{{ vdata.buyerRemark }}
|
||||
<text :style="{ 'padding-left': '6rpx'}">修改</text>
|
||||
</text> -->
|
||||
<view class="payment-text" v-if="vdata.isAdsOpen">
|
||||
|
||||
<view class="payment-text-guanggao txt" @click="getadsName()" >
|
||||
<!-- <scroll-view class="scroll-view" scroll-x="true" :scroll-left="vdata.scrollLeft" autoplay @scrolltolower="scrollToLower"> -->
|
||||
<view class="scroll-content" >
|
||||
{{appConfig.marketingConfig.adsName}}
|
||||
</view>
|
||||
<!-- <text ></text> -->
|
||||
<!-- </scroll-view> -->
|
||||
</view>
|
||||
<!-- <view class="payment-text-amount txt">实付金额:<text>¥{{doubleToThousands(vdata.originAmount) }}</text></view> -->
|
||||
</view>
|
||||
<syb-keyboard
|
||||
ref="sybKeyboardRef"
|
||||
:primaryColor="vdata.primaryColor"
|
||||
@change="onChange"
|
||||
@pay="getSybPayType">
|
||||
</syb-keyboard>
|
||||
</view>
|
||||
<!-- <view v-if="vdata.payOrderInfo['fixedFlag']" class="payment-no-keyboard" @tap="pay">付 款</view> -->
|
||||
|
||||
<view v-if="vdata.remarkVisible" class="remark-model">
|
||||
<view class="remark-content">
|
||||
<text class="remark-content-title" >添加备注</text>
|
||||
<input v-model="vdata.modelRemark" :focus="vdata.remarkVisible" maxlength="40" placeholder="最多输入20个字" class="remark-content-body" />
|
||||
<view class="remark-content-btn">
|
||||
<text class="btn-cancel" @tap.stop="closeRemarkModel">取消</text>
|
||||
<text class="btn-confirm" :style="{'backgroundColor': '#1678FF', 'borderColor': '#ffffff'}" @tap.stop="confirmRemark">确认</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- <SelectedPay ref="sybCodePay" :list="vdata.payTypeList" @choiceValue="updataBank" /> -->
|
||||
|
||||
<!-- 选择支付 接口 -->
|
||||
<!-- <JeepayPopupListSelect style="background-color: #fff;" ref="selectIfcodeRef" title='支付方式' :isCheckbox="false" :reqTableDataFunc="reqTableDataByIfcodeFunc"
|
||||
:fields="{ key: 'value', left: 'name', right: 'value', img: 'img' }" @confirm="confirmIfCode">
|
||||
|
||||
|
||||
</JeepayPopupListSelect> -->
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { onMounted, reactive, ref } from 'vue'
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import { $getPayOrderInfo, $getPayPackage,$getMarketingConfig,$getCalcDiscount } from '@/http/apiManager.js'
|
||||
import { doubleToThousands } from '@/util/amount.js'
|
||||
import { toErrPageFunc } from '@/util/toErrorPageUtil.js'
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
import theme from '@/config/theme.js'
|
||||
// import SelectedPay from './components/SelectedPay.vue'
|
||||
import paywayCallFunc from '@/pages/payway/payway.js'
|
||||
|
||||
const sybCodePay = ref()
|
||||
const sybKeyboardRef = ref()
|
||||
const selectIfcodeRef = ref()
|
||||
|
||||
const vdata = reactive({
|
||||
scrollLeft: 0, // 滚动位置
|
||||
scrollSpeed: 2, // 滚动速度,单位px/ms
|
||||
scrollInterval: null, // 定时器ID
|
||||
payTypeList:[] as any,
|
||||
typeItems: [{
|
||||
img:"/static/img/wechat.png",
|
||||
value: 1,
|
||||
name: '微信支付',
|
||||
checked: false,
|
||||
},{
|
||||
img:"/static/img/wechat.png",
|
||||
value: 2,
|
||||
name: '微信H5',
|
||||
checked: false,
|
||||
},{
|
||||
img:"/static/payIcon/zfb.png",
|
||||
value: 3,
|
||||
name: '支付宝支付',
|
||||
checked: false,
|
||||
},{
|
||||
img:"/static/payIcon/zfb.png",
|
||||
value: 4,
|
||||
name: '支付宝H5',
|
||||
checked: false,
|
||||
},{
|
||||
img:"/static/img/payred.png",
|
||||
value: 5,
|
||||
name: '红包',
|
||||
checked: false,
|
||||
price: '',
|
||||
},
|
||||
],
|
||||
addIfCodeList:{} as any,
|
||||
isAdsOpen:false,
|
||||
redPacketIsOpen:false,
|
||||
current: 0,
|
||||
primaryColor: '',
|
||||
originAmount: '0',
|
||||
amount: '0',
|
||||
buyerRemark: '', // 买家备注
|
||||
modelRemark: '', // 弹层显示备注
|
||||
remarkVisible: false,
|
||||
doubleToThousands: doubleToThousands(),
|
||||
payOrderInfo: {},
|
||||
calcDiscount:{},
|
||||
storeId:'',
|
||||
clearStorageFlag: 0, //显示清空缓存的提示
|
||||
isForceReamrk:false,
|
||||
}) as any
|
||||
|
||||
onLoad(() => {
|
||||
|
||||
vdata.amount = '0'
|
||||
vdata.primaryColor = theme.changeColors()
|
||||
|
||||
|
||||
// #ifdef H5
|
||||
console.log(111111111111111111111111111111111111111)
|
||||
//解决H5的刷新问题
|
||||
if(!appConfig.tokenValue){ // 不存在 则需要跳转到首页再次放置 获取userID等信息。
|
||||
|
||||
window.location.href = '/cashier/pages/hub/default?' + appConfig.tokenKey + "=" + window.sessionStorage.getItem(appConfig.tokenKey)
|
||||
return false;
|
||||
}
|
||||
// #endif
|
||||
// 获取订单信息
|
||||
// getOrderInfo()
|
||||
|
||||
})
|
||||
onMounted(() => {
|
||||
getOrderInfo()
|
||||
})
|
||||
function getPayType(){
|
||||
const typeItems = vdata.typeItems
|
||||
vdata.payTypeList = [];
|
||||
console.log(appConfig.redPacketIsOpen,'appConfigredPacketIsOpen')
|
||||
if(!appConfig.redPacketIsOpen){
|
||||
delete typeItems[4]
|
||||
}
|
||||
if(appConfig.currentPageType == 'wechatLite'){
|
||||
delete typeItems[1]
|
||||
delete typeItems[2]
|
||||
delete typeItems[3]
|
||||
}
|
||||
if(appConfig.currentPageType == 'wechatH5'){
|
||||
delete typeItems[0]
|
||||
delete typeItems[2]
|
||||
delete typeItems[3]
|
||||
}
|
||||
if(appConfig.currentPageType == 'alipayLite'){
|
||||
delete typeItems[0]
|
||||
delete typeItems[1]
|
||||
delete typeItems[3]
|
||||
}
|
||||
// return uni.showToast({
|
||||
// title: appConfig.currentPageType,
|
||||
// icon: 'none'
|
||||
// })
|
||||
if(appConfig.currentPageType == 'alipayH5'){
|
||||
delete typeItems[0]
|
||||
delete typeItems[1]
|
||||
delete typeItems[2]
|
||||
}
|
||||
console.log(typeItems,'codePay')
|
||||
typeItems.forEach(function(item,index){
|
||||
if(index == 4){
|
||||
item.price = appConfig.redbalance
|
||||
}
|
||||
if(appConfig.currentPageType == 'wechatLite' || appConfig.currentPageType == 'wechatH5'){
|
||||
if(item.value == 3 || item.value == 4){
|
||||
|
||||
}else{
|
||||
vdata.payTypeList.push(item)
|
||||
}
|
||||
}else if(appConfig.currentPageType == 'alipayLite' || appConfig.currentPageType == 'alipayH5'){
|
||||
if(item.value == 0 || item.value == 1){
|
||||
|
||||
}else{
|
||||
vdata.payTypeList.push(item)
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
if(typeItems.length){
|
||||
typeItems[0].checked = true
|
||||
}
|
||||
}
|
||||
function updataBank (index,type=0) {
|
||||
console.log(type,'typetype')
|
||||
if(type == 1){
|
||||
pay()
|
||||
return false;
|
||||
}
|
||||
if(vdata.payTypeList[index].value == 5){
|
||||
if(appConfig.redPacketIsOpen){
|
||||
getCalcDiscount(vdata.amount)
|
||||
}else{
|
||||
vdata.originAmount = vdata.amount
|
||||
}
|
||||
}
|
||||
}
|
||||
function startAutoScroll() {
|
||||
if (vdata.scrollInterval) {
|
||||
clearInterval(vdata.scrollInterval);
|
||||
}
|
||||
const contentWidth = uni.upx2px(375) * 3; // 假设内容宽度是屏幕宽度的三倍,这里需要根据实际情况调整
|
||||
vdata.scrollInterval = setInterval(() => {
|
||||
if (vdata.scrollLeft < contentWidth) {
|
||||
vdata.scrollLeft += vdata.scrollSpeed;
|
||||
} else {
|
||||
vdata.scrollLeft = 0;
|
||||
}
|
||||
}, 100); // 每100ms滚动一次,可以根据需要调整
|
||||
}
|
||||
function stopAutoScroll() {
|
||||
clearInterval(vdata.scrollInterval);
|
||||
vdata.scrollInterval = null;
|
||||
}
|
||||
function scrollToLower(){
|
||||
vdata.scrollLeft = 0;
|
||||
}
|
||||
function getSybPayType(){
|
||||
if(vdata.amount <= 0) {
|
||||
return uni.showToast({
|
||||
title: '金额必须大于0',
|
||||
icon: 'none'
|
||||
})
|
||||
return false;
|
||||
}
|
||||
if(vdata.payTypeList.length <= 1){
|
||||
pay()
|
||||
return false;
|
||||
}else{
|
||||
sybCodePay.value.open();
|
||||
}
|
||||
}
|
||||
// 选择支付通道
|
||||
function confirmIfCode (selected) {
|
||||
selectIfcodeRef.value.close()
|
||||
}
|
||||
|
||||
function radioChange(evt) {
|
||||
console.log(evt.target.value,'evt')
|
||||
vdata.current = evt.target.value;
|
||||
}
|
||||
|
||||
// 输入金额
|
||||
function onChange(e: any) {
|
||||
if(vdata.payOrderInfo['fixedFlag']){
|
||||
return false;
|
||||
}
|
||||
vdata.amount = e
|
||||
if(appConfig.redPacketIsOpen){
|
||||
getCalcDiscount(e)
|
||||
}else{
|
||||
vdata.originAmount = e
|
||||
}
|
||||
}
|
||||
function getadsName(){
|
||||
if(!appConfig.marketingConfig.isAdsOpen){
|
||||
return false;
|
||||
}
|
||||
uni.navigateTo({
|
||||
url: '/pages/H5/H5?url='+ appConfig.marketingConfig.adsUrl
|
||||
})
|
||||
}
|
||||
//获取红包信息
|
||||
function getMarketingConfig(storeId){
|
||||
$getMarketingConfig('marketingConfig',storeId).then(({bizData}) => {
|
||||
vdata.redPacketIsOpen = bizData.marketingConfig.isOpen
|
||||
console.log(bizData.marketingConfig.isAdsOpen,'bizData.marketingConfig.isAdsOpen')
|
||||
vdata.isAdsOpen = bizData.marketingConfig.isAdsOpen
|
||||
appConfig.redPacketIsOpen = bizData.marketingConfig.isOpen
|
||||
appConfig.redbalance = bizData.marketingConfig.balance
|
||||
appConfig.marketingConfig = bizData.marketingConfig
|
||||
})
|
||||
}
|
||||
//计算红包实付金额
|
||||
function getCalcDiscount(originAmount){
|
||||
$getCalcDiscount(originAmount,vdata.storeId).then(({bizData}) => {
|
||||
vdata.calcDiscount = bizData;
|
||||
vdata.originAmount = (bizData.findAmt/100).toFixed(2)
|
||||
vdata.discountAmt = bizData.discountAmt
|
||||
})
|
||||
}
|
||||
|
||||
// 获取订单信息
|
||||
function getOrderInfo() {
|
||||
$getPayOrderInfo().then(({bizData}) => {
|
||||
console.log(bizData,'bizDatabizDatabizDatabizData')
|
||||
appConfig.video = bizData.video
|
||||
vdata.payOrderInfo = bizData
|
||||
vdata.isForceReamrk = bizData.isForceReamrk
|
||||
vdata.storeId = '';
|
||||
if(bizData.storeId) {
|
||||
vdata.storeId = bizData.storeId
|
||||
}
|
||||
getMarketingConfig(vdata.storeId)
|
||||
|
||||
if(bizData.amount) {
|
||||
vdata.amount = (bizData.amount/100).toString()
|
||||
getCalcDiscount(vdata.amount)
|
||||
}
|
||||
|
||||
|
||||
// 金额传入键盘组件
|
||||
sybKeyboardRef.value.setValue(vdata.amount)
|
||||
|
||||
// 如果订单已支付,则转到提示页面
|
||||
if(bizData.state && bizData.state === 2) {
|
||||
return toErrPageFunc("订单已支付");
|
||||
}
|
||||
setTimeout(()=>{
|
||||
getPayType()
|
||||
},2000)
|
||||
// 自动调起支付
|
||||
if(bizData.autoPay) {
|
||||
// pay()
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log(err);
|
||||
})
|
||||
}
|
||||
//视频号数据
|
||||
function sphGet(){
|
||||
console.log(appConfig.video,'videovideovideovideovideo')
|
||||
if(appConfig.currentPageType == 'alipayLite' || appConfig.currentPageType == 'alipayH5' || appConfig.video == undefined || appConfig.video == null){
|
||||
|
||||
|
||||
}else{
|
||||
uni.openChannelsActivity({
|
||||
finderUserName: appConfig.video.uniqueId,//视频号ID
|
||||
feedId: appConfig.video.exportId,//视频ID
|
||||
complete (res) {
|
||||
console.log(res)
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
}
|
||||
function toAddPage () {
|
||||
vdata.addIfCodeList = [
|
||||
{ifCode:"dgpay",ifName:"汇付斗拱支付"},
|
||||
{ifCode:"yspay",ifName:"银盛支付"},
|
||||
{ifCode:"kqpay",ifName:"快钱支付"},
|
||||
{ifCode:"lklspay",ifName:"拉卡拉支付"},
|
||||
{ifCode:"dgpay2",ifName:"汇付斗拱支付"}
|
||||
]
|
||||
vdata.addIfCodeList = vdata.typeItems
|
||||
selectIfcodeRef.value.open()
|
||||
}
|
||||
function reqTableDataByIfcodeFunc () {
|
||||
// 模拟请求数据
|
||||
return Promise.resolve({ bizData: { records: vdata.addIfCodeList, hasNext: false } })
|
||||
}
|
||||
// 发起支付
|
||||
function pay() {
|
||||
if(vdata.isForceReamrk && !vdata.modelRemark){
|
||||
vdata.remarkVisible = true
|
||||
return false;
|
||||
}
|
||||
vdata.payOrderInfo.amount = vdata.amount
|
||||
|
||||
if(vdata.amount <= 0) {
|
||||
return uni.showToast({
|
||||
title: '金额必须大于0',
|
||||
icon: 'none'
|
||||
})
|
||||
return false;
|
||||
}
|
||||
|
||||
// console.log(111111111)
|
||||
// uni.navigateTo({
|
||||
// url: '/pages/paySuccess/redSuccess?payOrderId=20240124O1750143430237061121'
|
||||
// })
|
||||
// return false;
|
||||
|
||||
if(vdata.redPacketIsOpen){
|
||||
if(!vdata.calcDiscount){
|
||||
return false;
|
||||
}
|
||||
if(!vdata.calcDiscount.findAmt){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
uni.showLoading({
|
||||
title: '请稍等...',
|
||||
mask: true
|
||||
})
|
||||
// setTimeout(() => {
|
||||
// uni.navigateTo({
|
||||
// url: '/pages/paySuccess/redSuccess?payOrderId=O1749678699690803202'
|
||||
// })
|
||||
// }, 1000)
|
||||
// return false;
|
||||
$getPayPackage(vdata.amount, vdata.buyerRemark,null,null,vdata.calcDiscount).then( ({bizData}) => {
|
||||
uni.hideLoading()
|
||||
|
||||
console.log(bizData,'bizDatabizData')
|
||||
//订单创建异常
|
||||
if(bizData.code != '0') {
|
||||
let msg = bizData.msg;
|
||||
if(bizData.msg =='系统:Success'){
|
||||
msg = '订单异常'
|
||||
}
|
||||
return uni.showToast({title: msg,icon:'none'})
|
||||
// return toErrPageFunc(bizData.msg);
|
||||
}
|
||||
|
||||
// 订单响应结果
|
||||
let orderRes = bizData.data;
|
||||
|
||||
if(orderRes.orderState != 1 ) { //订单不是支付中,说明订单异常
|
||||
if(orderRes.msg){
|
||||
return uni.showToast({title: orderRes.msg,icon:'none'})
|
||||
}else if(orderRes.errMsg){
|
||||
return uni.showToast({title: orderRes.errMsg,icon:'none'})
|
||||
}else{
|
||||
return uni.showToast({title: '订单异常',icon:'none'})
|
||||
}
|
||||
// return toErrPageFunc(orderRes.errMsg);
|
||||
}
|
||||
|
||||
// if(bizData.code == 0){
|
||||
// uni.navigateTo({
|
||||
// url:"/pages/paySuccess/redSuccess"
|
||||
// })
|
||||
// return false;
|
||||
// }
|
||||
|
||||
if(orderRes.payUrl){
|
||||
location.href = orderRes.payUrl;
|
||||
return false;
|
||||
}
|
||||
|
||||
// 以下为调起 jsapi的函数: 分为: H5 和 各端小程序
|
||||
let thisPaywayCallFunc = paywayCallFunc()[appConfig.currentPageType];
|
||||
thisPaywayCallFunc(orderRes, vdata.payOrderInfo);
|
||||
}).catch( () => {
|
||||
uni.hideLoading()
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
// 显示备注弹窗
|
||||
function showRemarkModel() {
|
||||
vdata.modelRemark = vdata.buyerRemark
|
||||
vdata.remarkVisible = true
|
||||
}
|
||||
|
||||
// 备注弹窗确认
|
||||
function confirmRemark() {
|
||||
vdata.buyerRemark = vdata.modelRemark
|
||||
vdata.remarkVisible = false
|
||||
}
|
||||
|
||||
// 关闭备注弹窗
|
||||
function closeRemarkModel() {
|
||||
vdata.modelRemark = ''
|
||||
vdata.remarkVisible = false
|
||||
}
|
||||
|
||||
// 高级功能模块的显示
|
||||
function advancedFunc(){
|
||||
|
||||
vdata.clearStorageFlag = vdata.clearStorageFlag + 1
|
||||
|
||||
if(vdata.clearStorageFlag >= 10){
|
||||
vdata.clearStorageFlag = 0
|
||||
|
||||
// 目前仅清空缓存
|
||||
uni.showModal({
|
||||
title: '确认清除缓存?',
|
||||
success: function(r) {
|
||||
if (r.confirm) {
|
||||
uni.clearStorageSync()
|
||||
return uni.showToast({title: '已清空'})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.remark-model {
|
||||
position: fixed;
|
||||
height: 100vh;
|
||||
width: 100vw;
|
||||
z-index: 20;
|
||||
background-color: rgba(0,0,0,0.6);
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
.remark-content {
|
||||
height: 290rpx;
|
||||
width: 600rpx;
|
||||
background-color: #FFFFFF;
|
||||
border-radius: 20rpx;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
padding: 50rpx 0 20rpx 0;
|
||||
margin-bottom: 70%;
|
||||
.remark-content-title {
|
||||
font-weight: bold;
|
||||
font-size: 33rpx;
|
||||
letter-spacing: 0.05em;
|
||||
margin-left: 50rpx;
|
||||
}
|
||||
|
||||
.remark-content-body {
|
||||
margin-left: 50rpx;
|
||||
}
|
||||
|
||||
.remark-content-btn {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-around;
|
||||
margin-left: 20rpx;
|
||||
|
||||
text {
|
||||
width: 230rpx;
|
||||
height: 90rpx;
|
||||
border-radius: 10rpx;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.btn-cancel{
|
||||
background: #fff;
|
||||
border: 1rpx solid #c5c7cc;
|
||||
font-weight: 500;
|
||||
font-size: 30rpx;
|
||||
letter-spacing: 0.07em;
|
||||
color: #808080;
|
||||
}
|
||||
|
||||
.btn-confirm{
|
||||
border: 3rpx solid #0041c4;
|
||||
font-weight: 500;
|
||||
font-size: 30rpx;
|
||||
letter-spacing: 0.07em;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.content {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
|
||||
.content-top-bg {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
height: 212rpx;
|
||||
border-radius: 0 0 30rpx 30rpx;
|
||||
z-index: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.payment {
|
||||
// position: relative;
|
||||
// width: 650rpx;
|
||||
width: 96%;
|
||||
// height: 321rpx;
|
||||
margin-top: 20rpx;
|
||||
border-radius: 30rpx;
|
||||
background: #fff;
|
||||
z-index: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
.payment-mchName {
|
||||
width: 100%;
|
||||
// height: 105rpx;
|
||||
padding: 30rpx 0;
|
||||
font-size: 30rpx;
|
||||
letter-spacing: 0.04em;
|
||||
padding-left: 30rpx;
|
||||
color: #000;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.payment-divider {
|
||||
height: 1rpx;
|
||||
width: 100%;
|
||||
background-color: $uni-bg-color-grey;
|
||||
}
|
||||
.payment-amountTips {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
font-size: 25rpx;
|
||||
letter-spacing: 0.04em;
|
||||
text-align: left;
|
||||
padding: 30rpx 0 0 40rpx;
|
||||
color: rgba(0, 0, 0, 0.6);
|
||||
.desc{
|
||||
width: 50%;
|
||||
}
|
||||
.desc1{
|
||||
width: 30%;
|
||||
}
|
||||
.desc2{
|
||||
width: 70%;
|
||||
text-align: right;
|
||||
margin-right: 10%;
|
||||
color: #387CE7;
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
.payment-amount {
|
||||
padding: 15rpx 0 0 40rpx;
|
||||
|
||||
.payment-amount-value {
|
||||
font-size: 80rpx;
|
||||
letter-spacing: 0.03em;
|
||||
padding-left: 15rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
.payment-keyboard {
|
||||
width: 100%;
|
||||
position: fixed;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
z-index: 5;
|
||||
bottom: constant(safe-area-inset-bottom);
|
||||
bottom: env(safe-area-inset-bottom);
|
||||
|
||||
.buyer-remark {
|
||||
position: absolute;
|
||||
top : -80rpx;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
}
|
||||
}
|
||||
.payment-no-keyboard {
|
||||
width: 80%;
|
||||
height: 88rpx;
|
||||
position: fixed;
|
||||
left: 10%;
|
||||
right: 10%;
|
||||
bottom: 240rpx;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
font-size: 36rpx;
|
||||
color: $uni-text-color-inverse;
|
||||
border-radius: 8rpx;
|
||||
}
|
||||
.payment-text{
|
||||
margin-bottom: 16rpx;
|
||||
width: 92%;
|
||||
background: #FAFAFA;
|
||||
display: flex;
|
||||
padding:15px;
|
||||
color: #8F97A9;
|
||||
margin-left: 1%;
|
||||
.txt{
|
||||
width: 50%;
|
||||
}
|
||||
.payment-text-guanggao{
|
||||
text-align: left;
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.payment-text-amount{
|
||||
text-align: right;
|
||||
// margin-right: 10%;
|
||||
text{
|
||||
font-weight: 600;
|
||||
color: #000;
|
||||
}
|
||||
}
|
||||
}
|
||||
.pay-div-type{
|
||||
width: 96%;
|
||||
border-radius: 5%;
|
||||
margin-left: 1%;
|
||||
margin-top: 10px;
|
||||
background: #ffffff;
|
||||
.radio-group-box{
|
||||
padding: 20rpx;
|
||||
border-bottom: 2rpx solid #F4F4F4;
|
||||
.radio-group-div{
|
||||
width: 50%;
|
||||
}
|
||||
.radio-group-name{
|
||||
width: 70%;
|
||||
text-align: left;
|
||||
display: flex;
|
||||
image{
|
||||
width: 50rpx;
|
||||
height: 50rpx;
|
||||
border-radius: 50%;
|
||||
}
|
||||
text{
|
||||
padding: 8rpx 0 10rpx 10rpx ;
|
||||
}
|
||||
.radio-group-name-price{
|
||||
color: #c3c3c3;
|
||||
}
|
||||
}
|
||||
.radio-group-radio{
|
||||
width: 30%;
|
||||
text-align: right;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.payment-amountTips-price{
|
||||
display: flex;
|
||||
width: 100%;
|
||||
font-size: 25rpx;
|
||||
letter-spacing: 0.04em;
|
||||
text-align: left;
|
||||
padding: 30rpx 0 0 40rpx;
|
||||
color: rgba(0, 0, 0, 0.6);
|
||||
padding: 20rpx 0;
|
||||
.desc3{
|
||||
font-size: 21rpx;
|
||||
width: 50%;
|
||||
text-align: left;
|
||||
margin-left: 3%;
|
||||
color: #3D3D3D;
|
||||
.desc3-text1{
|
||||
border:2rpx solid #FE5735 ;
|
||||
border-radius: 10rpx;
|
||||
color: #FE5735;
|
||||
padding: 2rpx;
|
||||
}
|
||||
.desc3-text2{
|
||||
padding-left: 8rpx;
|
||||
}
|
||||
}
|
||||
.desc4{
|
||||
font-size: 30rpx;
|
||||
width: 50%;
|
||||
text-align: right;
|
||||
margin-left: 3%;
|
||||
margin-right: 20rpx;
|
||||
color: #3D3D3D;
|
||||
.desc4-text1{
|
||||
color: #8F97A9;
|
||||
font-size: 24rpx;
|
||||
// border:2rpx solid #FE5735 ;
|
||||
// border-radius: 10rpx;
|
||||
// color: #FE5735;
|
||||
padding: 2rpx;
|
||||
}
|
||||
.desc4-text2{
|
||||
font-weight: 600;
|
||||
padding-left: 8rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
.payment-mchName-img{
|
||||
width: 120rpx;
|
||||
height: 120rpx;
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
.payment-mchName1{
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
.payment-mchName2{
|
||||
font-size: 26rpx;
|
||||
margin-top: 15rpx;
|
||||
font-weight: 400;
|
||||
}
|
||||
.payment-mchName2-text1{
|
||||
color: #3598FE;
|
||||
border: 1px solid #3598FE;
|
||||
border-radius: 10rpx;
|
||||
padding: 4rpx 8rpx;
|
||||
}
|
||||
.payment-mchName2-text2{
|
||||
font-size: 28rpx;
|
||||
color: #3D3D3D;
|
||||
margin-left: 10rpx;
|
||||
}
|
||||
.scroll-view {
|
||||
width: 100%;
|
||||
}
|
||||
.scroll-content {
|
||||
display: inline-block;
|
||||
// width: 1000rpx; /* 设置一个足够大的宽度以确保文本可以滚动 */
|
||||
animation: slide 5s linear infinite;
|
||||
}
|
||||
@keyframes slide {
|
||||
0% {
|
||||
transform: translateX(0);
|
||||
}
|
||||
100% {
|
||||
transform: translateX(-100%);
|
||||
}
|
||||
}
|
||||
</style>
|
||||
369
jeepay-ui-uapp-cashier/pages/payway/index_back.vue
Normal file
@@ -0,0 +1,369 @@
|
||||
<template>
|
||||
<view class="content">
|
||||
<view class="content-top-bg" :style="{'backgroundColor': vdata.primaryColor}"></view>
|
||||
<view class="payment">
|
||||
<view class="payment-mchName" @tap="advancedFunc">付款给{{ vdata.payOrderInfo.mchName }}</view>
|
||||
<view class="payment-divider"></view>
|
||||
<view class="payment-amountTips">付款金额:</view>
|
||||
<view class="payment-amount" :style="{'color': vdata.primaryColor}">
|
||||
<text class="payment-amount-rmb">¥</text>
|
||||
<text class="payment-amount-value">{{ doubleToThousands(vdata.amount) }}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="payment-keyboard" v-if="!vdata.payOrderInfo['fixedFlag']">
|
||||
<text class="buyer-remark" v-if="!vdata.buyerRemark" :style="{'color': vdata.primaryColor}" @tap="showRemarkModel">添加备注</text>
|
||||
<text class="buyer-remark" v-else @tap="showRemarkModel">
|
||||
{{ vdata.buyerRemark }}
|
||||
<text :style="{'color': vdata.primaryColor, 'padding-left': '6rpx'}">修改</text>
|
||||
</text>
|
||||
<jq-keyboard
|
||||
ref="jqKeyboardRef"
|
||||
:primaryColor="vdata.primaryColor"
|
||||
@change="onChange"
|
||||
@pay="pay">
|
||||
</jq-keyboard>
|
||||
</view>
|
||||
<view v-else class="payment-no-keyboard" :style="{'backgroundColor': vdata.primaryColor}" @tap="pay">付 款</view>
|
||||
|
||||
<view v-if="vdata.remarkVisible" class="remark-model">
|
||||
<view class="remark-content">
|
||||
<text class="remark-content-title" :style="{'color': vdata.primaryColor}">添加备注</text>
|
||||
<input v-model="vdata.modelRemark" :focus="vdata.remarkVisible" maxlength="20" placeholder="最多输入12个字" class="remark-content-body" />
|
||||
<view class="remark-content-btn">
|
||||
<text class="btn-cancel" @tap.stop="closeRemarkModel">取消</text>
|
||||
<text class="btn-confirm" :style="{'backgroundColor': vdata.primaryColor, 'borderColor': vdata.primaryColor}" @tap.stop="confirmRemark">确认</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { reactive, ref } from 'vue'
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import { $getPayOrderInfo, $getPayPackage } from '@/http/apiManager.js'
|
||||
import { doubleToThousands } from '@/util/amount.js'
|
||||
import { toErrPageFunc } from '@/util/toErrorPageUtil.js'
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
import theme from '@/config/theme.js'
|
||||
import paywayCallFunc from '@/pages/payway/payway.js'
|
||||
|
||||
const jqKeyboardRef = ref()
|
||||
|
||||
const vdata = reactive({
|
||||
primaryColor: '',
|
||||
amount: '0',
|
||||
buyerRemark: '', // 买家备注
|
||||
modelRemark: '', // 弹层显示备注
|
||||
remarkVisible: false,
|
||||
doubleToThousands: doubleToThousands(),
|
||||
payOrderInfo: {},
|
||||
clearStorageFlag: 0, //显示清空缓存的提示
|
||||
}) as any
|
||||
|
||||
onLoad(() => {
|
||||
|
||||
vdata.amount = '0'
|
||||
|
||||
vdata.primaryColor = theme.changeColors()
|
||||
|
||||
// #ifdef H5
|
||||
//解决H5的刷新问题
|
||||
if(!appConfig.tokenValue){ // 不存在 则需要跳转到首页再次放置 获取userID等信息。
|
||||
|
||||
window.location.href = '/cashier/pages/hub/default?' + appConfig.tokenKey + "=" + window.sessionStorage.getItem(appConfig.tokenKey)
|
||||
return false;
|
||||
}
|
||||
// #endif
|
||||
|
||||
// 获取订单信息
|
||||
getOrderInfo()
|
||||
|
||||
})
|
||||
|
||||
// 输入金额
|
||||
function onChange(e: any) {
|
||||
vdata.amount = e
|
||||
}
|
||||
// 获取订单信息
|
||||
function getOrderInfo() {
|
||||
console.log(5641322198)
|
||||
$getPayOrderInfo().then(({bizData}) => {
|
||||
|
||||
vdata.payOrderInfo = bizData
|
||||
|
||||
if(bizData.amount) {
|
||||
vdata.amount = (bizData.amount/100).toString()
|
||||
|
||||
}
|
||||
|
||||
// 金额传入键盘组件
|
||||
jqKeyboardRef.value.setValue(vdata.amount)
|
||||
|
||||
// 如果订单已支付,则转到提示页面
|
||||
if(bizData.state && bizData.state === 2) {
|
||||
return toErrPageFunc("订单已支付");
|
||||
}
|
||||
|
||||
// 自动调起支付
|
||||
if(bizData.autoPay) {
|
||||
pay()
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log(err);
|
||||
})
|
||||
}
|
||||
|
||||
// 发起支付
|
||||
function pay() {
|
||||
vdata.payOrderInfo.amount = vdata.amount
|
||||
|
||||
if(vdata.amount <= 0) {
|
||||
return uni.showToast({
|
||||
title: '金额必须大于0',
|
||||
icon: 'none'
|
||||
})
|
||||
}
|
||||
|
||||
uni.showLoading({
|
||||
title: '请稍等...',
|
||||
mask: true
|
||||
})
|
||||
console.log(vdata,'vdatavdata')
|
||||
$getPayPackage(vdata.amount, vdata.buyerRemark).then( ({bizData}) => {
|
||||
uni.hideLoading()
|
||||
|
||||
//订单创建异常
|
||||
if(bizData.code != '0') {
|
||||
return toErrPageFunc(bizData.msg);
|
||||
}
|
||||
|
||||
// 订单响应结果
|
||||
let orderRes = bizData.data;
|
||||
|
||||
if(orderRes.orderState != 1 ) { //订单不是支付中,说明订单异常
|
||||
return toErrPageFunc(orderRes.errMsg);
|
||||
}
|
||||
|
||||
if(orderRes.payUrl){
|
||||
location.href = orderRes.payUrl;
|
||||
return false;
|
||||
}
|
||||
|
||||
// 以下为调起 jsapi的函数: 分为: H5 和 各端小程序
|
||||
let thisPaywayCallFunc = paywayCallFunc()[appConfig.currentPageType];
|
||||
thisPaywayCallFunc(orderRes, vdata.payOrderInfo);
|
||||
}).catch( () => {
|
||||
uni.hideLoading()
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
// 显示备注弹窗
|
||||
function showRemarkModel() {
|
||||
vdata.modelRemark = vdata.buyerRemark
|
||||
vdata.remarkVisible = true
|
||||
}
|
||||
|
||||
// 备注弹窗确认
|
||||
function confirmRemark() {
|
||||
vdata.buyerRemark = vdata.modelRemark
|
||||
vdata.remarkVisible = false
|
||||
}
|
||||
|
||||
// 关闭备注弹窗
|
||||
function closeRemarkModel() {
|
||||
vdata.modelRemark = ''
|
||||
vdata.remarkVisible = false
|
||||
}
|
||||
|
||||
// 高级功能模块的显示
|
||||
function advancedFunc(){
|
||||
|
||||
vdata.clearStorageFlag = vdata.clearStorageFlag + 1
|
||||
|
||||
if(vdata.clearStorageFlag >= 10){
|
||||
vdata.clearStorageFlag = 0
|
||||
|
||||
// 目前仅清空缓存
|
||||
uni.showModal({
|
||||
title: '确认清除缓存?',
|
||||
success: function(r) {
|
||||
if (r.confirm) {
|
||||
uni.clearStorageSync()
|
||||
return uni.showToast({title: '已清空'})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.remark-model {
|
||||
position: fixed;
|
||||
height: 100vh;
|
||||
width: 100vw;
|
||||
z-index: 20;
|
||||
background-color: rgba(0,0,0,0.6);
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
.remark-content {
|
||||
height: 290rpx;
|
||||
width: 600rpx;
|
||||
background-color: #FFFFFF;
|
||||
border-radius: 20rpx;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
padding: 50rpx 0 20rpx 0;
|
||||
|
||||
.remark-content-title {
|
||||
font-weight: bold;
|
||||
font-size: 33rpx;
|
||||
letter-spacing: 0.05em;
|
||||
margin-left: 50rpx;
|
||||
}
|
||||
|
||||
.remark-content-body {
|
||||
margin-left: 50rpx;
|
||||
}
|
||||
|
||||
.remark-content-btn {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-around;
|
||||
margin-left: 20rpx;
|
||||
|
||||
text {
|
||||
width: 230rpx;
|
||||
height: 90rpx;
|
||||
border-radius: 10rpx;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.btn-cancel{
|
||||
background: #fff;
|
||||
border: 1rpx solid #c5c7cc;
|
||||
font-weight: 500;
|
||||
font-size: 30rpx;
|
||||
letter-spacing: 0.07em;
|
||||
color: #808080;
|
||||
}
|
||||
|
||||
.btn-confirm{
|
||||
border: 3rpx solid #0041c4;
|
||||
font-weight: 500;
|
||||
font-size: 30rpx;
|
||||
letter-spacing: 0.07em;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.content {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
|
||||
.content-top-bg {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
height: 212rpx;
|
||||
border-radius: 0 0 30rpx 30rpx;
|
||||
z-index: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.payment {
|
||||
position: relative;
|
||||
width: 650rpx;
|
||||
height: 321rpx;
|
||||
margin-top: 20rpx;
|
||||
border-radius: 30rpx;
|
||||
background: #fff;
|
||||
z-index: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
.payment-mchName {
|
||||
width: 100%;
|
||||
height: 105rpx;
|
||||
font-size: 30rpx;
|
||||
letter-spacing: 0.04em;
|
||||
padding-left: 30rpx;
|
||||
color: #000;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.payment-divider {
|
||||
height: 1rpx;
|
||||
width: 100%;
|
||||
background-color: $uni-bg-color-grey;
|
||||
}
|
||||
.payment-amountTips {
|
||||
font-size: 25rpx;
|
||||
letter-spacing: 0.04em;
|
||||
text-align: left;
|
||||
padding: 30rpx 0 0 40rpx;
|
||||
color: rgba(0, 0, 0, 0.6);
|
||||
}
|
||||
.payment-amount {
|
||||
padding: 15rpx 0 0 40rpx;
|
||||
|
||||
.payment-amount-value {
|
||||
font-size: 80rpx;
|
||||
letter-spacing: 0.03em;
|
||||
padding-left: 15rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
.payment-keyboard {
|
||||
width: 100%;
|
||||
position: fixed;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
z-index: 5;
|
||||
bottom: constant(safe-area-inset-bottom);
|
||||
bottom: env(safe-area-inset-bottom);
|
||||
|
||||
.buyer-remark {
|
||||
position: absolute;
|
||||
top : -80rpx;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
}
|
||||
}
|
||||
.payment-no-keyboard {
|
||||
width: 80%;
|
||||
height: 88rpx;
|
||||
position: fixed;
|
||||
left: 10%;
|
||||
right: 10%;
|
||||
bottom: 240rpx;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
font-size: 36rpx;
|
||||
color: $uni-text-color-inverse;
|
||||
border-radius: 8rpx;
|
||||
}
|
||||
</style>
|
||||
187
jeepay-ui-uapp-cashier/pages/payway/payway.js
Normal file
@@ -0,0 +1,187 @@
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
import { toErrPageFunc } from '@/util/toErrorPageUtil.js'
|
||||
import { $payCancelBoardCast, $payEventBoardCast } from '@/http/apiManager.js'
|
||||
|
||||
function wechatH5Func(orderRes, payOrderInfo){
|
||||
|
||||
|
||||
let onBridgeReady = function () {
|
||||
|
||||
// eslint-disable-next-line no-undef
|
||||
WeixinJSBridge.invoke( 'getBrandWCPayRequest', JSON.parse(orderRes.payInfo), function(res) {
|
||||
|
||||
payEventBoardCast(orderRes.payOrderId, res)
|
||||
|
||||
if (res.err_msg == "get_brand_wcpay_request:ok") {
|
||||
// 使用以上方式判断前端返回,微信团队郑重提示:
|
||||
//res.err_msg将在用户支付成功后返回ok,但并不保证它绝对可靠。
|
||||
// //重定向
|
||||
if(payOrderInfo.returnUrl){
|
||||
location.href = payOrderInfo.returnUrl;
|
||||
}else{
|
||||
alert('支付成功!');
|
||||
// if(payOrderInfo.fun) return payOrderInfo.fun()
|
||||
window.WeixinJSBridge.call('closeWindow')
|
||||
}
|
||||
|
||||
}
|
||||
if (res.err_msg == "get_brand_wcpay_request:cancel") {
|
||||
// payCancel(orderRes.payOrderId)
|
||||
alert("支付取消");
|
||||
// return false;
|
||||
window.WeixinJSBridge.call('closeWindow')
|
||||
}
|
||||
if (res.err_msg == "get_brand_wcpay_request:fail") {
|
||||
alert('支付失败:' + JSON.stringify(res))
|
||||
// return false;
|
||||
window.WeixinJSBridge.call('closeWindow')
|
||||
}
|
||||
if (res.err_msg == "total_fee") {
|
||||
alert('缺少参数')
|
||||
window.WeixinJSBridge.call('closeWindow')
|
||||
}
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
if (typeof WeixinJSBridge == "undefined"){
|
||||
if( document.addEventListener ){
|
||||
document.addEventListener('WeixinJSBridgeReady', onBridgeReady, false);
|
||||
}else if (document.attachEvent){
|
||||
document.attachEvent('WeixinJSBridgeReady', onBridgeReady);
|
||||
document.attachEvent('onWeixinJSBridgeReady', onBridgeReady);
|
||||
}
|
||||
}else{
|
||||
onBridgeReady();
|
||||
}
|
||||
}
|
||||
|
||||
// 支付宝内的浏览器调起支付:https://myjsapi.alipay.com/jsapi/native/trade-pay.html
|
||||
function alipayH5Func(orderRes){
|
||||
// 执行事件
|
||||
let doAlipay = function () {
|
||||
AlipayJSBridge.call("tradePay", { tradeNO: orderRes.alipayTradeNo }, function (data) {
|
||||
payEventBoardCast(orderRes.payOrderId, data)
|
||||
if ("9000" == data.resultCode) {
|
||||
// //重定向
|
||||
if(orderRes.returnUrl){
|
||||
location.href = orderRes.returnUrl;
|
||||
}else{
|
||||
alert('支付成功!');
|
||||
window.AlipayJSBridge.call('closeWebview')
|
||||
}
|
||||
//‘8000’:后台获取支付结果超时,暂时未拿到支付结果;
|
||||
// ‘6004’:支付过程中网络出错, 暂时未拿到支付结果;
|
||||
}else if("8000" == data.resultCode || "6004" == data.resultCode){ //其他
|
||||
alert(JSON.stringify(data));
|
||||
window.AlipayJSBridge.call('closeWebview')
|
||||
}else{ ///其他异常信息, 需要取消订单
|
||||
// payCancel(orderRes.payOrderId)
|
||||
alert('用户已取消!');
|
||||
window.AlipayJSBridge.call('closeWebview')
|
||||
}
|
||||
});
|
||||
}
|
||||
if (!window.AlipayJSBridge) {
|
||||
document.addEventListener('AlipayJSBridgeReady', doAlipay, false);
|
||||
}else{
|
||||
doAlipay();
|
||||
}
|
||||
}
|
||||
|
||||
function wechatLiteFunc(orderRes, payOrderInfo){
|
||||
const payInfo = JSON.parse(orderRes.payInfo)
|
||||
wx.requestPayment({
|
||||
"timeStamp": payInfo.timeStamp,
|
||||
"nonceStr": payInfo.nonceStr,
|
||||
"package": payInfo.package,
|
||||
"signType": payInfo.signType,
|
||||
"paySign": payInfo.paySign,
|
||||
"success": function(res){
|
||||
if(appConfig.redPacketIsOpen){
|
||||
setTimeout(() => {
|
||||
uni.navigateTo({
|
||||
url: '/pages/paySuccess/redSuccess?payOrderId=' + orderRes.payOrderId
|
||||
})
|
||||
}, 1000)
|
||||
return false;
|
||||
}
|
||||
if(payOrderInfo.fun) return payOrderInfo.fun()
|
||||
uni.navigateTo({
|
||||
url: '/pages/paySuccess/paySuccess?amount=' + payOrderInfo.amount + '&payOrderId=' + orderRes.payOrderId
|
||||
})
|
||||
},
|
||||
"fail": function(res){
|
||||
if(res.errMsg == 'requestPayment:fail cancel') {
|
||||
// payCancel(orderRes.payOrderId)
|
||||
// toErrPageFunc('取消支付')
|
||||
return uni.showToast({title: '取消支付',icon:'none'})
|
||||
}else {
|
||||
toErrPageFunc(res.errMsg)
|
||||
}
|
||||
},
|
||||
"complete": (res) => {
|
||||
payEventBoardCast(orderRes.payOrderId, res)
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
function alipayLiteFunc(orderRes, payOrderInfo){
|
||||
my.tradePay({
|
||||
tradeNO: orderRes.alipayTradeNo,
|
||||
success: (res) => {
|
||||
if(res.resultCode == 9000) {
|
||||
if(payOrderInfo.fun) return payOrderInfo.fun()
|
||||
uni.navigateTo({
|
||||
url: '/pages/paySuccess/paySuccess?amount=' + payOrderInfo.amount
|
||||
})
|
||||
}else if(res.resultCode == 6001) {
|
||||
// payCancel(orderRes.payOrderId)
|
||||
// toErrPageFunc('取消支付')
|
||||
return uni.showToast({title: '取消支付',icon:'none'})
|
||||
}else if(res.resultCode == 4000) {
|
||||
// toErrPageFunc('订单处理失败')
|
||||
return uni.showToast({title: '订单处理失败',icon:'none'})
|
||||
}else if(res.resultCode == 4) {
|
||||
toErrPageFunc('无权限调用')
|
||||
}else {
|
||||
toErrPageFunc(JSON.stringify(res))
|
||||
}
|
||||
},
|
||||
fail: (res) => {
|
||||
toErrPageFunc(JSON.stringify(res))
|
||||
},
|
||||
complete: (res) => {
|
||||
payEventBoardCast(orderRes.payOrderId, res)
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function ysfpayH5Func(orderRes){
|
||||
window.location.href = orderRes.redirectUrl
|
||||
}
|
||||
|
||||
|
||||
function payCancel(payOrderId) {
|
||||
$payCancelBoardCast(payOrderId).then(() => {
|
||||
console.log("取消支付")
|
||||
})
|
||||
}
|
||||
|
||||
function payEventBoardCast(payOrderId, resData) {
|
||||
$payEventBoardCast(payOrderId, resData)
|
||||
}
|
||||
|
||||
|
||||
export default () => {
|
||||
|
||||
let result = {}
|
||||
result[appConfig.PAGE_TYPE_ENUM.WECHAT_H5] = wechatH5Func;
|
||||
result[appConfig.PAGE_TYPE_ENUM.ALIPAY_H5] = alipayH5Func;
|
||||
result[appConfig.PAGE_TYPE_ENUM.WECHAT_LITE] = wechatLiteFunc;
|
||||
result[appConfig.PAGE_TYPE_ENUM.ALIPAY_LITE] = alipayLiteFunc;
|
||||
result[appConfig.PAGE_TYPE_ENUM.YSFPAY_H5] = ysfpayH5Func;
|
||||
|
||||
return result;
|
||||
}
|
||||
816
jeepay-ui-uapp-cashier/pages/route/index.vue
Normal file
@@ -0,0 +1,816 @@
|
||||
<template>
|
||||
<view class="content">
|
||||
<!-- <view class="content-top-bg" :style="{'backgroundColor': vdata.primaryColor}"></view> -->
|
||||
<view class="payment">
|
||||
<view class="payment-mchName" @tap="advancedFunc">
|
||||
<view style="display: contents;">
|
||||
<image src="/static/img/store.svg" mode="scaleToFill" class="payment-mchName-img" />
|
||||
<view style="display: grid;margin-left: 16rpx;font-size: 35rpx;">
|
||||
付款给交易路由商家
|
||||
<!-- <text class="payment-mchName1">{{ vdata.payOrderInfo.mchName }}</text>
|
||||
<view class="payment-mchName2">
|
||||
|
||||
<text class="payment-mchName2-text1">门店</text>
|
||||
<text class="payment-mchName2-text2">{{vdata.payOrderInfo.storeName}}</text>
|
||||
</view> -->
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="payment-divider"></view>
|
||||
<view class="payment-amountTips">
|
||||
<view class="desc1 ">付款金额:</view>
|
||||
<view class="desc2 " v-if="!vdata.buyerRemark" @tap="showRemarkModel"><span v-if="vdata.isForceReamrk" style='color: #FF0000;'>*</span>添加备注</view>
|
||||
<text class="desc2 buyer-remark" v-else @tap="showRemarkModel">
|
||||
{{ vdata.buyerRemark }}
|
||||
<text :style="{ 'padding-left': '6rpx'}">修改</text>
|
||||
</text>
|
||||
</view>
|
||||
<view class="payment-amount" >
|
||||
<text class="payment-amount-rmb">¥</text>
|
||||
<text class="payment-amount-value">{{ doubleToThousands(vdata.amount) }}</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="payment-keyboard" >
|
||||
<syb-keyboard
|
||||
ref="sybKeyboardRef"
|
||||
:primaryColor="vdata.primaryColor"
|
||||
@change="onChange"
|
||||
@pay="getSybPayType">
|
||||
</syb-keyboard>
|
||||
</view>
|
||||
|
||||
<view v-if="vdata.remarkVisible" class="remark-model">
|
||||
<view class="remark-content">
|
||||
<text class="remark-content-title" >添加备注</text>
|
||||
<input v-model="vdata.modelRemark" :focus="vdata.remarkVisible" maxlength="40" placeholder="最多输入20个字" class="remark-content-body" />
|
||||
<view class="remark-content-btn">
|
||||
<text class="btn-cancel" @tap.stop="closeRemarkModel">取消</text>
|
||||
<text class="btn-confirm" :style="{'backgroundColor': '#1678FF', 'borderColor': '#ffffff'}" @tap.stop="confirmRemark">确认</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { onMounted, reactive, ref } from 'vue'
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import { $getPayOrderInfo, $payApiDoRoute,$getMarketingConfig,$getChannelUserId } from '@/http/apiManager.js'
|
||||
import { doubleToThousands } from '@/util/amount.js'
|
||||
import { toErrPageFunc } from '@/util/toErrorPageUtil.js'
|
||||
import appConfig from '@/config/appConfig.js'
|
||||
import theme from '@/config/theme.js'
|
||||
import storageManage from '@/util/storageManage.js'
|
||||
// import SelectedPay from './components/SelectedPay.vue'
|
||||
import paywayCallFunc from '@/pages/payway/payway.js'
|
||||
|
||||
const sybCodePay = ref()
|
||||
const sybKeyboardRef = ref()
|
||||
const selectIfcodeRef = ref()
|
||||
|
||||
const vdata = reactive({
|
||||
scrollLeft: 0, // 滚动位置
|
||||
scrollSpeed: 2, // 滚动速度,单位px/ms
|
||||
scrollInterval: null, // 定时器ID
|
||||
navigatorUrl:"",
|
||||
payTypeList:[] as any,
|
||||
typeItems: [{
|
||||
img:"/static/img/wechat.png",
|
||||
value: 1,
|
||||
name: '微信支付',
|
||||
checked: false,
|
||||
},{
|
||||
img:"/static/img/wechat.png",
|
||||
value: 2,
|
||||
name: '微信H5',
|
||||
checked: false,
|
||||
},{
|
||||
img:"/static/payIcon/zfb.png",
|
||||
value: 3,
|
||||
name: '支付宝支付',
|
||||
checked: false,
|
||||
},{
|
||||
img:"/static/payIcon/zfb.png",
|
||||
value: 4,
|
||||
name: '支付宝H5',
|
||||
checked: false,
|
||||
},{
|
||||
img:"/static/img/payred.png",
|
||||
value: 5,
|
||||
name: '红包',
|
||||
checked: false,
|
||||
price: '',
|
||||
},
|
||||
],
|
||||
addIfCodeList:{} as any,
|
||||
isAdsOpen:false,
|
||||
redPacketIsOpen:false,
|
||||
current: 0,
|
||||
primaryColor: '',
|
||||
originAmount: '0',
|
||||
amount: '0',
|
||||
buyerRemark: '', // 买家备注
|
||||
modelRemark: '', // 弹层显示备注
|
||||
remarkVisible: false,
|
||||
doubleToThousands: doubleToThousands(),
|
||||
payOrderInfo: {},
|
||||
calcDiscount:{},
|
||||
storeId:'',
|
||||
clearStorageFlag: 0, //显示清空缓存的提示
|
||||
isForceReamrk:false,
|
||||
appid:"",
|
||||
tk:"",
|
||||
env:"route"
|
||||
}) as any
|
||||
|
||||
onLoad((options) => {
|
||||
uni.setNavigationBarColor({
|
||||
backgroundColor: '#ffffff',
|
||||
frontColor: '#000000',
|
||||
})
|
||||
options.env = 'route'
|
||||
if(appConfig.currentPageType == 'alipayLite' && options.env !='route'){
|
||||
options = uni.getLaunchOptionsSync().query
|
||||
}
|
||||
uni.setStorageSync('payH5', JSON.stringify(options)) // 改变存储
|
||||
appConfig.payH5 = options
|
||||
appConfig.itoken = options.tk
|
||||
storageManage.iToken(options.tk)
|
||||
appConfig.tk = options.tk
|
||||
appConfig.tokenValue = options.tk
|
||||
if(options.ap){
|
||||
vdata.appid = options.ap;
|
||||
}
|
||||
// uni.showToast({title: JSON.stringify(appConfig),icon:'none',duration:5000})
|
||||
if(options.env){
|
||||
vdata.env = options.env;
|
||||
if(vdata.env =='route'){
|
||||
// if((appConfig.currentPageType == 'wechatH5' || appConfig.currentPageType == 'alipayH5') && options.env == 'route' && !appConfig.channelUserId){
|
||||
// location.href = appConfig.env.JEEPAY_PAY_BASE_URL+"/pages/hub/h5?tk="+options.tk+"&env="+options.env
|
||||
// return false;
|
||||
// }
|
||||
}
|
||||
}
|
||||
console.log(appConfig.currentPageType,'appConfig.currentPageType')
|
||||
if(appConfig.currentPageType == 'wechatH5' || appConfig.currentPageType == 'wechatLite' || appConfig.currentPageType == 'alipayLite'){
|
||||
// getLogin();
|
||||
}
|
||||
if(appConfig.currentPageType == 'alipayH5' && that.env == "scan"){
|
||||
// getLogin();
|
||||
}
|
||||
// if(appConfig.currentPageType == 'alipayH5'){
|
||||
// loadScriptAndCallFunction();
|
||||
// }
|
||||
vdata.tk = options.tk;
|
||||
|
||||
})
|
||||
onMounted(() => {
|
||||
if(appConfig.currentPageType == 'alipayH5'){
|
||||
// loadScriptAndCallFunction();
|
||||
}
|
||||
})
|
||||
|
||||
function loadScriptAndCallFunction() {
|
||||
// 动态加载外部 JavaScript 文件
|
||||
const script = document.createElement('script');
|
||||
script.src = 'https://gw.alipayobjects.com/as/g/h5-lib/alipayjsapi/3.1.1/alipayjsapi.min.js'; // 假设alipayjsapi.min.js在static文件夹中
|
||||
script.onload = () => {
|
||||
|
||||
// 脚本加载完成后调用函数
|
||||
callApFunction();
|
||||
};
|
||||
document.head.appendChild(script);
|
||||
}
|
||||
function callApFunction() {
|
||||
// 调用 ap.getAuthCode() 函数
|
||||
ap.getAuthCode({
|
||||
appId:vdata.appid,
|
||||
// appId:'2021002175627786',
|
||||
scopes: ['auth_user']
|
||||
}, (res) => {
|
||||
// setPay(res.authCode)
|
||||
uni.showToast({title: "授权"+JSON.stringify(res),icon:'none'})
|
||||
// res.authCode
|
||||
});
|
||||
}
|
||||
function getPayType(){
|
||||
const typeItems = vdata.typeItems
|
||||
vdata.payTypeList = [];
|
||||
console.log(appConfig.redPacketIsOpen,'appConfigredPacketIsOpen')
|
||||
if(!appConfig.redPacketIsOpen){
|
||||
delete typeItems[4]
|
||||
}
|
||||
if(appConfig.currentPageType == 'wechatLite'){
|
||||
delete typeItems[1]
|
||||
delete typeItems[2]
|
||||
delete typeItems[3]
|
||||
}
|
||||
if(appConfig.currentPageType == 'wechatH5'){
|
||||
delete typeItems[0]
|
||||
delete typeItems[2]
|
||||
delete typeItems[3]
|
||||
}
|
||||
if(appConfig.currentPageType == 'alipayLite'){
|
||||
delete typeItems[0]
|
||||
delete typeItems[1]
|
||||
delete typeItems[3]
|
||||
}
|
||||
// return uni.showToast({
|
||||
// title: appConfig.currentPageType,
|
||||
// icon: 'none'
|
||||
// })
|
||||
if(appConfig.currentPageType == 'alipayH5'){
|
||||
delete typeItems[0]
|
||||
delete typeItems[1]
|
||||
delete typeItems[2]
|
||||
}
|
||||
console.log(typeItems,'codePay')
|
||||
typeItems.forEach(function(item,index){
|
||||
if(index == 4){
|
||||
item.price = appConfig.redbalance
|
||||
}
|
||||
if(appConfig.currentPageType == 'wechatLite' || appConfig.currentPageType == 'wechatH5'){
|
||||
if(item.value == 3 || item.value == 4){
|
||||
|
||||
}else{
|
||||
vdata.payTypeList.push(item)
|
||||
}
|
||||
}else if(appConfig.currentPageType == 'alipayLite' || appConfig.currentPageType == 'alipayH5'){
|
||||
if(item.value == 0 || item.value == 1){
|
||||
|
||||
}else{
|
||||
vdata.payTypeList.push(item)
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
if(typeItems.length){
|
||||
typeItems[0].checked = true
|
||||
}
|
||||
}
|
||||
function updataBank (index,type=0) {
|
||||
console.log(type,'typetype')
|
||||
pay()
|
||||
}
|
||||
function scrollToLower(){
|
||||
vdata.scrollLeft = 0;
|
||||
}
|
||||
function getSybPayType(){
|
||||
if(vdata.amount <= 0) {
|
||||
return uni.showToast({
|
||||
title: '金额必须大于0',
|
||||
icon: 'none'
|
||||
})
|
||||
return false;
|
||||
}
|
||||
if(vdata.payTypeList.length <= 1){
|
||||
pay()
|
||||
return false;
|
||||
}else{
|
||||
sybCodePay.value.open();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// 输入金额
|
||||
function onChange(e: any) {
|
||||
if(vdata.payOrderInfo['fixedFlag']){
|
||||
return false;
|
||||
}
|
||||
vdata.amount = e
|
||||
vdata.originAmount = e
|
||||
|
||||
}
|
||||
function getadsName(){
|
||||
if(!appConfig.marketingConfig.isAdsOpen){
|
||||
return false;
|
||||
}
|
||||
uni.navigateTo({
|
||||
url: '/pages/H5/H5?url='+ appConfig.marketingConfig.adsUrl
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
// 发起支付
|
||||
function pay() {
|
||||
|
||||
if(vdata.isForceReamrk && !vdata.modelRemark){
|
||||
vdata.remarkVisible = true
|
||||
return false;
|
||||
}
|
||||
|
||||
if(vdata.amount <= 0) {
|
||||
return uni.showToast({
|
||||
title: '金额必须大于0',
|
||||
icon: 'none'
|
||||
})
|
||||
return false;
|
||||
}
|
||||
|
||||
// if(!appConfig.channelUniId){
|
||||
// getLogin()
|
||||
// return false;
|
||||
// }
|
||||
|
||||
uni.showLoading({
|
||||
title: '请稍等...',
|
||||
mask: true
|
||||
})
|
||||
$payApiDoRoute(vdata.amount, vdata.buyerRemark).then( ({bizData}) => {
|
||||
|
||||
console.log(bizData,'bizDatabizData')
|
||||
uni.hideLoading()
|
||||
//订单创建异常
|
||||
if(bizData.orderState != 0) {
|
||||
let msg = bizData.msg;
|
||||
if(bizData.msg =='系统:Success'){
|
||||
msg = '订单异常'
|
||||
}
|
||||
return uni.showToast({title: msg,icon:'none'})
|
||||
}
|
||||
|
||||
if(bizData.orderState == 0){
|
||||
if(appConfig.currentPageType == 'alipayH5' && bizData.extData.payMethod == 0){
|
||||
uni.navigateTo({
|
||||
url:"/pages/payment/index?ap="+bizData.extData.appid+"&tk="+bizData.payData+"&order_no="+bizData.payOrderId+"&price="+vdata.amount+"&env=scan&opTk="+vdata.tk
|
||||
})
|
||||
}else if(appConfig.currentPageType == 'wechatH5' && bizData.extData.payMethod == 0){
|
||||
console.log('wechatH5支付')
|
||||
uni.navigateTo({
|
||||
url:"/pages/payment/index?tk="+bizData.payData+"&order_no="+bizData.payOrderId+"&price="+vdata.amount+"&env=scan&opTk="+vdata.tk
|
||||
})
|
||||
}else if(appConfig.currentPageType == 'wechatH5' && bizData.extData.payMethod == 1){
|
||||
|
||||
const query = encodeURIComponent("tk="+bizData.payData+"&order_no="+bizData.payOrderId+"&price="+vdata.amount+"&env=scan&opTk="+vdata.tk+"&env_version=release")
|
||||
const url = "weixin://dl/business/?appid="+bizData.extData.liteAppid+"&path=pages/payment/index&query="+query;
|
||||
console.log('wechatH5小程序支付')
|
||||
location.href = url
|
||||
// vdata.navigatorUrl = url
|
||||
// // 获取a标签
|
||||
// setTimeout(()=>{
|
||||
// var link = document.getElementById('myLink');
|
||||
// // 模拟点击
|
||||
// link.click();
|
||||
// },2000)
|
||||
// window.open(url)
|
||||
|
||||
}else if(appConfig.currentPageType == 'alipayH5' && bizData.extData.payMethod == 1){
|
||||
var query = encodeURIComponent("price="+vdata.amount+"&tk="+bizData.payData+"&order_no="+bizData.payOrderId+"&env=scanXcx&opTk="+vdata.tk+"&env_version=release")
|
||||
|
||||
var url = encodeURIComponent('pages/payment/index');
|
||||
|
||||
var pathUrl ="alipays://platformapi/startapp?appId="+bizData.extData.liteAppid+"&page="+url+"&query="+query;
|
||||
// window.open(pathUrl)
|
||||
// vdata.navigatorUrl = pathUrl
|
||||
// // 获取a标签
|
||||
// setTimeout(()=>{
|
||||
// var link = document.getElementById('myLink');
|
||||
// // 模拟点击
|
||||
// link.click();
|
||||
// },2000)
|
||||
// console.log(pathUrl,'url')
|
||||
window.location.href = pathUrl
|
||||
}else{
|
||||
console.log(9999)
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
}).catch( () => {
|
||||
uni.hideLoading()
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
// 显示备注弹窗
|
||||
function showRemarkModel() {
|
||||
vdata.modelRemark = vdata.buyerRemark
|
||||
vdata.remarkVisible = true
|
||||
}
|
||||
|
||||
// 备注弹窗确认
|
||||
function confirmRemark() {
|
||||
vdata.buyerRemark = vdata.modelRemark
|
||||
vdata.remarkVisible = false
|
||||
}
|
||||
|
||||
// 关闭备注弹窗
|
||||
function closeRemarkModel() {
|
||||
vdata.modelRemark = ''
|
||||
vdata.remarkVisible = false
|
||||
}
|
||||
|
||||
// 高级功能模块的显示
|
||||
function advancedFunc(){
|
||||
|
||||
vdata.clearStorageFlag = vdata.clearStorageFlag + 1
|
||||
|
||||
if(vdata.clearStorageFlag >= 10){
|
||||
vdata.clearStorageFlag = 0
|
||||
|
||||
// 目前仅清空缓存
|
||||
uni.showModal({
|
||||
title: '确认清除缓存?',
|
||||
success: function(r) {
|
||||
if (r.confirm) {
|
||||
uni.clearStorageSync()
|
||||
return uni.showToast({title: '已清空'})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function getLogin(){
|
||||
|
||||
if(appConfig.currentPageType == 'wechatH5' || appConfig.currentPageType == 'alipayH5'){
|
||||
// that.setPay(that.aliCode);
|
||||
that.setPay(null)
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
// 获取服务供应商
|
||||
uni.getProvider({
|
||||
service: 'oauth',
|
||||
success: function (res) {
|
||||
// 获取用户登录凭证code
|
||||
// let provider = res.provider[0];
|
||||
uni.login({
|
||||
provider: res.provider[0],
|
||||
success: function (loginRes) {
|
||||
console.log('uniapp登录凭证登录凭证登录凭证登录凭证',loginRes);
|
||||
|
||||
// #ifdef MP-ALIPAY
|
||||
getLoginCode(loginRes.code)
|
||||
// #endif
|
||||
// #ifdef MP-WEIXIN
|
||||
getLoginCode(loginRes.code)
|
||||
// #endif
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function getLoginCode(code){
|
||||
uni.showLoading({
|
||||
title: '加载中...',
|
||||
mask: true,
|
||||
duration:2000
|
||||
})
|
||||
// 以下为不存在缓存数据
|
||||
$getChannelUserId({isUseSubmchAccount:0,code:code}).then(({ bizData }) => {
|
||||
appConfig.channelUserId = bizData;
|
||||
uni.hideLoading()
|
||||
// 保存到localStorage
|
||||
if(bizData.channelUserIdCacheKey){
|
||||
storageManage.channelUserId(bizData.channelUserIdCacheKey, bizData)
|
||||
}
|
||||
if(vdata.amount >0) {
|
||||
pay()
|
||||
return false;
|
||||
}
|
||||
console.log(appConfig,'appConfigappConfig')
|
||||
}).catch(err => {
|
||||
uni.hideLoading()
|
||||
})
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.remark-model {
|
||||
position: fixed;
|
||||
height: 100vh;
|
||||
width: 100vw;
|
||||
z-index: 20;
|
||||
background-color: rgba(0,0,0,0.6);
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
.remark-content {
|
||||
height: 290rpx;
|
||||
width: 600rpx;
|
||||
background-color: #FFFFFF;
|
||||
border-radius: 20rpx;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
padding: 50rpx 0 20rpx 0;
|
||||
margin-bottom: 70%;
|
||||
.remark-content-title {
|
||||
font-weight: bold;
|
||||
font-size: 33rpx;
|
||||
letter-spacing: 0.05em;
|
||||
margin-left: 50rpx;
|
||||
}
|
||||
|
||||
.remark-content-body {
|
||||
margin-left: 50rpx;
|
||||
}
|
||||
|
||||
.remark-content-btn {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-around;
|
||||
margin-left: 20rpx;
|
||||
|
||||
text {
|
||||
width: 230rpx;
|
||||
height: 90rpx;
|
||||
border-radius: 10rpx;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.btn-cancel{
|
||||
background: #fff;
|
||||
border: 1rpx solid #c5c7cc;
|
||||
font-weight: 500;
|
||||
font-size: 30rpx;
|
||||
letter-spacing: 0.07em;
|
||||
color: #808080;
|
||||
}
|
||||
|
||||
.btn-confirm{
|
||||
border: 3rpx solid #0041c4;
|
||||
font-weight: 500;
|
||||
font-size: 30rpx;
|
||||
letter-spacing: 0.07em;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.content {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
|
||||
.content-top-bg {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
height: 212rpx;
|
||||
border-radius: 0 0 30rpx 30rpx;
|
||||
z-index: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.payment {
|
||||
// position: relative;
|
||||
// width: 650rpx;
|
||||
width: 96%;
|
||||
// height: 321rpx;
|
||||
margin-top: 20rpx;
|
||||
border-radius: 30rpx;
|
||||
background: #fff;
|
||||
z-index: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
.payment-mchName {
|
||||
width: 100%;
|
||||
// height: 105rpx;
|
||||
padding: 30rpx 0;
|
||||
font-size: 30rpx;
|
||||
letter-spacing: 0.04em;
|
||||
padding-left: 30rpx;
|
||||
color: #000;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.payment-divider {
|
||||
height: 1rpx;
|
||||
width: 100%;
|
||||
background-color: $uni-bg-color-grey;
|
||||
}
|
||||
.payment-amountTips {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
font-size: 25rpx;
|
||||
letter-spacing: 0.04em;
|
||||
text-align: left;
|
||||
padding: 30rpx 0 0 40rpx;
|
||||
color: rgba(0, 0, 0, 0.6);
|
||||
.desc{
|
||||
width: 50%;
|
||||
}
|
||||
.desc1{
|
||||
width: 30%;
|
||||
}
|
||||
.desc2{
|
||||
width: 70%;
|
||||
text-align: right;
|
||||
margin-right: 10%;
|
||||
color: #387CE7;
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
.payment-amount {
|
||||
padding: 15rpx 0 0 40rpx;
|
||||
|
||||
.payment-amount-value {
|
||||
font-size: 80rpx;
|
||||
letter-spacing: 0.03em;
|
||||
padding-left: 15rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
.payment-keyboard {
|
||||
width: 100%;
|
||||
position: fixed;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
z-index: 5;
|
||||
bottom: constant(safe-area-inset-bottom);
|
||||
bottom: env(safe-area-inset-bottom);
|
||||
|
||||
.buyer-remark {
|
||||
position: absolute;
|
||||
top : -80rpx;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
}
|
||||
}
|
||||
.payment-no-keyboard {
|
||||
width: 80%;
|
||||
height: 88rpx;
|
||||
position: fixed;
|
||||
left: 10%;
|
||||
right: 10%;
|
||||
bottom: 240rpx;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
font-size: 36rpx;
|
||||
color: $uni-text-color-inverse;
|
||||
border-radius: 8rpx;
|
||||
}
|
||||
.payment-text{
|
||||
margin-bottom: 16rpx;
|
||||
width: 92%;
|
||||
background: #FAFAFA;
|
||||
display: flex;
|
||||
padding:15px;
|
||||
color: #8F97A9;
|
||||
margin-left: 1%;
|
||||
.txt{
|
||||
width: 50%;
|
||||
}
|
||||
.payment-text-guanggao{
|
||||
text-align: left;
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.payment-text-amount{
|
||||
text-align: right;
|
||||
// margin-right: 10%;
|
||||
text{
|
||||
font-weight: 600;
|
||||
color: #000;
|
||||
}
|
||||
}
|
||||
}
|
||||
.pay-div-type{
|
||||
width: 96%;
|
||||
border-radius: 5%;
|
||||
margin-left: 1%;
|
||||
margin-top: 10px;
|
||||
background: #ffffff;
|
||||
.radio-group-box{
|
||||
padding: 20rpx;
|
||||
border-bottom: 2rpx solid #F4F4F4;
|
||||
.radio-group-div{
|
||||
width: 50%;
|
||||
}
|
||||
.radio-group-name{
|
||||
width: 70%;
|
||||
text-align: left;
|
||||
display: flex;
|
||||
image{
|
||||
width: 50rpx;
|
||||
height: 50rpx;
|
||||
border-radius: 50%;
|
||||
}
|
||||
text{
|
||||
padding: 8rpx 0 10rpx 10rpx ;
|
||||
}
|
||||
.radio-group-name-price{
|
||||
color: #c3c3c3;
|
||||
}
|
||||
}
|
||||
.radio-group-radio{
|
||||
width: 30%;
|
||||
text-align: right;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.payment-amountTips-price{
|
||||
display: flex;
|
||||
width: 100%;
|
||||
font-size: 25rpx;
|
||||
letter-spacing: 0.04em;
|
||||
text-align: left;
|
||||
padding: 30rpx 0 0 40rpx;
|
||||
color: rgba(0, 0, 0, 0.6);
|
||||
padding: 20rpx 0;
|
||||
.desc3{
|
||||
font-size: 21rpx;
|
||||
width: 50%;
|
||||
text-align: left;
|
||||
margin-left: 3%;
|
||||
color: #3D3D3D;
|
||||
.desc3-text1{
|
||||
border:2rpx solid #FE5735 ;
|
||||
border-radius: 10rpx;
|
||||
color: #FE5735;
|
||||
padding: 2rpx;
|
||||
}
|
||||
.desc3-text2{
|
||||
padding-left: 8rpx;
|
||||
}
|
||||
}
|
||||
.desc4{
|
||||
font-size: 30rpx;
|
||||
width: 50%;
|
||||
text-align: right;
|
||||
margin-left: 3%;
|
||||
margin-right: 20rpx;
|
||||
color: #3D3D3D;
|
||||
.desc4-text1{
|
||||
color: #8F97A9;
|
||||
font-size: 24rpx;
|
||||
// border:2rpx solid #FE5735 ;
|
||||
// border-radius: 10rpx;
|
||||
// color: #FE5735;
|
||||
padding: 2rpx;
|
||||
}
|
||||
.desc4-text2{
|
||||
font-weight: 600;
|
||||
padding-left: 8rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
.payment-mchName-img{
|
||||
width: 120rpx;
|
||||
height: 120rpx;
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
.payment-mchName1{
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
.payment-mchName2{
|
||||
font-size: 26rpx;
|
||||
margin-top: 15rpx;
|
||||
font-weight: 400;
|
||||
}
|
||||
.payment-mchName2-text1{
|
||||
color: #3598FE;
|
||||
border: 1px solid #3598FE;
|
||||
border-radius: 10rpx;
|
||||
padding: 4rpx 8rpx;
|
||||
}
|
||||
.payment-mchName2-text2{
|
||||
font-size: 28rpx;
|
||||
color: #3D3D3D;
|
||||
margin-left: 10rpx;
|
||||
}
|
||||
.scroll-view {
|
||||
width: 100%;
|
||||
}
|
||||
.scroll-content {
|
||||
display: inline-block;
|
||||
// width: 1000rpx; /* 设置一个足够大的宽度以确保文本可以滚动 */
|
||||
animation: slide 5s linear infinite;
|
||||
}
|
||||
@keyframes slide {
|
||||
0% {
|
||||
transform: translateX(0);
|
||||
}
|
||||
100% {
|
||||
transform: translateX(-100%);
|
||||
}
|
||||
}
|
||||
</style>
|
||||
BIN
jeepay-ui-uapp-cashier/static/alipay.png
Normal file
|
After Width: | Height: | Size: 1.4 KiB |
8
jeepay-ui-uapp-cashier/static/css/public.css
Normal file
@@ -0,0 +1,8 @@
|
||||
|
||||
/* 全局背景色 */
|
||||
html,
|
||||
body,
|
||||
page {
|
||||
height: 100%;
|
||||
background-color: #F5F7FA;
|
||||
}
|
||||
66
jeepay-ui-uapp-cashier/static/css/red_common.css
Normal file
@@ -0,0 +1,66 @@
|
||||
|
||||
page view {
|
||||
box-sizing: border-box;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
body {
|
||||
font-family: PingFangSC-Regular, Roboto, Helvetica Neue, Helvetica, Tahoma,
|
||||
Arial, PingFang SC-Light, Microsoft YaHei;
|
||||
margin: 0;
|
||||
}
|
||||
button {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
border: 1px solid transparent;
|
||||
outline: none;
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
button:active {
|
||||
opacity: 0.6;
|
||||
}
|
||||
.flex-col {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
.flex-row {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
}
|
||||
.justify-start {
|
||||
display: flex;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
.justify-center {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.justify-end {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
.justify-evenly {
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
}
|
||||
.justify-around {
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
}
|
||||
.justify-between {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
.align-start {
|
||||
display: flex;
|
||||
align-items: flex-start;
|
||||
}
|
||||
.align-center {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.align-end {
|
||||
display: flex;
|
||||
align-items: flex-end;
|
||||
}
|
||||
361
jeepay-ui-uapp-cashier/static/css/red_success.css
Normal file
@@ -0,0 +1,361 @@
|
||||
.page {
|
||||
background-color: rgba(255, 255, 255, 1);
|
||||
position: relative;
|
||||
width: 750rpx;
|
||||
height: 1624rpx;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.group_10 {
|
||||
height: 1624rpx;
|
||||
background: url(https://lanhu.oss-cn-beijing.aliyuncs.com/MasterDDSSlicePNG21c5ca80f552f09809d1d44675445954.png)
|
||||
100% no-repeat;
|
||||
background-size: 100% 100%;
|
||||
width: 750rpx;
|
||||
}
|
||||
|
||||
.group_11 {
|
||||
width: 750rpx;
|
||||
height: 714rpx;
|
||||
background: url(https://lanhu.oss-cn-beijing.aliyuncs.com/MasterDDSSlicePNG1d59307cf1f1af9624bfb9d5030af866.png)
|
||||
100% no-repeat;
|
||||
background-size: 100% 100%;
|
||||
margin-top: 604rpx;
|
||||
}
|
||||
|
||||
.section_15 {
|
||||
width: 448rpx;
|
||||
height: 32rpx;
|
||||
margin: 48rpx 0 0 152rpx;
|
||||
}
|
||||
|
||||
.block_9 {
|
||||
width: 112rpx;
|
||||
height: 2rpx;
|
||||
border: 1px solid rgba(247, 195, 117, 1);
|
||||
margin-top: 14rpx;
|
||||
}
|
||||
|
||||
.text_15 {
|
||||
width: 192rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(225, 96, 16, 1);
|
||||
font-size: 32rpx;
|
||||
font-family: MiSans-Bold;
|
||||
font-weight: 700;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
margin-left: 16rpx;
|
||||
}
|
||||
|
||||
.block_10 {
|
||||
width: 112rpx;
|
||||
height: 2rpx;
|
||||
border: 1px solid rgba(247, 195, 117, 1);
|
||||
margin: 14rpx 0 0 16rpx;
|
||||
}
|
||||
|
||||
.text_16 {
|
||||
width: 216rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(115, 73, 46, 1);
|
||||
font-size: 24rpx;
|
||||
font-family: PingFang SC-Regular;
|
||||
font-weight: normal;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
margin: 176rpx 0 0 268rpx;
|
||||
}
|
||||
|
||||
.section_16 {
|
||||
width: 464rpx;
|
||||
height: 2rpx;
|
||||
border: 1px solid rgba(200, 109, 52, 1);
|
||||
margin: 14rpx 0 410rpx 144rpx;
|
||||
}
|
||||
|
||||
.group_12 {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 750rpx;
|
||||
height: 1624rpx;
|
||||
}
|
||||
|
||||
.box_18 {
|
||||
position: relative;
|
||||
width: 750rpx;
|
||||
height: 1558rpx;
|
||||
}
|
||||
|
||||
.group_13 {
|
||||
width: 658rpx;
|
||||
height: 30rpx;
|
||||
margin: 30rpx 0 0 64rpx;
|
||||
}
|
||||
|
||||
.image_1 {
|
||||
width: 66rpx;
|
||||
height: 30rpx;
|
||||
}
|
||||
|
||||
.thumbnail_1 {
|
||||
width: 40rpx;
|
||||
height: 28rpx;
|
||||
margin: 2rpx 0 0 454rpx;
|
||||
}
|
||||
|
||||
.thumbnail_2 {
|
||||
width: 32rpx;
|
||||
height: 28rpx;
|
||||
margin: 2rpx 0 0 8rpx;
|
||||
}
|
||||
|
||||
.box_2 {
|
||||
height: 24rpx;
|
||||
background: url(https://lanhu-dds-backend.oss-cn-beijing.aliyuncs.com/merge_image/imgs/16890bbe294344c2b9415a85413483c8_mergeImage.png)
|
||||
100% no-repeat;
|
||||
background-size: 100% 100%;
|
||||
width: 50rpx;
|
||||
margin: 4rpx 0 0 8rpx;
|
||||
}
|
||||
|
||||
.section_3 {
|
||||
background-color: rgba(0, 0, 0, 1);
|
||||
border-radius: 1px;
|
||||
width: 38rpx;
|
||||
height: 16rpx;
|
||||
margin: 4rpx 0 0 4rpx;
|
||||
}
|
||||
|
||||
.group_14 {
|
||||
width: 702rpx;
|
||||
height: 104rpx;
|
||||
margin: 30rpx 0 0 36rpx;
|
||||
}
|
||||
|
||||
.thumbnail_3 {
|
||||
width: 18rpx;
|
||||
height: 34rpx;
|
||||
margin-top: 36rpx;
|
||||
}
|
||||
|
||||
.text_1 {
|
||||
width: 96rpx;
|
||||
height: 104rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(0, 0, 0, 1);
|
||||
font-size: 32rpx;
|
||||
font-family: Inter-Regular;
|
||||
font-weight: normal;
|
||||
text-align: center;
|
||||
margin-left: 274rpx;
|
||||
}
|
||||
|
||||
.image_2 {
|
||||
width: 174rpx;
|
||||
height: 64rpx;
|
||||
margin: 20rpx 0 0 140rpx;
|
||||
}
|
||||
|
||||
.group_15 {
|
||||
width: 172rpx;
|
||||
height: 144rpx;
|
||||
margin: 510rpx 0 0 292rpx;
|
||||
}
|
||||
|
||||
.section_5 {
|
||||
width: 58rpx;
|
||||
height: 74rpx;
|
||||
margin-top: 46rpx;
|
||||
}
|
||||
|
||||
.text_3 {
|
||||
text-shadow: 0px 3px 3px rgba(217, 142, 50, 0.3);
|
||||
background-image: linear-gradient(
|
||||
180deg,
|
||||
rgba(255, 115, 0, 1) 0,
|
||||
rgba(255, 49, 43, 1) 100%
|
||||
);
|
||||
width: 100rpx;
|
||||
height: 144rpx;
|
||||
overflow-wrap: break-word;
|
||||
font-size: 144rpx;
|
||||
font-family: MiSans-Bold;
|
||||
font-weight: 700;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
line-height: 144rpx;
|
||||
-webkit-background-clip: text;
|
||||
-webkit-text-fill-color: transparent;
|
||||
}
|
||||
|
||||
.group_16 {
|
||||
width: 462rpx;
|
||||
height: 144rpx;
|
||||
margin: 84rpx 0 482rpx 144rpx;
|
||||
}
|
||||
|
||||
.text-group_6 {
|
||||
width: 112rpx;
|
||||
height: 144rpx;
|
||||
}
|
||||
|
||||
.text_5 {
|
||||
width: 112rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(205, 94, 24, 1);
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC-Medium;
|
||||
font-weight: 500;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
}
|
||||
|
||||
.text_6 {
|
||||
width: 112rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(205, 94, 24, 1);
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC-Medium;
|
||||
font-weight: 500;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
margin-top: 24rpx;
|
||||
}
|
||||
|
||||
.text_7 {
|
||||
width: 112rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(159, 74, 20, 1);
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC-Medium;
|
||||
font-weight: 500;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
margin-top: 24rpx;
|
||||
}
|
||||
|
||||
.group_17 {
|
||||
width: 74rpx;
|
||||
height: 144rpx;
|
||||
}
|
||||
|
||||
.text-wrapper_17 {
|
||||
width: 74rpx;
|
||||
height: 32rpx;
|
||||
}
|
||||
|
||||
.text_8 {
|
||||
width: 28rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(205, 94, 24, 1);
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC-Medium;
|
||||
font-weight: 500;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
}
|
||||
|
||||
.text_9 {
|
||||
width: 46rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(205, 94, 24, 1);
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC-Medium;
|
||||
font-weight: 500;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
}
|
||||
|
||||
.text-wrapper_18 {
|
||||
width: 46rpx;
|
||||
height: 32rpx;
|
||||
margin: 24rpx 0 0 28rpx;
|
||||
}
|
||||
|
||||
.text_10 {
|
||||
width: 28rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(200, 109, 52, 1);
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC-Medium;
|
||||
font-weight: 500;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
}
|
||||
|
||||
.text_11 {
|
||||
width: 18rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(200, 109, 52, 1);
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC-Medium;
|
||||
font-weight: 500;
|
||||
text-align: right;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
}
|
||||
|
||||
.text-wrapper_19 {
|
||||
width: 62rpx;
|
||||
height: 32rpx;
|
||||
margin: 24rpx 0 0 12rpx;
|
||||
}
|
||||
|
||||
.text_12 {
|
||||
width: 28rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(159, 74, 20, 1);
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC-Medium;
|
||||
font-weight: 500;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
}
|
||||
|
||||
.text_13 {
|
||||
width: 34rpx;
|
||||
height: 32rpx;
|
||||
overflow-wrap: break-word;
|
||||
color: rgba(159, 74, 20, 1);
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC-Medium;
|
||||
font-weight: 500;
|
||||
text-align: right;
|
||||
white-space: nowrap;
|
||||
line-height: 32rpx;
|
||||
}
|
||||
|
||||
.box_8 {
|
||||
position: absolute;
|
||||
left: 276rpx;
|
||||
top: 742rpx;
|
||||
width: 88rpx;
|
||||
height: 88rpx;
|
||||
}
|
||||
|
||||
.image_3 {
|
||||
width: 750rpx;
|
||||
height: 68rpx;
|
||||
margin: 1556rpx 0 0 -750rpx;
|
||||
}
|
||||
30
jeepay-ui-uapp-cashier/static/iconImg/ali-none.svg
Normal file
@@ -0,0 +1,30 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 360 280" class="design-iconfont">
|
||||
<g clip-path="url(#euzspa6h6__clip0_625_247)">
|
||||
<path d="M333.562 167.271C333.562 197.901 308.559 222.672 277.372 222.672C276.835 222.672 272.264 222.672 238.658 222.672C215.267 222.672 177.897 222.672 118.212 222.672H89.7132C52.3426 223.471 22.5 193.906 22.5 158.215C22.5 122.257 52.6115 92.4259 90.5197 94.2904C123.051 -6.39042 271.995 7.72619 284.631 111.87C312.592 115.332 333.562 138.771 333.562 167.271Z" fill="url(#euzspa6h6__paint0_linear_625_247)"/>
|
||||
<path d="M280.406 222.688C311.821 222.688 337.5 198.04 337.5 167.562C337.5 137.085 311.821 112.438 280.406 112.438C248.991 112.438 223.312 137.085 223.312 167.562C223.312 198.04 248.991 222.688 280.406 222.688Z" fill="url(#euzspa6h6__paint1_linear_625_247)"/>
|
||||
<path d="M185.906 222.688C241.238 222.688 286.313 177.762 286.313 122.281C286.313 66.8007 241.238 21.875 185.906 21.875C130.575 21.875 85.5 66.8007 85.5 122.281C85.5 177.762 130.305 222.688 185.906 222.688Z" fill="url(#euzspa6h6__paint2_linear_625_247)"/>
|
||||
<path d="M149.922 138.342C160.264 131.712 172.462 128 185.456 128C220.99 128 249.894 156.639 249.894 192.173C249.894 227.707 220.99 256.346 185.456 256.346C149.922 256.346 121.017 227.707 121.017 192.173C120.487 169.633 132.155 150.01 149.922 138.342Z" fill="url(#euzspa6h6__paint3_linear_625_247)"/>
|
||||
<path d="M181.449 199.51C181.348 197.51 181.6 195.736 182.204 194.187C182.809 192.637 183.539 191.338 184.396 190.288C185.302 189.189 186.511 187.939 188.022 186.54C189.836 184.841 191.17 183.366 192.027 182.117C192.933 180.867 193.387 179.368 193.387 177.619C193.387 175.77 192.681 174.195 191.271 172.896C189.861 171.596 187.896 170.947 185.378 170.947C183.111 170.947 181.121 171.621 179.409 172.971C177.696 174.32 176.387 176.169 175.48 178.518L168 174.92C169.511 171.222 171.803 168.323 174.876 166.224C177.948 164.075 181.6 163 185.831 163C189.105 163 191.976 163.625 194.444 164.874C196.913 166.074 198.776 167.698 200.036 169.747C201.345 171.796 202 174.07 202 176.569C202 178.868 201.647 180.867 200.942 182.567C200.287 184.216 199.481 185.59 198.524 186.69C197.567 187.74 196.308 188.989 194.747 190.438C192.933 192.038 191.573 193.437 190.667 194.637C189.81 195.836 189.332 197.31 189.231 199.06L189.004 204.382H181.751L181.449 199.51ZM190.289 222H180.467V212.254H190.289V222Z" fill="#fff"/>
|
||||
</g>
|
||||
<defs>
|
||||
<linearGradient id="euzspa6h6__paint0_linear_625_247" x1="23715.3" y1="16824.8" x2="6888.77" y2="-1523.54" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F4F7FA"/>
|
||||
<stop offset="1" stop-color="#E8ECF3"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="euzspa6h6__paint1_linear_625_247" x1="13397.6" y1="9714.28" x2="555.901" y2="-179.453" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#E8ECF3"/>
|
||||
<stop offset="1" stop-color="#FAFBFE"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="euzspa6h6__paint2_linear_625_247" x1="23254" y1="18052.5" x2="85.4997" y2="-434.976" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#E8ECF3"/>
|
||||
<stop offset="1" stop-color="#FAFBFE"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="euzspa6h6__paint3_linear_625_247" x1="13554.6" y1="10501.2" x2="-985.647" y2="2289.87" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#AEB7C4"/>
|
||||
<stop offset="1" stop-color="#CFD5E0"/>
|
||||
</linearGradient>
|
||||
<clipPath id="euzspa6h6__clip0_625_247">
|
||||
<path fill="#fff" d="M0 0H360V280H0z"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 3.4 KiB |
4
jeepay-ui-uapp-cashier/static/iconImg/ali-resete.svg
Normal file
@@ -0,0 +1,4 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 28 28" class="design-iconfont">
|
||||
<path d="M21.4246 21.4246C19.5245 23.3248 16.8995 24.5 14 24.5C8.20102 24.5 3.5 19.799 3.5 14C3.5 8.20102 8.20102 3.5 14 3.5C16.8995 3.5 19.5245 4.67525 21.4246 6.57539C22.3918 7.54256 24.5 9.91667 24.5 9.91667" stroke="#1F7BFE" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M24.5 4.66699V9.91699H19.25" stroke="#1F7BFE" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 524 B |
63
jeepay-ui-uapp-cashier/static/iconImg/ali-success.svg
Normal file
@@ -0,0 +1,63 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 350 280" class="design-iconfont">
|
||||
<g clip-path="url(#bzjbuct8z__clip0_625_207)">
|
||||
<g opacity=".9">
|
||||
<path opacity=".331" d="M175 275.597C201.579 275.597 223.125 273.421 223.125 270.736C223.125 268.051 201.579 265.875 175 265.875C148.421 265.875 126.875 268.051 126.875 270.736C126.875 273.421 148.421 275.597 175 275.597Z" fill="#E1FFE4"/>
|
||||
<g opacity=".7794">
|
||||
<path opacity=".5988" d="M69.6115 203.264C72.7258 203.264 75.2504 202.48 75.2504 201.514C75.2504 200.547 72.7258 199.764 69.6115 199.764C66.4973 199.764 63.9727 200.547 63.9727 201.514C63.9727 202.48 66.4973 203.264 69.6115 203.264Z" fill="#51FFC0" fill-opacity=".5"/>
|
||||
<path opacity=".05" d="M64.6533 201.514C66.2088 202.194 73.7921 190.333 74.8616 187.222C75.931 184.111 74.7644 180.611 72.2366 179.541C69.7088 178.472 66.7921 180.125 65.7227 183.333C64.6533 186.541 63.0005 200.833 64.6533 201.514Z" fill="#1EFF5D"/>
|
||||
<path d="M64.944 201.514C66.8884 200.931 66.5968 184.111 65.6245 180.319C64.6523 176.528 61.444 174.194 58.3329 175.069C55.2218 175.944 53.569 179.736 54.444 183.528C55.319 187.319 62.9995 202.097 64.944 201.514Z" fill="url(#bzjbuct8z__paint0_linear_625_207)"/>
|
||||
</g>
|
||||
<path opacity=".4847" d="M55.6111 51.4996C55.2222 51.4996 54.8333 51.4996 54.4444 51.4023C53.9583 51.4996 53.4722 51.4996 52.9861 51.4996C45.5 51.4996 39.375 45.4718 39.375 37.8885C39.375 30.3051 45.4028 24.2773 52.9861 24.2773C53.8611 24.2773 54.7361 24.3746 55.5139 24.4718C58.625 18.6385 64.75 14.6523 71.8472 14.6523C81.9583 14.6523 90.2222 22.9162 90.2222 33.0273H101.111C106.167 33.0273 110.347 37.1107 110.347 42.2635C110.347 47.4162 106.264 51.4996 101.111 51.4996H55.6111Z" fill="url(#bzjbuct8z__paint1_linear_625_207)"/>
|
||||
<path d="M35 244C50.1667 221.736 64.75 210.556 78.5556 210.556C92.3611 210.556 108.208 221.736 126 244H35Z" fill="#DEFFE5"/>
|
||||
<path d="M88.8594 244C104.901 213.667 122.109 198.5 140.387 198.5C158.665 198.5 191.915 213.667 240.137 244H88.8594Z" fill="#DEFFE5"/>
|
||||
<path d="M315 244C298.278 220.278 282.431 208.417 267.653 208.417C252.875 208.417 228.958 220.278 196 244H315Z" fill="#DEFFE5"/>
|
||||
<path opacity=".6699" d="M262.5 179.25C264.916 179.25 266.875 178.64 266.875 177.888C266.875 177.137 264.916 176.527 262.5 176.527C260.084 176.527 258.125 177.137 258.125 177.888C258.125 178.64 260.084 179.25 262.5 179.25Z" fill="#51FFC0" fill-opacity=".5"/>
|
||||
<path opacity=".05" d="M258.71 177.889C259.974 178.375 265.71 169.917 266.585 167.681C267.46 165.444 266.487 163.014 264.64 162.236C262.793 161.458 260.46 162.722 259.585 164.958C258.71 167.097 257.543 177.403 258.71 177.889Z" fill="#1EFF5D"/>
|
||||
<path d="M258.514 177.888C260.07 177.5 259.778 165.638 259.098 163.013C258.417 160.388 255.792 158.638 253.459 159.222C251.126 159.805 249.764 162.527 250.445 165.152C251.126 167.777 257.056 178.277 258.514 177.888Z" fill="url(#bzjbuct8z__paint2_linear_625_207)"/>
|
||||
<g opacity=".8969">
|
||||
<path opacity=".5969" d="M276.4 273.75C279.568 273.75 282.136 272.966 282.136 272C282.136 271.034 279.568 270.25 276.4 270.25C273.232 270.25 270.664 271.034 270.664 272C270.664 272.966 273.232 273.75 276.4 273.75Z" fill="#51FFC0" fill-opacity=".5"/>
|
||||
<path opacity=".05" d="M272.32 272.292C274.362 273.07 284.181 258.778 285.64 254.986C287.098 251.195 285.543 247.014 282.237 245.75C278.931 244.486 275.14 246.528 273.681 250.32C272.223 254.111 270.279 271.514 272.32 272.292Z" fill="#1EFF5D"/>
|
||||
<path d="M272.318 272.389C274.943 271.709 274.555 251.584 273.291 247.112C272.027 242.639 267.652 239.625 263.568 240.695C259.485 241.764 257.249 246.334 258.513 250.903C259.777 255.473 269.693 273.07 272.318 272.389Z" fill="url(#bzjbuct8z__paint3_linear_625_207)"/>
|
||||
</g>
|
||||
<path opacity=".4847" d="M208.153 83.875H267.847C272.125 83.875 275.625 87.375 275.625 91.6528V132.097C275.625 136.375 272.125 139.875 267.847 139.875H208.153C203.875 139.875 200.375 136.375 200.375 132.097V91.6528C200.375 87.375 203.875 83.875 208.153 83.875Z" fill="url(#bzjbuct8z__paint4_linear_625_207)"/>
|
||||
<path d="M216.417 97.875H226.917C228.569 97.875 229.833 99.1389 229.833 100.792V102.347C229.833 104 228.569 105.264 226.917 105.264H216.417C214.764 105.264 213.5 104 213.5 102.347V100.792C213.5 99.1389 214.764 97.875 216.417 97.875Z" fill="url(#bzjbuct8z__paint5_linear_625_207)"/>
|
||||
<path d="M215.542 115.181H261.236C262.889 115.181 264.153 116.445 264.153 118.097V120.528C264.153 122.181 262.889 123.445 261.236 123.445H215.542C213.889 123.445 212.625 122.181 212.625 120.528V118.097C212.625 116.445 213.986 115.181 215.542 115.181Z" fill="url(#bzjbuct8z__paint6_linear_625_207)"/>
|
||||
<path d="M175.264 236.028C212.206 236.028 242.153 206.081 242.153 169.139C242.153 132.197 212.206 102.25 175.264 102.25C138.322 102.25 108.375 132.197 108.375 169.139C108.375 206.081 138.322 236.028 175.264 236.028Z" fill="#25D84C" fill-opacity=".1"/>
|
||||
<path d="M174.889 241.778C211.831 241.778 241.778 211.831 241.778 174.889C241.778 137.947 211.831 108 174.889 108C137.947 108 108 137.947 108 174.889C108 211.831 137.947 241.778 174.889 241.778Z" fill="#20C863"/>
|
||||
</g>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M162.879 199.477C162.918 199.518 162.957 199.558 162.997 199.598C165.053 201.654 167.95 202.357 170.582 201.707C170.648 201.69 170.714 201.673 170.779 201.655C172.073 201.3 173.296 200.614 174.312 199.597C174.343 199.567 174.373 199.536 174.403 199.505L208.252 165.657C211.376 162.533 211.376 157.467 208.252 154.343C205.127 151.219 200.062 151.219 196.938 154.343L168.655 182.626L157.657 171.628C154.533 168.504 149.467 168.504 146.343 171.628C143.219 174.752 143.219 179.818 146.343 182.942L162.879 199.477Z" fill="#fff"/>
|
||||
</g>
|
||||
<defs>
|
||||
<linearGradient id="bzjbuct8z__paint0_linear_625_207" x1="662.845" y1="174.768" x2="662.845" y2="2839.26" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#E6FDEE"/>
|
||||
<stop offset="1" stop-color="#FF522C"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="bzjbuct8z__paint1_linear_625_207" x1="3588.19" y1="14.4899" x2="3588.19" y2="3699.21" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#DEF3DA"/>
|
||||
<stop offset="1" stop-color="#2ECF2B"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="bzjbuct8z__paint2_linear_625_207" x1="719.233" y1="159.027" x2="719.233" y2="2037.99" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#E6FDEE"/>
|
||||
<stop offset="1" stop-color="#FF522C"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="bzjbuct8z__paint3_linear_625_207" x1="1063.76" y1="240.338" x2="1063.76" y2="3433.34" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#E6FDEE"/>
|
||||
<stop offset="1" stop-color="#FF522C"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="bzjbuct8z__paint4_linear_625_207" x1="3963.09" y1="83.6281" x2="3963.09" y2="5683.63" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#DEF3DA"/>
|
||||
<stop offset="1" stop-color="#2ECF2B"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="bzjbuct8z__paint5_linear_625_207" x1="1844.35" y1="470.149" x2="208.476" y2="470.149" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#fff" stop-opacity=".192"/>
|
||||
<stop offset="1" stop-color="#FFFFFD"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="bzjbuct8z__paint6_linear_625_207" x1="5365.14" y1="525.142" x2="212.15" y2="525.142" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#fff" stop-opacity=".192"/>
|
||||
<stop offset="1" stop-color="#FFFFFD"/>
|
||||
</linearGradient>
|
||||
<clipPath id="bzjbuct8z__clip0_625_207">
|
||||
<path fill="#fff" d="M0 0H350V280H0z"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 7.5 KiB |
1
jeepay-ui-uapp-cashier/static/iconImg/computer.svg
Normal file
@@ -0,0 +1 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="none" version="1.1" width="200" height="200" viewBox="0 0 200 200"><defs><mask id="master_svg0_57_4135"><g style="mix-blend-mode:passthrough"><rect x="0" y="0" width="200" height="200" rx="0" fill="#FFFFFF" fill-opacity="1"/></g></mask></defs><g style="mix-blend-mode:passthrough" mask="url(#master_svg0_57_4135)"><g style="mix-blend-mode:passthrough"><path d="M10.52284,39.31389Q9.5,41.7322,9.5,44.375L9.5,124.375Q9.5,127.0179,10.52284,129.4361Q11.50981,131.76999999999998,13.30761,133.567Q15.1054,135.365,17.43889,136.352Q19.857100000000003,137.375,22.5,137.375L98.5,137.375L98.5,170.375L62.5,170.375C61.6716,170.375,61,171.047,61,171.875C61,172.703,61.6716,173.375,62.5,173.375L137.5,173.375C138.328,173.375,139,172.703,139,171.875C139,171.047,138.328,170.375,137.5,170.375L101.5,170.375L101.5,137.375L177.5,137.375Q180.143,137.375,182.561,136.352Q184.895,135.365,186.692,133.567Q188.49,131.76999999999998,189.477,129.4361Q190.5,127.0179,190.5,124.375L190.5,44.375Q190.5,41.7322,189.477,39.31389Q188.49,36.9804,186.692,35.18261Q184.895,33.38481,182.561,32.39784Q180.143,31.375,177.5,31.375L22.5,31.375Q19.857100000000003,31.375,17.43889,32.39784Q15.10541,33.38482,13.30761,35.18261Q11.50982,36.98041,10.52284,39.31389ZM22.5,34.375C16.97715,34.375,12.5,38.85215,12.5,44.375L12.5,124.375C12.5,129.8979,16.97715,134.375,22.5,134.375L177.5,134.375C183.023,134.375,187.5,129.8979,187.5,124.375L187.5,44.375C187.5,38.85215,183.023,34.375,177.5,34.375L22.5,34.375ZM19.5,45.375Q19.5,43.7181,20.671599999999998,42.5466Q21.8431,41.375,23.5,41.375L176.5,41.375Q178.157,41.375,179.328,42.5466Q180.5,43.718199999999996,180.5,45.375L180.5,123.375Q180.5,125.0318,179.328,126.2034Q178.157,127.375,176.5,127.375L23.5,127.375Q21.8431,127.375,20.671599999999998,126.2034Q19.5,125.0319,19.5,123.375L19.5,45.375ZM22.5,45.375C22.5,44.8227,22.947699999999998,44.375,23.5,44.375L176.5,44.375C177.052,44.375,177.5,44.8227,177.5,45.375L177.5,123.375C177.5,123.9273,177.052,124.375,176.5,124.375L23.5,124.375C22.947699999999998,124.375,22.5,123.9273,22.5,123.375L22.5,45.375Z" fill-rule="evenodd" fill="#808080" fill-opacity="1"/></g></g></svg>
|
||||
|
After Width: | Height: | Size: 2.2 KiB |
10
jeepay-ui-uapp-cashier/static/iconImg/custom-time-icon.svg
Normal file
@@ -0,0 +1,10 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 41 40" class="design-iconfont">
|
||||
<path d="M6.5 16H34.5V31.5217C34.5 32.3382 33.8402 33 33.0263 33H7.97368C7.15979 33 6.5 32.3382 6.5 31.5217V16Z" stroke="#2980FD" stroke-width="2.5" stroke-linejoin="round"/>
|
||||
<path d="M6.5 8.5C6.5 7.67157 7.15979 7 7.97368 7H33.0263C33.8402 7 34.5 7.67157 34.5 8.5V16H6.5V8.5Z" stroke="#2980FD" stroke-width="2.5" stroke-linejoin="round"/>
|
||||
<path d="M14.5 5V11" stroke="#2980FD" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M26.5 5V11" stroke="#2980FD" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M23.5 27H27.5" stroke="#2980FD" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M13.5 27H17.5" stroke="#2980FD" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M23.5 21H27.5" stroke="#2980FD" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M13.5 21H17.5" stroke="#2980FD" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.1 KiB |
7
jeepay-ui-uapp-cashier/static/iconImg/default-img.svg
Normal file
@@ -0,0 +1,7 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 150 150" class="design-iconfont">
|
||||
<g opacity=".15" stroke="#000" stroke-width="5" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path d="M93.75 52.5H56.25C54.1789 52.5 52.5 54.1789 52.5 56.25V93.75C52.5 95.8211 54.1789 97.5 56.25 97.5H93.75C95.8211 97.5 97.5 95.8211 97.5 93.75V56.25C97.5 54.1789 95.8211 52.5 93.75 52.5Z"/>
|
||||
<path d="M67.5 73.75C70.9517 73.75 73.75 70.9517 73.75 67.5C73.75 64.0483 70.9517 61.25 67.5 61.25C64.0483 61.25 61.25 64.0483 61.25 67.5C61.25 70.9517 64.0483 73.75 67.5 73.75Z"/>
|
||||
<path d="M79.7376 77.7742C80.758 76.4085 82.816 76.4422 83.7911 77.8405L94.7596 93.57C95.9153 95.2274 94.7294 97.5 92.7089 97.5H65L79.7376 77.7742Z"/>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 752 B |
@@ -0,0 +1,3 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40" class="design-iconfont">
|
||||
<path d="M12 24L20 16L28 24" stroke="#000" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 217 B |
@@ -0,0 +1,3 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40" class="design-iconfont">
|
||||
<path d="M28 16L20 24L12 16" stroke="#fff" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 217 B |
@@ -0,0 +1,3 @@
|
||||
<svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M24 28L16 20L24 12" stroke="#808080" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 217 B |
@@ -0,0 +1,3 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 110 110" class="design-iconfont">
|
||||
<path d="M51 47L59 55L51 63" stroke="#999" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 217 B |
@@ -0,0 +1,3 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 108 40" class="design-iconfont">
|
||||
<path d="M50 12L58 20L50 28" stroke="#999" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 216 B |
10
jeepay-ui-uapp-cashier/static/iconImg/icon-calendar.svg
Normal file
@@ -0,0 +1,10 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40" class="design-iconfont">
|
||||
<path d="M6 16H34V31.5217C34 32.3382 33.3402 33 32.5263 33H7.47368C6.65979 33 6 32.3382 6 31.5217V16Z" stroke="#F5F5F5" stroke-width="2.5" stroke-linejoin="round"/>
|
||||
<path d="M6 8.5C6 7.67157 6.65979 7 7.47368 7H32.5263C33.3402 7 34 7.67157 34 8.5V16H6V8.5Z" stroke="#F5F5F5" stroke-width="2.5" stroke-linejoin="round"/>
|
||||
<path d="M14 5V11" stroke="#F5F5F5" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M26 5V11" stroke="#F5F5F5" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M23 27H27" stroke="#F5F5F5" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M13 27H17" stroke="#F5F5F5" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M23 21H27" stroke="#F5F5F5" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M13 21H17" stroke="#F5F5F5" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.0 KiB |
3
jeepay-ui-uapp-cashier/static/iconImg/icon-check.svg
Normal file
@@ -0,0 +1,3 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 36 36" class="design-iconfont">
|
||||
<path d="M12 18L16 22L24 14" stroke="#fff" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 215 B |
32
jeepay-ui-uapp-cashier/static/iconImg/icon-code.svg
Normal file
@@ -0,0 +1,32 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 60" class="design-iconfont">
|
||||
<defs>
|
||||
<clipPath id="3ftqpm40ea">
|
||||
<path data-name="矩形 3414" transform="translate(242 1064)" stroke="#707070" fill="#fff" d="M0 0H60V60H0z"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
<g data-name="蒙版组 15" transform="translate(-242 -1064)" clip-path="url(#3ftqpm40ea)">
|
||||
<g data-name="组 1189" transform="translate(246.167 1069)" fill="#fff">
|
||||
<rect data-name="矩形 3397" width="51.667" height="5" rx="1" transform="translate(0 19.167)"/>
|
||||
<g data-name="组 1187">
|
||||
<path data-name="矩形 3398" d="M2,0H5.833a0,0,0,0,1,0,0V16.667a0,0,0,0,1,0,0H0a0,0,0,0,1,0,0V2A2,2,0,0,1,2,0Z" transform="translate(1.667)" opacity=".7"/>
|
||||
<path data-name="矩形 3399" transform="translate(10)" opacity=".7" d="M0 0H3.333V16.667H0z"/>
|
||||
<path data-name="矩形 3400" transform="translate(15.834)" opacity=".7" d="M0 0H5V16.667H0z"/>
|
||||
<path data-name="矩形 3401" transform="translate(23.334)" opacity=".7" d="M0 0H14.167V16.667H0z"/>
|
||||
<path data-name="矩形 3402" d="M0,0H8a2,2,0,0,1,2,2V16.667a0,0,0,0,1,0,0H0a0,0,0,0,1,0,0V0A0,0,0,0,1,0,0Z" transform="translate(40)" opacity=".7"/>
|
||||
</g>
|
||||
<g data-name="组 1188">
|
||||
<path data-name="矩形 3403" d="M0,0H5A0,0,0,0,1,5,0V23.333a0,0,0,0,1,0,0H2a2,2,0,0,1-2-2V0A0,0,0,0,1,0,0Z" transform="translate(1.667 26.667)"/>
|
||||
<path data-name="矩形 3404" transform="translate(5 26.667)" d="M0 0H20V5H0z"/>
|
||||
<path data-name="矩形 3405" transform="translate(20.834 26.667)" d="M0 0H5V23.333H0z"/>
|
||||
<path data-name="矩形 3406" transform="translate(5.834 45)" d="M0 0H18.333V5H0z"/>
|
||||
<path data-name="矩形 3407" transform="translate(9.167 34.167)" d="M0 0H9.167V8.333H0z"/>
|
||||
<path data-name="矩形 3408" transform="translate(28.334 26.667)" d="M0 0H10.833V10.833H0z"/>
|
||||
<path data-name="矩形 3409" transform="translate(35.834 35.834)" d="M0 0H14.167V5H0z"/>
|
||||
<path data-name="矩形 3410" transform="translate(45.834 26.667)" d="M0 0H4.167V14.167H0z"/>
|
||||
<path data-name="矩形 3411" transform="translate(28.334 26.667)" d="M0 0H4.167V23.333H0z"/>
|
||||
<path data-name="矩形 3412" transform="translate(35 43.334)" d="M0 0H6.667V6.667H0z"/>
|
||||
<path data-name="矩形 3413" d="M0,0H5A0,0,0,0,1,5,0V4.667a2,2,0,0,1-2,2H0a0,0,0,0,1,0,0V0A0,0,0,0,1,0,0Z" transform="translate(45 43.334)"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 2.4 KiB |
14
jeepay-ui-uapp-cashier/static/iconImg/icon-delete.svg
Normal file
@@ -0,0 +1,14 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 51 37" class="design-iconfont">
|
||||
<defs>
|
||||
<clipPath id="ixxikwyx7a">
|
||||
<path data-name="矩形 2105" fill="none" d="M0 0H51V37H0z"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
<g data-name="组 1098">
|
||||
<g data-name="组 1097" clip-path="url(#ixxikwyx7a)" fill="#2c2c2c">
|
||||
<path data-name="路径 5229" d="M4716.382,4934.836a1.688,1.688,0,0,1-1.558-1.06,1.737,1.737,0,0,1,.366-1.869l10.219-10.395a1.668,1.668,0,0,1,2.376.01,1.737,1.737,0,0,1,.009,2.417l-10.219,10.4a1.672,1.672,0,0,1-1.193.5Zm0,0" transform="translate(-4691.476 -4909.443)"/>
|
||||
<path data-name="路径 5230" d="M4726.6,4934.726a1.667,1.667,0,0,1-1.193-.5l-10.219-10.395a1.736,1.736,0,0,1,0-2.427,1.666,1.666,0,0,1,2.386,0l10.219,10.395a1.737,1.737,0,0,1,.365,1.869,1.69,1.69,0,0,1-1.557,1.06Zm0,0" transform="translate(-4691.476 -4909.332)"/>
|
||||
<path data-name="路径 5231" d="M4472.326,4817.348h-28.967a5.562,5.562,0,0,1-4.31-2.051l-11.22-13.707a4.325,4.325,0,0,1-.949-2.684,4.214,4.214,0,0,1,.792-2.494c.02-.027.04-.054.062-.079l11.294-13.791a5.551,5.551,0,0,1,4.332-2.078h28.967a5.583,5.583,0,0,1,5.528,5.623v25.638a5.583,5.583,0,0,1-5.528,5.623Zm-41.96-18.869a.747.747,0,0,0-.112.429.834.834,0,0,0,.185.507l11.2,13.686a2.25,2.25,0,0,0,1.718.817h28.967a2.176,2.176,0,0,0,2.154-2.192v-25.638a2.176,2.176,0,0,0-2.154-2.191h-28.967a2.251,2.251,0,0,0-1.733.833Zm0,0" transform="translate(-4426.89 -4780.427)"/>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.4 KiB |
3
jeepay-ui-uapp-cashier/static/iconImg/icon-disable.svg
Normal file
@@ -0,0 +1,3 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 36 36" class="design-iconfont">
|
||||
<path d="M10 26L26 10" stroke="#D9D9D9" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 212 B |
5
jeepay-ui-uapp-cashier/static/iconImg/icon-more.svg
Normal file
@@ -0,0 +1,5 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 70 70" class="design-iconfont">
|
||||
<rect x="19" y="32" width="6" height="6" rx="1" fill="#000" fill-opacity=".5"/>
|
||||
<rect x="32" y="32" width="6" height="6" rx="1" fill="#000" fill-opacity=".5"/>
|
||||
<rect x="45" y="32" width="6" height="6" rx="1" fill="#000" fill-opacity=".5"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 350 B |
3
jeepay-ui-uapp-cashier/static/iconImg/icon-nav-left.svg
Normal file
@@ -0,0 +1,3 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 44 44" class="design-iconfont">
|
||||
<path d="M28.5 35L15.5 22L28.5 9" stroke="#000" stroke-width="4" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 220 B |
3
jeepay-ui-uapp-cashier/static/iconImg/icon-nav-white.svg
Normal file
@@ -0,0 +1,3 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 44 44" class="design-iconfont">
|
||||
<path d="M28.5 35L15.5 22L28.5 9" stroke="#fff" stroke-width="4" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 220 B |
@@ -0,0 +1,7 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 42 36" class="design-iconfont">
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M0.5 18C0.5 17.1716 1.17157 16.5 2 16.5H40C40.8284 16.5 41.5 17.1716 41.5 18C41.5 18.8284 40.8284 19.5 40 19.5H2C1.17157 19.5 0.5 18.8284 0.5 18Z" fill="#fff"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M3.5 2C3.5 1.17157 4.17157 0.5 5 0.5H16C16.8284 0.5 17.5 1.17157 17.5 2C17.5 2.82843 16.8284 3.5 16 3.5H6.5V11C6.5 11.8284 5.82843 12.5 5 12.5C4.17157 12.5 3.5 11.8284 3.5 11V2Z" fill="#fff" fill-opacity=".6"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M5 23.5C5.82843 23.5 6.5 24.1716 6.5 25V32.5H16C16.8284 32.5 17.5 33.1716 17.5 34C17.5 34.8284 16.8284 35.5 16 35.5H5C4.17157 35.5 3.5 34.8284 3.5 34V25C3.5 24.1716 4.17157 23.5 5 23.5Z" fill="#fff" fill-opacity=".6"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M24.5 2C24.5 1.17157 25.1716 0.5 26 0.5H37C37.8284 0.5 38.5 1.17157 38.5 2V11C38.5 11.8284 37.8284 12.5 37 12.5C36.1716 12.5 35.5 11.8284 35.5 11V3.5H26C25.1716 3.5 24.5 2.82843 24.5 2Z" fill="#fff" fill-opacity=".6"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M37 23.5C37.8284 23.5 38.5 24.1716 38.5 25V34C38.5 34.8284 37.8284 35.5 37 35.5H26C25.1716 35.5 24.5 34.8284 24.5 34C24.5 33.1716 25.1716 32.5 26 32.5H35.5V25C35.5 24.1716 36.1716 23.5 37 23.5Z" fill="#fff" fill-opacity=".6"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.4 KiB |
15
jeepay-ui-uapp-cashier/static/iconImg/icon-scan.svg
Normal file
@@ -0,0 +1,15 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 60" class="design-iconfont">
|
||||
<defs>
|
||||
<clipPath id="ka80l7163a">
|
||||
<path data-name="矩形 3396" transform="translate(78 1064)" stroke="#707070" fill="#fff" d="M0 0H60V60H0z"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
<g data-name="蒙版组 14" transform="translate(-78 -1064)" clip-path="url(#ka80l7163a)">
|
||||
<g data-name="组 1186" fill="#fff">
|
||||
<path data-name="矩形 3392" d="M2,0H46.333a2,2,0,0,1,2,2V23.333a0,0,0,0,1,0,0H0a0,0,0,0,1,0,0V2A2,2,0,0,1,2,0Z" transform="translate(83.833 1069)"/>
|
||||
<path data-name="矩形 3393" d="M2,0H46.333a2,2,0,0,1,2,2V23.333a0,0,0,0,1,0,0H0a0,0,0,0,1,0,0V2A2,2,0,0,1,2,0Z" transform="rotate(180 66.083 559.5)" opacity=".7"/>
|
||||
<path data-name="矩形 3394" d="M1,0H2.5a0,0,0,0,1,0,0V3.333a0,0,0,0,1,0,0H1a1,1,0,0,1-1-1V1A1,1,0,0,1,1,0Z" transform="translate(81.333 1092.333)"/>
|
||||
<path data-name="矩形 3395" d="M0,0H1.5a1,1,0,0,1,1,1V2.333a1,1,0,0,1-1,1H0a0,0,0,0,1,0,0V0A0,0,0,0,1,0,0Z" transform="translate(132.166 1092.333)"/>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.0 KiB |
3
jeepay-ui-uapp-cashier/static/iconImg/icon-screen.svg
Normal file
@@ -0,0 +1,3 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 26" class="design-iconfont">
|
||||
<path d="M105.569,19.679a2.623,2.623,0,0,1,.591-1.654l5.915-7.263a.605.605,0,0,0,.139-.382V9.321a.617.617,0,0,0-.623-.612H94.983a.617.617,0,0,0-.623.612v1.06a.6.6,0,0,0,.139.38l5.917,7.263a2.625,2.625,0,0,1,.591,1.655v8.2a.609.609,0,0,0,.343.547l4.223,2.075V19.679ZM94.98,6.672h16.606a2.676,2.676,0,0,1,2.7,2.65v1.06a2.623,2.623,0,0,1-.591,1.654L107.784,19.3a.605.605,0,0,0-.139.382V30.836a1.828,1.828,0,0,1-.886,1.562,1.9,1.9,0,0,1-1.818.081l-4.523-2.222a2.646,2.646,0,0,1-1.492-2.37v-8.2a.605.605,0,0,0-.139-.382l-5.911-7.265a2.621,2.621,0,0,1-.591-1.655V9.322a2.676,2.676,0,0,1,2.7-2.65Z" transform="translate(-92.284 -6.671)" fill="#666f80"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 741 B |
3
jeepay-ui-uapp-cashier/static/iconImg/icon-search.svg
Normal file
@@ -0,0 +1,3 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 25 26" class="design-iconfont">
|
||||
<path d="M81.569,59.244,76.042,53.73a11.238,11.238,0,1,0-1.4,1.213l5.611,5.6a.926.926,0,0,0,1.575-.648A.905.905,0,0,0,81.569,59.244ZM58.684,45.982a9.328,9.328,0,1,1,9.328,9.305A9.331,9.331,0,0,1,58.684,45.982Z" transform="translate(-56.832 -34.816)" fill="#666f80"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 361 B |
10
jeepay-ui-uapp-cashier/static/iconImg/icon-success.svg
Normal file
@@ -0,0 +1,10 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100" class="design-iconfont">
|
||||
<rect width="100" height="100" rx="50" fill="url(#ekca1sz58__paint0_linear_142_2608)"/>
|
||||
<path d="M29 54L44.3333 69L75 39" stroke="#fff" stroke-width="10" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<defs>
|
||||
<linearGradient id="ekca1sz58__paint0_linear_142_2608" x1="100" y1="0" x2="0" y2="100" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#2CE354"/>
|
||||
<stop offset="1" stop-color="#28B571"/>
|
||||
</linearGradient>
|
||||
</defs>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 558 B |
1
jeepay-ui-uapp-cashier/static/iconImg/icon-x-white.svg
Normal file
@@ -0,0 +1 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="none" version="1.1" width="50" height="50" viewBox="0 0 50 50"><defs><mask id="master_svg0_57_3608"><g style="mix-blend-mode:passthrough" transform="matrix(-1,0,0,1,100,0)"><rect x="50" y="0" width="50" height="50" rx="0" fill="#FFFFFF" fill-opacity="1"/></g></mask></defs><g style="mix-blend-mode:passthrough" mask="url(#master_svg0_57_3608)"><g style="mix-blend-mode:passthrough"><g style="mix-blend-mode:passthrough" transform="matrix(0.7071067690849304,0.7071067690849304,-0.7071067690849304,0.7071067690849304,12.585870129036252,-6.384550740631326)"><rect x="13.999769926071167" y="12.000213623046875" width="33.94084548950195" height="2.8284037113189697" rx="1.4142018556594849" fill="#fff" fill-opacity="1"/></g><g style="mix-blend-mode:passthrough" transform="matrix(-0.7071067690849304,0.7071067690849304,-0.7071067690849304,-0.7071067690849304,74.77071235856795,-2.971104132586447)"><rect x="38.00069236755371" y="13.999969482421875" width="33.94084548950195" height="2.8284037113189697" rx="1.4142018556594849" fill="#fff" fill-opacity="1"/></g></g></g></svg>
|
||||
|
After Width: | Height: | Size: 1.1 KiB |
1
jeepay-ui-uapp-cashier/static/iconImg/icon-x.svg
Normal file
@@ -0,0 +1 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="none" version="1.1" width="50" height="50" viewBox="0 0 50 50"><defs><mask id="master_svg0_57_3608"><g style="mix-blend-mode:passthrough" transform="matrix(-1,0,0,1,100,0)"><rect x="50" y="0" width="50" height="50" rx="0" fill="#FFFFFF" fill-opacity="1"/></g></mask></defs><g style="mix-blend-mode:passthrough" mask="url(#master_svg0_57_3608)"><g style="mix-blend-mode:passthrough"><g style="mix-blend-mode:passthrough" transform="matrix(0.7071067690849304,0.7071067690849304,-0.7071067690849304,0.7071067690849304,12.585870129036252,-6.384550740631326)"><rect x="13.999769926071167" y="12.000213623046875" width="33.94084548950195" height="2.8284037113189697" rx="1.4142018556594849" fill="#000000" fill-opacity="1"/></g><g style="mix-blend-mode:passthrough" transform="matrix(-0.7071067690849304,0.7071067690849304,-0.7071067690849304,-0.7071067690849304,74.77071235856795,-2.971104132586447)"><rect x="38.00069236755371" y="13.999969482421875" width="33.94084548950195" height="2.8284037113189697" rx="1.4142018556594849" fill="#000000" fill-opacity="1"/></g></g></g></svg>
|
||||
|
After Width: | Height: | Size: 1.1 KiB |
14
jeepay-ui-uapp-cashier/static/img/del.svg
Normal file
@@ -0,0 +1,14 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 51 37" class="design-iconfont">
|
||||
<defs>
|
||||
<clipPath id="xt74im3aca">
|
||||
<path data-name="矩形 2105" fill="none" d="M0 0H51V37H0z"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
<g data-name="组 1098">
|
||||
<g data-name="组 1097" clip-path="url(#xt74im3aca)" fill="#2c2c2c">
|
||||
<path data-name="路径 5229" d="M4716.382,4934.836a1.688,1.688,0,0,1-1.558-1.06,1.737,1.737,0,0,1,.366-1.869l10.219-10.395a1.668,1.668,0,0,1,2.376.01,1.737,1.737,0,0,1,.009,2.417l-10.219,10.4a1.672,1.672,0,0,1-1.193.5Zm0,0" transform="translate(-4691.476 -4909.443)"/>
|
||||
<path data-name="路径 5230" d="M4726.6,4934.726a1.667,1.667,0,0,1-1.193-.5l-10.219-10.395a1.736,1.736,0,0,1,0-2.427,1.666,1.666,0,0,1,2.386,0l10.219,10.395a1.737,1.737,0,0,1,.365,1.869,1.69,1.69,0,0,1-1.557,1.06Zm0,0" transform="translate(-4691.476 -4909.332)"/>
|
||||
<path data-name="路径 5231" d="M4472.326,4817.348h-28.967a5.562,5.562,0,0,1-4.31-2.051l-11.22-13.707a4.325,4.325,0,0,1-.949-2.684,4.214,4.214,0,0,1,.792-2.494c.02-.027.04-.054.062-.079l11.294-13.791a5.551,5.551,0,0,1,4.332-2.078h28.967a5.583,5.583,0,0,1,5.528,5.623v25.638a5.583,5.583,0,0,1-5.528,5.623Zm-41.96-18.869a.747.747,0,0,0-.112.429.834.834,0,0,0,.185.507l11.2,13.686a2.25,2.25,0,0,0,1.718.817h28.967a2.176,2.176,0,0,0,2.154-2.192v-25.638a2.176,2.176,0,0,0-2.154-2.191h-28.967a2.251,2.251,0,0,0-1.733.833Zm0,0" transform="translate(-4426.89 -4780.427)"/>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.4 KiB |
36
jeepay-ui-uapp-cashier/static/img/fail.svg
Normal file
@@ -0,0 +1,36 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<svg width="120px" height="83px" viewBox="0 0 120 83" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<title>编组 2</title>
|
||||
<defs>
|
||||
<path d="M32,5 C17.1060465,5 5,17.1060465 5,32 C5,46.8939535 17.1060465,59 32,59 C46.8939535,59 59,46.8939535 59,32 C59,17.1060465 46.8939535,5 32,5 Z" id="path-1"></path>
|
||||
<filter x="-14.8%" y="-7.4%" width="129.6%" height="129.6%" filterUnits="objectBoundingBox" id="filter-2">
|
||||
<feMorphology radius="1.5" operator="erode" in="SourceAlpha" result="shadowSpreadOuter1"></feMorphology>
|
||||
<feOffset dx="0" dy="4" in="shadowSpreadOuter1" result="shadowOffsetOuter1"></feOffset>
|
||||
<feGaussianBlur stdDeviation="3.5" in="shadowOffsetOuter1" result="shadowBlurOuter1"></feGaussianBlur>
|
||||
<feColorMatrix values="0 0 0 0 1 0 0 0 0 0.518902972 0 0 0 0 0 0 0 0 0.614210009 0" type="matrix" in="shadowBlurOuter1"></feColorMatrix>
|
||||
</filter>
|
||||
</defs>
|
||||
<g id="收银台" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
||||
<g id="1.3.3-扫码支付-生成流水号等系统异常失败--" transform="translate(-130.000000, -153.000000)">
|
||||
<g id="反馈:60/操作结果Result:6/提示备份" transform="translate(0.000000, 98.000000)">
|
||||
<g id="编组-2" transform="translate(130.000000, 55.000000)">
|
||||
<rect id="矩形" fill="#F0F2F4" x="67" y="0" width="53" height="37" rx="2"></rect>
|
||||
<rect id="矩形" fill="#FFFFFF" x="71" y="9" width="15" height="6"></rect>
|
||||
<rect id="矩形备份" fill="#FFFFFF" x="71" y="21" width="44" height="6"></rect>
|
||||
<g id="closed" transform="translate(29.000000, 16.000000)" fill-rule="nonzero">
|
||||
<path d="M32,0 C14.347907,0 0,14.347907 0,32 C0,49.652093 14.347907,64 32,64 C49.652093,64 64,49.652093 64,32 C64,14.347907 49.652093,0 32,0 Z" id="路径" fill="#FFFFFF"></path>
|
||||
<g id="路径">
|
||||
<use fill="black" fill-opacity="1" filter="url(#filter-2)" xlink:href="#path-1"></use>
|
||||
<use fill="#FF9243" xlink:href="#path-1"></use>
|
||||
</g>
|
||||
<path d="M34.1156352,45.985342 C34.7068404,45.4087948 35,44.7100977 35,43.8843648 C35,43.0684039 34.7019544,42.3599349 34.1156352,41.7687296 C33.52443,41.1775244 32.8159609,40.8794788 32,40.8794788 C31.1840391,40.8794788 30.47557,41.1775244 29.8843648,41.7687296 C29.2931596,42.3599349 29,43.0684039 29,43.8843648 C29,44.7052117 29.2980456,45.4039088 29.8843648,45.985342 C30.3387622,46.4250814 30.8615635,46.6986971 31.4429967,46.8013029 C31.6286645,46.8110749 31.8094463,46.8159609 32,46.8159609 C32.1905537,46.8159609 32.3713355,46.8110749 32.5570033,46.8013029 C33.1433225,46.6986971 33.6612378,46.4299674 34.1156352,45.985342 L34.1156352,45.985342 Z" id="路径" fill="#FFFFFF"></path>
|
||||
<path d="M34.1546338,36.6173171 C35.3848779,27.0115749 36,21.8818069 36,21.228013 C36,20.0162866 35.6286645,19.0130293 34.8794788,18.2052117 C34.1302932,17.4039088 33.1726384,17 32.0065147,17 C30.8403909,17 29.8827362,17.4104235 29.1270358,18.2247557 C28.3778502,19.0325733 28.0065147,20.0358306 28.0065147,21.228013 C28.0065147,21.8818292 28.6409027,27.011926 29.9096788,36.6183032 C30.0505743,37.6849226 30.9599456,38.4820847 32.0358306,38.4820847 C33.1106694,38.4820847 34.0181113,37.6834503 34.1546338,36.6173171 Z" id="路径" fill="#FFFFFF"></path>
|
||||
</g>
|
||||
<circle id="椭圆形" fill="#FF9243" cx="31.5" cy="14.5" r="2.5"></circle>
|
||||
<circle id="椭圆形备份" stroke="#FF9243" cx="15" cy="36" r="3"></circle>
|
||||
<path d="M6.85878336,16.1852886 C7.0450031,16.3715084 7.0450031,16.6741155 6.85878336,16.8603352 C6.67256363,17.0465549 6.37150838,17.0465549 6.18528864,16.8603352 L4.5,15.1734947 L2.81315953,16.8587834 C2.62693979,17.0450031 2.32588454,17.0450031 2.1396648,16.8587834 C1.95344507,16.6725636 1.95344507,16.3715084 2.1396648,16.1852886 L3.82650528,14.4984482 L2.14121664,12.8147114 C1.9549969,12.6284916 1.9549969,12.3258845 2.14121664,12.1396648 C2.32743637,11.9534451 2.63004345,11.9534451 2.81626319,12.1396648 L4.5,13.8249534 L6.18528864,12.1396648 C6.37150838,11.9534451 6.67411546,11.9534451 6.8603352,12.1396648 C7.04655493,12.3258845 7.04655493,12.6284916 6.8603352,12.8147114 L5.17504655,14.5 L6.85878336,16.1852886 Z" id="路径" stroke="#FF9243" stroke-width="0.5" fill="#FF9243" transform="translate(4.500000, 14.500000) rotate(-315.000000) translate(-4.500000, -14.500000) "></path>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 4.7 KiB |
5
jeepay-ui-uapp-cashier/static/img/note-icon.svg
Normal file
@@ -0,0 +1,5 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 40 40" class="design-iconfont">
|
||||
<path d="M9.6001 8.4802C9.6001 7.77327 10.1821 7.2002 10.9001 7.2002H21.8517C23.1644 7.2002 24.4244 7.7164 25.3597 8.63736L28.9081 12.1312C29.8626 13.071 30.4001 14.3545 30.4001 15.694V31.5202C30.4001 32.2271 29.8181 32.8002 29.1001 32.8002H10.9001C10.1821 32.8002 9.6001 32.2271 9.6001 31.5202V8.4802Z" stroke="#FF5F4D" stroke-width="2" stroke-linejoin="round"/>
|
||||
<path d="M15.2 17.6001H24.8" stroke="#FFA64D" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M15.2 23.2002H24.8" stroke="#FFA64D" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 698 B |
BIN
jeepay-ui-uapp-cashier/static/img/payred.png
Normal file
|
After Width: | Height: | Size: 2.1 KiB |
13
jeepay-ui-uapp-cashier/static/img/scan.svg
Normal file
@@ -0,0 +1,13 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 150 150" class="design-iconfont">
|
||||
<defs>
|
||||
<clipPath id="k8kvqmo4ja">
|
||||
<path data-name="矩形 2139" transform="translate(300 382)" fill="#fff" stroke="#707070" d="M0 0H150V150H0z"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
<g data-name="蒙版组 1" transform="translate(-300 -382)" clip-path="url(#k8kvqmo4ja)" fill="#212e2c">
|
||||
<path data-name="矩形 2130 - 轮廓" d="M10,10V40H40V10H10M10,0H40A10,10,0,0,1,50,10V40A10,10,0,0,1,40,50H10A10,10,0,0,1,0,40V10A10,10,0,0,1,10,0Z" transform="translate(300 482)" opacity=".25"/>
|
||||
<rect data-name="矩形 2131" width="150" height="10" rx="5" transform="translate(300 454)" opacity=".5"/>
|
||||
<path data-name="联合 30" d="M-1560,150h-14a5,5,0,0,1-5-5,5,5,0,0,1,5-5h14V102a5,5,0,0,1,5-5,5,5,0,0,1,5,5v38A10,10,0,0,1-1560,150Zm0-102V10h-38a5,5,0,0,1-5-5,5,5,0,0,1,5-5h38a10,10,0,0,1,10,10V48a5,5,0,0,1-5,5A5,5,0,0,1-1560,48Zm-140,0V10a10,10,0,0,1,10-10h38a5,5,0,0,1,5,5,5,5,0,0,1-5,5h-38V48a5,5,0,0,1-5,5A5,5,0,0,1-1700,48Z" transform="translate(2000 382)" opacity=".5"/>
|
||||
<rect data-name="矩形 2138" width="18" height="10" rx="5" transform="rotate(180 202.5 266)" opacity=".25"/>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.2 KiB |
@@ -0,0 +1,4 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 16 16" class="design-iconfont">
|
||||
<path d="M0 0H10.6C12.8498 0 13.9748 0 14.7634 0.572949C15.018 0.757988 15.242 0.98196 15.4271 1.23664C16 2.02524 16 3.15016 16 5.4V16H5.4C3.15016 16 2.02524 16 1.23664 15.4271C0.98196 15.242 0.757988 15.018 0.572949 14.7634C0 13.9748 0 12.8498 0 10.6V0Z" fill="#468FF5"/>
|
||||
<path d="M5.5 7.9L7.23913 9.5L10.5 6.5" stroke="#fff" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 503 B |
@@ -0,0 +1,3 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 15 16" class="design-iconfont">
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M7.92847 7.29272L1.56445 0.928711L0.857346 1.63582L7.22136 7.99983L0.857422 14.3638L1.56453 15.0709L7.92847 8.70694L14.2924 15.0708L14.9995 14.3637L8.63557 7.99983L14.9996 1.63585L14.2925 0.928741L7.92847 7.29272Z" fill="#000"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 384 B |
|
After Width: | Height: | Size: 12 KiB |
@@ -0,0 +1,10 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 30 30" class="design-iconfont">
|
||||
<rect width="30" height="30" rx="7" fill="url(#ue9ruwwl1__paint0_linear_254_95)"/>
|
||||
<path d="M12.8191 16.8558C12.7469 16.892 12.6655 16.9129 12.579 16.9129C12.3791 16.9129 12.2052 16.8036 12.1139 16.6423L12.079 16.5662L10.6226 13.3969C10.6068 13.3623 10.597 13.3234 10.597 13.2856C10.597 13.1395 10.7164 13.0209 10.8637 13.0209C10.9236 13.0209 10.9788 13.0406 11.0234 13.0735L12.7419 14.2869C12.8675 14.3685 13.0174 14.4163 13.1787 14.4163C13.2751 14.4163 13.3668 14.3985 13.4524 14.3675L21.5346 10.8C20.0861 9.10673 17.7 8 14.9999 8C10.5816 8 7 10.9601 7 14.6117C7 16.6041 8.07765 18.3973 9.7642 19.6093C9.89959 19.705 9.98807 19.8624 9.98807 20.04C9.98807 20.0987 9.97535 20.1526 9.96004 20.2085C9.82532 20.707 9.6096 21.5048 9.59955 21.5422C9.58276 21.6047 9.55641 21.6701 9.55641 21.7356C9.55641 21.8816 9.67591 22 9.82326 22C9.8813 22 9.92843 21.9787 9.97734 21.9508L11.7287 20.9481C11.8604 20.8726 11.9999 20.8259 12.1535 20.8259C12.2353 20.8259 12.3143 20.8384 12.3888 20.861C13.2057 21.094 14.0872 21.2236 14.9999 21.2236C19.4181 21.2236 23 18.2634 23 14.6117C23 13.5058 22.6696 12.4641 22.0888 11.548L12.8774 16.8224L12.8191 16.8558Z" fill="#fff"/>
|
||||
<defs>
|
||||
<linearGradient id="ue9ruwwl1__paint0_linear_254_95" x1="30" y1="24" x2="0" y2="0" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#00C800"/>
|
||||
<stop offset="1" stop-color="#AADF3B"/>
|
||||
</linearGradient>
|
||||
</defs>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.5 KiB |
14
jeepay-ui-uapp-cashier/static/img/selfcashier-san-code.svg
Normal file
@@ -0,0 +1,14 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30" class="design-iconfont">
|
||||
<rect width="30" height="30" rx="7" fill="url(#r3o43bqmv__paint0_linear_254_82)"/>
|
||||
<path d="M13.6667 9H9V13.6667H13.6667V9Z" stroke="#fff" stroke-width="1.5" stroke-linejoin="round"/>
|
||||
<path d="M13.6667 16.3333H9V20.9999H13.6667V16.3333Z" stroke="#fff" stroke-width="1.5" stroke-linejoin="round"/>
|
||||
<path d="M20.9997 9H16.333V13.6667H20.9997V9Z" stroke="#fff" stroke-width="1.5" stroke-linejoin="round"/>
|
||||
<path d="M16.667 16.3333V20.9999" stroke="#fff" stroke-width="1.5" stroke-linecap="round"/>
|
||||
<path d="M20.667 16.3333V20.9999" stroke="#fff" stroke-width="1.5" stroke-linecap="round"/>
|
||||
<defs>
|
||||
<linearGradient id="r3o43bqmv__paint0_linear_254_82" x1="30" y1="24" x2="0" y2="0" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#354268"/>
|
||||
<stop offset="1" stop-color="#3E5496"/>
|
||||
</linearGradient>
|
||||
</defs>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 944 B |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 13 KiB |
22
jeepay-ui-uapp-cashier/static/img/selfcashier-zfb-code.svg
Normal file
@@ -0,0 +1,22 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 38 32" class="design-iconfont">
|
||||
<rect width="30" height="30" rx="7" fill="url(#y1vhjy03w__paint0_linear_254_186)"/>
|
||||
<path d="M22 17.5278L17.4967 16.0135C17.4967 16.0135 17.8428 15.4954 18.2122 14.4797C18.5817 13.464 18.6346 12.9062 18.6346 12.9062L15.7195 12.8822V11.8865L19.2498 11.8616V11.1577H15.7188V9.55549H13.9897V11.1578H10.6958V11.8617L13.9897 11.8383V12.9062H11.3476V13.4639H16.7858C16.7858 13.4639 16.726 13.9165 16.5175 14.4797C16.3091 15.0428 16.0944 15.5359 16.0944 15.5359C16.0944 15.5359 13.5409 14.6422 12.1953 14.6422C10.8498 14.6422 9.21331 15.1828 9.05464 16.7516C8.89673 18.3196 9.81694 19.169 11.1134 19.4816C12.4099 19.7959 13.6069 19.4785 14.6491 18.9683C15.6914 18.4588 16.7142 17.3007 16.7142 17.3007L21.9626 19.8495C21.7485 21.093 20.6694 22.0013 19.4076 22H10.5923C9.16193 22.0014 8.00133 20.8429 8 19.4125V10.5924C7.99867 9.1619 9.15728 8.00128 10.5877 8H19.4076C20.8381 7.99869 21.9987 9.15723 22 10.5876L22 17.5278ZM15.4367 16.6505C15.4367 16.6505 13.7983 18.7188 11.8679 18.7188C9.93671 18.7188 9.53126 17.736 9.53126 17.0292C9.53126 16.3233 9.93273 15.5552 11.5759 15.4441C13.2181 15.3332 15.4375 16.6505 15.4375 16.6505H15.4367H15.4367Z" fill="#fff"/>
|
||||
<rect x="19" y="13" width="18" height="18" rx="5" fill="#184894"/>
|
||||
<g clip-path="url(#y1vhjy03w__clip0_254_186)" stroke="#fff">
|
||||
<path d="M27.1667 18.25H24.25V21.1667H27.1667V18.25Z" stroke-linejoin="round"/>
|
||||
<path d="M27.1667 22.8333H24.25V25.7499H27.1667V22.8333Z" stroke-linejoin="round"/>
|
||||
<path d="M31.7497 18.25H28.833V21.1667H31.7497V18.25Z" stroke-linejoin="round"/>
|
||||
<path d="M29.042 22.8333V25.7499" stroke-linecap="round"/>
|
||||
<path d="M31.542 22.8333V25.7499" stroke-linecap="round"/>
|
||||
</g>
|
||||
<rect x="19" y="13" width="18" height="18" rx="5" stroke="#fff" stroke-width="2"/>
|
||||
<defs>
|
||||
<linearGradient id="y1vhjy03w__paint0_linear_254_186" x1="30" y1="24" x2="0" y2="0" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#175CE6"/>
|
||||
<stop offset="1" stop-color="#66B3FF"/>
|
||||
</linearGradient>
|
||||
<clipPath id="y1vhjy03w__clip0_254_186">
|
||||
<path fill="#fff" transform="translate(23 17)" d="M0 0H10V10H0z"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 2.2 KiB |
20
jeepay-ui-uapp-cashier/static/img/selfcashier-zfb-pc.svg
Normal file
@@ -0,0 +1,20 @@
|
||||
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 38 32" class="design-iconfont">
|
||||
<rect width="30" height="30" rx="7" fill="url(#olcalueos__paint0_linear_254_187)"/>
|
||||
<path d="M22 17.5278L17.4967 16.0135C17.4967 16.0135 17.8428 15.4954 18.2122 14.4797C18.5817 13.464 18.6346 12.9062 18.6346 12.9062L15.7195 12.8822V11.8865L19.2498 11.8616V11.1577H15.7188V9.55549H13.9897V11.1578H10.6958V11.8617L13.9897 11.8383V12.9062H11.3476V13.4639H16.7858C16.7858 13.4639 16.726 13.9165 16.5175 14.4797C16.3091 15.0428 16.0944 15.5359 16.0944 15.5359C16.0944 15.5359 13.5409 14.6422 12.1953 14.6422C10.8498 14.6422 9.21331 15.1828 9.05464 16.7516C8.89673 18.3196 9.81694 19.169 11.1134 19.4816C12.4099 19.7959 13.6069 19.4785 14.6491 18.9683C15.6914 18.4588 16.7142 17.3007 16.7142 17.3007L21.9626 19.8495C21.7485 21.093 20.6694 22.0013 19.4076 22H10.5923C9.16193 22.0014 8.00133 20.8429 8 19.4125V10.5924C7.99867 9.1619 9.15728 8.00128 10.5877 8H19.4076C20.8381 7.99869 21.9987 9.15723 22 10.5876L22 17.5278ZM15.4367 16.6505C15.4367 16.6505 13.7983 18.7188 11.8679 18.7188C9.93671 18.7188 9.53126 17.736 9.53126 17.0292C9.53126 16.3233 9.93273 15.5552 11.5759 15.4441C13.2181 15.3332 15.4375 16.6505 15.4375 16.6505H15.4367H15.4367Z" fill="#fff"/>
|
||||
<rect x="19" y="13" width="18" height="18" rx="5" fill="#184894"/>
|
||||
<g clip-path="url(#olcalueos__clip0_254_187)" stroke="#fff">
|
||||
<path d="M28 24.0833V25.7499" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M25.917 25.75H30.0837" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<rect x="24.25" y="18.25" width="7.5" height="5.74365" rx="1"/>
|
||||
</g>
|
||||
<rect x="19" y="13" width="18" height="18" rx="5" stroke="#fff" stroke-width="2"/>
|
||||
<defs>
|
||||
<linearGradient id="olcalueos__paint0_linear_254_187" x1="30" y1="24" x2="0" y2="0" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#175CE6"/>
|
||||
<stop offset="1" stop-color="#66B3FF"/>
|
||||
</linearGradient>
|
||||
<clipPath id="olcalueos__clip0_254_187">
|
||||
<path fill="#fff" transform="translate(23 17)" d="M0 0H10V10H0z"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 2.0 KiB |
1
jeepay-ui-uapp-cashier/static/img/store.svg
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
jeepay-ui-uapp-cashier/static/img/success.png
Normal file
|
After Width: | Height: | Size: 5.8 KiB |
42
jeepay-ui-uapp-cashier/static/img/success.svg
Normal file
@@ -0,0 +1,42 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<svg width="120px" height="83px" viewBox="0 0 120 83" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<title>编组 2</title>
|
||||
<defs>
|
||||
<path d="M32,5 C17.1060465,5 5,17.1060465 5,32 C5,46.8939535 17.1060465,59 32,59 C46.8939535,59 59,46.8939535 59,32 C59,17.1060465 46.8939535,5 32,5 Z" id="path-1"></path>
|
||||
<filter x="-14.8%" y="-7.4%" width="129.6%" height="129.6%" filterUnits="objectBoundingBox" id="filter-2">
|
||||
<feMorphology radius="1.5" operator="erode" in="SourceAlpha" result="shadowSpreadOuter1"></feMorphology>
|
||||
<feOffset dx="0" dy="4" in="shadowSpreadOuter1" result="shadowOffsetOuter1"></feOffset>
|
||||
<feGaussianBlur stdDeviation="3.5" in="shadowOffsetOuter1" result="shadowBlurOuter1"></feGaussianBlur>
|
||||
<feColorMatrix values="0 0 0 0 0.0113015838 0 0 0 0 0.934952446 0 0 0 0 0.000623539169 0 0 0 0.731861888 0" type="matrix" in="shadowBlurOuter1"></feColorMatrix>
|
||||
</filter>
|
||||
<filter id="filter-3">
|
||||
<feColorMatrix in="SourceGraphic" type="matrix" values="0 0 0 0 1.000000 0 0 0 0 1.000000 0 0 0 0 1.000000 0 0 0 1.000000 0"></feColorMatrix>
|
||||
</filter>
|
||||
</defs>
|
||||
<g id="收银台" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
||||
<g id="1.3.4-收款成功--" transform="translate(-130.000000, -153.000000)">
|
||||
<g id="反馈:60/操作结果Result:6/提示备份" transform="translate(0.000000, 98.000000)">
|
||||
<g id="编组-2" transform="translate(130.000000, 55.000000)">
|
||||
<rect id="矩形" fill="#F0F2F4" x="67" y="0" width="53" height="37" rx="2"></rect>
|
||||
<rect id="矩形" fill="#FFFFFF" x="71" y="9" width="15" height="6"></rect>
|
||||
<rect id="矩形备份" fill="#FFFFFF" x="71" y="21" width="44" height="6"></rect>
|
||||
<g id="closed" transform="translate(29.000000, 16.000000)">
|
||||
<path d="M32,0 C14.347907,0 0,14.347907 0,32 C0,49.652093 14.347907,64 32,64 C49.652093,64 64,49.652093 64,32 C64,14.347907 49.652093,0 32,0 Z" id="路径" fill="#FFFFFF" fill-rule="nonzero"></path>
|
||||
<g id="路径" fill-rule="nonzero">
|
||||
<use fill="black" fill-opacity="1" filter="url(#filter-2)" xlink:href="#path-1"></use>
|
||||
<use fill="#0AB708" xlink:href="#path-1"></use>
|
||||
</g>
|
||||
<g filter="url(#filter-3)" id="成功">
|
||||
<g transform="translate(18.000000, 20.000000)">
|
||||
<path d="M22.8245333,3.57117059 L20.8698928,5.32781137 C15.2408998,10.6608064 10.7554893,17.2340206 10.7554893,17.2340206 L7.91606814,11.739717 C7.66688718,11.2575498 7.07858377,11.0621704 6.59046176,11.2994746 L1.58499823,13.7329185 C1.08830606,13.9743961 0.881406984,14.5727987 1.12287897,15.0694936 C1.2005994,15.2293604 1.31952878,15.3656208 1.46741936,15.4642425 C6.01899032,18.4994819 9.25745852,21.2039497 11.182824,23.5776459 L11.191598,23.5793639 C13.063896,20.158913 19.6054157,14.0412336 24.2765738,10.918372 L26.1119956,9.79744843 C26.449747,9.61506415 26.8550825,9.43440558 27.328002,9.25547274 C27.7158226,9.10876294 27.9728574,8.73792722 27.9741454,8.32328651 L27.9943586,1.81609925 C27.9961025,1.26380164 27.5497675,0.814685127 26.9974698,0.812969524 C26.8042534,0.812369335 26.6150004,0.867755897 26.452594,0.972432222 C24.8935592,1.97728222 23.6842169,2.84353857 22.8245669,3.57120127 L22.8245333,3.57117059 Z" id="形状" fill="#000000" fill-rule="nonzero"></path>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<circle id="椭圆形" fill="#0AB708" cx="31.5" cy="14.5" r="2.5"></circle>
|
||||
<circle id="椭圆形备份" stroke="#0AB708" cx="15" cy="36" r="3"></circle>
|
||||
<path d="M6.85878336,16.1852886 C7.0450031,16.3715084 7.0450031,16.6741155 6.85878336,16.8603352 C6.67256363,17.0465549 6.37150838,17.0465549 6.18528864,16.8603352 L4.5,15.1734947 L2.81315953,16.8587834 C2.62693979,17.0450031 2.32588454,17.0450031 2.1396648,16.8587834 C1.95344507,16.6725636 1.95344507,16.3715084 2.1396648,16.1852886 L3.82650528,14.4984482 L2.14121664,12.8147114 C1.9549969,12.6284916 1.9549969,12.3258845 2.14121664,12.1396648 C2.32743637,11.9534451 2.63004345,11.9534451 2.81626319,12.1396648 L4.5,13.8249534 L6.18528864,12.1396648 C6.37150838,11.9534451 6.67411546,11.9534451 6.8603352,12.1396648 C7.04655493,12.3258845 7.04655493,12.6284916 6.8603352,12.8147114 L5.17504655,14.5 L6.85878336,16.1852886 Z" id="路径" stroke="#0AB708" stroke-width="0.5" fill="#0AB708" transform="translate(4.500000, 14.500000) rotate(-315.000000) translate(-4.500000, -14.500000) "></path>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 4.8 KiB |
BIN
jeepay-ui-uapp-cashier/static/img/unselected.png
Normal file
|
After Width: | Height: | Size: 3.4 KiB |