Commit b9d9e475 authored by 黄奎's avatar 黄奎

新增配置

parent 29ed1b71
......@@ -359,7 +359,8 @@ namespace Edu.Common
/// <summary>
/// okr关注事项配置
/// </summary>
public static string OKRMatterValue {
public static string OKRMatterValue
{
get
{
return ReadConfigKey("OKRMatterValue");
......@@ -424,5 +425,16 @@ namespace Edu.Common
return studyAbroadManagerId;
}
}
/// <summary>
/// 获取合同默认抬头
/// </summary>
public static string ContractDefaultTitle
{
get
{
return ReadConfigKey("ContractDefaultTitle");
}
}
}
}
\ No newline at end of file
using Edu.Model.Entity.Course;
using System;
using System.Collections.Generic;
namespace Edu.Model.ViewModel.Course
......@@ -52,21 +53,178 @@ namespace Edu.Model.ViewModel.Course
/// <summary>
/// 学员生日字符串
/// </summary>
public string StuBirthStr { get { return Common.ConvertHelper.FormatDate(this.StuBirth); } }
public string StuBirthStr
{
get { return Common.ConvertHelper.FormatDate2(this.StuBirth); }
}
/// <summary>
/// 性别字符串
/// </summary>
public string StuSexStr
{
get
{
string str = "男";
if (this.StuSex == 1)
{
str = "女";
}
return str;
}
}
/// <summary>
/// 第一期-支付日期字符串
/// </summary>
public string FirstPayDateStr
{
get
{
return Common.ConvertHelper.FormatDate(this.FirstPayDate);
}
}
/// <summary>
/// 第二期-支付日期
/// </summary>
public string SecondPayDateStr
{
get
{
return Common.ConvertHelper.FormatDate(this.SecondPayDate);
}
}
/// <summary>
/// 第三期-支付日期
/// </summary>
public string ThirdPayDateStr
{
get
{
return Common.ConvertHelper.FormatDate(this.ThirdPayDate);
}
}
/// <summary>
/// 总课时数
/// </summary>
public int TotalClassHours
{
get
{
Int32.TryParse(this.FirstClassHours.ToString(), out int FirstClassHours);
Int32.TryParse(this.SecondClassHours.ToString(), out int SecondClassHours);
Int32.TryParse(this.ThirdClassHours.ToString(), out int ThirdClassHours);
return FirstClassHours + SecondClassHours + ThirdClassHours;
}
}
/// <summary>
/// 总课时费
/// </summary>
public decimal TotalCourseFee
{
get
{
decimal.TryParse(this.FirstCourseFee.ToString(), out decimal FirstCourseFee);
decimal.TryParse(this.SecondCourseFee.ToString(), out decimal SecondCourseFee);
decimal.TryParse(this.ThirdCourseFee.ToString(), out decimal ThirdCourseFee);
return FirstCourseFee + SecondCourseFee + ThirdCourseFee;
}
}
/// <summary>
/// 总教材费
/// </summary>
public decimal TotalBookFee
{
get
{
decimal.TryParse(this.FirstBookFee.ToString(), out decimal FirstBookFee);
decimal.TryParse(this.SecondBookFee.ToString(), out decimal SecondBookFee);
decimal.TryParse(this.ThirdBookFee.ToString(), out decimal ThirdBookFee);
return FirstBookFee + SecondBookFee + ThirdBookFee;
}
}
/// <summary>
/// 总课件费
/// </summary>
public decimal TotalClassFee
{
get
{
decimal.TryParse(this.FirstClassFee.ToString(), out decimal FirstClassFee);
decimal.TryParse(this.SecondClassFee.ToString(), out decimal SecondClassFee);
decimal.TryParse(this.ThirdClassFee.ToString(), out decimal ThirdClassFee);
return FirstClassFee + SecondClassFee + ThirdClassFee;
}
}
/// <summary>
/// 第一期费用小计
/// </summary>
public decimal FirstSubTotal
{
get
{
return this.FirstCourseFee + this.FirstBookFee + this.FirstClassFee;
}
}
/// <summary>
/// 第一期-支付日期字符串
/// 第二期费用小计
/// </summary>
public string FirstPayDateStr { get { return Common.ConvertHelper.FormatDate(this.FirstPayDate); } }
public decimal SecondSubTotal
{
get { return this.SecondCourseFee + this.SecondBookFee + this.SecondClassFee; }
}
/// <summary>
/// 第二期-支付日期字符串
/// 第三期费用小计
/// </summary>
public string SecondPayDateStr { get { return Common.ConvertHelper.FormatDate(this.SecondPayDate); } }
public decimal ThirdSubTotal
{
get { return this.ThirdCourseFee + this.ThirdBookFee + this.ThirdClassFee; }
}
/// <summary>
/// 第三期-支付日期字符串
/// 总费用小计
/// </summary>
public string ThirdPayDateStr { get { return Common.ConvertHelper.FormatDate(this.ThirdPayDate); } }
public decimal TotalSub
{
get { return this.FirstSubTotal + this.SecondSubTotal + this.ThirdSubTotal; }
}
/// <summary>
/// 总优惠金额
/// </summary>
public decimal TotalDiscountMoney
{
get
{
decimal.TryParse(this.FirstDiscountMoney.ToString(), out decimal FirstDiscountMoney);
decimal.TryParse(this.SecondDiscountMoney.ToString(), out decimal SecondDiscountMoney);
decimal.TryParse(this.ThirdDiscountMoney.ToString(), out decimal ThirdDiscountMoney);
return FirstDiscountMoney + SecondDiscountMoney + ThirdDiscountMoney;
}
}
/// <summary>
/// 总金额
/// </summary>
public decimal TotalMoney
{
get
{
decimal.TryParse(this.FirstMoney.ToString(), out decimal FirstMoney);
decimal.TryParse(this.SecondMoney.ToString(), out decimal SecondMoney);
decimal.TryParse(this.ThirdMoney.ToString(), out decimal ThirdMoney);
return FirstMoney + SecondMoney + ThirdMoney;
}
}
}
}
......@@ -229,10 +229,10 @@ namespace Edu.Module.Course
public string CreateContractNumModule(int GroupId,int schoolId)
{
var schoolModel= schoolRepository.GetEntity(schoolId);
string newContractNum = "JH-CD";
string newContractNum = Common.Config.ContractDefaultTitle;
if (schoolModel != null && schoolModel.SId > 0)
{
newContractNum = schoolModel?.ContractTitle ?? "JH-CD";
newContractNum = schoolModel?.ContractTitle ?? Common.Config.ContractDefaultTitle;
}
var totalCount = education_ContractRepository.GetContractCount(new RB_Education_Contract_ViewModel() { Group_Id = GroupId });
string num = (totalCount + 1).ToString("D4");
......
......@@ -127,7 +127,7 @@ WHERE 1=1
builder.AppendFormat(" AND s.{0}={1} ", nameof(RB_School_ViewModel.Status), (int)query.Status);
}
}
builder.Append(" ORDER BY CreateTime DESC");
builder.AppendFormat(" ORDER BY s.{0} ASC ", nameof(RB_School_ViewModel.SId));
return GetPage<RB_School_ViewModel>(pageIndex, pageSize, out rowsCount, builder.ToString(), parameters).ToList();
}
}
......
......@@ -53,5 +53,7 @@
//留学就业部门主管审核编号[王涛]
"StudyAbroadDirectorId": 64,
//留学就业部门负责人审核编号[姚顺先]
"StudyAbroadManagerId": 52
"StudyAbroadManagerId": 52,
//合同默认抬头
"ContractDefaultTitle": "JH-DZ-CD-"
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment