file.go
677 字节
package transform
import (
"gitlab.fjmaimaimai.com/allied-creation/character-library-metadata-bastion/pkg/domain"
"gitlab.fjmaimaimai.com/allied-creation/character-library-metadata-bastion/pkg/infrastructure/pg/models"
)
func TransformToFileDomainModelFromPgModels(fileModel *models.File) (*domain.File, error) {
return &domain.File{
FileId: fileModel.FileId,
FileType: fileModel.FileType,
FileInfo: fileModel.FileInfo,
SourceFileId: fileModel.SourceFileId,
Operator: fileModel.Operator,
CreatedAt: fileModel.CreatedAt,
UpdatedAt: fileModel.UpdatedAt,
DeletedAt: fileModel.DeletedAt,
Version: fileModel.Version,
}, nil
}