This commit is contained in:
parent
c4dec49f28
commit
6c6432e21c
|
|
@ -160,9 +160,10 @@ export default {
|
||||||
methods: {
|
methods: {
|
||||||
// 获取医院列表 app/gethospital
|
// 获取医院列表 app/gethospital
|
||||||
getHospitalList() {
|
getHospitalList() {
|
||||||
|
const cry = new Crypoto()
|
||||||
const params = {
|
const params = {
|
||||||
token: this.token,
|
token: this.token,
|
||||||
idcard: this.idcard
|
idcard: cry.encrypt(this.idcard)
|
||||||
}
|
}
|
||||||
console.log('🚀 ~ getHospitalList ~ params:', params)
|
console.log('🚀 ~ getHospitalList ~ params:', params)
|
||||||
uni.request({
|
uni.request({
|
||||||
|
|
@ -178,7 +179,6 @@ export default {
|
||||||
console.log('🚀 ~ getHospitalList ~ res:', res)
|
console.log('🚀 ~ getHospitalList ~ res:', res)
|
||||||
if (res.res == 1) {
|
if (res.res == 1) {
|
||||||
this.hospitalList = res.obj
|
this.hospitalList = res.obj
|
||||||
// this.hospitalInfo = res.obj[0]
|
|
||||||
// this.columns 双层数组, 将医院列表push到columns中
|
// this.columns 双层数组, 将医院列表push到columns中
|
||||||
this.columns.push(this.hospitalList)
|
this.columns.push(this.hospitalList)
|
||||||
console.log('🚀 ~ getHospitalList ~ this.hospitalList:', this.hospitalList)
|
console.log('🚀 ~ getHospitalList ~ this.hospitalList:', this.hospitalList)
|
||||||
|
|
@ -191,9 +191,10 @@ export default {
|
||||||
},
|
},
|
||||||
// 获取检查类型
|
// 获取检查类型
|
||||||
getCheckType() {
|
getCheckType() {
|
||||||
|
const cry = new Crypoto()
|
||||||
const params = {
|
const params = {
|
||||||
token: this.token,
|
token: this.token,
|
||||||
idcard: this.idcard
|
idcard: cry.encrypt(this.idcard)
|
||||||
}
|
}
|
||||||
console.log('🚀 ~ getCheckType ~ params:', params)
|
console.log('🚀 ~ getCheckType ~ params:', params)
|
||||||
uni.request({
|
uni.request({
|
||||||
|
|
@ -329,11 +330,10 @@ export default {
|
||||||
const params = {
|
const params = {
|
||||||
hospitalId: this.hospitalInfo.id,
|
hospitalId: this.hospitalInfo.id,
|
||||||
setMealId: this.setMealId,
|
setMealId: this.setMealId,
|
||||||
// checkId: '1',
|
|
||||||
phyAppontTime: this.healthTime,
|
phyAppontTime: this.healthTime,
|
||||||
setMealType: '2',
|
setMealType: '2',
|
||||||
combName: this.checkTypeContent,
|
combName: this.checkTypeContent,
|
||||||
token: this.token
|
// token: this.token
|
||||||
}
|
}
|
||||||
console.log('🚀 ~ handleSave ~ params:', params)
|
console.log('🚀 ~ handleSave ~ params:', params)
|
||||||
console.log('🚀 ~ handleSave ~ params:', cry.encrypt(JSON.stringify(params)))
|
console.log('🚀 ~ handleSave ~ params:', cry.encrypt(JSON.stringify(params)))
|
||||||
|
|
@ -341,8 +341,8 @@ export default {
|
||||||
uni.request({
|
uni.request({
|
||||||
url: config.tjBaseUrl + '/app/phyappoint',
|
url: config.tjBaseUrl + '/app/phyappoint',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
// data: { encryptedData: params, token: this.token },
|
data: { encryptedData: cry.encrypt(JSON.stringify(params)), token: this.token },
|
||||||
data: params,
|
// data: params,
|
||||||
header: {
|
header: {
|
||||||
'Content-Type': 'application/x-www-form-urlencoded',
|
'Content-Type': 'application/x-www-form-urlencoded',
|
||||||
token: this.token
|
token: this.token
|
||||||
|
|
|
||||||
|
|
@ -71,6 +71,7 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import config from '@/config'
|
import config from '@/config'
|
||||||
|
import { decryptCBC } from '@/utils/aescbc'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -174,9 +175,13 @@ export default {
|
||||||
},
|
},
|
||||||
success: res => {
|
success: res => {
|
||||||
res = res.data
|
res = res.data
|
||||||
console.log('🚀 ~ getapplogininfo ~ res:', res)
|
console.log('🚀 ~ getAppLoginInfo ~ res:', res)
|
||||||
if (res.res === 1) {
|
if (res.res === 1) {
|
||||||
this.userInfo = res.obj[0]
|
this.userInfo = res.obj[0]
|
||||||
|
this.userInfo.phyName = decryptCBC(this.userInfo.phyName)
|
||||||
|
this.userInfo.idcard = decryptCBC(this.userInfo.idcard)
|
||||||
|
this.userInfo.telepNumber = decryptCBC(this.userInfo.telepNumber)
|
||||||
|
console.log('🚀 ~ getAppLoginInfo ~ this.userInfo:', this.userInfo)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
fail: err => {
|
fail: err => {
|
||||||
|
|
|
||||||
|
|
@ -104,7 +104,6 @@ export default {
|
||||||
getHospitalList() {
|
getHospitalList() {
|
||||||
const params = {
|
const params = {
|
||||||
token: this.token,
|
token: this.token,
|
||||||
idcard: this.idcard
|
|
||||||
}
|
}
|
||||||
console.log('🚀 ~ getHospitalList ~ params:', params)
|
console.log('🚀 ~ getHospitalList ~ params:', params)
|
||||||
uni.request({
|
uni.request({
|
||||||
|
|
@ -134,8 +133,7 @@ export default {
|
||||||
// 获取检查类型
|
// 获取检查类型
|
||||||
getCheckType() {
|
getCheckType() {
|
||||||
const params = {
|
const params = {
|
||||||
token: this.token,
|
token: this.token
|
||||||
idcard: this.idcard
|
|
||||||
}
|
}
|
||||||
console.log('🚀 ~ getCheckType ~ params:', params)
|
console.log('🚀 ~ getCheckType ~ params:', params)
|
||||||
uni.request({
|
uni.request({
|
||||||
|
|
@ -240,7 +238,7 @@ export default {
|
||||||
phyAppontTime: this.healthTime,
|
phyAppontTime: this.healthTime,
|
||||||
setMealType: '3',
|
setMealType: '3',
|
||||||
combName: this.checkType,
|
combName: this.checkType,
|
||||||
token: this.token
|
// token: this.token
|
||||||
}
|
}
|
||||||
console.log('🚀 ~ handleSave ~ params:', params)
|
console.log('🚀 ~ handleSave ~ params:', params)
|
||||||
console.log('🚀 ~ handleSave ~ params:', cry.encrypt(JSON.stringify(params)))
|
console.log('🚀 ~ handleSave ~ params:', cry.encrypt(JSON.stringify(params)))
|
||||||
|
|
@ -248,8 +246,8 @@ export default {
|
||||||
uni.request({
|
uni.request({
|
||||||
url: config.tjBaseUrl + '/app/phyappoint',
|
url: config.tjBaseUrl + '/app/phyappoint',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
// data: { encryptedData: params, token: this.token },
|
data: { encryptedData: cry.encrypt(JSON.stringify(params)), token: this.token },
|
||||||
data: params,
|
// data: params,
|
||||||
header: {
|
header: {
|
||||||
'Content-Type': 'application/x-www-form-urlencoded',
|
'Content-Type': 'application/x-www-form-urlencoded',
|
||||||
token: this.token
|
token: this.token
|
||||||
|
|
|
||||||
|
|
@ -52,6 +52,7 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import config from '@/config'
|
import config from '@/config'
|
||||||
|
import Crypoto from '@/utils/aescbc'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -142,9 +143,10 @@ export default {
|
||||||
},
|
},
|
||||||
// 操作-删除 cancelpoint
|
// 操作-删除 cancelpoint
|
||||||
handleDelete(item) {
|
handleDelete(item) {
|
||||||
|
const cry = new Crypoto()
|
||||||
console.log('🚀 ~ handleDelete ~ item:', item)
|
console.log('🚀 ~ handleDelete ~ item:', item)
|
||||||
const params = {
|
const params = {
|
||||||
cancelId: item.id,
|
cancelId: cry.encrypt(item.id),
|
||||||
mealType: item.setMealType,
|
mealType: item.setMealType,
|
||||||
token: this.token
|
token: this.token
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -47,6 +47,7 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import config from '@/config'
|
import config from '@/config'
|
||||||
|
import Crypoto from '@/utils/aescbc'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -108,10 +109,11 @@ export default {
|
||||||
},
|
},
|
||||||
// 获取列表
|
// 获取列表
|
||||||
getList() {
|
getList() {
|
||||||
|
const cry = new Crypoto()
|
||||||
const params = {
|
const params = {
|
||||||
name: this.keyword,
|
name: cry.encrypt(this.keyword),
|
||||||
data: this.year,
|
data: this.year,
|
||||||
type: this.typeValue,
|
type: cry.encrypt(this.typeValue),
|
||||||
token: this.token
|
token: this.token
|
||||||
}
|
}
|
||||||
console.log('🚀 ~ getList ~ params:', params)
|
console.log('🚀 ~ getList ~ params:', params)
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="explain">*进入考试后,计时结束将自动交卷,退出后将会继续计时</div>
|
<div class="explain">*进入考试后,计时结束将自动交卷,退出后将会继续计时,考试期间请勿登录其他设备,否则成绩作废</div>
|
||||||
|
|
||||||
<!-- 底部固定按钮 -->
|
<!-- 底部固定按钮 -->
|
||||||
<div class="bottom-btn">
|
<div class="bottom-btn">
|
||||||
|
|
|
||||||
|
|
@ -279,12 +279,10 @@ export default {
|
||||||
console.log('🚀 ~ changeCountDown ~ 人脸识别')
|
console.log('🚀 ~ changeCountDown ~ 人脸识别')
|
||||||
// this.openFaceScan() // Android 人脸识别
|
// this.openFaceScan() // Android 人脸识别
|
||||||
this.openPhotograph() // IOS 拍照识别
|
this.openPhotograph() // IOS 拍照识别
|
||||||
}
|
} else if (this.answerTime / 1000 == this.random2) {
|
||||||
if (this.answerTime / 1000 == this.random2) {
|
|
||||||
// this.openFaceScan()
|
// this.openFaceScan()
|
||||||
this.openPhotograph()
|
this.openPhotograph()
|
||||||
}
|
} else if (this.answerTime == this.time) {
|
||||||
if (this.answerTime == this.time) {
|
|
||||||
// 提示: 时间结束, 自动提交
|
// 提示: 时间结束, 自动提交
|
||||||
this.$refs.uToast.show({
|
this.$refs.uToast.show({
|
||||||
message: '考试时间结束, 系统将自动提交',
|
message: '考试时间结束, 系统将自动提交',
|
||||||
|
|
|
||||||
|
|
@ -96,6 +96,7 @@
|
||||||
<script>
|
<script>
|
||||||
import TabbarConfig from '@/totalTabbar.js'
|
import TabbarConfig from '@/totalTabbar.js'
|
||||||
import config from '@/config'
|
import config from '@/config'
|
||||||
|
import Crypoto from '@/utils/aescbc'
|
||||||
|
|
||||||
import {
|
import {
|
||||||
getDayNoticeAnnoByUserId,
|
getDayNoticeAnnoByUserId,
|
||||||
|
|
@ -192,6 +193,7 @@
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
gotoYy(name) {
|
gotoYy(name) {
|
||||||
|
const cry = new Crypoto()
|
||||||
const params = {
|
const params = {
|
||||||
username: uni.getStorageSync('userPhone'),
|
username: uni.getStorageSync('userPhone'),
|
||||||
jwtToken: uni.getStorageSync('App-Token')
|
jwtToken: uni.getStorageSync('App-Token')
|
||||||
|
|
@ -199,7 +201,7 @@
|
||||||
const tjparams = {
|
const tjparams = {
|
||||||
// username: '17681010134', // 15912575796
|
// username: '17681010134', // 15912575796
|
||||||
// password: 'YNsbd@123456'
|
// password: 'YNsbd@123456'
|
||||||
telephone: uni.getStorageSync('userPhone'),
|
telephone: cry.encrypt(uni.getStorageSync('userPhone')),
|
||||||
jwtToken: uni.getStorageSync('App-Token')
|
jwtToken: uni.getStorageSync('App-Token')
|
||||||
}
|
}
|
||||||
console.log('🚀 ~ gotoYy ~ tjparams:', tjparams)
|
console.log('🚀 ~ gotoYy ~ tjparams:', tjparams)
|
||||||
|
|
@ -243,7 +245,7 @@
|
||||||
})
|
})
|
||||||
} else if( name == '健康体检移动端') {
|
} else if( name == '健康体检移动端') {
|
||||||
uni.request({
|
uni.request({
|
||||||
url: config.tjBaseUrl + '/login',
|
url: config.tjBaseUrl + '/app/loginNoPassword',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
data: tjparams,
|
data: tjparams,
|
||||||
header: {
|
header: {
|
||||||
|
|
@ -251,10 +253,12 @@
|
||||||
},
|
},
|
||||||
success: res => {
|
success: res => {
|
||||||
console.log('🚀 ~ gotoYy ~ res:', res,)
|
console.log('🚀 ~ gotoYy ~ res:', res,)
|
||||||
console.log('🚀 ~ gotoYy ~ res:', res.data.token)
|
console.log('🚀 ~ gotoYy ~ res:', res.data.obj)
|
||||||
if (res.statusCode == 200) {
|
if (res.statusCode == 200) {
|
||||||
uni.removeStorageSync('tjToken')
|
uni.removeStorageSync('tjToken')
|
||||||
uni.setStorageSync('tjToken', res.data.token)
|
uni.removeStorageSync('tjPhone')
|
||||||
|
uni.setStorageSync('tjToken', res.data.obj)
|
||||||
|
uni.setStorageSync('tjPhone', tjparams.telephone)
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
uni.reLaunch({
|
uni.reLaunch({
|
||||||
url: '/pages/HealthExaminationApp/index/index'
|
url: '/pages/HealthExaminationApp/index/index'
|
||||||
|
|
|
||||||
|
|
@ -33,3 +33,22 @@ export default class Crypoto {
|
||||||
|
|
||||||
decrypt
|
decrypt
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const jie_mi=true;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 解密
|
||||||
|
* @param word
|
||||||
|
* @returns {*}
|
||||||
|
*/
|
||||||
|
export const decryptCBC = function(word) {
|
||||||
|
if(!jie_mi){
|
||||||
|
return word;
|
||||||
|
}
|
||||||
|
const encrypted = CryptoJS.AES.decrypt(word, CryptoJS.enc.Utf8.parse('zhgd@bonus@zhgd@bonus@1234567890'), {
|
||||||
|
iv: CryptoJS.enc.Utf8.parse('1234567812345678'),
|
||||||
|
mode: CryptoJS.mode.CBC,
|
||||||
|
padding: CryptoJS.pad.Pkcs7
|
||||||
|
})
|
||||||
|
return encrypted.toString(CryptoJS.enc.Utf8)
|
||||||
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue