App-Zapzi

 view release on metacpan or  search on metacpan

lib/App/Zapzi/Database/Schema/Article.pm  view on Meta::CPAN

package App::Zapzi::Database::Schema::Article;
# ABSTRACT: zapzi article table

use utf8;
use strict;
use warnings;

our $VERSION = '0.017'; # VERSION

use base 'DBIx::Class::Core';
use DateTime::Format::SQLite;
__PACKAGE__->load_components(qw/InflateColumn::DateTime/);


__PACKAGE__->table("articles");


__PACKAGE__->add_columns
(
    "id",
    { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
    "title",
    { data_type => "text", default_value => "Unknown", is_nullable => 0 },
    "folder",
    { data_type => "integer", is_nullable => 0 },
    "created",
    { data_type => 'datetime', is_nullable => 0,
      default_value => \"(datetime('now', 'localtime'))" },
    "source",
    { data_type => "text", default_value => "", is_nullable => 0 },
);


__PACKAGE__->set_primary_key("id");


__PACKAGE__->belongs_to(folder => 'App::Zapzi::Database::Schema::Folder',
                        'folder');

__PACKAGE__->might_have(article_text =>
                        'App::Zapzi::Database::Schema::ArticleText',
                        'id');
1;

__END__

=pod

=encoding UTF-8

=head1 NAME

App::Zapzi::Database::Schema::Article - zapzi article table

=head1 VERSION

version 0.017

=head1 DESCRIPTION

This module defines the schema for the articles table in the Zapzi
database.

=head1 ACCESSORS

=head2 id

  Unique ID for this article
  data_type: 'integer'
  is_auto_increment: 1
  is_nullable: 0



( run in 1.076 second using v1.01-cache-2.11-cpan-cdf2f3d4e48 )