[英]Unable to add "mbox" in actor of learning locker
我正在開發一個 .NET 核心應用程序並使用學習儲物櫃。 我正在使用 TinCan API 與學習儲物櫃進行通信。 我用於創建演員以學習更衣室語句的代碼是:
public Agent MakeActor(bool anonymous)
{
return new Agent
{
name = anonymous ? AnonymousUser : UserName,
account = new AgentAccount
{
name = anonymous ? AnonymousUser : UserId.ToString(),
homePage = new Uri(StringHelper.ResolveHostName(Name,AwsDefines.AwsDomain))
}
};
}
現在我還必須在記錄中添加用戶電子郵件地址。 我從谷歌得到的是演員中有一個“mbox”字段,可用於添加電子郵件地址。 所以我更新了我的代碼:
public Agent MakeActor(bool anonymous)
{
return new Agent
{
name = anonymous ? AnonymousUser : UserName,
mbox = UserEmailAddress,
account = new AgentAccount
{
name = anonymous ? AnonymousUser : UserId.ToString(),
homePage = new Uri(StringHelper.ResolveHostName(Name,AwsDefines.AwsDomain))
}
};
}
現在我在演員的 mbox 字段中有我的電子郵件地址,但是當我保存語句並在學習儲物櫃中看到它時,“mbox”字段未保存,“mbox”字段甚至不存在演員。
任何幫助他都會非常感激。
account
屬性和mbox
都是 IFI(逆功能標識符),因此要求在 Agent 對象中是唯一的。
An Agent MUST NOT include more than one (1) Inverse Functional Identifier;
(參考: https : //github.com/adlnet/xAPI-Spec/blob/master/xAPI-Data.md#2421-when-the-actor-objecttype-is-agent )
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.