aboutsummaryrefslogtreecommitdiff
path: root/perl/lib/Wallet/Schema/Result/Duo.pm
diff options
context:
space:
mode:
authorRuss Allbery <eagle@eyrie.org>2014-12-08 18:33:09 -0800
committerRuss Allbery <eagle@eyrie.org>2014-12-08 18:33:09 -0800
commit535ab35781b30805962201874ffff16492ca265d (patch)
tree433a3446b17227a87f29e064aa710a88f7f8a4ac /perl/lib/Wallet/Schema/Result/Duo.pm
parentd5968989923768688b7bd2e4279a9db43a2b93df (diff)
parent49f5b0d38e96d13b6cfb329b21599f9d6ff853d6 (diff)
Merge pull request #1 from jonrober/master
Duo and rename updates
Diffstat (limited to 'perl/lib/Wallet/Schema/Result/Duo.pm')
-rw-r--r--perl/lib/Wallet/Schema/Result/Duo.pm14
1 files changed, 12 insertions, 2 deletions
diff --git a/perl/lib/Wallet/Schema/Result/Duo.pm b/perl/lib/Wallet/Schema/Result/Duo.pm
index 80a71dc..6ad61e9 100644
--- a/perl/lib/Wallet/Schema/Result/Duo.pm
+++ b/perl/lib/Wallet/Schema/Result/Duo.pm
@@ -45,9 +45,19 @@ __PACKAGE__->table("duo");
__PACKAGE__->add_columns(
"du_name",
{ data_type => "varchar", is_nullable => 0, size => 255 },
+ "du_type",
+ { data_type => "varchar", is_nullable => 0, size => 16 },
"du_key",
{ data_type => "varchar", is_nullable => 0, size => 255 },
);
-__PACKAGE__->set_primary_key("du_name");
-
+__PACKAGE__->set_primary_key("du_name", "du_type");
+
+__PACKAGE__->belongs_to(
+ 'object',
+ 'Wallet::Schema::Result::Object',
+ {
+ 'foreign.ob_type' => 'self.du_type',
+ 'foreign.ob_name' => 'self.du_name',
+ },
+ );
1;