bug
This commit is contained in:
parent
a96bb9cd86
commit
17c34c7ebf
@ -1,11 +1,11 @@
|
||||
// 请求地址
|
||||
// export const URL_BASE = 'http://192.168.3.106:9090/server'
|
||||
//export const URL_BASE = 'http://192.168.3.131:9090/server'
|
||||
// export const URL_BASE = 'http://192.168.3.196:9090/server'
|
||||
// export const URL_KAOSHI = 'http://192.168.3.196:8090/practice_api'
|
||||
export const URL_BASE = 'http://192.168.3.196:9090/server'
|
||||
export const URL_KAOSHI = 'http://192.168.3.196:8090/practice_api'
|
||||
// 生产
|
||||
export const URL_BASE = 'http://1.30.216.250:19090/server'
|
||||
export const URL_KAOSHI = 'http://1.30.216.250:19091/practice_api'
|
||||
// export const URL_BASE = 'https://1.30.216.250:1443/server'
|
||||
// export const URL_KAOSHI = 'http://1.30.216.250:19091/practice_api'
|
||||
// 测试
|
||||
// export const URL_BASE = 'http://117.15.170.44:29279/server'
|
||||
// export const URL_KAOSHI = 'http://117.15.170.44:29285/practice_api'
|
||||
|
||||
@ -61,6 +61,7 @@ export default {
|
||||
options.header = headerObj;
|
||||
options.method = options.method || 'GET';
|
||||
options.timeout = 10000;
|
||||
options.sslVerify = false;
|
||||
resolve(options);
|
||||
})
|
||||
},
|
||||
|
||||
@ -64,7 +64,8 @@
|
||||
password: '',
|
||||
passwordBox: false,
|
||||
imageVerifyCode:'',
|
||||
messageVerifyCode:""
|
||||
messageVerifyCode:"",
|
||||
type:"app"
|
||||
});
|
||||
const tiaozhuan = ref('1');
|
||||
const examType = ref('examinee');
|
||||
@ -104,6 +105,7 @@
|
||||
url: `${URL_BASE}/code/getOneDataApp`,
|
||||
data: {},
|
||||
method: 'GET',
|
||||
sslVerify:false,
|
||||
success: (res) => {
|
||||
console.log(res);
|
||||
if (res) {
|
||||
@ -145,6 +147,7 @@
|
||||
url: `${URL_BASE}/lianlu/createCaptcha`,
|
||||
data: {},
|
||||
method: 'GET',
|
||||
sslVerify:false,
|
||||
success: (res) => {
|
||||
// console.log(res);
|
||||
imageVerifyCode.value = "data:image/png;base64,"+res.data.data.imageBase64;
|
||||
@ -184,6 +187,7 @@
|
||||
url: `${URL_BASE}/lianlu/sendVerificationApp`,
|
||||
data: {phone:loginData.telephone,type:(tiaozhuan.value==='1'?0:1),captcha:loginData.imageVerifyCode,oldCaptcha:captcha.value},
|
||||
method: 'GET',
|
||||
sslVerify:false,
|
||||
success: (res) => {
|
||||
if(res.data.code==="0"){
|
||||
messageCode.value = res.data.data+"";
|
||||
@ -260,6 +264,7 @@
|
||||
url: `${URL_BASE}/basic_functions/login_and_index/login`,
|
||||
data: toRaw(loginData),
|
||||
method: 'POST',
|
||||
sslVerify:false,
|
||||
success: (res) => {
|
||||
console.log(res);
|
||||
if (res.data.code === "200" && res.data.data.code === "1") {
|
||||
@ -317,6 +322,7 @@
|
||||
url: `${URL_KAOSHI}/loginApp`,
|
||||
data: {username:lgData.telephone,password:lgData.password,loginType:examType.value},
|
||||
method: 'POST',
|
||||
sslVerify:false,
|
||||
success: (res) => {
|
||||
// console.log(res);
|
||||
if (res.statusCode === 200 && res.data.code === 0 && res.data.flag) {
|
||||
|
||||
@ -60,6 +60,7 @@
|
||||
url: `${URL_BASE}//basic_functions/user/pwdForPhone`,
|
||||
data: toRaw(upData),
|
||||
method: 'POST',
|
||||
sslVerify:false,
|
||||
success: (res) => {
|
||||
if (res.data.code === "200") {
|
||||
if (res.data.data.code === "0") {
|
||||
|
||||
@ -77,6 +77,7 @@
|
||||
uni.hideLoading()
|
||||
},
|
||||
fail: function(err) {
|
||||
console.log(err);
|
||||
uni.hideLoading()
|
||||
let title = '数据中心',
|
||||
content = '请打开系统定位开关'
|
||||
@ -119,6 +120,7 @@
|
||||
data: { id: clear.erWeiMa.data },
|
||||
header:{'token':token},
|
||||
method: 'GET',
|
||||
sslVerify:false,
|
||||
success: (data) => {
|
||||
// console.log(data);
|
||||
if(data.data.code=='200'){
|
||||
|
||||
@ -97,6 +97,7 @@
|
||||
data: { id: clear.erWeiMa.data },
|
||||
header:{'token':token},
|
||||
method: 'GET',
|
||||
sslVerify:false,
|
||||
success: (data) => {
|
||||
// console.log(data);
|
||||
if(data.data.code=='200'){
|
||||
|
||||
@ -102,6 +102,7 @@
|
||||
data: { id: clear.erWeiMa.data },
|
||||
header:{'token':token},
|
||||
method: 'GET',
|
||||
sslVerify:false,
|
||||
success: (data) => {
|
||||
// console.log(data);
|
||||
if(data.data.code=='200'){
|
||||
|
||||
@ -79,6 +79,7 @@
|
||||
url: `${URL_BASE}/code/getOneDataApp`,
|
||||
data: {},
|
||||
method: 'GET',
|
||||
sslVerify:false,
|
||||
success: (res) => {
|
||||
// console.log(res);
|
||||
if (res) {
|
||||
|
||||
@ -50,7 +50,8 @@
|
||||
return false
|
||||
}
|
||||
const data = await HTTP.get('/station/getTodayStation')
|
||||
if (!data.id) {
|
||||
console.log(data);
|
||||
if (!data || !data.id) {
|
||||
return false
|
||||
}
|
||||
formData.id = data.id
|
||||
@ -66,7 +67,7 @@
|
||||
for (let str of picUrl) {
|
||||
imgSZ.push({
|
||||
url: `${URL_BASE}/imgFile/stationPic/${str}`,
|
||||
name: str.split('_')[1],
|
||||
name: str,
|
||||
extname: str.split('.')[1]
|
||||
})
|
||||
}
|
||||
@ -74,7 +75,7 @@
|
||||
// 控制视频回显
|
||||
formData.videoValue = {
|
||||
url: `${URL_BASE}/imgFile/stationFile/${data.videoUrl}`,
|
||||
name: data.videoUrl.split('_')[1],
|
||||
name: data.videoUrl,
|
||||
extname: data.videoUrl.split('.')[1]
|
||||
}
|
||||
}
|
||||
@ -85,20 +86,25 @@
|
||||
const selectImg = (e) => {
|
||||
uni.showLoading({ title: '上传图片中' })
|
||||
let files = []
|
||||
for (const obj of e.tempFilePaths) {
|
||||
files.push({ uri: obj })
|
||||
// console.log(e);
|
||||
console.log(e.tempFiles);
|
||||
let i=1;
|
||||
for (const obj of e.tempFiles) {
|
||||
files.push({ uri: obj.url,name:`file${i}`,file:obj.file });
|
||||
i++;
|
||||
}
|
||||
uni.uploadFile({
|
||||
url: `${URL_BASE}/station/fileUpload`,
|
||||
header: { token },
|
||||
files,
|
||||
files:files,
|
||||
success: (res) => {
|
||||
// console.log(res);
|
||||
const data = JSON.parse(res.data)
|
||||
if (data.code === '200') {
|
||||
for (let file of data.data) {
|
||||
formData.imageValue.push({
|
||||
url: `${URL_BASE}/imgFile/stationPic/${file}`,
|
||||
name: file.split('_')[1],
|
||||
name: file,
|
||||
extname: file.split('.')[1]
|
||||
})
|
||||
}
|
||||
@ -125,13 +131,16 @@
|
||||
filePath: e.tempFilePaths[0],
|
||||
name: 'file',
|
||||
success: (res) => {
|
||||
const data = JSON.parse(res.data)
|
||||
// console.log(res);
|
||||
const data = JSON.parse(res.data);
|
||||
if (data.code === '200') {
|
||||
console.log(data.data);
|
||||
formData.videoValue = {
|
||||
url: `${URL_BASE}/imgFile/stationPic/${data.data}`,
|
||||
name: data.data.split('_')[1],
|
||||
name: data.data,
|
||||
extname: data.data.split('.')[1]
|
||||
}
|
||||
console.log(formData.videoValue);
|
||||
} else {
|
||||
uni.showToast({ title: '上传失败请重试', duration: 2000, icon: 'error' })
|
||||
}
|
||||
@ -166,7 +175,13 @@
|
||||
uni.showToast({ title: '请选视频', icon: 'error', duration: 1000 })
|
||||
return false
|
||||
}
|
||||
// console.log(formData.imageValue);
|
||||
// console.log(formData.videoValue);
|
||||
const videoUrl = formData.videoValue.url.substring(formData.videoValue.url.lastIndexOf('/') + 1)
|
||||
// console.log("planId:"+planId);
|
||||
// console.log("videoUrl:"+videoUrl);
|
||||
// console.log("picUrl:"+picUrl);
|
||||
// console.log("id:"+formData.id);
|
||||
await HTTP.post('/station/addOrUpdateStation', { planId, videoUrl, picUrl, id: formData.id })
|
||||
uni.showToast({ title: '站班会提交成功', duration: 1000 })
|
||||
setTimeout(() => uni.switchTab({ url: '/pages/tabBar/gongzuotai' }) , 1000);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user