|
@@ -171,30 +171,10 @@
|
|
|
|
|
|
function getHead(fileId) {
|
|
|
$('.head img').attr('src', '../static/img/invite/header-img.png');
|
|
|
- var timestamp = new Date().getTime()
|
|
|
- var encrypts = encrypt(
|
|
|
- 'RuiChiSecurityGo' + timestamp,
|
|
|
- 'RuiChiSecurityGo'
|
|
|
- )
|
|
|
- var data = {
|
|
|
- keyType: 2,
|
|
|
- security: encrypts
|
|
|
+ if(fileId){
|
|
|
+ let urls = baseUrl == 'http://14.18.190.141:24380'?'http://110.53.221.195:8210':'https://wjzx.androidscloud.com:9091';
|
|
|
+ $('.head img').attr('src', `${urls}/document/newFile/download/0/3dn9b4585511476691c6?fileKey=`+fileId);
|
|
|
}
|
|
|
- let urls = baseUrl == 'http://14.18.190.141:24380'?'http://110.53.221.195:8210':'https://wjzx.androidscloud.com:9091';
|
|
|
- $.ajax({
|
|
|
- url: `${urls}/document/newFile/download/0/3dn9b4585511476691c6?fileKey=`+fileId,
|
|
|
- type: 'get',
|
|
|
- headers: data,
|
|
|
- xhrFields: { responseType: "blob" },
|
|
|
- cache: false,
|
|
|
- success: function (res) {
|
|
|
- var xhr = new XMLHttpRequest();
|
|
|
- var imageType = xhr.getResponseHeader("Content-Type");
|
|
|
- var blob = new Blob([res], { type: imageType });
|
|
|
- var imageUrl = (window.URL || window.webkitURL).createObjectURL(blob);
|
|
|
- $('.head img').attr('src', imageUrl);
|
|
|
- }
|
|
|
- })
|
|
|
}
|
|
|
|
|
|
function encrypt(word, keyStr) {
|