|  | @@ -282,9 +282,9 @@ $(document).ready(() => {
 | 
	
		
			
				|  |  |                  for (const level2 of level2List) {
 | 
	
		
			
				|  |  |                      jianAnHtml += `<tr>
 | 
	
		
			
				|  |  |                                              <td class="text-left pl-3">${level2.name}</td>
 | 
	
		
			
				|  |  | -                                            <td>${level2.gai_tp ? level2.gai_tp/10000 : 0}</td>
 | 
	
		
			
				|  |  | -                                            <td>${level2.final_tp ? level2.final_tp/10000 : 0}</td>
 | 
	
		
			
				|  |  | -                                            <td class="${ZhCalc.sub(level2.final_tp, level2.gai_tp) > 0 ? 'text-danger' : ZhCalc.sub(level2.final_tp, level2.gai_tp) === 0 ? '' : 'text-success'}">${ZhCalc.sub(level2.final_tp, level2.gai_tp)/10000}</td>
 | 
	
		
			
				|  |  | +                                            <td>${level2.gai_tp ? ZhCalc.div(level2.gai_tp, 10000) : 0}</td>
 | 
	
		
			
				|  |  | +                                            <td>${level2.final_tp ? ZhCalc.div(level2.final_tp, 10000) : 0}</td>
 | 
	
		
			
				|  |  | +                                            <td class="${ZhCalc.sub(level2.final_tp, level2.gai_tp) > 0 ? 'text-danger' : ZhCalc.sub(level2.final_tp, level2.gai_tp) === 0 ? '' : 'text-success'}">${ZhCalc.div(ZhCalc.sub(level2.final_tp, level2.gai_tp), 10000)}</td>
 | 
	
		
			
				|  |  |                                          </tr>`;
 | 
	
		
			
				|  |  |                  }
 | 
	
		
			
				|  |  |                  $('#jianan-table').html(jianAnHtml);
 | 
	
	
		
			
				|  | @@ -306,9 +306,9 @@ $(document).ready(() => {
 | 
	
		
			
				|  |  |                      total_gu_tp = ZhCalc.sub(ZhCalc.sum(_.map(level1List, 'gu_tp')), huishouInfo.gu_tp);
 | 
	
		
			
				|  |  |                      total_yu_tp = ZhCalc.sub(ZhCalc.sum(_.map(level1List, 'yu_tp')), huishouInfo.yu_tp);
 | 
	
		
			
				|  |  |                      total_price = ZhCalc.sub(ZhCalc.sum(_.map(level1List, 'total_price')), huishouInfo.total_price);
 | 
	
		
			
				|  |  | -                    total_rate = ZhCalc.round(ZhCalc.div(ZhCalc.sub(total_final_tp, total_gai_tp), total_gai_tp), 2);
 | 
	
		
			
				|  |  | -                    $('#total_gai_tp').text(total_gai_tp ? total_gai_tp/10000 : 0);
 | 
	
		
			
				|  |  | -                    $('#total_final_tp').text(total_final_tp ? total_final_tp/10000 : 0);
 | 
	
		
			
				|  |  | +                    total_rate = ZhCalc.div(ZhCalc.sub(total_final_tp, total_gai_tp), total_gai_tp);
 | 
	
		
			
				|  |  | +                    $('#total_gai_tp').text(total_gai_tp ? ZhCalc.div(total_gai_tp, 10000) : 0);
 | 
	
		
			
				|  |  | +                    $('#total_final_tp').text(total_final_tp ? ZhCalc.div(total_final_tp, 10000) : 0);
 | 
	
		
			
				|  |  |                      // level1List.push(huishouInfo);
 | 
	
		
			
				|  |  |                  } else {
 | 
	
		
			
				|  |  |                      total_gai_tp = ZhCalc.sum(_.map(level1List, 'gai_tp'));
 | 
	
	
		
			
				|  | @@ -316,12 +316,12 @@ $(document).ready(() => {
 | 
	
		
			
				|  |  |                      total_gu_tp = ZhCalc.sum(_.map(level1List, 'gu_tp'));
 | 
	
		
			
				|  |  |                      total_yu_tp = ZhCalc.sum(_.map(level1List, 'yu_tp'));
 | 
	
		
			
				|  |  |                      total_price = ZhCalc.sum(_.map(level1List, 'total_price'));
 | 
	
		
			
				|  |  | -                    total_rate = ZhCalc.round(ZhCalc.div(ZhCalc.sub(total_final_tp, total_gai_tp), total_gai_tp), 2);
 | 
	
		
			
				|  |  | -                    $('#total_gai_tp').text(total_gai_tp ? total_gai_tp/10000 : 0);
 | 
	
		
			
				|  |  | -                    $('#total_final_tp').text(total_final_tp ? total_final_tp/10000 : 0);
 | 
	
		
			
				|  |  | +                    total_rate = ZhCalc.div(ZhCalc.sub(total_final_tp, total_gai_tp), total_gai_tp);
 | 
	
		
			
				|  |  | +                    $('#total_gai_tp').text(total_gai_tp ? ZhCalc.div(total_gai_tp, 10000) : 0);
 | 
	
		
			
				|  |  | +                    $('#total_final_tp').text(total_final_tp ? ZhCalc.div(total_final_tp, 10000) : 0);
 | 
	
		
			
				|  |  |                  }
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  | -            $('#total_rate').text((total_rate ? total_rate : 0) + '%');
 | 
	
		
			
				|  |  | +            $('#total_rate').text((total_rate ? ZhCalc.round(ZhCalc.mul(total_rate,100), 2) : 0) + '%');
 | 
	
		
			
				|  |  |              if (total_rate > 0) {
 | 
	
		
			
				|  |  |                  $('#total_rate').parents('.canyu-band').removeClass('text-success').addClass('text-danger');
 | 
	
		
			
				|  |  |              } else if (total_rate < 0) {
 | 
	
	
		
			
				|  | @@ -331,12 +331,12 @@ $(document).ready(() => {
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  |              console.log(level1List);
 | 
	
		
			
				|  |  |              option.series[0].data = [
 | 
	
		
			
				|  |  | -                total_gu_tp/10000,
 | 
	
		
			
				|  |  | -                total_gai_tp/10000,
 | 
	
		
			
				|  |  | -                total_yu_tp/10000,
 | 
	
		
			
				|  |  | -                total_price/10000,
 | 
	
		
			
				|  |  | -                ZhCalc.add(total_change_tp, total_price)/10000,
 | 
	
		
			
				|  |  | -                total_final_tp/10000,
 | 
	
		
			
				|  |  | +                ZhCalc.div(total_gu_tp, 10000),
 | 
	
		
			
				|  |  | +                ZhCalc.div(total_gai_tp, 10000),
 | 
	
		
			
				|  |  | +                ZhCalc.div(total_yu_tp, 10000),
 | 
	
		
			
				|  |  | +                ZhCalc.div(total_price, 10000),
 | 
	
		
			
				|  |  | +                ZhCalc.div(ZhCalc.add(total_change_tp, total_price), 10000),
 | 
	
		
			
				|  |  | +                ZhCalc.div(total_final_tp, 10000),
 | 
	
		
			
				|  |  |              ];
 | 
	
		
			
				|  |  |              if (huishouInfo) level1List.push(huishouInfo);
 | 
	
		
			
				|  |  |              option2.legend.data = _.map(level1List, 'name');
 | 
	
	
		
			
				|  | @@ -345,7 +345,10 @@ $(document).ready(() => {
 | 
	
		
			
				|  |  |                      name: level1.name,
 | 
	
		
			
				|  |  |                      type: 'line',
 | 
	
		
			
				|  |  |                      stack: 'Total',
 | 
	
		
			
				|  |  | -                    data: [level1.gu_tp/10000, level1.gai_tp/10000, level1.yu_tp/10000, level1.total_price/10000, level1.final_tp/10000]
 | 
	
		
			
				|  |  | +                    data: [ZhCalc.div(level1.gu_tp, 10000), ZhCalc.div(level1.gai_tp, 10000),
 | 
	
		
			
				|  |  | +                        ZhCalc.div(level1.yu_tp, 10000), ZhCalc.div(level1.total_price, 10000),
 | 
	
		
			
				|  |  | +                        ZhCalc.div(level1.final_tp, 10000)
 | 
	
		
			
				|  |  | +                    ]
 | 
	
		
			
				|  |  |                  });
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  |          }
 |