feat: bind crud
Some checks failed
Spell Check / Spell Check with Typos (push) Failing after 9s

This commit is contained in:
Thanaphon Frappet 2025-03-10 17:19:45 +07:00
parent 39c7754d5f
commit bfa0571e0b
4 changed files with 400 additions and 17 deletions

View file

@ -41,7 +41,7 @@ export const useProperty = defineStore('property-store', () => {
return res;
}
async function editProperty(data: Property & { id: string }) {
async function editProperty(data: Property) {
const res = await api.put<Property>(`/property/${data.id}`, {
...data,
id: undefined,

View file

@ -1,5 +1,9 @@
import { Status } from '../types';
export type Property = {
id?: string;
name: string;
nameEN: string;
type: Record<string, any>;
status?: Status;
};