Deleted old sample budget sql-data for Ukrainian and Russian
[koha.git] / tools / letter.pl
index 94fc2f5..ab6039c 100755 (executable)
@@ -13,9 +13,9 @@
 # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
 # A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
 #
-# You should have received a copy of the GNU General Public License along with
-# Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
-# Suite 330, Boston, MA  02111-1307 USA
+# You should have received a copy of the GNU General Public License along
+# with Koha; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
 
 =head1 tools/letter.pl
 
@@ -36,6 +36,7 @@
        - we delete the designated record
 
 =cut
+
 # TODO This script drives the CRUD operations on the letter table
 # The DB interaction should be handled by calls to C4/Letters.pm
 
@@ -145,21 +146,7 @@ sub add_form {
         $template->param( adding => 1 );
     }
 
-    # build field list
-    my $field_selection = [
-    {
-        value => 'LibrarianFirstname',
-        text  => 'LibrarianFirstname',
-    },
-    {
-        value => 'LibrarianSurname',
-        text  => 'LibrarianSurname',
-    },
-    {
-        value => 'LibrarianEmailaddress',
-        text  => 'LibrarianEmailaddress',
-    }
-    ];
+    my $field_selection;
     push @{$field_selection}, add_fields('branches');
     if ($module eq 'reserves') {
         push @{$field_selection}, add_fields('borrowers', 'reserves', 'biblio', 'items');
@@ -178,6 +165,9 @@ sub add_form {
             push @{$field_selection}, {value => "biblio.$_", text => ucfirst $_ };
         }
     }
+    elsif ($module eq 'suggestions') {
+        push @{$field_selection}, add_fields('suggestions', 'borrowers', 'biblio');
+    }
     else {
         push @{$field_selection}, add_fields('biblio','biblioitems'),
             {value => q{},             text => '---ITEMS---'  },
@@ -298,6 +288,7 @@ sub get_columns_for {
         aqorders      => '---ORDERS---',
         serial        => '---SERIALS---',
         reserves      => '---HOLDS---',
+        suggestions   => '---SUGGESTIONS---',
     );
     my @fields = ();
     if (exists $column_map{$table} ) {