mirror of
https://github.com/Karaka-Management/oms-SupplierManagement.git
synced 2026-01-10 17:08:41 +00:00
crash backup
This commit is contained in:
parent
c67fc68693
commit
81d12f8b6a
|
|
@ -235,19 +235,6 @@
|
|||
"default_value": "",
|
||||
"values": []
|
||||
},
|
||||
{
|
||||
"name": "tax_id",
|
||||
"l11n": {
|
||||
"en": "Tax Id",
|
||||
"de": "Steuernummer"
|
||||
},
|
||||
"value_type": 2,
|
||||
"is_custom_allowed": true,
|
||||
"validation_pattern": "",
|
||||
"is_required": false,
|
||||
"default_value": "",
|
||||
"values": []
|
||||
},
|
||||
{
|
||||
"name": "legal_form",
|
||||
"l11n": {
|
||||
|
|
@ -346,6 +333,19 @@
|
|||
"default_value": "",
|
||||
"values": []
|
||||
},
|
||||
{
|
||||
"name": "bill_approval",
|
||||
"l11n": {
|
||||
"en": "Approval group",
|
||||
"de": "Freigabegruppe"
|
||||
},
|
||||
"value_type": 2,
|
||||
"is_custom_allowed": true,
|
||||
"validation_pattern": "",
|
||||
"is_required": false,
|
||||
"default_value": "",
|
||||
"values": []
|
||||
},
|
||||
{
|
||||
"name": "bill_match_pattern",
|
||||
"l11n": {
|
||||
|
|
|
|||
|
|
@ -243,7 +243,7 @@ final class ApiAttributeController extends Controller
|
|||
->with('type')
|
||||
->with('type/defaults')
|
||||
->with('value')
|
||||
->where('id', (int) $request->getData('id'))
|
||||
->where('id', $request->getDataInt('id') ?? 0)
|
||||
->execute();
|
||||
|
||||
$new = $this->updateAttributeFromRequest($request, clone $old);
|
||||
|
|
@ -291,7 +291,7 @@ final class ApiAttributeController extends Controller
|
|||
|
||||
$supplierAttribute = SupplierAttributeMapper::get()
|
||||
->with('type')
|
||||
->where('id', (int) $request->getData('id'))
|
||||
->where('id', $request->getDataInt('id') ?? 0)
|
||||
->execute();
|
||||
|
||||
if ($supplierAttribute->type->isRequired) {
|
||||
|
|
@ -327,7 +327,7 @@ final class ApiAttributeController extends Controller
|
|||
}
|
||||
|
||||
/** @var BaseStringL11n $old */
|
||||
$old = SupplierAttributeTypeL11nMapper::get()->where('id', (int) $request->getData('id'))->execute();
|
||||
$old = SupplierAttributeTypeL11nMapper::get()->where('id', $request->getDataInt('id') ?? 0)->execute();
|
||||
$new = $this->updateAttributeTypeL11nFromRequest($request, clone $old);
|
||||
|
||||
$this->updateModel($request->header->account, $old, $new, SupplierAttributeTypeL11nMapper::class, 'supplier_attribute_type_l11n', $request->getOrigin());
|
||||
|
|
@ -357,7 +357,7 @@ final class ApiAttributeController extends Controller
|
|||
}
|
||||
|
||||
/** @var BaseStringL11n $supplierAttributeTypeL11n */
|
||||
$supplierAttributeTypeL11n = SupplierAttributeTypeL11nMapper::get()->where('id', (int) $request->getData('id'))->execute();
|
||||
$supplierAttributeTypeL11n = SupplierAttributeTypeL11nMapper::get()->where('id', $request->getDataInt('id') ?? 0)->execute();
|
||||
$this->deleteModel($request->header->account, $supplierAttributeTypeL11n, SupplierAttributeTypeL11nMapper::class, 'supplier_attribute_type_l11n', $request->getOrigin());
|
||||
$this->createStandardDeleteResponse($request, $response, $supplierAttributeTypeL11n);
|
||||
}
|
||||
|
|
@ -385,7 +385,7 @@ final class ApiAttributeController extends Controller
|
|||
}
|
||||
|
||||
/** @var AttributeType $old */
|
||||
$old = SupplierAttributeTypeMapper::get()->with('defaults')->where('id', (int) $request->getData('id'))->execute();
|
||||
$old = SupplierAttributeTypeMapper::get()->with('defaults')->where('id', $request->getDataInt('id') ?? 0)->execute();
|
||||
$new = $this->updateAttributeTypeFromRequest($request, clone $old);
|
||||
|
||||
$this->updateModel($request->header->account, $old, $new, SupplierAttributeTypeMapper::class, 'supplier_attribute_type', $request->getOrigin());
|
||||
|
|
@ -417,7 +417,7 @@ final class ApiAttributeController extends Controller
|
|||
}
|
||||
|
||||
/** @var AttributeType $supplierAttributeType */
|
||||
$supplierAttributeType = SupplierAttributeTypeMapper::get()->with('defaults')->where('id', (int) $request->getData('id'))->execute();
|
||||
$supplierAttributeType = SupplierAttributeTypeMapper::get()->with('defaults')->where('id', $request->getDataInt('id') ?? 0)->execute();
|
||||
$this->deleteModel($request->header->account, $supplierAttributeType, SupplierAttributeTypeMapper::class, 'supplier_attribute_type', $request->getOrigin());
|
||||
$this->createStandardDeleteResponse($request, $response, $supplierAttributeType);
|
||||
}
|
||||
|
|
@ -445,7 +445,7 @@ final class ApiAttributeController extends Controller
|
|||
}
|
||||
|
||||
/** @var AttributeValue $old */
|
||||
$old = SupplierAttributeValueMapper::get()->where('id', (int) $request->getData('id'))->execute();
|
||||
$old = SupplierAttributeValueMapper::get()->where('id', $request->getDataInt('id') ?? 0)->execute();
|
||||
|
||||
/** @var \Modules\Attribute\Models\Attribute $attr */
|
||||
$attr = SupplierAttributeMapper::get()
|
||||
|
|
@ -485,7 +485,7 @@ final class ApiAttributeController extends Controller
|
|||
// }
|
||||
|
||||
// /** @var \Modules\SupplierManagement\Models\SupplierAttributeValue $supplierAttributeValue */
|
||||
// $supplierAttributeValue = SupplierAttributeValueMapper::get()->where('id', (int) $request->getData('id'))->execute();
|
||||
// $supplierAttributeValue = SupplierAttributeValueMapper::get()->where('id', $request->getDataInt('id') ?? 0)->execute();
|
||||
// $this->deleteModel($request->header->account, $supplierAttributeValue, SupplierAttributeValueMapper::class, 'supplier_attribute_value', $request->getOrigin());
|
||||
// $this->createStandardDeleteResponse($request, $response, $supplierAttributeValue);
|
||||
}
|
||||
|
|
@ -513,7 +513,7 @@ final class ApiAttributeController extends Controller
|
|||
}
|
||||
|
||||
/** @var BaseStringL11n $old */
|
||||
$old = SupplierAttributeValueL11nMapper::get()->where('id', (int) $request->getData('id'));
|
||||
$old = SupplierAttributeValueL11nMapper::get()->where('id', $request->getDataInt('id') ?? 0);
|
||||
$new = $this->updateAttributeValueL11nFromRequest($request, clone $old);
|
||||
|
||||
$this->updateModel($request->header->account, $old, $new, SupplierAttributeValueL11nMapper::class, 'supplier_attribute_value_l11n', $request->getOrigin());
|
||||
|
|
@ -543,7 +543,7 @@ final class ApiAttributeController extends Controller
|
|||
}
|
||||
|
||||
/** @var BaseStringL11n $supplierAttributeValueL11n */
|
||||
$supplierAttributeValueL11n = SupplierAttributeValueL11nMapper::get()->where('id', (int) $request->getData('id'))->execute();
|
||||
$supplierAttributeValueL11n = SupplierAttributeValueL11nMapper::get()->where('id', $request->getDataInt('id') ?? 0)->execute();
|
||||
$this->deleteModel($request->header->account, $supplierAttributeValueL11n, SupplierAttributeValueL11nMapper::class, 'supplier_attribute_value_l11n', $request->getOrigin());
|
||||
$this->createStandardDeleteResponse($request, $response, $supplierAttributeValueL11n);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ final class BackendController extends Controller
|
|||
->with('l11n')
|
||||
->with('defaults')
|
||||
->with('defaults/l11n')
|
||||
->where('id', (int) $request->getData('id'))
|
||||
->where('id', $request->getDataInt('id') ?? 0)
|
||||
->where('l11n/language', $response->header->l11n->language)
|
||||
->where('defaults/l11n/language', [$response->header->l11n->language, null])
|
||||
->execute();
|
||||
|
|
@ -156,7 +156,7 @@ final class BackendController extends Controller
|
|||
|
||||
$view->attribute = SupplierAttributeValueMapper::get()
|
||||
->with('l11n')
|
||||
->where('id', (int) $request->getData('id'))
|
||||
->where('id', $request->getDataInt('id') ?? 0)
|
||||
->where('l11n/language', [$response->header->l11n->language, null])
|
||||
->execute();
|
||||
|
||||
|
|
|
|||
|
|
@ -49,6 +49,7 @@ Suppliers can be put in categories for horizontal and vertical grouping. By defa
|
|||
| Attribute | Description | Internal default value |
|
||||
| --------- | ----------- | ---------------------- |
|
||||
| minimum_order | Minimum order amount required | |
|
||||
| bill_approval | Default group that can approve the bill | |
|
||||
|
||||
### Accounting
|
||||
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@ $languages = ISO639Enum::getConstants();
|
|||
$supplier = $this->data['supplier'] ?? new NullSupplier();
|
||||
$isNew = $supplier->id === 0;
|
||||
|
||||
$supplierImage = $this->getData('supplierImage') ?? new NullMedia();
|
||||
$supplierImage = $this->data['supplierImage'] ?? new NullMedia();
|
||||
|
||||
$supplierStatus = SupplierStatus::getConstants();
|
||||
|
||||
|
|
@ -246,7 +246,7 @@ echo $this->data['nav']->render();
|
|||
|
||||
<section class="portlet hl-4">
|
||||
<div class="portlet-body">
|
||||
<textarea class="undecorated"><?= $this->printTextarea($supplier->info); ?></textarea>
|
||||
<textarea class="undecorated" aria-label="Info"><?= $this->printTextarea($supplier->info); ?></textarea>
|
||||
</div>
|
||||
</section>
|
||||
<?php endif; ?>
|
||||
|
|
@ -682,7 +682,7 @@ echo $this->data['nav']->render();
|
|||
<div class="portlet-body">
|
||||
<input id="iPriceId" class="vh" name="id" type="number" data-tpl-text="/id" data-tpl-value="/id">
|
||||
<input id="iPriceSupplierId" class="vh" name="supplier" type="text" value="<?= $supplier->id; ?>">
|
||||
<input id="iPriceItemType" class="vh" name="type" type="text" value="<?= PriceType::PURCHASE; ?>">
|
||||
<input id="iPriceType" class="vh" name="type" type="text" value="<?= PriceType::PURCHASE; ?>">
|
||||
|
||||
<div class="form-group">
|
||||
<label for="iPriceName"><?= $this->getHtml('Name'); ?></label>
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user