|
@@ -15,16 +15,23 @@ namespace Util
|
|
//发奖入口
|
|
//发奖入口
|
|
public static void sendPrize(string content)
|
|
public static void sendPrize(string content)
|
|
{
|
|
{
|
|
- batchNo = DateTime.Now.ToString("yyyyMMddHHmmssfff") + Function.get_Random(3);
|
|
|
|
- JsonData jsonObj = JsonMapper.ToObject(content);
|
|
|
|
- string priObjString = prizeInSet(int.Parse(Function.CheckInt(jsonObj["prize_tag"].ToString())));
|
|
|
|
- content = jsonObj["content"].ToString();
|
|
|
|
- if(!string.IsNullOrEmpty(priObjString))
|
|
|
|
|
|
+ try
|
|
{
|
|
{
|
|
- string[] priObjData = priObjString.Split('|');
|
|
|
|
- string priListIds = priObjData[0];
|
|
|
|
- int projectId = int.Parse(priObjData[1]);
|
|
|
|
- prizeSend(projectId, priListIds, content);
|
|
|
|
|
|
+ batchNo = DateTime.Now.ToString("yyyyMMddHHmmssfff") + Function.get_Random(3);
|
|
|
|
+ JsonData jsonObj = JsonMapper.ToObject(content);
|
|
|
|
+ string priObjString = prizeInSet(int.Parse(Function.CheckInt(jsonObj["prize_tag"].ToString())));
|
|
|
|
+ content = jsonObj["content"].ToString();
|
|
|
|
+ if(!string.IsNullOrEmpty(priObjString))
|
|
|
|
+ {
|
|
|
|
+ string[] priObjData = priObjString.Split('|');
|
|
|
|
+ string priListIds = priObjData[0];
|
|
|
|
+ int projectId = int.Parse(priObjData[1]);
|
|
|
|
+ prizeSend(projectId, priListIds, content);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ catch(Exception ex)
|
|
|
|
+ {
|
|
|
|
+ Function.WriteLog(DateTime.Now + "\n" + ex.ToString(), "发奖异常");
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|