mirror of
https://bitbucket.org/wisemapping/wisemapping-frontend.git
synced 2024-11-11 01:43:23 +01:00
Fix minor bugs on history
This commit is contained in:
parent
85d44786c7
commit
2a7387cb6c
@ -110,6 +110,9 @@
|
|||||||
"forgot.desc": {
|
"forgot.desc": {
|
||||||
"defaultMessage": "We will send you an email to reset your password"
|
"defaultMessage": "We will send you an email to reset your password"
|
||||||
},
|
},
|
||||||
|
"forgot.email": {
|
||||||
|
"defaultMessage": "Email"
|
||||||
|
},
|
||||||
"forgot.register": {
|
"forgot.register": {
|
||||||
"defaultMessage": "Send recovery link"
|
"defaultMessage": "Send recovery link"
|
||||||
},
|
},
|
||||||
@ -128,6 +131,9 @@
|
|||||||
"header.haveaccount": {
|
"header.haveaccount": {
|
||||||
"defaultMessage": "Already have an account?"
|
"defaultMessage": "Already have an account?"
|
||||||
},
|
},
|
||||||
|
"history.no-changes": {
|
||||||
|
"defaultMessage": "There is no changes available"
|
||||||
|
},
|
||||||
"login.desc": {
|
"login.desc": {
|
||||||
"defaultMessage": "Log into your account"
|
"defaultMessage": "Log into your account"
|
||||||
},
|
},
|
||||||
@ -198,6 +204,18 @@
|
|||||||
"registration.desc": {
|
"registration.desc": {
|
||||||
"defaultMessage": "Signing up is free and just take a moment"
|
"defaultMessage": "Signing up is free and just take a moment"
|
||||||
},
|
},
|
||||||
|
"registration.email": {
|
||||||
|
"defaultMessage": "Email"
|
||||||
|
},
|
||||||
|
"registration.firstname": {
|
||||||
|
"defaultMessage": "First Name"
|
||||||
|
},
|
||||||
|
"registration.lastname": {
|
||||||
|
"defaultMessage": "Last Name"
|
||||||
|
},
|
||||||
|
"registration.password": {
|
||||||
|
"defaultMessage": "Password"
|
||||||
|
},
|
||||||
"registration.register": {
|
"registration.register": {
|
||||||
"defaultMessage": "Register"
|
"defaultMessage": "Register"
|
||||||
},
|
},
|
||||||
|
@ -221,6 +221,12 @@
|
|||||||
"value": "We will send you an email to reset your password"
|
"value": "We will send you an email to reset your password"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"forgot.email": [
|
||||||
|
{
|
||||||
|
"type": 0,
|
||||||
|
"value": "Email"
|
||||||
|
}
|
||||||
|
],
|
||||||
"forgot.register": [
|
"forgot.register": [
|
||||||
{
|
{
|
||||||
"type": 0,
|
"type": 0,
|
||||||
@ -257,6 +263,12 @@
|
|||||||
"value": "Already have an account?"
|
"value": "Already have an account?"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"history.no-changes": [
|
||||||
|
{
|
||||||
|
"type": 0,
|
||||||
|
"value": "There is no changes available"
|
||||||
|
}
|
||||||
|
],
|
||||||
"login.desc": [
|
"login.desc": [
|
||||||
{
|
{
|
||||||
"type": 0,
|
"type": 0,
|
||||||
@ -395,6 +407,30 @@
|
|||||||
"value": "Signing up is free and just take a moment"
|
"value": "Signing up is free and just take a moment"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"registration.email": [
|
||||||
|
{
|
||||||
|
"type": 0,
|
||||||
|
"value": "Email"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"registration.firstname": [
|
||||||
|
{
|
||||||
|
"type": 0,
|
||||||
|
"value": "First Name"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"registration.lastname": [
|
||||||
|
{
|
||||||
|
"type": 0,
|
||||||
|
"value": "Last Name"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"registration.password": [
|
||||||
|
{
|
||||||
|
"type": 0,
|
||||||
|
"value": "Password"
|
||||||
|
}
|
||||||
|
],
|
||||||
"registration.register": [
|
"registration.register": [
|
||||||
{
|
{
|
||||||
"type": 0,
|
"type": 0,
|
||||||
|
@ -24,10 +24,10 @@ const HistoryDialog = (props: DialogProps) => {
|
|||||||
props.onClose();
|
props.onClose();
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleOnClick = (event,vid): void => {
|
const handleOnClick = (event, vid): void => {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
client.revertHistory(mapId,vid)
|
client.revertHistory(mapId, vid)
|
||||||
.then((mapId)=>{
|
.then((mapId) => {
|
||||||
handleOnClose();
|
handleOnClose();
|
||||||
})
|
})
|
||||||
};
|
};
|
||||||
@ -50,7 +50,14 @@ const HistoryDialog = (props: DialogProps) => {
|
|||||||
</TableRow>
|
</TableRow>
|
||||||
</TableHead>
|
</TableHead>
|
||||||
<TableBody>
|
<TableBody>
|
||||||
{changeHistory.map((row) => (
|
|
||||||
|
{changeHistory.length == 0 ? (
|
||||||
|
<TableRow>
|
||||||
|
<TableCell colSpan={4}><FormattedMessage id='history.no-changes' defaultMessage='There is no changes available' />
|
||||||
|
</TableCell>
|
||||||
|
</TableRow>
|
||||||
|
) :
|
||||||
|
changeHistory.map((row) => (
|
||||||
<TableRow key={row.id}>
|
<TableRow key={row.id}>
|
||||||
<TableCell align="left">{row.creator}</TableCell>
|
<TableCell align="left">{row.creator}</TableCell>
|
||||||
<TableCell align="left">
|
<TableCell align="left">
|
||||||
@ -59,7 +66,7 @@ const HistoryDialog = (props: DialogProps) => {
|
|||||||
</Tooltip>
|
</Tooltip>
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell align="left"><Link href={`c/maps/${mapId}/${row.id}/view`} target="history"><FormattedMessage id="maps.view" defaultMessage="View" /></Link></TableCell>
|
<TableCell align="left"><Link href={`c/maps/${mapId}/${row.id}/view`} target="history"><FormattedMessage id="maps.view" defaultMessage="View" /></Link></TableCell>
|
||||||
<TableCell align="left"><Link href="#" onClick={(e)=>handleOnClick(e,row.id)}><FormattedMessage id="maps.revert" defaultMessage="Revert" /></Link></TableCell>
|
<TableCell align="left"><Link href="#" onClick={(e) => handleOnClick(e, row.id)}><FormattedMessage id="maps.revert" defaultMessage="Revert" /></Link></TableCell>
|
||||||
</TableRow>
|
</TableRow>
|
||||||
))}
|
))}
|
||||||
</TableBody>
|
</TableBody>
|
||||||
|
Loading…
Reference in New Issue
Block a user