View | Details | Raw Unified | Return to bug 36831
Collapse All | Expand All

(-)a/Koha/ERM/EHoldings/Title.pm (-2 / +2 lines)
Lines 140-146 sub read_file { Link Here
140
        return ( $column_headers, $lines, $error );
140
        return ( $column_headers, $lines, $error );
141
    }
141
    }
142
142
143
    return ( $column_headers, $lines );
143
    return ( $column_headers, $lines, '' );
144
}
144
}
145
145
146
=head3 get_valid_headers
146
=head3 get_valid_headers
Lines 262-268 sub _detect_delimiter_and_quote { Link Here
262
    my %quote_count;
262
    my %quote_count;
263
263
264
    foreach my $line (@lines) {
264
    foreach my $line (@lines) {
265
        foreach my $char ( ',', '\t', ';', '|' ) {
265
        foreach my $char ( ",", "\t", ";", "|" ) {
266
            my $count = () = $line =~ /\Q$char\E/g;
266
            my $count = () = $line =~ /\Q$char\E/g;
267
            $delimiter_count{$char} += $count if $count;
267
            $delimiter_count{$char} += $count if $count;
268
        }
268
        }
(-)a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/EHoldingsLocalTitlesKBARTImport.vue (-17 / +1 lines)
Lines 2-22 Link Here
2
    <h2>{{ $__("Import from a KBART file") }}</h2>
2
    <h2>{{ $__("Import from a KBART file") }}</h2>
3
    <div class="page-section" id="files">
3
    <div class="page-section" id="files">
4
        <form @submit="addDocument($event)" class="file_upload">
4
        <form @submit="addDocument($event)" class="file_upload">
5
            <h3>{{ $__("Requirements:") }}</h3>
6
            <ul style="margin-bottom: 1.5em">
7
                <li>{{ $__("The file must be in TSV or CSV format") }}</li>
8
                <li>
9
                    {{
10
                        $__(
11
                            "The file should not contain any additional information / header rows, e.g. a file with a single title would be structured as follows:"
12
                        )
13
                    }}
14
                    <ol>
15
                        <li>{{ $__("Column headings row") }}</li>
16
                        <li>{{ $__("Title data row") }}</li>
17
                    </ol>
18
                </li>
19
            </ul>
20
            <fieldset class="rows" id="package_list">
5
            <fieldset class="rows" id="package_list">
21
                <h3>{{ $__("Select file for upload") }}:</h3>
6
                <h3>{{ $__("Select file for upload") }}:</h3>
22
                <ol>
7
                <ol>
Lines 174-180 export default { Link Here
174
                    }
159
                    }
175
                    if (success.warnings.invalid_filetype) {
160
                    if (success.warnings.invalid_filetype) {
176
                        message += `<p>${this.$__(
161
                        message += `<p>${this.$__(
177
                            "The file must be in .tsv or .csv format, please convert your file and try again."
162
                            "Could not detect whether the file is TSV or CSV, please check the file."
178
                        )}</p>`;
163
                        )}</p>`;
179
                        this.setWarning(message);
164
                        this.setWarning(message);
180
                    }
165
                    }
181
- 

Return to bug 36831