Search Posts

Jhipster-generator error on production profile

I’m Trying to run my app in production profile, i’m using jhipster-generator for spring-boot app and angular. The app only run the footer and the background but the rest of the aplication nope, The error Uncaught Error: [$injector:modulerr] Failed to instantiate module myAppdue to: Error: [$injector:nomod] Module ‘myApp’ is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second […]

Wrap angularjs page in http post request to nodejs server

I need to send my angularjs client page as email from my nodejs server. For sending email, I’m using nodemailer, which is working fantastic. I need to provide HTML to nodemailer transporter. To achieve this, I have following options – Use phantomjs and send the page using nodemailer (it’s not working due to authentication issues) To re-create html on server side (I don’t know how) Use angular universal (I’ll need to learn this, which I […]

set up dynamic $stateProvider states from jSon data

I have to build a bunch of multi-step forms in angular and am trying to simplify the process. What I would like to do is have each step (state) produced dynamically via json data. Each step has a very basic layout just an input field. Because of this I would ideally have even the template created dynamically. this is what I have as far as an actual working simple form: angular.module(‘formApp’, [‘ui.router’]) .config(function($stateProvider, $urlRouterProvider) { […]

Gulp, Grunt or Jgeni as doc tool in an angularJS

Documentations are always a complicated topic. The need of constant updates and an extra work (that doesn’t generate value in short-term) makes it a non priority when coding and many times ignored necessity. I know that one must always focus on documenting with the code itself (variable names, functions separations and styleguides), but it’s hard to keep tracking of the working of a big app with the time and even harder to understand to those […]

How to Rotate an image over another with fixed position ionic1

I have to rotate an image on touch on a fixed axis. Currently I am able to set the image to a fixed position with certain angle. But when i am trying to rotate it with some other deg. then the position of image gets changed. I have set the transform-origin: 0 0; Since my image is covering more area. the rotation is not working as i want. My screen shot goes here I have […]

How to trim and concatenate strings in AngularJS

I want an event which currently has its starting date and ending date in a list as: Event1={Start: ‘Sep 18, 2017 10:00AM’, End: ‘Sep 18, 2017 11:00AM’} How can I trim and concatenate this to just display Event1 as Sep 18, 2017, 10:00 AM – 11:00 AM as my event start and end dates would always be the same so I don’t need them to displayed separately. I could do them both in my controller […]

In AngularJS, how do I go about linking an image to an url?

I am working on an AngularJS application and I would like to have an image which, if clicked, redirects to an URL. I already am able to do that but with text. This is what my code looks like: JS: myLink: { LinkText: “Click here for the pdf:”, LinkHRef: “/documents/pdfs/Final.pdf” } HTML: <div class=”basic-page__link” ng-if=”section.myLink”> <a ng-if=”section.myLink.sectionLinkNewTab !== false” target=”_blank” ng-href=”{{ section.myLink.LinkHref }}”>{{ section.myLink.LinkText }}</a> <a ng-if=”section.myLink.sectionLinkNewTab === false” ng-href=” {{section.myLink.LinkHref }}”> {{section.myLink.LinkText }}</a> </div> […]

ng-click on img not working inside ng-repeat

In my view I have a list of icons that when clicked, should call a function from the controller. View <div ng-controller=”EditorController” class=”main-div”> <aside> <div ng-repeat=”icon in EditorIcons”> <img ng-click=”changeme()” data-ng-src=”{{icon.source}}” alt=”{{icon.name}}”/> </div> </aside> </div> Controller app.controller(‘EditorController’, function($scope) { $scope.EditorIcons = [ … ]; $scope.changeme = function() { console.log(“changing”); } } I’ve seen this question asked before, yet I still wasn’t able to find out the problem here. What am I doing wrong? UPDATE I’ve […]

Before Angularjs main Module bootstrap, how do I use angular-md5 or any other alternative if available to calculate hash of user Info?

I am trying to store both user info and its hash in session storage. The user authentication info is provided by SiteMinder. In case of refresh, I want to use session storage, instead of again calling back end to obtain authenticated header (rest api provides authenticated header) which includes user name, id, and many more useful information. However, session storage can be changed or altered from console or other ways, therefore, in each refresh or […]

Easy way to customize the bullets for my list element in AnguIarJS

I am working on an angularJS webpage. I have a data type for a list. in HTML, it looks like this: <div class=”basic-page__section-list–mylist” ng-if=”section.theList”> <ul class=”section-list section-list–mylist”> <li ng-repeat=”listItem in section.theList”>{{ listItem }}</li> </ul> </div> in JS: app.controller(“myCtrl”, function($scope) { $scope.applySettings({ theList: [ “Alaska”, “Arkansas”, “Florida”, “Texas”, ] },{ This does what it’s supposed to. It prints out a list where Alaska, Arkansas, Florida, Texas are the elements. However, I want to customize what the […]

Next Page » « Previous Page