Просмотр исходного кода

零售和供货商的收支记录

jf 5 лет назад
Родитель
Сommit
0cef9ae455

+ 1 - 1
ghsApp/src/mixins/list.js

@@ -42,7 +42,7 @@ export default {
         this.list.finished = true
       }
       let listArr = res.data.list || res.data.data || res.data[listKey]
-      console.log(listArr,111)
+      // console.log(listArr,111)
       this.list.data =
         this.list.page === 1 ? listArr : this.list.data.concat(listArr)
       this.list.total = res.data.totalPage * this.list.pageSize

+ 11 - 32
ghsApp/src/pagesStore/me/incomeExpenses.vue

@@ -1,13 +1,6 @@
 <template>
 	<div>
-		<app-tabs
-		:tabs="tabs"
-		:isFixed="true"
-		:currentTab="tabIndex"
-		:height="100"
-		@change="changeIncome"
-		itemWidth="50%"
-		/>
+		<app-tabs :tabs="tabs" :isFixed="true" :currentTab="tabIndex" :height="100" @change="changeIncome" itemWidth="50%"/>
 		<div class="list-by_box" v-if="!$util.isEmpty(list.data)">
 			<t-table :headerBackgroundColor="'#F0F2F6'">
 				<t-tr header>
@@ -51,30 +44,10 @@ export default {
 	data() {
 		return {
 			columns: [
-				{
-					name: "事项",
-					dataIndex: "event",
-					color: "info",
-					align: "center"
-				},
-				{
-					name: "金额",
-					dataIndex: "amount",
-					color: "info",
-					align: "center"
-				},
-				{
-					name: "累计",
-					dataIndex: "totalIncome",
-					color: "info",
-					align: "center"
-				},
-				{
-					name: "时间",
-					dataIndex: "addTime",
-					color: "info",
-					align: "center"
-				}
+				{name: "事项",dataIndex: "event",color: "info",align: "center"},
+				{name: "金额",dataIndex: "amount",color: "info",align: "center"},
+				{name: "累计",dataIndex: "totalIncome",color: "info",align: "center"},
+				{name: "时间",dataIndex: "addTime",color: "info",align: "center"}
 			],
 			tabIndex: 0,
 			tabs: [
@@ -98,6 +71,12 @@ export default {
 				return false;
 			} else {
 				this.tabIndex = e.index;
+					this.columns = [
+						{name: "事项",dataIndex: "event",color: "info",align: "center"},
+						{name: "金额",dataIndex: "amount",color: "info",align: "center"},
+						{name: "累计",dataIndex: this.tabIndex==0?"totalIncome":"totalExpend",color: "info",align: "center"},
+						{name: "时间",dataIndex: "addTime",color: "info",align: "center"}
+					]
 				this.resetList();
 				this._list();
 			}

+ 7 - 8
hdApp/src/pagesStore/me/incomeExpenses.vue

@@ -1,13 +1,6 @@
 <template>
 	<div>
-		<app-tabs
-		:tabs="tabs"
-		:isFixed="true"
-		:currentTab="tabIndex"
-		:height="100"
-		@change="changeIncome"
-		itemWidth="50%"
-		/>
+		<app-tabs :tabs="tabs" :isFixed="true" :currentTab="tabIndex" :height="100" @change="changeIncome" itemWidth="50%"/>
 		<div class="list-by_box" v-if="!$util.isEmpty(list.data)">
 			<t-table :headerBackgroundColor="'#F0F2F6'">
 				<t-tr header>
@@ -98,6 +91,12 @@ export default {
 				return false;
 			} else {
 				this.tabIndex = e.index;
+					this.columns = [
+						{name: "事项",dataIndex: "event",color: "info",align: "center"},
+						{name: "金额",dataIndex: "amount",color: "info",align: "center"},
+						{name: "累计",dataIndex: this.tabIndex==0?"totalIncome":"totalExpend",color: "info",align: "center"},
+						{name: "时间",dataIndex: "addTime",color: "info",align: "center"}
+					]
 				this.resetList();
 				this._list();
 			}