Omar Hassan
@Omar Hassan
Posts made by Omar Hassan
-
RE: document.addEventListener("show" is not working in cordova with onsen
I have the same issue, Show event is not fired, i am using onsen 1.x,
Here is my code,document.addEventListener("show", function (event) { if (event.target.id == "service_requests-page") { alert("init service_requests-page"); } }, false);
Any one can help ?
-
RE: cordova google map plugin not shown map
I have the same issue, Show event is not fired, i am using onsen 1.x,
Here is my code,document.addEventListener("show", function (event) { if (event.target.id == "service_requests-page") { alert("init service_requests-page"); } }, false);
Any one can help ?
-
RE: Sneak Peeking 1.2.2: Lazy Repeat (or Infinite Scrolling)
How we can calculate item height dynamically in calculateItemHeight ? Could you please give us an example ?
-
RE: Dynamic HTML error Onsen 2
Dears Onsen ui developers , No fix for this issue ?
-
RE: Dynamic HTML error Onsen 2
If i changed your example to this
var onsItem = document.createElement('ons-list-item'); onsItem.setAttribute('modifier', "chevron"); onsItem.setAttribute('ng-click', 'functionName()'); onsItem.innerHTML = '<img src="" alt="something here" />'; ons.compile(onsItem); var ccc = document.getElementById('listIDorSomething'); ccc.appendChild(onsItem);
It give me this error
Error: AngularJS Scope is null. Argument DOM element must be attached in DOM document. at Object.ons.compile (angular-onsenui.js:472) at Scope.$scope.login_click (app.js:171) at angular.js:13924 at angular-onsenui.js:11397 at Scope.$eval (angular.js:16052) at Scope.$apply (angular.js:16152) at ons-button.listener (angular-onsenui.js:11396) at defaultHandlerWrapper (angular.js:3346) at ons-button.eventHandler (angular.js:3334)(anonymous function) @ angular.js:12520 17:4400/plugins/cordova-plugin-whitelist/whitelist.js:25 No Content-Security-Policy meta tag found. Please add one when using the cordova-plugin-whitelist plugin.
-
RE: Dynamic HTML error Onsen 2
@Fran-Diox
Here is a sample from my generated HTML,<ul class="tabs"> <li class="current" ng-click="oneClick(0)">ملاحظات</li> <li class="current" ng-click="oneClick(1)">عام</li> </ul> <br> <div class="form" ng-show="shouldShow(0)"></div> <div class="form" ng-show="shouldShow(1)"> <p>رصيد أيام الإجازة</p> <br><input id="BalanceVactionDays" value="7" name="BalanceVactionDays" type="text" class="text-input" onkeypress="return event.charCode >= 48 && event.charCode <= 57" ng-init="BalanceVactionDays= 7" ng-model="BalanceVactionDays"> <div class="error-msgs" ng-messages="requestDetailsFrom.BalanceVactionDays.$error"> <p ng-message="emptyValidator">Required nn</p> </div> <p>مدة الإجازة الفعلية \ يوم</p> <br><input id="ActualVacationDays" value="1" name="ActualVacationDays" type="text" class="text-input" onkeypress="return event.charCode >= 48 && event.charCode <= 57" ng-init="ActualVacationDays= 1" ng-model="ActualVacationDays"> <div class="error-msgs" ng-messages="requestDetailsFrom.ActualVacationDays.$error"> <p ng-message="emptyValidator">Required nn</p> </div> </div>
-
RE: Dynamic HTML error Onsen 2
@munsterlander said:
Yes, it also does ,not work.
For example here if you chnaged onlick here to be ng-clickonsItem.setAttribute('ng-click', "functionName()");
it will not work, all things works well in onsen 1.3.
-
RE: Dynamic HTML error Onsen 2
@munsterlander, @Fran Diox
But all angular directives doesnot work such as ng-click and ng-show,
Any advise to fix this ?