Search Posts

Category: twitter-bootstrap-3

AngularJs filter date adding 2 hours

how to AngularJs filter date adding 2 hours I have a reservation calendar, where I can click on day and time, so I open a bootstrap modal where there is a date input and a time input. I’m using on the modal load with “date” parameter: $scope.calendarChosenDay = $filter(‘date’)(new Date(date), ‘yyyy-MM-dd’); $scope.calendarChosenTime = $filter(‘date’)(new Date(date), ‘HH:mm’); When the modal opens, the date is correct, but the time is adding 2 hours because of timezone i […]

How to create directive search input in angularjs?

I want to create a search input which when I click on the search icon, it will display the search modal. On the search modal screen, I will search for the data and select one of the search results. The purpose of this job is that I want to use this input search in multiple screens. My source code is here . With this code, if I use this search input in other screens, my […]

Blank content in Bootstrap Modal for second AngularJS directive and onwards

The following is my html with AngularJS directive: <div class=”container”> <my-direc query=”Select * FROM booking”></my-direc> <my-direc query=”Select * FROM booking”></my-direc> </div> The query attribute is used by getData() to retrieve the data from MySQL database. The data will be stored into $ As my data are stored into database, so I just insert some dummy data and store it into $ in array form. Directive: var app = angular.module(“my-app”, [‘ngCookies’]); app.directive(“myDirec”, function ($parse, $http, $cookies) […]

Bootstrap progress bar width transition doesn’t apply when changing between danger, warning, info and success classes

I am using AngularJS and have set the width of a bootstrap progress bar to change dynamically using a varible, and used ng-class to change the colour of the bar depending on the width of the bar. ng-class=”{‘progress-bar-danger’ : sprint.sprintProgress >= 0 && sprint.sprintProgress <= 25, ‘progress-bar-warning’ : sprint.sprintProgress > 25 && sprint.sprintProgress <= 50 }” If the active class on the slider is progress-bar-danger then changing the width results in the default transition being […]

angulajs pagination not showing pagination bar

pleae helpme why pagination bar is not showing <pagination total-items=”Employee.length” ng-model=”currentPage” items-per-page=”pagesize”></pagination> When i chk values as {{Employee.length}}{{pagesize}} its display my values On my table i config as <tr ng-repeat=”Emp in Employee |startFrom:1 |limitTo:pagesize”> Myfilters $scope.currentPage = 1 $scope.pagesize = 3 $scope.maxSize = 5; .filter(‘startFrom’, function () { debugger; return function(data,start){ return data.slice(start) } }) Source: AngularJS

Image passed in a function is not displaying in bootstrap modal popup

I have a image displayed in small icon , when I click on the image , I want to pass the imagesource in a function showPhotos() and display it in popup. I tried doing it , but my popup is coming empty without photos. My thumbnail image html: <div class=”image” ng-repeat=”image in filteredImages track by $index”> <div class=”dropdown”> <img ng-src=”{{image.source}}” class=”images” style=”cursor: pointer;” ng-click=”showPhotos(image.source)”/> </div> </div> JS: $scope.model.selectedImage = “”; $scope.showPhotos = function(image) { $scope.model.selectedImage […]

bootstrap Tooltip remains visible when click on button which redirect user to the other page

See I have applied ‘data-toggle=”tooltip” data-trigger=”hover” When I click on the button it redirect to other page , but tooltip still appear on the new page! I can do manual hide of the too-tip but, is there any other solution to tackle this? buttonTemplate: ‘<button class=”btn btn-xs btnGrey” {tooltip} ng-if=”{2}” ng-click=”{0}”><span><span class=”btn-Grid-Icon”><i class=”fa {1}”></i></span></span></button>’, tooltipTemplate: ‘data-toggle=”tooltip” data-trigger=”hover” data-container=”body” data-placement=”{1}” title=”{0}”‘, createIconButtonHtml: function (config) { var editButton = this.buttonTemplate.replace(“{0}”, config.action); editButton = editButton.replace(“{1}”, config.iconClass); editButton = […]

Modal not popping up in bootstrap.When I clicked "Learn more" modal is not opening up ?Can someone tell me where i went wrong

I have provided the code below and Plunkr link as well.Modal doesn’t display properly when I click the “Learn more” button the issue araises.Can someone tell me where exactly I went wrong.The details are provided below.Well, how about adding more details. Like, what are you trying to accomplish, how are you doing it, what difficulties you have found with the approach, another approaches you have tried, etc. In summary, without code isn’t a good question […]

ng-dropdown-multiselect library not working for me

I found this cool library to do dropdown menus with angularjs + twitter-bootstrap-3, here: I am following the examples, I have this in my html: <div ng-dropdown-multiselect=”” options=”stringData” selected-model=”stringModel” extra-settings=”stringSettings”> </div> And this in my controller: $scope.stringData = [‘a’, ‘b’, ‘c’]; $scope.stringModel = []; $scope.stringSettings = { template: ‘{{option}}’, smartButtonTextConverter: function(skip, option) { return option; }, }; And yet, absolutely nothing is being rendered to the page. 🙁 Anybody have any idea what might […]

Next Page »