json新版本

DS7Zhanhao
hanxuntao 2 years ago
parent 79f6038e72
commit d7ed85e16d

@ -124,6 +124,9 @@
<Reference Include="MimeKit, Version=2.4.0.0, Culture=neutral, PublicKeyToken=bede1c8a46c66814, processorArchitecture=MSIL"> <Reference Include="MimeKit, Version=2.4.0.0, Culture=neutral, PublicKeyToken=bede1c8a46c66814, processorArchitecture=MSIL">
<HintPath>..\packages\MimeKit.2.4.1\lib\net45\MimeKit.dll</HintPath> <HintPath>..\packages\MimeKit.2.4.1\lib\net45\MimeKit.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="NPOI, Version=2.4.1.0, Culture=neutral, PublicKeyToken=0df73ec7942b34e1, processorArchitecture=MSIL"> <Reference Include="NPOI, Version=2.4.1.0, Culture=neutral, PublicKeyToken=0df73ec7942b34e1, processorArchitecture=MSIL">
<HintPath>..\packages\NPOI.2.4.1\lib\net45\NPOI.dll</HintPath> <HintPath>..\packages\NPOI.2.4.1\lib\net45\NPOI.dll</HintPath>
</Reference> </Reference>
@ -203,9 +206,6 @@
<Private>True</Private> <Private>True</Private>
<HintPath>..\packages\Microsoft.AspNet.WebPages.3.2.4\lib\net45\System.Web.WebPages.Razor.dll</HintPath> <HintPath>..\packages\Microsoft.AspNet.WebPages.3.2.4\lib\net45\System.Web.WebPages.Razor.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json">
<HintPath>..\packages\Newtonsoft.Json.11.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="WebGrease"> <Reference Include="WebGrease">
<Private>True</Private> <Private>True</Private>
<HintPath>..\packages\WebGrease.1.6.0\lib\WebGrease.dll</HintPath> <HintPath>..\packages\WebGrease.1.6.0\lib\WebGrease.dll</HintPath>

@ -85,7 +85,7 @@
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" /> <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" />
<bindingRedirect oldVersion="0.0.0.0-11.0.0.0" newVersion="11.0.0.0" /> <bindingRedirect oldVersion="0.0.0.0-13.0.0.0" newVersion="13.0.0.0" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" /> <assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />

@ -35,7 +35,7 @@
<package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net451" /> <package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net451" />
<package id="MimeKit" version="2.4.1" targetFramework="net451" /> <package id="MimeKit" version="2.4.1" targetFramework="net451" />
<package id="Modernizr" version="2.8.3" targetFramework="net451" /> <package id="Modernizr" version="2.8.3" targetFramework="net451" />
<package id="Newtonsoft.Json" version="11.0.1" targetFramework="net451" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net451" />
<package id="NPOI" version="2.4.1" targetFramework="net451" /> <package id="NPOI" version="2.4.1" targetFramework="net451" />
<package id="Portable.BouncyCastle" version="1.8.1.3" targetFramework="net451" /> <package id="Portable.BouncyCastle" version="1.8.1.3" targetFramework="net451" />
<package id="Quartz" version="2.6.2" targetFramework="net451" /> <package id="Quartz" version="2.6.2" targetFramework="net451" />

@ -85,6 +85,9 @@
<Reference Include="MimeKit, Version=2.4.0.0, Culture=neutral, PublicKeyToken=bede1c8a46c66814, processorArchitecture=MSIL"> <Reference Include="MimeKit, Version=2.4.0.0, Culture=neutral, PublicKeyToken=bede1c8a46c66814, processorArchitecture=MSIL">
<HintPath>..\packages\MimeKit.2.4.1\lib\net45\MimeKit.dll</HintPath> <HintPath>..\packages\MimeKit.2.4.1\lib\net45\MimeKit.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="NPOI, Version=2.4.1.0, Culture=neutral, PublicKeyToken=0df73ec7942b34e1, processorArchitecture=MSIL"> <Reference Include="NPOI, Version=2.4.1.0, Culture=neutral, PublicKeyToken=0df73ec7942b34e1, processorArchitecture=MSIL">
<HintPath>..\packages\NPOI.2.4.1\lib\net45\NPOI.dll</HintPath> <HintPath>..\packages\NPOI.2.4.1\lib\net45\NPOI.dll</HintPath>
</Reference> </Reference>
@ -156,9 +159,6 @@
<Private>True</Private> <Private>True</Private>
<HintPath>..\packages\Microsoft.AspNet.WebPages.3.2.4\lib\net45\System.Web.WebPages.Razor.dll</HintPath> <HintPath>..\packages\Microsoft.AspNet.WebPages.3.2.4\lib\net45\System.Web.WebPages.Razor.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json">
<HintPath>..\packages\Newtonsoft.Json.11.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="WebGrease"> <Reference Include="WebGrease">
<Private>True</Private> <Private>True</Private>
<HintPath>..\packages\WebGrease.1.6.0\lib\WebGrease.dll</HintPath> <HintPath>..\packages\WebGrease.1.6.0\lib\WebGrease.dll</HintPath>

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<!-- <!--
有关如何配置 ASP.NET 应用程序的详细信息,请访问 有关如何配置 ASP.NET 应用程序的详细信息,请访问
https://go.microsoft.com/fwlink/?LinkId=301880 https://go.microsoft.com/fwlink/?LinkId=301880
@ -74,7 +74,7 @@
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" /> <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" />
<bindingRedirect oldVersion="0.0.0.0-11.0.0.0" newVersion="11.0.0.0" /> <bindingRedirect oldVersion="0.0.0.0-13.0.0.0" newVersion="13.0.0.0" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" /> <assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />

@ -31,7 +31,7 @@
<package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net451" /> <package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net451" />
<package id="MimeKit" version="2.4.1" targetFramework="net451" /> <package id="MimeKit" version="2.4.1" targetFramework="net451" />
<package id="Modernizr" version="2.8.3" targetFramework="net451" /> <package id="Modernizr" version="2.8.3" targetFramework="net451" />
<package id="Newtonsoft.Json" version="11.0.1" targetFramework="net451" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net451" />
<package id="NPOI" version="2.4.1" targetFramework="net451" /> <package id="NPOI" version="2.4.1" targetFramework="net451" />
<package id="Quartz" version="2.6.2" targetFramework="net451" /> <package id="Quartz" version="2.6.2" targetFramework="net451" />
<package id="SharpZipLib" version="1.0.0" targetFramework="net451" /> <package id="SharpZipLib" version="1.0.0" targetFramework="net451" />

@ -43,8 +43,8 @@
<Reference Include="log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=1b44e1d426115821, processorArchitecture=MSIL"> <Reference Include="log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=1b44e1d426115821, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.1.2.10\lib\2.0\log4net.dll</HintPath> <HintPath>..\packages\log4net.1.2.10\lib\2.0\log4net.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll</HintPath> <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference> </Reference>
<Reference Include="NuonuoSDK"> <Reference Include="NuonuoSDK">
<HintPath>..\Lib\NuonuoSDK.dll</HintPath> <HintPath>..\Lib\NuonuoSDK.dll</HintPath>

@ -2,5 +2,5 @@
<packages> <packages>
<package id="EntityFramework" version="6.4.4" targetFramework="net45" /> <package id="EntityFramework" version="6.4.4" targetFramework="net45" />
<package id="log4net" version="1.2.10" targetFramework="net45" /> <package id="log4net" version="1.2.10" targetFramework="net45" />
<package id="Newtonsoft.Json" version="12.0.3" targetFramework="net45" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net45" />
</packages> </packages>

@ -0,0 +1,511 @@
using System;
using System.Text;
using System.Security.Cryptography;
using System.Collections.Generic;
using System.Linq;
using DSWeb.MvcShipping.Helper;
namespace Dingtalk
{
public class DingCallBackMsg
{
public string EventType { get; set; }
public string processInstanceId { get; set; }
public string corpId { get; set; }
public string createTime { get; set; }
public string title { get; set; }
public string type { get; set; }
public string staffId { get; set; }
public string url { get; set; }
public string processCode { get; set; }
public string result { get; set; }
}
/**
*
*/
public class DingTalkEncryptor
{
//private static readonly Charset CHARSET = Charset.forName("utf-8");
//private static readonly Base64 base64 = new Base64();
private byte[] aesKey;
private String token;
private String corpId;
/**ask getPaddingBytes key固定长度**/
private static readonly int AES_ENCODE_KEY_LENGTH = 43;
/**加密随机字符串字节长度**/
private static readonly int RANDOM_LENGTH = 16;
/**
*
* @param token token
* @param encodingAesKey EncodingAESKey
* @param corpId -, 使appKey
* -, 使corpId
* , 使suiteKey
*
* @throws DingTalkEncryptException
*/
public DingTalkEncryptor(String token, String encodingAesKey, String corpId)
{
if (null == encodingAesKey || encodingAesKey.Length != AES_ENCODE_KEY_LENGTH)
{
throw new DingTalkEncryptException(DingTalkEncryptException.AES_KEY_ILLEGAL);
}
this.token = token;
this.corpId = corpId;
aesKey = Convert.FromBase64String(encodingAesKey + "=");
}
/**
* ,Map
*/
public Dictionary<String, String> getEncryptedMap(String plaintext)
{
var time = DateTime.Now.Millisecond;
return getEncryptedMap(plaintext, time);
}
/**
* ,Map
* @param plaintext
* @param timeStamp
* @param nonce
* @return
* @throws DingTalkEncryptException
*/
public Dictionary<String, String> getEncryptedMap(String plaintext, long timeStamp)
{
if (null == plaintext)
{
throw new DingTalkEncryptException(DingTalkEncryptException.ENCRYPTION_PLAINTEXT_ILLEGAL);
}
var nonce = Utils.getRandomStr(RANDOM_LENGTH);
if (null == nonce)
{
throw new DingTalkEncryptException(DingTalkEncryptException.ENCRYPTION_NONCE_ILLEGAL);
}
String encrypt = this.encrypt(nonce, plaintext);
String signature = getSignature(token, timeStamp.ToString(), nonce, encrypt);
Dictionary<String, String> resultMap = new Dictionary<String, String>();
resultMap["msg_signature"] = signature;
resultMap["encrypt"] = encrypt;
resultMap["timeStamp"] = timeStamp.ToString();
resultMap["nonce"] = nonce;
return resultMap;
}
/**
*
* @param msgSignature
* @param timeStamp
* @param nonce
* @param encryptMsg
* @return
* @throws DingTalkEncryptException
*/
public String getDecryptMsg(String msgSignature, String timeStamp, String nonce, String encryptMsg)
{
//校验签名
String signature = getSignature(token, timeStamp, nonce, encryptMsg);
if (!signature.Equals(msgSignature))
{
throw new DingTalkEncryptException(DingTalkEncryptException.COMPUTE_SIGNATURE_ERROR);
}
// 解密
String result = decrypt(encryptMsg);
return result;
}
/*
* .
* @param text
* @return base64
*/
private String encrypt(String random, String plaintext)
{
try
{
byte[] randomBytes = System.Text.Encoding.UTF8.GetBytes(random);// random.getBytes(CHARSET);
byte[] plainTextBytes = System.Text.Encoding.UTF8.GetBytes(plaintext);// plaintext.getBytes(CHARSET);
byte[] lengthByte = Utils.int2Bytes(plainTextBytes.Length);
byte[] corpidBytes = System.Text.Encoding.UTF8.GetBytes(corpId);// corpId.getBytes(CHARSET);
//MemoryStream byteStream = new MemoryStream();
var bytestmp = new List<byte>();
bytestmp.AddRange(randomBytes);
bytestmp.AddRange(lengthByte);
bytestmp.AddRange(plainTextBytes);
bytestmp.AddRange(corpidBytes);
byte[] padBytes = PKCS7Padding.getPaddingBytes(bytestmp.Count);
bytestmp.AddRange(padBytes);
byte[] unencrypted = bytestmp.ToArray();
RijndaelManaged rDel = new RijndaelManaged();
rDel.Mode = CipherMode.CBC;
rDel.Padding = PaddingMode.Zeros;
rDel.Key = aesKey;
rDel.IV = aesKey.ToList().Take(16).ToArray();
ICryptoTransform cTransform = rDel.CreateEncryptor();
byte[] resultArray = cTransform.TransformFinalBlock(unencrypted, 0, unencrypted.Length);
return Convert.ToBase64String(resultArray, 0, resultArray.Length);
//Cipher cipher = Cipher.getInstance("AES/CBC/NoPadding");
//SecretKeySpec keySpec = new SecretKeySpec(aesKey, "AES");
//IvParameterSpec iv = new IvParameterSpec(aesKey, 0, 16);
//cipher.init(Cipher.ENCRYPT_MODE, keySpec, iv);
//byte[] encrypted = cipher.doFinal(unencrypted);
//String result = base64.encodeToString(encrypted);
//return result;
}
catch (Exception e)
{
throw new DingTalkEncryptException(DingTalkEncryptException.COMPUTE_ENCRYPT_TEXT_ERROR);
}
}
/*
* .
* @param text
* @return
*/
private String decrypt(String text)
{
byte[] originalArr;
try
{
byte[] toEncryptArray = Convert.FromBase64String(text);
RijndaelManaged rDel = new RijndaelManaged();
rDel.Mode = CipherMode.CBC;
rDel.Padding = PaddingMode.Zeros;
rDel.Key = aesKey;
rDel.IV = aesKey.ToList().Take(16).ToArray();
ICryptoTransform cTransform = rDel.CreateDecryptor();
originalArr = cTransform.TransformFinalBlock(toEncryptArray, 0, toEncryptArray.Length);
//return System.Text.UTF8Encoding.UTF8.GetString(resultArray);
//// 设置解密模式为AES的CBC模式
//Cipher cipher = Cipher.getInstance("AES/CBC/NoPadding");
//SecretKeySpec keySpec = new SecretKeySpec(aesKey, "AES");
//IvParameterSpec iv = new IvParameterSpec(Arrays.copyOfRange(aesKey, 0, 16));
//cipher.init(Cipher.DECRYPT_MODE, keySpec, iv);
//// 使用BASE64对密文进行解码
//byte[] encrypted = Base64.decodeBase64(text);
//// 解密
//originalArr = cipher.doFinal(encrypted);
}
catch (Exception e)
{
throw new DingTalkEncryptException(DingTalkEncryptException.COMPUTE_DECRYPT_TEXT_ERROR);
}
String plainText;
String fromCorpid;
try
{
// 去除补位字符
byte[] bytes = PKCS7Padding.removePaddingBytes(originalArr);
Console.Out.WriteLine("bytes size:" + bytes.Length);
// 分离16位随机字符串,网络字节序和corpId
byte[] networkOrder = bytes.Skip(16).Take(4).ToArray();// Arrays.copyOfRange(bytes, 16, 20);
for (int i = 0; i < 4; i++)
{
Console.Out.WriteLine("networkOrder size:" + (int)networkOrder[i]);
}
Console.Out.WriteLine("bytes plainText:" + networkOrder.Length + " " + JsonConvert.Serialize(networkOrder));
int plainTextLegth = Utils.bytes2int(networkOrder);
Console.Out.WriteLine("bytes size:" + plainTextLegth);
plainText = System.Text.UTF8Encoding.UTF8.GetString(bytes.Skip(20).Take(plainTextLegth).ToArray()); // new String(Arrays.copyOfRange(bytes, 20, 20 + plainTextLegth), CHARSET);
fromCorpid = System.Text.UTF8Encoding.UTF8.GetString(bytes.Skip(20 + plainTextLegth).ToArray()); //new String(Arrays.copyOfRange(bytes, 20 + plainTextLegth, bytes.length), CHARSET);
Console.Out.WriteLine("bytes plainText:" + plainText);
}
catch (Exception e)
{
throw new DingTalkEncryptException(DingTalkEncryptException.COMPUTE_DECRYPT_TEXT_LENGTH_ERROR);
}
Console.Out.WriteLine(fromCorpid + "=====" + corpId);
// corpid不相同的情况
if (!fromCorpid.Equals(corpId))
{
throw new DingTalkEncryptException(DingTalkEncryptException.COMPUTE_DECRYPT_TEXT_CORPID_ERROR);
}
return plainText;
}
/**
*
* @param token isv token
* @param timestamp
* @param nonce
* @param encrypt
* @return
* @throws DingTalkEncryptException
*/
public String getSignature(String token, String timestamp, String nonce, String encrypt)
{
try
{
Console.Out.WriteLine(encrypt);
String[] array = new String[] { token, timestamp, nonce, encrypt };
Array.Sort(array, StringComparer.Ordinal);
//var tmparray = array.ToList();
//tmparray.Sort(new JavaStringComper());
//array = tmparray.ToArray();
Console.Out.WriteLine("array:" + JsonConvert.Serialize(array));
StringBuilder sb = new StringBuilder();
for (int i = 0; i < 4; i++)
{
sb.Append(array[i]);
}
String str = sb.ToString();
Console.Out.WriteLine(str);
//MessageDigest md = MessageDigest.getInstance("SHA-1");
//md.update(str.getBytes());
//byte[] digest = md.digest();
System.Security.Cryptography.SHA1 hash = System.Security.Cryptography.SHA1.Create();
System.Text.Encoding encoder = System.Text.Encoding.ASCII;
byte[] combined = encoder.GetBytes(str);
////byte 转换
//sbyte[] myByte = new sbyte[]
//byte[] mySByte = new byte[myByte.Length];
//for (int i = 0; i < myByte.Length; i++)
//{
// if (myByte[i] > 127)
// mySByte[i] = (sbyte)(myByte[i] - 256);
// else
// mySByte[i] = (sbyte)myByte[i];
//}
byte[] digest = hash.ComputeHash(combined);
StringBuilder hexstr = new StringBuilder();
String shaHex = "";
for (int i = 0; i < digest.Length; i++)
{
shaHex = ((int)digest[i]).ToString("x");// Integer.toHexString(digest[i] & 0xFF);
if (shaHex.Length < 2)
{
hexstr.Append(0);
}
hexstr.Append(shaHex);
}
return hexstr.ToString();
}
catch (Exception e)
{
throw new DingTalkEncryptException(DingTalkEncryptException.COMPUTE_SIGNATURE_ERROR);
}
}
}
/**
*
*/
public class DingTalkEncryptException : Exception
{
/**成功**/
public static readonly int SUCCESS = 0;
/**加密明文文本非法**/
public readonly static int ENCRYPTION_PLAINTEXT_ILLEGAL = 900001;
/**加密时间戳参数非法**/
public readonly static int ENCRYPTION_TIMESTAMP_ILLEGAL = 900002;
/**加密随机字符串参数非法**/
public readonly static int ENCRYPTION_NONCE_ILLEGAL = 900003;
/**不合法的aeskey**/
public readonly static int AES_KEY_ILLEGAL = 900004;
/**签名不匹配**/
public readonly static int SIGNATURE_NOT_MATCH = 900005;
/**计算签名错误**/
public readonly static int COMPUTE_SIGNATURE_ERROR = 900006;
/**计算加密文字错误**/
public readonly static int COMPUTE_ENCRYPT_TEXT_ERROR = 900007;
/**计算解密文字错误**/
public readonly static int COMPUTE_DECRYPT_TEXT_ERROR = 900008;
/**计算解密文字长度不匹配**/
public readonly static int COMPUTE_DECRYPT_TEXT_LENGTH_ERROR = 900009;
/**计算解密文字corpid不匹配**/
public readonly static int COMPUTE_DECRYPT_TEXT_CORPID_ERROR = 900010;
private static Dictionary<int, String> msgMap = new Dictionary<int, String>();
static DingTalkEncryptException()
{
msgMap[SUCCESS] = "成功";
msgMap[ENCRYPTION_PLAINTEXT_ILLEGAL] = "加密明文文本非法";
msgMap[ENCRYPTION_TIMESTAMP_ILLEGAL] = "加密时间戳参数非法";
msgMap[ENCRYPTION_NONCE_ILLEGAL] = "加密随机字符串参数非法";
msgMap[SIGNATURE_NOT_MATCH] = "签名不匹配";
msgMap[COMPUTE_SIGNATURE_ERROR] = "签名计算失败";
msgMap[AES_KEY_ILLEGAL] = "不合法的aes key";
msgMap[COMPUTE_ENCRYPT_TEXT_ERROR] = "计算加密文字错误";
msgMap[COMPUTE_DECRYPT_TEXT_ERROR] = "计算解密文字错误";
msgMap[COMPUTE_DECRYPT_TEXT_LENGTH_ERROR] = "计算解密文字长度不匹配";
msgMap[COMPUTE_DECRYPT_TEXT_CORPID_ERROR] = "计算解密文字corpid不匹配";
}
private int code;
public DingTalkEncryptException(int exceptionCode) : base(msgMap[exceptionCode])
{
this.code = exceptionCode;
}
}
/*
* PKCS7
*/
public class PKCS7Padding
{
//private readonly static Charset CHARSET = Charset.forName("utf-8");
private readonly static int BLOCK_SIZE = 32;
/**
* mode
* @param count
* @return
*/
public static byte[] getPaddingBytes(int count)
{
int amountToPad = BLOCK_SIZE - (count % BLOCK_SIZE);
if (amountToPad == 0)
{
amountToPad = BLOCK_SIZE;
}
char padChr = chr(amountToPad);
String tmp = string.Empty; ;
for (int index = 0; index < amountToPad; index++)
{
tmp += padChr;
}
return System.Text.Encoding.UTF8.GetBytes(tmp);
}
/**
* mode
* @param decrypted
* @return
*/
public static byte[] removePaddingBytes(byte[] decrypted)
{
int pad = (int)decrypted[decrypted.Length - 1];
if (pad < 1 || pad > BLOCK_SIZE)
{
pad = 0;
}
//Array.Copy()
var output = new byte[decrypted.Length - pad];
Array.Copy(decrypted, output, decrypted.Length - pad);
return output;
}
private static char chr(int a)
{
byte target = (byte)(a & 0xFF);
return (char)target;
}
}
/**
*
*/
public class Utils
{
/**
*
* @return
*/
public static String getRandomStr(int count)
{
String baset = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
Random random = new Random();
StringBuilder sb = new StringBuilder();
for (int i = 0; i < count; i++)
{
int number = random.Next(baset.Length);
sb.Append(baset[number]);
}
return sb.ToString();
}
/*
* intbyte,
*/
public static byte[] int2Bytes(int count)
{
byte[] byteArr = new byte[4];
byteArr[3] = (byte)(count & 0xFF);
byteArr[2] = (byte)(count >> 8 & 0xFF);
byteArr[1] = (byte)(count >> 16 & 0xFF);
byteArr[0] = (byte)(count >> 24 & 0xFF);
return byteArr;
}
/**
* bytesint
* @param byteArr
* @return
*/
public static int bytes2int(byte[] byteArr)
{
int count = 0;
for (int i = 0; i < 4; ++i)
{
count <<= 8;
count |= byteArr[i] & 255;
}
return count;
}
}
public class JavaStringComper : IComparer<string>
{
public int Compare(string x, string y)
{
return String.Compare(x, y);
}
}
//// 测试加解密的正确性
//public class Program
//{
// public static void Main(string[] args)
// {
// String[] a = new String[] { "1", "W", "t" };
// var ding = new DingTalkEncryptor("tokenxxxx", "o1w0aum42yaptlz8alnhwikjd3jenzt9cb9wmzptgus", "dingxxxxxx");
// var msg = ding.getEncryptedMap("success");
// Console.Out.WriteLine(msg);
// //msg_signature, $data->timeStamp, $data->nonce, $data->encrypt
// var text = ding.getDecryptMsg(msg["msg_signature"], msg["timeStamp"], msg["nonce"], msg["encrypt"]);
// Console.Out.WriteLine(text);
// // "msg_signature":"c01beb7b06384cf416e04930aed794684aae98c1","encrypt":"","timeStamp":,"nonce":""
// //{"timeStamp":"1605695694141","msg_signature":"702c953056613f5c7568b79ed134a27bd2dcd8d0",
// //"encrypt":"","nonce":"WelUQl6bCqcBa2fMc6eI"}
// text = ding.getDecryptMsg("f36f4ba5337d426c7d4bca0dbcb06b3ddc1388fc", "1605695694141", "WelUQl6bCqcBa2fM", "X1VSe9cTJUMZu60d3kyLYTrBq5578ZRJtteU94wG0Q4Uk6E/wQYeJRIC0/UFW5Wkya1Ihz9oXAdLlyC9TRaqsQ==");
// Console.Out.WriteLine(text);
// }
//}
}

@ -1088,7 +1088,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpSubSeaOrderDAL
headList.ORDNO = bill.ORDNO;//委托 headList.ORDNO = bill.ORDNO;//委托
headList.GID ="*";//业务编号 headList.GID ="*";//业务编号
headList.BSDATE = DateTime.Now;//接单日期 headList.BSDATE = DateTime.Now;//接单日期
headList.MBLNO ="32ES"+bill.MBLNO;//主提单号 headList.MBLNO ="43LG"+bill.MBLNO;//主提单号
headList.HBLNO =bill.MBLNO;//分提单号 headList.HBLNO =bill.MBLNO;//分提单号
headList.MESSRS =bill.CONSIGNEE;//收货人内容 headList.MESSRS =bill.CONSIGNEE;//收货人内容
headList.VESSEL =bill.VESSEL;//船名 headList.VESSEL =bill.VESSEL;//船名
@ -1121,8 +1121,8 @@ namespace DSWeb.MvcShipping.DAL.MsOpSubSeaOrderDAL
headList.DESCRIPTION=headList.DESCRIPTION + "\r\n\r\n " + bill.BLFRT; headList.DESCRIPTION=headList.DESCRIPTION + "\r\n\r\n " + bill.BLFRT;
headList.GROSSWEIGHT = bill.GROSSWEIGHT; headList.GROSSWEIGHT = bill.GROSSWEIGHT;
headList.MEASUREMENT = bill.MEASUREMENT; headList.MEASUREMENT = bill.MEASUREMENT;
headList.KGS = string.Format("{0:0.00}",bill.KGS); headList.KGS = bill.KGS.ToString();
headList.CBM = string.Format("{0:0.000}",bill.CBM); headList.CBM = bill.CBM.ToString();
headList.INPUTBY = username; headList.INPUTBY = username;
return headList; return headList;
@ -2953,7 +2953,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpSubSeaOrderDAL
var strRULEYEAR = dETD.ToString("yy") + dETD.ToString("MM"); var strRULEYEAR = dETD.ToString("yy") + dETD.ToString("MM");
int iRULENOLENGTH =4; int iRULENOLENGTH =4;
int inum = 0; int inum = 0;
var strCONTENT = "CWJIS" + strRULEYEAR; var strCONTENT = "NOSIS" + strRULEYEAR;
string strRULENOLENGTH = ""; string strRULENOLENGTH = "";
T_ALL_DA T_ALL_DA = new T_ALL_DA(); T_ALL_DA T_ALL_DA = new T_ALL_DA();

@ -60,7 +60,7 @@ Ext.extend(Shipping.MsOpBillLSEdit, Ext.Panel, {
displayField: 'CodeAndName' displayField: 'CodeAndName'
}); });
_thisbilledit = this;
//客户加载_发货人 //客户加载_发货人
@ -1702,12 +1702,12 @@ Ext.extend(Shipping.MsOpBillLSEdit, Ext.Panel, {
this.formEdit.getForm().findField('PLACERECEIPTID').setValue(this.MainEditRecord.data.PLACERECEIPTID); this.formEdit.getForm().findField('PLACERECEIPTID').setValue(this.MainEditRecord.data.PLACERECEIPTID);
Ext.MessageBox.confirm('提示', '要调入主单的收发通信息吗?', function (btn) { Ext.MessageBox.confirm('提示', '要调入主单的收发通信息吗?', function (btn) {
if (btn == 'yes') { if (btn == 'yes') {
_thisbilledit.formEdit.getForm().findField('SHIPPERID').setValue(_thisbilledit.MainEditRecord.data.SHIPPERID); this.formEdit.getForm().findField('SHIPPERID').setValue(this.MainEditRecord.data.SHIPPERID);
_thisbilledit.formEdit.getForm().findField('SHIPPER').setValue(_thisbilledit.MainEditRecord.data.SHIPPER); this.formEdit.getForm().findField('SHIPPER').setValue(this.MainEditRecord.data.SHIPPER);
_thisbilledit.formEdit.getForm().findField('CONSIGNEEID').setValue(_thisbilledit.MainEditRecord.data.CONSIGNEEID); this.formEdit.getForm().findField('CONSIGNEEID').setValue(this.MainEditRecord.data.CONSIGNEEID);
_thisbilledit.formEdit.getForm().findField('CONSIGNEE').setValue(_thisbilledit.MainEditRecord.data.CONSIGNEE); this.formEdit.getForm().findField('CONSIGNEE').setValue(this.MainEditRecord.data.CONSIGNEE);
_thisbilledit.formEdit.getForm().findField('NOTIFYPARTYID').setValue(_thisbilledit.MainEditRecord.data.NOTIFYPARTYID); this.formEdit.getForm().findField('NOTIFYPARTYID').setValue(this.MainEditRecord.data.NOTIFYPARTYID);
_thisbilledit.formEdit.getForm().findField('NOTIFYPARTY').setValue(_thisbilledit.MainEditRecord.data.NOTIFYPARTY); this.formEdit.getForm().findField('NOTIFYPARTY').setValue(this.MainEditRecord.data.NOTIFYPARTY);
} }
}); });
if (this.formEdit.getForm().findField('MBLNO').getValue() == '') if (this.formEdit.getForm().findField('MBLNO').getValue() == '')
@ -3771,9 +3771,9 @@ this.storeConsignee.on('beforeload', function (store) {
//this.formEdit.getForm().findField('NOTIFYPARTYNAME').setValue(this.formcd.getForm().findField('NOTIFYPARTYNAME').getValue()); //this.formEdit.getForm().findField('NOTIFYPARTYNAME').setValue(this.formcd.getForm().findField('NOTIFYPARTYNAME').getValue());
//this.formEdit.getForm().findField('NOTIFYPARTYADDR1').setValue(this.formcd.getForm().findField('NOTIFYPARTYADDR1').getValue()); //this.formEdit.getForm().findField('NOTIFYPARTYADDR1').setValue(this.formcd.getForm().findField('NOTIFYPARTYADDR1').getValue());
//this.formEdit.getForm().findField('SCACCODE').setValue(this.formcd.getForm().findField('SCACCODE').getValue()); //this.formEdit.getForm().findField('SCACCODE').setValue(this.formcd.getForm().findField('SCACCODE').getValue());
this.formEdit.getForm().findField('BSNO').setDisabled(false); this.formEdit.getForm().findField('AS_ID').setDisabled(false);
var data = this.formEdit.getForm().getValues(false, false, false); var data = this.formEdit.getForm().getValues(false, false, false);
this.formEdit.getForm().findField('BSNO').setDisabled(true); this.formEdit.getForm().findField('AS_ID').setDisabled(true);
var data2 = this.formcd.getForm().getValues(false, false, false); var data2 = this.formcd.getForm().getValues(false, false, false);
data.BSNO = this.MainEditRecord.data.BSNO; data.BSNO = this.MainEditRecord.data.BSNO;
Object.assign(data, data2); Object.assign(data, data2);

@ -314,9 +314,8 @@
<Reference Include="MimeKit, Version=2.9.0.0, Culture=neutral, PublicKeyToken=bede1c8a46c66814, processorArchitecture=MSIL"> <Reference Include="MimeKit, Version=2.9.0.0, Culture=neutral, PublicKeyToken=bede1c8a46c66814, processorArchitecture=MSIL">
<HintPath>..\packages\MimeKit.2.9.1\lib\net45\MimeKit.dll</HintPath> <HintPath>..\packages\MimeKit.2.9.1\lib\net45\MimeKit.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=11.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion> <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
<HintPath>bin\Newtonsoft.Json.dll</HintPath>
</Reference> </Reference>
<Reference Include="NPOI, Version=2.5.1.0, Culture=neutral, PublicKeyToken=0df73ec7942b34e1, processorArchitecture=MSIL"> <Reference Include="NPOI, Version=2.5.1.0, Culture=neutral, PublicKeyToken=0df73ec7942b34e1, processorArchitecture=MSIL">
<HintPath>..\packages\NPOI.2.5.1\lib\net45\NPOI.dll</HintPath> <HintPath>..\packages\NPOI.2.5.1\lib\net45\NPOI.dll</HintPath>

@ -33,7 +33,7 @@
<package id="Microsoft.Owin.Host.SystemWeb" version="2.1.0" targetFramework="net45" /> <package id="Microsoft.Owin.Host.SystemWeb" version="2.1.0" targetFramework="net45" />
<package id="Microsoft.Owin.Security" version="2.1.0" targetFramework="net45" /> <package id="Microsoft.Owin.Security" version="2.1.0" targetFramework="net45" />
<package id="MimeKit" version="2.9.1" targetFramework="net45" /> <package id="MimeKit" version="2.9.1" targetFramework="net45" />
<package id="Newtonsoft.Json" version="11.0.1" targetFramework="net40" requireReinstallation="true" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net45" />
<package id="NPOI" version="2.5.1" targetFramework="net45" /> <package id="NPOI" version="2.5.1" targetFramework="net45" />
<package id="NPOI.Excel" version="2.1.1" targetFramework="net45" /> <package id="NPOI.Excel" version="2.1.1" targetFramework="net45" />
<package id="Owin" version="1.0" targetFramework="net45" /> <package id="Owin" version="1.0" targetFramework="net45" />

@ -46,6 +46,9 @@
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="Microsoft.CSharp" /> <Reference Include="Microsoft.CSharp" />
<Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="System" /> <Reference Include="System" />
<Reference Include="System.Data" /> <Reference Include="System.Data" />
<Reference Include="System.Drawing" /> <Reference Include="System.Drawing" />
@ -99,9 +102,6 @@
<Private>True</Private> <Private>True</Private>
<HintPath>..\packages\Microsoft.AspNet.WebPages.3.2.4\lib\net45\System.Web.WebPages.Razor.dll</HintPath> <HintPath>..\packages\Microsoft.AspNet.WebPages.3.2.4\lib\net45\System.Web.WebPages.Razor.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json">
<HintPath>..\packages\Newtonsoft.Json.11.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="WebGrease"> <Reference Include="WebGrease">
<Private>True</Private> <Private>True</Private>
<HintPath>..\packages\WebGrease.1.6.0\lib\WebGrease.dll</HintPath> <HintPath>..\packages\WebGrease.1.6.0\lib\WebGrease.dll</HintPath>

@ -2,6 +2,13 @@
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup> <PropertyGroup>
<LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig> <LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig>
<UseIISExpress>true</UseIISExpress>
<Use64BitIISExpress />
<IISExpressSSLPort />
<IISExpressAnonymousAuthentication />
<IISExpressWindowsAuthentication />
<IISExpressUseClassicPipelineMode />
<UseGlobalApplicationHostFile />
</PropertyGroup> </PropertyGroup>
<ProjectExtensions> <ProjectExtensions>
<VisualStudio> <VisualStudio>

@ -5,70 +5,64 @@
--> -->
<configuration> <configuration>
<appSettings> <appSettings>
<add key="webpages:Version" value="3.0.0.0"/> <add key="webpages:Version" value="3.0.0.0" />
<add key="webpages:Enabled" value="false"/> <add key="webpages:Enabled" value="false" />
<add key="ClientValidationEnabled" value="true"/> <add key="ClientValidationEnabled" value="true" />
<add key="UnobtrusiveJavaScriptEnabled" value="true"/> <add key="UnobtrusiveJavaScriptEnabled" value="true" />
<add key="DsErpApiServer" value="http://localhost:8080"/> <add key="DsErpApiServer" value="http://localhost:8080" />
</appSettings> </appSettings>
<system.web> <system.web>
<compilation debug="true" targetFramework="4.5"/> <compilation debug="true" targetFramework="4.5" />
<httpRuntime targetFramework="4.5"/> <httpRuntime targetFramework="4.5" />
<sessionState mode="StateServer" stateConnectionString="tcpip=127.0.0.1:42424" cookieless="false" timeout="60" /> <sessionState mode="StateServer" stateConnectionString="tcpip=127.0.0.1:42424" cookieless="false" timeout="60" />
</system.web> </system.web>
<runtime> <runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="Antlr3.Runtime" publicKeyToken="eb42632606e9261f"/> <assemblyIdentity name="Antlr3.Runtime" publicKeyToken="eb42632606e9261f" />
<bindingRedirect oldVersion="0.0.0.0-3.5.0.2" newVersion="3.5.0.2"/> <bindingRedirect oldVersion="0.0.0.0-3.5.0.2" newVersion="3.5.0.2" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Diagnostics.DiagnosticSource" publicKeyToken="cc7b13ffcd2ddd51"/> <assemblyIdentity name="System.Diagnostics.DiagnosticSource" publicKeyToken="cc7b13ffcd2ddd51" />
<bindingRedirect oldVersion="0.0.0.0-4.0.2.1" newVersion="4.0.2.1"/> <bindingRedirect oldVersion="0.0.0.0-4.0.2.1" newVersion="4.0.2.1" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed"/> <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" />
<bindingRedirect oldVersion="0.0.0.0-11.0.0.0" newVersion="11.0.0.0"/> <bindingRedirect oldVersion="0.0.0.0-13.0.0.0" newVersion="13.0.0.0" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Web.Optimization" publicKeyToken="31bf3856ad364e35"/> <assemblyIdentity name="System.Web.Optimization" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="1.1.0.0"/> <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="1.1.0.0" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35"/> <assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-1.6.5135.21930" newVersion="1.6.5135.21930"/> <bindingRedirect oldVersion="0.0.0.0-1.6.5135.21930" newVersion="1.6.5135.21930" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35"/> <assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0"/> <bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35"/> <assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0"/> <bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35"/> <assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-5.2.4.0" newVersion="5.2.4.0"/> <bindingRedirect oldVersion="1.0.0.0-5.2.4.0" newVersion="5.2.4.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
</runtime> </runtime>
<system.webServer> <system.webServer>
<modules> <modules>
<remove name="TelemetryCorrelationHttpModule"/> <remove name="TelemetryCorrelationHttpModule" />
<add name="TelemetryCorrelationHttpModule" <add name="TelemetryCorrelationHttpModule" type="Microsoft.AspNet.TelemetryCorrelation.TelemetryCorrelationHttpModule, Microsoft.AspNet.TelemetryCorrelation" preCondition="integratedMode,managedHandler" />
type="Microsoft.AspNet.TelemetryCorrelation.TelemetryCorrelationHttpModule, Microsoft.AspNet.TelemetryCorrelation"
preCondition="integratedMode,managedHandler"/>
</modules> </modules>
</system.webServer> </system.webServer>
<system.codedom> <system.codedom>
<compilers> <compilers>
<compiler language="c#;cs;csharp" extension=".cs" <compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:6 /nowarn:1659;1699;1701" />
type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" <compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:14 /nowarn:41008 /define:_MYTYPE=\&quot;Web\&quot; /optionInfer+" />
warningLevel="4" compilerOptions="/langversion:6 /nowarn:1659;1699;1701"/>
<compiler language="vb;vbs;visualbasic;vbscript" extension=".vb"
type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"
warningLevel="4" compilerOptions="/langversion:14 /nowarn:41008 /define:_MYTYPE=\&quot;Web\&quot; /optionInfer+"/>
</compilers> </compilers>
</system.codedom> </system.codedom>
</configuration> </configuration>

@ -17,7 +17,7 @@
<package id="Microsoft.jQuery.Unobtrusive.Validation" version="3.2.4" targetFramework="net45" /> <package id="Microsoft.jQuery.Unobtrusive.Validation" version="3.2.4" targetFramework="net45" />
<package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net45" /> <package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net45" />
<package id="Modernizr" version="2.8.3" targetFramework="net45" /> <package id="Modernizr" version="2.8.3" targetFramework="net45" />
<package id="Newtonsoft.Json" version="11.0.1" targetFramework="net45" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net45" />
<package id="System.Diagnostics.DiagnosticSource" version="4.4.1" targetFramework="net45" /> <package id="System.Diagnostics.DiagnosticSource" version="4.4.1" targetFramework="net45" />
<package id="WebGrease" version="1.6.0" targetFramework="net45" /> <package id="WebGrease" version="1.6.0" targetFramework="net45" />
</packages> </packages>

@ -49,7 +49,7 @@
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" /> <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-11.0.0.0" newVersion="11.0.0.0" /> <bindingRedirect oldVersion="0.0.0.0-13.0.0.0" newVersion="13.0.0.0" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="AspNetPager" publicKeyToken="fb0a0fe055d40fd4" culture="neutral" /> <assemblyIdentity name="AspNetPager" publicKeyToken="fb0a0fe055d40fd4" culture="neutral" />

@ -113,8 +113,8 @@
<Reference Include="MimeKit, Version=2.9.0.0, Culture=neutral, PublicKeyToken=bede1c8a46c66814, processorArchitecture=MSIL"> <Reference Include="MimeKit, Version=2.9.0.0, Culture=neutral, PublicKeyToken=bede1c8a46c66814, processorArchitecture=MSIL">
<HintPath>..\packages\MimeKit.2.9.1\lib\net45\MimeKit.dll</HintPath> <HintPath>..\packages\MimeKit.2.9.1\lib\net45\MimeKit.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=11.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.11.0.1\lib\net45\Newtonsoft.Json.dll</HintPath> <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference> </Reference>
<Reference Include="System" /> <Reference Include="System" />
<Reference Include="System.Configuration" /> <Reference Include="System.Configuration" />

@ -7,7 +7,7 @@
<package id="MailKit" version="2.8.0" targetFramework="net45" /> <package id="MailKit" version="2.8.0" targetFramework="net45" />
<package id="Microsoft.CSharp" version="4.0.1" targetFramework="net45" /> <package id="Microsoft.CSharp" version="4.0.1" targetFramework="net45" />
<package id="MimeKit" version="2.9.1" targetFramework="net45" /> <package id="MimeKit" version="2.9.1" targetFramework="net45" />
<package id="Newtonsoft.Json" version="11.0.1" targetFramework="net45" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net45" />
<package id="Portable.BouncyCastle" version="1.8.5" targetFramework="net45" /> <package id="Portable.BouncyCastle" version="1.8.5" targetFramework="net45" />
<package id="SharpZipLib" version="1.2.0" targetFramework="net45" /> <package id="SharpZipLib" version="1.2.0" targetFramework="net45" />
</packages> </packages>

@ -40,9 +40,8 @@
<Reference Include="Microsoft.Practices.EnterpriseLibrary.Logging"> <Reference Include="Microsoft.Practices.EnterpriseLibrary.Logging">
<HintPath>..\DSWeb\bin\Microsoft.Practices.EnterpriseLibrary.Logging.dll</HintPath> <HintPath>..\DSWeb\bin\Microsoft.Practices.EnterpriseLibrary.Logging.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=6.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion> <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net40\Newtonsoft.Json.dll</HintPath>
<HintPath>..\DSWeb\bin\Newtonsoft.Json.dll</HintPath>
</Reference> </Reference>
<Reference Include="System" /> <Reference Include="System" />
<Reference Include="System.Core" /> <Reference Include="System.Core" />
@ -81,6 +80,9 @@
<Name>JsonHelper</Name> <Name>JsonHelper</Name>
</ProjectReference> </ProjectReference>
</ItemGroup> </ItemGroup>
<ItemGroup>
<None Include="packages.config" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it. <!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets. Other similar extension points exist, see Microsoft.Common.targets.

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Newtonsoft.Json" version="13.0.1" targetFramework="net40" />
</packages>

@ -46,8 +46,8 @@
<Reference Include="Microsoft.Practices.EnterpriseLibrary.Data"> <Reference Include="Microsoft.Practices.EnterpriseLibrary.Data">
<HintPath>..\DSWeb\bin\Microsoft.Practices.EnterpriseLibrary.Data.dll</HintPath> <HintPath>..\DSWeb\bin\Microsoft.Practices.EnterpriseLibrary.Data.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net40\Newtonsoft.Json.dll</HintPath> <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference> </Reference>
<Reference Include="Quartz, Version=2.6.2.0, Culture=neutral, PublicKeyToken=f6b8c98a402cc8a4, processorArchitecture=MSIL"> <Reference Include="Quartz, Version=2.6.2.0, Culture=neutral, PublicKeyToken=f6b8c98a402cc8a4, processorArchitecture=MSIL">
<HintPath>..\packages\Quartz.2.6.2\lib\net40\Quartz.dll</HintPath> <HintPath>..\packages\Quartz.2.6.2\lib\net40\Quartz.dll</HintPath>

@ -3,6 +3,6 @@
<package id="Common.Logging" version="3.3.1" targetFramework="net40" /> <package id="Common.Logging" version="3.3.1" targetFramework="net40" />
<package id="Common.Logging.Core" version="3.3.1" targetFramework="net40" /> <package id="Common.Logging.Core" version="3.3.1" targetFramework="net40" />
<package id="log4net" version="2.0.8" targetFramework="net40" requireReinstallation="true" /> <package id="log4net" version="2.0.8" targetFramework="net40" requireReinstallation="true" />
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net40" requireReinstallation="true" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net451" />
<package id="Quartz" version="2.6.2" targetFramework="net40" /> <package id="Quartz" version="2.6.2" targetFramework="net40" />
</packages> </packages>

@ -40,8 +40,8 @@
<Reference Include="log4net, Version=2.0.8.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL"> <Reference Include="log4net, Version=2.0.8.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.8\lib\net40-full\log4net.dll</HintPath> <HintPath>..\packages\log4net.2.0.8\lib\net40-full\log4net.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net40\Newtonsoft.Json.dll</HintPath> <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net40\Newtonsoft.Json.dll</HintPath>
</Reference> </Reference>
<Reference Include="Quartz, Version=2.6.2.0, Culture=neutral, PublicKeyToken=f6b8c98a402cc8a4, processorArchitecture=MSIL"> <Reference Include="Quartz, Version=2.6.2.0, Culture=neutral, PublicKeyToken=f6b8c98a402cc8a4, processorArchitecture=MSIL">
<HintPath>..\packages\Quartz.2.6.2\lib\net40\Quartz.dll</HintPath> <HintPath>..\packages\Quartz.2.6.2\lib\net40\Quartz.dll</HintPath>

@ -3,6 +3,6 @@
<package id="Common.Logging" version="3.3.1" targetFramework="net40" /> <package id="Common.Logging" version="3.3.1" targetFramework="net40" />
<package id="Common.Logging.Core" version="3.3.1" targetFramework="net40" /> <package id="Common.Logging.Core" version="3.3.1" targetFramework="net40" />
<package id="log4net" version="2.0.8" targetFramework="net40" /> <package id="log4net" version="2.0.8" targetFramework="net40" />
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net40" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net40" />
<package id="Quartz" version="2.6.2" targetFramework="net40" /> <package id="Quartz" version="2.6.2" targetFramework="net40" />
</packages> </packages>

@ -54,6 +54,9 @@
<SpecificVersion>False</SpecificVersion> <SpecificVersion>False</SpecificVersion>
<HintPath>..\packages\MimeKit.2.8.0\lib\net45\MimeKit.dll</HintPath> <HintPath>..\packages\MimeKit.2.8.0\lib\net45\MimeKit.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="Quartz, Version=2.6.2.0, Culture=neutral, PublicKeyToken=f6b8c98a402cc8a4, processorArchitecture=MSIL"> <Reference Include="Quartz, Version=2.6.2.0, Culture=neutral, PublicKeyToken=f6b8c98a402cc8a4, processorArchitecture=MSIL">
<HintPath>..\packages\Quartz.2.6.2\lib\net40\Quartz.dll</HintPath> <HintPath>..\packages\Quartz.2.6.2\lib\net40\Quartz.dll</HintPath>
</Reference> </Reference>

@ -3,6 +3,6 @@
<package id="Common.Logging" version="3.3.1" targetFramework="net40" /> <package id="Common.Logging" version="3.3.1" targetFramework="net40" />
<package id="Common.Logging.Core" version="3.3.1" targetFramework="net40" /> <package id="Common.Logging.Core" version="3.3.1" targetFramework="net40" />
<package id="log4net" version="2.0.8" targetFramework="net40" requireReinstallation="true" /> <package id="log4net" version="2.0.8" targetFramework="net40" requireReinstallation="true" />
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net40" requireReinstallation="true" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net451" />
<package id="Quartz" version="2.6.2" targetFramework="net40" /> <package id="Quartz" version="2.6.2" targetFramework="net40" />
</packages> </packages>

@ -43,8 +43,8 @@
<Reference Include="log4net, Version=2.0.8.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL"> <Reference Include="log4net, Version=2.0.8.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.8\lib\net40-full\log4net.dll</HintPath> <HintPath>..\packages\log4net.2.0.8\lib\net40-full\log4net.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net40\Newtonsoft.Json.dll</HintPath> <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference> </Reference>
<Reference Include="Quartz, Version=2.6.2.0, Culture=neutral, PublicKeyToken=f6b8c98a402cc8a4, processorArchitecture=MSIL"> <Reference Include="Quartz, Version=2.6.2.0, Culture=neutral, PublicKeyToken=f6b8c98a402cc8a4, processorArchitecture=MSIL">
<HintPath>..\packages\Quartz.2.6.2\lib\net40\Quartz.dll</HintPath> <HintPath>..\packages\Quartz.2.6.2\lib\net40\Quartz.dll</HintPath>
@ -74,6 +74,7 @@
<Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<None Include="app.config" />
<None Include="job_scheduling_data_2_0.xsd"> <None Include="job_scheduling_data_2_0.xsd">
<SubType>Designer</SubType> <SubType>Designer</SubType>
</None> </None>

@ -3,6 +3,6 @@
<package id="Common.Logging" version="3.3.1" targetFramework="net40" /> <package id="Common.Logging" version="3.3.1" targetFramework="net40" />
<package id="Common.Logging.Core" version="3.3.1" targetFramework="net40" /> <package id="Common.Logging.Core" version="3.3.1" targetFramework="net40" />
<package id="log4net" version="2.0.8" targetFramework="net40" requireReinstallation="true" /> <package id="log4net" version="2.0.8" targetFramework="net40" requireReinstallation="true" />
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net40" requireReinstallation="true" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net451" />
<package id="Quartz" version="2.6.2" targetFramework="net40" /> <package id="Quartz" version="2.6.2" targetFramework="net40" />
</packages> </packages>

@ -13,7 +13,7 @@
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" /> <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-12.0.0.0" newVersion="12.0.0.0" /> <bindingRedirect oldVersion="0.0.0.0-13.0.0.0" newVersion="13.0.0.0" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="AspNetPager" publicKeyToken="fb0a0fe055d40fd4" culture="neutral" /> <assemblyIdentity name="AspNetPager" publicKeyToken="fb0a0fe055d40fd4" culture="neutral" />

@ -1,20 +0,0 @@
The MIT License (MIT)
Copyright (c) 2007 James Newton-King
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

Binary file not shown.

@ -1,20 +0,0 @@
The MIT License (MIT)
Copyright (c) 2007 James Newton-King
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

Binary file not shown.

@ -1,20 +0,0 @@
The MIT License (MIT)
Copyright (c) 2007 James Newton-King
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.7 KiB

Loading…
Cancel
Save