2021-06-01 12:20:20 +00:00
|
|
|
# Copyright (C) 2012-2021 Zammad Foundation, http://zammad-foundation.org/
|
|
|
|
|
2020-10-30 07:59:32 +00:00
|
|
|
FactoryBot.define do
|
|
|
|
factory :'report/profile', aliases: %i[report_profile] do
|
|
|
|
sequence(:name) { |n| "Report #{n}" }
|
|
|
|
active { true }
|
|
|
|
created_by_id { 1 }
|
|
|
|
updated_by_id { 1 }
|
2021-11-29 14:21:47 +00:00
|
|
|
|
|
|
|
trait :condition_created_at do
|
|
|
|
transient do
|
|
|
|
ticket_created_at { nil }
|
|
|
|
end
|
|
|
|
|
|
|
|
condition do
|
|
|
|
{
|
|
|
|
'ticket.created_at' => {
|
|
|
|
operator: 'before (absolute)',
|
|
|
|
value: ticket_created_at.iso8601
|
|
|
|
}
|
|
|
|
}
|
|
|
|
end
|
|
|
|
end
|
2020-10-30 07:59:32 +00:00
|
|
|
end
|
|
|
|
end
|