zpj 2 місяців тому
батько
коміт
106a1ea9ea
3 змінених файлів з 60 додано та 4 видалено
  1. 2 0
      api/chart.js
  2. 58 4
      pages/index/index.vue
  3. BIN
      static/tenlist.png

+ 2 - 0
api/chart.js

@@ -15,3 +15,5 @@ export const chartList = (data) => request(url + 'list', 'post', data)
 export const chartNewList = (data) => request(url + 'new_list', 'post', data)
 
 export const chartSummary = (data) => request(url + 'summary', 'post', data)
+
+export const distributorIncomeList = (data) => request(url + 'distributor_income_list', 'post', data)

+ 58 - 4
pages/index/index.vue

@@ -235,16 +235,57 @@
 						</view>
 					</view> -->
 				</view>
-				<view class="flex-1 chart-box">
+				
+				
+				<!-- <view class="flex-1 chart-box">
 					<image class="chart-bg" src="/static/k2.png" mode=""></image>
 					<view class="title-box">
 						<image class="title-img" src="/static/kbt.png" mode=""></image>
 					</view>
 					<view class="flex-1 z-3 column-box">
-						<!-- 曲线图 -->
+						
 						<lineVue ref="lineRef"></lineVue>
 					</view>
+				</view> -->
+				
+				
+				<view class="flex-1 chart-box">
+					<image class="chart-bg" src="/static/k2.png" mode=""></image>
+					<view class="title-box mb-15">
+						<image class="title-img" src="@/static/tenlist.png" mode=""></image>
+						
+					</view>
+					<swiper class="scroll-view-css z-3" circular :indicator-dots="false" :autoplay="true"
+						:interval="850" :duration="800" :vertical="true" :circular='true' :display-multiple-items="2">
+						<swiper-item v-for="(item,i) in tenList" :key="i">
+							<view class="item-box-two">
+								<view class="user-box w-30">
+									<image class="user-img" :src="item.head_img" mode=""></image>
+									<view class="">
+										<view class="fs-32 fc-f w-90 text-overflow-ellipsis-one">
+											{{item.nickname}}
+										</view>
+									</view>
+								</view>
+								<view class="w-30">
+									<view class="fs-32 fc-f w-90 text-overflow-ellipsis-one">
+										{{item.city_name}}
+									</view>
+								</view>
+								<view class="w-20">
+									<view class="fs-32 fc-f">
+										¥{{item.total_income}}
+									</view>
+									<view class="fs-28 fc-B2D6FF">
+										累计收益
+									</view>
+								</view>
+							</view>
+							<view class="hr"></view>
+						</swiper-item>
+					</swiper>
 				</view>
+				
 			</view>
 		</view>
 	</view>
@@ -260,7 +301,7 @@
 		chartTotal,
 		chartList,
 		chartSummary,
-		chartNewList
+		chartNewList,distributorIncomeList
 	} from '@/api/chart.js';
 	export default {
 		components: {
@@ -282,7 +323,10 @@
 				page: 1,
 				total: 0,
 				newListData: [],
-				orderId: ''
+				orderId: '',
+				
+				
+				tenList:[],
 			}
 		},
 		onReady() {
@@ -309,8 +353,18 @@
 			this.chartTotal()
 			this.chartList()
 			// this.chartSummary()
+			
+			this.getDistributorIncomeList();
 		},
 		methods: {
+			getDistributorIncomeList(){
+				distributorIncomeList().then((res)=>{
+					if(res.code == 1){
+						this.tenList = res.data
+					}
+				})
+			},
+			
 			setTotalMoney(money) {
 				let m = ((money * 1 + 100000) / 10000).toFixed(2);
 				return m

BIN
static/tenlist.png