Commit 637d8fa9 by 李伟康

Merge branch 'SAAS+V4.53.0' into dev

2 parents 9d701c14 5d70dfb5
Showing 229 changed files with 689 additions and 314 deletions
......@@ -4,24 +4,20 @@
"version" : "0.0",
"configurations" : [
{
"app-plus" :
{
"launchtype" : "local"
},
"default" :
{
"launchtype" : "local"
},
"h5" :
{
"launchtype" : "local"
},
"mp-weixin" :
{
"launchtype" : "local"
},
"provider" : "aliyun",
"type" : "uniCloud"
"app-plus" : {
"launchtype" : "local"
},
"default" : {
"launchtype" : "local"
},
"h5" : {
"launchtype" : "local"
},
"mp-weixin" : {
"launchtype" : "local"
},
"provider" : "aliyun",
"type" : "uniCloud"
},
{
"playground" : "standard",
......
......@@ -2,7 +2,7 @@
* @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2024-04-07 17:09:53
* @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-12-31 10:50:50
* @LastEditTime: 2025-01-14 11:27:04
* @FilePath: \gl_tape\App.vue
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
......@@ -15,10 +15,8 @@ export default {
computed: {
...mapState('audio', ['isEnd', 'isStart'])
},
onLoad() {},
onLaunch: async function () {
this.onKeep()
// this.init()
this.setAPPVersion()
setTimeout(() => {
plus.screen.unlockOrientation() //解除锁定屏幕方向
......@@ -31,60 +29,21 @@ export default {
},
methods: {
onKeep() {
keepAlive.onKeep(
{
title: '接待',
content: '接待通知'
},
res => {
console.log(res)
}
)
},
init() {
uni.addInterceptor('navigateTo', {
//监听跳转
invoke(e) {
console.log('******** invoke-navigateTo ********', e.url.split('?').shift())
if (PATH.includes(e.url.split('?').shift())) {
console.log(888)
keepAlive &&
keepAlive.onKeep(
{
title: '接待',
content: '接待通知'
},
res => {
console.log(res)
}
}
})
//2
uni.addInterceptor('redirectTo', {
//监听关闭本页面跳转
invoke(e) {
console.log('******** redirectTo ********', e.url)
}
})
uni.addInterceptor('switchTab', {
//监听tabBar跳转
invoke(e) {
console.log('******** switchTab ********', e.url)
}
})
//4
uni.addInterceptor('navigateBack', {
//监听返回
invoke(e) {
console.log('******** navigateBack ********', e)
}
})
)
},
setAPPVersion() {
let version = plus.runtime.version
let storageVersion = uni.$storage.get('storageVersion')
console.log(storageVersion, version)
uni.$logger.local.info(`storageVersion ->${storageVersion}, version ->${version}`)
if (storageVersion != version) {
uni.$storage.rm('userInfo')
uni.$storage.rm('noSignInUuid')
......@@ -94,7 +53,7 @@ export default {
},
onShow: async function () {
uni.$logger.local.info('切回app')
this.$store.dispatch('setBackgroundState', false)
// const systemInfo = await uni.$api.systemApi.getMockData();
// if (systemInfo.isCheckedUpdate) {
// checkUpdate();
......@@ -106,7 +65,7 @@ export default {
// });
},
onHide: function () {
uni.$logger.local.info('切出app')
this.$store.dispatch('setBackgroundState', true)
},
onError: function (e) {
try {
......@@ -119,12 +78,8 @@ export default {
</script>
<style lang="scss">
body {
// overflow: hidden;
}
page {
font-size: toRpx(28);
font-size: 28rpx;
height: 100%;
min-height: 100%;
}
......@@ -170,7 +125,7 @@ button {
margin: 0;
padding: 0;
line-height: 1.5;
font-size: toRpx(28);
font-size: 28rpx;
background-color: transparent;
border-radius: 0;
position: relative;
......@@ -182,14 +137,14 @@ button::after {
// 指定按钮按下去的样式类
.button-hover {
transform: translate(toRpx(1), toRpx(1));
transform: translate(1rpx, 1rpx);
}
.webview-container {
position: absolute;
width: toRpx(100);
height: toRpx(100);
top: 0;
left: 0;
width: 100rpx;
height: 100rpx;
top: 0rpx;
left: 0rpx;
}
</style>
/*
* @Description:
* @Description:
* @Author: huyue
* @Date: 2024-09-05 14:05:25
* @LastEditors: huyue
* @LastEditTime: 2024-09-13 11:08:55
*/
import http from "../request/http";
import http from '../request/http'
module.exports = {
/**获取APP更新 */
findSoureList (data) {
findSoureList(data) {
return http.post({
method: "dj.api.smartcarlife.recepiton.soure.findSoureList",
projectName: "boutique",
...data,
});
method: 'dj.api.smartcarlife.recepiton.soure.findSoureList',
projectName: 'boutique',
...data
})
},
/** 查询可发放礼券-分页查询商户券列表 */
findCouponList (data) {
findCouponList(data) {
return http.post({
method: "dj.api.smartcarlife.merchantCoupon.pageForZYApp",
projectName: "boutique",
method: 'dj.api.smartcarlife.merchantCoupon.pageForZYApp',
projectName: 'boutique',
onlyUsable: true,
currentPage: 1,
pageSize: 99999,
...data,
});
...data
})
},
/**查询用户是否领券 */
findCustomerReceivedStatus (data) {
findCustomerReceivedStatus(data) {
return http.post({
method: "dj.api.smartcarlife.customerCoupon.pageForZYApp",
projectName: "boutique",
method: 'dj.api.smartcarlife.customerCoupon.pageForZYApp',
projectName: 'boutique',
...data,
currentPage: 1,
pageSize: 99999,
statusList: [0, 1]
});
})
},
/**历史成交客户 */
historyDealOrderPage (data) {
historyDealOrderPage(data) {
return http.post({
method: "dj.api.smartcarlife.order.historyDealOrder.page",
projectName: "boutique",
...data,
});
method: 'dj.api.smartcarlife.order.historyDealOrder.page',
projectName: 'boutique',
...data
})
},
// 历史订单列表
getQuotationList (data) {
getQuotationList(data) {
return http.post({
method: "dj.api.smartcarlife.vehicle.damage.upgrade.quotation.page",
projectName: "boutique",
...data,
});
method: 'dj.api.smartcarlife.vehicle.damage.upgrade.quotation.page',
projectName: 'boutique',
...data
})
},
// 历史订单列表
getOrderList(data) {
return http.post({
method: 'dj.api.smartcarlife.vehicle.damage.upgrade.for.pad.page',
projectName: 'boutique',
...data
})
},
/**客户邀约记录 */
customerInviteRecordPage (data) {
customerInviteRecordPage(data) {
return http.post({
method: "dj.api.smartcarlife.customerInviteRecord.page",
projectName: "boutique",
...data,
});
method: 'dj.api.smartcarlife.customerInviteRecord.page',
projectName: 'boutique',
...data
})
},
/**轻改素材配置 */
getBoutiqueMaterialConfig (data) {
getBoutiqueMaterialConfig(data) {
return http.post({
method: "dj.api.boutique.recepiton.material.merchant.detail",
projectName: "boutique",
...data,
});
method: 'dj.api.boutique.recepiton.material.merchant.detail',
projectName: 'boutique',
...data
})
},
/** 案例视频 */
getCaseList(data) {
return http.post({
method: "dj.api.smartcarlife.recepiton.material.case.find",
projectName: "boutique",
method: 'dj.api.smartcarlife.recepiton.material.case.find',
projectName: 'boutique',
...data
})
},
/** 获取类目 */
getCategory(data) {
return http.post({
method: "dj.api.boutique.recepiton.material.merchant.category",
projectName: "boutique",
method: 'dj.api.boutique.recepiton.material.merchant.category',
projectName: 'boutique',
...data
})
},
/**
* 客户邀约记录-邀约类型数目统计
*/
getInviteRecordCount(data) {
return http.post({
method: 'dj.api.smartcarlife.customerInviteRecord.inviteStatus.count',
projectName: 'boutique',
...data
})
}
};
}
......@@ -164,5 +164,152 @@ module.exports = {
projectName: 'boutique',
...data
})
},
/** 系统消息埋点接口 */
addSystemInfo(data) {
return http.post({
method: 'dj.api.smartcarlife.contentManagerTask.view.add',
projectName: 'mindworkplate',
...data
})
},
leaveSystemInfo(data) {
return http.post({
method: 'dj.api.smartcarlife.contentManagerTask.view.leave',
projectName: 'mindworkplate',
...data
})
},
/** 消息盒子 */
// 获取客户标签分类信息
getClassConfig(data = {}) {
return http.post({
method: 'dj.pad.api.list.script.config.class',
projectName: 'pad',
...data
})
},
// 查阅未阅读的优秀话术
getUnreadRecord(data) {
return http.post({
method: 'dj.pad.api.list.unread.script.message.box.record',
projectName: 'pad',
...data
})
},
// 分页查询的优秀话术接口
getPageRecord(data) {
return http.post({
method: 'dj.pad.api.page.script.message.box.record',
projectName: 'pad',
...data
})
},
// 更新话术状态
updateMessageStatus(data) {
return http.post({
method: 'dj.pad.api.update.script.message.status',
projectName: 'pad',
...data
})
},
// 埋点
extractExcellent(data) {
return http.post({
method: 'dj.pad.api.burying.point.script.extract.excellent.browse',
projectName: 'pad',
...data
})
},
/** 系统消息接口 */
// 分页查询系统消息
getTaskInfo(data) {
return http.post({
method: 'dj.pad.api.contentManagerTask.page',
projectName: 'pad',
...data
})
},
// 查询系统详细信息
getTaskById(data) {
return http.post({
method: 'dj.pad.api.contentManagerTask.getById',
projectName: 'pad',
...data
})
},
// 根据状态查询消息数量
getMessageCount(data) {
return http.post({
method: 'dj.pad.api.message.box.count.by.status',
projectName: 'pad',
...data
})
},
// 获取ai智能体入口
getAiagentList(data) {
return http.post({
method: 'dj.pad.api.aiagent.get.entry.list',
projectName: 'pad',
...data
})
},
// 预警消息
getWarningPage(data) {
return http.post({
method: 'dj.pad.api.message.box.findWarningNotificationPage',
projectName: 'pad',
...data
})
},
recordInsert(data) {
return http.post(
{
method: 'clue.api.burial.point.record.batch.insert',
projectName: 'clue',
...data
},
false,
'scrm'
)
},
//获取北森代办数量
getUnreadCount(data) {
return http.post(
{
method: 'dj.pad.api.beisen.getUnreadCount',
projectName: 'pad',
...data
},
true
)
},
//获取北森SSO鉴权
findBeiSenSSOToken(data) {
return http.post(
{
method: 'dj.pad.api.beisen.findBeiSenSSOToken',
projectName: 'pad',
...data
},
true
)
},
//北森埋点进入
dynamicrecordAdd(data) {
return http.post({
method: 'dj.pad.api.beisen.dynamicrecord.add',
projectName: 'pad',
...data
})
},
//更新埋点离开信息
dynamicrecordLeave(data) {
return http.post({
method: 'dj.pad.api.beisen.dynamicrecord.leave',
projectName: 'pad',
...data
})
}
}
import http from "../request/http";
import environment from "@/env";
import http from '../request/http'
import environment from '@/env'
module.exports = {
/**查询当前门店是否有客户档案权限 */
haveCustomerAccess (data) {
haveCustomerAccess(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.findPermissionsMerchantList',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
/**查询当前门店客户档案列表 */
getCustomerFileList (data) {
getCustomerFileList(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.customerInfoPage',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
/* 删除客户档案*/
delCustomerFile (data) {
delCustomerFile(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.deleteVisitsInfo',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
/** 根据业务查询接待场景 */
findAllSence (data) {
findAllSence(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.findAllSence',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
/**根据业务查询客户标签 */
findCustomerTags (data) {
findCustomerTags(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.findSenceTag',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
/**
* 查询客户档案详情
*/
findVisitsInfo (data) {
findVisitsInfo(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.findVisitsInfo',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
/*
* 保存客户档案
*/
saveVisitsInfo (data) {
* 保存客户档案
*/
saveVisitsInfo(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.saveVisitsInfo',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
/**
* 更新客户档案
*/
updateVisitsInfo (data) {
updateVisitsInfo(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.updateVisitsInfo',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
/**查询客户档案列表 */
getCustomerInfoList (data) {
getCustomerInfoList(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.customerInfoList',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
/**接待客户素材
*
*
*/
getMaterialResponsePage (data) {
getMaterialResponsePage(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.getMaterialResponsePage',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
/**素材详情 查询素材详情 */
getMaterialDetail (data) {
getMaterialDetail(data) {
return http.post({
method: 'dj.api.smartcarlife.customervisits.getMaterialById',
projectName: "boutique",
...data,
});
projectName: 'boutique',
...data
})
},
}
\ No newline at end of file
/**直营驻店人员 */
saleOpen(data) {
return http.post({
method: 'dj.api.car.boutique.resident.direct.sale.merchant',
projectName: 'boutique',
...data
})
}
}
/*
* @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2024-12-19 11:02:01
* @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-12-19 11:02:25
* @LastEditors: yangming@didihu.com.cn yangming@didihu.com.cn
* @LastEditTime: 2025-04-23 17:19:15
* @FilePath: \gl-tape\api\module\point.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
......@@ -44,12 +44,190 @@ module.exports = {
projectName: 'boutique',
...data
})
} /**积分首页 */,
},
/**积分首页 */
getPoint(data) {
return http.post({
method: 'dj.api.car.boutique.resident.point.home.page',
projectName: 'boutique',
...data
})
},
/**积分奖励规则 */
rewardRule(data) {
return http.post({
method: 'dj.api.car.boutique.resident.point.reward.rule',
projectName: 'boutique',
...data
})
},
badgeList(data) {
return http.post({
method: 'dj.api.car.boutique.resident.point.month.badge.list',
projectName: 'boutique',
...data
})
},
incomeMeasurementConfig(data) {
return http.post({
method: 'dj.smartcarlife.api.incomeMeasurement.switch.config.search',
projectName: 'boutique',
...data
})
},
/**员工收入测算获取员工信息 */
incomeCalculation(data) {
return http.post({
method: 'dj.api.smartcarlife.staff.incomeCalculation.staffInfo',
projectName: 'boutique',
...data
})
},
/**获取员工绩效测算详情 */
incomeCalculationDetail(data) {
return http.post({
method: 'dj.api.smartcarlife.staff.incomeCalculation.detail',
projectName: 'boutique',
...data
})
},
/**分页查询员工月度工资统计列表 */
pageStat(data) {
return http.post({
method: 'dj.api.smartcarlife.staff.monthSalary.pageStat',
projectName: 'boutique',
...data
})
},
/**获取员工(测算/历史)月度工资明细 */
monthSalaryDetail(data) {
return http.post({
method: 'dj.api.smartcarlife.staff.monthSalary.detail',
projectName: 'boutique',
...data
})
},
/**获取试算门店工资绩效配置详细 */
getLatestConfigDetail(data) {
return http.post({
method: 'dj.api.smartcarlife.staff.incomeCalculation.getLatestConfigDetail',
projectName: 'boutique',
...data
})
},
/**员工工资试算*/
monthSalaryCalculation(data) {
return http.post({
method: 'dj.api.smartcarlife.staff.incomeCalculation.monthSalaryCalculation',
projectName: 'boutique',
...data
})
},
/**员工考勤日历 */
calendarDetail(data) {
return http.post({
method: 'dj.api.smartcarlife.clock.in.staff.calendar',
projectName: 'boutique',
...data
})
},
/**查询员工提示信息 */
getTipsMessage(data) {
return http.post({
method: 'dj.api.smartcarlife.staff.tipsMessage.list',
projectName: 'boutique',
...data
})
},
/**直级介绍配置查询 */
getJobConfig(data) {
return http.post({
method: 'dj.smartcarlife.api.job.rank.config.search',
projectName: 'boutique',
...data
})
},
/** 优惠券二级列表 */
getGrantRecord(data) {
return http.post({
method: 'dj.api.car.boutique.resident.coupon.grant.record',
projectName: 'boutique',
...data
})
},
/** 优惠券领取 */
receiveCoupon(data) {
return http.post({
method: 'dj.api.car.boutique.resident.coupon.receive',
projectName: 'boutique',
...data
})
},
/** 统计 优惠券 类型总数 */
statisticsCount(data) {
return http.post({
method: 'dj.api.smartcarlife.resident.coupon.statistics.count',
projectName: 'boutique',
...data
})
},
/** 查询附近地址 */
searchStoreAddress(data) {
return http.post({
method: 'dj.api.car.boutique.resident.coupon.address.search',
projectName: 'boutique',
...data
})
},
/** 查询勋章列表 */
searchLevelConfig(data) {
return http.post({
method: 'dj.api.car.boutique.resident.level.config.page',
projectName: 'boutique',
...data
})
},
/** 我的考勤相关接口 */
/** 员工考勤日历 */
newCalendar(data) {
return http.post({
method: 'dj.api.car.boutique.clock.in.staff.calendar.new',
projectName: 'boutique',
...data
})
},
/** 打卡申诉列表 */
getAppealList(data) {
return http.post({
method: 'dj.api.car.boutique.clock.in.staff.appeal.list',
projectName: 'boutique',
...data
})
},
/** 提交打卡申诉 */
appealCommit(data) {
return http.post({
method: 'dj.api.car.boutique.clock.in.staff.appeal.commit',
projectName: 'boutique',
...data
})
},
/** 考勤出勤明细 */
attendanceDetail(data) {
return http.post({
method: 'dj.api.car.boutique.clock.in.staff.attendance.detail',
projectName: 'boutique',
...data
})
},
appealExist(data) {
return http.post({
method: 'dj.api.car.boutique.clock.in.staff.appeal.exist',
projectName: 'boutique',
...data
})
}
}
......@@ -2,28 +2,22 @@ import http from '../request/http'
import { env } from '../../env'
const serverConfig = {
mockRequestCount: null,
mockTimer: {},
mockCache: null
},
bydServerConfig = {
mockRequestCount: null,
mockTimer: {},
mockCache: null
},
mockRequestCount: null,
mockTimer: {},
mockCache: null
},
boutiqueServerConfig = {
mockRequestCount: null,
mockTimer: {},
mockCache: null
},
configModule = 'app-tape',
bydConfigModule = 'byd-pad-config',
appConfigModule = 'app-config-url',
boutiqueConfigModule = 'boutique-pad-config',
appConfigUrl = `https://config-center-backend.glsx.com.cn/glsxAdmin/config?moduleUrl=${appConfigModule}&env=${env}`,
configUrl = `https://config-center-backend.glsx.com.cn/glsxAdmin/config?moduleUrl=${configModule}&env=${env}`,
bydConfigUrl = `https://config-center-backend.glsx.com.cn/glsxAdmin/config?moduleUrl=${bydConfigModule}&env=${env}`,
boutiqueConfigUrl = `https://config-center-backend.glsx.com.cn/glsxAdmin/config?moduleUrl=${boutiqueConfigModule}&env=${env}`
/**获取mock数据 */
/**获取APP配置 */
const getMockData = async (immediate = false) => {
const MOCKDATA = uni.$storage.get('mock_data')
try {
......@@ -35,8 +29,6 @@ const getMockData = async (immediate = false) => {
serverConfig.mockRequestCount = Date.now()
const data = await http.uni_request({ url: configUrl })
data.createTime = Date.now()
data.moduleList = await imgToBase64(data.moduleList, 'thumbnail')
data.default_moduleList = await imgToBase64(data.default_moduleList, 'thumbnail')
serverConfig.mockCache = data
uni.$storage.set('mock_data', data)
return Promise.resolve(data)
......@@ -60,84 +52,32 @@ const getMockData = async (immediate = false) => {
return Promise.reject(error)
}
}
const imgToBase64 = (list, urlKey) => {
return new Promise((resolve, reject) => {
let arr = [],
newList = JSON.parse(JSON.stringify(list))
list.map((e, index) => {
if (!e[urlKey]) return resolve(list)
if (!e[urlKey].startsWith('https')) return resolve(list)
uni.request({
url: urlKey ? e[urlKey] : e,
method: 'GET',
responseType: 'arraybuffer',
success: res => {
const base64 = `data:image/png;base64,${uni.arrayBufferToBase64(res.data)}`
newList[index][urlKey] = base64
newList[index][`original_${urlKey}`] = e[urlKey]
arr.push(e)
if (arr.length === list.length) resolve(newList)
},
fail: err => {
reject(err)
}
})
})
})
}
const updateMockData = (dataList, keyList, storageName = 'mock_data') => {
const mockData = uni.$storage.get(storageName)
keyList.map(key => {
mockData[key] = dataList[key]
/**
*权益配置
*/
const findReceptionpriproConfigList = data => {
return http.post({
method: 'dj.api.smartcarlife.recepiton.customer.findReceptionpriproConfigList',
projectName: 'boutique',
...data
})
setTimeout(() => {
uni.$storage.set(storageName, mockData)
}, 1e3)
}
/**
*获取比亚迪配置
*获取后台延保素材ID
*/
const getBydMockData = async (immediate = false) => {
const MOCKDATA = uni.$storage.get('byd_mock_data')
try {
if (!immediate && MOCKDATA && Date.now() - MOCKDATA.createTime < 5 * 60e3) {
return Promise.resolve(MOCKDATA)
} else {
if (!bydServerConfig.mockRequestCount || immediate) {
bydServerConfig.mockCache = null
bydServerConfig.mockRequestCount = Date.now()
const data = await http.uni_request({ url: bydConfigUrl })
data.createTime = Date.now()
data.moduleList = await imgToBase64(data.moduleList, 'thumbnail')
bydServerConfig.mockCache = data
uni.$storage.set('byd_mock_data', data)
return Promise.resolve(data)
} else {
const key = Date.now()
return new Promise(resolve => {
bydServerConfig.mockTimer[key] = setInterval(() => {
if (bydServerConfig.mockCache) {
clearInterval(bydServerConfig.mockTimer[key])
bydServerConfig.mockRequestCount = null
resolve(bydServerConfig.mockCache)
}
}, 1e3)
})
}
}
} catch (error) {
console.log(error)
if (bydServerConfig.mockTimer[key]) clearInterval(bydServerConfig.mockTimer[key])
bydServerConfig.mockRequestCount = null
return Promise.reject(error)
}
const getEquityMaterialId = data => {
return http.post({
method: 'dj.api.smartcarlife.reception.home.page.material.view',
projectName: 'boutique',
...data
})
}
/**
*获取后台素材配置
*获取后台延保素材配置
*/
const findReceptionpriproConfigList = data => {
const getEquityMaterialConfig = data => {
return http.post({
method: 'dj.api.smartcarlife.recepiton.customer.findReceptionpriproConfigList',
method: 'dj.api.car.boutique.reception.home.page.entrance.material.detail',
projectName: 'boutique',
...data
})
......@@ -184,13 +124,135 @@ const getImageVersion = async () => {
const accountInfo = await getMockData()
return accountInfo?.version || Date.now()
}
/**获取素材配置 */
const getSoureData = async (shopMerchantId, sceneType, params = {}) => {
try {
const res = await getEquityMaterialId({
merchantId: shopMerchantId,
...params
})
if (res && res.id) {
let data = await getEquityMaterialConfig({
id: res.id
})
if (data) {
let { toolList, materialInfoList } = data,
storageName = `source_${sceneType}_${shopMerchantId}`
if (params.brandId && params.subBrandId) storageName += `_${params.brandId}_${params.subBrandId}`
let hasEquity = materialInfoList.find(e => e.componentName == 'insurance')
if (hasEquity) {
let configList
try {
configList = await findReceptionpriproConfigList({})
uni.$storage.set('findReceptionpriproConfigList', configList)
} catch (error) {
configList = uni.$storage.get('findReceptionpriproConfigList')
}
const toolOtherList = configList.map(i => {
return {
id: hasEquity.id + 100 + i.id,
shortTitle: i.productName,
shortTitleUrl: i.procuctLog
}
})
toolList = toolList.concat(toolOtherList)
const moduleOtherList = configList.map(i => {
return {
id: hasEquity.id + 100 + i.id,
title: i.productName,
shortTitleUrl: i.procuctLog,
productPoster: i.productPoster,
showAlt: false,
componentName: 'CaseCenter',
receptionpriproCusCaseList: i.receptionpriproCusCaseList,
hide: true
}
})
materialInfoList = materialInfoList.concat(moduleOtherList)
}
data.toolList = await imgTransformBase64(toolList, ['shortTitleUrl'])
data.moduleList = await imgTransformBase64(materialInfoList, ['thumbnail', 'receptionSourceDetailList', 'screenList'])
uni.setStorageSync(storageName, {
moduleList: data.moduleList,
toolList: data.toolList,
id: res.id
})
return Promise.resolve(data)
}
}
} catch (error) {
console.log(error)
uni.showToast({
title: error,
icon: 'none',
duration: 2000
})
}
}
/**批量图片转base64 */
const imgTransformBase64 = async (imgList = [], keyList = []) => {
return await Promise.all(
imgList?.map(async e => {
await Promise.all(
Object.keys(e).map(async key => {
if (keyList.includes(key)) {
let isArray = Array.isArray(e[key])
if (isArray) {
await Promise.all(
e[key].map(async i => {
await Promise.all(
Object.keys(i).map(async k => {
// i[`original_${k}`] = JSON.parse(JSON.stringify(i[k]))
if (k == 'detailUrl' && i[k]) i[k] = await getBase64(i[k])
})
)
})
)
} else {
if (typeof e[key] === 'string' && e[key]) {
// e[`original_${key}`] = JSON.parse(JSON.stringify(e[key]))
e[key] = await getBase64(e[key])
}
if (e[key] && typeof e[key] === 'object') {
await Promise.all(
Object.keys(e[key]).map(async k => {
// e[key][`original_${k}`] = JSON.parse(JSON.stringify(e[key][k]))
if (e[key][k]) e[key][k] = await getBase64(e[key][k])
})
)
}
}
}
})
)
return e
})
)
}
/**转base64 */
const getBase64 = async url => {
return new Promise((resolve, reject) => {
uni.request({
url,
method: 'GET',
responseType: 'arraybuffer',
success: res => {
const base64 = `data:image/png;base64,${uni.arrayBufferToBase64(res.data)}`
resolve(base64)
},
fail: err => {
resolve(url)
// reject(err)
}
})
})
}
module.exports = {
getImageVersion,
getMockData,
imgToBase64,
updateMockData,
getBydMockData,
getBoutiqueMockData,
findReceptionpriproConfigList
findReceptionpriproConfigList,
getSoureData,
getEquityMaterialId,
getEquityMaterialConfig
}
import http from "../request/http";
import http from '../request/http'
module.exports = {
/**获取短信 */
getSmsCode (data = {}) {
data.projectName = "boutique";
return http.fetch("dj.api.smartcarlife.sms.get.code", data);
getSmsCode(data = {}) {
data.projectName = 'boutique'
return http.fetch('dj.api.smartcarlife.sms.get.code', data)
},
/**手机验证码登录 */
smsLogin (data = {}) {
smsLogin(data = {}) {
data.projectName = 'boutique'
data.source = 'MINIAPP'
data.productCode = 'PC00c2'
return http.fetch('dj.api.smartcarlife.sms.applogin', data)
},
/**免登 */
autoLogin (data = {}) {
data.projectName = "boutique";
return http.fetch("dj.api.smartcarlife.sms.noSignIn.login", data);
autoLogin(data = {}) {
data.projectName = 'boutique'
return http.fetch('dj.api.smartcarlife.sms.noSignIn.login', data)
},
// 获取园区店下的4s店
getSceneMerchantRefStoreList (data) {
data.projectName = "boutique";
getSceneMerchantRefStoreList(data) {
data.projectName = 'boutique'
return http.post({
method: "dj.api.scenemerchantref.query4SRefByYqShopByLogin",
...data,
});
method: 'dj.api.scenemerchantref.query4SRefByYqShopByLogin',
...data
})
},
/**获取帐号列表 */
getListSelectAccount (data = {}) {
data.projectName = "boutique";
return http.fetch("dj.api.smartcarlife.workWechat.listSelectAccount", data);
getListSelectAccount(data = {}) {
data.projectName = 'boutique'
return http.fetch('dj.api.smartcarlife.workWechat.listSelectAccount', data)
},
/**选择帐号登陆 */
selectAccountLogin (data) {
data.projectName = "boutique";
selectAccountLogin(data) {
data.projectName = 'boutique'
return http.post({
method: "dj.api.smartcarlife.workWechat.selectAccountLogin",
...data,
});
method: 'dj.api.smartcarlife.workWechat.selectAccountLogin',
...data
})
},
// 选择4s店和场景
selectMerchantScene (data) {
data.projectName = "boutique";
selectMerchantScene(data) {
data.projectName = 'boutique'
return http.post({
method: "dj.api.smartcarlife.selectMerchantScene",
...data,
});
method: 'dj.api.smartcarlife.selectMerchantScene',
...data
})
},
// 获取园区店开通的场景入口
getYqMerchantSceneConfigAPI (data) {
data.projectName = "boutique";
getYqMerchantSceneConfigAPI(data) {
data.projectName = 'boutique'
return http.post({
method: "dj.api.smartcarlife.select.openScene.info",
...data,
});
method: 'dj.api.smartcarlife.select.openScene.info',
...data
})
},
/**退出*/
logout (data = {}) {
logout(data = {}) {
data.projectName = 'boutique'
return http.fetch('dj.api.smartcarlife.logout', data);
return http.fetch('dj.api.smartcarlife.logout', data)
},
/**
* 查询门店品牌 "渠道标识channelType 1.问界 2.比亚迪 3.其他"
* 查询门店品牌 "渠道标识channelType 1.问界 2.比亚迪 3.其他"
*/
getMerchantBrand (data = {}) {
data.projectName = "boutique";
getMerchantBrand(data = {}) {
data.projectName = 'boutique'
return http.post({
method: "dj.api.smartcarlife.recepiton.findMerchantBrand",
...data,
});
method: 'dj.api.smartcarlife.recepiton.findMerchantBrand',
...data
})
},
/**
* 查询门店保险权益
*/
getMerchantInsuranceList (data = {}) {
data.projectName = "boutique";
getMerchantInsuranceList(data = {}) {
data.projectName = 'boutique'
return http.post({
method: "dj.api.smartcarlife.recepiton.findMerchantItem",
...data,
});
method: 'dj.api.smartcarlife.recepiton.findMerchantItem',
...data
})
},
};
/**
* 员工隐私密码验证
*/
verifyStaffPassword(data = {}) {
data.projectName = 'boutique'
return http.post({
method: 'dj.api.smartcarlife.staff.private.password.verify',
...data
})
}
}

131 KB | W: | H:

189 KB | W: | H:

assets/images/boutique/nothing.png
assets/images/boutique/nothing.png
assets/images/boutique/nothing.png
assets/images/boutique/nothing.png
  • 2-up
  • Swipe
  • Onion skin
No preview for this file type
No preview for this file type
No preview for this file type

26.9 KB | W: | H:

89.7 KB | W: | H:

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

958 Bytes | W: | H:

6.14 KB | W: | H:

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

1.27 MB | W: | H:

2.43 MB | W: | H:

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

6.42 KB | W: | H:

6.89 KB | W: | H:

assets/spritesmith/certificate.png
assets/spritesmith/certificate.png
assets/spritesmith/certificate.png
assets/spritesmith/certificate.png
  • 2-up
  • Swipe
  • Onion skin

30.6 KB | W: | H:

5.53 KB | W: | H:

assets/spritesmith/customer-file-active.png
assets/spritesmith/customer-file-active.png
assets/spritesmith/customer-file-active.png
assets/spritesmith/customer-file-active.png
  • 2-up
  • Swipe
  • Onion skin

6.06 KB | W: | H:

948 Bytes | W: | H:

assets/spritesmith/customer-file.png
assets/spritesmith/customer-file.png
assets/spritesmith/customer-file.png
assets/spritesmith/customer-file.png
  • 2-up
  • Swipe
  • Onion skin

28.1 KB | W: | H:

5.01 KB | W: | H:

assets/spritesmith/home-active.png
assets/spritesmith/home-active.png
assets/spritesmith/home-active.png
assets/spritesmith/home-active.png
  • 2-up
  • Swipe
  • Onion skin

28.9 KB | W: | H:

30.6 KB | W: | H:

assets/spritesmith/point-active.png
assets/spritesmith/point-active.png
assets/spritesmith/point-active.png
assets/spritesmith/point-active.png
  • 2-up
  • Swipe
  • Onion skin

6.17 KB | W: | H:

6.84 KB | W: | H:

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

6.95 KB | W: | H:

1.22 KB | W: | H:

assets/spritesmith/record.png
assets/spritesmith/record.png
assets/spritesmith/record.png
assets/spritesmith/record.png
  • 2-up
  • Swipe
  • Onion skin
This diff is collapsed. Click to expand it.
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!