projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c2fd718
)
quotations, RT#16996
author
Ivan Kohler
<ivan@freeside.biz>
Mon, 2 Jul 2012 21:22:56 +0000
(14:22 -0700)
committer
Ivan Kohler
<ivan@freeside.biz>
Mon, 2 Jul 2012 21:22:56 +0000
(14:22 -0700)
FS/FS/Quotable_Mixin.pm
[new file with mode: 0644]
patch
|
blob
diff --git a/FS/FS/Quotable_Mixin.pm
b/FS/FS/Quotable_Mixin.pm
new file mode 100644
(file)
index 0000000..
dfd3ddd
--- /dev/null
+++ b/
FS/FS/Quotable_Mixin.pm
@@ -0,0
+1,13
@@
+package FS::Quotable_Mixin;
+
+use strict;
+use FS::Record qw( qsearch ); #qsearchs );
+use FS::quotation;
+
+sub quotation {
+ my $self = shift;
+ my $pk = $self->primary_key;
+ qsearch('quotation', { $pk => $self->$pk() } );
+}
+
+1;