zhengkaixin 2 年之前
父节点
当前提交
6ed03b1643
共有 2 个文件被更改,包括 30 次插入3 次删除
  1. 14 1
      pagesFinance/detailed/index.vue
  2. 16 2
      pagesFinance/share/index.vue

+ 14 - 1
pagesFinance/detailed/index.vue

@@ -480,8 +480,21 @@
 			getStation(bl) {
 				
 				API.stationList().then((res) => {
+					var list= res.data.stationList
+					
+					var list2=list.sort(function(item1,item2){
+						
+						if(item1.stationNo.indexOf("D")==0){
+							return 1
+						}
+						return (item1.stationNo>item2.stationNo)?1:-1
+					})
+					for(var i in list2){
+						console.log(list2[i].stationNo)
+					}
+					
+					this.stationList =list2
 					
-					this.stationList = res.data.stationList
 					this.stationListSon=res.data.deviceList	
 				}).catch(error => {
 					uni.showToast({

+ 16 - 2
pagesFinance/share/index.vue

@@ -463,8 +463,22 @@
 
 				API.stationList().then((res) => {
 
-					this.stationList = res.data.stationList
-					this.stationListSon = res.data.deviceList
+					var list= res.data.stationList
+					
+					var list2=list.sort(function(item1,item2){
+						
+						if(item1.stationNo.indexOf("D")==0){
+							return 1
+						}
+						return (item1.stationNo>item2.stationNo)?1:-1
+					})
+					for(var i in list2){
+						console.log(list2[i].stationNo)
+					}
+					
+					this.stationList =list2
+					
+					this.stationListSon=res.data.deviceList	
 				}).catch(error => {
 					uni.showToast({