mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2026-03-01 04:49:36 +00:00
Remove unused counter variable in BatchEdaController
This commit is contained in:
parent
f314578790
commit
e05a751b84
1 changed files with 0 additions and 10 deletions
|
|
@ -40,43 +40,33 @@ class BatchEdaController extends AbstractController
|
|||
$form->handleRequest($request);
|
||||
|
||||
if ($form->isSubmitted() && $form->isValid()) {
|
||||
$updated = 0;
|
||||
|
||||
foreach ($parts as $part) {
|
||||
$this->denyAccessUnlessGranted('edit', $part);
|
||||
$edaInfo = $part->getEdaInfo();
|
||||
|
||||
if ($form->get('apply_reference_prefix')->getData()) {
|
||||
$edaInfo->setReferencePrefix($form->get('reference_prefix')->getData() ?: null);
|
||||
$updated++;
|
||||
}
|
||||
if ($form->get('apply_value')->getData()) {
|
||||
$edaInfo->setValue($form->get('value')->getData() ?: null);
|
||||
$updated++;
|
||||
}
|
||||
if ($form->get('apply_kicad_symbol')->getData()) {
|
||||
$edaInfo->setKicadSymbol($form->get('kicad_symbol')->getData() ?: null);
|
||||
$updated++;
|
||||
}
|
||||
if ($form->get('apply_kicad_footprint')->getData()) {
|
||||
$edaInfo->setKicadFootprint($form->get('kicad_footprint')->getData() ?: null);
|
||||
$updated++;
|
||||
}
|
||||
if ($form->get('apply_visibility')->getData()) {
|
||||
$edaInfo->setVisibility($form->get('visibility')->getData());
|
||||
$updated++;
|
||||
}
|
||||
if ($form->get('apply_exclude_from_bom')->getData()) {
|
||||
$edaInfo->setExcludeFromBom($form->get('exclude_from_bom')->getData());
|
||||
$updated++;
|
||||
}
|
||||
if ($form->get('apply_exclude_from_board')->getData()) {
|
||||
$edaInfo->setExcludeFromBoard($form->get('exclude_from_board')->getData());
|
||||
$updated++;
|
||||
}
|
||||
if ($form->get('apply_exclude_from_sim')->getData()) {
|
||||
$edaInfo->setExcludeFromSim($form->get('exclude_from_sim')->getData());
|
||||
$updated++;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue