strapi-community / strapi-plugin-slugify

A plugin for Strapi Headless CMS that provides the ability to auto slugify a field for any content type.

Home Page:https://market.strapi.io/plugins/strapi-plugin-slugify

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

article model name not found, all models must be defined in the settings and are case sensitive.

akirawinz opened this issue · comments

I've follow document and here is my config

slugify: {
       enabled: true,
       config: {
         contentTypes: {
           article: {
             field: 'slug',
             references: 'title',
           },
         },
       },
     },

and after I enter http://localhost:1337/api/slugify/slugs/artlcle/test

the error show up

"error": {
"status": 400,
"name": "ValidationError",
"message": "article model name not found, all models must be defined in the settings and are case sensitive.",
"details": {}
}

Here is my article schema.json

 "collectionName": "articles",
  "info": {
    "singularName": "article",
    "pluralName": "articles",
    "displayName": "Article",
    "description": ""
  }

where can I get right model name ?

That looks correct, the only reasons a model would not be registered is if the field or reference(s) values are not valid for that model. Their should have been a message logged to the console in these cases though.

Do you have any example repo where I can take a look?

Closing due to no response, will re-open if any follow ups.