🧮
RollupProperty
👉
Links (Property base class)
💡
[P] means methods for Page Property, [D] means methods for Database Property.
1. Instance methods
filter_after(value) → 🎛️
Query
- [PARAM] value
value for filter
filter_after creates a Query object for
after filter.
filter_before(value) → 🎛️
Query
- [PARAM] value
value for filter
filter_before creates a Query object for
before filter.
filter_contains(value) → 🎛️
Query
- [PARAM] value
value_for_filter
filter_contains creates a Query object for
contains filter.
filter_does_not_contain(value) → 🎛️
Query
- [PARAM] value
value_for_filter
filter_does_not_contain creates a Query object for
does_not_contain filter.
filter_does_not_equal(value) → 🎛️
Query
- [PARAM] value
value for filter
filter_does_not_equal creates a Query object for
does_not_equal filter.
filter_ends_with(str) → 🎛️
Query
filter_ends_with(str) creates a Query object for ends_with filter.
filter_equals(value) → 🎛️
Query
- [PARAM] value
value for filter
filter_equals creates a Query object for
equals filter.
filter_greater_than(value) → 🎛️
Query
- [PARAM] value
value for filter
filter_greater_than creates a Query object for
greater_than filter.
filter_greater_than_or_equal_to(value) → 🎛️
Query
- [PARAM] value
value for filter
filter_greater_than_or_equal_to creates a Query object for
greater_than_or_equal_to filter.
filter_less_than(value) → 🎛️
Query
- [PARAM] value
value for filter
filter_less_than creates a Query object for
less_than filter.
filter_less_than_or_equal_to(value) → 🎛️
Query
- [PARAM] value
value for filter
filter_less_than_or_equal_to creates a Query object for
less_than_or_equal_to filter.
filter_on_or_after(value) → 🎛️
Query
- [PARAM] value
value for filter
filter_on_or_after creates a Query object for
on_or_after filter.
filter_on_or_before(value) → 🎛️
Query
- [PARAM] value
value for filter
filter_on_or_before creates a Query object for
on_or_before filter.
filter_next_week → 🎛️
Query
filter_next_week creates a Query object for
next_week filter.
filter_next_year → 🎛️
Query
filter_next_year creates a Query object for
next_year filter.
filter_past_month → 🎛️
Query
filter_past_month creates a Query object for
past_month filter.
filter_past_week → 🎛️
Query
filter_past_week creates a Query object for
past_week filter.
filter_past_year → 🎛️
Query
filter_past_year creates a Query object for
past_year filter.
filter_starts_with(str) → 🎛️
Query
filter_starts_with(str) creates a Query object for starts_with filter.
[D] function
function of Page property raises StandardError.
function of Database property returns the function of the rollup setting.
[D] function=(new_func)
function= of Page property raises StandardError.
function= of Database property set the function of the rollup setting.
[D] relation_property_name
relation_property_name of Page property raises StandardError.
relation_property_name of Database property returns the relation property name of the rollup setting.
[D] relation_property_name=(new_relation)
relation_property_name= of Page property raises StandardError.
relation_property_name= of Database property sets the relation property name of the rollup setting.
rollup
rollup of Page property returns the rollup property values of the Page.
rollup of Database property returns the setting of the rollup property.
[D] rollup_property_name
rollup_property_name of Page property raises StandardError.
rollup_property_name of Database property returns the rollup property name of the rollup setting.
[D] rollup_property_name=(“new_rollup”)
rollup_property_name= of Page property raises StandardError.
rollup_property_name= of Database property sets the rollup property name of the rollup setting.
> db.created_time.filter_after Time.new(2022, 5, 4, 21, 30)
# => #<NotionRubyMapping::Query:0x000000011058def8 @filter={"timestamp"=>"created_time", "created_time"=>{"after"=>"2022-05-04T21:30:00+09:00"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty
db.properties["RollupTitle"].filter_after Date.new(2022, 5, 7), another_type: "date"
# => #<NotionRubyMapping::Query:0x0000000109241f58 @filter={"property"=>"RollupTitle", "date"=>{"after"=>"2022-05-07"}}, @page_size=100, @sort=[], @start_cursor=nil>
db.created_time.filter_before Time.new(2022, 5, 4, 21, 30)
# => #<NotionRubyMapping::Query:0x0000000110675cf8 @filter={"timestamp"=>"created_time", "created_time"=>{"before"=>"2022-05-04T21:30:00+09:00"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (date)
db.properties["RollupTitle"].filter_before Date.new(2022, 5, 7), another_type: "date"
# => #<NotionRubyMapping::Query:0x00000001055804e8 @filter={"property"=>"RollupTitle", "date"=>{"before"=>"2022-05-07"}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["CreatedByTitle"].filter_contains "a_user_id"
# => #<NotionRubyMapping::Query:0x0000000110525498 @filter={"property"=>"CreatedByTitle", "created_by"=>{"contains"=>"a_user_id"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (none, any, every)
db.properties["RollupTitle"].filter_contains "abc", condition: "any", another_type: "rich_text"
# => #<NotionRubyMapping::Query:0x0000000105394f30 @filter={"property"=>"RollupTitle", "any"=>{"rich_text"=>{"contains"=>"abc"}}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["CreatedByTitle"].filter_does_not_contain "a_user_id"
=> #<NotionRubyMapping::Query:0x0000000110666b68 @filter={"property"=>"CreatedByTitle", "created_by"=>{"does_not_contain"=>"a_user_id"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (none, any, every)
db.properties["CreatedByTitle"].filter_does_not_contain "abc", condition: "every", another_type: "people"
# => #<NotionRubyMapping::Query:0x000000010533e888 @filter={"property"=>"RollupTitle", "every"=>{"people"=>{"does_not_contain"=>"abc"}}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["CheckboxTitle"].filter_does_not_equal true
# => #<NotionRubyMapping::Query:0x0000000110487680 @filter={"property"=>"CheckboxTitle", "checkbox"=>{"does_not_equal"=>true}}, @page_size=100, @sort=[], @start_cursor=nil>
db.created_time.filter_does_not_equal Date.new(2022, 5, 4)
# => #<NotionRubyMapping::Query:0x000000011052c928 @filter={"timestamp"=>"created_time", "created_time"=>{"does_not_equal"=>"2022-05-04"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (none, any, every)
db.properties["RollupTitle"].filter_does_not_equal "abc", condition: "every", another_type: "phone_number"
# => #<NotionRubyMapping::Query:0x00000001090d5430 @filter={"property"=>"RollupTitle", "every"=>{"phone_number"=>{"does_not_equal"=>"abc"}}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (date)
db.properties["RollupTitle"].filter_does_not_equal Date.new(2022, 5, 7), another_type: "date"
# => #<NotionRubyMapping::Query:0x00000001090ff668 @filter={"property"=>"RollupTitle", "date"=>{"does_not_equal"=>"2022-05-07"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (number)
db.properties["RollupTitle"].filter_does_not_equal 100, another_type: "number"
# => #<NotionRubyMapping::Query:0x00000001090dc7f8 @filter={"property"=>"RollupTitle", "number"=>{"does_not_equal"=>100}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["MailTitle"].filter_ends_with "ac.jp"
=> #<NotionRubyMapping::Query:0x0000000105281b48 @filter={"property"=>"MailTitle", "email"=>{"ends_with"=>"ac.jp"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (none, any, every)
db.properties["RollupTitle"].filter_ends_with "abc", condition: "none", another_type: "rich_text"
# => #<NotionRubyMapping::Query:0x00000001054d9558 @filter={"property"=>"RollupTitle", "none"=>{"rich_text"=>{"ends_with"=>"abc"}}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["CheckboxTitle"].filter_equals true
# => #<NotionRubyMapping::Query:0x00000001105279f0 @filter={"property"=>"CheckboxTitle", "checkbox"=>{"equals"=>true}}, @page_size=100, @sort=[], @start_cursor=nil>
db.created_time.filter_equals Date.new(2022, 5, 4)
# => #<NotionRubyMapping::Query:0x000000011046dd20 @filter={"timestamp"=>"created_time", "created_time"=>{"equals"=>"2022-05-04"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (none, any, every)
db.properties["RollupTitle"].filter_equals "abc", condition: "every", another_type: "phone_number"
# => #<NotionRubyMapping::Query:0x0000000109033928 @filter={"property"=>"RollupTitle", "every"=>{"phone_number"=>{"equals"=>"abc"}}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (date)
db.properties["RollupTitle"].filter_equals Date.new(2022, 5, 7), another_type: "date"
# => #<NotionRubyMapping::Query:0x000000010925b480 @filter={"property"=>"RollupTitle", "date"=>{"equals"=>"2022-05-07"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (number)
db.properties["RollupTitle"].filter_equals 100, another_type: "number"
# => #<NotionRubyMapping::Query:0x0000000108f5f0b0 @filter={"property"=>"RollupTitle", "number"=>{"equals"=>100}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["NumberTitle"].filter_greater_than 10
# => #<NotionRubyMapping::Query:0x0000000106bddf88 @filter={"property"=>"NumberTitle", "number"=>{"greater_than"=>10}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (number)
db.properties["RollupTitle"].filter_greater_than 100, another_type: "number"
# => #<NotionRubyMapping::Query:0x0000000108f550b0 @filter={"property"=>"RollupTitle", "number"=>{"greater_than"=>100}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["NumberTitle"].filter_greater_than_or_equal_to 10
# => #<NotionRubyMapping::Query:0x00000001055a7e30 @filter={"property"=>"NumberTitle", "number"=>{"greater_than_or_equal_to"=>10}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (number)
db.properties["RollupTitle"].filter_greater_than_or_equal_to 100, another_type: "number"
# => #<NotionRubyMapping::Query:0x0000000108f564b0 @filter={"property"=>"RollupTitle", "number"=>{"greater_than_or_equal_to"=>100}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["NumberTitle"].filter_less_than 100
# => #<NotionRubyMapping::Query:0x0000000105143e70 @filter={"property"=>"NumberTitle", "number"=>{"less_than"=>100}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (number)
db.properties["RollupTitle"].filter_less_than 100, another_type: "number"
# => #<NotionRubyMapping::Query:0x00000001093b17f8 @filter={"property"=>"RollupTitle", "number"=>{"less_than"=>100}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["NumberTitle"].filter_less_than_or_equal_to 100
# => #<NotionRubyMapping::Query:0x0000000106b7e740 @filter={"property"=>"NumberTitle", "number"=>{"less_than_or_equal_to"=>100}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (number)
db.properties["RollupTitle"].filter_less_than_or_equal_to 100, another_type: "number"
# => #<NotionRubyMapping::Query:0x0000000108f247a8 @filter={"property"=>"RollupTitle", "number"=>{"less_than_or_equal_to"=>100}}, @page_size=100, @sort=[], @start_cursor=nil>
db.created_time.filter_on_or_after Time.new(2022, 5, 4, 21, 30)
# => #<NotionRubyMapping::Query:0x0000000110557880 @filter={"timestamp"=>"created_time", "created_time"=>{"on_or_after"=>"2022-05-04T21:30:00+09:00"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (date)
db.properties["RollupTitle"].filter_on_or_after Date.new(2022, 5, 7), another_type: "date"
# => #<NotionRubyMapping::Query:0x0000000109378598 @filter={"property"=>"RollupTitle", "date"=>{"on_or_after"=>"2022-05-07"}}, @page_size=100, @sort=[], @start_cursor=nil>
db.created_time.filter_on_or_before Time.new(2022, 5, 4, 21, 30)
# => #<NotionRubyMapping::Query:0x0000000106e65f58 @filter={"timestamp"=>"created_time", "created_time"=>{"on_or_before"=>"2022-05-04T21:30:00+09:00"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (date)
db.properties["RollupTitle"].filter_on_or_before Date.new(2022, 5, 7), another_type: "date"
# => #<NotionRubyMapping::Query:0x00000001090a9ec0 @filter={"property"=>"RollupTitle", "date"=>{"on_or_before"=>"2022-05-07"}}, @page_size=100, @sort=[], @start_cursor=nil>
db.created_time.filter_next_week
# => #<NotionRubyMapping::Query:0x000000011053f2a8 @filter={"timestamp"=>"created_time", "created_time"=>{"next_week"=>{}}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (date)
db.properties["RollupTitle"].filter_next_week another_type: "date"
# => #<NotionRubyMapping::Query:0x00000001093497c0 @filter={"property"=>"RollupTitle", "date"=>{"next_week"=>{}}}, @page_size=100, @sort=[], @start_cursor=nil>
db.created_time.filter_next_year
# => #<NotionRubyMapping::Query:0x000000011061cef0 @filter={"timestamp"=>"created_time", "created_time"=>{"next_year"=>{}}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (date)
db.properties["RollupTitle"].filter_next_year another_type: "date"
# => #<NotionRubyMapping::Query:0x0000000109370b68 @filter={"property"=>"RollupTitle", "date"=>{"next_year"=>{}}}, @page_size=100, @sort=[], @start_cursor=nil>
db.created_time.filter_past_month
# => #<NotionRubyMapping::Query:0x0000000106861940 @filter={"timestamp"=>"created_time", "created_time"=>{"past_month"=>{}}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (date)
db.properties["RollupTitle"].filter_past_month another_type: "date"
# => #<NotionRubyMapping::Query:0x0000000108ffb848 @filter={"property"=>"RollupTitle", "date"=>{"past_month"=>{}}}, @page_size=100, @sort=[], @start_cursor=nil>
db.created_time.filter_past_week
=> #<NotionRubyMapping::Query:0x000000010699aac8 @filter={"timestamp"=>"created_time", "created_time"=>{"past_week"=>{}}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (date)
db.properties["RollupTitle"].filter_past_week another_type: "date"
# => #<NotionRubyMapping::Query:0x00000001090dd2e8 @filter={"property"=>"RollupTitle", "date"=>{"past_week"=>{}}}, @page_size=100, @sort=[], @start_cursor=nil>
db.created_time.filter_past_year
=> #<NotionRubyMapping::Query:0x0000000110276a80 @filter={"timestamp"=>"created_time", "created_time"=>{"past_year"=>{}}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (date)
db.properties["RollupTitle"].filter_past_year another_type: "date"
# => #<NotionRubyMapping::Query:0x0000000109258118 @filter={"property"=>"RollupTitle", "date"=>{"past_year"=>{}}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["MailTitle"].filter_starts_with "hkob"
=> #<NotionRubyMapping::Query:0x0000000101377218 @filter={"property"=>"MailTitle", "email"=>{"starts_with"=>"hkob"}}, @page_size=100, @sort=[], @start_cursor=nil>
### only RollupProperty (none, any, every)
db.properties["RollupTitle"].filter_starts_with "abc", condition: "none", another_type: "rich_text"
=> #<NotionRubyMapping::Query:0x0000000105523c70 @filter={"property"=>"RollupTitle", "none"=>{"rich_text"=>{"starts_with"=>"abc"}}}, @page_size=100, @sort=[], @start_cursor=nil>
page.properties["RollupTitle"].function
# => ...in `assert_database_property': function can execute only Database property. (StandardError)
db.properties["RollupTitle"].function
# => "show_original"
page.properties["RollupTitle"].function = "new_func"
# => ...in `assert_database_property': function can execute only Database property. (StandardError)
db.properties["RollupTitle"].function = "new_func"
# => "new_func"
page.properties["RollupTitle"].relation_property_name
# => ...in `assert_database_property': relation_property_name can execute only Database property. (StandardError)
db.properties["RollupTitle"].relation_property_name
# => "RelationTitle"
page.properties["RollupTitle"].relation_property_name = "new_relation"
# => ...in `assert_database_property': relation_property_name can execute only Database property. (StandardError)
db.properties["RollupTitle"].relation_property_name = "new_relation"
# => "new_relation"
page.properties["RollupTitle"].rollup
# =>
# {"type"=>"array",
# "array"=>[{"type"=>"multi_select", "multi_select"=>[{"id"=>"e81a52e0-b168-451e-b23b-1c35e57037b2", "name"=>"Tag 1", "color"=>"brown"}]}],
# "function"=>"show_original"}
db.properties["RollupTitle"].rollup
# =>
# {"rollup_property_name"=>"Tags",
# "relation_property_name"=>"RelationTitle",
# "rollup_property_id"=>":>Fq",
# "relation_property_id"=>"<nJT",
# "function"=>"show_original"}
page.properties["RollupTitle"].rollup_property_name
# => ...in `assert_database_property': rollup_property_name can execute only Database property. (StandardError)
db.properties["RollupTitle"].rollup_property_name
=> "Tags"
page.properties["RollupTitle"].rollup_property_name = "new_rollup"
# => ...in `assert_database_property': rollup_property_name can execute only Database property. (StandardError)
db.properties["RollupTitle"].rollup_property_name = "new_rollup"
=> "new_rollup"