Erweiterung der Produktpflege

This commit is contained in:
2026-08-27 15:31:50 +02:00
parent b2ce536723
commit cdf7a538c1
240 changed files with 8264 additions and 6420 deletions
@@ -291,6 +291,13 @@ func (vr *ValueRepository) DeleteValueFromPropertyId(valueId int, propertyId int
return nil
}
func (vr *ValueRepository) UpdateValue(value *models.Value) error {
// Implement the logic to update the label/description of an existing value
query := `UPDATE values SET label=$1, description=$2 WHERE id=$3 AND propertyid=$4`
_, err := vr.db.Exec(query, value.Label, value.Description, value.ID, value.PropertyID)
return err
}
func (vr *ValueRepository) GetValue(id int) (*models.Value, error) {
// Implement the logic to retrieve the value from the database for the given id
query := `SELECT id, label, description FROM values WHERE id=$1`