mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-07-10 18:34:32 +02:00
Removed unnecessary getIDString() function in AbstractDBElement.
This commit is contained in:
parent
a3af55d4e2
commit
8b6fe757a0
26 changed files with 3 additions and 219 deletions
|
@ -116,16 +116,6 @@ class Category extends AbstractPartsContainingDBElement
|
|||
*/
|
||||
protected $parameters;
|
||||
|
||||
/**
|
||||
* Returns the ID as an string, defined by the element class.
|
||||
* This should have a form like P000014, for a part with ID 14.
|
||||
*
|
||||
* @return string The ID as a string;
|
||||
*/
|
||||
public function getIDString(): string
|
||||
{
|
||||
return 'C'.sprintf('%09d', $this->getID());
|
||||
}
|
||||
|
||||
public function getPartnameHint(): string
|
||||
{
|
||||
|
|
|
@ -103,16 +103,6 @@ class Footprint extends AbstractPartsContainingDBElement
|
|||
*/
|
||||
protected $parameters;
|
||||
|
||||
/**
|
||||
* Returns the ID as an string, defined by the element class.
|
||||
* This should have a form like P000014, for a part with ID 14.
|
||||
*
|
||||
* @return string The ID as a string;
|
||||
*/
|
||||
public function getIDString(): string
|
||||
{
|
||||
return 'F'.sprintf('%06d', $this->getID());
|
||||
}
|
||||
|
||||
/****************************************
|
||||
* Getters
|
||||
|
|
|
@ -95,15 +95,4 @@ class Manufacturer extends AbstractCompany
|
|||
* @Assert\Valid()
|
||||
*/
|
||||
protected $parameters;
|
||||
|
||||
/**
|
||||
* Returns the ID as an string, defined by the element class.
|
||||
* This should have a form like P000014, for a part with ID 14.
|
||||
*
|
||||
* @return string The ID as a string;
|
||||
*/
|
||||
public function getIDString(): string
|
||||
{
|
||||
return 'M'.sprintf('%06d', $this->getID());
|
||||
}
|
||||
}
|
||||
|
|
|
@ -113,16 +113,6 @@ class MeasurementUnit extends AbstractPartsContainingDBElement
|
|||
*/
|
||||
protected $parameters;
|
||||
|
||||
/**
|
||||
* Returns the ID as an string, defined by the element class.
|
||||
* This should have a form like P000014, for a part with ID 14.
|
||||
*
|
||||
* @return string The ID as a string;
|
||||
*/
|
||||
public function getIDString(): string
|
||||
{
|
||||
return 'MU'.$this->getID();
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
|
|
|
@ -176,16 +176,6 @@ class Part extends AttachmentContainingDBElement
|
|||
parent::__clone();
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the ID as an string, defined by the element class.
|
||||
* This should have a form like P000014, for a part with ID 14.
|
||||
*
|
||||
* @return string The ID as a string;
|
||||
*/
|
||||
public function getIDString(): string
|
||||
{
|
||||
return 'P'.sprintf('%06d', $this->getID());
|
||||
}
|
||||
|
||||
/**
|
||||
* Get all devices which uses this part.
|
||||
|
|
|
@ -128,16 +128,6 @@ class PartLot extends AbstractDBElement implements TimeStampableInterface, Named
|
|||
parent::__clone();
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the ID as an string, defined by the element class.
|
||||
* This should have a form like P000014, for a part with ID 14.
|
||||
*
|
||||
* @return string The ID as a string;
|
||||
*/
|
||||
public function getIDString(): string
|
||||
{
|
||||
return 'PL'.$this->getID();
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if the current part lot is expired.
|
||||
|
|
|
@ -224,15 +224,4 @@ class Storelocation extends AbstractPartsContainingDBElement
|
|||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the ID as an string, defined by the element class.
|
||||
* This should have a form like P000014, for a part with ID 14.
|
||||
*
|
||||
* @return string The ID as a string;
|
||||
*/
|
||||
public function getIDString(): string
|
||||
{
|
||||
return 'L'.sprintf('%06d', $this->getID());
|
||||
}
|
||||
}
|
||||
|
|
|
@ -172,15 +172,4 @@ class Supplier extends AbstractCompany
|
|||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the ID as an string, defined by the element class.
|
||||
* This should have a form like P000014, for a part with ID 14.
|
||||
*
|
||||
* @return string The ID as a string;
|
||||
*/
|
||||
public function getIDString(): string
|
||||
{
|
||||
return 'L'.sprintf('%06d', $this->getID());
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue