Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
V
vue
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
lib
unicaen
vue
Commits
d5d01112
You need to sign in or sign up before continuing.
Commit
d5d01112
authored
Mar 26, 2024
by
Laurent Lecluse
Browse files
Options
Downloads
Patches
Plain Diff
Plus de formatDate
parent
d2f7c095
No related branches found
No related tags found
No related merge requests found
Pipeline
#27301
passed
Mar 26, 2024
Stage: publish
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
js/Client/unicaenVue.js
+0
-31
0 additions, 31 deletions
js/Client/unicaenVue.js
with
0 additions
and
31 deletions
js/Client/unicaenVue.js
+
0
−
31
View file @
d5d01112
...
@@ -47,37 +47,6 @@ const unicaenVue = {
...
@@ -47,37 +47,6 @@ const unicaenVue = {
}
}
return
params
.
join
(
'
&
'
);
return
params
.
join
(
'
&
'
);
},
/**
* Formate une date pour affichage
*
* @param String val
* @param String format
* @returns String
*/
formatDate
:
(
val
,
format
)
=>
{
if
(
val
===
undefined
)
{
return
undefined
;
}
let
date
=
new
Date
(
val
);
const
year
=
date
.
getFullYear
();
const
month
=
(
date
.
getMonth
()
+
1
).
toString
().
padStart
(
2
,
'
0
'
);
const
day
=
date
.
getDate
().
toString
().
padStart
(
2
,
'
0
'
);
const
hour
=
date
.
getHours
().
toString
().
padStart
(
2
,
'
0
'
);
const
min
=
date
.
getMinutes
().
toString
().
padStart
(
2
,
'
0
'
);
const
sec
=
date
.
getSeconds
().
toString
().
padStart
(
2
,
'
0
'
);
if
(
format
)
{
switch
(
format
){
case
'
datetime
'
:
return
`
${
day
}
/
${
month
}
/
${
year
}
à
${
hour
}
:
${
min
}
`
;
case
'
time
'
:
return
`
${
hour
}
:
${
min
}
:
${
sec
}
`
;
}
}
return
`
${
day
}
/
${
month
}
/
${
year
}
`
;
}
}
};
};
...
...
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