@gadmin2n/prisma-react-generator 0.0.35 → 0.0.36
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
handleOnFinish,
|
|
15
15
|
ModelType,
|
|
16
16
|
produceModel,
|
|
17
|
-
} from '@
|
|
17
|
+
} from '@gadmin2n/react-common';
|
|
18
18
|
import { Create, useFileUploadState, useForm } from "@refinedev/antd";
|
|
19
19
|
import { Form } from "antd";
|
|
20
20
|
import { IResourceComponentsProps, useApiUrl, useTranslate } from "@refinedev/core";
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
handleOnFinish,
|
|
15
15
|
ModelType,
|
|
16
16
|
produceModel,
|
|
17
|
-
} from "@
|
|
17
|
+
} from "@gadmin2n/react-common";
|
|
18
18
|
import { Edit, ListButton, RefreshButton, useFileUploadState, useForm } from "@refinedev/antd";
|
|
19
19
|
import { Form } from "antd";
|
|
20
20
|
import { IResourceComponentsProps, useApiUrl, useParsed, useTranslate } from "@refinedev/core";
|
|
@@ -10,7 +10,7 @@ const generateListPage = ({ model, templateHelpers: t, uiConfig, allModels, }) =
|
|
|
10
10
|
/**
|
|
11
11
|
* ${model.name} List Page
|
|
12
12
|
*
|
|
13
|
-
* Generated using simplified pattern with @
|
|
13
|
+
* Generated using simplified pattern with @gadmin2n/react-common hooks and components.
|
|
14
14
|
*
|
|
15
15
|
* Flexibility Levels:
|
|
16
16
|
* 1. Basic usage - Use components with defaults (this file)
|
|
@@ -37,7 +37,7 @@ import {
|
|
|
37
37
|
ModelType,
|
|
38
38
|
produceModel,
|
|
39
39
|
tableSearchBar,
|
|
40
|
-
} from '@
|
|
40
|
+
} from '@gadmin2n/react-common';
|
|
41
41
|
|
|
42
42
|
// Generated imports
|
|
43
43
|
import { modelsEnum, modelsMap } from 'generated/models.index';
|
|
@@ -7,7 +7,7 @@ const helpers_1 = require("./helpers");
|
|
|
7
7
|
const generateModelProps = ({ dmmf, model, templateHelpers: t, uiConfig, allModels, }) => {
|
|
8
8
|
const instanceName = (0, case_1.camel)(model.name);
|
|
9
9
|
return `
|
|
10
|
-
import { ModelsFieldsTypeMap, ModelType } from "@
|
|
10
|
+
import { ModelsFieldsTypeMap, ModelType } from "@gadmin2n/react-common";
|
|
11
11
|
import { useSelect } from "@refinedev/antd";
|
|
12
12
|
${t.each(dmmf.datamodel.models, (model) => `import type { ${model.name} } from '../../types/prisma.types';`, '\n')}
|
|
13
13
|
import { modelsMap } from '../../models.index';
|
|
@@ -6,7 +6,7 @@ const fs = require("fs");
|
|
|
6
6
|
const generatePageShow = ({ model, templateHelpers: t, uiConfig, allModels, }) => {
|
|
7
7
|
const instanceName = (0, case_1.camel)(model.name);
|
|
8
8
|
return `
|
|
9
|
-
import { ModelType, getColumns, produceModel } from "@
|
|
9
|
+
import { ModelType, getColumns, produceModel } from "@gadmin2n/react-common";
|
|
10
10
|
import { CloneButton, DeleteButton, EditButton, ListButton, RefreshButton, Show } from "@refinedev/antd";
|
|
11
11
|
import { IResourceComponentsProps, useShow, useTranslate } from "@refinedev/core";
|
|
12
12
|
import React, { useState } from "react";
|
package/package.json
CHANGED