You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
91 lines
1.7 KiB
91 lines
1.7 KiB
import request from '@/components/hzjc/utils/request.js'
|
|
|
|
let project = {}
|
|
|
|
/**
|
|
* 获取项目LOGO
|
|
* @date 2022-10-13
|
|
*/
|
|
project.getLogo = function() {
|
|
return new Promise((resolve, reject) => {
|
|
request.getData('project/api/Config/getLogo', {
|
|
}).then(res => {
|
|
resolve(res)
|
|
}).catch(res => {
|
|
reject(res)
|
|
})
|
|
})
|
|
}
|
|
|
|
/**
|
|
* 获取微信小程序首页分享基础信息
|
|
* @date 2022-10-28
|
|
*/
|
|
project.getMpweixinConfig = function() {
|
|
return new Promise((resolve, reject) => {
|
|
request.getData('project/api/Config/getMpweixinConfig', {
|
|
}).then(res => {
|
|
resolve(res)
|
|
}).catch(res => {
|
|
reject(res)
|
|
})
|
|
})
|
|
}
|
|
|
|
/**
|
|
* 获取常见问题设置
|
|
* @date 2022-12-16
|
|
*/
|
|
project.getQuestionConfig = function() {
|
|
return new Promise((resolve, reject) => {
|
|
request.getData('project/api/Question/getQuestionConfig', {
|
|
}).then(res => {
|
|
resolve(res)
|
|
}).catch(res => {
|
|
reject(res)
|
|
})
|
|
})
|
|
}
|
|
|
|
/**
|
|
* 获取常见问题列表
|
|
* @param {object} that
|
|
* @param {int} isFirstPage 是否第一页 0--不是 1--是
|
|
* @date 2022-12-16
|
|
*/
|
|
project.listQuestion = function(that, isFirstPage) {
|
|
return new Promise((resolve, reject) => {
|
|
request.getList('project/api/Question/listQuestion', {
|
|
|
|
}, {
|
|
that: that,
|
|
first_page: isFirstPage
|
|
}).then(res => {
|
|
resolve(res)
|
|
}).catch(res => {
|
|
reject(res)
|
|
})
|
|
})
|
|
}
|
|
|
|
/**
|
|
* 获取常见问题详情
|
|
* @param {int} questionId 问题ID
|
|
* @date 2022-12-16
|
|
*/
|
|
project.getQuestion = function(questionId) {
|
|
return new Promise((resolve, reject) => {
|
|
request.getData('project/api/Question/getQuestion', {
|
|
question_id: questionId
|
|
}).then(res => {
|
|
resolve(res)
|
|
}).catch(res => {
|
|
reject(res)
|
|
})
|
|
})
|
|
}
|
|
|
|
|
|
|
|
export default project
|