Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,8 @@ locales:
msgfmt -o modules/imaging_browser/locale/ja/LC_MESSAGES/imaging_browser.mo modules/imaging_browser/locale/ja/LC_MESSAGES/imaging_browser.po
msgfmt -o modules/imaging_qc/locale/ja/LC_MESSAGES/imaging_qc.mo modules/imaging_qc/locale/ja/LC_MESSAGES/imaging_qc.po
msgfmt -o modules/imaging_uploader/locale/ja/LC_MESSAGES/imaging_uploader.mo modules/imaging_uploader/locale/ja/LC_MESSAGES/imaging_uploader.po
msgfmt -o modules/imaging_uploader/locale/hi/LC_MESSAGES/imaging_uploader.mo modules/imaging_uploader/locale/hi/LC_MESSAGES/imaging_uploader.po
npx i18next-conv -l hi -s modules/imaging_uploader/locale/hi/LC_MESSAGES/imaging_uploader.po -t modules/imaging_uploader/locale/hi/LC_MESSAGES/imaging_uploader.json
msgfmt -o modules/instrument_builder/locale/ja/LC_MESSAGES/instrument_builder.mo modules/instrument_builder/locale/ja/LC_MESSAGES/instrument_builder.po
msgfmt -o modules/instrument_list/locale/ja/LC_MESSAGES/instrument_list.mo modules/instrument_list/locale/ja/LC_MESSAGES/instrument_list.po
msgfmt -o modules/instrument_manager/locale/ja/LC_MESSAGES/instrument_manager.mo modules/instrument_manager/locale/ja/LC_MESSAGES/instrument_manager.po
Expand Down
12 changes: 12 additions & 0 deletions locale/hi/LC_MESSAGES/loris.po
Original file line number Diff line number Diff line change
Expand Up @@ -120,13 +120,25 @@ msgstr "हाँ"
msgid "No"
msgstr "नहीं"

msgid "Browse"
msgstr "ब्राउज़ करें"

msgid "Upload"
msgstr "अपलोड करें"

msgid "Clear Filters"
msgstr "फ़िल्टर हटाएँ"

# Common candidate terms
msgid "PSCID"
msgstr "पीएससीआईडी"

msgid "DCCID"
msgstr "डीसीसीआईडी"

msgid "CandID"
msgstr "उम्मीदवार आईडी"

msgid "Visit Label"
msgstr "दौरे का लेबल"

Expand Down
51 changes: 12 additions & 39 deletions locale/loris.pot
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,15 @@ msgstr ""
msgid "No"
msgstr ""

msgid "Clear Filters"
msgstr ""

msgid "Browse"
msgstr ""

msgid "Upload"
msgstr ""

# Common swal labels
msgid "Cancel"
msgstr ""
Expand All @@ -133,6 +142,9 @@ msgstr ""
msgid "DCCID"
msgstr ""

msgid "CandID"
msgstr ""

msgid "Visit Label"
msgstr ""

Expand Down Expand Up @@ -220,42 +232,3 @@ msgstr ""
msgid "NEW"
msgstr ""

msgid "Updated"
msgstr ""

msgid "Uploaded"
msgstr ""

msgid "Total"
msgstr ""

# Common timepoint and vist terms
msgid "Not Started"
msgstr ""

msgid "Screening"
msgstr ""

msgid "Visit"
msgstr ""

msgid "Approval"
msgstr ""

msgid "Subject"
msgstr ""

msgid "Recycling Bin"
msgstr ""

msgid "Pass"
msgstr ""

msgid "Failure"
msgstr ""

msgid "Withdrawal"
msgstr ""

msgid "In Progress"
msgstr ""
15 changes: 9 additions & 6 deletions modules/imaging_uploader/jsx/ImagingUploader.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import PropTypes from 'prop-types';
import FilterForm from 'FilterForm';
import {Tabs, TabPane} from 'Tabs';
import Loader from 'Loader';

import {withTranslation} from 'react-i18next';
import LogPanel from './LogPanel';
import UploadForm from './UploadForm';
import {TextboxElement, SelectElement, ButtonElement} from 'jsx/Form';
Expand Down Expand Up @@ -211,13 +211,14 @@ class ImagingUploader extends Component {
* @return {JSX} - React markup for the component
*/
render() {
const {t} = this.props;
if (!this.state.isLoaded) {
return <Loader/>;
}

const tabList = [
{id: 'browse', label: 'Browse'},
{id: 'upload', label: 'Upload'},
{id: 'browse', label: t('Browse', {ns: 'loris'})},
{id: 'upload', label: t('Upload', {ns: 'loris'})},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we have Upload in the loris.po yet

];

return (
Expand All @@ -238,13 +239,13 @@ class ImagingUploader extends Component {
<SelectElement {... this.state.data.form.visitLabel} />
<ButtonElement
type='reset'
label='Clear Filters'
label={t('Clear Filters', {ns: 'loris'})}
onUserInput={this.resetFilters}
/>
</FilterForm>
</div>
<div className='col-md-7'>
<LogPanel />
<LogPanel t={t}/>
</div>
</div>
<div id='mri_upload_table'>
Expand All @@ -265,6 +266,7 @@ class ImagingUploader extends Component {
imagingUploaderAutoLaunch={
this.state.data.imagingUploaderAutoLaunch
}
t={t}
/>
</TabPane>
</Tabs>
Expand All @@ -274,6 +276,7 @@ class ImagingUploader extends Component {

ImagingUploader.propTypes = {
DataURL: PropTypes.string.isRequired,
t: PropTypes.func,
};

export default ImagingUploader;
export default withTranslation(['imaging_uploader', 'loris'])(ImagingUploader);
18 changes: 11 additions & 7 deletions modules/imaging_uploader/jsx/LogPanel.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
/* global UploadProgress */
import React, {Component} from 'react';
import Panel from 'Panel';
import PropTypes from 'prop-types';
import {withTranslation} from 'react-i18next';
import {
FormElement,
SelectElement,
Expand Down Expand Up @@ -198,17 +200,18 @@ class LogPanel extends Component {
* @return {JSX} - React markup for the component
*/
render() {
const {t} = this.props;
const logTypes = {
summary: 'Summary',
detailed: 'Detailed',
summary: t('Summary', {ns: 'imaging_uploader'}),
detailed: t('Detailed', {ns: 'imaging_uploader'}),
};

return (
<Panel id='log_panel' title='Log Viewer'>
<Panel id='log_panel' title={t('Log Viewer', {ns: 'imaging_uploader'})}>
<FormElement name='log_form'>
<SelectElement
name='LogType'
label='Logs to display'
label={t('Logs to display', {ns: 'imaging_uploader'})}
options={logTypes}
onUserInput={this.onLogTypeChange}
value={this.state.logType}
Expand All @@ -227,7 +230,8 @@ class LogPanel extends Component {
}
}

LogPanel.propTypes = {};
LogPanel.defaultProps = {};
LogPanel.propTypes = {
t: PropTypes.func,
};

export default LogPanel;
export default withTranslation(['imaging_uploader', 'loris'])(LogPanel);
Loading
Loading