-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
input tag에 이미 데이터가 있는 경우 어떻게 해야 date-picker에서 보일까요? #35
Comments
안녕하세요. 질문해주신 내용을 보면 value에 값을 그대로 넣으주시면 될 것 같은데요. |
다음은 tui date-picker에서 제공해주는 예제이구요. value="2019-05-09"만 input tag에 추가했어요.
<input type="text" class="datepicker-input" aria-label="Date-Time" value="2019-05-09">
이렇게 했을 때 tui-date-picker 달력이 떴을 때 해당 value의 일자가 선택되어 있었으면 좋겠는데 안되네요
-------------
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>1. Basic</title>
<link rel="stylesheet" type="text/css" href="./css/tui-example-style.css" />
<link href="../dist/tui-date-picker.css" rel="stylesheet">
</head>
<body>
<div class="code-html">
<div class="tui-datepicker-input tui-datetime-input tui-has-focus">
<input type="text" id="datepicker-input" aria-label="Date-Time" value="2019-05-09">
<span class="tui-ico-date"></span>
</div>
<div id="wrapper" style="margin-top: -1px;"></div>
</div>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
<script type="text/javascript" src="https://uicdn.toast.com/tui.code-snippet/v1.5.0/tui-code-snippet.js"></script>
<script type="text/javascript" src="../dist/tui-date-picker.js"></script>
<script class="code-js">
var datepicker = new tui.DatePicker('#wrapper', {
date: new Date(),
language: 'ko',
input: {
element: '#datepicker-input',
format: 'yyyy-MM-dd'
}
});
</script>
</body>
</html>
…-----Original Message-----
From: "한정"<[email protected]>
To: "nhn/tui.date-picker"<[email protected]>;
Cc: "dongsilove"<[email protected]>; "Author"<[email protected]>;
Sent: 2019-05-29 (수) 15:11:23 (GMT+09:00)
Subject: Re: [nhn/tui.date-picker] input tag에 이미 데이터가 있는 경우 어떻게 해야 date-picker에서 보일까요? (#35)
안녕하세요. 질문해주신 내용을 보면 value에 값을 그대로 넣으주시면 될 것 같은데요.
사용예제나 코드를 구체적으로 보여주실수 있을까요?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
처음에 datepicker 인스턴스를 생성할때 |
그렇다면 각 날짜입력란마다 하나의 datepicker가 필요하다는 말씀이네요. 제가 이해한 것이 맞나요?
-------- 원본 이메일 --------발신: 한정 <[email protected]> 날짜: 19/5/30 오후 4:48 (GMT+09:00) 받은 사람: "nhn/tui.date-picker" <[email protected]> 참조: dongsilove <[email protected]>, Author <[email protected]> 제목: Re: [nhn/tui.date-picker] input tag에 이미 데이터가 있는 경우 어떻게 해야 date-picker에서 보일까요? (#35) 처음에 datepicker 인스턴스를 생성할때 date옵션에 new Date() 대신 원하는 값을 넣어주시면 될 것 같습니다.
—You are receiving this because you authored the thread.Reply to this email directly, view it on GitHub, or mute the thread.
[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "#35?email_source=notifications\u0026email_token=AE7N34VRGYCRM6SZTQMSRKLPX6BGVA5CNFSM4HQI5K2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWRUMBY#issuecomment-497239559",
"url": "#35?email_source=notifications\u0026email_token=AE7N34VRGYCRM6SZTQMSRKLPX6BGVA5CNFSM4HQI5K2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWRUMBY#issuecomment-497239559",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]
|
@dongsilove 넵 맞습니다. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
input type="text" class="datepicker-input" aria-label="Date-Time" value="2019-05-09"
보통 날짜를 value에 위와 같이 setting하게 되는데 기존의 데이터를 date-picker에서 보이도록 하려면 어떻게 해야할까요?
The text was updated successfully, but these errors were encountered: