« Shopify/Model/SmartCollection/Image.pm
↑ Summary
Shopify/Model/TenderTransaction/PaymentDetails.pm »
| 1 | #!/usr/bin/perl | ||
| 2 | |||
| 3 | use strict; | ||
| 4 | use warnings; | ||
| 5 | |||
| 6 | use WWW::Shopify; | ||
| 7 | |||
| 8 | package WWW::Shopify::Model::TenderTransaction; | ||
| 9 | use parent "WWW::Shopify::Model::Item"; | ||
| 10 | |||
| 11 | my $fields; sub fields { return $fields; } | ||
| 12 | BEGIN { $fields = { | ||
| 13 | "id" => new WWW::Shopify::Field::Identifier(), | ||
| 14 | "order_id" => new WWW::Shopify::Field::Relation::ReferenceOne('WWW::Shopify::Model::Order'), | ||
| 15 | "user_id" => new WWW::Shopify::Field::Relation::ReferenceOne('WWW::Shopify::Model::User'), | ||
| 16 | "amount" => new WWW::Shopify::Field::Money(), | ||
| 17 | "currency" => new WWW::Shopify::Field::Currency(), | ||
| 18 | "test" => new WWW::Shopify::Field::Boolean(), | ||
| 19 | "processed_at" => new WWW::Shopify::Field::Date(), | ||
| 20 | "remote_reference" => new WWW::Shopify::Field::String(), | ||
| 21 | "payment_details" => new WWW::Shopify::Field::Relation::OwnOne('WWW::Shopify::Model::TenderTransaction::PaymentDetails'), | ||
| 22 | "payment_method" => new WWW::Shopify::Field::String::Enum([qw(credit_card cash android_pay apple_pay google_pay samsung_pay shopify_pay amazon klarna paypal unknown other)]) | ||
| 23 | }; } | ||
| 24 | my $queries; sub queries { return $queries; } | ||
| 25 | BEGIN { $queries = { | ||
| 26 | since_id => new WWW::Shopify::Query::LowerBound('id'), | ||
| 27 | processed_at_min => new WWW::Shopify::Query::LowerBound('processed_at'), | ||
| 28 | processed_at_max => new WWW::Shopify::Query::UpperBound('processed_at'), | ||
| 29 | processed_at => new WWW::Shopify::Query::Match('processed_at') | ||
| 30 | }; } | ||
| 31 | |||
| 32 | sub updatable { undef }; | ||
| 33 | sub creatable { undef }; | ||
| 34 | |||
| 35 | sub read_scope { return "read_orders"; } | ||
| 36 | |||
| 37 | eval(__PACKAGE__->generate_accessors); die $@ if $@; | ||
| 38 | |||
| 39 | 1 |