SQL-Translator-Producer-GraphQL

 view release on metacpan or  search on metacpan

t/lib-dbicschema/Schema/Result/Blog.pm  view on Meta::CPAN

    is_nullable   => 0,
  },
  "location",
  { data_type => "char", is_nullable => 1, size => 100 },
);
__PACKAGE__->set_primary_key("id");
__PACKAGE__->has_many(
  "blog_tags",
  "Schema::Result::BlogTag",
  { "foreign.blog" => "self.id" },
  { cascade_copy => 0, cascade_delete => 0 },
);


# Created by DBIx::Class::Schema::Loader v0.07015 @ 2012-02-05 21:35:07
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Pu8So1Y80nFfvuHrqLpqag

# Convert date strings to datetime objects, and vice versa
__PACKAGE__->inflate_column(
  "created_time",
  { inflate => sub { DateTime->from_epoch(epoch => shift); },
    deflate => sub { shift->epoch; },
  }
);

__PACKAGE__->has_many(
  "tags", "Schema::Result::BlogTag",
  {"foreign.blog" => "self.id"},
  {cascade_copy   => 0, cascade_delete => 0},
);

sub url_title {
  my $self  = shift;
  my $title = $self->title;

  $title =~ s/\W/_/g;

  return lc $title;
}

t/lib-dbicschema/Schema/Result/Photo.pm  view on Meta::CPAN

    is_deferrable => 1,
    join_type     => "LEFT",
    on_delete     => "CASCADE",
    on_update     => "CASCADE",
  },
);
__PACKAGE__->has_many(
  "photosets",
  "Schema::Result::Photoset",
  { "foreign.primary_photo" => "self.id" },
  { cascade_copy => 0, cascade_delete => 0 },
);


# Created by DBIx::Class::Schema::Loader v0.07015 @ 2012-02-05 21:35:07
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:hBwyD8s8bHZ6aae1bl2a3Q

__PACKAGE__->belongs_to(
  "set",
  "Schema::Result::Photoset",
  {id => "photoset"},

t/lib-dbicschema/Schema/Result/Photoset.pm  view on Meta::CPAN

  "needs_interstitial",
  { data_type => "integer", is_nullable => 1 },
  "visibility_can_see_set",
  { data_type => "integer", is_nullable => 1 },
);
__PACKAGE__->set_primary_key("id");
__PACKAGE__->has_many(
  "photos",
  "Schema::Result::Photo",
  { "foreign.photoset" => "self.id" },
  { cascade_copy => 0, cascade_delete => 0 },
);
__PACKAGE__->belongs_to(
  "primary_photo",
  "Schema::Result::Photo",
  { id => "primary_photo" },
  {
    is_deferrable => 1,
    join_type     => "LEFT",
    on_delete     => "CASCADE",
    on_update     => "CASCADE",



( run in 1.111 second using v1.01-cache-2.11-cpan-49f99fa48dc )