|
@@ -453,7 +453,7 @@ namespace TEAMModelOS.Services.Common
|
|
|
var client = _azureCosmos.GetCosmosClient();
|
|
|
Survey survey = null;
|
|
|
///TODO 检查是否在投票范围内,包括在tmdids 及班级 但是需要处理认证金钥中的班级问题
|
|
|
- await foreach (var item in client.GetContainer("TEAMModelOS", "Common").GetItemQueryIterator<Survey>(queryText: $"select c.id,c.code , c.progress,c.times,c.voteNum,c.startTime,c.endTime from c where c.id = '{id}'",
|
|
|
+ await foreach (var item in client.GetContainer("TEAMModelOS", "Common").GetItemQueryIterator<Survey>(queryText: $"select c.id,c.owner, c.code ,c.ans , c.progress,c.times,c.startTime,c.endTime from c where c.id = '{id}'",
|
|
|
requestOptions: new QueryRequestOptions() { PartitionKey = new PartitionKey($"{code}") }))
|
|
|
{
|
|
|
survey = item;
|
|
@@ -518,7 +518,8 @@ namespace TEAMModelOS.Services.Common
|
|
|
}
|
|
|
}
|
|
|
//保存当前提交人的记录
|
|
|
- await _azureStorage.UploadFileByContainer(survey.owner, record.ToJsonString(), "survey", $"{survey.name}/record/{userid}.json");
|
|
|
+ await _azureStorage.UploadFileByContainer(survey.owner, record.ToJsonString(), "survey", $"{survey.name}/record/{userid}.json");
|
|
|
+ msgid = 1;
|
|
|
}
|
|
|
else {
|
|
|
//提交的作答不符合问卷的答案长度。
|