提交 a496f911 authored 作者: lihuihui's avatar lihuihui

办事大厅修改

上级 bbb96923
......@@ -20,7 +20,7 @@ export default class AffairsAPI extends BaseAPI {
* symposium_lecturer
* 返回 {'flag' : true, 'errors' : []}
*/
submitLearning = (obj = {}) => this.post('/v2/lobby/processes', obj)
submitLearning = (obj = {}) => this.post('/v2/lobby/processes', obj, { headers: { 'Content-Type': 'application/json' } })
/* 删除事务 */
deleteAffairs = (reid) => this.delete(`/v2/lobby/processes/${reid}`, {})
/* 获取事务详情 */
......
......@@ -44,7 +44,7 @@ export default class ReportAPI extends BaseAPI {
* report_description 报告描述
* file_url 文章URL
*/
submitReport = (rid, obj = {}) => this.post(`/v2/education/symposium/${rid}/report`, obj)
submitReport = (rid, obj = {}) => this.post(`/v2/education/symposium/${rid}/report`, obj, { headers: { 'Content-Type': 'application/json' } })
/**
* 获取学术报告详情
*/
......
......@@ -19,7 +19,7 @@
<template
v-for="(head, index) in tableHead">
<el-table-column
:show-overflow-tooltip="true"
:show-overflow-tooltip="false"
:fixed="head.fix"
:key="index"
:label="head.label"
......
......@@ -96,7 +96,7 @@ export default {
mounted () {
if (this.rid !== '-1') {
const loading = this.$loading({ lock: true, text: '', spinner: '', background: 'rgba(255, 255, 255, 0.9)' })
cAction.reportAction.getReportActive(this.rid).then(data => {
cAction.Affairs.getReportActive(this.rid).then(data => {
if (data.symposium_name) {
this.setApply.name = data.symposium_name
this.setApply.time = data.symposium_time
......@@ -126,7 +126,7 @@ export default {
},
uploadFile () {
const loading = this.$loading({ lock: true, text: '', spinner: '', background: 'rgba(255, 255, 255, 0.9)' })
cAction.reportAction.uploadFile(this.file).then(data => {
cAction.Affairs.uploadFile(this.file).then(data => {
this.successFileUrl = data.url
// this.filesArr.pop()
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
......@@ -136,7 +136,7 @@ export default {
this.dialogVisible = true
},
gobackActiveList () {
this.$router.push({ path: '/app/service-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall' })
},
onApplyFrom () {
this.$refs.setApplyForm.validate((valid) => {
......@@ -150,7 +150,7 @@ export default {
let reportActive = null
if (this.rid !== '-1') {
/* 修改 */
reportActive = cAction.reportAction.submitLearning(this.rid, {
reportActive = cAction.Affairs.submitLearning(this.rid, {
symposium_name: this.setApply.name,
symposium_time: this.setApply.time,
symposium_lecturer: this.setApply.author,
......@@ -160,7 +160,7 @@ export default {
})
} else {
/* 新建 */
reportActive = cAction.reportAction.submitLearning({
reportActive = cAction.Affairs.submitLearning({
affair_id: this.affair_id,
personal_name: this.setApply.personal_name,
class_name: this.setApply.class_name,
......@@ -173,7 +173,7 @@ export default {
if (data.success) {
this.$message({ type: 'success', message: '提交成功' })
setTimeout(() => {
this.$router.push({ path: '/app/service-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall' })
}, 500)
}
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
......
......@@ -2,7 +2,6 @@
<div>
<div class="con-title">
<div>办事大厅</div>
<div @click="goMyApply">我的申请</div>
</div>
<Tap :tapParam='tapParam' @tapParam='tapIndexs'></Tap>
<div class="con-box">
......@@ -21,6 +20,17 @@
/>
</template>
</div>
<el-dialog
title="提示"
:visible.sync="dialogVisible"
width="30%"
>
<span>确定删除?</span>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">取 消</el-button>
<el-button type="primary" @click="confirmDeletion">确 定</el-button>
</span>
</el-dialog>
</div>
</template>
......@@ -35,6 +45,7 @@ export default {
},
data () {
return {
dialogVisible: false,
ismPageFlag: false,
tapIndex: 0,
// tap切换
......@@ -56,7 +67,8 @@ export default {
dataParam: 1,
params: {},
// params: { keywords: '', curPage: 1, pageSize: 5, total: '' },
objFn: {}
objFn: {},
_obj: null
// 音分享
}
},
......@@ -68,35 +80,41 @@ export default {
this.VueEvent.$on('command-tablelist-x', (_obj) => {
if (_obj.command.command === 'activelist-show') {
const rid = _obj.tableData[_obj.index - 1].id
this.$router.push({ path: `/app/service-hall/view-report/${rid}` })
this.$router.push({ path: `/app/affairs-hall/view-report/${rid}` })
}
if (_obj.command.command === 'activereport-add') {
const syid = _obj.tableData[_obj.index - 1].formId
this.$router.push({ path: `/app/service-hall/upload-report/${syid}/-1` })
this.$router.push({ path: `/app/affairs-hall/upload-report/${syid}/-1` })
}
if (_obj.command.command === 'activelist-edit') {
const rid = _obj.tableData[_obj.index - 1].id
this.$router.push({ path: `/app/service-hall/learning-add/${rid}`, query: { id: this.tapParam[0].arrItem[this.tapIndex].val } })
this.$router.push({ path: `/app/affairs-hall/learning-add/${rid}`, query: { id: this.tapParam[0].arrItem[this.tapIndex].val } })
}
if (_obj.command.command === 'activelist-delete') {
this.dialogVisible = true
}
this._obj = _obj
})
},
methods: {
confirmDeletion () {
const _obj = this._obj
const rid = _obj.tableData[_obj.index - 1].id
/* 删除 */
const loading = this.$loading({ lock: true, text: '', spinner: '', background: 'rgba(255, 255, 255, 0.9)' })
cAction.reportAction.deleteAffairs(rid).then(data => {
cAction.Affairs.deleteAffairs(rid).then(data => {
if (data.success) {
this.$message({ type: 'success', message: '删除成功' })
this.setmPage()
}
}).catch(e => { this.$message.error(e.message) }).finally(() => { loading.close() })
}
})
this.dialogVisible = false
},
methods: {
setmPage () {
this.objFn = {
paramsFn: (_this) => { return { affair_id: this.dataParam } },
nameAPI: 'getAffairsData',
actionClass: 'reportAction',
actionClass: 'Affairs',
// nameExcel: 'getStatSummaryExcel',
nameExcel: 'getExportExcel3_4_14',
callback: (_this, data) => {
......@@ -158,7 +176,7 @@ export default {
{ prop: 'approve_status', label: '审核状态', minWidth: '80', fix: false },
{ prop: 'approve_time', label: '审核时间', minWidth: '120', fix: false },
// { prop: '', label: '', minWidth: '', fix: false, goObj: { routerName: '', params: {} } }, // 点击跳转页面并传参数
{ prop: 'operate-x', label: '操作', width: '200px', fix: false, commandArr: "[ { command: 'activelist-show', name: '查看报告' }, { command: 'activereport-add', name: '上传报告' }, { command: 'activelist-edit', name: '编辑' }, { command: 'activelist-delete', name: '删除' } ]" }
{ prop: 'operate-x', label: '操作', width: '200px', fix: false, commandArr: [{ command: 'activelist-show', name: '查看报告' }, { command: 'activereport-add', name: '上传报告' }, { command: 'activelist-edit', name: '编辑' }, { command: 'activelist-delete', name: '删除' }] }
]
break
case 1:
......@@ -206,15 +224,15 @@ export default {
},
golearningAdd (n) {
if (n === 0) {
this.$router.push({ path: '/app/service-hall/learning-add/-1', query: { id: this.tapParam[0].arrItem[this.tapIndex].val } })
this.$router.push({ path: '/app/affairs-hall/learning-add/-1', query: { id: this.tapParam[0].arrItem[this.tapIndex].val } })
} else if (n === 1) {
this.$router.push({ path: '/app/service-hall/share-add/-1', query: { id: this.tapParam[0].arrItem[this.tapIndex].val } })
this.$router.push({ path: '/app/affairs-hall/share-add/-1', query: { id: this.tapParam[0].arrItem[this.tapIndex].val } })
} else {
this.$router.push({ path: '/app/service-hall/again-add/-1', query: { id: this.tapParam[0].arrItem[this.tapIndex].val } })
this.$router.push({ path: '/app/affairs-hall/again-add/-1', query: { id: this.tapParam[0].arrItem[this.tapIndex].val } })
}
},
goMyApply () {
this.$router.push({ path: '/app/service-hall/my-apply', query: { id1: this.tapParam[0].arrItem[0].val, id2: this.tapParam[0].arrItem[1].val, id3: this.tapParam[0].arrItem[2].val } })
this.$router.push({ path: '/app/affairs-hall/my-apply', query: { id1: this.tapParam[0].arrItem[0].val, id2: this.tapParam[0].arrItem[1].val, id3: this.tapParam[0].arrItem[2].val } })
}
}
}
......
......@@ -119,7 +119,7 @@ export default {
console.log('------', this.affair_id)
if (this.rid !== '-1') {
const loading = this.$loading({ lock: true, text: '', spinner: '', background: 'rgba(255, 255, 255, 0.9)' })
cAction.reportAction.getAffairsDetails(this.rid).then(data => {
cAction.Affairs.getAffairsDetails(this.rid).then(data => {
console.log(data)
if (data.form.symposium_name) {
this.setApply.personal_name = data.form.personal_name
......@@ -158,7 +158,7 @@ export default {
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
},
gobackActiveList () {
this.$router.push({ path: '/app/service-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall' })
},
onApplyFrom () {
this.$refs.setApplyForm.validate((valid) => {
......@@ -172,7 +172,7 @@ export default {
let reportActive = null
if (this.rid !== '-1') {
/* 修改 */
reportActive = cAction.reportAction.updateAffairs(this.rid, {
reportActive = cAction.Affairs.updateAffairs(this.rid, {
affair_id: this.affair_id,
personal_name: this.setApply.personal_name,
class_name: this.setApply.class_name,
......@@ -185,7 +185,7 @@ export default {
})
} else {
/* 新建 */
reportActive = cAction.reportAction.submitLearning({
reportActive = cAction.Affairs.submitLearning({
affair_id: this.affair_id,
personal_name: this.setApply.personal_name,
class_name: this.setApply.class_name,
......@@ -201,7 +201,7 @@ export default {
if (data.success) {
this.$message({ type: 'success', message: '提交成功' })
setTimeout(() => {
this.$router.push({ path: '/app/service-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall' })
}, 500)
}
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
......
......@@ -127,7 +127,7 @@ export default {
},
methods: {
getSelect () {
cAction.reportAction.getAffairsType().then(data => {
cAction.Affairs.getAffairsType().then(data => {
for (let i = 0; i < data.length; i++) {
this.options.push({ label: data[i].affair_name, value: data[i].id })
}
......@@ -136,7 +136,7 @@ export default {
})
},
onSubmit () {
cAction.reportAction.getAffairsData({ affair_id: this.selsectValue }).then(data => {
cAction.Affairs.getAffairsData({ affair_id: this.selsectValue }).then(data => {
this.unfinishedCount = []
this.finishedCount = []
let num1 = 0
......
......@@ -113,7 +113,7 @@ export default {
mounted () {
if (this.rid !== '-1') {
const loading = this.$loading({ lock: true, text: '', spinner: '', background: 'rgba(255, 255, 255, 0.9)' })
cAction.reportAction.getReportActive(this.rid).then(data => {
cAction.Affairs.getReportActive(this.rid).then(data => {
if (data.symposium_name) {
this.setApply.name = data.symposium_name
this.setApply.time = data.symposium_time
......@@ -150,7 +150,7 @@ export default {
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
},
gobackActiveList () {
this.$router.push({ path: '/app/service-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall' })
},
onApplyFrom () {
this.$refs.setApplyForm.validate((valid) => {
......@@ -164,7 +164,7 @@ export default {
let reportActive = null
if (this.rid !== '-1') {
/* 修改 */
reportActive = cAction.reportAction.submitLearning(this.rid, {
reportActive = cAction.Affairs.submitLearning(this.rid, {
symposium_name: this.setApply.name,
symposium_time: this.setApply.time,
symposium_lecturer: this.setApply.author,
......@@ -174,7 +174,7 @@ export default {
})
} else {
/* 新建 */
reportActive = cAction.reportAction.submitLearning({
reportActive = cAction.Affairs.submitLearning({
affair_id: this.affair_id,
personal_name: this.setApply.personal_name,
trade_name: this.setApply.trade_name,
......@@ -188,7 +188,7 @@ export default {
if (data.success) {
this.$message({ type: 'success', message: '提交成功' })
setTimeout(() => {
this.$router.push({ path: '/app/service-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall' })
}, 500)
}
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
......
......@@ -80,7 +80,7 @@ export default {
mounted () {
if (this.reid !== '-1') {
const loading = this.$loading({ lock: true, text: '', spinner: '', background: 'rgba(255, 255, 255, 0.9)' })
cAction.reportAction.getSubmitReport(this.rid, this.reid).then(data => {
cAction.Affairs.getSubmitReport(this.rid, this.reid).then(data => {
if (data.report_name) {
this.setSubmit.name = data.report_name
this.setSubmit.title = data.report_description
......@@ -107,14 +107,13 @@ export default {
},
uploadFile () {
const loading = this.$loading({ lock: true, text: '', spinner: '', background: 'rgba(255, 255, 255, 0.9)' })
cAction.chapterAction.uploadFile(this.file).then(data => {
cAction.Affairs.uploadFile(this.file).then(data => {
this.successFileUrl = data.url
this.filesArr.pop()
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
},
gobackActiveList () {
// this.$router.push({ path: `/app/my-learn/report-list-all/${this.rid}` })
this.$router.push({ path: '/app/service-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall' })
},
onSubmitFrom () {
this.$refs.setSubmitForm.validate((valid) => {
......@@ -128,7 +127,7 @@ export default {
let report = null
if (this.reid !== '-1') {
/* 修改 */
report = cAction.reportAction.updateSubmitReport(this.rid, this.reid, {
report = cAction.Affairs.updateSubmitReport(this.rid, this.reid, {
report_name: this.setSubmit.name,
report_description: this.setSubmit.title,
file_url: JSON.stringify([{
......@@ -138,7 +137,7 @@ export default {
})
} else {
/* 新建 */
report = cAction.reportAction.submitReport(this.rid, {
report = cAction.Report.submitReport(this.rid, {
report_name: this.setSubmit.name,
report_description: this.setSubmit.title,
file_url: JSON.stringify([{
......@@ -151,7 +150,7 @@ export default {
if (data.flag) {
this.$message({ type: 'success', message: '提交成功' })
setTimeout(() => {
this.$router.push({ path: `/app/my-learn/report-list-all/${this.rid}` })
this.$router.push({ path: `/app/affairs-hall/view-report/${this.rid}` })
}, 500)
}
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
......
......@@ -43,7 +43,7 @@ export default {
objFn: {
paramsFn: (_this) => { return { rid: this.rid } },
nameAPI: 'getReportListAll',
actionClass: 'reportAction',
actionClass: 'Report',
// nameExcel: 'getStatSummaryExcel',
nameExcel: 'getExportExcel3_4_14',
callback: (_this, data) => {
......@@ -62,13 +62,13 @@ export default {
this.VueEvent.$on('command-tablelist-x', (_obj) => {
if (_obj.command.command === 'reportlist-edit') {
const reid = _obj.tableData[_obj.index - 1].id
this.$router.push({ path: `/app/my-learn/report-submit/${this.rid}/${reid}` })
this.$router.push({ path: `/app/learn/report-submit/${this.rid}/${reid}` })
}
if (_obj.command.command === 'reportlist-delete') {
const reid = _obj.tableData[_obj.index - 1].id
/* 删除 */
const loading = this.$loading({ lock: true, text: '', spinner: '', background: 'rgba(255, 255, 255, 0.9)' })
cAction.reportAction.deleteSubmitReport(this.rid, reid).then(data => {
cAction.Affairs.deleteSubmitReport(this.rid, reid).then(data => {
if (data.flag) {
this.$message({ type: 'success', message: '删除成功' })
}
......@@ -79,10 +79,10 @@ export default {
},
methods: {
goReportSubmit () {
this.$router.push({ path: `/app/my-learn/report-submit/${this.rid}/-1` })
this.$router.push({ path: `/app/learn/report-submit/${this.rid}/-1` })
},
gobackReportActiveList () {
this.$router.push({ path: '/app/service-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall' })
}
}
}
......
......@@ -41,8 +41,10 @@ const agentProcessor = () => {
headers['Host'] = 'sso.ezijing.com'
headers['host'] = 'sso.ezijing.com'
} else {
headers['Host'] = 'lms-api.ezijing.com'
headers['host'] = 'lms-api.ezijing.com'
// headers['Host'] = 'lms-api.ezijing.com'
// headers['host'] = 'lms-api.ezijing.com'
headers['Host'] = 'lms-worklobby-api.ezijing.com'
headers['host'] = 'lms-worklobby-api.ezijing.com'
}
/* 测试 */
// if (/\/essay/gi.test(options.url) && /post/gi.test(req.method)) {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论