2017-09-05 17:31:58 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
include_once __DIR__.'/../../core.php';
|
|
|
|
|
2017-09-22 15:19:59 +02:00
|
|
|
$module = Modules::get($id_module);
|
2017-09-05 17:31:58 +02:00
|
|
|
|
2019-02-14 17:49:58 +01:00
|
|
|
$options = [
|
|
|
|
'op' => 'nota_credito',
|
|
|
|
'id_importazione' => 'id_documento',
|
|
|
|
'final_module' => $module['name'],
|
|
|
|
'original_module' => $module['name'],
|
|
|
|
'sql' => [
|
2018-07-03 17:28:02 +02:00
|
|
|
'table' => 'co_documenti',
|
|
|
|
'rows' => 'co_righe_documenti',
|
2019-02-14 17:49:58 +01:00
|
|
|
'id_rows' => 'iddocumento',
|
|
|
|
],
|
|
|
|
'serials' => [
|
|
|
|
'id_riga' => 'id_riga_documento',
|
2018-07-03 17:28:02 +02:00
|
|
|
'condition' => '(1 = 2)',
|
|
|
|
],
|
2019-02-14 17:49:58 +01:00
|
|
|
'button' => tr('Aggiungi'),
|
|
|
|
'dir' => $dir,
|
|
|
|
'create_document' => true,
|
|
|
|
'allow-empty' => true,
|
2017-09-05 17:31:58 +02:00
|
|
|
];
|
|
|
|
|
2019-02-14 17:49:58 +01:00
|
|
|
$result = [
|
|
|
|
'id_record' => $id_record,
|
|
|
|
'id_documento' => get('iddocumento'),
|
|
|
|
];
|
2018-07-03 17:28:02 +02:00
|
|
|
|
2019-02-14 17:49:58 +01:00
|
|
|
echo App::load('importa.php', $result, $options, true);
|