TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
shankar jha
NA
267
37.3k
Angular with asp.net
Feb 10 2017 7:13 AM
Hi ,
everyone
app.directive('example', function () {
return function (scope, element, attrs) {
angular.element(document).ready(function () {
alert("#"+attrs["id"]);
$("#" + attrs["id"]).datepicker({
showOn: 'button',
buttonImageOnly: true,
buttonImage: 'assests/images/calendar.png',
dateFormat: 'dd-mm-yy'
});
//MANIPULATE THE DOM
});
};
});
and html is-
tr ng-repeat="item in delListdate track by $index" id="deltr">
<td>
<input type="hidden" name="item.ProductDeliveryTypeId" ng-model="item.ProductDeliveryTypeId" value="{{item.ProductDeliveryTypeId}}" />
<input type="text" ng-value="item.DeliveryTypes" ng-model="item.Name" class="form-control" ng-attr-id="{{'DeliveryTypes' + item.DeliveryTypes }}" /></td>
<td>
<input type="date" id="{{'DeliveryDates-'+$index}}" ng-model="item.DeliveryDates" class="form-control" />
<%-- <input type="text" id="{{$index}}" example class="form-control xdate" ng-model="item.DeliveryDates" placeholder="DD/MM/YY" id="datePickerItem_{{$index}}" datepicker-popup="shortDate" is-open="opened[$index]" datepicker-options="dateOptions" current-text="Today" clear-text="Clear" close-text="Close" ng-readonly="false" />
<span class="input-group-btn">
<button type="button" class="btn btn-default" ng-click="openDatePicker($event, $index)">
<i class="glyphicon glyphicon-calendar"></i>
</button>
</span>--%>
</td>
</tr>
<tr>
</tr>
id is alerted but calender is not showing but i fix the id it working fine and dynmically assign id is not working.
Reply
Answers (
1
)
insert data from other database table using sql server
How to open a popup div in Codebehind c#