sigesp 0.8.54-220105 → 0.8.55-220105

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.
@@ -5663,10 +5663,16 @@ class SigespService {
5663
5663
  */
5664
5664
  getJsonMenu(id_usuario, sistema) {
5665
5665
  return this.http.get(`${this.URL}/dao/sss/menu_dao.php?id_usuario=${id_usuario}&sistema=${sistema}`, { headers: this.getHttpHeaders() }).pipe(map((res) => {
5666
- //console.log('respuesta :',res);
5667
- //this.userMenu = res ;
5668
- //sessionStorage.setItem('menu', this.userMenu);
5669
- return res;
5666
+ var menuJson = res.data;
5667
+ var stringifiedData = JSON.stringify(menuJson);
5668
+ stringifiedData = stringifiedData.substring(9, (stringifiedData.length - 2));
5669
+ stringifiedData = stringifiedData.substring(0, stringifiedData.length - 1);
5670
+ //console.log('stringJson : ',this.stringifiedData );
5671
+ var string_menu = "[" + stringifiedData + "\"]";
5672
+ var menu = string_menu;
5673
+ menu = JSON.parse(menu);
5674
+ this.userMenu = menu;
5675
+ return this.userMenu;
5670
5676
  }));
5671
5677
  }
5672
5678
  }