refactor: 移除高优先级投标功能及相关代码
This commit is contained in:
@@ -33,24 +33,6 @@ export class BidsService {
|
||||
return { items, total };
|
||||
}
|
||||
|
||||
getHighPriority() {
|
||||
return this.bidRepository.find({
|
||||
where: { priority: LessThan(0) }, // This is just a placeholder logic, priority should be > 0
|
||||
order: { priority: 'DESC', publishDate: 'DESC' },
|
||||
take: 10,
|
||||
});
|
||||
}
|
||||
|
||||
// Update logic for priority
|
||||
async getHighPriorityCorrected() {
|
||||
return this.bidRepository.createQueryBuilder('bid')
|
||||
.where('bid.priority > 0')
|
||||
.orderBy('bid.priority', 'DESC')
|
||||
.addOrderBy('bid.publishDate', 'DESC')
|
||||
.limit(10)
|
||||
.getMany();
|
||||
}
|
||||
|
||||
async createOrUpdate(data: Partial<BidItem>) {
|
||||
// Use title or a hash of title to check for duplicates
|
||||
let item = await this.bidRepository.findOne({ where: { title: data.title } });
|
||||
|
||||
Reference in New Issue
Block a user