Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
V
VIPSWeb
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
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
VIPS
VIPSWeb
Commits
f1f78a5d
Commit
f1f78a5d
authored
7 years ago
by
Tor-Einar Skog
Browse files
Options
Downloads
Patches
Plain Diff
Couple of bug fixes
parent
3c75a8ea
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
cerealblotchmodels/templates/cerealblotchmodels/septoriahumiditymodelform.html
+1
-2
1 addition, 2 deletions
...mplates/cerealblotchmodels/septoriahumiditymodelform.html
forecasts/static/forecasts/js/forecasts.js
+2
-2
2 additions, 2 deletions
forecasts/static/forecasts/js/forecasts.js
with
3 additions
and
4 deletions
cerealblotchmodels/templates/cerealblotchmodels/septoriahumiditymodelform.html
+
1
−
2
View file @
f1f78a5d
...
@@ -424,7 +424,6 @@
...
@@ -424,7 +424,6 @@
document
.
getElementById
(
"
chartContainer
"
).
style
.
display
=
"
block
"
;
document
.
getElementById
(
"
chartContainer
"
).
style
.
display
=
"
block
"
;
data
.
reverse
();
data
.
reverse
();
var
warningStatusPlotBandData
=
getWarningStatusPlotBandData
(
data
);
var
warningStatusPlotBandData
=
getWarningStatusPlotBandData
(
data
);
//console.log(warningStatusPlotBandData);
var
data
=
getHighChartsSeries
(
var
data
=
getHighChartsSeries
(
data
,
data
,
[
[
...
@@ -437,7 +436,7 @@
...
@@ -437,7 +436,7 @@
{
key
:
"
SEPTORIAHU.SPP
"
,
type
:
"
spline
"
,
lineWidth
:
5
,
color
:
"
blue
"
,
name
:
"
{% trans
"
Spraying
protection
period
"
%}
"
,
yAxis
:
1
},
{
key
:
"
SEPTORIAHU.SPP
"
,
type
:
"
spline
"
,
lineWidth
:
5
,
color
:
"
blue
"
,
name
:
"
{% trans
"
Spraying
protection
period
"
%}
"
,
yAxis
:
1
},
]
]
);
);
renderForecastChart
(
"
chartContainer
"
,
"
{% trans
"
Barley
net
blotch
development
"
%}
"
,
warningStatusPlotBandData
,
data
);
renderForecastChart
(
"
chartContainer
"
,
"
{% trans
"
Septoria
humidity
model
"
%}
"
,
warningStatusPlotBandData
,
data
);
}
}
var
handleAjaxError
=
function
(
jqXHR
,
textStatus
,
errorThrown
){
var
handleAjaxError
=
function
(
jqXHR
,
textStatus
,
errorThrown
){
...
...
This diff is collapsed.
Click to expand it.
forecasts/static/forecasts/js/forecasts.js
+
2
−
2
View file @
f1f78a5d
...
@@ -229,7 +229,7 @@ function changeLatestDays(theForm){
...
@@ -229,7 +229,7 @@ function changeLatestDays(theForm){
*/
*/
function
getWarningStatusPlotBandData
(
forecastResults
)
function
getWarningStatusPlotBandData
(
forecastResults
)
{
{
//console.
log
(forecastResults);
//console.
info
(forecastResults);
var
warningStatuses
=
{
var
warningStatuses
=
{
0
:
{
name
:
"
No forecast available
"
,
color
:
"
#C9C9C9
"
},
0
:
{
name
:
"
No forecast available
"
,
color
:
"
#C9C9C9
"
},
1
:
{
name
:
"
Missing data
"
,
color
:
"
#4DA0FE
"
},
1
:
{
name
:
"
Missing data
"
,
color
:
"
#4DA0FE
"
},
...
@@ -275,7 +275,7 @@ function getWarningStatusPlotBandData(forecastResults)
...
@@ -275,7 +275,7 @@ function getWarningStatusPlotBandData(forecastResults)
if
(
plotBand
!=
null
&&
plotBand
[
"
to
"
]
==
null
)
if
(
plotBand
!=
null
&&
plotBand
[
"
to
"
]
==
null
)
{
{
// Moment.js!!!
// Moment.js!!!
plotBand
.
to
=
getUnixTimestampFromJSON
([
forecastResults
.
length
-
1
][
"
validTimeStart
"
])
+
bandOffset
;
plotBand
.
to
=
getUnixTimestampFromJSON
(
forecastResults
[
forecastResults
.
length
-
1
][
"
validTimeStart
"
])
+
bandOffset
;
plotBands
.
push
(
plotBand
);
plotBands
.
push
(
plotBand
);
}
}
...
...
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