add field

This commit is contained in:
kamonwan taengsuk
2022-12-12 13:06:21 +07:00
parent f56408a9b2
commit cb9742c514
3 changed files with 47 additions and 16 deletions

View File

@@ -129,7 +129,7 @@ namespace rmutr_report.Controllers
[ApiExplorerSettings(GroupName = "reports")]
public IActionResult GetDataLineReport([FromRoute] string type, [FromBody] data_line_support data_line_supports)
{
var data_line_supportss = new List<data_line_support>() {data_line_supports};
var data_line_supportss = new List<data_line_support>() {data_line_supports};
Report report = new Report();
report.Load(_setting.report_path + "data_line_support.frx");
@@ -309,32 +309,53 @@ namespace rmutr_report.Controllers
public IActionResult GetPostponementCompensationReport([FromRoute] string type,
[FromBody] postponement_compensation postponement_compensations)
{
string NumberText1 = postponement_compensations.data_date;
if (postponement_compensations.get_promoted == true)
{
postponement_compensations.check_get_promoted = "/";
postponement_compensations.reason = "";
}
if (postponement_compensations.get_promoted == false)
{
postponement_compensations.check_get_promoted = "";
}
if (postponement_compensations.not_get_promoted == true)
{
postponement_compensations.check_not_get_promoted = "/";
}
if (postponement_compensations.not_get_promoted == false)
{
postponement_compensations.check_not_get_promoted = "";
}
string NumberText1 = postponement_compensations.data_date;
var str1 =
NumberText1.Replace('0', '').Replace('1', '๑').Replace('2', '๒').Replace('3', '๓')
.Replace('4', '๔').Replace('5', '๕').Replace('6', '๖').Replace('7', '๗').Replace('8', '๘')
.Replace('9', '๙');
postponement_compensations.data_date = str1;
string NumberText2 = postponement_compensations.start_date;
string NumberText2 = postponement_compensations.start_date;
var str2 =
NumberText2.Replace('0', '').Replace('1', '๑').Replace('2', '๒').Replace('3', '๓')
.Replace('4', '๔').Replace('5', '๕').Replace('6', '๖').Replace('7', '๗').Replace('8', '๘')
.Replace('9', '๙');
postponement_compensations.start_date = str2;
string NumberText3 = postponement_compensations.end_date;
string NumberText3 = postponement_compensations.end_date;
var str3 =
NumberText3.Replace('0', '').Replace('1', '๑').Replace('2', '๒').Replace('3', '๓')
.Replace('4', '๔').Replace('5', '๕').Replace('6', '๖').Replace('7', '๗').Replace('8', '๘')
.Replace('9', '๙');
postponement_compensations.end_date = str3;
string NumberText4 = postponement_compensations.base_calculation_date;
string NumberText4 = postponement_compensations.base_calculation_date;
var str4 =
NumberText4.Replace('0', '').Replace('1', '๑').Replace('2', '๒').Replace('3', '๓')
.Replace('4', '๔').Replace('5', '๕').Replace('6', '๖').Replace('7', '๗').Replace('8', '๘')
.Replace('9', '๙');
postponement_compensations.base_calculation_date = str4;
string NumberText5 = postponement_compensations.director_date;
string NumberText5 = postponement_compensations.director_date;
var str5 =
NumberText5.Replace('0', '').Replace('1', '๑').Replace('2', '๒').Replace('3', '๓')
.Replace('4', '๔').Replace('5', '๕').Replace('6', '๖').Replace('7', '๗').Replace('8', '๘')
@@ -368,6 +389,7 @@ namespace rmutr_report.Controllers
postponement_compensations.money1 = str;
}
}
if (data.compensation_slide != null)
{
string NumberText = data.compensation_slide.ToString();
@@ -394,6 +416,7 @@ namespace rmutr_report.Controllers
postponement_compensations.money2 = str;
}
}
if (data.compensation_receive != null)
{
string NumberText = data.compensation_receive.ToString();
@@ -420,6 +443,7 @@ namespace rmutr_report.Controllers
postponement_compensations.money3 = str;
}
}
string NumberText6 = data.percentage.ToString();
var str6 =
NumberText6.Replace('0', '').Replace('1', '๑').Replace('2', '๒').Replace('3', '๓')
@@ -427,6 +451,7 @@ namespace rmutr_report.Controllers
.Replace('9', '๙');
postponement_compensations.percentage = str6;
}
var _postponement_compensations = new List<postponement_compensation>() {postponement_compensations};
Report report = new Report();