scinote-web/app/services/repository_columns/create_asset_column_service.rb
2019-11-29 10:16:46 +01:00

21 lines
423 B
Ruby

# frozen_string_literal: true
module RepositoryColumns
class CreateAssetColumnService < ColumnService
def initialize(user, repository_id, name)
super(user, repository_id, name)
end
def call
return self unless valid?
ActiveRecord::Base.transaction do
create_base_column(Extends::REPOSITORY_DATA_TYPES[:RepositoryAssetValue])
# TODO
end
self
end
end
end