| 1234567891011121314151617181920212223242526 |
- var publicKey ="042DBA45E7B03394F603CADAFCDDEC854D3E01A4E9C52CD799B85B1A14BDB970137AE58BA553D79F058604DC1CD4B77DE5408BA3308E767584100C2B663510C819";
- var privateKey ="BF1F907B4E0487F798DC80AFD7BC2A6201E8514233002272EA3BE2FC6F797843";
- //加密
- function encryptFn(value){
- var encrText = sm2.doEncrypt(value, publicKey,0);
- return encrText
- }
- //解密
- function decryptFn(value){
- var decryptText = ""
- if(value){
- decryptText = sm2.doDecrypt(value.slice(2), privateKey,0);
- }
- return decryptText
- }
- function phoneTableClick(ele,data){
- ele.innerText =decryptFn(data)
- }
- function addPhoneHtml(ele,data,dataShow){
- var html = '<a onclick="phoneTableClick(this ,\'' +row.CallNumberShow+'\')"> ' + val + '</a>'
- $(html).appendTo($(ele))
- }
|