Insert Date input today - Angular

Asked

Viewed 241 times

1

I’m maintaining an angular code, but I don’t know much about version 1 of this framework, how do I put today’s date in this input? someone has some idea?

<input disabled type="text" class="form-control dateinput" datepicker-popup="{{format}}" ng-model="panorama.start" is-open="startopened" min-date="minDate" max-date="'2315-06-22'" datepicker-options="dateOptions" date-disabled="disabled(date, mode)" ng-required="true" close-text="Fechar" current-text="Hoje" clear-text="Limpar" style="width: 100px">

I found this in the js code

angular.module("panorama11App").controller("HeaderCtrl", ["$scope", "$routeParams", "$filter", "panorama", "Config", function(a, b, c, d, e) {
    var myVar = '2015-10-10';
    a.open = function(b, c) {
        console.log("Opening..."), b.preventDefault(), b.stopPropagation(), a[c] = !0
    }, a.panorama = d, a.$watch("panorama", function() {
        d = a.panorama
    }), console.log("RouteParams:", b), a.config = e
}]),

in the code there are also some re-turns like this:

return {
    restrict: "E",
    scope: {
        title: "@",
        content: "@",
        "class": "@",
        dngmodel: "=",
        editable: "@",
        placeholder: "@"
    },
    controller: EditablespanCtrl,
    templateUrl: "views/editablespan.html"
}

will be that if I add a variable then I can put it in the code ?

I put an id in my input and added a value to it, but it doesn’t work

  • Where it comes from panorama.start?

  • good question, I’m looking here

  • @Sergio did a search on the only javascript files that contain this page, and I did not find any panorama.start settings.

  • Do a search for .start, or by .panorama .

  • @Sergio there appears a lot of thing, I put an excerpt from the file js, ps esse var = myVar (I who did it for testing )

  • @Sergio still can’t get :/ complicated, I don’t know nd of angular

Show 1 more comment
No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.