|
|
@@ -10,6 +10,7 @@ namespace molilian.core
|
|
|
public class RecordDTO
|
|
|
{
|
|
|
public int id { get; set; }
|
|
|
+ public int platform { get; set; }
|
|
|
public int data_type { get; set; }
|
|
|
public DateTime report_date { get; set; }
|
|
|
public int uclk_uv { get; set; } = 0;
|
|
|
@@ -90,7 +91,12 @@ namespace molilian.core
|
|
|
|
|
|
public static async Task<List<dynamic>> DataTypeReportDailysAsync(int platform, int distributiontype, int data_type, DateTime stime, DateTime etime, string clientIp, bool debug = false)
|
|
|
{
|
|
|
- string filter = "`is_show`=@is_show AND platform=@platform AND data_type=@data_type AND report_date>=@stime AND report_date<=@etime";
|
|
|
+ string filter = "`is_show`=@is_show AND data_type=@data_type AND report_date>=@stime AND report_date<=@etime";
|
|
|
+ if (platform > 0)
|
|
|
+ {
|
|
|
+ filter = "`is_show`=@is_show AND data_type=@data_type AND platform=@platform AND report_date>=@stime AND report_date<=@etime";
|
|
|
+ platform -= 1;
|
|
|
+ }
|
|
|
string orderBy = "report_date DESC";
|
|
|
|
|
|
var list = new DBContext.Table("api_call_report_dailys")
|
|
|
@@ -120,6 +126,7 @@ namespace molilian.core
|
|
|
|
|
|
data = list.Select(e => new
|
|
|
{
|
|
|
+ platform = e.platform + 1,
|
|
|
report_date = e.report_date.ToString("yyyy-MM-dd"),
|
|
|
type = e.data_type,
|
|
|
e.uclk_uv,
|
|
|
@@ -157,6 +164,7 @@ namespace molilian.core
|
|
|
{
|
|
|
results.Add(new
|
|
|
{
|
|
|
+ platform = e.platform + 1,
|
|
|
//metric_type = "req_goods_num",
|
|
|
//metric_value = e.req_goods_num,
|
|
|
report_date = e.report_date.ToString("yyyy-MM-dd"),
|
|
|
@@ -182,6 +190,7 @@ namespace molilian.core
|
|
|
{
|
|
|
results.Add(new
|
|
|
{
|
|
|
+ platform = e.platform + 1,
|
|
|
report_date = e.report_date.ToString("yyyy-MM-dd"),
|
|
|
type = e.data_type,
|
|
|
e.uclk_uv,
|
|
|
@@ -205,6 +214,7 @@ namespace molilian.core
|
|
|
{
|
|
|
results.Add(new
|
|
|
{
|
|
|
+ platform = e.platform + 1,
|
|
|
report_date = e.report_date.ToString("yyyy-MM-dd"),
|
|
|
type = e.data_type,
|
|
|
e.uclk_uv,
|
|
|
@@ -228,6 +238,7 @@ namespace molilian.core
|
|
|
{
|
|
|
results.Add(new
|
|
|
{
|
|
|
+ platform = e.platform + 1,
|
|
|
report_date = e.report_date.ToString("yyyy-MM-dd"),
|
|
|
type = e.data_type,
|
|
|
e.uclk_uv,
|
|
|
@@ -251,6 +262,7 @@ namespace molilian.core
|
|
|
{
|
|
|
results.Add(new
|
|
|
{
|
|
|
+ platform = e.platform + 1,
|
|
|
report_date = e.report_date.ToString("yyyy-MM-dd"),
|
|
|
type = e.data_type,
|
|
|
e.uclk_uv,
|
|
|
@@ -275,6 +287,7 @@ namespace molilian.core
|
|
|
{
|
|
|
results.Add(new
|
|
|
{
|
|
|
+ platform = e.platform + 1,
|
|
|
report_date = e.report_date.ToString("yyyy-MM-dd"),
|
|
|
type = e.data_type,
|
|
|
e.uclk_uv,
|
|
|
@@ -300,6 +313,7 @@ namespace molilian.core
|
|
|
{
|
|
|
results.Add(new
|
|
|
{
|
|
|
+ platform = e.platform + 1,
|
|
|
report_date = e.report_date.ToString("yyyy-MM-dd"),
|
|
|
type = e.data_type,
|
|
|
e.uclk_uv,
|