mirror of
https://github.com/cool-team-official/cool-admin-midway.git
synced 2024-11-01 06:02:39 +08:00
5.x
This commit is contained in:
parent
14a51132ec
commit
746ce5fdf9
@ -4,7 +4,7 @@
|
||||
"description": "",
|
||||
"private": true,
|
||||
"dependencies": {
|
||||
"@cool-midway/core": "^5.0.4",
|
||||
"@cool-midway/core": "^5.0.5",
|
||||
"@cool-midway/es": "^5.0.1",
|
||||
"@cool-midway/file": "^5.0.1",
|
||||
"@cool-midway/pay": "^5.0.0",
|
||||
|
23
src/modules/demo/entity/goods-test.ts
Normal file
23
src/modules/demo/entity/goods-test.ts
Normal file
@ -0,0 +1,23 @@
|
||||
// import { EntityModel } from '@midwayjs/orm';
|
||||
// import { BaseEntity } from '@cool-midway/core';
|
||||
// import { Column } from 'typeorm';
|
||||
|
||||
// /**
|
||||
// * 商品(多数据库连接)
|
||||
// */
|
||||
// @EntityModel('demo_goods_1', {
|
||||
// connectionName: 'test',
|
||||
// })
|
||||
// export class DemoGoodsTestEntity extends BaseEntity {
|
||||
// @Column({ comment: '标题' })
|
||||
// title: string;
|
||||
|
||||
// @Column({ comment: '图片' })
|
||||
// pic: string;
|
||||
|
||||
// @Column({ comment: '价格', type: 'decimal', precision: 5, scale: 2 })
|
||||
// price: number;
|
||||
|
||||
// @Column({ comment: '分类', type: 'tinyint', default: 0 })
|
||||
// type: number;
|
||||
// }
|
@ -1,15 +1,11 @@
|
||||
import { Inject, Provide } from '@midwayjs/decorator';
|
||||
import { Provide } from '@midwayjs/decorator';
|
||||
import { BaseService } from '@cool-midway/core';
|
||||
import { CoolRpc } from '@cool-midway/rpc';
|
||||
|
||||
/**
|
||||
* 缓存
|
||||
*/
|
||||
@Provide()
|
||||
export class DemoGoodsService extends BaseService {
|
||||
@Inject()
|
||||
rpc: CoolRpc;
|
||||
|
||||
async test() {
|
||||
console.log('调用');
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user