Popup content does not show in device


#1

this is the template:

<div class="list">
    <label class="item item-radio">
        <input type="radio" name="group" ng-model="data.one"  />
        <div class="item-content">
            Value1
        </div>
        <i class="radio-icon ion-checkmark"></i>
    </label>
    <label class="item item-radio">
        <input type="radio" name="group" ng-model="data.two" />
        <div class="item-content">
            Value2
        </div>
        <i class="radio-icon ion-checkmark"></i>
    </label>
    <label class="item item-radio">
        <input type="radio" name="group" ng-model="data.three"  />
        <div class="item-content">
            Value3
        </div>
        <i class="radio-icon ion-checkmark"></i>
    </label>
</div>

and this is the popup in the controller

            var saveType = $ionicPopup.show({
                scope: $scope,
                templateUrl:   'app/templates/cash.html',
                title: 'The type is',
                cssClass: 'custom-popup',
                buttons: [
                    {
                        text: '<b>OK</b>',
                        type: 'button-energized',
                        onTap: function (e) {
                            return true;
                        }
                    },
                    {
                        text: 'Cancel',
                        type: 'button-positive',
                        onTap: function (e) {
                            return false;
                        }
                    }
                ]
            });
            saveType.then(function (r) {

            });

running the application with “ionic serve”, the popup shows completely. but in the emulator or the device does not.

any idea?


#2

double-check the path to your template file. i’ve been through this issue before, the template file was found in the browser but when deployed as an application the path was incorrect.


#3

I understand your point. But, i could not find how to check the real path into the device. as a workaround I put the template inside the popup function. It works.
thx for your support


#4

Even I am facing the same problem. Any luck? I tried injecting template inside the popup function and it works but it doesn’t work when we use templateURL. This problem occurs only on device not when we do ionic serve --lab. Can anyone please explain this problem?