File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
packages/cli/template/pages/nextjs/table-edit Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 1
1
"use server" ;
2
2
3
- import { __CLIENT_NAME__ } from "@/config/schemas/__SOURCE_NAME__/client" ;
4
3
import { __ZOD_TYPE_NAME__ } from "@/config/schemas/__SOURCE_NAME__/__SCHEMA_NAME__" ;
4
+ import { __CLIENT_NAME__ } from "@/config/schemas/__SOURCE_NAME__/client" ;
5
5
import { __ACTION_CLIENT__ } from "@/server/safe-action" ;
6
+
6
7
import { idFieldName } from "./schema" ;
7
8
8
9
export const updateRecord = __ACTION_CLIENT__
9
- . schema ( __ZOD_TYPE_NAME__ . partial ( ) )
10
+ . inputSchema ( __ZOD_TYPE_NAME__ . partial ( ) )
10
11
. action ( async ( { parsedInput } ) => {
11
12
const id = parsedInput [ idFieldName ] ;
12
13
delete parsedInput [ idFieldName ] ; // this ensures the id field value is not included in the updated fieldData
You can’t perform that action at this time.
0 commit comments