|
Lines 1102-1107
subtest 'Helpers' => sub {
Link Here
|
| 1102 |
}); |
1102 |
}); |
| 1103 |
is($queue->count, 1, "Notice is not queued"); |
1103 |
is($queue->count, 1, "Notice is not queued"); |
| 1104 |
|
1104 |
|
|
|
1105 |
my $attribute = $builder->build({ |
| 1106 |
source => 'Illrequestattribute', |
| 1107 |
value => { illrequest_id => $illrq_obj->illrequest_id, type => 'pages', value => '42' } |
| 1108 |
}); |
| 1109 |
|
| 1110 |
my $ILL_REQUEST_CANCEL_content = |
| 1111 |
q{The patron for interlibrary loans request [% illrequest.illrequest_id %], with the following details, has requested cancellation of this ILL request: |
| 1112 |
|
| 1113 |
[% ill_full_metadata %] |
| 1114 |
|
| 1115 |
Attribute: Pages=[% illrequestattributes.pages %] |
| 1116 |
}; |
| 1117 |
my $dbh = C4::Context->dbh; |
| 1118 |
$dbh->do(q{UPDATE letter |
| 1119 |
SET content=? |
| 1120 |
WHERE code="ILL_REQUEST_CANCEL" |
| 1121 |
}, undef, $ILL_REQUEST_CANCEL_content); |
| 1122 |
|
| 1105 |
#get_notice |
1123 |
#get_notice |
| 1106 |
my $not = $illrq_obj->get_notice({ |
1124 |
my $not = $illrq_obj->get_notice({ |
| 1107 |
notice_code => 'ILL_REQUEST_CANCEL', |
1125 |
notice_code => 'ILL_REQUEST_CANCEL', |
|
Lines 1130-1136
subtest 'Helpers' => sub {
Link Here
|
| 1130 |
$not->{content} =~ s/\s//g; |
1148 |
$not->{content} =~ s/\s//g; |
| 1131 |
|
1149 |
|
| 1132 |
is( |
1150 |
is( |
| 1133 |
$not->{content},"Thepatronforinterlibraryloansrequest" . $illrq_obj->id . ",withthefollowingdetails,hasrequestedcancellationofthisILLrequest:-author:myauthor-title:mytitle", |
1151 |
$not->{content},"Thepatronforinterlibraryloansrequest" . $illrq_obj->id . ",withthefollowingdetails,hasrequestedcancellationofthisILLrequest:-author:myauthor-title:mytitleAttribute:Pages=42", |
| 1134 |
'Correct content returned from get_notice with metadata correctly ordered' |
1152 |
'Correct content returned from get_notice with metadata correctly ordered' |
| 1135 |
); |
1153 |
); |
| 1136 |
|
1154 |
|
| 1137 |
- |
|
|