Prechádzať zdrojové kódy

button name, token flags, filter lock changed

Devansh Vakharia 1 týždeň pred
rodič
commit
fa1f74dd2f

+ 35 - 12
src/app/contact/contact.component.html

@@ -172,14 +172,22 @@
                                     </div> -->
 
                                     <div class="form-group" [ngClass]="displayFieldCss('designation')">
-                                        <input type="text" class="form-control" formControlName='designation'
-                                            name="designation" id="designation">
-                                        <label for="Desg." class="animated-label">Designation<span style="color: red;"> *</span></label>
+                                        <!-- <input type="text" class="form-control" formControlName='designation'
+                                            name="designation" id="designation"> -->
+                                        <!-- <label for="Desg." class="animated-label">Designation<span style="color: red;"> *</span></label> -->
+                                        <select id="designation" class="form-control" formControlName="designation">
+                                            <option value="" disabled selected>Select</option>
+                                            <option *ngFor="let desig of designations" [ngValue]="desig">
+                                                {{ desig }}
+                                            </option>
+                                        </select>
+                                        <label class="animated-label">Designation<span style="color: red;"> *</span></label>
+
+                                        </div>
+
                                         <app-field-error-display [displayError]="isFieldValid('designation')"
                                             errorMsg="Please enter Designation">
                                         </app-field-error-display>
-                                    </div>
-
                                 </div>
                             </div>
 
@@ -200,10 +208,17 @@
 
                                 </div>
                                 <div class="col-lg-3">
-                                    <!-- <label class="animated-label">Department<span style="color: red;"> *</span></label> -->
                                     <div class="form-group">
-                                        <input type="text" class="form-control " formControlName='department' name="department">
-                                        <label class="animated-label">Department<span style="color: red;"> *</span></label>                                        
+                                        <!-- <input type="text" class="form-control " formControlName='department' name="department">
+                                        <label class="animated-label">Department<span style="color: red;"> *</span></label> -->
+                                        <select id="department" class="form-control" formControlName="department">
+                                            <option value="" disabled selected>Select</option>
+                                            <option *ngFor="let depart of departments" [ngValue]="depart">
+                                                {{ depart }}
+                                            </option>
+
+                                    </select>
+                                    <label class="animated-label">Department<span style="color: red;"> *</span></label>
                                     </div>
                                     <!-- <select id="Axis" class="form-control" formControlName='department'
                                         style="margin-top: 0px;">
@@ -219,9 +234,17 @@
                                 </div>
                                 <div class="col-lg-3">
                                     <div class="form-group">
-                                        <input type="text" class="form-control " formControlName='function'
+                                        <!-- <input type="text" class="form-control " formControlName='function'
                                             name="function">
+                                        <label class="animated-label">Function<span style="color: red;"> *</span></label> -->
+                                        <select id="function" class="form-control" formControlName="function">
+                                            <option value="" disabled selected>Select</option>
+                                            <option *ngFor="let funct of functions" [ngValue]="funct">
+                                                {{ funct }}
+                                            </option>
+                                        </select>
                                         <label class="animated-label">Function<span style="color: red;"> *</span></label>
+   
                                     </div>
                                     <app-field-error-display [displayError]="isFieldValid('function')"
                                         errorMsg="Please enter Functional Area">
@@ -260,16 +283,16 @@
         <div class="col-lg-8 col-md-8">
         </div>
 
-        <div class="col-lg-1 col-sm-12 col-md-2" style="margin-bottom:6px; margin-right: 12px;">
+        <div class="col-lg-1 col-sm-12 col-md-2" *ngIf="isEditMode" style="margin-bottom:6px;">
             <!-- EDIT / UPDATE BUTTON -->
             <button class="submitbutton" *ngIf="role === 'admin'"
                     type="button" (click)="onEditButtonClick()" 
                     [style.background-color]="isEditMode ? '#f9b523' : 'grey'">
-                {{ isEditMode ? 'Edit' : 'Edit' }}
+                {{ isEditMode ? 'Save' : 'Save' }}
             </button>
         </div>
 
-        <div class="col-lg-1 col-sm-12 col-md-2" style="margin-bottom:6px;">
+        <div class="col-lg-1 col-sm-12 col-md-2" *ngIf="!isEditMode" style="margin-bottom:6px;">
             <!-- SAVE / SUBMIT BUTTON -->
             <input class="submitbutton" 
                    type="submit" 

+ 37 - 7
src/app/contact/contact.component.ts

@@ -53,7 +53,9 @@ selectedCustomerFilter: string = ''; // Holds the name selected in the new filte
   dtOptions = {};
   dtTrigger: Subject<any> = new Subject();
 
-
+  designations = ["Executive","AM","Manager","Senior Manager","GM","AGM","PMO","DVP","AVP","VP","SVP","EVP","Head","CTO","CIO","CISO","CFO","President","Director","Managing Director","CEO"];
+  functions = ["Infra","Cloud","Devops","Digital Transformation","Applications","Testing","Vendor Management","Procurement","Finance","Audit","Business Systems","Quality Assurance", "Buiness Solutions Group"];
+  departments = ["IT","Procurement","Finance","Business"];
 
   sucess_flag: boolean = false;
   backtodvr_flag: boolean = false;
@@ -71,6 +73,14 @@ selectedCustomerFilter: string = ''; // Holds the name selected in the new filte
   constructor(private commonservice: CommonFunctionService, private router: Router, private fb: FormBuilder) {
 
  this.dtOptions = {
+  stateSave: true,   // 👈 ADD THIS
+  stateSaveCallback: function(settings, data) {
+    localStorage.setItem('customerTableState', JSON.stringify(data));
+  },
+  stateLoadCallback: function(settings) {
+    return JSON.parse(localStorage.getItem('customerTableState'));
+  },
+  stateDuration: -1, // 👈 keeps forever (uses localStorage)
   pagingType: 'full_numbers',
   pageLength: 15,
   processing: true,
@@ -158,6 +168,26 @@ initComplete: function(settings: any, json: any) {
       dropdown.append(checkbox);
     });
 
+    
+    
+    // Restore saved search
+    const savedSearch = column.search();
+
+    if (savedSearch) {
+      const values = savedSearch.split('|')
+        .map(v => v.replace(/^\^|\$$/g, '')); // remove ^ and $
+
+      dropdown.find('input[type=checkbox]').not('[value="all"]').each(function () {
+        const val = $(this).val()?.toString();
+        $(this).prop('checked', values.includes(val));
+      });
+
+      const total = dropdown.find('input[type=checkbox]').not('[value="all"]').length;
+      const checkedCount = dropdown.find('input[type=checkbox]:checked').not('[value="all"]').length;
+
+      allCheckbox.find('input').prop('checked', checkedCount === total);
+    }
+
     // --- Checkbox handling ---
     dropdown.on('change', 'input[type=checkbox]', function () {
       const allChecked = allCheckbox.find('input').prop('checked');
@@ -240,7 +270,7 @@ $(document).on('click', function () {
 
       this.cont_name = result;
       this.commonservice.getAllData(this.commonservice.projectpath + "/getcustcontactdetails?customer_id=" + this.cont_name).subscribe(response => {
-        if (response.status == 'falsetoken') {
+        if (response.status == 'tokenfalse') {
           this.router.navigate(['/login'])
         } else {
           console.log("aaaaaaaaaaa", this.contactList);
@@ -289,7 +319,7 @@ $(document).on('click', function () {
       this.contnav_flag = false;
 
       this.commonservice.getAllData(this.commonservice.projectpath + "/getcustcontactdetails?customer_id=0&passid=number").subscribe(response => {
-        if (response.status == 'falsetoken') {
+        if (response.status == 'tokenfalse') {
           this.router.navigate(['/login'])
         } else {
           this.contactList = response.data[0].conrtactData;
@@ -326,7 +356,7 @@ $(document).on('click', function () {
     }
 
     this.commonservice.getAllData(this.commonservice.projectpath + "/getselectionData").subscribe(response => {
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
       } else {
         // this.cust_data = response.data[0].customerData;
@@ -435,7 +465,7 @@ $(document).on('click', function () {
 
           console.log("in create contact response=========>", response);
 
-          if (response.status == 'falsetoken') {
+          if (response.status == 'tokenfalse') {
             this.router.navigate(['/login'])
           } else {
             // console.log("response", response);
@@ -540,7 +570,7 @@ $(document).on('click', function () {
 
           console.log("response", response);
 
-          if (response.status == 'falsetoken') {
+          if (response.status == 'tokenfalse') {
             this.router.navigate(['/login'])
           } else {
             // console.log("response", response);
@@ -867,7 +897,7 @@ modo(value: any) {
 
 //     // 1. Call the API to get the new, filtered data
 //     this.commonservice.getAllData(this.commonservice.projectpath + "/getcustcontactdetails?customer_id=" + id + "&passid=number").subscribe(response => {
-//         if (response.status == 'falsetoken') {
+//         if (response.status == 'tokenfalse') {
 //             this.router.navigate(['/login']);
 //         } else {
 //             // 2. Assign the new data

+ 19 - 18
src/app/createentry/dvrentry.component.ts

@@ -74,9 +74,6 @@ export class DvrEntryComponent implements OnInit, OnDestroy {
 
   checkoperationflag: boolean = false;
   checkdataflag: boolean;
-
-
-
   entry_successflag: boolean = false;
   second_contact: any;
 
@@ -234,6 +231,12 @@ export class DvrEntryComponent implements OnInit, OnDestroy {
 
     }
 
+    this.logindata.push(JSON.parse(localStorage.getItem("loginData")));
+    this.username = this.logindata[0]["user_name"];
+    this.last_login_date = this.logindata[0]["last_loginDate"];
+    this.login_id = this.logindata[0]["user_id"];
+    this.role = this.logindata[0]["role"];
+    console.log(" this.logindata=========>", this.login_id, this.role);
 
 
 
@@ -292,18 +295,16 @@ export class DvrEntryComponent implements OnInit, OnDestroy {
     // this.mincurrent_date = yyyy + '-' + min_mm + '-' + dd1;
     this.mincurrent_date = yyyy + '-' + min_mm + '-' + date;
 
+    console.log(this.role);
+    if (this.role == 'admin') {
+      this.mincurrent_date = '2024-01-01'; // Temporary fix, min date reset
+    }
+
     console.log("min date------>", this.mincurrent_date);
     document.getElementById("Date").setAttribute("min", this.mincurrent_date);
 
-    this.logindata.push(JSON.parse(localStorage.getItem("loginData")));
-    this.username = this.logindata[0]["user_name"];
-    this.last_login_date = this.logindata[0]["last_loginDate"];
-    this.login_id = this.logindata[0]["user_id"];
-    this.role = this.logindata[0]["role"];
-    console.log(" this.logindata=========>", this.login_id, this.role);
-
     this.commonservice.getAllData(this.commonservice.projectpath + "/getselectionData").subscribe(response => {
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
 
       }
@@ -334,7 +335,7 @@ export class DvrEntryComponent implements OnInit, OnDestroy {
     });
 
     this.commonservice.getAllData(this.commonservice.projectpath + "/getlastestdvr?role=" + this.role + "&login_id=" + this.login_id).subscribe(response => {
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
 
       } else {
@@ -525,7 +526,7 @@ export class DvrEntryComponent implements OnInit, OnDestroy {
       this.commonservice.updateData(this.commonservice.projectpath + "/updateDvrEntry", createdvr).subscribe(response => {
         this.status_msg = "";
         this.error_msg = "";
-        if (response.status == 'falsetoken') {
+        if (response.status == 'tokenfalse') {
           this.router.navigate(['/login'])
         } else {
           console.log("response.error", response.error);
@@ -615,7 +616,7 @@ export class DvrEntryComponent implements OnInit, OnDestroy {
         this.status_msg = "";
         this.error_msg = "";
 
-        if (response.status == 'falsetoken') {
+        if (response.status == 'tokenfalse') {
           this.router.navigate(['/login'])
         } else {
           console.log("response.error", response.error);
@@ -689,7 +690,7 @@ export class DvrEntryComponent implements OnInit, OnDestroy {
 
     this.commonservice.getAllData(this.commonservice.projectpath + "/getlastestdvr?role=" + this.role + "&login_id=" + this.login_id).subscribe(response => {
 
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
       } else {
         // console.log("response-------->", response);
@@ -801,7 +802,7 @@ export class DvrEntryComponent implements OnInit, OnDestroy {
     console.log("form value", form.value.custName.customer_name);
     if (form.value.custName) {
       this.commonservice.getAllData(this.commonservice.projectpath + "/getcustcontactdetails?customer_id=" + form.value.custName.customer_name).subscribe(response => {
-        if (response.status == 'falsetoken') {
+        if (response.status == 'tokenfalse') {
           this.router.navigate(['/login'])
         } else {
           this.contact_data = response.data[0].conrtactData;
@@ -878,7 +879,7 @@ export class DvrEntryComponent implements OnInit, OnDestroy {
 
       console.log("response", response);
 
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
       } else {
         console.log("response", response);
@@ -964,7 +965,7 @@ export class DvrEntryComponent implements OnInit, OnDestroy {
     if (form.value.postion != null) {
       console.log("postion", form.value.postion)
       this.commonservice.getAllData(this.commonservice.projectpath + "/mappingFuncIDToPersonNames?func_id=" + form.value.postion.func_id).subscribe(response => {
-        if (response.status == 'falsetoken') {
+        if (response.status == 'tokenfalse') {
           this.router.navigate(['/login'])
         } else {
           console.log("response:::::::::::::::::::::::::::::::::::::::::::::::::", response.data)

+ 10 - 0
src/app/customer/customer.component.css

@@ -92,3 +92,13 @@ th{background: #ffe8cb !important;}
 .sort-btn:hover, .filter-btn:hover {
   color: #007bff;
 }
+
+.mapping-right {
+  text-align: right;
+}
+
+.mapping-message {
+  margin-top: 6px;
+  font-size: 13px;
+  color: #6c757d;
+}

+ 25 - 17
src/app/customer/customer.component.html

@@ -137,33 +137,28 @@
 
                             <div class="row text-lg-right">
                                 <div class="col-lg-12 row">
-                                                <div class="col-lg-1 col-sm-12 col-md-2" style="margin-bottom:6px;">
+
+                                                
+                                                <div class="col-lg-1 col-sm-12 col-md-2" *ngIf="isEditMode" style="margin-bottom:6px;">
                                                     <!-- EDIT / UPDATE BUTTON -->
                                                     <button class="submitbutton" 
                                                             type="button" 
                                                             (click)="onEditButtonClick()" 
                                                             [style.background-color]="isEditMode ? '#f9b523' : 'grey'">
-                                                        {{ isEditMode ? 'Edit' : 'Edit' }}
+                                                        {{ isEditMode ? 'Add' : 'Add' }}
                                                     </button>
                                                 </div>
+ 
+                                    <div class="col-lg-1 col-sm-12 col-md-2" *ngIf="!isEditMode" style="margin-bottom:6px">
 
-
-
-                                    <div class="col-lg-1 col-sm-12 col-md-2" style="margin-bottom:6px;">
-                                                    <!-- EDIT / UPDATE BUTTON -->
-                                                    <button class="submitbutton" 
+                                        <!-- <input class="submitbutton" type="submit" value="Save New Customer"
+                                        [style.background-color]="!isEditMode ? '#f9b523' : 'grey'" > -->
+                                        <button class="submitbutton" 
                                                             type="button" 
-                                                            (click)="onAddButtonClick()" 
-                                                            [style.background-color]="isAddMode ? '#f9b523' : 'grey'">
-                                                        {{ isAddMode ? 'Add' : 'Add' }}
+                                                            (click)="customerData(customerForm)" 
+                                                            [style.background-color]="!isEditMode ? '#f9b523' : 'grey'">
+                                                        {{ isEditMode ? 'Add' : 'Add' }}
                                                     </button>
-                                                </div>
-
- 
-                                    <div class="col-lg-1 col-sm-12 col-md-2" style="margin-bottom:6px">
-
-                                        <input class="submitbutton" type="submit" value="Save"
-                                        [style.background-color]="!isEditMode ? '#f9b523' : 'grey'" >
                                     </div>
 
 
@@ -172,6 +167,19 @@
                                              (click)="reset()">
                                     </div>
 
+                                    <div class="col-lg-3 offset-lg-5 col-sm-12 col-md-2" style="margin-bottom:6px; text-align:right;">
+
+                                                    <button class="submitbutton" 
+                                                            type="button" 
+                                                            (click)="onAddButtonClick()" 
+                                                            [style.background-color]="isAddMode ? '#f9b523' : 'grey'">
+                                                        {{ isAddMode ? 'New Mapping' : 'New Mapping' }}
+                                                    </button>
+                                                        <!-- Fixed message below -->
+                                                    <div style="font-size:13px; margin-top:4px; color:#6c757d;">
+                                                        Map existing customer to another user.
+                                                    </div>
+                                                </div>
 
                                 </div>
 

+ 36 - 8
src/app/customer/customer.component.ts

@@ -62,6 +62,15 @@ export class CustomerComponent implements OnInit {
 
 
     this.dtOptions = {
+      stateSave: true,   // 👈 ADD THIS
+      stateSaveCallback: function(settings, data) {
+        localStorage.setItem('customerTableState', JSON.stringify(data));
+      },
+      stateLoadCallback: function(settings) {
+        return JSON.parse(localStorage.getItem('customerTableState'));
+      },
+
+      stateDuration: -1, // 👈 keeps forever (uses localStorage)
       // paging: true,
       pagingType: 'full_numbers',
       pageLength: 15,
@@ -136,6 +145,25 @@ export class CustomerComponent implements OnInit {
       dropdown.append(checkbox);
     });
 
+    
+    // Restore saved search
+    const savedSearch = column.search();
+
+    if (savedSearch) {
+      const values = savedSearch.split('|')
+        .map(v => v.replace(/^\^|\$$/g, '')); // remove ^ and $
+
+      dropdown.find('input[type=checkbox]').not('[value="all"]').each(function () {
+        const val = $(this).val()?.toString();
+        $(this).prop('checked', values.includes(val));
+      });
+
+      const total = dropdown.find('input[type=checkbox]').not('[value="all"]').length;
+      const checkedCount = dropdown.find('input[type=checkbox]:checked').not('[value="all"]').length;
+
+      allCheckbox.find('input').prop('checked', checkedCount === total);
+    }
+
     // --- Checkbox handling ---
     dropdown.on('change', 'input[type=checkbox]', function () {
       const allChecked = allCheckbox.find('input').prop('checked');
@@ -216,7 +244,7 @@ $(document).on('click', function () {
     this.role = this.loginData[0]["role"];
 
     this.commonservice.getAllData(this.commonservice.projectpath + "/getselectionData").subscribe(response => {
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
       } else {
         this.cust_data = response.data[0].customerData;
@@ -228,7 +256,7 @@ $(document).on('click', function () {
     });
 
     this.commonservice.getAllData(this.commonservice.projectpath + "/getsalepersonlist").subscribe(response => {
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
 
       }
@@ -266,7 +294,7 @@ $(document).on('click', function () {
 
       console.log("response", response);
 
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
       } else {
         console.log("response", response);
@@ -422,7 +450,7 @@ addTask(customerId: string, userId: string) {
 
       console.log("response", response);
 
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
       } else {
         console.log("response", response);
@@ -444,7 +472,7 @@ addTask(customerId: string, userId: string) {
 
           } else {
             this.status_msg = "Warning";
-            this.error_msg = response.data[0].message;
+            this.error_msg = response.data[0].message || response.error;
             this.openPopup();
           }
         }
@@ -469,7 +497,7 @@ addTask(customerId: string, userId: string) {
 
       console.log("response", response);
 
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
       } else {
         console.log("response", response);
@@ -575,7 +603,7 @@ addTask(customerId: string, userId: string) {
 
 
     this.commonservice.getAllData(this.commonservice.projectpath + "/getcustcontactdetails?customer_id=" + id + "&passid=number").subscribe(response => {
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
       } else {
 
@@ -622,7 +650,7 @@ addTask(customerId: string, userId: string) {
   reset(){
     this.resetflag=true;
     this.isEditMode = false;
-    this.isAddMode = false;
+    this.isAddMode = true;
     this.customerForm.reset();
   }
 }

+ 20 - 20
src/app/home/home.component.ts

@@ -133,7 +133,7 @@ export class HomeComponent implements OnInit {
 
 
     this.commonservice.getAllData(this.commonservice.projectpath + "/getsalepersonlist").subscribe(response => {
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
 
       }
@@ -166,7 +166,7 @@ export class HomeComponent implements OnInit {
     }
 
     this.commonservice.getAllData(this.commonservice.projectpath + "/getselectionData").subscribe(response => {
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
 
       }
@@ -284,7 +284,7 @@ export class HomeComponent implements OnInit {
     console.log("dvrlist", this.dvrList);
     this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=" + searchfilter + "&login_id=" + this.user_id).subscribe(response => {
 
-      if (response.status == 'falsetoken') {
+      if (response.status == 'tokenfalse') {
         this.router.navigate(['/login'])
 
 
@@ -394,7 +394,7 @@ export class HomeComponent implements OnInit {
       if (this.sale_person != undefined && this.customer == undefined && this.startDate == "" && this.endDate == "" && this.sale_person != 'undefined') {
         console.log("only sales person");
         this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=undefineddate&login_id=" + this.user_id + "&salePerson=" + this.sale_person).subscribe(response => {
-          if (response.status == 'falsetoken') {
+          if (response.status == 'tokenfalse') {
             this.router.navigate(['/login'])
           } else {
             if (response.data[0].getdvrDataStatus == '0') {
@@ -437,7 +437,7 @@ export class HomeComponent implements OnInit {
       else if (this.sale_person == undefined && this.customer != undefined && this.endDate == "" && this.startDate == "" && this.sale_person != 'undefined' && this.customer != 'undefined') {
         console.log("only customer")
         this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=undefineddate&login_id=" + this.user_id + "&customer=" + this.customer.customer_name + "&customerid=" + this.customer.customer_id).subscribe(response => {
-          if (response.status == 'falsetoken') {
+          if (response.status == 'tokenfalse') {
             this.router.navigate(['/login'])
           } else {
             if (response.data[0].getdvrDataStatus == '0') {
@@ -479,7 +479,7 @@ export class HomeComponent implements OnInit {
       } else if (this.sale_person != undefined && this.customer != undefined && this.endDate == "" && this.startDate == "" && this.sale_person != 'undefined') {
         console.log("for sales person and customer");
         this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=undefineddate&login_id=" + this.user_id + "&customer=" + this.customer.customer_name + "&salePerson=" + this.sale_person + "&customerid=" + this.customer.customer_id).subscribe(response => {
-          if (response.status == 'falsetoken') {
+          if (response.status == 'tokenfalse') {
             this.router.navigate(['/login'])
           } else {
             if (response.data[0].getdvrDataStatus == '0') {
@@ -520,7 +520,7 @@ export class HomeComponent implements OnInit {
       } else if (this.sale_person != undefined && this.customer == undefined && this.startDate != "" && this.endDate != "" && this.sale_person != 'undefined') {
         console.log("for date and sales_person")
         this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=" + searchfilter + "&login_id=" + this.user_id + "&salePerson=" + this.sale_person).subscribe(response => {
-          if (response.status == 'falsetoken') {
+          if (response.status == 'tokenfalse') {
             this.router.navigate(['/login'])
           } else {
 
@@ -565,7 +565,7 @@ export class HomeComponent implements OnInit {
       } else if (this.sale_person == undefined && this.customer != undefined && this.endDate != "" && this.startDate != "" && this.sale_person != 'undefined' && this.customer != 'undefined') {
         console.log("for date and customer");
         this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=" + searchfilter + "&login_id=" + this.user_id + "&customer=" + this.customer.customer_name + "&customerid=" + this.customer.customer_id).subscribe(response => {
-          if (response.status == 'falsetoken') {
+          if (response.status == 'tokenfalse') {
             this.router.navigate(['/login'])
           } else {
 
@@ -610,7 +610,7 @@ export class HomeComponent implements OnInit {
       } else if (this.sale_person != undefined && this.customer != undefined && this.startDate != undefined && this.endDate != undefined) {
         console.log("all filters date,customer and sales_person");
         this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=" + searchfilter + "&login_id=" + this.user_id + "&salePerson=" + this.sale_person + "&customer=" + this.customer.customer_name + "&customerid=" + this.customer.customer_id).subscribe(response => {
-          if (response.status == 'falsetoken') {
+          if (response.status == 'tokenfalse') {
             this.router.navigate(['/login'])
           } else {
             console.log("in searchfilterd");
@@ -667,7 +667,7 @@ export class HomeComponent implements OnInit {
           } else {
             console.log("valid date");
             this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=" + searchfilter + "&login_id=" + this.user_id).subscribe(response => {
-              if (response.status == 'falsetoken') {
+              if (response.status == 'tokenfalse') {
                 this.router.navigate(['/login'])
               } else {
                 if (response.data[0].getdvrDataStatus == '0') {
@@ -706,7 +706,7 @@ export class HomeComponent implements OnInit {
         } else {
           console.log("invalid date");
           this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?login_id=" + this.user_id).subscribe(response => {
-            if (response.status == 'falsetoken') {
+            if (response.status == 'tokenfalse') {
               this.router.navigate(['/login'])
             } else {
               if (response.data[0].getdvrDataStatus == '0') {
@@ -758,7 +758,7 @@ export class HomeComponent implements OnInit {
       //   console.log("for sale person and date filters and customer filter");
 
       //   this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=" + searchfilter + "&login_id=" + this.user_id + "&salePerson=" + this.sale_person + "&customer=" + this.customer.customer_name + "&customerid=" + this.customer.customer_id).subscribe(response => {
-      //     if (response.status == 'falsetoken') {
+      //     if (response.status == 'tokenfalse') {
       //       this.router.navigate(['/login'])
       //     } else {
 
@@ -798,7 +798,7 @@ export class HomeComponent implements OnInit {
       //   // for customer and sale_person
       //   console.log("for sale_person and customer");
       //   this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=undefineddate&login_id=" + this.user_id + "&customer=" + this.customer.customer_name + "&salePerson=" + this.sale_person + "&customerid=" + this.customer.customer_id).subscribe(response => {
-      //     if (response.status == 'falsetoken') {
+      //     if (response.status == 'tokenfalse') {
       //       this.router.navigate(['/login'])
       //     } else {
       //       if (response.data[0].getdvrDataStatus == '0') {
@@ -833,7 +833,7 @@ export class HomeComponent implements OnInit {
       //  //for sale_person and date
       //  console.log("for sale_person and date filter");
       //  this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=" + searchfilter + "&login_id=" + this.user_id + "&salePerson=" + this.sale_person).subscribe(response => {
-      //   if (response.status == 'falsetoken') {
+      //   if (response.status == 'tokenfalse') {
       //     this.router.navigate(['/login'])
       //   } else {
 
@@ -873,7 +873,7 @@ export class HomeComponent implements OnInit {
       //   //for customer and date filter 
       //   console.log("for customer and date filter")
       //   this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=" + searchfilter + "&login_id=" + this.user_id + "&customer=" + this.customer.customer_name + "&customerid=" + this.customer.customer_id).subscribe(response => {
-      //     if (response.status == 'falsetoken') {
+      //     if (response.status == 'tokenfalse') {
       //       this.router.navigate(['/login'])
       //     } else {
 
@@ -912,7 +912,7 @@ export class HomeComponent implements OnInit {
       //   // only for sale_person
       //   console.log("only for sale_person")
       //   this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=undefineddate&login_id=" + this.user_id + "&salePerson=" + this.sale_person).subscribe(response => {
-      //     if (response.status == 'falsetoken') {
+      //     if (response.status == 'tokenfalse') {
       //       this.router.navigate(['/login'])
       //     } else {
       //       if (response.data[0].getdvrDataStatus == '0') {
@@ -946,7 +946,7 @@ export class HomeComponent implements OnInit {
       //   //for customer filter
       //   console.log("only for customer filter")
       //   this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=undefineddate&login_id=" + this.user_id + "&customer=" + this.customer.customer_name + "&customerid=" + this.customer.customer_id).subscribe(response => {
-      //     if (response.status == 'falsetoken') {
+      //     if (response.status == 'tokenfalse') {
       //       this.router.navigate(['/login'])
       //     } else {
       //       if (response.data[0].getdvrDataStatus == '0') {
@@ -987,7 +987,7 @@ export class HomeComponent implements OnInit {
       //   if (result != undefined && result1 != undefined) {
       //     console.log("valid date")
       //     this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?searchfiltertype=" + searchfilter + "&login_id=" + this.user_id).subscribe(response => {
-      //       if (response.status == 'falsetoken') {
+      //       if (response.status == 'tokenfalse') {
       //         this.router.navigate(['/login'])
       //       } else {
       //         if (response.data[0].getdvrDataStatus == '0') {
@@ -1018,7 +1018,7 @@ export class HomeComponent implements OnInit {
       //   } else {
       //     console.log("invalid date");
       //     this.commonservice.getAllData(this.commonservice.projectpath + "/getdashboarddetails?login_id=" + this.user_id).subscribe(response => {
-      //       if (response.status == 'falsetoken') {
+      //       if (response.status == 'tokenfalse') {
       //         this.router.navigate(['/login'])
       //       } else {
       //         if (response.data[0].getdvrDataStatus == '0') {
@@ -1126,7 +1126,7 @@ export class HomeComponent implements OnInit {
     console.log(sale_person)
     if (sale_person) {
       this.commonservice.getAllData(this.commonservice.projectpath + "/mappingCustomerDetails?sale_person=" + sale_person).subscribe(response => {
-        if (response.status == 'falsetoken') {
+        if (response.status == 'tokenfalse') {
           this.router.navigate(['/login'])
         } else {
           console.log("sale_person------------>",response);

+ 2 - 4
src/assets/css/style.css

@@ -1037,7 +1037,8 @@ margin-left: 30px; }
     -webkit-box-flex: 0;
     -ms-flex: 0 0 8.33333%;
     flex: 0 0 8.33333%;
-    max-width: 8.33333%; }
+    /* max-width: 8.33333%; } */
+  }
   .col-lg-2 {
     -webkit-box-flex: 0;
     -ms-flex: 0 0 16.66667%;
@@ -8580,9 +8581,6 @@ table.dataTable.display tbody tr.even > .sorting_1, table.dataTable.order-column
     border: 1px solid #8c8a8a;
 }
 th input{   border-radius: 3px; border: 1px solid #8c8a8a;font-weight:500}
-table.dataTable.row-border tbody th, table.dataTable.row-border tbody td, table.dataTable.display tbody th, table.dataTable.display tbody td {
-   
-}
 
 .card-header {
     border-radius: calc(0.25rem - 1px) calc(0.25rem - 1px) 0 0;

+ 2 - 4
src/styles.css

@@ -1037,7 +1037,8 @@ margin-left: 30px; }
     -webkit-box-flex: 0;
     -ms-flex: 0 0 8.33333%;
     flex: 0 0 8.33333%;
-    max-width: 8.33333%; }
+    /* max-width: 8.33333%;  */
+  }
   .col-lg-2 {
     -webkit-box-flex: 0;
     -ms-flex: 0 0 16.66667%;
@@ -8566,9 +8567,6 @@ table.dataTable.display tbody tr.even > .sorting_1, table.dataTable.order-column
     border: 1px solid #8c8a8a;
 }
 th input{   border-radius: 3px; border: 1px solid #8c8a8a;font-weight:500}
-table.dataTable.row-border tbody th, table.dataTable.row-border tbody td, table.dataTable.display tbody th, table.dataTable.display tbody td {
-   
-}
 
 .card-header {
     border-radius: calc(0.25rem - 1px) calc(0.25rem - 1px) 0 0;