Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
stwkit
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
stw
stwkit
Commits
b5ee28eb
Commit
b5ee28eb
authored
Oct 31, 2017
by
Tomas Pettersson
🏸
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
limits period date to be within max and min
parent
14d0d1e2
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
1 deletion
+6
-1
src/components/cards.js
src/components/cards.js
+3
-0
src/components/cards.js.map
src/components/cards.js.map
+1
-1
src/components/cards.ts
src/components/cards.ts
+2
-0
No files found.
src/components/cards.js
View file @
b5ee28eb
...
@@ -589,6 +589,9 @@ var STWkit;
...
@@ -589,6 +589,9 @@ var STWkit;
PeriodCard
.
prototype
.
changeFn
=
function
(
changeCard
)
{
PeriodCard
.
prototype
.
changeFn
=
function
(
changeCard
)
{
var
self
=
this
;
var
self
=
this
;
if
((
typeof
changeCard
.
obsDateInput
!==
'
undefined
'
)
&&
(
typeof
changeCard
.
obsTimeInput
!==
'
undefined
'
))
{
if
((
typeof
changeCard
.
obsDateInput
!==
'
undefined
'
)
&&
(
typeof
changeCard
.
obsTimeInput
!==
'
undefined
'
))
{
var
date
=
moment
.
utc
(
changeCard
.
obsDateInput
.
value
+
'
'
+
changeCard
.
obsTimeInput
.
value
,
self
.
datetimeFormat
);
if
(
date
.
isBefore
(
self
.
minDate
)
||
date
.
isAfter
(
self
.
maxDate
))
return
;
self
.
startDateInput
.
value
=
changeCard
.
obsDateInput
.
value
;
self
.
startDateInput
.
value
=
changeCard
.
obsDateInput
.
value
;
self
.
startTimeInput
.
value
=
changeCard
.
obsTimeInput
.
value
;
self
.
startTimeInput
.
value
=
changeCard
.
obsTimeInput
.
value
;
self
.
updateFromStartDate
();
self
.
updateFromStartDate
();
...
...
src/components/cards.js.map
View file @
b5ee28eb
This source diff could not be displayed because it is too large. You can
view the blob
instead.
src/components/cards.ts
View file @
b5ee28eb
...
@@ -651,6 +651,8 @@ module STWkit {
...
@@ -651,6 +651,8 @@ module STWkit {
public
changeFn
(
changeCard
)
{
public
changeFn
(
changeCard
)
{
var
self
=
this
;
var
self
=
this
;
if
((
typeof
changeCard
.
obsDateInput
!==
'
undefined
'
)
&&
(
typeof
changeCard
.
obsTimeInput
!==
'
undefined
'
))
{
if
((
typeof
changeCard
.
obsDateInput
!==
'
undefined
'
)
&&
(
typeof
changeCard
.
obsTimeInput
!==
'
undefined
'
))
{
var
date
=
moment
.
utc
(
changeCard
.
obsDateInput
.
value
+
'
'
+
changeCard
.
obsTimeInput
.
value
,
self
.
datetimeFormat
);
if
(
date
.
isBefore
(
self
.
minDate
)
||
date
.
isAfter
(
self
.
maxDate
))
return
;
self
.
startDateInput
.
value
=
changeCard
.
obsDateInput
.
value
;
self
.
startDateInput
.
value
=
changeCard
.
obsDateInput
.
value
;
self
.
startTimeInput
.
value
=
changeCard
.
obsTimeInput
.
value
;
self
.
startTimeInput
.
value
=
changeCard
.
obsTimeInput
.
value
;
self
.
updateFromStartDate
();
self
.
updateFromStartDate
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment