using Ewide.Core.Util;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Vote.Services.Entities;
namespace Vote.Services.Dto
{
public class ProjectsInput
{
///
/// 项目类型
///
public int? type { get; set; }
public int? is_no_inspection { get; set; }
}
public class ProjectsOutput
{
///
///
///
public string id { get; set; }
///
/// 项目序号
///
public int serial_number { get; set; }
///
/// 工程名称
///
public string name { get; set; }
///
/// 项目类型
///
public EnumProjectType type { get; set; }
///
/// 项目类型
///
public string type_title
{
get
{
return type.GetEnumDescription();
}
}
///
///
///
public bool vote { get; set; } = false;
public int is_no_inspection { get; set; }
}
public class CheckSubmitCodeInput
{
///
/// 项目类型
///
[Required]
public string code { get; set; }
}
public class SubmitInput
{
///
/// 项目类型
///
[Required]
public string code { get; set; }
[Required]
public List projects { get; set; }
}
public class ProjectsList2Output
{
///
///
///
public string id { get; set; }
///
/// 项目序号
///
public int serial_number { get; set; }
///
/// 工程名称
///
public string name { get; set; }
public int no_count { get; set; }
public int yes_count { get; set; }
///
///
///
public bool is_agree
{
get
{
return yes_count > 15;
// return (yes_count / (yes_count + no_count)) >= (2.0 / 3.0);
}
}
///
/// 项目类型
///
public EnumProjectType type { get; set; }
///
/// 项目类型
///
public string type_title
{
get
{
return type.GetEnumDescription();
}
}
public class AddExpertInput
{
[Required]
public int expertnum { get; set; }
}
public int is_no_inspection { get; set; }
}
}