diff --git a/src/api/api.js b/src/api/api.js
index 0fe10e54..7b0ec26d 100644
--- a/src/api/api.js
+++ b/src/api/api.js
@@ -130,7 +130,7 @@ const getWorkGroupTreeList = (params) => getAction('/sys/lawsWorkingGroup/list',
const getEnterpriseLevelMapList = (params) => getAction('/sys/lawsGrade/list', params)
// 车型项目下拉数据
-const getCarTypeProjectList = (params) => getAction('/projectLibrary/lawsProjectLibrary/list', params)
+const getCarTypeProjectList = (params) => getAction('/projectLibrary/lawsProjectLibrary/queryList', params)
export {
addRole,
diff --git a/src/api/businessSupport.js b/src/api/businessSupport.js
new file mode 100644
index 00000000..3e63267f
--- /dev/null
+++ b/src/api/businessSupport.js
@@ -0,0 +1,17 @@
+import { getAction, postAction } from './manage'
+
+// 问答库详情-根据id获取问题信息
+const getQuizById = (params) => getAction('/laws/library/lawsProblemLibrary/queryById', params)
+// 问答库回答-回答
+const answerQuiz = (params) => postAction('/laws/library/lawsProblemLibrary/addAnswer', params)
+// 问答库回答-设置置顶
+const setOrCancelTop = (params) => getAction('/laws/library/lawsProblemLibrary/isTop', params)
+// 回答库详情-删除回答
+const deleteAnswer = (params) => postAction('/laws/library/lawsProblemLibrary/deleteAnswer', params)
+
+export {
+ getQuizById,
+ answerQuiz,
+ setOrCancelTop,
+ deleteAnswer
+}
diff --git a/src/common/lang/businessSupport/en.js b/src/common/lang/businessSupport/en.js
index 02625ce5..678d6a7e 100644
--- a/src/common/lang/businessSupport/en.js
+++ b/src/common/lang/businessSupport/en.js
@@ -18,6 +18,7 @@ module.exports = {
cancelTop: 'untop',
setTop: 'Set To Top',
answerQuestion: 'reply to a question',
- word: 'word'
+ word: 'word',
+ pleaseEnterAnswerDesc: '请输入回答描述'
}
}
diff --git a/src/common/lang/businessSupport/zh.js b/src/common/lang/businessSupport/zh.js
index 36ddb563..06a38ded 100644
--- a/src/common/lang/businessSupport/zh.js
+++ b/src/common/lang/businessSupport/zh.js
@@ -18,6 +18,7 @@ module.exports = {
cancelTop: '取消置顶',
setTop: '设置为置顶',
answerQuestion: '回复问题',
- word: '字'
+ word: '字',
+ pleaseEnterAnswerDesc: '请输入回答描述'
}
}
diff --git a/src/views/businessSupport/questionAnswerLibrary/QuestionAnswerList.vue b/src/views/businessSupport/questionAnswerLibrary/QuestionAnswerList.vue
index 936f5cc7..25306580 100644
--- a/src/views/businessSupport/questionAnswerLibrary/QuestionAnswerList.vue
+++ b/src/views/businessSupport/questionAnswerLibrary/QuestionAnswerList.vue
@@ -4,29 +4,33 @@
+
+ dict-code="problem_library_type"
+ v-model="queryParam.type">
+
-
+
+
-
+
+
-
+
@@ -76,7 +80,7 @@
-
+
@@ -123,6 +127,11 @@ export default {
components: { QuizModal, JTable },
data () {
return {
+ /* 排序参数 */
+ isorter: {
+ column: 'quizTime',
+ order: 'desc'
+ },
labelCol: {
span: 4
},
@@ -130,56 +139,49 @@ export default {
span: 14
},
columns: [
- {
+ { // 分类
title: this.$t('businessSupport.questionAnswer.classify'),
align: 'center',
width: 180,
- dataIndex: 'classify_dictText',
+ dataIndex: 'type_dictText',
scopedSlots: { customRender: 'text' }
},
- {
+ { // 标准编号
title: this.$t('standardNumber'),
align: 'center',
width: 180,
dataIndex: 'standardNumber',
scopedSlots: { customRender: 'text' }
},
- {
+ { // 标准名称
title: this.$t('standardName'),
align: 'center',
width: 180,
dataIndex: 'standardName',
scopedSlots: { customRender: 'text' }
},
- {
+ { // 标题
title: this.$t('title'),
align: 'center',
width: 180,
- dataIndex: 'titleSlot',
+ dataIndex: 'title',
scopedSlots: { customRender: 'text' }
},
- {
+ { // 项目
title: this.$t('project'),
align: 'center',
width: 180,
- dataIndex: 'project',
+ dataIndex: 'project_dictText',
scopedSlots: { customRender: 'text' }
},
- {
+ { // 问题描述
title: this.$t('businessSupport.questionAnswer.questionDesc'),
align: 'center',
width: 180,
- dataIndex: 'questionDesc',
+ dataIndex: 'problemDescription',
scopedSlots: { customRender: 'text' }
},
- {
- title: this.$t('businessSupport.questionAnswer.attach'),
- align: 'center',
- width: 180,
- dataIndex: 'attach',
- scopedSlots: { customRender: 'attach' }
- },
- {
+ { // 提问时间
title: this.$t('businessSupport.questionAnswer.quizTime'),
align: 'center',
width: 180,
@@ -195,16 +197,10 @@ export default {
}
],
url: {
- list: '',
- delete: ''
+ list: '/laws/library/lawsProblemLibrary/page',
+ delete: '/laws/library/lawsProblemLibrary/deleteProblem'
},
- userInfo: {},
- dataSource: [
- {
- id: 1,
- // createBy: 'e9ca23d68d884d4ebb19d07889727dae'
- }
- ]
+ userInfo: {}
}
},
mounted () {
diff --git a/src/views/businessSupport/questionAnswerLibrary/modules/QuizModal.vue b/src/views/businessSupport/questionAnswerLibrary/modules/QuizModal.vue
index 48b90032..6888cae0 100644
--- a/src/views/businessSupport/questionAnswerLibrary/modules/QuizModal.vue
+++ b/src/views/businessSupport/questionAnswerLibrary/modules/QuizModal.vue
@@ -11,11 +11,12 @@
+
+ v-decorator.trim="[ 'type', validatorRules.type]">
请选择
国内标准
海外标准
@@ -24,29 +25,33 @@
-
+
+
-
+
+
+
+
+
+
-
@@ -156,13 +164,13 @@ export default {
],
validateTrigger: 'change'
},
- questionDesc: {
+ problemDescription: {
rules: [
{ required: true, message: this.$t('pleaseEnter') + this.$t('businessSupport.questionAnswer.questionDesc') }
],
validateTrigger: 'blur'
},
- attach: {
+ file: {
rules: [
{ required: false, message: this.$t('pleaseSelect') + this.$t('businessSupport.questionAnswer.attach') }
],
@@ -170,7 +178,7 @@ export default {
}
},
url: {
- quiz: ''
+ quiz: '/laws/library/lawsProblemLibrary/addProblem'
},
projectList: [] // 项目下拉框数据
}
diff --git a/src/views/businessSupport/questionAnswerLibrary/page/AnswerPage.vue b/src/views/businessSupport/questionAnswerLibrary/page/AnswerPage.vue
index b5918432..fb823275 100644
--- a/src/views/businessSupport/questionAnswerLibrary/page/AnswerPage.vue
+++ b/src/views/businessSupport/questionAnswerLibrary/page/AnswerPage.vue
@@ -2,7 +2,8 @@
{{ model.title }}
- {{ $t('businessSupport.questionAnswer.poster') + ':' + model.orgCodeTxt + ' ' + model.poster }}
+
+ {{ $t('businessSupport.questionAnswer.poster') + ':' + model.orgCode_dictText + ' ' + model.userId_dictText }}
@@ -14,59 +15,81 @@
- {{ model.project || global.emptyLine }}
+ {{ model.project_dictText || global.emptyLine }}
-
+
-
{{ model.attach || global.emptyLine }}
+
+
+
+
+
+
{{ file.fileName }}
+
+
+
+ {{ $t('download') }}
+
+
+
+
+
+
+
+
+
+
{{ global.emptyLine }}
-
{{ model.questionDesc }}
+
{{ model.problemDescription }}
{{ model.quizTime }}
{{ answerArr.length + $t('businessSupport.questionAnswer.answerNum')}}
-
-
-
-
{{ item.realname }}
-
{{ item.orgCodeTxt }}
+
+
+
+
+
{{ item.name }}
+
{{ item.departName }}
+
+
-
-
+
+
-
{{ currentUser.realname }}
+
{{ currentUser.realname }}
{{ currentUser.orgCodeTxt }}
+
+
+
+
![]()
+
+