Commit 6697f61c by 胡悦

提交

1 parent 12c0f6cb
import http from "../request/http";
module.exports = {
/**获取APP更新 */
findSoureList(data) {
return http.post({
method: 'dj.api.smartcarlife.recepiton.soure.findSoureList',
projectName: "boutique",
...data,
});
}
}
\ No newline at end of file \ No newline at end of file
...@@ -2,8 +2,10 @@ ...@@ -2,8 +2,10 @@
import commonApi from './common' import commonApi from './common'
import systemApi from './systemApi' import systemApi from './systemApi'
import userApi from './userApi' import userApi from './userApi'
import boutiqueApi from './boutique'
module.exports = { module.exports = {
commonApi, commonApi,
systemApi, systemApi,
userApi userApi,
boutiqueApi
} }
\ No newline at end of file \ No newline at end of file
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @Author: huyue * @Author: huyue
* @Date: 2024-05-30 14:40:39 * @Date: 2024-05-30 14:40:39
* @LastEditors: huyue * @LastEditors: huyue
* @LastEditTime: 2024-05-31 14:56:25 * @LastEditTime: 2024-05-31 15:14:36
--> -->
<template> <template>
<view> <view>
...@@ -17,13 +17,13 @@ ...@@ -17,13 +17,13 @@
<view class="wrapper"> <view class="wrapper">
<view class="wrapper-content"> <view class="wrapper-content">
<view class="first-tab"> <view class="first-tab">
<view class="tab-item" v-for="(i, index) in firstNav" :key="index" @click="changeIndex(index)"> <view class="tab-item" v-for="(i, index) in firstNav" :key="index" @click="changeIndex(index, 'firstIndex')">
<view class="sprite-icon" :class="[firstIndex == index ? `icon-${i.class} active` : '']" :style="{left: i.left}"></view> <view class="sprite-icon" :class="[firstIndex == index ? `icon-${i.class} active` : '']" :style="{left: i.left}"></view>
{{i.name}}</view> {{i.name}}</view>
</view> </view>
<view class="content"> <view class="content">
<view class="second-tab"> <view class="second-tab">
<view v-for="(item, ind) in secondNav" :key="ind" class="tab-item" :class="[secondIndex == ind ? 'active':'']">{{item}}</view> <view v-for="(item, ind) in secondNav" :key="ind" class="tab-item" :class="[secondIndex == ind ? 'active':'']" @click="changeIndex(ind, 'secondIndex')">{{item}}</view>
</view> </view>
</view> </view>
</view> </view>
...@@ -58,11 +58,19 @@ export default { ...@@ -58,11 +58,19 @@ export default {
secondNav: ['车窗膜', '改色膜', '车衣', '天窗冰甲'] secondNav: ['车窗膜', '改色膜', '车衣', '天窗冰甲']
} }
}, },
mounted () { mounted() {
this.firstIndex = 0
this.secondIndex = 0
this.findSoureList()
}, },
methods: { methods: {
changeIndex(index) { changeIndex(index, name) {
this.firstIndex = index this[name] = index
},
async findSoureList() {
console.log(1111)
const data = await uni.$api.boutiqueApi.findSoureList({})
console.log(data)
} }
} }
} }
...@@ -146,9 +154,11 @@ export default { ...@@ -146,9 +154,11 @@ export default {
display: flex; display: flex;
background: #F2F2F2; background: #F2F2F2;
border-radius: 16rpx; border-radius: 16rpx;
height: 100%;
align-items: center;
.tab-item { .tab-item {
display: inline-block; display: inline-block;
padding: 18rpx 48rpx; padding: 0 48rpx;
&.active { &.active {
background-color: #fff; background-color: #fff;
margin: 4rpx; margin: 4rpx;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!