clear:删除无用的参数

This commit is contained in:
luying
2022-07-26 16:09:52 +08:00
parent efb827a52c
commit 23c047b63e
2 changed files with 0 additions and 37 deletions

View File

@@ -1,36 +0,0 @@
import BaseModel from './BaseModel';
import { index, getModelForClass, prop, DocumentType, modelOptions } from '@typegoose/typegoose';
import { ShopItem } from '../domain/dbGeneral';
/**
* 分红记录表
**/
@modelOptions({ schemaOptions: { id: false } })
@index({ shopId: 1 })
export default class DicShopList extends BaseModel {
@prop({ required: true })
shopId: number; // 商店id dic_zyz_shopList内的id
@prop({ required: true, default: false })
useJson: boolean; // 如果为true则会随dic_zyz_shop表内商品增加而增加items只提供顺序折扣等为false则只提供items里的商品
@prop({ required: true, default: [], _id: false, type: () => ShopItem })
items: ShopItem[]; // 商店id dic_zyz_shopList内的id
// public static async findByShopId(shopId: number) {
// const rec: DicShopListType = await DicShopListModel.findOne({ shopId }).lean();
// return rec;
// }
// public static async createShop(shopId: number, useJson: boolean, item: ShopItem) {
// const rec: DicShopListType = await DicShopListModel.findOneAndUpdate({ shopId }, { useJson, $push: { items: item } }, { new: true, upsert: true }).lean();
// return rec;
// }
}
export const DicShopListModel = getModelForClass(DicShopList);
export interface DicShopListType extends Pick<DocumentType<DicShopList>, keyof DicShopList>{}
export type DicShopListParam = Partial<DicShopListType>;

View File

@@ -3,7 +3,6 @@ import { index, getModelForClass, prop, DocumentType } from '@typegoose/typegoos
import { LADDER_STATUS } from '../consts';
import { LadderDefense, LadderOppPlayerInfo, LadderOppPlayerHeroInfo } from '../domain/battleField/ladder';
import { genCode } from '../pubUtils/util';
import { LADDER } from '../pubUtils/dicParam';
@index({ battleCode: 1 })
export default class LadderMatchRec extends BaseModel {