product_plan.go
1.1 KB
package transform
import (
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-manufacture/pkg/domain"
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-manufacture/pkg/infrastructure/pg/models"
)
func TransformToProductPlanDomainModelFromPgModels(productPlanModel *models.ProductPlan) (*domain.ProductPlan, error) {
return &domain.ProductPlan{
ProductPlanId: productPlanModel.ProductPlanId,
CompanyId: productPlanModel.CompanyId,
OrgId: productPlanModel.OrgId,
BatchNumber: productPlanModel.BatchNumber,
ProductDate: productPlanModel.ProductDate,
Workshop: productPlanModel.Workshop,
WorkOn: productPlanModel.WorkOn,
Machine: productPlanModel.Machine,
PlanProductName: productPlanModel.PlanProductName,
PlanDevoted: productPlanModel.PlanDevoted,
PlanStatus: productPlanModel.PlanStatus,
WorkStation: productPlanModel.WorkStation,
Remark: productPlanModel.Remark,
CreatedAt: productPlanModel.CreatedAt,
UpdatedAt: productPlanModel.UpdatedAt,
DeletedAt: productPlanModel.DeletedAt,
}, nil
}