@@ 140-149 (lines=10) @@ | ||
137 | * @param SalesOrder $oOrder |
|
138 | * @return string |
|
139 | */ |
|
140 | public function getInvoiceAppendix(SalesOrder $oOrder) |
|
141 | { |
|
142 | $sText = $this->getConfigParam('invoice_appendix', 'invoicing'); // get invoice appendix from config |
|
143 | $aSubstitutionArray = [ |
|
144 | '{{order_increment_id}}' => $oOrder->getIncrementId(), |
|
145 | '{{customer_id}}' => $oOrder->getCustomerId(), |
|
146 | ]; |
|
147 | $sInvoiceAppendix = $this->handleSubstituteReplacement($sText, $aSubstitutionArray, 255); |
|
148 | return $sInvoiceAppendix; |
|
149 | } |
|
150 | ||
151 | /** |
|
152 | * Returns narrative text for authorization request |
|
@@ 158-166 (lines=9) @@ | ||
155 | * @param PayoneMethod $oPayment |
|
156 | * @return string |
|
157 | */ |
|
158 | public function getNarrativeText(SalesOrder $oOrder, PayoneMethod $oPayment) |
|
159 | { |
|
160 | $sText = $this->getConfigParam('narrative_text', $oPayment->getCode(), 'payone_payment'); // get narrative text for payment from config |
|
161 | $aSubstitutionArray = [ |
|
162 | '{{order_increment_id}}' => $oOrder->getIncrementId(), |
|
163 | ]; |
|
164 | $sNarrativeText = $this->handleSubstituteReplacement($sText, $aSubstitutionArray, $oPayment->getNarrativeTextMaxLength()); |
|
165 | return $sNarrativeText; |
|
166 | } |
|
167 | ||
168 | /** |
|
169 | * Format a price to the XX.YY format |