This commit is contained in:
parent
3f580831a1
commit
b2cf921b9a
@ -14,7 +14,7 @@ namespace NeDvachAPI.Controllers
|
|||||||
//Post[] posts = DBchat.DbList();
|
//Post[] posts = DBchat.DbList();
|
||||||
List<Post> posts = DBchat.DbList();
|
List<Post> posts = DBchat.DbList();
|
||||||
string postsJson = JsonSerializer.Serialize(posts);
|
string postsJson = JsonSerializer.Serialize(posts);
|
||||||
Console.WriteLine("Запрошен список постов.);
|
Console.WriteLine("Запрошен список постов");
|
||||||
return postsJson ;
|
return postsJson ;
|
||||||
|
|
||||||
|
|
||||||
|
@ -65,17 +65,11 @@ namespace NeDvachAPI
|
|||||||
//);
|
//);
|
||||||
Post receivedPost = new()
|
Post receivedPost = new()
|
||||||
{
|
{
|
||||||
<<<<<<< HEAD
|
|
||||||
Id = reader.GetInt32(0),
|
Id = reader.GetInt32(0),
|
||||||
Text = reader.GetString(1),
|
Text = reader.GetString(1),
|
||||||
Timestamp = reader.GetString(2),
|
Timestamp = reader.GetString(2),
|
||||||
ImgURL = (string)reader.GetString(3)
|
ImgURL = (string)reader.GetString(3)
|
||||||
=======
|
|
||||||
//Date = DateTime.Now,
|
|
||||||
Id = reader.GetInt32(0),
|
|
||||||
Text = reader.GetString(1),
|
|
||||||
Timestamp = reader.GetString(2)
|
|
||||||
>>>>>>> 10b089091585b363d2cf227a688da611f5870b5d
|
|
||||||
};
|
};
|
||||||
posts.Add(receivedPost);
|
posts.Add(receivedPost);
|
||||||
//posts[postCount] = receivedPost;
|
//posts[postCount] = receivedPost;
|
||||||
|
Reference in New Issue
Block a user