Skip to content

Commit

Permalink
have scaffold titleTo and buttonTo depend on getTemplateStrings (#6806)
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-escoto authored Nov 7, 2022
1 parent 19e3ea5 commit 176fa01
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/cli/src/commands/generate/scaffold/scaffold.js
Original file line number Diff line number Diff line change
Expand Up @@ -694,11 +694,12 @@ const addSetImport = (task) => {
}

const addScaffoldSetToRouter = async (model, path) => {
const templateNames = getTemplateStrings(model, path)
const nameVars = nameVariants(model)
const title = nameVars.pluralPascalName
const titleTo = nameVars.pluralCamelName
const titleTo = templateNames.pluralRouteName
const buttonLabel = `New ${nameVars.singularPascalName}`
const buttonTo = `new${nameVars.singularPascalName}`
const buttonTo = templateNames.newRouteName

return addRoutesToRouterTask(
await routes({ model, path }),
Expand Down

0 comments on commit 176fa01

Please sign in to comment.