Commit 5e72cfcc by 前端

合并

1 parent ecb6bc15
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: 前端 qianduan01@didihu.com.cn * @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2024-04-07 17:09:53 * @Date: 2024-04-07 17:09:53
* @LastEditors: 前端 qianduan01@didihu.com.cn * @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-12-21 14:41:41 * @LastEditTime: 2024-12-24 16:06:29
* @FilePath: \gl_tape\App.vue * @FilePath: \gl_tape\App.vue
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
--> -->
......
...@@ -2,19 +2,19 @@ import http from '../request/http' ...@@ -2,19 +2,19 @@ import http from '../request/http'
import { env } from '../../env' import { env } from '../../env'
const serverConfig = { const serverConfig = {
mockRequestCount: null, mockRequestCount: null,
mockTimer: {}, mockTimer: {},
mockCache: null, mockCache: null
}, },
bydServerConfig = { bydServerConfig = {
mockRequestCount: null, mockRequestCount: null,
mockTimer: {}, mockTimer: {},
mockCache: null, mockCache: null
}, },
boutiqueServerConfig = { boutiqueServerConfig = {
mockRequestCount: null, mockRequestCount: null,
mockTimer: {}, mockTimer: {},
mockCache: null, mockCache: null
}, },
configModule = 'app-tape', configModule = 'app-tape',
bydConfigModule = 'byd-pad-config', bydConfigModule = 'byd-pad-config',
...@@ -28,38 +28,38 @@ const getMockData = async (immediate = false) => { ...@@ -28,38 +28,38 @@ const getMockData = async (immediate = false) => {
const MOCKDATA = uni.$storage.get('mock_data') const MOCKDATA = uni.$storage.get('mock_data')
try { try {
if (!immediate && MOCKDATA && Date.now() - MOCKDATA.createTime < 5 * 60e3) { if (!immediate && MOCKDATA && Date.now() - MOCKDATA.createTime < 5 * 60e3) {
return Promise.resolve(MOCKDATA); return Promise.resolve(MOCKDATA)
} else { } else {
if (!serverConfig.mockRequestCount || immediate) { if (!serverConfig.mockRequestCount || immediate) {
serverConfig.mockCache = null; serverConfig.mockCache = null
serverConfig.mockRequestCount = Date.now(); serverConfig.mockRequestCount = Date.now()
const data = await http.uni_request({ url: configUrl }); const data = await http.uni_request({ url: configUrl })
data.createTime = Date.now(); data.createTime = Date.now()
data.moduleList = await imgToBase64(data.moduleList, 'thumbnail') data.moduleList = await imgToBase64(data.moduleList, 'thumbnail')
data.default_moduleList = await imgToBase64(data.default_moduleList, 'thumbnail') data.default_moduleList = await imgToBase64(data.default_moduleList, 'thumbnail')
serverConfig.mockCache = data; serverConfig.mockCache = data
uni.$storage.set('mock_data', data); uni.$storage.set('mock_data', data)
return Promise.resolve(data); return Promise.resolve(data)
} else { } else {
const key = Date.now(); const key = Date.now()
return new Promise((resolve) => { return new Promise(resolve => {
serverConfig.mockTimer[key] = setInterval(() => { serverConfig.mockTimer[key] = setInterval(() => {
if (serverConfig.mockCache) { if (serverConfig.mockCache) {
clearInterval(serverConfig.mockTimer[key]); clearInterval(serverConfig.mockTimer[key])
serverConfig.mockRequestCount = null; serverConfig.mockRequestCount = null
resolve(serverConfig.mockCache); resolve(serverConfig.mockCache)
} }
}, 1e3); }, 1e3)
}); })
} }
} }
} catch (error) { } catch (error) {
console.log(error) console.log(error)
if (serverConfig.mockTimer[key]) clearInterval(serverConfig.mockTimer[key]); if (serverConfig.mockTimer[key]) clearInterval(serverConfig.mockTimer[key])
serverConfig.mockRequestCount = null; serverConfig.mockRequestCount = null
return Promise.reject(error); return Promise.reject(error)
} }
}; }
const imgToBase64 = (list, urlKey) => { const imgToBase64 = (list, urlKey) => {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
let arr = [], let arr = [],
...@@ -71,20 +71,20 @@ const imgToBase64 = (list, urlKey) => { ...@@ -71,20 +71,20 @@ const imgToBase64 = (list, urlKey) => {
url: urlKey ? e[urlKey] : e, url: urlKey ? e[urlKey] : e,
method: 'GET', method: 'GET',
responseType: 'arraybuffer', responseType: 'arraybuffer',
success: (res) => { success: res => {
const base64 = `data:image/png;base64,${uni.arrayBufferToBase64(res.data)}` const base64 = `data:image/png;base64,${uni.arrayBufferToBase64(res.data)}`
newList[index][urlKey] = base64 newList[index][urlKey] = base64
newList[index][`original_${urlKey}`] = e[urlKey] newList[index][`original_${urlKey}`] = e[urlKey]
arr.push(e) arr.push(e)
if (arr.length === list.length) resolve(newList) if (arr.length === list.length) resolve(newList)
}, },
fail: (err) => { fail: err => {
reject(err) reject(err)
} }
}) })
}) })
}) })
}; }
const updateMockData = (dataList, keyList, storageName = 'mock_data') => { const updateMockData = (dataList, keyList, storageName = 'mock_data') => {
const mockData = uni.$storage.get(storageName) const mockData = uni.$storage.get(storageName)
keyList.map(key => { keyList.map(key => {
...@@ -101,72 +101,82 @@ const getBydMockData = async (immediate = false) => { ...@@ -101,72 +101,82 @@ const getBydMockData = async (immediate = false) => {
const MOCKDATA = uni.$storage.get('byd_mock_data') const MOCKDATA = uni.$storage.get('byd_mock_data')
try { try {
if (!immediate && MOCKDATA && Date.now() - MOCKDATA.createTime < 5 * 60e3) { if (!immediate && MOCKDATA && Date.now() - MOCKDATA.createTime < 5 * 60e3) {
return Promise.resolve(MOCKDATA); return Promise.resolve(MOCKDATA)
} else { } else {
if (!bydServerConfig.mockRequestCount || immediate) { if (!bydServerConfig.mockRequestCount || immediate) {
bydServerConfig.mockCache = null; bydServerConfig.mockCache = null
bydServerConfig.mockRequestCount = Date.now(); bydServerConfig.mockRequestCount = Date.now()
const data = await http.uni_request({ url: bydConfigUrl }); const data = await http.uni_request({ url: bydConfigUrl })
data.createTime = Date.now(); data.createTime = Date.now()
data.moduleList = await imgToBase64(data.moduleList, 'thumbnail') data.moduleList = await imgToBase64(data.moduleList, 'thumbnail')
bydServerConfig.mockCache = data; bydServerConfig.mockCache = data
uni.$storage.set('byd_mock_data', data); uni.$storage.set('byd_mock_data', data)
return Promise.resolve(data); return Promise.resolve(data)
} else { } else {
const key = Date.now(); const key = Date.now()
return new Promise((resolve) => { return new Promise(resolve => {
bydServerConfig.mockTimer[key] = setInterval(() => { bydServerConfig.mockTimer[key] = setInterval(() => {
if (bydServerConfig.mockCache) { if (bydServerConfig.mockCache) {
clearInterval(bydServerConfig.mockTimer[key]); clearInterval(bydServerConfig.mockTimer[key])
bydServerConfig.mockRequestCount = null; bydServerConfig.mockRequestCount = null
resolve(bydServerConfig.mockCache); resolve(bydServerConfig.mockCache)
} }
}, 1e3); }, 1e3)
}); })
} }
} }
} catch (error) { } catch (error) {
console.log(error) console.log(error)
if (bydServerConfig.mockTimer[key]) clearInterval(bydServerConfig.mockTimer[key]); if (bydServerConfig.mockTimer[key]) clearInterval(bydServerConfig.mockTimer[key])
bydServerConfig.mockRequestCount = null; bydServerConfig.mockRequestCount = null
return Promise.reject(error); return Promise.reject(error)
} }
} }
/** /**
*获取后台素材配置
*/
const findReceptionpriproConfigList = data => {
return http.post({
method: 'dj.api.smartcarlife.recepiton.customer.findReceptionpriproConfigList',
projectName: 'boutique',
...data
})
}
/**
*获取轻改配置 *获取轻改配置
*/ */
const getBoutiqueMockData = async (immediate = false) => { const getBoutiqueMockData = async (immediate = false) => {
const MOCKDATA = uni.$storage.get('boutique_mock_data') const MOCKDATA = uni.$storage.get('boutique_mock_data')
try { try {
if (!immediate && MOCKDATA && Date.now() - MOCKDATA.createTime < 5 * 60e3) { if (!immediate && MOCKDATA && Date.now() - MOCKDATA.createTime < 5 * 60e3) {
return Promise.resolve(MOCKDATA); return Promise.resolve(MOCKDATA)
} else { } else {
if (!boutiqueServerConfig.mockRequestCount || immediate) { if (!boutiqueServerConfig.mockRequestCount || immediate) {
boutiqueServerConfig.mockCache = null; boutiqueServerConfig.mockCache = null
boutiqueServerConfig.mockRequestCount = Date.now(); boutiqueServerConfig.mockRequestCount = Date.now()
const data = await http.uni_request({ url: boutiqueConfigUrl }); const data = await http.uni_request({ url: boutiqueConfigUrl })
data.createTime = Date.now(); data.createTime = Date.now()
boutiqueServerConfig.mockCache = data; boutiqueServerConfig.mockCache = data
uni.$storage.set('boutique_mock_data', data); uni.$storage.set('boutique_mock_data', data)
return Promise.resolve(data); return Promise.resolve(data)
} else { } else {
const key = Date.now(); const key = Date.now()
return new Promise((resolve) => { return new Promise(resolve => {
boutiqueServerConfig.mockTimer[key] = setInterval(() => { boutiqueServerConfig.mockTimer[key] = setInterval(() => {
if (boutiqueServerConfig.mockCache) { if (boutiqueServerConfig.mockCache) {
clearInterval(boutiqueServerConfig.mockTimer[key]); clearInterval(boutiqueServerConfig.mockTimer[key])
boutiqueServerConfig.mockRequestCount = null; boutiqueServerConfig.mockRequestCount = null
resolve(boutiqueServerConfig.mockCache); resolve(boutiqueServerConfig.mockCache)
} }
}, 1e3); }, 1e3)
}); })
} }
} }
} catch (error) { } catch (error) {
console.log(error) console.log(error)
if (boutiqueServerConfig.mockTimer[key]) clearInterval(boutiqueServerConfig.mockTimer[key]); if (boutiqueServerConfig.mockTimer[key]) clearInterval(boutiqueServerConfig.mockTimer[key])
boutiqueServerConfig.mockRequestCount = null; boutiqueServerConfig.mockRequestCount = null
return Promise.reject(error); return Promise.reject(error)
} }
} }
// 图片版本号 // 图片版本号
...@@ -181,5 +191,6 @@ module.exports = { ...@@ -181,5 +191,6 @@ module.exports = {
imgToBase64, imgToBase64,
updateMockData, updateMockData,
getBydMockData, getBydMockData,
getBoutiqueMockData
}
\ No newline at end of file \ No newline at end of file
getBoutiqueMockData,
findReceptionpriproConfigList
}

2.57 KB | W: | H:

4.13 KB | W: | H:

assets/images/point/crown_1.png
assets/images/point/crown_1.png
assets/images/point/crown_1.png
assets/images/point/crown_1.png
  • 2-up
  • Swipe
  • Onion skin

2.78 KB | W: | H:

4.99 KB | W: | H:

assets/images/point/crown_2.png
assets/images/point/crown_2.png
assets/images/point/crown_2.png
assets/images/point/crown_2.png
  • 2-up
  • Swipe
  • Onion skin

2.64 KB | W: | H:

4.47 KB | W: | H:

assets/images/point/crown_3.png
assets/images/point/crown_3.png
assets/images/point/crown_3.png
assets/images/point/crown_3.png
  • 2-up
  • Swipe
  • Onion skin

19.5 KB | W: | H:

83 KB | W: | H:

assets/images/point/day-ai.png
assets/images/point/day-ai.png
assets/images/point/day-ai.png
assets/images/point/day-ai.png
  • 2-up
  • Swipe
  • Onion skin

18.9 KB | W: | H:

80.6 KB | W: | H:

assets/images/point/day-course.png
assets/images/point/day-course.png
assets/images/point/day-course.png
assets/images/point/day-course.png
  • 2-up
  • Swipe
  • Onion skin

19.1 KB | W: | H:

83.8 KB | W: | H:

assets/images/point/day-ipad.png
assets/images/point/day-ipad.png
assets/images/point/day-ipad.png
assets/images/point/day-ipad.png
  • 2-up
  • Swipe
  • Onion skin

18.6 KB | W: | H:

82.2 KB | W: | H:

assets/images/point/day-report.png
assets/images/point/day-report.png
assets/images/point/day-report.png
assets/images/point/day-report.png
  • 2-up
  • Swipe
  • Onion skin

19.8 KB | W: | H:

82.4 KB | W: | H:

assets/images/point/day-study.png
assets/images/point/day-study.png
assets/images/point/day-study.png
assets/images/point/day-study.png
  • 2-up
  • Swipe
  • Onion skin

18.8 KB | W: | H:

80.6 KB | W: | H:

assets/images/point/day-time.png
assets/images/point/day-time.png
assets/images/point/day-time.png
assets/images/point/day-time.png
  • 2-up
  • Swipe
  • Onion skin

19.4 KB | W: | H:

84.3 KB | W: | H:

assets/images/point/day-training.png
assets/images/point/day-training.png
assets/images/point/day-training.png
assets/images/point/day-training.png
  • 2-up
  • Swipe
  • Onion skin

36.9 KB | W: | H:

114 KB | W: | H:

assets/images/point/point_bg.png
assets/images/point/point_bg.png
assets/images/point/point_bg.png
assets/images/point/point_bg.png
  • 2-up
  • Swipe
  • Onion skin

19.8 KB | W: | H:

40.7 KB | W: | H:

assets/images/point/star_grey.png
assets/images/point/star_grey.png
assets/images/point/star_grey.png
assets/images/point/star_grey.png
  • 2-up
  • Swipe
  • Onion skin
...@@ -81,7 +81,7 @@ export default { ...@@ -81,7 +81,7 @@ export default {
const res = await uni.$api.customerApi.haveCustomerAccess({ const res = await uni.$api.customerApi.haveCustomerAccess({
merchantId merchantId
}) })
if (res && this.tabs.length == 2) this.tabs.splice(2,0,{ if (res && this.tabs.length == 3) this.tabs.splice(2,0,{
label: "客户档案", label: "客户档案",
icon: "customer-file", icon: "customer-file",
}) })
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @Author: huyue * @Author: huyue
* @Date: 2024-04-08 11:30:30 * @Date: 2024-04-08 11:30:30
* @LastEditors: 前端 qianduan01@didihu.com.cn * @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-12-23 09:54:41 * @LastEditTime: 2024-12-25 14:33:54
--> -->
<template> <template>
<view class="point-box"> <view class="point-box">
...@@ -15,13 +15,13 @@ ...@@ -15,13 +15,13 @@
<view class="month-tabs"> <view class="month-tabs">
<view class="tab-prev" v-if="month <= currentMonth && month > 1" @click="prevTab"> <view class="tab-prev" v-if="month <= currentMonth && month > 1" @click="prevTab">
<view class="tab-icon"> <view class="tab-icon">
<uni-icons type="left" size="20"></uni-icons> <uni-icons type="left" size="16"></uni-icons>
</view> </view>
</view> </view>
<view class="tab-mid">{{ month == currentMonth ? '本' : (month + '').padStart(2, '0') }}月</view> <view class="tab-mid">{{ month == currentMonth ? '本' : (month + '').padStart(2, '0') }}月</view>
<view class="tab-next" v-if="month != currentMonth" @click="nextTab"> <view class="tab-next" v-if="month != currentMonth" @click="nextTab">
<view class="tab-icon"> <view class="tab-icon">
<uni-icons type="right" size="20"></uni-icons> <uni-icons type="right" size="16"></uni-icons>
</view> </view>
</view> </view>
</view> </view>
...@@ -139,6 +139,15 @@ export default { ...@@ -139,6 +139,15 @@ export default {
border-radius: 50%; border-radius: 50%;
height: 48rpx; height: 48rpx;
background: #ffffff; background: #ffffff;
.tab-icon {
margin-left: -4rpx;
margin-top: 4rpx;
}
}
.tab-next {
.tab-icon {
margin-left: 2rpx;
}
} }
} }
} }
...@@ -186,14 +195,16 @@ export default { ...@@ -186,14 +195,16 @@ export default {
background: #ffffff73; background: #ffffff73;
box-shadow: inset 0 0 16rpx 0 #ffffff; box-shadow: inset 0 0 16rpx 0 #ffffff;
border-radius: 32rpx; border-radius: 32rpx;
padding: 24rpx 48rpx; height: calc(100vh - 420rpx);
height: calc(100vh - 380rpx); overflow: hidden;
.item-header { .item-header {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
line-height: 56rpx; line-height: 56rpx;
margin-bottom: 26rpx; margin-bottom: 26rpx;
background: rgba($color: #fff, $alpha: 0.6);
padding: 24rpx 48rpx;
.point-class { .point-class {
font-size: 36rpx; font-size: 36rpx;
color: #1a1a1a; color: #1a1a1a;
...@@ -204,8 +215,9 @@ export default { ...@@ -204,8 +215,9 @@ export default {
} }
} }
.desc-wrap { .desc-wrap {
height: calc(100% - 102rpx); height: calc(100% - 152rpx);
overflow-y: auto; overflow-y: auto;
padding: 0 48rpx;
} }
.empty-box { .empty-box {
text-align: center; text-align: center;
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @Author: huyue * @Author: huyue
* @Date: 2024-04-08 11:30:30 * @Date: 2024-04-08 11:30:30
* @LastEditors: 前端 qianduan01@didihu.com.cn * @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-12-20 13:50:35 * @LastEditTime: 2024-12-25 17:00:42
--> -->
<template> <template>
<view class="point-box"> <view class="point-box">
...@@ -24,13 +24,13 @@ ...@@ -24,13 +24,13 @@
<view class="day-title">{{ i.typeName }}</view> <view class="day-title">{{ i.typeName }}</view>
<view class="day-content">{{ i.content }}</view> <view class="day-content">{{ i.content }}</view>
</view> </view>
<uni-icons type="checkmarkempty" v-if="i.completed"></uni-icons> <uni-icons type="checkmarkempty" v-if="i.completed" size="20"></uni-icons>
<view class="day-go" @click="handleGo(i)" v-else>去完成</view> <view class="day-go" @click="handleGo(i)" v-else>去完成</view>
</view> </view>
</view> </view>
<view class="dailog-panel" v-if="show"> <view class="dailog-panel" v-if="show">
<view class="dailog-box"> <view class="dailog-box">
<view class="dailog-close" @click="show = false"><uni-icons type="closeempty" size="30"></uni-icons></view> <view class="dailog-close" @click="show = false"><uni-icons type="closeempty" size="20"></uni-icons></view>
<view class="dailog-logo"><image :src="selectItem.logo"></image></view> <view class="dailog-logo"><image :src="selectItem.logo"></image></view>
<view class="dailog-title">{{ selectItem.typeName }}</view> <view class="dailog-title">{{ selectItem.typeName }}</view>
<view class="dailog-content">{{ selectItem.rules }}</view> <view class="dailog-content">{{ selectItem.rules }}</view>
...@@ -128,10 +128,10 @@ export default { ...@@ -128,10 +128,10 @@ export default {
width: 50%; width: 50%;
transform: translate(-50%, -50%); transform: translate(-50%, -50%);
background: #fff; background: #fff;
background-image: linear-gradient(179deg, #d6e9ff 12%, #ffffff00 100%); /* 顶部渐变和底部白色 */ background-image: linear-gradient(179deg, #d6e9ff 12%, #ffffff 100%); /* 顶部渐变和底部白色 */
background-size: background-size:
100% 160rpx, 100% 110rpx,
100% calc(100% - 160rpx); /* 分别设置渐变和白色的背景大小 */ 100% calc(100% - 110rpx); /* 分别设置渐变和白色的背景大小 */
background-repeat: no-repeat, no-repeat; /* 确保背景不重复 */ background-repeat: no-repeat, no-repeat; /* 确保背景不重复 */
background-position: top, bottom; /* 分别设置渐变和白色的位置 */ background-position: top, bottom; /* 分别设置渐变和白色的位置 */
border-radius: 48rpx; border-radius: 48rpx;
...@@ -161,7 +161,9 @@ export default { ...@@ -161,7 +161,9 @@ export default {
font-size: 32rpx; font-size: 32rpx;
color: #808291; color: #808291;
text-align: center; text-align: center;
line-height: 60rpx; line-height: 46rpx;
margin-top: 16rpx;
padding: 0 64rpx;
} }
.dailog-footer { .dailog-footer {
display: flex; display: flex;
...@@ -216,6 +218,7 @@ export default { ...@@ -216,6 +218,7 @@ export default {
font-size: 36rpx; font-size: 36rpx;
color: #1a1a1a; color: #1a1a1a;
margin-left: 160rpx; margin-left: 160rpx;
font-weight: 700;
text { text {
font-size: 64rpx; font-size: 64rpx;
color: #4673ff; color: #4673ff;
...@@ -236,8 +239,8 @@ export default { ...@@ -236,8 +239,8 @@ export default {
align-items: center; align-items: center;
.day-logo { .day-logo {
image { image {
width: 76rpx; width: 80rpx;
height: 76rpx; height: 80rpx;
margin-right: 20rpx; margin-right: 20rpx;
} }
} }
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @Author: huyue * @Author: huyue
* @Date: 2024-04-08 11:30:30 * @Date: 2024-04-08 11:30:30
* @LastEditors: 前端 qianduan01@didihu.com.cn * @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-12-21 10:10:29 * @LastEditTime: 2024-12-25 17:35:05
--> -->
<template> <template>
<view class="point-box"> <view class="point-box">
...@@ -38,13 +38,15 @@ ...@@ -38,13 +38,15 @@
<view class="level-item" :style="index == levelIndex || isHigh ? item.style : ''" v-for="(item, index) in levelList" :key="index"> <view class="level-item" :style="index == levelIndex || isHigh ? item.style : ''" v-for="(item, index) in levelList" :key="index">
<image class="my-level" v-if="index == levelIndex"" :src="require('@/assets/images/point/my_level.png')" /> <image class="my-level" v-if="index == levelIndex"" :src="require('@/assets/images/point/my_level.png')" />
<view class="item-name" :style="index == levelIndex || isHigh ? item.titleStyle : ''">{{ item.title }}</view> <view class="item-name" :style="index == levelIndex || isHigh ? item.titleStyle : ''">{{ item.title }}</view>
<view class="item-logo"><image :src="index == levelIndex || isHigh ? item.logo : item.logo_grey"></image></view> <view class="item-logo"><image mode="widthFix" :src="index == levelIndex || isHigh ? item.logo : item.logo_grey"></image></view>
<view class="item-footer">
<view :class="{ 'item-desc': true, grey: index != levelIndex && !isHigh }">{{ item.content }}</view> <view :class="{ 'item-desc': true, grey: index != levelIndex && !isHigh }">{{ item.content }}</view>
<view class="item-detail" :style="index == levelIndex || isHigh ? item.detailStyle : ''"> <view class="item-detail" :style="index == levelIndex || isHigh ? item.detailStyle : 'background:#efeff1'">
<ul> <ul>
<li class="item-coupon" v-for="(coupon, index) in item.coupon.list" :key="index">{{ coupon }}</li> <li class="item-coupon" v-for="(coupon, index) in item.coupon.list" :key="index">{{ coupon }}</li>
</ul> </ul>
</view> </view>
</view>
</view> </view>
</view> </view>
</view> </view>
...@@ -88,7 +90,7 @@ export default { ...@@ -88,7 +90,7 @@ export default {
title: '青铜级萌新', title: '青铜级萌新',
titleStyle: 'background: linear-gradient(129deg, #88696B 13%, #665253 91%);color: transparent; background-clip: text;-webkit-background-clip: text; ', titleStyle: 'background: linear-gradient(129deg, #88696B 13%, #665253 91%);color: transparent; background-clip: text;-webkit-background-clip: text; ',
content: '每月度奖励', content: '每月度奖励',
detailStyle: 'color: #995737;background-image: linear-gradient(93deg, rgba(255, 255, 255, 0.3) 2%, rgba(255, 255, 255, 0.5) 51%, rgba(255, 255, 255, 0.15) 99%);', detailStyle: 'color: #995737;background-image: linear-gradient(93deg, #ffffff2e 2%, #ffffff4d 51%, #ffffff17 99%);',
coupon: { coupon: {
list: ['咖啡奶茶券 1 张', '美团外卖直兑券 1 张'] list: ['咖啡奶茶券 1 张', '美团外卖直兑券 1 张']
}, },
...@@ -99,7 +101,7 @@ export default { ...@@ -99,7 +101,7 @@ export default {
{ {
title: '白银级熟手', title: '白银级熟手',
titleStyle: 'background: linear-gradient(129deg, #4A668F 13%, #333B43 91%);color: transparent; background-clip: text;webkit-background-clip: text;', titleStyle: 'background: linear-gradient(129deg, #4A668F 13%, #333B43 91%);color: transparent; background-clip: text;webkit-background-clip: text;',
detailStyle: 'color: #556985;background-image: linear-gradient(93deg, rgba(255, 255, 255, 0.3) 2%, rgba(255, 255, 255, 0.5) 51%, rgba(255, 255, 255, 0.15) 99%);;', detailStyle: 'color: #556985;background-image: linear-gradient(93deg, #ffffff2e 2%, #ffffff4d 51%, #ffffff17 99%);',
content: '每月度奖励', content: '每月度奖励',
coupon: { coupon: {
list: ['咖啡奶茶券 2 张', '美团外卖直兑券 2 张'], list: ['咖啡奶茶券 2 张', '美团外卖直兑券 2 张'],
...@@ -113,7 +115,7 @@ export default { ...@@ -113,7 +115,7 @@ export default {
title: '黄金级能手', title: '黄金级能手',
titleStyle: 'background: linear-gradient(129deg, #B17813 13%, #794308 91%);color: transparent; background-clip: text;webkit-background-clip: text;', titleStyle: 'background: linear-gradient(129deg, #B17813 13%, #794308 91%);color: transparent; background-clip: text;webkit-background-clip: text;',
content: '每月度奖励', content: '每月度奖励',
detailStyle: 'color: #855A1B;background-image: linear-gradient(97deg, rgba(255, 255, 255, 0.3) 2%, rgba(255, 255, 255, 0.5) 51%, rgba(255, 255, 255, 0.15) 99%);', detailStyle: 'color: #855A1B;background-image: linear-gradient(97deg, #ffffff2e 2%, #ffffff4d 51%, #ffffff17 99%);',
coupon: { coupon: {
list: ['拥有晋升、评优资格', '咖啡奶茶券 4 张', '生日月专享生日餐券', '美团外卖直兑券 4 张', '公司定制公仔礼包'], list: ['拥有晋升、评优资格', '咖啡奶茶券 4 张', '生日月专享生日餐券', '美团外卖直兑券 4 张', '公司定制公仔礼包'],
style: 'color: #995737' style: 'color: #995737'
...@@ -126,7 +128,7 @@ export default { ...@@ -126,7 +128,7 @@ export default {
title: '钻石级专家', title: '钻石级专家',
content: '每月度奖励', content: '每月度奖励',
titleStyle: 'background: linear-gradient(111deg, #E7E8FD 11%, #C7CDF2 53%, #F4D8E8 100%);color: transparent; background-clip: text;webkit-background-clip: text;', titleStyle: 'background: linear-gradient(111deg, #E7E8FD 11%, #C7CDF2 53%, #F4D8E8 100%);color: transparent; background-clip: text;webkit-background-clip: text;',
detailStyle: 'color: #E7E8FD;background: rgba(255, 255, 255, .5);', detailStyle: 'color: #E7E8FD;background: rgba(255, 255, 255, .12);',
coupon: { coupon: {
list: ['拥有晋升、评优资格', '咖啡奶茶券 6 张', '生日月专享生日餐券', '闭门课分享活动参加资格', '美团外卖直兑券 6 张', '公司定制公仔礼包'], list: ['拥有晋升、评优资格', '咖啡奶茶券 6 张', '生日月专享生日餐券', '闭门课分享活动参加资格', '美团外卖直兑券 6 张', '公司定制公仔礼包'],
style: 'color: #995737' style: 'color: #995737'
...@@ -137,10 +139,10 @@ export default { ...@@ -137,10 +139,10 @@ export default {
} }
], ],
groupList: [ groupList: [
{ title: '学习之星', medalType: 1, logo: require('@/assets/images/point/study_star.png'), logo_grey: require('@/assets/images/point/study_grey.png'), content: '月度学习类积分排名前10名', couponName: '50元话费券', couponNum: '1张' }, { title: '学习之星',style:'background: #FFFAED;', medalType: 1, logo: require('@/assets/images/point/study_star.png'), logo_grey: require('@/assets/images/point/study_grey.png'), content: '月度学习类积分排名前10名', couponName: '50元话费券', couponNum: '1张' },
{ title: '全勤之星', medalType: 2, logo: require('@/assets/images/point/time_star.png'), logo_grey: require('@/assets/images/point/time_grey.png'), content: '当月全勤准时打卡,不包含请假特批', couponName: '50元饮品券', couponNum: '1张' }, { title: '全勤之星',style:'background: #FFFAED;', medalType: 2, logo: require('@/assets/images/point/time_star.png'), logo_grey: require('@/assets/images/point/time_grey.png'), content: '当月全勤准时打卡,不包含请假特批', couponName: '50元饮品券', couponNum: '1张' },
{ title: '零售导师', medalType: 3, logo: require('@/assets/images/point/teacher_star.png'), logo_grey: require('@/assets/images/point/teacher_grey.png'), content: '分享授课类积分前10名', couponName: '50元加油券', couponNum: '1张' }, { title: '零售导师', style:'background: #FFFAED;',medalType: 3, logo: require('@/assets/images/point/teacher_star.png'), logo_grey: require('@/assets/images/point/teacher_grey.png'), content: '分享授课类积分前10名', couponName: '50元加油券', couponNum: '1张' },
{ title: '平板接待精英', medalType: 4, logo: require('@/assets/images/point/elite_star.png'), logo_grey: require('@/assets/images/point/elite_grey.png'), content: '平板接待月度无扣分记录', couponName: '50元水果券', couponNum: '1张' } { title: '平板接待精英',style:'background: #FFFAED;', medalType: 4, logo: require('@/assets/images/point/elite_star.png'), logo_grey: require('@/assets/images/point/elite_grey.png'), content: '平板接待月度无扣分记录', couponName: '50元水果券', couponNum: '1张' }
], ],
badgeList: [] badgeList: []
} }
...@@ -244,7 +246,7 @@ export default { ...@@ -244,7 +246,7 @@ export default {
line-height: 44rpx; line-height: 44rpx;
width: 64rpx; width: 64rpx;
text-align: center; text-align: center;
margin-top: 16prx; margin-top: 16rpx;
} }
} }
.level-desc { .level-desc {
...@@ -260,7 +262,6 @@ export default { ...@@ -260,7 +262,6 @@ export default {
padding: 56rpx 48rpx; padding: 56rpx 48rpx;
.level-item { .level-item {
background: #f7f7f7; background: #f7f7f7;
border: 4rpx solid #ffffff33;
border-radius: 36rpx; border-radius: 36rpx;
position: relative; position: relative;
.my-level { .my-level {
...@@ -330,6 +331,7 @@ export default { ...@@ -330,6 +331,7 @@ export default {
text-align: center; text-align: center;
font-size: 40rpx; font-size: 40rpx;
line-height: 60rpx; line-height: 60rpx;
margin-top: 4rpx;
color: #292d33; color: #292d33;
font-weight: 600; font-weight: 600;
&.grey { &.grey {
...@@ -348,24 +350,25 @@ export default { ...@@ -348,24 +350,25 @@ export default {
.item-logo { .item-logo {
position: absolute; position: absolute;
top: 0rpx; top: 0rpx;
right: 0rpx; right: 32rpx;
image { image {
width: 184rpx; width: 184rpx;
height: 220rpx;
} }
} }
.item-desc { .item-desc {
bottom: calc(100% - 260rpx); padding-left: 40rpx;
left: 40rpx; font-size: 24rpx;
position: absolute;
&.grey { &.grey {
color: #a2a2a8; color: #a2a2a8;
} }
} }
.item-detail { .item-footer {
position: absolute; position: absolute;
left: 0; left: 0;
bottom: 26rpx; bottom: 26rpx;
width: 100%;
}
.item-detail {
width: calc(100% - 48rpx); width: calc(100% - 48rpx);
box-sizing: border-box; box-sizing: border-box;
border-radius: 16rpx; border-radius: 16rpx;
...@@ -373,7 +376,6 @@ export default { ...@@ -373,7 +376,6 @@ export default {
overflow-y: auto; overflow-y: auto;
margin: 16rpx 24rpx; margin: 16rpx 24rpx;
padding: 12rpx 0rpx; padding: 12rpx 0rpx;
background: #efeff1;
color: #a2a2a8; color: #a2a2a8;
.item-coupon { .item-coupon {
position: relative; position: relative;
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @Author: huyue * @Author: huyue
* @Date: 2024-04-08 11:30:30 * @Date: 2024-04-08 11:30:30
* @LastEditors: 前端 qianduan01@didihu.com.cn * @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-12-20 16:16:33 * @LastEditTime: 2024-12-25 10:34:42
--> -->
<template> <template>
<view class="point-box"> <view class="point-box">
...@@ -15,13 +15,13 @@ ...@@ -15,13 +15,13 @@
<view class="month-tabs"> <view class="month-tabs">
<view class="tab-prev" v-if="month <= currentMonth && month > 1" @click="prevTab"> <view class="tab-prev" v-if="month <= currentMonth && month > 1" @click="prevTab">
<view class="tab-icon"> <view class="tab-icon">
<uni-icons type="left" size="20"></uni-icons> <uni-icons type="left" size="16"></uni-icons>
</view> </view>
</view> </view>
<view class="tab-mid">{{ month == currentMonth ? '本' : (month + '').padStart(2, '0') }}月</view> <view class="tab-mid">{{ month == currentMonth ? '本' : (month + '').padStart(2, '0') }}月</view>
<view class="tab-next" v-if="month != currentMonth" @click="nextTab"> <view class="tab-next" v-if="month != currentMonth" @click="nextTab">
<view class="tab-icon"> <view class="tab-icon">
<uni-icons type="right" size="20"></uni-icons> <uni-icons type="right" size="16"></uni-icons>
</view> </view>
</view> </view>
</view> </view>
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
<view class="item-logo" v-if="l.ranking > 3">{{ item.ranking }}</view> <view class="item-logo" v-if="l.ranking > 3">{{ item.ranking }}</view>
<view class="item-image" v-else><image :src="require(`@/assets/images/point/${index == 0 ? 'crown_' : 'prize_'}${l.ranking || 0}.png`)" /></view> <view class="item-image" v-else><image :src="require(`@/assets/images/point/${index == 0 ? 'crown_' : 'prize_'}${l.ranking || 0}.png`)" /></view>
<view class="item-name">{{ l.staffName }}</view> <view class="item-name">{{ l.staffName }}</view>
<view v-if="l.badgeList && l.badgeList.length" :class="{ 'item-prize': index == 0, 'item-medal': index != 0 }"><image :src="index == 0 ? pointImg[item.badgeList[0].growthType - 1] : starImg[index - 1]" /></view> <view v-if="l.badgeList && l.badgeList.length" :class="{ 'item-prize': index == 0, 'item-medal': index != 0 }"><image :src="index == 0 ? pointImg[l.badgeList[0].growthType - 1] : starImg[index - 1]" /></view>
<view class="item-num">{{ l.pointValue }}</view> <view class="item-num">{{ l.pointValue }}</view>
</view> </view>
</view> </view>
...@@ -151,6 +151,15 @@ export default { ...@@ -151,6 +151,15 @@ export default {
border-radius: 50%; border-radius: 50%;
height: 48rpx; height: 48rpx;
background: #ffffff; background: #ffffff;
.tab-icon {
margin-left: -4rpx;
margin-top: 4rpx;
}
}
.tab-next {
.tab-icon {
margin-left: 2rpx;
}
} }
} }
} }
...@@ -218,7 +227,7 @@ export default { ...@@ -218,7 +227,7 @@ export default {
border-radius: 50%; border-radius: 50%;
background: #ffffff; background: #ffffff;
border: 2rpx solid #ffffff; border: 2rpx solid #ffffff;
line-height: 72rpx; line-height: 76rpx;
font-size: 34rpx; font-size: 34rpx;
color: #a0a1ad; color: #a0a1ad;
text-align: center; text-align: center;
......
...@@ -10,14 +10,16 @@ ...@@ -10,14 +10,16 @@
<view class="table-box"> <view class="table-box">
<table class="score-table"> <table class="score-table">
<tr class="th"> <tr class="th">
<th v-for="(item, index) in tabelTh" :key="index" :style="{ width: item.width + 'vw' }">{{ item.title }} <th v-for="(item, index) in tabelTh" :key="index" :style="{ width: item.width + 'vw' }">{{ item.title }}</th>
</th>
</tr> </tr>
<tr v-for="(item, index) in tabelTr" :key="index" :class="{ line: item.row1Span }"> <tr v-for="(item, index) in tabelTr" :key="index" :class="{ line: item.row1Span }">
<td :rowspan="item.row1Span" v-if="item.showRow1">{{ item.categoryName }}</td> <td class="row_1" :rowspan="item.row1Span" v-if="item.showRow1">{{ item.categoryName }}</td>
<td :rowspan="item.row2Span"" v-if="item.showRow2">{{ item.typeName }}</td> <td :rowspan="item.row2Span" v-if="item.showRow2">{{ item.typeName }}</td>
<td>{{ item.description }}</td> <td>{{ item.description }}</td>
<td>{{ item.pointValue }}</td> <td>
<template v-if="item.pointValue">{{ item.pointValue }}</template>
<text v-else>自动</text>
</td>
<td>{{ item.detail }}</td> <td>{{ item.detail }}</td>
</tr> </tr>
</table> </table>
...@@ -37,7 +39,7 @@ export default { ...@@ -37,7 +39,7 @@ export default {
{ title: '积分类型', width: 8 }, { title: '积分类型', width: 8 },
{ title: '积分描述', width: 14 }, { title: '积分描述', width: 14 },
{ title: '积分值', width: 6 }, { title: '积分值', width: 6 },
{ title: '说明', width: 50 }, { title: '说明', width: 50 }
], ],
tabelTr: [], tabelTr: [],
processedData: [], processedData: [],
...@@ -48,34 +50,25 @@ export default { ...@@ -48,34 +50,25 @@ export default {
methods: { methods: {
getDetail() { getDetail() {
uni.$api.pointApi.pointRuleDetail().then(res => { uni.$api.pointApi.pointRuleDetail().then(res => {
let result = []; let result = []
let row1Span = 0; let row1Span = 0
let row2Span = 0; let row2Span = 0
const obj = res || [] const obj = res || []
obj.forEach((item, index) => { obj.forEach((item, index) => {
if (index === 0 || obj[index - 1].categoryName !== item.categoryName) { if (index === 0 || obj[index - 1].categoryName !== item.categoryName) {
row1Span = obj.filter( row1Span = obj.filter((el, idx) => idx >= index && el.categoryName === item.categoryName).length
(el, idx) => idx >= index && el.categoryName === item.categoryName result.push({ ...item, row1Span, showRow1: true })
).length;
result.push({ ...item, row1Span, showRow1: true });
} else { } else {
result.push({ ...item, showRow1: false }); result.push({ ...item, showRow1: false })
} }
if ( if (index === 0 || obj[index - 1].typeName !== item.typeName || obj[index - 1].categoryName !== item.categoryName) {
index === 0 || row2Span = obj.filter((el, idx) => idx >= index && el.categoryName === item.categoryName && el.typeName === item.typeName).length
obj[index - 1].typeName !== item.typeName || result[index].row2Span = row2Span
obj[index - 1].categoryName !== item.categoryName result[index].showRow2 = true
) {
row2Span = obj.filter(
(el, idx) =>
idx >= index && el.categoryName === item.categoryName && el.typeName === item.typeName
).length;
result[index].row2Span = row2Span;
result[index].showRow2 = true;
} else { } else {
result[index].showRow2 = false; result[index].showRow2 = false
} }
}); })
this.tabelTr = result this.tabelTr = result
}) })
}, },
...@@ -136,7 +129,11 @@ export default { ...@@ -136,7 +129,11 @@ export default {
border-collapse: separate; border-collapse: separate;
/* 防止边框合并 */ /* 防止边框合并 */
border-spacing: 0; border-spacing: 0;
border: none;
.th {
position: sticky;
top: 0;
}
/* 单元格之间没有间距 */ /* 单元格之间没有间距 */
tr { tr {
border: none; border: none;
...@@ -144,7 +141,7 @@ export default { ...@@ -144,7 +141,7 @@ export default {
&.line { &.line {
td { td {
border-top: 16rpx solid #fff; border-top: 16rpx solid rgba($color: #fff, $alpha: 0.9);
} }
} }
...@@ -161,10 +158,11 @@ export default { ...@@ -161,10 +158,11 @@ export default {
&:first-child { &:first-child {
border-left: none; border-left: none;
border-radius: 16rpx 0 0 16rpx;
} }
&:last-child { &:last-child {
border-right: none; border-radius: 0 16rpx 16rpx 0;
} }
} }
...@@ -178,6 +176,9 @@ export default { ...@@ -178,6 +176,9 @@ export default {
height: 88rpx; height: 88rpx;
font-size: 26rpx; font-size: 26rpx;
color: #333333; color: #333333;
text {
color: #c8c8cc;
}
&.line { &.line {
border-bottom: 16rpx solid #fff; border-bottom: 16rpx solid #fff;
......
<template> <template>
<view class="tool-box" :style="toolStyle"> <view class="tool-box" :style="toolStyle">
<view <view :class="['btn', { hideIcon: !show }]" @click="show = false">
:class="['btn', {hideIcon:!show}]" <view class="icon sprite-icon icon-tool-file"></view>
@click="show = false"
>
<view class="icon sprite-icon icon-tool-file">
</view>
文件夹 文件夹
</view> </view>
<view :class="['list',{showList:!show}]"> <view :class="['list', { showList: !show }]">
<view <view class="title" @click="show = true">文件夹</view>
class="title" <view class="list-body">
@click="show = true" <template v-for="(i, index) in data">
>文件夹</view> <view :class="['item', { active: i[idKey] == id }]" :key="index" @click="jump(i)">
<template v-for="(i,index) in data"> <image class="icon" :src="i.shortTitleUrl" mode="scaleToFill" />
<view {{ i.shortTitle }}
:class="['item', {active: i[idKey] == id} ]" </view>
:key="index" </template>
@click="jump(i)" </view>
>
<image
class="icon"
:src="i.shortTitleUrl"
mode="scaleToFill"
/>
{{i.shortTitle}}
</view>
</template>
<template v-if="showPayBtn"> <template v-if="showPayBtn">
<view <view class="item" @click="toPay">
class="item"
@click="toPay"
>
<view class="icon"> <view class="icon">
<view class="sprite-icon icon-tool-pay"></view> <view class="sprite-icon icon-tool-pay"></view>
</view> </view>
...@@ -39,10 +23,7 @@ ...@@ -39,10 +23,7 @@
</view> </view>
</template> </template>
<template v-if="type != 'preview'"> <template v-if="type != 'preview'">
<view <view class="item" @click="finish">
class="item"
@click="finish"
>
<view class="icon"> <view class="icon">
<view class="sprite-icon icon-tool-finish"></view> <view class="sprite-icon icon-tool-finish"></view>
</view> </view>
...@@ -53,7 +34,7 @@ ...@@ -53,7 +34,7 @@
</view> </view>
</template> </template>
<script type='text/ecmascript-6'> <script type="text/ecmascript-6">
export default { export default {
name: 'ToolBox', name: 'ToolBox',
props: { props: {
...@@ -105,7 +86,7 @@ export default { ...@@ -105,7 +86,7 @@ export default {
} }
</script> </script>
<style scoped lang='scss'> <style scoped lang="scss">
.tool-box { .tool-box {
position: fixed; position: fixed;
right: toRpx(40); right: toRpx(40);
...@@ -157,7 +138,7 @@ export default { ...@@ -157,7 +138,7 @@ export default {
height: 0; height: 0;
&::after { &::after {
position: absolute; position: absolute;
content: ""; content: '';
background: inherit; background: inherit;
top: 0; top: 0;
left: 0; left: 0;
...@@ -176,6 +157,10 @@ export default { ...@@ -176,6 +157,10 @@ export default {
align-items: center; align-items: center;
justify-content: center; justify-content: center;
} }
.list-body {
max-height: 60vh;
overflow-y: auto;
}
.item { .item {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
...@@ -215,4 +200,4 @@ export default { ...@@ -215,4 +200,4 @@ export default {
} }
} }
} }
</style>
\ No newline at end of file \ No newline at end of file
</style>
const target = ['ip', 'dev', 'uat', 'prod', 'beta'] const target = ['ip', 'dev', 'uat', 'prod', 'beta']
const index = 2 const index = 4
/** /**
* *
0本地 0本地
......
<template> <template>
<view :class="['layout',{ 'byd-layout':isByd } ]"> <view :class="['layout', { 'byd-layout': isByd }]">
<view class="layout-content"> <view class="layout-content">
<view class="title">{{ title }}</view> <view class="title">{{ title }}</view>
<template v-if="views&&views.length > 1"> <template v-if="views && views.length > 1">
<view class="tabs-box"> <view class="tabs-box">
<tabs <tabs :list="views" @tabclick="changeTab"></tabs>
:list="views"
@tabclick="changeTab"
></tabs>
</view> </view>
</template> </template>
<template v-if="list.length > 0"> <template v-if="list.length > 0">
<scroll-view <scroll-view :class="['record-box', { 'has-tabs': views && views.length > 1 }]" scroll-y :scroll-top="scrollTop" @scrolltolower="pageonReachBottom">
:class="['record-box',{'has-tabs':views && views.length > 1} ]"
scroll-y
:scroll-top="scrollTop"
@scrolltolower="pageonReachBottom"
>
<view class="card-list"> <view class="card-list">
<view <view class="card-item" v-for="item in list" :key="item.id">
class="card-item" <template v-if="!views || views.length <= 1">
v-for="item in list" <image v-if="item.vdQuotationPaymentDoc && item.vdQuotationPaymentDoc.paymentDocUrl" class="image-box" :src="item.vdQuotationPaymentDoc.paymentDocUrl" />
:key="item.id" <image v-else class="image-box photo" src="https://img02.glsx.com.cn/weapp/resource/app-tape/media/common/pay.webp" />
>
<template>
<image
v-if="item.vdQuotationPaymentDoc && item.vdQuotationPaymentDoc.paymentDocUrl"
class="image-box"
:src="item.vdQuotationPaymentDoc.paymentDocUrl"
/>
<image
v-else
class="image-box"
src="https://img02.glsx.com.cn/weapp/resource/app-tape/media/common/pay.webp"
/>
<view class="gradient-overlay"></view> <view class="gradient-overlay"></view>
</template> </template>
<view> <view>
...@@ -42,7 +22,7 @@ ...@@ -42,7 +22,7 @@
<view class="goods-name">{{ item.goodsName }}</view> <view class="goods-name">{{ item.goodsName }}</view>
<view class="card-info"> <view class="card-info">
<view class="label">车架号</view> <view class="label">车架号</view>
<view class="value">{{ item.carVin || "-" }}</view> <view class="value">{{ item.carVin || '-' }}</view>
</view> </view>
<view class="card-info"> <view class="card-info">
<view class="label">工单号</view> <view class="label">工单号</view>
...@@ -55,25 +35,19 @@ ...@@ -55,25 +35,19 @@
<view class="card-info"> <view class="card-info">
<view class="label">实收金额</view> <view class="label">实收金额</view>
<view class="price"> <view class="price">
<view class="flag">¥</view>{{ accDiv(item.equityPrice) }} <view class="flag">¥</view>
{{ accDiv(item.equityPrice) }}
</view> </view>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view <view class="end-text" v-if="list.length > 0 && isEnd">我是一个有底线的人</view>
class="end-text"
v-if="list.length > 0 && isEnd"
>我是一个有底线的人</view>
</scroll-view> </scroll-view>
</template> </template>
<template v-else> <template v-else>
<view class="no-data"> <view class="no-data">
<glsx-image <glsx-image class="no-data-img" src="media/no-data.png" mode="scaleToFill" />
class="no-data-img"
src="media/no-data.png"
mode="scaleToFill"
/>
<view class="no-data-text">暂无数据</view> <view class="no-data-text">暂无数据</view>
</view> </view>
</template> </template>
...@@ -82,8 +56,8 @@ ...@@ -82,8 +56,8 @@
</template> </template>
<script> <script>
import utils from '@/utils/utils'; import utils from '@/utils/utils'
import Record from "@/mixin/record"; import Record from '@/mixin/record'
import Tabs from './Tabs.vue' import Tabs from './Tabs.vue'
export default { export default {
components: { components: {
...@@ -96,9 +70,9 @@ export default { ...@@ -96,9 +70,9 @@ export default {
madiaId: Number, madiaId: Number,
show: Boolean, show: Boolean,
isByd: Boolean, isByd: Boolean,
views: Array, views: Array
}, },
data () { data() {
return { return {
shopMerchantId: '', shopMerchantId: '',
goodsName: null, goodsName: null,
...@@ -106,41 +80,41 @@ export default { ...@@ -106,41 +80,41 @@ export default {
} }
}, },
watch: { watch: {
show (n) { show(n) {
if (n) this.init() if (n) this.init()
else this.scrollTop = 0 else this.scrollTop = 0
}, },
watchStatus: { watchStatus: {
immediate: true, immediate: true,
handler (newval) { handler(newval) {
this.pageNum = 1 this.pageNum = 1
this.scrollTop = 1000 this.scrollTop = 1000
this.list = [] this.list = []
setTimeout(() => { setTimeout(() => {
this.scrollTop = 0 this.scrollTop = 0
}, 100); }, 100)
} }
}, }
}, },
computed: { computed: {
watchStatus () { watchStatus() {
return this.$store.state.user.historyStatus return this.$store.state.user.historyStatus
}, }
}, },
mounted () { mounted() {
if (this.show) this.init() if (this.show) this.init()
}, },
methods: { methods: {
init () { init() {
const { shopMerchantId } = uni.$storage.get("userInfo"); const { shopMerchantId } = uni.$storage.get('userInfo')
this.shopMerchantId = shopMerchantId this.shopMerchantId = shopMerchantId
if (this.list.length == 0) { if (this.list.length == 0) {
this.list = uni.getStorageSync(`${this.shopMerchantId}-historyList`) this.list = uni.getStorageSync(`${this.shopMerchantId}-historyList`)
this.isEnd = true this.isEnd = true
} }
if (this.pageNum == 1) this.getQuotationList(); if (this.pageNum == 1) this.getQuotationList()
}, },
async getQuotationList () { async getQuotationList() {
const { goodsName, shopMerchantId, pageNum, pageSize } = this const { goodsName, shopMerchantId, pageNum, pageSize } = this
try { try {
await this.getList('getQuotationList', { await this.getList('getQuotationList', {
...@@ -148,14 +122,14 @@ export default { ...@@ -148,14 +122,14 @@ export default {
pageNum, pageNum,
pageSize, pageSize,
goodsName, goodsName,
orderStatus: 3, orderStatus: 3
}) })
if (!goodsName && this.pageNum == 1 && this.list.length) uni.setStorageSync(`${shopMerchantId}-historyList`, this.list) if (!goodsName && this.pageNum == 1 && this.list.length) uni.setStorageSync(`${shopMerchantId}-historyList`, this.list)
} catch (error) { } catch (error) {
if (!goodsName && this.pageNum == 1) this.list = uni.getStorageSync(`${this.shopMerchantId}-historyList`) if (!goodsName && this.pageNum == 1) this.list = uni.getStorageSync(`${this.shopMerchantId}-historyList`)
} }
}, },
pageonReachBottom () { pageonReachBottom() {
this.isEnd = false this.isEnd = false
let { pageNum, total, isEnd, pageSize } = this let { pageNum, total, isEnd, pageSize } = this
if (!isEnd) isEnd = false if (!isEnd) isEnd = false
...@@ -165,13 +139,13 @@ export default { ...@@ -165,13 +139,13 @@ export default {
} else this.isEnd = true } else this.isEnd = true
}, },
// 脱敏 // 脱敏
nameHide (name) { nameHide(name) {
return name.substring(0, 1) + '*'; return name.substring(0, 1) + '*'
}, },
accDiv (val) { accDiv(val) {
return utils.accDiv(val || 0, 100) return utils.accDiv(val || 0, 100)
}, },
changeTab (index) { changeTab(index) {
let { views } = this, let { views } = this,
goodsName = index == 0 ? null : views[index].tabName goodsName = index == 0 ? null : views[index].tabName
if (this.goodsName == goodsName) return if (this.goodsName == goodsName) return
...@@ -291,7 +265,17 @@ export default { ...@@ -291,7 +265,17 @@ export default {
} }
} }
.image-box { .image-box {
display: none; height: 100%;
position: absolute;
top: 0rpx;
// opacity: 0.5;
right: 0rpx;
background-size: 100% 100%;
// border-radius: 32rpx;
z-index: -1;
&.photo {
width: toRpx(250);
}
} }
.gradient-overlay { .gradient-overlay {
z-index: -1; z-index: -1;
...@@ -351,4 +335,4 @@ export default { ...@@ -351,4 +335,4 @@ export default {
} }
} }
} }
</style>
\ No newline at end of file \ No newline at end of file
</style>
...@@ -2,93 +2,45 @@ ...@@ -2,93 +2,45 @@
* @Description: * @Description:
* @Author: huyue * @Author: huyue
* @Date: 2024-04-08 11:30:30 * @Date: 2024-04-08 11:30:30
* @LastEditors: huyue * @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-07-01 16:38:24 * @LastEditTime: 2024-12-25 18:52:46
--> -->
<template> <template>
<view <view class="detail-box" @dblclick="dbClick">
class="detail-box" <view class="nav-bar" :style="{ 'z-index': backZindex }">
@dblclick="dbClick" <view class="back" @click="back">
> <uni-icons type="left" :size="20" color="#000"></uni-icons>
<view class="nav-bar">
<view
class="back"
@click="back"
>
<uni-icons
type="left"
:size="20"
color="#000"
></uni-icons>
</view> </view>
</view> </view>
<template v-for="(item, index) in media"> <template v-for="(item, index) in media">
<view <view :class="['view', { showView: id == item.id }, modeName]" :key="index" @touchstart.stop="touchStart" @touchend.stop="touchEnd">
:class="['view', { showView: id == item.id }, modeName]" <component @full="handleFull" :detail="item" :is="item.componentName" :views="item.receptionSourceDetailList || []" :penSwitch="penSwitch" :show="id == item.id" :ref="'media' + item.id" :title="item.detailTitle || ''" :madiaId="item.id" @scale="scale" :ulList="item.ulList" :screenList="item.screenList" @onProductModel="productModelStatus = $event" :isPreview="isPreview" :isByd="isByd" />
:key="index"
@touchstart.stop="touchStart"
@touchend.stop="touchEnd"
>
<component
:is="item.componentName"
:views="item.receptionSourceDetailList || []"
:penSwitch="penSwitch"
:show="id == item.id"
:ref="'media' + item.id"
:title="item.detailTitle || ''"
:madiaId="item.id"
@scale="scale"
:ulList="item.ulList"
:screenList="item.screenList"
@onProductModel="productModelStatus = $event"
:isPreview="isPreview"
:isByd="isByd"
/>
</view> </view>
</template> </template>
<template v-if="type != 'preview'"> <template v-if="type != 'preview'">
<tool-box <template v-if="backZindex">
ref="toolRef" <tool-box ref="toolRef" :data="toolList" :type="type" @choose="choose" @finish="open" :id="id" @toPay="toPay" :showPayBtn="watchPayInfo" />
:data="toolList" <view class="pen-box" @click="drawStatus = !drawStatus">
:type="type" <view :class="['sprite-icon', `${!drawStatus ? 'icon-pen' : 'icon-pen-active'}`]"></view>
@choose="choose" </view>
@finish="open" </template>
:id="id"
@toPay="toPay"
:showPayBtn="watchPayInfo"
/>
<view
class="pen-box"
@click="drawStatus = !drawStatus"
>
<view :class="['sprite-icon', `${!drawStatus ? 'icon-pen' : 'icon-pen-active'}`]"> </view>
</view>
</template> </template>
<pay-pop <pay-pop ref="pay" @jumpPay="showPayPage = true"></pay-pop>
ref="pay" <finish-step ref="stepRef" @submit="done" :titleTips="finishTips" />
@jumpPay="showPayPage = true" <informationEntry :showPayPage.sync="showPayPage" @finish="open" />
></pay-pop>
<finish-step
ref="stepRef"
@submit="done"
:titleTips="finishTips"
/>
<informationEntry
:showPayPage.sync="showPayPage"
@finish="open"
/>
</view> </view>
</template> </template>
<script> <script>
import ToolBox from "@/components/ToolBox.vue"; import ToolBox from '@/components/ToolBox.vue'
import Reception from "./components/Reception.vue"; import Reception from './components/Reception.vue'
import MediaComponent from "./components/MediaComponent.vue"; import CaseCenter from './components/CaseCenter.vue'
import History from "./components/History.vue"; import MediaComponent from './components/MediaComponent.vue'
import ThreeGuarantees from "./components/ThreeGuarantees.vue"; import History from './components/History.vue'
import Guarantee from './components/Guarantee.vue'; import ThreeGuarantees from './components/ThreeGuarantees.vue'
import payPop from "./components/payPop.vue"; import Guarantee from './components/Guarantee.vue'
import FinishStep from '@/components/FinishStep.vue'; import payPop from './components/payPop.vue'
import { mapMutations } from "vuex"; import FinishStep from '@/components/FinishStep.vue'
import { mapMutations } from 'vuex'
import informationEntry from './components/informationEntry.vue' import informationEntry from './components/informationEntry.vue'
import insurance from '@/components/Insurance/Insurance.vue' import insurance from '@/components/Insurance/Insurance.vue'
import { receptionTrackMixin } from '@/mixin/index.js' import { receptionTrackMixin } from '@/mixin/index.js'
...@@ -98,6 +50,7 @@ export default { ...@@ -98,6 +50,7 @@ export default {
Reception, Reception,
MediaComponent, MediaComponent,
payPop, payPop,
CaseCenter,
FinishStep, FinishStep,
Guarantee, Guarantee,
History, History,
...@@ -115,8 +68,9 @@ export default { ...@@ -115,8 +68,9 @@ export default {
toolList: Array toolList: Array
}, },
mixins: [receptionTrackMixin], mixins: [receptionTrackMixin],
data () { data() {
return { return {
backZindex: 9,
drawStatus: false, drawStatus: false,
startX: null, startX: null,
startY: null, startY: null,
...@@ -125,92 +79,94 @@ export default { ...@@ -125,92 +79,94 @@ export default {
showPayPage: false, showPayPage: false,
productModelStatus: false, productModelStatus: false,
modeName: '' modeName: ''
}; }
}, },
computed: { computed: {
watchStatus () { watchStatus() {
return this.$store.state.user.historyStatus return this.$store.state.user.historyStatus
}, },
penSwitch () { penSwitch() {
return !this.isPreview && this.drawStatus return !this.isPreview && this.drawStatus
}, },
watchPayInfo () { watchPayInfo() {
return this.$store.state.user.paymentType.length ? true : false return this.$store.state.user.paymentType.length ? true : false
}, },
title () { title() {
let { id } = this, let { id } = this,
name = this.media.find((e) => e.id == id)?.detailTitle || "" name = this.media.find(e => e.id == id)?.detailTitle || ''
return name; return name
}, },
finishTips () { finishTips() {
const { channelType } = uni.$storage.get("userInfo") const { channelType } = uni.$storage.get('userInfo')
let text = '' let text = ''
if (channelType == 3) text = '检测到“汽车保险告知书”中未填写客户档案,请填写后再完成接待。' if (channelType == 3) text = '检测到“汽车保险告知书”中未填写客户档案,请填写后再完成接待。'
return text return text
}, },
isByd () { isByd() {
const { channelType } = uni.$storage.get("userInfo") const { channelType } = uni.$storage.get('userInfo')
return channelType == 2 return channelType == 2
}, },
isPreview () { isPreview() {
return this.type == 'preview' return this.type == 'preview'
} }
}, },
watch: { watch: {
watchStatus: { watchStatus: {
immediate: true, immediate: true,
handler (newval) { handler(newval) {
if (newval) this.drawStatus = false if (newval) this.drawStatus = false
} }
}, }
}, },
mounted () { mounted() {
const systemInfo = uni.getSystemInfoSync() const systemInfo = uni.getSystemInfoSync()
this.screenWidth = systemInfo.screenWidth this.screenWidth = systemInfo.screenWidth
}, },
methods: { methods: {
...mapMutations("audio", ["setReceptionStatus"]), ...mapMutations('audio', ['setReceptionStatus']),
open () { open() {
this.$refs.stepRef.open() this.$refs.stepRef.open()
}, },
handleFull(val) {
this.backZindex = val ? 0 : 9
},
/**切换素材 */ /**切换素材 */
choose (e) { choose(e) {
Object.keys(this.$refs).map(refKey => { Object.keys(this.$refs).map(refKey => {
let ref = this.$refs[refKey]; let ref = this.$refs[refKey]
if (ref) { if (ref) {
if (Array.isArray(ref)) ref = ref[0] if (Array.isArray(ref)) ref = ref[0]
ref.closeAllPopup && ref.closeAllPopup() ref && ref.closeAllPopup && ref.closeAllPopup()
} }
}) })
this.receptionTrackLeave() this.receptionTrackLeave()
this.$emit('update:id', e.id) this.$emit('update:id', e.id)
uni.$logger.local.info(`预览${e.title}`) uni.$logger.local.info(`预览${e.title}`)
}, },
back () { back() {
this.$refs?.toolRef?.hide() this.$refs?.toolRef?.hide()
this.$emit('back') this.$emit('back')
}, },
done (e) { done(e) {
this.showPayPage = false this.showPayPage = false
this.$refs.toolRef.hide() this.$refs.toolRef.hide()
this.$refs.stepRef.close() this.$refs.stepRef.close()
this.receptionTrackLeave() this.receptionTrackLeave()
this.$emit('done', e) this.$emit('done', e)
}, },
toPay () { toPay() {
this.$refs.pay.show() this.$refs.pay.show()
}, },
dbClick () { dbClick() {
if (!this.isPreview) this.drawStatus = !this.drawStatus if (!this.isPreview) this.drawStatus = !this.drawStatus
}, },
touchStart (e) { touchStart(e) {
if (!this.drawStatus && e.changedTouches?.length) { if (!this.drawStatus && e.changedTouches?.length) {
this.startX = e.changedTouches[0].pageX this.startX = e.changedTouches[0].pageX
this.startY = e.changedTouches[0].pageY this.startY = e.changedTouches[0].pageY
} }
}, },
touchEnd (e) { touchEnd(e) {
if (this.modeName) return if (this.modeName) return
try { try {
let { toolList, drawStatus, startX, screenWidth, id, scaleValueObject, productModelStatus } = this let { toolList, drawStatus, startX, screenWidth, id, scaleValueObject, productModelStatus } = this
...@@ -235,14 +191,14 @@ export default { ...@@ -235,14 +191,14 @@ export default {
console.log(error) console.log(error)
} }
}, },
getNextId (index, toolList, startX, halfScreenWidth) { getNextId(index, toolList, startX, halfScreenWidth) {
let nextItem = {}, let nextItem = {},
modeName = '' modeName = ''
if (startX > halfScreenWidth) { if (startX > halfScreenWidth) {
nextItem = index === toolList.length - 1 ? toolList[0] : toolList[index + 1]; nextItem = index === toolList.length - 1 ? toolList[0] : toolList[index + 1]
modeName = 'to-right' modeName = 'to-right'
} else { } else {
nextItem = index === 0 ? toolList[toolList.length - 1] : toolList[index - 1]; nextItem = index === 0 ? toolList[toolList.length - 1] : toolList[index - 1]
modeName = 'to-left' modeName = 'to-left'
} }
return { return {
...@@ -251,14 +207,12 @@ export default { ...@@ -251,14 +207,12 @@ export default {
title: nextItem.title title: nextItem.title
} }
}, },
scale (e) { scale(e) {
let { id } = this let { id } = this
this.scaleValueObject[id] = e this.scaleValueObject[id] = e
}, }
}
}, }
};
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
.detail-box { .detail-box {
...@@ -299,7 +253,7 @@ export default { ...@@ -299,7 +253,7 @@ export default {
} }
.view { .view {
position: absolute; //验证 position: absolute; //验证
width: 100%; width: 100%;
height: 100%; height: 100%;
z-index: -1; z-index: -1;
top: 0; top: 0;
......
...@@ -127,10 +127,38 @@ export default { ...@@ -127,10 +127,38 @@ export default {
}) })
}, },
// 查询素材 // 查询素材
// 查询素材
async getSoure() { async getSoure() {
/**比亚迪 */ /**比亚迪 */
if (this.channelType == 2) { if (this.channelType == 2) {
let { moduleList, toolList } = await uni.$api.systemApi.getBydMockData(true) let { moduleList, toolList } = await uni.$api.systemApi.getBydMockData(true)
let configList
try {
configList = await uni.$api.systemApi.findReceptionpriproConfigList({})
uni.$storage.set('findReceptionpriproConfigList', configList)
} catch (error) {
configList = uni.$storage.get('findReceptionpriproConfigList')
}
const toolOtherList = configList.map(i => {
return {
id: 10 + i.id,
shortTitle: i.productName,
shortTitleUrl: i.procuctLog
}
})
toolList = toolList.concat(toolOtherList)
const moduleOtherList = configList.map(i => {
return {
id: 10 + i.id,
title: i.productName,
shortTitleUrl: i.procuctLog,
productPoster: i.productPoster,
showAlt: false,
componentName: 'CaseCenter',
receptionpriproCusCaseList: i.receptionpriproCusCaseList
}
})
moduleList = moduleList.concat(moduleOtherList)
moduleList = await Promise.all( moduleList = await Promise.all(
moduleList.map(async e => ({ moduleList.map(async e => ({
...e, ...e,
...@@ -151,6 +179,33 @@ export default { ...@@ -151,6 +179,33 @@ export default {
} else { } else {
let { moduleList, toolList, default_moduleList, default_toolList, boutiqueDefaultCarBrandId } = await uni.$api.systemApi.getMockData(true) let { moduleList, toolList, default_moduleList, default_toolList, boutiqueDefaultCarBrandId } = await uni.$api.systemApi.getMockData(true)
if (this.channelType == 3) { if (this.channelType == 3) {
let configList
try {
configList = await uni.$api.systemApi.findReceptionpriproConfigList({})
uni.$storage.set('findReceptionpriproConfigList', configList)
} catch (error) {
configList = uni.$storage.get('findReceptionpriproConfigList')
}
const toolOtherList = configList.map(i => {
return {
id: 10 + i.id,
shortTitle: i.productName,
shortTitleUrl: i.procuctLog
}
})
default_toolList = default_toolList.concat(toolOtherList)
const moduleOtherList = configList.map(i => {
return {
id: 10 + i.id,
title: i.productName,
shortTitleUrl: i.procuctLog,
productPoster: i.productPoster,
showAlt: false,
componentName: 'CaseCenter',
receptionpriproCusCaseList: i.receptionpriproCusCaseList
}
})
default_moduleList = default_moduleList.concat(moduleOtherList)
/**其他品牌 */ /**其他品牌 */
default_toolList = await uni.$api.systemApi.imgToBase64(default_toolList, 'shortTitleUrl') default_toolList = await uni.$api.systemApi.imgToBase64(default_toolList, 'shortTitleUrl')
uni.$api.systemApi.updateMockData( uni.$api.systemApi.updateMockData(
...@@ -180,6 +235,7 @@ export default { ...@@ -180,6 +235,7 @@ export default {
['moduleList', 'toolList'] ['moduleList', 'toolList']
) )
this.$store.state.user.boutiqueDefaultCarBrandId = boutiqueDefaultCarBrandId this.$store.state.user.boutiqueDefaultCarBrandId = boutiqueDefaultCarBrandId
console.log(moduleList, toolList, 999)
this.setViewInfo(moduleList, toolList) this.setViewInfo(moduleList, toolList)
} }
} }
...@@ -193,17 +249,17 @@ export default { ...@@ -193,17 +249,17 @@ export default {
uni.showLoading({ uni.showLoading({
mask: true mask: true
}) })
const result = await this.$permision.requestAndroidPermission('android.permission.RECORD_AUDIO') // const result = await this.$permision.requestAndroidPermission('android.permission.RECORD_AUDIO')
if (result !== 1) { // if (result !== 1) {
uni.showToast({ // uni.showToast({
title: '为了记录语音通话,请打开录音权限', // title: '为了记录语音通话,请打开录音权限',
icon: 'none' // icon: 'none'
}) // })
return // return
} // }
this.getSoure() this.getSoure()
this.clearHistory() this.clearHistory()
this.$refs.home.startAudio() // this.$refs.home.startAudio()
this.id = this.moduleList[0].id this.id = this.moduleList[0].id
this.type = 'edit' this.type = 'edit'
this.recording = true this.recording = true
......
/*
* @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2024-04-16 09:55:40
* @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-12-24 15:53:41
* @FilePath: \gl-tape\utils\cache\constantData.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
// export const IMG_URL = 'https://img02.glsx.com.cn/weapp/resource/miniprogram/store-assistant/' // export const IMG_URL = 'https://img02.glsx.com.cn/weapp/resource/miniprogram/store-assistant/'
// import util from '~/utils/util' // import util from '~/utils/util'
...@@ -25,5 +33,6 @@ export const STORAGE_OBJECTKEY = { ...@@ -25,5 +33,6 @@ export const STORAGE_OBJECTKEY = {
historyList: 'historyList', historyList: 'historyList',
storageVersion: 'storageVersion', storageVersion: 'storageVersion',
byd_mock_data: 'byd_mock_data', byd_mock_data: 'byd_mock_data',
boutique_mock_data: 'boutique_mock_data' boutique_mock_data: 'boutique_mock_data',
findReceptionpriproConfigList: 'findReceptionpriproConfigList'
} }
...@@ -2,32 +2,33 @@ ...@@ -2,32 +2,33 @@
* @Author: 前端 qianduan01@didihu.com.cn * @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2024-11-01 15:06:40 * @Date: 2024-11-01 15:06:40
* @LastEditors: 前端 qianduan01@didihu.com.cn * @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-12-19 16:43:04 * @LastEditTime: 2024-12-25 18:20:52
* @FilePath: \gl-tape\utils\logger\LogCat.js * @FilePath: \gl-tape\utils\logger\LogCat.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/ */
import { getTime } from './util' import { getTime } from './util'
class LogCat { class LogCat {
main = plus.android.runtimeMainActivity() // main = plus.android.runtimeMainActivity()
File = plus.android.importClass('java.io.File') // File = plus.android.importClass('java.io.File')
Environment = plus.android.importClass('android.os.Environment') // Environment = plus.android.importClass('android.os.Environment')
BufferedWriter = plus.android.importClass('java.io.BufferedWriter') // BufferedWriter = plus.android.importClass('java.io.BufferedWriter')
FileOutputStream = plus.android.importClass('java.io.FileOutputStream') // FileOutputStream = plus.android.importClass('java.io.FileOutputStream')
OutputStreamWriter = plus.android.importClass('java.io.OutputStreamWriter') // OutputStreamWriter = plus.android.importClass('java.io.OutputStreamWriter')
// BufferedReader = plus.android.importClass('java.io.BufferedReader') // BufferedReader = plus.android.importClass('java.io.BufferedReader')
// FileInputStream = plus.android.importClass('java.io.FileInputStream') // FileInputStream = plus.android.importClass('java.io.FileInputStream')
// InputStreamReader = plus.android.importClass('java.io.InputStreamReader') // InputStreamReader = plus.android.importClass('java.io.InputStreamReader')
LogPath = '' LogPath = ''
constructor(folderName = '_zyzs_log') { constructor(folderName = '_zyzs_log') {
if (this.Environment.MEDIA_MOUNTED || !this.Environment.isExternalStorageRemovable()) { // if (this.Environment.MEDIA_MOUNTED || !this.Environment.isExternalStorageRemovable()) {
this.LogPath = this.main.getExternalFilesDir(null).getPath() + folderName // this.LogPath = this.main.getExternalFilesDir(null).getPath() + folderName
} else { // } else {
this.LogPath = this.main.getFilesDir().getPath() + folderName // this.LogPath = this.main.getFilesDir().getPath() + folderName
} // }
console.log('日志文件存放路径->', this.LogPath) // console.log('日志文件存放路径->', this.LogPath)
} }
writeLog(tag, msg) { writeLog(tag, msg) {
return
let date = getTime('YYYY-MM-DD') let date = getTime('YYYY-MM-DD')
let datetime = getTime() let datetime = getTime()
//文件名 //文件名
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!