toModel method

  1. @override
Model toModel()

Implementation

@override
Model toModel() {
  return Model(
    name: description().title,
    icon: 'key',
    fields: [
      [
        fieldToModelName,
        fieldToModelId,
      ],
      [
        fieldToModelSort,
        fieldToModelShowInList,
        fieldToModelIsRequired,
      ],
      // TODO(alphamikle): Make code field
      // [
      //   if (Env.isRealCMS) fieldToModelValidator,
      // ],
    ],
  );
}