Skip to content

Commit 222e4f7

Browse files
authored
Merge pull request #1137 from iceljc/master
fix datetime convert
2 parents 7a3171c + d413a08 commit 222e4f7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Plugins/BotSharp.Plugin.Qdrant/QdrantDb.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ public async Task<bool> Upsert(string collectionName, Guid id, float[] vector, s
230230
{
231231
foreach (var item in payload)
232232
{
233-
var value = item.Value.DataValue?.ToString();
233+
var value = item.Value.DataValue?.ConvertToString();
234234
if (value == null || item.Key.IsEqualTo(KnowledgePayloadName.Text))
235235
{
236236
continue;
@@ -248,7 +248,7 @@ public async Task<bool> Upsert(string collectionName, Guid id, float[] vector, s
248248
point.Payload[item.Key] = doubleVal;
249249
break;
250250
case VectorPayloadDataType.Datetime when DateTime.TryParse(value, out var dt):
251-
point.Payload[item.Key] = dt.ToUniversalTime().ToString("o");
251+
point.Payload[item.Key] = dt.ToString("o");
252252
break;
253253
case VectorPayloadDataType.String:
254254
point.Payload[item.Key] = value;

0 commit comments

Comments
 (0)