flowable / flowable/flowable-engine
Flowable IDM UI fails to jump to the root web context.
- Lingua principale
- Java
- Stelle
- 9.5k
- Fork
- 2.9k
- Merge medio
- 7h 8m
- PR unite (30g)
- 2
Descrizione
**Problem describe**
The UI works well if a root web context like '/flowable-ui' is used.
If the root web context is '/' or '', the idm UI fails to jump to the root web context.(On the IDM UI page, click the 'flowable' icon in the upper left corner)
**Expected**
the idm UI should jump to the root web context.(On the IDM UI page, click the 'flowable' icon in the upper left corner)
**Code**
Seems to me the issue is caused by the following code part in app-cfg.js:
`var pathname = window.location.pathname.replace(/^(\/[^\/]*)(\/.*)?idm\/?$/, '$1').replace(/\/$/, '');`
Operated on a '/flowable-ui' root web context the value of pathname will always be '/flowable-ui'. Jump function work well.
Operated on a '/' root web context the value of pathname will always be ''. Jump function does not meet expectations.
Case: when the root web context is '/' or ''
In the idm app ui, the `window.location.pathname` like this '/idm/'.
The value of pathname will always be ''. Jump logic is actually `window.location.href = pathname`, so the page will always stay on 'http://ip:port/idm/'. The expected result is to jump to 'http://ip:port/'.
**Additional context**
my pom.xml
```xml
4.0.0
org.springframework.boot
spring-boot-starter-parent
2.2.2.RELEASE
org.example
FlowableBoot
1.0-SNAPSHOT
1.8
6.6.0
org.flowable
flowable-spring-boot-starter-rest
${flowable.version}
org.flowable
flowable-spring-boot-starter-ui-idm
${flowable.version}
org.flowable
flowable-spring-boot-starter-ui-modeler
${flowable.version}
org.flowable
flowable-spring-boot-starter-ui-admin
${flowable.version}
org.flowable
flowable-spring-boot-starter-ui-task
${flowable.version}
mysql
mysql-connector-java
runtime
org.springframework.boot
spring-boot-maven-plugin
```
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Direzione di ricerca
Inizia in app-cfg.js, dove l’IDM UI ricava pathname da window.location.pathname e lo assegna a window.location.href quando si fa clic sull’icona Flowable. Riproduci il comportamento con l’IDM UI montata su '/' o '' e su '/flowable-ui'. Il lavoro è completato quando l’icona naviga al contesto web root in entrambi i casi senza compromettere il contesto non root.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- javascript
- Ambito
- frontend
- Tipo di issue
- Bug
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Stato di attività
- Ferma
- Chiarezza
- Specificata chiaramente
- Idoneità per principianti
- 35/100