1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
import Form from './ProductForm';
import { ServiceParams } from '../../lib/ServiceContext';
import { Product } from '../types';
const service: ServiceParams<Product> = {
route: 'products',
name: 'Товары',
nameSingular: 'Товар',
tableFields: [
{ key: 'name', label: 'Название' },
{ key: 'price', label: 'Цена' },
{ key: 'quantity', label: 'На складе' },
],
searchBy: ['name'],
default: {
name: '',
price: 0,
quantity: 0,
},
Form,
};
export default service;
|