perbaikan cost management
This commit is contained in:
		
							parent
							
								
									8cc1a2b9fb
								
							
						
					
					
						commit
						95fa99799c
					
				@ -92,7 +92,9 @@ export class CostManagementComponent implements OnInit {
 | 
				
			|||||||
      .subscribe((response) => {
 | 
					      .subscribe((response) => {
 | 
				
			||||||
        this.data = response.results.data;
 | 
					        this.data = response.results.data;
 | 
				
			||||||
        this.filteredRows = this.data;
 | 
					        this.filteredRows = this.data;
 | 
				
			||||||
        this.kwhTerm = response.results.kwh;
 | 
					        let kwhData = parseFloat(response.results.kwh)
 | 
				
			||||||
 | 
					        this.kwhTerm = kwhData.toFixed(1);
 | 
				
			||||||
 | 
					        
 | 
				
			||||||
        this.costTerm = response.results.cost;
 | 
					        this.costTerm = response.results.cost;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        this.data_cost = this.filteredRows.map((item) => ({
 | 
					        this.data_cost = this.filteredRows.map((item) => ({
 | 
				
			||||||
@ -100,7 +102,7 @@ export class CostManagementComponent implements OnInit {
 | 
				
			|||||||
          roomName: item.room_name,
 | 
					          roomName: item.room_name,
 | 
				
			||||||
          categoryName: item.category_name,
 | 
					          categoryName: item.category_name,
 | 
				
			||||||
          estimationCost: item.estimation_cost,
 | 
					          estimationCost: item.estimation_cost,
 | 
				
			||||||
          totalUse: item.total_use,
 | 
					          totalUse: item.total_use.toFixed(1),
 | 
				
			||||||
          endDate: this.convertToUTC7(item.end_date),
 | 
					          endDate: this.convertToUTC7(item.end_date),
 | 
				
			||||||
          // endDate: item.end_date,
 | 
					          // endDate: item.end_date,
 | 
				
			||||||
          statusId: item.status_id,
 | 
					          statusId: item.status_id,
 | 
				
			||||||
 | 
				
			|||||||
@ -13,7 +13,7 @@
 | 
				
			|||||||
                  <div class="media-body text-left">
 | 
					                  <div class="media-body text-left">
 | 
				
			||||||
                    <h5 class="custom-label">Kwh Consumption</h5>
 | 
					                    <h5 class="custom-label">Kwh Consumption</h5>
 | 
				
			||||||
                    <h3 class="custom-value">
 | 
					                    <h3 class="custom-value">
 | 
				
			||||||
                      {{ topCard?.kwh_consumption ? topCard?.kwh_consumption.toFixed(3) : 0 }} Kwh
 | 
					                      {{ topCard?.kwh_consumption ? topCard?.kwh_consumption.toFixed(1) : 0 }} Kwh
 | 
				
			||||||
                    </h3>
 | 
					                    </h3>
 | 
				
			||||||
                  </div>
 | 
					                  </div>
 | 
				
			||||||
                  <div class="align-self-center">
 | 
					                  <div class="align-self-center">
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user