mirror of
https://github.com/strapi/strapi.git
synced 2025-09-26 17:00:55 +00:00
Make groups non repeatable by default
This commit is contained in:
parent
f757d4d952
commit
f484b4d66e
@ -237,7 +237,7 @@ module.exports = function createQueryBuilder({ model, modelKey, strapi }) {
|
|||||||
|
|
||||||
for (let key of groupKeys) {
|
for (let key of groupKeys) {
|
||||||
const attr = model.attributes[key];
|
const attr = model.attributes[key];
|
||||||
const { group, required = false, repeatable = true } = attr;
|
const { group, required = false, repeatable = false } = attr;
|
||||||
|
|
||||||
const groupModel = strapi.groups[group];
|
const groupModel = strapi.groups[group];
|
||||||
|
|
||||||
@ -294,7 +294,7 @@ module.exports = function createQueryBuilder({ model, modelKey, strapi }) {
|
|||||||
if (!_.has(values, key)) continue;
|
if (!_.has(values, key)) continue;
|
||||||
|
|
||||||
const attr = model.attributes[key];
|
const attr = model.attributes[key];
|
||||||
const { group, repeatable = true } = attr;
|
const { group, repeatable = false } = attr;
|
||||||
|
|
||||||
const groupModel = strapi.groups[group];
|
const groupModel = strapi.groups[group];
|
||||||
|
|
||||||
|
@ -38,7 +38,7 @@ module.exports = ({ model, modelKey, strapi }) => {
|
|||||||
|
|
||||||
for (let key of groupKeys) {
|
for (let key of groupKeys) {
|
||||||
const attr = model.attributes[key];
|
const attr = model.attributes[key];
|
||||||
const { group, required = false, repeatable = true } = attr;
|
const { group, required = false, repeatable = false } = attr;
|
||||||
|
|
||||||
const groupModel = strapi.groups[group];
|
const groupModel = strapi.groups[group];
|
||||||
|
|
||||||
@ -89,7 +89,7 @@ module.exports = ({ model, modelKey, strapi }) => {
|
|||||||
if (!_.has(values, key)) continue;
|
if (!_.has(values, key)) continue;
|
||||||
|
|
||||||
const attr = model.attributes[key];
|
const attr = model.attributes[key];
|
||||||
const { group, repeatable = true } = attr;
|
const { group, repeatable = false } = attr;
|
||||||
|
|
||||||
const groupModel = strapi.groups[group];
|
const groupModel = strapi.groups[group];
|
||||||
const groupValue = values[key];
|
const groupValue = values[key];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user