76f266645d
含 Phase 1.1 IM seq 排序、断线重连、多端已读同步与微信式语音转文字 UI。 排除 node_modules、构建产物、安装包与 .env 密钥。 Co-authored-by: Cursor <cursoragent@cursor.com>
36 lines
806 B
TypeScript
36 lines
806 B
TypeScript
import { PrismaClient } from '@prisma/client';
|
|
|
|
const ITEMS = [
|
|
['公开招标', 1],
|
|
['邀请招标', 2],
|
|
['询价', 3],
|
|
['竞谈【综合评分】', 4],
|
|
['竞谈【最低价中】', 5],
|
|
['单一来源', 6],
|
|
['其他', 7],
|
|
] as const;
|
|
|
|
const prisma = new PrismaClient();
|
|
|
|
async function main() {
|
|
await prisma.dictItem.deleteMany({ where: { tenantId: '1', dictType: 'tenderMethod' } });
|
|
await prisma.dictItem.createMany({
|
|
data: ITEMS.map(([value, sortNo]) => ({
|
|
tenantId: '1',
|
|
dictType: 'tenderMethod',
|
|
label: value,
|
|
value,
|
|
sortNo,
|
|
})),
|
|
});
|
|
console.log('tenderMethod dict synced', ITEMS.length);
|
|
}
|
|
|
|
main()
|
|
.then(() => prisma.$disconnect())
|
|
.catch(async (e) => {
|
|
console.error(e);
|
|
await prisma.$disconnect();
|
|
process.exit(1);
|
|
});
|