@csmart/ngc-smart-victim 1.14.34 → 1.14.36

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -410,8 +410,8 @@ class NgcSmartVictimService {
410
410
  const tempVal = JSON.stringify(val);
411
411
  return this.http.post(this.smartVictimServiceUrl + 'VictimSupports/' + id, tempVal, options).pipe(map(res => { return res; }));
412
412
  }
413
- deleteVictims(val) {
414
- return this.http.delete(this.smartVictimServiceUrl + 'Victims/' + val, options).pipe(map(res => { return res; }));
413
+ deleteVictims(val, staffId) {
414
+ return this.http.delete(this.smartVictimServiceUrl + 'Victims/' + val + '?staffId=' + staffId, options).pipe(map(res => { return res; }));
415
415
  }
416
416
  // //==============Victim Serive===================================
417
417
  getVictims(offenderId) {
@@ -1086,7 +1086,7 @@ class SmartVictimDetailComponent {
1086
1086
  .subscribe(res => {
1087
1087
  this.result = res;
1088
1088
  if (this.result) {
1089
- this.victimService.deleteVictims(this.victimDetail.victimId)
1089
+ this.victimService.deleteVictims(this.victimDetail.victimId, this.staffId)
1090
1090
  .subscribe(result => {
1091
1091
  this.snackBar.open('Delete Successfully!', '', {
1092
1092
  duration: 3000,
@@ -1820,6 +1820,10 @@ class NgcSmartVictimComponent {
1820
1820
  };
1821
1821
  }
1822
1822
  ngOnInit() {
1823
+ const queryParams = this.route.snapshot.queryParams;
1824
+ if (queryParams['routeTo']) {
1825
+ this.router.navigate([queryParams['routeTo']]);
1826
+ }
1823
1827
  var data = this.route.snapshot.data;
1824
1828
  var myPath = this.router.url.slice(-10);
1825
1829
  console.log("offender id at smart-victim");
@@ -1945,7 +1949,8 @@ class NgcSmartVictimComponent {
1945
1949
  duration: 3000,
1946
1950
  });
1947
1951
  //this.router.navigate(['/warrant '], { queryParams: { intake: 1 } });
1948
- this.document.location.href = `${this.smartWarrantUrl}/?offenderId=${this.offenderId}&routeTo=warrant`;
1952
+ this.document.location.href =
1953
+ `${this.smartWarrantUrl}/?offenderId=${this.offenderId}&intakeFlag=${this.isIntake}&routeTo=warrant`;
1949
1954
  });
1950
1955
  }
1951
1956
  goToCaseNote(victimId) {