Commit 882348a1 authored by Evren Kutar's avatar Evren Kutar

dashboard for user role prepare for style

parent d2eda8e9
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
data-intro="isim veya tcno ile öğrenci araması yapabilirsiniz."> data-intro="isim veya tcno ile öğrenci araması yapabilirsiniz.">
<div class="text-center"> <div class="text-center">
<h3>ÖĞRENCİ</h3> <h3>ÖĞRENCİ</h3>
<input type="text" placeholder="Öğrenci ara" ng-model="student_kw" <input type="text" placeholder="Öğrenci ara" ng-model="keyword.student"
ng-keyup="search('ogrenci')"> ng-keyup="search('ogrenci')">
<span class="bordered-fa-icon fa fa-search" ng-click="search('ogrenci')"></span> <span class="bordered-fa-icon fa fa-search" ng-click="search('ogrenci')"></span>
</div> </div>
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
data-intro="isim veya tcno ile personel araması yapabilirsiniz."> data-intro="isim veya tcno ile personel araması yapabilirsiniz.">
<div class="text-center"> <div class="text-center">
<h3>PERSONEL</h3> <h3>PERSONEL</h3>
<input type="text" placeholder="Personel ara" ng-model="staff_kw" <input type="text" placeholder="Personel ara" ng-model="keyword.staff"
ng-keyup="search('personel')"> ng-keyup="search('personel')">
<span class="bordered-fa-icon fa fa-search" ng-click="search('personel')"></span> <span class="bordered-fa-icon fa fa-search" ng-click="search('personel')"></span>
</div> </div>
......
...@@ -23,8 +23,7 @@ angular.module('ulakbus.dashboard', []) ...@@ -23,8 +23,7 @@ angular.module('ulakbus.dashboard', [])
$scope.menuitems = data; $scope.menuitems = data;
}); });
$scope.student_kw = ""; $scope.keyword = {student: "", staff: ""};
$scope.staff_kw = "";
$scope.students = []; $scope.students = [];
$scope.staffs = []; $scope.staffs = [];
...@@ -33,20 +32,20 @@ angular.module('ulakbus.dashboard', []) ...@@ -33,20 +32,20 @@ angular.module('ulakbus.dashboard', [])
$timeout(function () { $timeout(function () {
if (where === 'personel') { if (where === 'personel') {
// if input length greater than 2 search for the value // if input length greater than 2 search for the value
if ($scope.staff_kw.length > 2) { if ($scope.keyword.staff.length > 2) {
$scope.getItems(where, $scope.staff_kw).success(function (data) { $scope.getItems(where, $scope.keyword.staff).success(function (data) {
$scope.staffs = data.results; $scope.staffs = data.results;
}); });
} }
} }
if (where === 'ogrenci') { if (where === 'ogrenci') {
if ($scope.student_kw.length > 2) { if ($scope.keyword.student.length > 2) {
$scope.getItems(where, $scope.student_kw).success(function (data) { $scope.getItems(where, $scope.keyword.student).success(function (data) {
$scope.students = data.results; $scope.students = data.results;
}) })
} }
} }
}); }, 500);
}; };
$scope.getItems = function (where, what) { $scope.getItems = function (where, what) {
......
...@@ -380,7 +380,6 @@ app.directive('logout', function ($http, $location, RESTURL) { ...@@ -380,7 +380,6 @@ app.directive('logout', function ($http, $location, RESTURL) {
$timeout(function () { $timeout(function () {
sidebarmenu.metisMenu(); sidebarmenu.metisMenu();
sidebarUserMenu.metisMenu(); sidebarUserMenu.metisMenu();
}); });
}); });
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<div class="sidebar-container"> <div class="sidebar-container">
<!-- sidebar-person-info --> <!-- sidebar-person-info -->
<div class="sidebar-person-info" ng-if="$root.current_user.is_staff"> <div class="sidebar-person-info" ng-show="$root.current_user.is_staff">
<!--<button class="btn btn-primary close-sidebar-person-info">Profili Kapat</button>--> <!--<button class="btn btn-primary close-sidebar-person-info">Profili Kapat</button>-->
<div class="identity"> <div class="identity">
<button type="button" class="close" ng-class="{hidden: $root.collapsed || !selectedUser}" <button type="button" class="close" ng-class="{hidden: $root.collapsed || !selectedUser}"
......
This diff is collapsed.
...@@ -302,7 +302,7 @@ angular.module("components/dashboard/dashboard.html", []).run(["$templateCache", ...@@ -302,7 +302,7 @@ angular.module("components/dashboard/dashboard.html", []).run(["$templateCache",
" data-intro=\"isim veya tcno ile öğrenci araması yapabilirsiniz.\">\n" + " data-intro=\"isim veya tcno ile öğrenci araması yapabilirsiniz.\">\n" +
" <div class=\"text-center\">\n" + " <div class=\"text-center\">\n" +
" <h3>ÖĞRENCİ</h3>\n" + " <h3>ÖĞRENCİ</h3>\n" +
" <input type=\"text\" placeholder=\"Öğrenci ara\" ng-model=\"student_kw\"\n" + " <input type=\"text\" placeholder=\"Öğrenci ara\" ng-model=\"keyword.student\"\n" +
" ng-keyup=\"search('ogrenci')\">\n" + " ng-keyup=\"search('ogrenci')\">\n" +
" <span class=\"bordered-fa-icon fa fa-search\" ng-click=\"search('ogrenci')\"></span>\n" + " <span class=\"bordered-fa-icon fa fa-search\" ng-click=\"search('ogrenci')\"></span>\n" +
" </div>\n" + " </div>\n" +
...@@ -324,7 +324,7 @@ angular.module("components/dashboard/dashboard.html", []).run(["$templateCache", ...@@ -324,7 +324,7 @@ angular.module("components/dashboard/dashboard.html", []).run(["$templateCache",
" data-intro=\"isim veya tcno ile personel araması yapabilirsiniz.\">\n" + " data-intro=\"isim veya tcno ile personel araması yapabilirsiniz.\">\n" +
" <div class=\"text-center\">\n" + " <div class=\"text-center\">\n" +
" <h3>PERSONEL</h3>\n" + " <h3>PERSONEL</h3>\n" +
" <input type=\"text\" placeholder=\"Personel ara\" ng-model=\"staff_kw\"\n" + " <input type=\"text\" placeholder=\"Personel ara\" ng-model=\"keyword.staff\"\n" +
" ng-keyup=\"search('personel')\">\n" + " ng-keyup=\"search('personel')\">\n" +
" <span class=\"bordered-fa-icon fa fa-search\" ng-click=\"search('personel')\"></span>\n" + " <span class=\"bordered-fa-icon fa fa-search\" ng-click=\"search('personel')\"></span>\n" +
" </div>\n" + " </div>\n" +
...@@ -1267,7 +1267,7 @@ angular.module("shared/templates/directives/sidebar.html", []).run(["$templateCa ...@@ -1267,7 +1267,7 @@ angular.module("shared/templates/directives/sidebar.html", []).run(["$templateCa
"\n" + "\n" +
" <div class=\"sidebar-container\">\n" + " <div class=\"sidebar-container\">\n" +
" <!-- sidebar-person-info -->\n" + " <!-- sidebar-person-info -->\n" +
" <div class=\"sidebar-person-info\" ng-if=\"$root.current_user.is_staff\">\n" + " <div class=\"sidebar-person-info\" ng-show=\"$root.current_user.is_staff\">\n" +
" <!--<button class=\"btn btn-primary close-sidebar-person-info\">Profili Kapat</button>-->\n" + " <!--<button class=\"btn btn-primary close-sidebar-person-info\">Profili Kapat</button>-->\n" +
" <div class=\"identity\">\n" + " <div class=\"identity\">\n" +
" <button type=\"button\" class=\"close\" ng-class=\"{hidden: $root.collapsed || !selectedUser}\"\n" + " <button type=\"button\" class=\"close\" ng-class=\"{hidden: $root.collapsed || !selectedUser}\"\n" +
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment