Commit f858d8b5 authored by jiyonggang's avatar jiyonggang

更换阿里云key

parent 99e614fa
...@@ -980,9 +980,9 @@ export default { ...@@ -980,9 +980,9 @@ export default {
const aliyun = { const aliyun = {
// "你的Region 注意 这个只要 空间名 不要 http:// 和 .aliyunoss.com !!", // "你的Region 注意 这个只要 空间名 不要 http:// 和 .aliyunoss.com !!",
Region: "oss-cn-beijing", Region: "oss-cn-beijing",
AccessKeyId: "LTAIOxFvkIPvgKrc", AccessKeyId: "LTAI5tJzo2DiQxQqh9EipDNh",
AccessKeySecret: "y5VxsiIviudY6swKWlFySFh3PRCafP", AccessKeySecret: "JnduhWY5Tr5VfuFHgDOv9XjqYx1mDg",
Bucket: "zx-material", Bucket: "zx-material-new",
//"你的SecurityToken" //"你的SecurityToken"
// SecurityToken: null, // SecurityToken: null,
}; };
...@@ -991,19 +991,19 @@ export default { ...@@ -991,19 +991,19 @@ export default {
AccessKeyId, AccessKeyId,
AccessKeySecret, AccessKeySecret,
Bucket, Bucket,
SecurityToken, // SecurityToken,
} = aliyun; } = aliyun;
//初始化连接oss参数 //初始化连接oss参数
this.uploadConf.region = Region; this.uploadConf.region = Region;
this.uploadConf.accessKeyId = AccessKeyId; this.uploadConf.accessKeyId = AccessKeyId;
this.uploadConf.accessKeySecret = AccessKeySecret; this.uploadConf.accessKeySecret = AccessKeySecret;
this.uploadConf.bucket = Bucket; this.uploadConf.bucket = Bucket;
this.uploadConf.stsToken = SecurityToken; // this.uploadConf.stsToken = SecurityToken;
}, },
//上传到阿里云OSS //上传到阿里云OSS
uploadMulFile(uploader) { uploadMulFile(uploader) {
console.log("文件信息", uploader); // console.log("文件信息", uploader);
//获取到文件的信息内容 //获取到文件的信息内容
let file = uploader.file; let file = uploader.file;
//获取文件类型 和 上传文件的日期 //获取文件类型 和 上传文件的日期
...@@ -1014,7 +1014,7 @@ export default { ...@@ -1014,7 +1014,7 @@ export default {
let curTime = new Date(); let curTime = new Date();
//定义上传到云端的路径和文件名字 //定义上传到云端的路径和文件名字
let upFilePath = let upFilePath =
file.type.split("/")[0] + "ad_putin_materials" +
"/" + "/" +
curTime.getFullYear() + curTime.getFullYear() +
"/" + "/" +
...@@ -1044,7 +1044,7 @@ export default { ...@@ -1044,7 +1044,7 @@ export default {
//解析url并替换前缀可访问 //解析url并替换前缀可访问
let strUrl = res.res.requestUrls[0].split("?")[0]; let strUrl = res.res.requestUrls[0].split("?")[0];
strUrl = strUrl.replace( strUrl = strUrl.replace(
"http://zx-material.oss-cn-beijing.aliyuncs.com", "http://zx-material-new.oss-cn-beijing.aliyuncs.com",
"https://cdn.zhangxingames.com" "https://cdn.zhangxingames.com"
); );
that.fileList = [...that.fileList, { uid: file.uid, url: strUrl }]; that.fileList = [...that.fileList, { uid: file.uid, url: strUrl }];
...@@ -1161,6 +1161,9 @@ export default { ...@@ -1161,6 +1161,9 @@ export default {
deleteMaterial(index) { deleteMaterial(index) {
this.items.splice(index, 1); this.items.splice(index, 1);
}, },
handleEnsureMaterial(newItems) {
this.selectedMaterials = [...this.selectedMaterials, ...newItems];
},
}, },
computed: { computed: {
/* 监听日期 */ /* 监听日期 */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment