3 커밋 bc3e37606a ... 66fa737f80

작성자 SHA1 메시지 날짜
  Amr 66fa737f80 df 5 년 전
  Amr 4744b86cd9 Merge branch 'ibrahimBranch2' into amr 5 년 전
  Hima ee6e6f3182 fff 5 년 전
39개의 변경된 파일223개의 추가작업 그리고 138개의 파일을 삭제
  1. 0 3
      src/app/External-Page/external-page-header/external-page-header.component.ts
  2. 2 1
      src/app/dashboard/definition-of-covenants/definition-of-covenants-add/definition-of-covenants-add.component.html
  3. 3 3
      src/app/dashboard/definition-of-covenants/definition-of-covenants-list/definition-of-covenants-list.component.html
  4. 3 0
      src/app/dashboard/definition-of-covenants/definition-of-covenants-list/definition-of-covenants-list.component.ts
  5. 5 1
      src/app/dashboard/department/department-list/department-list.component.ts
  6. 2 1
      src/app/dashboard/females_request_types/females-request-types-add/females-request-types-add.component.html
  7. 1 0
      src/app/dashboard/females_request_types/females-request-types-list/females-request-types-list.component.ts
  8. 3 3
      src/app/dashboard/link_unit_to_covenants/link-unit-to-covenants-add/link-unit-to-covenants-add.component.html
  9. 12 2
      src/app/dashboard/link_unit_to_covenants/link-unit-to-covenants-add/link-unit-to-covenants-add.component.ts
  10. 6 8
      src/app/dashboard/link_unit_to_covenants/link-unit-to-covenants-list/link-unit-to-covenants-list.component.html
  11. 2 1
      src/app/dashboard/living-service/living-service-add/living-service-add.component.html
  12. 5 1
      src/app/dashboard/living-service/living-service-list/living-service-list.component.ts
  13. 2 2
      src/app/dashboard/living_system_reports/living-system-reports/living-system-reports.component.css
  14. 34 28
      src/app/dashboard/living_system_reports/living-system-reports/living-system-reports.component.html
  15. 6 14
      src/app/dashboard/living_system_reports/living-system-reports/living-system-reports.component.ts
  16. 5 1
      src/app/dashboard/main-menu/main-list/main-list.component.ts
  17. 2 1
      src/app/dashboard/record-info-building/record-info-building-add/record-info-building-add.component.html
  18. 4 1
      src/app/dashboard/record-info-building/record-info-building-list/record-info-building-list.component.ts
  19. 1 1
      src/app/dashboard/sections/section-list/section-list.component.html
  20. 3 0
      src/app/dashboard/sections/section-list/section-list.component.ts
  21. 1 0
      src/app/dashboard/unit-building-information/unit-building-information-add/unit-building-information-add.component.html
  22. 6 6
      src/app/dashboard/unit-building-information/unit-building-information-list/unit-building-information-list.component.html
  23. 3 0
      src/app/dashboard/unit-building-information/unit-building-information-list/unit-building-information-list.component.ts
  24. 2 1
      src/app/dashboard/unit-information/unit-information-add/unit-information-add.component.html
  25. 4 0
      src/app/dashboard/unit-information/unit-information-list/unit-information-list.component.ts
  26. 7 3
      src/app/dashboard/users/form-user/form-user.component.html
  27. 39 16
      src/app/dashboard/users/form-user/form-user.component.ts
  28. 6 1
      src/app/dashboard/users/users.component.ts
  29. 4 3
      src/app/dashboard/view_my_female_requests/view-my-female-requests-add/view-my-female-requests-add.component.html
  30. 16 4
      src/app/dashboard/view_my_female_requests/view-my-female-requests-add/view-my-female-requests-add.component.ts
  31. 10 10
      src/app/dashboard/view_my_female_requests/view-my-female-requests-list/view-my-female-requests-list.component.html
  32. 2 1
      src/app/dashboard/view_requests_for_adminstration/view-requests-for-adminstration-details/view-requests-for-adminstration-details.component.html
  33. 8 8
      src/app/dashboard/view_requests_for_adminstration/view-requests-for-adminstration-list/view-requests-for-adminstration-list.component.html
  34. 1 0
      src/app/dashboard/view_requests_for_tenant/view-requests-for-tenant-details/view-requests-for-tenant-details.component.html
  35. 8 8
      src/app/dashboard/view_requests_for_tenant/view-requests-for-tenant/view-requests-for-tenant.component.html
  36. 0 3
      src/app/end-higri-date/end-higri-date.component.ts
  37. 0 1
      src/app/higri-date/higri-date.component.ts
  38. 1 0
      src/app/shared/dashboard.service.ts
  39. 4 1
      src/app/shared/shared.module.ts

+ 0 - 3
src/app/External-Page/external-page-header/external-page-header.component.ts

@@ -18,9 +18,6 @@ export class ExternalPageHeaderComponent implements OnInit {
    
     currentEnglishDate: any = Date.now(); //english date
 
-    372
-
-
 
     dataLoginUser:any;
 

+ 2 - 1
src/app/dashboard/definition-of-covenants/definition-of-covenants-add/definition-of-covenants-add.component.html

@@ -5,7 +5,8 @@
       <div class="row">
         <div class="col-12">
           <ul class="list-unstyled titileLi-w">
-            <li class="headingText-w"> خدمه البلاغات </li>
+            <li class="headingText-w"> خدمه السكن </li>
+            <li class="headingText-w activeLi-w" style="margin-right:5px; cursor: pointer;" (click)="authSer.backFromEdit()">تعريف  العهد</li>
             <li class="headingText-w activeLi-w" style="margin-right:5px"> {{typePage}} </li>
           </ul>
         </div>

+ 3 - 3
src/app/dashboard/definition-of-covenants/definition-of-covenants-list/definition-of-covenants-list.component.html

@@ -24,20 +24,20 @@
     </div>
 
     <div class="row">
-        <div class="col-12 col-sm-12 col-md-12 col-lg-6">
+        <div class="col-12 col-sm-12 col-md-12 col-lg-3">
           <div class="form-group">
             <span class="spanSelect-w" style="margin-right:10px;">
-                من العناصر يتم عرضها
               <select [ngModel]="dataTableNumber" class="form-control selectButton-w" (input)="onGetValue($event)">
                 <option value="5">5</option>
                 <option value="10">10</option>
                 <option value="15">15</option>
                 <option value="20">20</option>
               </select>
+              من العناصر يتم عرضها
             </span>
           </div>
         </div>
-        <div class="col-12 col-sm-12 col-md-12 col-lg-6">
+        <div class="col-12 col-sm-12 col-md-12 col-lg-3">
           <div class="form-group">
             <span class="spanSelect-w" style="margin-right:10px;">
                 تصنيف العهدة

+ 3 - 0
src/app/dashboard/definition-of-covenants/definition-of-covenants-list/definition-of-covenants-list.component.ts

@@ -297,6 +297,9 @@ onDelete() {
           (error) => {
             console.log(error);
             this.spinner.hide();
+            if(error.error.status == 'covenant is already taken in units'){
+              this.toastr.warning('لا يمكنك حذف العهده لانها جزء من النظام')
+            }
             },
           )
       );

+ 5 - 1
src/app/dashboard/department/department-list/department-list.component.ts

@@ -224,13 +224,17 @@ export class DepartmentListComponent implements OnInit {
                   this.spinner.hide();
                 },
                 (error) => {
-                  console.log(error);
+                  console.log('errorrrrr => ', error);
+                  
                   this.spinner.hide();
                 }
               );
             },
             (error) => {
               console.log(error);
+              if(error['error'].error == 'can not remove adminstration') {
+                this.toastr.warning('لا يمكن مسح الادارات المحدده لإتصالها بالنظام');
+              }
               this.spinner.hide();
             },
           )

+ 2 - 1
src/app/dashboard/females_request_types/females-request-types-add/females-request-types-add.component.html

@@ -5,7 +5,8 @@
       <div class="row">
         <div class="col-12">
           <ul class="list-unstyled titileLi-w">
-            <li class="headingText-w"> خدمه البلاغات </li>
+            <li class="headingText-w"> خدمه السكن </li>
+            <li class="headingText-w activeLi-w" style="margin-right:5px; cursor: pointer;" (click)="authSer.backFromEdit()" >تحديد انواع الطلبات</li>  
             <li class="headingText-w activeLi-w" style="margin-right:5px"> {{typePage}} </li>
           </ul>
         </div>

+ 1 - 0
src/app/dashboard/females_request_types/females-request-types-list/females-request-types-list.component.ts

@@ -110,6 +110,7 @@ export class FemalesRequestTypesListComponent implements OnInit {
           this.dataList = res['types'];
           this.count = res['count'];
           this.perPagePagenation = res['per_page'];
+          this.spinner.hide();
         },
         err => {
           console.log(err);

+ 3 - 3
src/app/dashboard/link_unit_to_covenants/link-unit-to-covenants-add/link-unit-to-covenants-add.component.html

@@ -6,6 +6,7 @@
         <div class="col-12">
           <ul class="list-unstyled titileLi-w">
             <li class="headingText-w"> خدمه  السكن </li>
+            <li class="headingText-w activeLi-w" style="margin-right:5px;cursor: pointer;" (click)="authSer.backFromEdit()">ربط السكن بالعهد</li>
             <li class="headingText-w activeLi-w" style="margin-right:5px"> {{typePage}} </li>
           </ul>
         </div>
@@ -68,15 +69,14 @@
                           <div class="col-6"  *ngIf="categoryId == category_conv.category_id">
                               <div class=form-group>
                                 <div class="custom-control custom-checkbox centerIneerItem">
-                                  <input type="checkbox" class="custom-control-input checkboxx" id="{{category_conv.id}}" [(ngModel)]="category_conv.selected" [value]='category_conv.id' name="{{category_conv.id}}" style="cursor: pointer;" (input)="checked($event.target.value)">
+                                  <input type="checkbox" class="custom-control-input checkboxx" id="{{category_conv.id}}" [(ngModel)]="category_conv.selected" [value]='category_conv.id' name="{{category_conv.id}}" style="cursor: pointer;" (change)="checked($event.target.value)">
                                   <label class="custom-control-label disblayBlock-w" for="{{category_conv.id}}" style="color:#2a2a2a; cursor:pointer; padding: 0 20px; margin: -3px 5px">{{category_conv.name}}</label>
                                 </div>
                               </div>
                             </div> 
                             <div class="col-6"  *ngIf="categoryId == category_conv.category_id ">
                               <div class="form-group">
-                                <input type="number" class="form-control" placeholer="amount" min="1" max="{{category_conv.available_amount}}"  [(ngModel)]="category_conv.covenant_amount" [ngModelOptions]="{standalone: true}"/>
-                                <!-- <p style="color: red" *ngIf="over">تخطيت الحد المسموح</p> -->
+                                <input type="number" class="form-control" placeholer="amount" min="1" max="{{category_conv.available_amount}}"  [(ngModel)]="category_conv.covenant_amount"  [ngModelOptions]="{standalone: true}"  (input)="check_max(category_conv.covenant_amount, category_conv.available_amount, category_conv.name)" />
                               </div>
                             </div>
                       </div>

+ 12 - 2
src/app/dashboard/link_unit_to_covenants/link-unit-to-covenants-add/link-unit-to-covenants-add.component.ts

@@ -5,7 +5,7 @@ import { Location } from '@angular/common';
 import { AuthServiceService } from './../../../shared/auth-service.service';
 import { ToastrService } from 'ngx-toastr';
 import { DashboardService } from './../../../shared/dashboard.service';
-import { Component, OnInit, ViewChild } from '@angular/core';
+import { Component, OnInit, ViewChild, ElementRef } from '@angular/core';
 import { NgForm } from '@angular/forms';
 
 @Component({
@@ -48,6 +48,7 @@ export class LinkUnitToCovenantsAddComponent implements OnInit {
   ) { }
 
   @ViewChild('f') linkForm : NgForm;
+  @ViewChild('amountVal') amountVal: ElementRef;
 
   formData = {
     housing_complex_id:'',
@@ -167,6 +168,8 @@ export class LinkUnitToCovenantsAddComponent implements OnInit {
            this.isComplex = false;
            this.isBuildingType = false;
            this.isBuilding = false;
+           this.toastr.warning('لا يوجد انواع مباني لهذا المجمع')
+
         }
       },
       err => {
@@ -190,6 +193,7 @@ export class LinkUnitToCovenantsAddComponent implements OnInit {
         }else{
              this.isBuildingType = false;
              this.isBuilding = false;
+           this.toastr.warning('لا يوجد بيانات لهذا النوع من المباني')
             
           }
           
@@ -215,6 +219,7 @@ getUnit(event){
 
       }else{
            this.isBuilding = false;
+           this.toastr.warning('لا يوجد وحدات لهذا المبنى ')
         }
 
     },
@@ -240,7 +245,12 @@ getUnit(event){
       console.log(this.formData.covenants);
     } 
 
-
+    check_max(value, max, name){
+      console.log( 'ss',value, max, name);
+      if(value > max){
+        this.toastr.warning(name+' تخطيت الحد الاقصى')
+      }
+    } 
     showcovenant_categories(){
       this.isConvenat = true;
     }

+ 6 - 8
src/app/dashboard/link_unit_to_covenants/link-unit-to-covenants-list/link-unit-to-covenants-list.component.html

@@ -36,15 +36,13 @@
                 </span>
               </div>
             </div>
-      </div>
-  
-      <div class="row">
+
        
           <div class="col-12 col-sm-12 col-md-12 col-lg-3">
               <div class="form-group">
                 <span class="spanSelect-w" style="margin-right:10px;">
                     المجمع السكني
-                  <select [ngModel]="housing_complex_id" class="form-control selectButton-w" (input)="getBuildingsType($event.target.value)">
+                  <select [ngModel]="housing_complex_id" class="form-control selectButton-w" (input)="getBuildingsType($event.target.value)" >
                     <option *ngFor="let complex of complex_list" [value]="complex.id">{{complex.name}}</option>
                   </select>
                 </span>
@@ -52,9 +50,9 @@
             </div>
             <div class="col-12 col-sm-12 col-md-12 col-lg-3" *ngIf="isComplex">
                 <div class="form-group">
-                  نوع المبنى
                   <span class="spanSelect-w" style="margin-right:10px;">
-                    <select [ngModel]="building_type_id" class="form-control selectButton-w" (input)="getBuilding($event.target.value)">
+                      نوع المبنى
+                    <select [ngModel]="building_type_id" class="form-control selectButton-w" (input)="getBuilding($event.target.value)" >
                     <option *ngFor="let type of building_types" [value]="type.id">{{type.name}}</option>
                     </select>
                   </span>
@@ -65,7 +63,7 @@
                   <div class="form-group">
                     <span class="spanSelect-w" style="margin-right:10px;">
                         اسم المبنى
-                      <select [ngModel]="building_id" class="form-control selectButton-w" (input)="getBuildingID($event.target.value)">
+                      <select [ngModel]="building_id" class="form-control selectButton-w" (input)="getBuildingID($event.target.value)" >
                        <option *ngFor="let building of building" [value]="building.id">{{building.building_name}}</option>
                       </select>
                     </span>
@@ -76,7 +74,7 @@
                     <div class="form-group">
                       <span class="spanSelect-w" style="margin-right:10px;">
                           رقم الوحدة
-                        <select [ngModel]="unitId" class="form-control selectButton-w" (input)="unitNum($event.target.value)" >
+                        <select [ngModel]="unitId" class="form-control selectButton-w" (input)="unitNum($event.target.value)" style="margin-right: 44px;padding-top: 10px;">
                          <option *ngFor="let unit of units" [value]="unit.id">{{unit.unit_number}}</option>
                         </select>
                       </span>

+ 2 - 1
src/app/dashboard/living-service/living-service-add/living-service-add.component.html

@@ -5,7 +5,8 @@
       <div class="row">
         <div class="col-12">
           <ul class="list-unstyled titileLi-w">
-            <li class="headingText-w"> خدمه البلاغات </li>
+            <li class="headingText-w"> خدمه السكن </li>
+            <li class="headingText-w activeLi-w" style="margin-right:5px; cursor: pointer;" (click)="authSer.backFromEdit()">تعريف تصنيفات العهد</li>
             <li class="headingText-w activeLi-w" style="margin-right:5px"> {{typePage}} </li>
           </ul>
         </div>

+ 5 - 1
src/app/dashboard/living-service/living-service-list/living-service-list.component.ts

@@ -261,8 +261,12 @@ onDelete() {
             );
           },
           (error) => {
-            console.log(error);
+            console.log(error.error.status);
+            if(error.error.status == 'covenant category id is already taken'){
+              this.toastr.warning('لا يمكنك حذف الصنف لانه جزء من النظام')
+            }
             this.spinner.hide();
+            
             },
           )
       );

+ 2 - 2
src/app/dashboard/living_system_reports/living-system-reports/living-system-reports.component.css

@@ -179,7 +179,7 @@ select.ng-invalid{
     padding: 9px;
     border-radius: 5px 5px 0 0;
     margin-bottom: 0;
-    margin-right: -12px;
+    /* margin-right: -12px; */
     color: #fff;
 }
 .statusBtn-w {
@@ -346,7 +346,7 @@ select.ng-invalid{
  }
  .fit-filter-style{
     display: flex;
-    justify-content: center;
+    /* justify-content: center; */
     margin-top: 20px;
     text-align: center;
     margin-right: 2%;

+ 34 - 28
src/app/dashboard/living_system_reports/living-system-reports/living-system-reports.component.html

@@ -9,44 +9,47 @@
           </div>
       </div>
       <div class="containerContent-w" id="print-section">
-          <div class="row printClass">
+          <!-- <div class="row printClass">
             <div class="col-12 col-md-4">
 
-                <div class="form-group">
-                    <span class="spanSelect-w" style="margin-right:10px;">
-                      <select [ngModel]="reportValue" class="form-control selectButton-w full"  (input)="getReport($event.target.value)">
-                        <option value="0"> رجاء الاختيار التقرير</option>
-                        <option value="1">تقارير عن الوحدات السكنية</option>
-                        <option value="2">تقارير عن السكان في مجمعات و المباني</option>
-                        <option value="3">تقارير عن ساكن</option>
-                        <option value="4">تقارير عن العهد الموجوده</option>
-                      </select>
-                    </span>
-                  </div>
+               
             </div>   
-           </div>
-           <div class="row fit-filter-style printClass" *ngIf="showFilters">
-              <div class="col-12 col-sm-3 col-md-3 col-lg-3">
-                <div class="form-group">
-                  <span class="spanSelect-w" style="margin-right:10px;">
+           </div> -->
+           <div class="row fit-filter-style printClass" >
+              <div class="col-12 col-sm-3 col-md-3 col-lg-2">
+                  <div class="form-group">
+                      <span class="spanSelect-w" style="margin-right:10px;">
+                        <select [ngModel]="reportValue" class="form-control selectButton-w full"  (input)="getReport($event.target.value)">
+                          <option value="0"> رجاء الاختيار التقرير</option>
+                          <option value="1">تقارير عن الوحدات السكنية</option>
+                          <option value="2">تقارير عن السكان في مجمعات و المباني</option>
+                          <option value="3">تقارير عن ساكن</option>
+                          <option value="4">تقارير عن العهد الموجوده</option>
+                        </select>
+                      </span>
+                    </div>
+              </div>
+              <div class="col-12 col-sm-3 col-md-3 col-lg-2">
+                <div class="form-group" *ngIf="showFilters">
+                  <span class="spanSelect-w" style="width: 100%;">
                     <select [ngModel]="housing_complex_id" class="form-control selectButton-w full" (input)="getBuildingsType($event.target.value)">
                       <option *ngFor="let complex of complex_list" [value]="complex.id">{{complex.name}}</option>
                     </select>
                   </span>
                 </div>
               </div>
-              <div class="col-12 col-sm-3 col-md-3 col-lg-3" *ngIf="isComplex">
+              <div class="col-12 col-sm-3 col-md-3 col-lg-2" *ngIf="isComplex">
                 <div class="form-group">
-                  <span class="spanSelect-w" style="margin-right:10px;">
+                  <span class="spanSelect-w" style="width: 100%;">
                     <select [ngModel]="building_type_id" class="form-control selectButton-w full" (input)="getBuilding($event.target.value)">
                     <option *ngFor="let type of building_types" [value]="type.id">{{type.name}}</option>
                     </select>
                   </span>
                 </div>
               </div>
-              <div class="col-12 col-sm-3 col-md-3 col-lg-3" *ngIf="isBuildingType">
+              <div class="col-12 col-sm-3 col-md-3 col-lg-2" *ngIf="isBuildingType">
                 <div class="form-group">
-                  <span class="spanSelect-w" style="margin-right:10px;">
+                  <span class="spanSelect-w"style="width: 100%;">
                     <select [ngModel]="building_id" class="form-control selectButton-w full " (input)="getBuildingID($event.target.value)">
                       <option *ngFor="let building of buildings" [value]="building.id">{{building.building_name}}</option>
                     </select>
@@ -54,21 +57,24 @@
                 </div>
               </div>  
 
-              <div class="col-12 col-sm-12 col-md-12 col-lg-3" *ngIf="isUnit">
+              <div class="col-12 col-sm-12 col-md-12 col-lg-2" *ngIf="isUnit">
                 <div class="form-group">
-                  <span class="spanSelect-w" style="margin-right:10px;">
+                  <span class="spanSelect-w" style="width: 100%;">
                     <select [ngModel]="unitId" class="form-control selectButton-w full" (input)="unitNum($event.target.value)">
                      <option *ngFor="let unit of units" [value]="unit.id">{{unit.unit_number}}</option>
                     </select>
                   </span>
                 </div>
               </div>   
+              <div class="col-12 col-sm-12 col-md-12 col-lg-2">
+                <div class="row printClass" *ngIf="reportValue == 3 && showSearchBtn " style="justify-content: center;">
+                  <input type="text" placeholder="{{placeholder}}" class="form-control numberReport-s" [(ngModel)]="searchValue" style="width: 100%"/>
+                 </div>
+                </div>  
            </div>
-           <div class="row printClass" *ngIf="reportValue == 3 && showSearchBtn " style="justify-content: center; margin-top: 50px">
-            <input type="text" placeholder="{{placeholder}}" class="form-control numberReport-s" [(ngModel)]="searchValue" style="width: 25%"/>
-           </div>
-           <div class="row fit-filter-style printClass" *ngIf="showSearchBtn ">
-              <button class="btn btn-success buttonS" (click)="onSearch()" style="margin-left: 2%;">أبحث</button>            
+          
+           <div class="row fit-filter-style printClass" *ngIf="showSearchBtn " style="    padding: 25px;">
+              <button class="btn btn-success buttonS" (click)="onSearch()">أبحث</button>            
           </div>
 
           <div class="col-12" *ngIf="fristReport">

+ 6 - 14
src/app/dashboard/living_system_reports/living-system-reports/living-system-reports.component.ts

@@ -154,9 +154,7 @@ getBuilding(event){
           this.isBuildingType= true;
 
           console.log(this.building_id , this.building_type_id , this.housing_complex_id);
-          if(this.fristReport || this.secondReport || this.thirdReport){
-            this.showSearchBtn = true;
-          }
+       
           
       },
       err =>{
@@ -180,13 +178,10 @@ getBuildingID(event){
         unit_number:'أختار رقم الوحدة',
       });
 
-             if(this.reportValue == 1){
-            this.showSearchBtn = true;
-
-          }else{
+   
             if(x > 1)
             this.isUnit = true;
-          }
+          
 
     },
 
@@ -199,19 +194,18 @@ getBuildingID(event){
 }
 unitNum(event){
  this.unitId = event;
- this.showSearchBtn = true;
+
 
   }
 
   getReport(event){
     this.reportValue = event
+    this.showSearchBtn= true;
     this.showFilters = true;
     this.housing_complex_id = 'all';
-
     this.isComplex = false;
     this.isBuildingType = false;
     this.isUnit = false;
-    this.showSearchBtn = false;
     this.building_types = [];
     this.buildings = [];
     this.assigned_units = [];
@@ -231,7 +225,7 @@ unitNum(event){
       this.fristReport = false;
       this.thirdReport = false;
       this.fourthReport = false;
-      this.showSearchBtn = true;
+
       
       this.reportName ='تقرير السكان في المحمع و المباني'
 
@@ -240,7 +234,6 @@ unitNum(event){
       this.fristReport = false;
       this.secondReport = false;
       this.fourthReport = false;
-      this.showSearchBtn = true;
       this.placeholder = 'ادخل رقم هوية الموظف'
       this.searchValue = '';
       this.reportName ='تقرير ساكن'
@@ -250,7 +243,6 @@ unitNum(event){
       this.fristReport = false;
       this.secondReport = false;
       this.thirdReport = false;
-      this.showSearchBtn = true;
       this.placeholder = 'ادخل رقم او كود الوحدة'
       this.searchValue = '';
       this.reportName ='تقرير العهد'

+ 5 - 1
src/app/dashboard/main-menu/main-list/main-list.component.ts

@@ -261,7 +261,11 @@ export class MainListComponent implements OnInit {
               },
               (error) => {
                 console.log(error);
-                this.toastr.error('حدث خطأ رجاء الانتظار وحاول ثانيه');
+                if(error['error'].error == 'menu already used'){
+                  this.toastr.warning('لايمكن مسح القوائم المحدده ، لربطها بالنظام !');
+                } else {
+                  this.toastr.error('حدث خطأ رجاء الانتظار وحاول ثانيه');
+                }
                 this.spinner.hide();
               }
           )

+ 2 - 1
src/app/dashboard/record-info-building/record-info-building-add/record-info-building-add.component.html

@@ -5,7 +5,8 @@
       <div class="row">
         <div class="col-12">
           <ul class="list-unstyled titileLi-w">
-            <li class="headingText-w"> خدمه البلاغات </li>
+            <li class="headingText-w"> خدمه السكن </li>
+            <li class="headingText-w activeLi-w" style="margin-right:5px; cursor: pointer" (click)="authSer.backFromEdit()">تسجيل معلومات المجمعات السكنية</li>
             <li class="headingText-w activeLi-w" style="margin-right:5px"> {{typePage}} </li>
           </ul>
         </div>

+ 4 - 1
src/app/dashboard/record-info-building/record-info-building-list/record-info-building-list.component.ts

@@ -235,7 +235,7 @@ onDelete() {
       dialogRef.result
       .then( result =>
         this.dashboardSer.deleteItem(this.dataListIds , this.pageId).subscribe(
-          (responce) => {
+          (responce) => { 
             console.log(responce);
             this.toastr.success('تم الحذف');
             this.spinner.show();
@@ -258,6 +258,9 @@ onDelete() {
           (error) => {
             console.log(error);
             this.spinner.hide();
+            if(error.error.status == 'housing_complex already used'){
+              this.toastr.warning('لا يمكنك حذف المجمع السكني لانه جزء من النظام')
+            }
             },
           )
       );

+ 1 - 1
src/app/dashboard/sections/section-list/section-list.component.html

@@ -63,7 +63,7 @@
                   </div>
                 </td>
                 <td>{{section.name}}</td>
-                <td>{{section.department_name ? section.department_name : '-'}}</td>
+                <td>{{section.adminstration_name ? section.adminstration_name : '-'}}</td>
                 <td *ngIf="authSer.showEditBtn"><button type="button" class="btn btn-outline-secondary" (click)="onEdit(section.id)"><i class="fas fa-edit"></i></button></td>
               </tr>
             </tbody>

+ 3 - 0
src/app/dashboard/sections/section-list/section-list.component.ts

@@ -226,6 +226,9 @@ export class SectionListComponent implements OnInit {
             },
             (error) => {
               console.log(error);
+              if(error['error'].error == 'department already used') {
+                this.toastr.warning('لايمكن مسح الأقسام المحدده لربطها بالنظام !');
+              }
               this.spinner.hide();
             },
           )

+ 1 - 0
src/app/dashboard/unit-building-information/unit-building-information-add/unit-building-information-add.component.html

@@ -6,6 +6,7 @@
           <div class="col-12">
             <ul class="list-unstyled titileLi-w">
               <li class="headingText-w"> خدمه  السكن </li>
+              <li class="headingText-w activeLi-w" style="margin-right:5px;cursor: pointer;" (click)="authSer.backFromEdit()">تسجيل معلومات المباني</li>
               <li class="headingText-w activeLi-w" style="margin-right:5px"> {{typePage}} </li>
             </ul>
           </div>

+ 6 - 6
src/app/dashboard/unit-building-information/unit-building-information-list/unit-building-information-list.component.html

@@ -27,13 +27,13 @@
           <div class="col-12 col-sm-12 col-md-12 col-lg-3">
             <div class="form-group">
               <span class="spanSelect-w" style="margin-right:10px;">
+                  <select [ngModel]="dataTableNumber" class="form-control selectButton-w" (input)="onGetValue($event)">
+                    <option value="5">5</option>
+                    <option value="10">10</option>
+                    <option value="15">15</option>
+                    <option value="20">20</option>
+                  </select>
                   من العناصر يتم عرضها
-                <select [ngModel]="dataTableNumber" class="form-control selectButton-w" (input)="onGetValue($event)">
-                  <option value="5">5</option>
-                  <option value="10">10</option>
-                  <option value="15">15</option>
-                  <option value="20">20</option>
-                </select>
               </span>
             </div>
           </div>

+ 3 - 0
src/app/dashboard/unit-building-information/unit-building-information-list/unit-building-information-list.component.ts

@@ -411,6 +411,9 @@ export class UnitBuildingInformationListComponent implements OnInit {
             (error) => {
               console.log(error);
               this.spinner.hide();
+              if(error.error.status == 'unit is already assigned'){
+                this.toastr.warning('لا يمكنك حذف الوحدة السكني لانه جزء من النظام')
+              }
               },
             )
         );

+ 2 - 1
src/app/dashboard/unit-information/unit-information-add/unit-information-add.component.html

@@ -5,7 +5,8 @@
       <div class="row">
         <div class="col-12">
           <ul class="list-unstyled titileLi-w">
-            <li class="headingText-w"> خدمه البلاغات </li>
+            <li class="headingText-w"> خدمه السكن </li>
+            <li class="headingText-w activeLi-w" style="margin-right:5px ; cursor: pointer;" (click)="authSer.backFromEdit()">تسجيل معلومات المباني</li>
             <li class="headingText-w activeLi-w" style="margin-right:5px"> {{typePage}} </li>
           </ul>
         </div>

+ 4 - 0
src/app/dashboard/unit-information/unit-information-list/unit-information-list.component.ts

@@ -255,12 +255,16 @@ onDelete() {
               (error) => {
                 console.log(error);
                 this.spinner.hide();
+               
               }
             );
           },
           (error) => {
             console.log(error);
             this.spinner.hide();
+            if(error.error.status == 'building is already used'){
+              this.toastr.warning('لا يمكنك حذف المبنى السكني لانه جزء من النظام')
+            }
             },
           )
       );

+ 7 - 3
src/app/dashboard/users/form-user/form-user.component.html

@@ -101,6 +101,7 @@
               <div class="form-group">
                 <label for="password" style="float:right">كلمه المرور <span class="spanReqired-w" *ngIf="checkRequiredSpan">*</span></label>
                 <input type="password" id="password" class="form-control" placeholder="كلمه المرور" formControlName="password" />
+                <span class="help-block" *ngIf="password.errors?.minlength && signupForm.get('password').touched" style="color:red;font-size:12px"> من فضلك , أدخل كلمه مرور لاتقل عن 6 ارقام</span>
               </div>
             </div>
 
@@ -108,6 +109,7 @@
               <div class="form-group">
                 <label for="password_confirmation" style="float:right">تأكيد كلمه المرور <span class="spanReqired-w">*</span></label>
                 <input type="password" id="password_confirmation" placeholder="تأكيد كلمه المرور" class="form-control" formControlName="password_confirmation" minlength="6"/>
+                <span class="help-block" *ngIf="repeatPassword.errors?.minlength && signupForm.get('password_confirmation').touched" style="color:red;font-size:12px">من فضلك , أدخل كلمه مرور لاتقل عن 6 ارقام</span>
               </div>
             </div>
 
@@ -123,7 +125,9 @@
             <div class="col-12 col-sm-12 col-md-4 col-lg-4">
               <div class="form-group">
                 <label for="birthday" style="float:right">تاريخ الميلاد <span class="spanReqired-w">*</span></label>
-                <input type="date" [max]="authSer.end" id="birthdate" class="form-control" formControlName="birthday" /> 
+                <!-- <input type="date" [max]="authSer.end" id="birthdate" class="form-control" formControlName="birthday" />  -->
+                <app-end-higri-date *ngIf="higri_birth_date && typeMode"  (onDatePicked)="getDate($event, 'higri_birthDate')" [myEndDate]="higri_birth_date" [higriDisabled]="disabledVal"> </app-end-higri-date>
+                <app-end-higri-date *ngIf="!typeMode"  (onDatePicked)="getDate($event, 'higri_birthDate')"> </app-end-higri-date>
               </div>
             </div>
 
@@ -138,10 +142,10 @@
               <div class="form-group">
                 <label for="date_employment_hij" style="float:right" >تاريخ التوظيف الهجري <span class="spanReqired-w">*</span></label>
                 <div *ngIf='bindingDateSplit && typeMode'>
-                  <app-higri-date (onDatePicked)="getDate($event)" [myDate]="bindingDateSplit"></app-higri-date>
+                  <app-higri-date (onDatePicked)="getDate($event, 'higriEmployement')" [myDate]="bindingDateSplit"></app-higri-date>
                 </div>
                 <div *ngIf='!typeMode'>
-                  <app-higri-date (onDatePicked)="getDate($event)" ></app-higri-date>
+                  <app-higri-date (onDatePicked)="getDate($event, 'higriEmployement')" ></app-higri-date>
                 </div>
               </div>
             </div>

+ 39 - 16
src/app/dashboard/users/form-user/form-user.component.ts

@@ -64,6 +64,7 @@ export class FormUserComponent implements OnInit {
   checkUserType:number;
 
   end:any;
+  higri_birth_date;
 
   ngOnInit() {
     this.spineer.show();
@@ -182,6 +183,8 @@ export class FormUserComponent implements OnInit {
           this.userSer.onGetUserData(this.userID, 'editUs').subscribe(
             (responce) => {
               console.log('data user' , responce);
+              
+      
               if(responce['user'].type == '0') {
                 this.signupForm.patchValue(
                   {
@@ -193,7 +196,7 @@ export class FormUserComponent implements OnInit {
                     password_confirmation: responce['user'].password_confirmation,
                     phone: responce['user'].phone,
                     gender: responce['user'].gender,
-                    birthday: responce['user'].birthday,
+                    //birthday: responce['user'].birthday,
                     nationality_id: responce['user'].nationality_id,
                     date_of_employment_gre: responce['user'].date_of_employment_gre,
                     job_title_id: responce['user'].job_title_id,
@@ -216,7 +219,7 @@ export class FormUserComponent implements OnInit {
                     email: responce['user'].email,
                     phone: responce['user'].phone,
                     gender: responce['user'].gender,
-                    birthday: responce['user'].birthday,
+                    //birthday: responce['user'].birthday,
                     nationality_id: responce['user'].nationality_id,
                     status: responce['user'].status,
                     identity_type_id: responce['user'].identity_type_id,
@@ -228,15 +231,22 @@ export class FormUserComponent implements OnInit {
               this.urlImg = responce['user'].photo ? this.authSer.pathImg + responce['user'].photo : this.urlImg;
               console.log(this.urlImg);
               const date = responce['user'].date_of_employment_hij ? responce['user'].date_of_employment_hij.split('-') : '';
-            
+              const birthday_val = responce['user'].birthday ? responce['user'].birthday.split('-') : '';
               this.bindingDateSplit = {
                 'year': parseInt(date[0]),
                 'month': parseInt(date[1]),
                 'day': parseInt(date[2])
               };
+
+              this.higri_birth_date = {
+                'year': parseInt(birthday_val[0]),
+                'month': parseInt(birthday_val[1]),
+                'day': parseInt(birthday_val[2])
+              }
               
               this.higriDateVal = responce['user'].date_of_employment_hij;
               console.log(this.bindingDateSplit);
+              console.log('birth day => ', this.higri_birth_date);
               
               this.getDepartment();
               this.spineer.hide();
@@ -261,7 +271,7 @@ export class FormUserComponent implements OnInit {
         password_confirmation: new FormControl(null, [Validators.required, Validators.minLength(6)]),
         phone: new FormControl(null, Validators.required),
         gender: new FormControl(null, Validators.required),
-        birthday: new FormControl(null, Validators.required),
+        //birthday: new FormControl(null, Validators.required),
         adminstration_id: new FormControl(null, Validators.required),
         department_id: new FormControl(null, Validators.required),
         nationality_id: new FormControl(null, Validators.required),
@@ -288,7 +298,7 @@ export class FormUserComponent implements OnInit {
         password: new FormControl(null, [Validators.minLength(6)]),
         phone: new FormControl(null, Validators.required),
         gender: new FormControl(null, Validators.required),
-        birthday: new FormControl(null, Validators.required),
+        //birthday: new FormControl(null, Validators.required),
         adminstration_id: new FormControl(null, Validators.required),
         department_id: new FormControl(null, Validators.required),
         nationality_id: new FormControl(null, Validators.required),
@@ -305,10 +315,17 @@ export class FormUserComponent implements OnInit {
   }
 
   //get value date from child component 
-  public getDate(date: any):void {
+  public getDate(date: any, type: string):void {
     console.log( date);
-    this.higriDateVal = date.year + '-' + date.month + '-' + date.day;
-    console.log('higrii date', this.higriDateVal);
+    if(type == 'higri_birthDate'){
+      this.higri_birth_date = date.year + '-' + date.month + '-' + date.day;
+      console.log('higri_birth_date ', this.higri_birth_date);
+    } else if(type == 'higriEmployement') {
+      this.higriDateVal = date.year + '-' + date.month + '-' + date.day;
+      console.log('higrii date', this.higriDateVal);
+    } else {
+      console.log('no date is recieved !');
+    }
   }
 
 
@@ -320,6 +337,9 @@ export class FormUserComponent implements OnInit {
       (responce) => {
         console.log(responce);
         this.departments = responce['departments'];
+        if(this.departments.length == 0) {
+          this.toastr.warning('لا يوجد أقسام بهذه الإداره !');
+        }
         this.showDepart = true;
       }
     );
@@ -338,7 +358,7 @@ export class FormUserComponent implements OnInit {
         password: new FormControl(null, [Validators.required, Validators.minLength(6)]),
         password_confirmation: new FormControl(null, [Validators.required, Validators.minLength(6)]),
         gender: new FormControl(null, Validators.required),
-        birthday: new FormControl(null, Validators.required),
+        //birthday: new FormControl(null, Validators.required),
         nationality_id: new FormControl(null, Validators.required),
         phone: new FormControl(null, Validators.required),
         status: new FormControl(null , Validators.required),
@@ -355,7 +375,7 @@ export class FormUserComponent implements OnInit {
         password_confirmation: new FormControl(null, [Validators.required, Validators.minLength(6)]),
         phone: new FormControl(null, Validators.required),
         gender: new FormControl(null, Validators.required),
-        birthday: new FormControl(null, Validators.required),
+        //birthday: new FormControl(null, Validators.required),
         adminstration_id: new FormControl(null, Validators.required),
         department_id: new FormControl(null, Validators.required),
         nationality_id: new FormControl(null, Validators.required),
@@ -368,7 +388,9 @@ export class FormUserComponent implements OnInit {
         staff_id: new FormControl(null),
       });
     } 
-  }
+  };
+
+
 
 
 
@@ -381,13 +403,12 @@ export class FormUserComponent implements OnInit {
     let birthDate;
     if(userData['type'] == 0){
       userData['date_of_employment_hij'] = this.higriDateVal;
-       birthDate = userData['birthday'].split('-')[0];
+       birthDate = this.higri_birth_date;
+       userData['birthday'] = birthDate;
        joinJopYear = userData['date_of_employment_gre'].split('-')[0];
       console.log(joinJopYear);
     }
  
-   
-
     if(this.checkChangeImage) {
       userData['photo'] = this.imageBase64;
       userData['photo_type'] = this.photoType[1];
@@ -401,8 +422,10 @@ export class FormUserComponent implements OnInit {
         this.toastr.warning('من فضلك تأكد أن كلمه المرور هي نفس تأكيد كلمه المرور ');
         this.checkSaveDisabled = false;
       } else if(userData['date_of_employment_hij'] == "") {
-          this.toastr.warning('من فضلك ، أدخل تاريخ التوظيف الهجري !');
-          this.checkSaveDisabled = false;
+        this.toastr.warning('من فضلك ، أدخل تاريخ التوظيف الهجري !');
+        this.checkSaveDisabled = false;
+     } else if(!birthDate){
+        this.toastr.warning('من فضلك أدخل تاريخ الميلاد !');
      } else if(this.signupForm.get('identity_number').value.substring(0,1) != 1 && this.signupForm.get('identity_type_id').value == 1){
         this.toastr.warning('رقم الهويه يجب ان يبدأ ب رقم 1');
         this.checkSaveDisabled = false;

+ 6 - 1
src/app/dashboard/users/users.component.ts

@@ -311,7 +311,12 @@ export class UsersComponent implements OnInit {
               }
               
             },
-            (error) => {console.log(error)},
+            (error) => {
+              console.log(error);
+              if(error['error'].error == 'user already used') {
+                this.toastr.warning('لايمكن مسح المستخدمين المحددين لإرتباطهم بالنظام !');
+              }
+            },
           )
         );
       } else {

+ 4 - 3
src/app/dashboard/view_my_female_requests/view-my-female-requests-add/view-my-female-requests-add.component.html

@@ -5,14 +5,15 @@
         <div class="row">
           <div class="col-12">
             <ul class="list-unstyled titileLi-w">
-              <li class="headingText-w"> خدمه البلاغات </li>
-              <li class="headingText-w activeLi-w" style="margin-right:5px"> {{typePage}} </li>
+              <li class="headingText-w"> خدمه السكن </li>
+              <li class="headingText-w activeLi-w" style="margin-right:5px; cursor: pointer;" (click)="authSer.backFromEdit()">عرض طلبات المستأجر للأدارة</li>
+              <li class="headingText-w activeLi-w" style="margin-right:5px">تفاصيل الطلب</li>
             </ul>
           </div>
         </div>
   
       <div class="containerContent-w">
-        <h2 class="title"  style="margin: auto ;text-align:  center" [ngClass]="{'green': statusAccept, 'red' : statusrefu}">{{ statusAccept ? 'مقبول' : statusrefu  ? 'مرفوض' : ' جديد'}}</h2>
+        <h2 class="title"  style="margin: auto ;text-align:  center" [ngClass]="{'green': statusAccept, 'red' : statusrefu}">{{comfoe}}</h2>
           <form (ngSubmit)="onSubmitted()" #f="ngForm" style="margin-top: 40px;">
               <div class="row">
                   <div class="col-12" >

+ 16 - 4
src/app/dashboard/view_my_female_requests/view-my-female-requests-add/view-my-female-requests-add.component.ts

@@ -36,6 +36,7 @@ export class ViewMyFemaleRequestsAddComponent implements OnInit {
   refusedCheak = false;
   statusAccept : boolean;
   statusrefu: boolean;
+  comfoe: string;
   toster: string;
   tookDes = false;
   employeeId: string;
@@ -117,9 +118,7 @@ export class ViewMyFemaleRequestsAddComponent implements OnInit {
       
     }
   );
-    if(this.whoIsComing == 'AD74'){
-      this.isAdmin = true;
-    }
+  
 
   console.log('current page',this.pageId)
   this.dashBoardSer.getRequestTypesList( 1 ,10000 , 'all', 'all', 'all').subscribe(
@@ -146,16 +145,29 @@ export class ViewMyFemaleRequestsAddComponent implements OnInit {
         if(this.isAdmin){
           this.adminForm.request_id = data.id;
         }
+        
         this.adminForm.status = data.status;
         if(this.adminForm.status != 'new'){
           this.tookDes = true;
-          if(this.adminForm.status == 'accepted'){
+          if(this.adminForm.status == 'accepted' || this.adminForm.status == 'confirmed'){
             this.statusAccept = true;
+            if(this.adminForm.status == 'accepted'){
+              this.comfoe = 'مقبول'
+            }else{
+              this.comfoe = 'مؤكد'
+            }
           }else if(this.adminForm.status == 'refused'){
             this.adminForm.status_description = data.status_description;
             this.statusAccept = false;
             this.statusrefu = true;
             this.refusedCheak = true;
+            this.comfoe = 'مرفوض'
+          }
+        }else{
+          this.comfoe = 'جديد'
+          if(this.whoIsComing == 'AD74'){
+            this.isAdmin = true;
+            
           }
         }
         this.employeeId = data.employee_id;

+ 10 - 10
src/app/dashboard/view_my_female_requests/view-my-female-requests-list/view-my-female-requests-list.component.html

@@ -4,7 +4,7 @@
       <div class="col-12">
         <ul class="list-unstyled titileLi-w">
           <li class="headingText-w">خدمه السكن  </li>
-          <li class="headingText-w activeLi-w" style="margin-right:5px">عرض الطلبات </li>
+          <li class="headingText-w activeLi-w" style="margin-right:5px">عرض طلبات المستأجر للأدارة</li>
         </ul>
       </div>
     </div>
@@ -24,20 +24,20 @@
       </div>
   
       <div class="row">
-          <div class="col-6 col-sm-12 col-md-12 col-lg-6">
+          <div class="col-6 col-sm-12 col-md-12 col-lg-3">
             <div class="form-group">
               <span class="spanSelect-w" style="margin-right:10px;">
+                  <select [ngModel]="dataTableNumber" class="form-control selectButton-w" (input)="onGetValue($event)">
+                    <option value="5">5</option>
+                    <option value="10">10</option>
+                    <option value="15">15</option>
+                    <option value="20">20</option>
+                  </select>
                   من العناصر يتم عرضها
-                <select [ngModel]="dataTableNumber" class="form-control selectButton-w" (input)="onGetValue($event)">
-                  <option value="5">5</option>
-                  <option value="10">10</option>
-                  <option value="15">15</option>
-                  <option value="20">20</option>
-                </select>
               </span>
             </div>
           </div>
-          <div class="col-6 col-sm-12 col-md-12 col-lg-6">
+          <div class="col-6 col-sm-12 col-md-12 col-lg-3">
               <div class="form-group">
                 <span class="spanSelect-w" style="margin-right:10px;">
                     الحالة
@@ -67,7 +67,7 @@
             <th *ngIf="accept">نوع الطلب</th>
             <th>الحاله</th>
             
-            <th *ngIf="authSer.showEditBtn">تعديل</th>
+            <th *ngIf="authSer.showEditBtn">التفاصيل</th>
           </tr>
         </thead>
         <tbody>

+ 2 - 1
src/app/dashboard/view_requests_for_adminstration/view-requests-for-adminstration-details/view-requests-for-adminstration-details.component.html

@@ -5,7 +5,8 @@
       <div class="col-12">
         <ul class="list-unstyled titileLi-w">
           <li class="headingText-w" style="cursor: pointer;" (click)="authSer.perviousLocation()">خدمه السكن</li>
-          <li class="headingText-w activeLi-w" style="margin-right:5px">  طلب سكن</li>
+          <li class="headingText-w activeLi-w" style="margin-right:5px;cursor: pointer;" (click)="authSer.backFromEdit()">عرض الطلبات للإدارة</li>
+          <li class="headingText-w activeLi-w" style="margin-right:5px"> تفاصيل الطلب</li>
         </ul>
       </div>
     </div>

+ 8 - 8
src/app/dashboard/view_requests_for_adminstration/view-requests-for-adminstration-list/view-requests-for-adminstration-list.component.html

@@ -24,20 +24,20 @@
     </div>
 
     <div class="row">
-        <div class="col-6 col-sm-12 col-md-12 col-lg-6">
+        <div class="col-6 col-sm-12 col-md-12 col-lg-3">
           <div class="form-group">
             <span class="spanSelect-w" style="margin-right:10px;">
+                <select [ngModel]="dataTableNumber" class="form-control selectButton-w" (input)="onGetValue($event)">
+                  <option value="5">5</option>
+                  <option value="10">10</option>
+                  <option value="15">15</option>
+                  <option value="20">20</option>
+                </select>
                 من العناصر يتم عرضها
-              <select [ngModel]="dataTableNumber" class="form-control selectButton-w" (input)="onGetValue($event)">
-                <option value="5">5</option>
-                <option value="10">10</option>
-                <option value="15">15</option>
-                <option value="20">20</option>
-              </select>
             </span>
           </div>
         </div>
-        <div class="col-6 col-sm-12 col-md-12 col-lg-6">
+        <div class="col-6 col-sm-12 col-md-12 col-lg-3">
           <div class="form-group">
             <span class="spanSelect-w" style="margin-right:10px;">
                 الحالة

+ 1 - 0
src/app/dashboard/view_requests_for_tenant/view-requests-for-tenant-details/view-requests-for-tenant-details.component.html

@@ -5,6 +5,7 @@
       <div class="col-12">
         <ul class="list-unstyled titileLi-w">
           <li class="headingText-w" style="cursor: pointer;" (click)="authSer.perviousLocation()">خدمه السكن</li>
+          <li class="headingText-w activeLi-w" style="margin-right:5px; cursor: pointer;" (click)="authSer.backFromEdit()">عرض الطلبات </li>
           <li class="headingText-w activeLi-w" style="margin-right:5px">  طلب سكن</li>
         </ul>
       </div>

+ 8 - 8
src/app/dashboard/view_requests_for_tenant/view-requests-for-tenant/view-requests-for-tenant.component.html

@@ -24,20 +24,20 @@
     </div>
 
     <div class="row">
-        <div class="col-6 col-sm-12 col-md-12 col-lg-6">
+        <div class="col-6 col-sm-12 col-md-12 col-lg-3">
           <div class="form-group">
             <span class="spanSelect-w" style="margin-right:10px;">
+                <select [ngModel]="dataTableNumber" class="form-control selectButton-w" (input)="onGetValue($event)">
+                  <option value="5">5</option>
+                  <option value="10">10</option>
+                  <option value="15">15</option>
+                  <option value="20">20</option>
+                </select>
                 من العناصر يتم عرضها
-              <select [ngModel]="dataTableNumber" class="form-control selectButton-w" (input)="onGetValue($event)">
-                <option value="5">5</option>
-                <option value="10">10</option>
-                <option value="15">15</option>
-                <option value="20">20</option>
-              </select>
             </span>
           </div>
         </div>
-        <div class="col-6 col-sm-12 col-md-12 col-lg-6">
+        <div class="col-6 col-sm-12 col-md-12 col-lg-3">
           <div class="form-group">
             <span class="spanSelect-w" style="margin-right:10px;">
                 الحالة

+ 0 - 3
src/app/end-higri-date/end-higri-date.component.ts

@@ -61,8 +61,5 @@ export class EndHigriDateComponent implements OnInit {
     this.onDatePicked.emit(date);
   }
  
- 
-
-
 
 }

+ 0 - 1
src/app/higri-date/higri-date.component.ts

@@ -41,7 +41,6 @@ export class HigriDateComponent implements OnInit {
   
   @Output() onDatePicked: EventEmitter<NgbDate> = new EventEmitter<NgbDate>();
   @Input() myDate;
-  @Input() myDate2;
   @Input() higriDisabled;
 
   model: NgbDateStruct;

+ 1 - 0
src/app/shared/dashboard.service.ts

@@ -34,6 +34,7 @@ export class DashboardService {
       return this.http.get(this.authService.pathApi + '/housing_requests_list/'+ currentPage +'/' + dataTableNumber  +'/' +to_whom + '/' + status);
     }
     getRequestTypesList(currentPage: number, dataTableNumber: number, require_attachments: any , require_approval: any, require_date:any){
+      this.spinner.show();
       return this.http.get(this.authService.pathApi + '/request_types_list/'+ currentPage +'/' + dataTableNumber  +'/' +require_attachments + '/' + require_approval + '/' + require_date);
 
     }

+ 4 - 1
src/app/shared/shared.module.ts

@@ -6,13 +6,16 @@ import { OnlyNumberDirective } from './only-number.directive';
 import { NumberDirective } from './number.directive';
 
 
+
 @NgModule({
   declarations: [
     OnlyNumberDirective,
     EnglishCharactersDirective,
     //CeiboShare,
     NumberDirective,
-  ],
+    
+    ]
+    ,
   exports: [
     CommonModule,
     OnlyNumberDirective,