Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
LOFAR
Manage
Activity
Members
Labels
Plan
Issues
Wiki
Jira issues
Open Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RadioObservatory
LOFAR
Commits
028bbac4
Commit
028bbac4
authored
3 years ago
by
Ramesh Kumar
Browse files
Options
Downloads
Patches
Plain Diff
TMSS-843
: Units added and round off done.
parent
7fdc5662
No related branches found
No related tags found
2 merge requests
!634
WIP: COBALT commissioning delta
,
!557
TMSS-843: Added custom read only fields frequency_resolution and...
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
SAS/TMSS/frontend/tmss_webapp/src/components/JSONEditor/JEditor.js
+5
-5
5 additions, 5 deletions
...frontend/tmss_webapp/src/components/JSONEditor/JEditor.js
with
5 additions
and
5 deletions
SAS/TMSS/frontend/tmss_webapp/src/components/JSONEditor/JEditor.js
+
5
−
5
View file @
028bbac4
...
...
@@ -457,14 +457,14 @@ function Jeditor(props) {
}
}
else
if
(
propertyKey
.
toLowerCase
()
===
'
channels_per_subband
'
&&
propertyValue
instanceof
Object
)
{
// Add custom fields to the properties where property 'channels_per_subband' is one of the property.
let
freqResolution
=
{
title
:
'
Frequency Resolution
'
,
let
freqResolution
=
{
title
:
'
Frequency Resolution
(kHz)
'
,
type
:
'
string
'
,
default
:
''
,
format
:
"
grid
"
,
// propertyOrder: 1002
};
properties
[
'
frequency_resolution
'
]
=
freqResolution
;
let
timeResolution
=
{
title
:
'
Time Resolution
'
,
let
timeResolution
=
{
title
:
`
Time Resolution
(
${
props
.
observationType
===
'
beamforming observation
'
?
'
ms
'
:
'
sec
'
}
)`
,
type
:
'
string
'
,
default
:
''
,
format
:
"
grid
"
,
...
...
@@ -678,9 +678,9 @@ function Jeditor(props) {
function
getFrequencyResolution
(
channelsPerSubband
)
{
if
(
props
.
observationType
)
{
if
(
props
.
observationType
.
toLowerCase
()
===
'
beamforming observation
'
)
{
return
clockValue
/
1024
*
channelsPerSubband
*
1
/
1000
;
return
(
clockValue
/
1024
*
channelsPerSubband
*
1
/
1000
).
toFixed
(
2
)
;
}
else
if
(
props
.
observationType
.
toLowerCase
()
===
'
target observation
'
)
{
return
clockValue
/
1024
/
channelsPerSubband
*
1
/
1000
;
return
(
clockValue
/
1024
/
channelsPerSubband
*
1
/
1000
).
toFixed
(
2
)
;
}
}
else
{
return
null
;
...
...
@@ -694,7 +694,7 @@ function Jeditor(props) {
* @returns Number calculated value
*/
function
getTimeResolution
(
channelsPerSubband
,
timeIntegrationSteps
)
{
return
1
/
clockValue
*
1024
*
channelsPerSubband
*
timeIntegrationSteps
;
return
1
/
clockValue
*
1024
*
channelsPerSubband
*
timeIntegrationSteps
*
(
props
.
observationType
===
'
beamforming observation
'
?
1000
:
1
)
;
}
/**
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment