Vorbereitung orderby sortby
This commit is contained in:
parent
68d3cde529
commit
5016e27cca
@ -45,7 +45,14 @@
|
|||||||
"id": "cordova-plugin-dbcopy"
|
"id": "cordova-plugin-dbcopy"
|
||||||
},
|
},
|
||||||
"cordova-plugin-file",
|
"cordova-plugin-file",
|
||||||
"cordova-plugin-file-transfer"
|
"cordova-plugin-file-transfer",
|
||||||
|
{
|
||||||
|
"variables": {
|
||||||
|
"BILLING_KEY": "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAm/DQuSuSDJgbmTThI8xMlwTf0IKvPWzsKUPRDw2pkoaWz2U+RL3AHUTwmUhXxpLGMvj7PC0Jt4xp9ilO5h5tWQ7TrqUxdTPBeL8U+WZHoQIDFmgi+ovWdClgA6aAHs1VARKPxCM2F4ngzCFIdIsiign1IeFo+uVMcel8IgUJIQX1zy7MabnQY+jIU97xjHb2bIQQsoUG40fm7jYoXWxM8OkyAdeBfXx6eGgpbvnUvjFqVlJEEGBy4ysM4K/XajBFlge4VINku8NCiGfpWUixtvEssrLX95f1r1Vo4Zw+OPp0uyVt5OyC0IeLPZyzpw0aDDxY1x3EiGhviRkKaOIgIwIDAQAB"
|
||||||
|
},
|
||||||
|
"locator": "C:\\_IONIC_\\AndroidInAppBilling",
|
||||||
|
"id": "com.smartmobilesoftware.androidinappbilling"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"cordovaPlatforms": [
|
"cordovaPlatforms": [
|
||||||
"ios",
|
"ios",
|
||||||
|
|||||||
@ -133,7 +133,7 @@ appControllers.controller('imageDownloadCtrl', function ($scope, $stateParams, $
|
|||||||
};
|
};
|
||||||
|
|
||||||
$scope.refreshData=function(){
|
$scope.refreshData=function(){
|
||||||
var data='refresh';
|
var data={command:'refresh', direction: ''};
|
||||||
dataShare.sendData(data);
|
dataShare.sendData(data);
|
||||||
$scope.navigateTo('app.pokemonlist', {isAnimated:false});
|
$scope.navigateTo('app.pokemonlist', {isAnimated:false});
|
||||||
};
|
};
|
||||||
|
|||||||
@ -16,39 +16,32 @@
|
|||||||
<ion-content scroll="false">
|
<ion-content scroll="false">
|
||||||
<!--list section-->
|
<!--list section-->
|
||||||
<md-list>
|
<md-list>
|
||||||
<md-subheader class="md-warn">The setting will change SQLite data</md-subheader>
|
<md-list-item class="md-list-item-default" ng-click="orderby('asc')">
|
||||||
|
|
||||||
<md-list-item class="md-list-item-default" ng-click="navigateTo('app.contractlist',true)">
|
|
||||||
<i class="fa fa-play"></i>
|
<i class="fa fa-play"></i>
|
||||||
|
<p>Sortierung aufsteigend</p>
|
||||||
<p>Enable Row Animation</p>
|
|
||||||
</md-list-item>
|
</md-list-item>
|
||||||
|
|
||||||
<md-list-item class="md-list-item-default" ng-click="navigateTo('app.contractlist',false)">
|
<md-list-item class="md-list-item-default" ng-click="orderby('desc')">
|
||||||
<i class="fa fa-stop"></i>
|
<i class="fa fa-stop"></i>
|
||||||
|
<p>Sortierung absteigend</p>
|
||||||
<p>Disable Row Animation</p>
|
|
||||||
</md-list-item>
|
</md-list-item>
|
||||||
|
|
||||||
<md-list-item class="md-list-item-default" ng-click="clearAllData($event)">
|
<md-list-item class="md-list-item-default" ng-click="sortby('pokedexid')">
|
||||||
<i class="ion-android-delete"></i>
|
<i class="ion-android-delete"></i>
|
||||||
|
<p>Nach PokedexID sortieren</p>
|
||||||
<p> Clear All Data</p>
|
</md-list-item>
|
||||||
|
<md-list-item class="md-list-item-default" ng-click="sortby('pokemonname')">
|
||||||
|
<i class="ion-android-delete"></i>
|
||||||
|
<p>Nach Namen sortieren</p>
|
||||||
|
</md-list-item>
|
||||||
|
<md-list-item class="md-list-item-default" ng-click="sortby('pokemontyp')">
|
||||||
|
<i class="ion-android-delete"></i>
|
||||||
|
<p>Nach Typ sortieren</p>
|
||||||
</md-list-item>
|
</md-list-item>
|
||||||
<md-list-item class="md-list-item-default" ng-click="refreshData()">
|
<md-list-item class="md-list-item-default" ng-click="refreshData()">
|
||||||
<i class="ion-android-refresh"></i>
|
<i class="ion-android-refresh"></i>
|
||||||
|
<p>Liste aktualisieren</p>
|
||||||
<p>Refresh Data</p>
|
|
||||||
</md-list-item>
|
</md-list-item>
|
||||||
<md-list-item class="md-list-item-default">
|
|
||||||
<i class="fa fa-user"></i>
|
|
||||||
|
|
||||||
<p>Contract Count</p>
|
|
||||||
<span ng-show="loading">...</span>
|
|
||||||
<span ng-show="!loading">{{contractsCount.length}}</span>
|
|
||||||
|
|
||||||
</md-list-item>
|
|
||||||
|
|
||||||
</md-list><!--end list section-->
|
</md-list><!--end list section-->
|
||||||
</ion-content>
|
</ion-content>
|
||||||
</ion-view>
|
</ion-view>
|
||||||
@ -103,10 +103,36 @@ appControllers.controller('pokemonListCtrl', function ($scope, $stateParams,$ion
|
|||||||
|
|
||||||
$scope.$on('data_shared',function(){
|
$scope.$on('data_shared',function(){
|
||||||
var data = dataShare.getData();
|
var data = dataShare.getData();
|
||||||
if (data=='refresh'){
|
|
||||||
|
if (data.command=='refresh'){
|
||||||
$scope.initialForm();
|
$scope.initialForm();
|
||||||
console.log('refresched');
|
console.log('refresched');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (data.command=='sortby'){
|
||||||
|
|
||||||
|
if (data.direction=='pokemonname'){
|
||||||
|
$scope.pokemons = $filter('orderBy')($scope.pokemons, 'pokemonname');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (data.direction=='pokedexid'){
|
||||||
|
$scope.pokemons = $filter('orderBy')($scope.pokemons, 'pokedexid');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (data.direction=='pokemontyp'){
|
||||||
|
$scope.pokemons = $filter('orderBy')($scope.pokemons, 'pokemontypa');
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
if (data.command=='orderby'){
|
||||||
|
|
||||||
|
if (data.direction=='asc'){
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
// initAdMob for initial AdMob
|
// initAdMob for initial AdMob
|
||||||
@ -390,8 +416,21 @@ appControllers.controller('pokemonSettingCtrl', function ($scope,$ionicViewSwitc
|
|||||||
|
|
||||||
};// End clear all data from sqlite
|
};// End clear all data from sqlite
|
||||||
|
|
||||||
|
$scope.orderby=function(orderby){
|
||||||
|
var data={command:'orderby', direction: orderby};
|
||||||
|
dataShare.sendData(data);
|
||||||
|
$scope.navigateTo('app.pokemonlist', {isAnimated:false});
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
$scope.sortby=function(sortby){
|
||||||
|
var data={command:'sortby', direction: sortby};
|
||||||
|
dataShare.sendData(data);
|
||||||
|
$scope.navigateTo('app.pokemonlist', {isAnimated:false});
|
||||||
|
};
|
||||||
|
|
||||||
$scope.refreshData=function(){
|
$scope.refreshData=function(){
|
||||||
var data='refresh';
|
var data={command:'refresh', direction: ''};
|
||||||
dataShare.sendData(data);
|
dataShare.sendData(data);
|
||||||
$scope.navigateTo('app.pokemonlist', {isAnimated:false});
|
$scope.navigateTo('app.pokemonlist', {isAnimated:false});
|
||||||
};
|
};
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user