|
@@ -2698,22 +2698,22 @@ export default {
|
|
)
|
|
)
|
|
.then(res => {
|
|
.then(res => {
|
|
this.tableData = res.data.data
|
|
this.tableData = res.data.data
|
|
|
|
+ //遍历保留两位小数
|
|
|
|
+ this.tableData.forEach(e=>{
|
|
|
|
+ try {
|
|
|
|
+ if(e.priceValue){
|
|
|
|
+ e.priceValue=e.priceValue.toFixed(2);
|
|
|
|
+ }
|
|
|
|
+ if(e.detailsAmount){
|
|
|
|
+ e.detailsAmount=e.detailsAmount.toFixed(2);
|
|
|
|
+ }
|
|
|
|
+ } catch (error) {
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ })
|
|
this.totalHeight += this.itemHeight
|
|
this.totalHeight += this.itemHeight
|
|
this.visibleList = res.data.data
|
|
this.visibleList = res.data.data
|
|
console.log(this.visibleList);
|
|
console.log(this.visibleList);
|
|
- try {
|
|
|
|
- //遍历保留两位小数
|
|
|
|
- this.visibleList.forEach(e=>{
|
|
|
|
- if(e.priceValue){
|
|
|
|
- e.priceValue=e.priceValue.toFixed(2);
|
|
|
|
- }
|
|
|
|
- if(e.detailsAmount){
|
|
|
|
- e.detailsAmount=e.detailsAmount.toFixed(2);
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- } catch (error) {
|
|
|
|
-
|
|
|
|
- }
|
|
|
|
console.log(this.visibleList, 'this.visibleList')
|
|
console.log(this.visibleList, 'this.visibleList')
|
|
this.getSpanArr(this.visibleList)
|
|
this.getSpanArr(this.visibleList)
|
|
this.getTotalNum(this.tableData)
|
|
this.getTotalNum(this.tableData)
|
|
@@ -2744,22 +2744,22 @@ export default {
|
|
obj
|
|
obj
|
|
)
|
|
)
|
|
.then(res => {
|
|
.then(res => {
|
|
- this.tableData = res.data.data
|
|
|
|
|
|
+ this.tableData1 = res.data.data
|
|
|
|
+ //遍历保留两位小数
|
|
|
|
+ this.tableData1.forEach(e=>{
|
|
|
|
+ try {
|
|
|
|
+ if(e.priceValue){
|
|
|
|
+ e.priceValue=e.priceValue.toFixed(2);
|
|
|
|
+ }
|
|
|
|
+ if(e.detailsAmount){
|
|
|
|
+ e.detailsAmount=e.detailsAmount.toFixed(2);
|
|
|
|
+ }
|
|
|
|
+ } catch (error) {
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ })
|
|
this.totalHeight += this.itemHeight
|
|
this.totalHeight += this.itemHeight
|
|
this.visibleList1 = res.data.data
|
|
this.visibleList1 = res.data.data
|
|
- try {
|
|
|
|
- //遍历保留两位小数
|
|
|
|
- this.visibleList1.forEach(e=>{
|
|
|
|
- if(e.priceValue){
|
|
|
|
- e.priceValue=e.priceValue.toFixed(2);
|
|
|
|
- }
|
|
|
|
- if(e.detailsAmount){
|
|
|
|
- e.detailsAmount=e.detailsAmount.toFixed(2);
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- } catch (error) {
|
|
|
|
-
|
|
|
|
- }
|
|
|
|
console.log(this.visibleList1, 'this.visibleList1')
|
|
console.log(this.visibleList1, 'this.visibleList1')
|
|
this.getSpanArr1(this.visibleList1)
|
|
this.getSpanArr1(this.visibleList1)
|
|
this.getTotalNum(this.tableData)
|
|
this.getTotalNum(this.tableData)
|
|
@@ -2851,25 +2851,25 @@ export default {
|
|
)
|
|
)
|
|
.then(res => {
|
|
.then(res => {
|
|
this.tableData = res.data.data
|
|
this.tableData = res.data.data
|
|
|
|
+ //遍历保留两位小数
|
|
|
|
+ this.tableData.forEach(e=>{
|
|
|
|
+ try {
|
|
|
|
+ if(e.priceValue){
|
|
|
|
+ e.priceValue=e.priceValue.toFixed(2);
|
|
|
|
+ }
|
|
|
|
+ if(e.detailsAmount){
|
|
|
|
+ e.detailsAmount=e.detailsAmount.toFixed(2);
|
|
|
|
+ }
|
|
|
|
+ } catch (error) {
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ })
|
|
this.totalHeight += this.itemHeight
|
|
this.totalHeight += this.itemHeight
|
|
this.visibleList = []
|
|
this.visibleList = []
|
|
this.visibleList = this.tableData.slice(
|
|
this.visibleList = this.tableData.slice(
|
|
0,
|
|
0,
|
|
Math.floor(this.maxHeight / this.itemHeight) + 1
|
|
Math.floor(this.maxHeight / this.itemHeight) + 1
|
|
)
|
|
)
|
|
- try {
|
|
|
|
- //遍历保留两位小数
|
|
|
|
- this.visibleList.forEach(e=>{
|
|
|
|
- if(e.priceValue){
|
|
|
|
- e.priceValue=e.priceValue.toFixed(2);
|
|
|
|
- }
|
|
|
|
- if(e.detailsAmount){
|
|
|
|
- e.detailsAmount=e.detailsAmount.toFixed(2);
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- } catch (error) {
|
|
|
|
-
|
|
|
|
- }
|
|
|
|
console.log(this.visibleList)
|
|
console.log(this.visibleList)
|
|
this.getSpanArr(this.visibleList)
|
|
this.getSpanArr(this.visibleList)
|
|
this.getTotalNum(this.tableData)
|
|
this.getTotalNum(this.tableData)
|
|
@@ -2903,25 +2903,25 @@ export default {
|
|
)
|
|
)
|
|
.then(res => {
|
|
.then(res => {
|
|
this.tableData1 = res.data.data
|
|
this.tableData1 = res.data.data
|
|
|
|
+ //遍历保留两位小数
|
|
|
|
+ this.tableData1.forEach(e=>{
|
|
|
|
+ try {
|
|
|
|
+ if(e.priceValue){
|
|
|
|
+ e.priceValue=e.priceValue.toFixed(2);
|
|
|
|
+ }
|
|
|
|
+ if(e.detailsAmount){
|
|
|
|
+ e.detailsAmount=e.detailsAmount.toFixed(2);
|
|
|
|
+ }
|
|
|
|
+ } catch (error) {
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ })
|
|
this.totalHeight += this.itemHeight
|
|
this.totalHeight += this.itemHeight
|
|
this.visibleList1 = []
|
|
this.visibleList1 = []
|
|
this.visibleList1 = this.tableData1.slice(
|
|
this.visibleList1 = this.tableData1.slice(
|
|
0,
|
|
0,
|
|
Math.floor(this.maxHeight / this.itemHeight) + 1
|
|
Math.floor(this.maxHeight / this.itemHeight) + 1
|
|
)
|
|
)
|
|
- try {
|
|
|
|
- //遍历保留两位小数
|
|
|
|
- this.visibleList1.forEach(e=>{
|
|
|
|
- if(e.priceValue){
|
|
|
|
- e.priceValue=e.priceValue.toFixed(2);
|
|
|
|
- }
|
|
|
|
- if(e.detailsAmount){
|
|
|
|
- e.detailsAmount=e.detailsAmount.toFixed(2);
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- } catch (error) {
|
|
|
|
-
|
|
|
|
- }
|
|
|
|
console.log(this.visibleList1)
|
|
console.log(this.visibleList1)
|
|
this.getSpanArr1(this.visibleList1)
|
|
this.getSpanArr1(this.visibleList1)
|
|
this.getTotalNum(this.tableData1)
|
|
this.getTotalNum(this.tableData1)
|