Revision 377e8efa
Von Johannes Grassler vor mehr als 1 Jahr hinzugefügt
SL/Controller/ZUGFeRD.pm | ||
---|---|---|
163 | 163 |
|
164 | 164 |
$vendor = find_vendor($metadata{'ustid'}, $metadata{'taxnumber'}); |
165 | 165 |
|
166 |
die t8("Please add a valid VAT ID or tax number for this vendor: #1", $metadata{'vendor_name'}) unless $vendor; |
|
166 |
die t8("Vendor with VAT ID (#1) and/or tax ID (#2) not found. Please check if the vendor " . |
|
167 |
"#3 exists and whether it has the correct tax ID/VAT ID." , |
|
168 |
$metadata{'ustid'}, |
|
169 |
$metadata{'taxnumber'}, |
|
170 |
$metadata{'vendor_name'}, |
|
171 |
) unless $vendor; |
|
167 | 172 |
|
168 | 173 |
|
169 | 174 |
# Create a record template for this imported invoice |
... | ... | |
207 | 212 |
); |
208 | 213 |
|
209 | 214 |
$template_ap->assign_attributes( |
210 |
template_name => "Faktur-X/ZUGFeRD/XRechnung Import $vendor->name, $invnumber",
|
|
215 |
template_name => t8("Faktur-X/ZUGFeRD/XRechnung import #1, #2", $vendor->name, $invnumber),
|
|
211 | 216 |
template_type => 'ap_transaction', |
212 | 217 |
direct_debit => $metadata{'direct_debit'}, |
213 | 218 |
notes => "Faktur-X/ZUGFeRD/XRechnung Import. Type: $metadata{'type'}\nIBAN: " . $ibanmessage, |
... | ... | |
239 | 244 |
# be sufficient for that to happen), grab the first tax fitting the default |
240 | 245 |
# category, just like the AP form would do it for manual entry. |
241 | 246 |
if ( scalar @{$taxes} == 0 ) { |
242 |
$taxes = SL::D::ManagerTax->get_all(
|
|
247 |
$taxes = SL::DB::Manager::Tax->get_all(
|
|
243 | 248 |
where => [ chart_categories => { like => '%' . $default_ap_amount_chart->category . '%' } ], |
244 | 249 |
); |
245 | 250 |
} |
Auch abrufbar als: Unified diff
ZUGFeRD-Import: verschiedene behoben