|
Lines 111-117
return {
Link Here
|
| 111 |
# Now this is getting weird |
111 |
# Now this is getting weird |
| 112 |
# We are adding an extra news with the same code when the lang is not "default" (/"en") |
112 |
# We are adding an extra news with the same code when the lang is not "default" (/"en") |
| 113 |
|
113 |
|
| 114 |
$new_lang = "default" if $new_lang eq 'en'; # Assume that "en" is "default" |
114 |
# $new_lang = "default" if $new_lang eq 'en'; # Assume that "en" is "default" |
| 115 |
|
115 |
|
| 116 |
my $sth_update = $dbh->prepare(q| |
116 |
my $sth_update = $dbh->prepare(q| |
| 117 |
UPDATE additional_contents |
117 |
UPDATE additional_contents |
|
Lines 124-130
return {
Link Here
|
| 124 |
$dbh->do(q| |
124 |
$dbh->do(q| |
| 125 |
INSERT INTO additional_contents(category, code, location, branchcode, title, content, lang, published_on, updated_on, expirationdate, number, borrowernumber) |
125 |
INSERT INTO additional_contents(category, code, location, branchcode, title, content, lang, published_on, updated_on, expirationdate, number, borrowernumber) |
| 126 |
VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) |
126 |
VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) |
| 127 |
|, undef, $category, 'tmp_code', $location, $c->{branchcode}, $c->{title}, $c->{content}, 'default', $c->{published_on}, $c->{updated_on}, $c->{expirationdate}, $c->{number}, $c->{borrowernumber}); |
127 |
|, undef, $category, 'tmp_code', $location, $c->{branchcode}, $c->{title}, '', 'default', $c->{published_on}, $c->{updated_on}, $c->{expirationdate}, $c->{number}, $c->{borrowernumber}); |
| 128 |
|
128 |
|
| 129 |
$parent_idnew = $dbh->last_insert_id(undef, undef, 'additional_contents', undef); |
129 |
$parent_idnew = $dbh->last_insert_id(undef, undef, 'additional_contents', undef); |
| 130 |
} |
130 |
} |
| 131 |
- |
|
|