/**
  * Fetch customer balance
  *
  * @param \Magento\Quote\Model\Quote\Address $address
  * @return $this
  */
 public function fetchTotals(\Magento\Quote\Model\Quote\Address $address)
 {
     $custbalance = $address->getCustbalanceAmount();
     if ($custbalance != 0) {
         $address->addTotal(['code' => 'custbalance', 'title' => __('Store Credit'), 'value' => -$custbalance]);
     }
     return $this;
 }
 /**
  * @param \Magento\Quote\Model\Quote\Address $address
  * @return $this
  */
 public function collect(\Magento\Quote\Model\Quote\Address $address)
 {
     $address->setCustbalanceAmount(0);
     $address->setBaseCustbalanceAmount(0);
     $address->setGrandTotal($address->getGrandTotal() - $address->getCustbalanceAmount());
     $address->setBaseGrandTotal($address->getBaseGrandTotal() - $address->getBaseCustbalanceAmount());
     return $this;
 }