12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273 |
- module.exports = {
- create: {
- requestBody: ['order_id'],
- },
- destroy: {
- params: ['!id'],
- service: 'delete',
- },
- update: {
- params: ['!id'],
- requestBody: [
- 'out_bill',
- 'type',
- 'group',
- 'remarks',
- 'order',
- 'shop',
- 'customer',
- 'address',
- 'no',
- 'transport',
- 'transport_type',
- 'goods',
- 'buy_time',
- 'pay_time',
- 'discount',
- 'status',
- ],
- },
- show: {
- parameters: {
- params: ['!id'],
- },
- service: 'fetch',
- },
- index: {
- parameters: {
- query: {
- 'meta.createdAt@start': 'meta.createdAt@start',
- 'meta.createdAt@end': 'meta.createdAt@end',
- order: 'order',
- shop: 'shop',
- customer: 'customer',
- address: 'address._id',
- no: 'no',
- 'pay_time@start': 'pay_time@start',
- 'pay_time@end': 'pay_time@end',
- 'buy_time@start': 'buy_time@start',
- 'buy_time@end': 'buy_time@end',
- status: 'status',
- type: 'type',
- group: 'group',
- out_bill: 'out_bill',
- goods: '%goods.goods.name%',
- transport_type: 'transport_type',
- },
- // options: {
- // "meta.state": 0 // 默认条件
- // },
- },
- service: 'query',
- options: {
- query: ['skip', 'limit'],
- sort: ['meta.createdAt'],
- desc: true,
- count: false,
- },
- },
- sot: {
- requestBody: ['!id','goods_id'],
- service: 'searchOrderTransport',
- },
- };
|