|
@@ -653,17 +653,17 @@ namespace GxPress.Repository.Implement.Media
|
|
|
/// 每日技能
|
|
|
/// </summary>
|
|
|
/// <returns></returns>
|
|
|
- public async Task<MediaCathedraResult> GetRandomDaySkillAsync()
|
|
|
+ public async Task<SkillInfo> GetRandomDaySkillAsync()
|
|
|
{
|
|
|
var sql = $@"SELECT
|
|
|
- Id,ImageUrls,Title,Author,MediaType,ReadCount,CreatedDate
|
|
|
+ Id,Blocks
|
|
|
FROM
|
|
|
tede_media IsExercises=1 and MediaType={AllTypeConst.Article.GetHashCode()}
|
|
|
ORDER BY RAND() LIMIT 1";
|
|
|
var databaseType = _databaseTypestr.ToEnum<DatabaseType>(DatabaseType.MySql);
|
|
|
var database = new Database(databaseType, _connectionString);
|
|
|
var connection = database.GetConnection();
|
|
|
- return await connection.QueryFirstAsync<MediaCathedraResult>(sql);
|
|
|
+ return await connection.QueryFirstAsync<SkillInfo>(sql);
|
|
|
}
|
|
|
}
|
|
|
}
|