package subscribeplansvc

import (
	subscribeplandomain "legalgo-BE-go/internal/domain/subscribe_plan"

	"github.com/google/uuid"
)

func (sb *impl) Create(spec subscribeplandomain.SubscribePlanReq) error {
	data := subscribeplandomain.SubscribePlan{
		ID:     uuid.NewString(),
		Code:   spec.Code,
		Name:   spec.Name,
		Length: spec.Length,
		Price:  spec.Price,
		Status: spec.Status,
	}
	return sb.subsRepo.Create(data)
}
