+
+
+
400
+
+
抱歉!您访问的页面失联啦 ...
+
+
返回上一页
+
+
进入首页
-
-
-
-
-
+
+
\ No newline at end of file
diff --git a/src/views/common/home.vue b/src/views/common/home.vue
index 948980de..fe655f7e 100644
--- a/src/views/common/home.vue
+++ b/src/views/common/home.vue
@@ -1,12 +1,18 @@
+
-
欢迎使用微信管理系统
+
+ 欢迎使用微信管理系统
-
-
-
+ }
+
+
\ No newline at end of file
diff --git a/src/views/common/login.vue b/src/views/common/login.vue
index a43ddb05..1914a120 100644
--- a/src/views/common/login.vue
+++ b/src/views/common/login.vue
@@ -1,184 +1,220 @@
-
-
-
-
微信后台管理系统
-
微信公众号后台管理系统。
-
-
-
管理员登录
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 登录
-
-
-
-
-
+
+
+
+
+
+
+
微信后台管理系统
+
微信公众号后台管理系统。
-
-
+
+
+
+
管理员登录
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ < img :src="captchaPath" @click="getCaptcha()" alt="">
+
+
+
+
+
+
+ 登录
+
+
+
+
+
+
+
-
+
\ No newline at end of file
diff --git a/src/views/common/theme.vue b/src/views/common/theme.vue
index 1aeccbcb..388b2ff6 100644
--- a/src/views/common/theme.vue
+++ b/src/views/common/theme.vue
@@ -1,33 +1,53 @@
- 布局设置
-
-
- default
- inverse
-
-
-
-
- light
- dark
-
-
+
+ 布局设置
+
+
+
+
+
+ default
+ inverse
+
+
+
+
+
+
+
+ light
+ dark
+
+
-
-
+
-
+
\ No newline at end of file
diff --git a/src/views/modules/oss/oss-config.vue b/src/views/modules/oss/oss-config.vue
index 484f90d5..ae429ca5 100644
--- a/src/views/modules/oss/oss-config.vue
+++ b/src/views/modules/oss/oss-config.vue
@@ -1,127 +1,150 @@
+
-
-
-
- 七牛
- 阿里云
- 腾讯云
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+ 七牛
+ 阿里云
+ 腾讯云
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
-
+
\ No newline at end of file
diff --git a/src/views/modules/oss/oss-uploader-tencent.vue b/src/views/modules/oss/oss-uploader-tencent.vue
index d3dac232..81e3ddb2 100644
--- a/src/views/modules/oss/oss-uploader-tencent.vue
+++ b/src/views/modules/oss/oss-uploader-tencent.vue
@@ -1,87 +1,105 @@
-
-
-
{{uploading?infoText:'上传文件'}}
-
-
-
-
+
+
+
+
+
+
{{uploading ? infoText : '上传文件'}}
+
+
+
+
-
-
+ },
+ mounted() {
+ // 组件加载完毕后,发起请求获取 COS 配置数据
+ this.$http({
+ url: this.$http.adornUrl('/sys/oss/config'),
+ method: 'get',
+ params: this.$http.adornParams() // 传递请求参数
+ }).then(({ data }) => {
+ if (data && data.code === 200) {
+ // 如果获取成功,保存配置数据
+ this.cosConfig = data.config;
+ // 初始化腾讯云 COS 实例
+ cos = new COS({
+ SecretId: data.config.qcloudSecretId,
+ SecretKey: data.config.qcloudSecretKey,
+ });
+ } else {
+ // 配置获取失败,提示错误信息
+ this.$message.error('请先配置云存储相关信息!');
+ }
+ })
+ },
+ methods: {
+ // 选择文件的方法
+ selectFile() {
+ // 如果当前没有文件正在上传,点击触发文件选择框
+ if (!this.uploading) {
+ this.$refs.fileInput.click();
+ }
+ },
+ // 文件选择后触发的回调方法
+ onFileChange() {
+ let file = this.$refs.fileInput.files[0]; // 获取选中的文件
+ this.uploading = true; // 设置上传状态为 true
+ let now = new Date();
+ // 生成上传文件的存储路径(包括日期和时间戳确保路径唯一)
+ let path = now.toISOString().slice(0, 10) + '/' + now.getTime() + file.name.substr(file.name.lastIndexOf('.'));
+
+ // 调用腾讯云 COS 上传文件方法
+ cos.putObject({
+ Bucket: this.cosConfig.qcloudBucketName, // 必须指定的桶名称
+ Region: this.cosConfig.qcloudRegion, // 必须指定的区域
+ Key: path, // 文件存储路径(文件名)
+ Body: file, // 上传的文件对象
+ onProgress: (progressData) => { // 上传进度回调
+ // 更新上传进度提示文本
+ this.infoText = '上传中:' + (progressData.percent * 100).toFixed(2) + '%';
+ }
+ }, (err, data) => {
+ // 上传完成后回调,处理成功和失败的情况
+ console.log(err || data);
+ this.uploading = false; // 上传状态恢复为 false
+ if (data) {
+ // 上传成功,更新提示文本
+ this.infoText = '上传文件';
+ // 生成文件访问的 URL
+ let fileUrl = 'https://' + this.cosConfig.qcloudBucketName + '.cos.' + this.cosConfig.qcloudRegion + '.myqcloud.com/' + path;
+ this.saveUploadResult(fileUrl); // 保存上传结果
+ } else {
+ // 上传失败,显示错误消息
+ this.$message.error('文件上传失败', err);
+ }
+ });
+ },
+ // 保存上传结果(上传成功后调用,传入文件的访问 URL)
+ saveUploadResult(url) {
+ this.$http({
+ url: this.$http.adornUrl('/sys/oss/upload'),
+ method: 'post',
+ data: { url: url } // 将上传的文件 URL 传给服务器
+ }).then(({ data }) => {
+ // 上传成功后,触发 `uploaded` 事件,将文件 URL 传递给父组件
+ this.$emit('uploaded', url);
+ })
+ }
+ }
+ }
+
+
+
+
\ No newline at end of file
diff --git a/src/views/modules/oss/oss-uploader.vue b/src/views/modules/oss/oss-uploader.vue
index e013aace..64bc5914 100644
--- a/src/views/modules/oss/oss-uploader.vue
+++ b/src/views/modules/oss/oss-uploader.vue
@@ -1,59 +1,73 @@
+
-
-
{{uploading?infoText:'上传文件'}}
+
+
+
+
{{uploading ? infoText : '上传文件'}}
-
-
-
+
+
\ No newline at end of file
diff --git a/src/views/modules/oss/oss.vue b/src/views/modules/oss/oss.vue
index 35fdcbeb..4c403ce3 100644
--- a/src/views/modules/oss/oss.vue
+++ b/src/views/modules/oss/oss.vue
@@ -39,108 +39,79 @@
diff --git a/src/views/modules/sys/config-add-or-update.vue b/src/views/modules/sys/config-add-or-update.vue
index 26b6aa1a..898bfb61 100644
--- a/src/views/modules/sys/config-add-or-update.vue
+++ b/src/views/modules/sys/config-add-or-update.vue
@@ -1,96 +1,117 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/modules/sys/config.vue b/src/views/modules/sys/config.vue
index 6a7517b5..b20162c1 100644
--- a/src/views/modules/sys/config.vue
+++ b/src/views/modules/sys/config.vue
@@ -1,134 +1,172 @@
-
-
-
-
-
- 查询
- 新增
- 批量删除
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 修改
- 删除
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+查询
+
+新增
+
+批量删除
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+修改
+
+删除
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/modules/sys/log.vue b/src/views/modules/sys/log.vue
index 117b2ac8..5223704c 100644
--- a/src/views/modules/sys/log.vue
+++ b/src/views/modules/sys/log.vue
@@ -1,90 +1,107 @@