using Microsoft.Azure.Cosmos.Table;
using System;
using System.Collections.Generic;
using System.Text;
namespace TEAMModelOS.SDK.Models.Table
{
///
/// 前端多语言处理
///
//public string title { get; set; }
///
/// 前端多语言处理
///
//public string content { get; set; }
/*
{
"title":"通知标题",
"type":"通知类型",
"level":"重要程度",
"content":"通知内容",
"data":"传输数据josn",
"stime":"发起时间戳",
"etime":"到期时间戳",
"id":"通知id",
"code":"发起人"
"pk":"notice"
}
*/
///
/// 通知主体存放位置:/notice/{业务id}.json
/// 通知主体存放位置: /notice/{业务id}.json
/// 活跃通知放在CosmosDB Common表中,并设置"ttl":2592000,不能超过30天(2592000),一天(3600),一周(25200),允许删除
/// 过期通知存放至blob中,存放位置, 允许被删除,直接删除记录
/// stuid:/student/stuid/receiver/xxxx时间戳排序.json
/// tmdid:/receiver/xxxx时间戳排序.json
///
public class Notice
{
///
/// 业务的id
///
public string id { get; set; }
///
/// Notice-{hbcn/tmdid}
///
public string code { get; set; }
public string scode { get; set; }
public string school { get; set; }
public string scope { get; set; }
public string spk { get; set; }
///
/// 通知
///
public string pk { get; set; } = "Notice";
///
/// 类型
///
public string type { get; set; }
public int level { get; set; }
public string data { get; set; }
public int stime { get; set; }
public int etime { get; set; }
///
/// 被通知的醍摩豆账号
///
public List tmdids { get; set; }
///
/// 被通知的学校学生账号
///
public List stuids { get; set; }
}
/*
{
"id":"通知id"
"code":"接收者1",
"status":"接收状态/已发送/已查看",
"pk":"receiver",
"ttl":2592000,不能超过30天(2592000),一天(3600),一周(25200)
}
*/
public class Receiver : CosmosEntity
{
public string pk { get; set; } = "Receiver";
///
/// 0 已发送,1已查看,2已处理,-1已过期
///
public int status { get; set; }=0;
}
}