Browse Source

对接接口

master
前端-胡立永 1 month ago
parent
commit
9340e269fc
2 changed files with 35 additions and 7 deletions
  1. +24
    -7
      config.js
  2. +11
    -0
      pages/index/index.vue

+ 24
- 7
config.js View File

@ -14,8 +14,11 @@ const config = {
dev: {
baseUrl: 'http://dev.java996.icu/clockin-api',
},
prod: {
test: {
baseUrl: 'https://clockin.java996.icu/clockin-api',
},
prod: {
baseUrl: 'https://admin.ptchemicalscc.com/clockin-api',
}
}
@ -24,19 +27,33 @@ const config = {
const defaultConfig = {
mapKey: 'XMBBZ-BCPCV-SXPPQ-5Y7MY-PHZXK-YFFVU',
aliOss: {
url: 'https://image.hhlm1688.com/',
url: 'https://image.ptchemicalscc.com/',
config: {
//桶的地址
region: 'oss-cn-guangzhou',
region: 'oss-cn-beijing',
//id
accessKeyId: 'LTAI5tQSs47izVy8DLVdwUU9',
accessKeyId: 'LTAI5tA1mo2mRHVwKLLE2V7Y',
//密钥
accessKeySecret: 'qHI7C3PaXYZySr84HTToviC71AYlFq',
accessKeySecret: 'PBs2Dx3mTuVSH7ReWkiZGW3Vc9i22I',
//桶的名字
bucket: 'hanhaiimage',
endpoint: 'oss-cn-shenzhen.aliyuncs.com',
bucket: 'ptchemicalscc',
endpoint: 'oss-cn-beijing.aliyuncs.com',
}
},
// aliOss: {
// url: 'https://image.hhlm1688.com/',
// config: {
// //桶的地址
// region: 'oss-cn-guangzhou',
// //id
// accessKeyId: 'LTAI5tQSs47izVy8DLVdwUU9',
// //密钥
// accessKeySecret: 'qHI7C3PaXYZySr84HTToviC71AYlFq',
// //桶的名字
// bucket: 'hanhaiimage',
// endpoint: 'oss-cn-shenzhen.aliyuncs.com',
// }
// },
}


+ 11
- 0
pages/index/index.vue View File

@ -49,6 +49,9 @@
</div>
</div>
<!-- <image
@click="upload"
:src="image" mode=""></image> -->
<!-- tab栏 -->
<tabbar :select="0"></tabbar>
@ -75,6 +78,7 @@
covers: [],
inter : null,
date : this.$dayjs(),
image : '',
}
},
computed : {
@ -100,6 +104,13 @@
url: "/pages/subPack/record/record"
})
},
upload(){
this.$Oss.ossUploadImage({
success : url => {
this.image = url
}
})
},
//
openBroadside() {


Loading…
Cancel
Save