1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-20 02:48:51 +00:00

[misc] updated text, fixup, cleaned up code & files for 'list sdoc revisions'

This commit is contained in:
llj
2023-08-25 18:04:38 +08:00
parent 6586660701
commit 1b53fe6265
11 changed files with 6 additions and 154 deletions

View File

@@ -210,7 +210,7 @@ class ExtraAttributesDialog extends Component {
return (
<>
<ModalHeader toggle={this.onToggle}>{gettext('Edit extra attributes')}</ModalHeader>
<ModalHeader toggle={this.onToggle}>{gettext('Edit extra properties')}</ModalHeader>
<ModalBody>
{this.renderColumns()}
</ModalBody>

View File

@@ -110,7 +110,7 @@ class DetailListView extends React.Component {
<tr className="file-extra-attributes">
<th colSpan={2}>
<div className="edit-file-extra-attributes-btn" onClick={this.toggleExtraAttributesDialog}>
{gettext('Edit extra attributes')}
{gettext('Edit extra properties')}
</div>
</th>
</tr>

View File

@@ -152,9 +152,6 @@ class DirentGridView extends React.Component {
case 'Unmark as draft':
this.onUnmarkAsDraft(currentObject);
break;
case 'List revisions':
this.openRevisionsPage(currentObject);
break;
case 'Comment':
this.onCommentItem();
break;
@@ -292,14 +289,6 @@ class DirentGridView extends React.Component {
});
}
openRevisionsPage = (currentObject) => {
const repoID = this.props.repoID;
const filePath = this.getDirentPath(currentObject);
const url = Utils.generateRevisionsURL(siteRoot, repoID, filePath);
if (!url) return;
window.open(url);
}
onCommentItem = () => {
this.props.showDirentDetail('comments');
}

View File

@@ -272,9 +272,6 @@ class DirentListItem extends React.Component {
case 'Unmark as draft':
this.onUnmarkAsDraft();
break;
case 'List revisions':
this.openRevisionsPage();
break;
case 'Comment':
this.props.onDirentClick(this.props.dirent);
this.props.showDirentDetail('comments');
@@ -394,14 +391,6 @@ class DirentListItem extends React.Component {
});
}
openRevisionsPage = () => {
const repoID = this.props.repoID;
const filePath = this.getDirentPath(this.props.dirent);
const url = Utils.generateRevisionsURL(siteRoot, repoID, filePath);
if (!url) return;
window.open(url);
}
onHistory = () => {
let repoID = this.props.repoID;
let filePath = this.getDirentPath(this.props.dirent);

View File

@@ -157,7 +157,7 @@ class LinkCreation extends React.Component {
return false;
}
if (parseInt(linkAmount) > SHARE_LINK_MAX_NUMBER) {
this.setState({errorInfo: gettext('Please enter an integer smaller than 200 as number of links.')});
this.setState({errorInfo: gettext('Please enter an integer not bigger than {max_number} as number of links.').replace('{max_number}', SHARE_LINK_MAX_NUMBER)});
return false;
}
}