<commit_before>const mongoose = require("mongoose");

const conn = mongoose.createConnection('mongodb://localhost/t-all'); // 连接数据库
const Schema = mongoose.Schema;   // 创建模型

conn.on('open', function(){
    console.log('connectDB open');
});
conn.on('error', function(){
    console.log('connectDB error');
});

mongoose.Promise = global.Promise;

const userSchema = new Schema({
    userId: String,
    userName: String,
    password: String,
    adminId: String,
    ticket: String,
    ticketValid: String
}); // 定义了一个新的模型，但是此模式还未和users集合有关联
const assigneeSchema = new Schema({
    id: String,
    name: String,
    startDate: String,
    endDate: String
});
const taskSchema = new Schema({
    id: String, // 任务ID
    name: String, // 任务名
    color: String, // 颜色
    startDate: String, // 开始日期
    endDate: String, // 结束日期
    asg: [ // 参与人员
        {
            id: String,
            effort: {
                dev: [String], // 开发时间
                intg: [String], // 联调自测时间
                test: [String], // 测试时间
                rls: [String] // 上线时间
            },
            nth: Number // 展示位置<commit_msg>[EDIT] 修改user表的ticketValid数据类型<commit_after>const mongoose = require("mongoose");

const conn = mongoose.createConnection('mongodb://localhost/t-all'); // 连接数据库
const Schema = mongoose.Schema;   // 创建模型

conn.on('open', function(){
    console.log('connectDB open');
});
conn.on('error', function(){
    console.log('connectDB error');
});

mongoose.Promise = global.Promise;

const userSchema = new Schema({
    userId: String,
    userName: String,
    password: String,
    adminId: String,
    ticket: String,
    ticketValid: Number
}); // 定义了一个新的模型，但是此模式还未和users集合有关联
const assigneeSchema = new Schema({
    id: String,
    name: String,
    startDate: String,
    endDate: String
});
const taskSchema = new Schema({
    id: String, // 任务ID
    name: String, // 任务名
    color: String, // 颜色
    startDate: String, // 开始日期
    endDate: String, // 结束日期
    asg: [ // 参与人员
        {
            id: String,
            effort: {
                dev: [String], // 开发时间
                intg: [String], // 联调自测时间
                test: [String], // 测试时间
                rls: [String] // 上线时间
            },
            nth: Number // 展示位置
{'fraction_non_alphanumeric': 0.14178112538768275, 'fraction_numerical': 0.0, 'mean_word_length': 2.1713483146067416, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7352693', 'n_tokens_mistral': 799, 'n_tokens_neox': 833, 'n_words': 178}