fabric8io / fabric8-generator

a jboss forge add on for the fabric8 upstream and SaaS generator wizards
Apache License 2.0
1 stars 12 forks source link

canMoveToNextStep set to false by `next` after selecting the mission in quickstart wizard #51

Open corinnekrych opened 7 years ago

corinnekrych commented 7 years ago

The wizard API for quickstart (fabric8-new-project) after selecting a quickstart mission on the next command to go to Fabric8ProjectInfoStep, returns a valid: false and canMoveToNextStep: false

See https://gist.github.com/corinnekrych/abfab9f9a8f7a7a587bca25385b57551#file-gistfile1-txt-L61-L64

This is wrong, we do not want a validation to occurs on the next.

corinnekrych commented 7 years ago

@jstrachan After discussing with @gastaldi it seems you can remove validation in next command like here. But you need the latest version of the launchpad backend (this piece of code). Let me create a separate epic to track the remove fork and mark it as dependency.

jstrachan commented 7 years ago

We'll also need to do a diff of the ObsidianResource to the launchpad one to see what other differences there are - we made a bunch of changes over the last 6 months to work around forge issues - particularly around adding our own commands, removing launchpad commands, removing the zips & json reporting of results & errors

jstrachan commented 7 years ago

Btw why do we need to disable validation on Next - how else is validate going to be called?

Either the form should validate if we pass a 'named' value into Next - or if the validation fails (the defaulted name already exists as a git repo) then we want the invalid result & message?

corinnekrych commented 7 years ago

@jstrachan in the ui we chain 2 promises which end end with 2 http calls (validate and next) are done one for validate and then next see: https://github.com/fabric8-ui/fabric8-ui/blob/master/src/app/space/wizard/services/fabric8-app-generator.client.ts#L259 But on the addon even when we call next, validate is done (this is what i observe)

jstrachan commented 7 years ago

Isn't it quicker & faster just to do 1 http call to 'next & validate'?

jstrachan commented 7 years ago

@corinnekrych is this fixed now?

corinnekrych commented 7 years ago

@jstrachan not fixed. forge addon api returns false.but the ui worked around it in this PR:https://github.com/fabric8-ui/fabric8-ui/pull/1914