@@ -74,87 +29,15 @@ export default {
visible: false,
dataForm: {
id: '',
- userId: '',
- nickName: '',
- userFace: '',
- mobile: '',
- topicContent: '',
- grid: '',
- gridId: '',
- eventState: '',
advice: '',
- delFlag: '',
- revision: '',
- createdBy: '',
- createdTime: '',
- updatedBy: '',
- updatedTime: '',
- parentDeptIds: '',
- parentDeptNames: '',
- allDeptIds: '',
- allDeptNames: ''
}
}
},
computed: {
dataRule () {
return {
- userId: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- nickName: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- userFace: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- mobile: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- topicContent: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- grid: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- gridId: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- eventState: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
advice: [
{ required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- delFlag: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- revision: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- createdBy: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- createdTime: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- updatedBy: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- updatedTime: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- parentDeptIds: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- parentDeptNames: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- allDeptIds: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
- ],
- allDeptNames: [
- { required: true, message: this.$t('validate.required'), trigger: 'blur' }
]
}
}
@@ -171,7 +54,7 @@ export default {
},
// 获取信息
getInfo () {
- this.$http.get(`/event/veterantopic/${this.dataForm.id}`).then(({ data: res }) => {
+ this.$http.get(`/events/veterantopic/${this.dataForm.id}`).then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
@@ -187,7 +70,7 @@ export default {
if (!valid) {
return false
}
- this.$http[!this.dataForm.id ? 'post' : 'put']('/event/veterantopic/', this.dataForm).then(({ data: res }) => {
+ this.$http[!this.dataForm.id ? 'post' : 'put']('/events/veterantopic/', this.dataForm).then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
diff --git a/src/views/modules/events/veterantopic.vue b/src/views/modules/events/veterantopic.vue
index b377aa9..4e73c60 100644
--- a/src/views/modules/events/veterantopic.vue
+++ b/src/views/modules/events/veterantopic.vue
@@ -3,7 +3,7 @@
-
+
{{ $t('query') }}
@@ -16,31 +16,18 @@
-
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
- {{ $t('update') }}
- {{ $t('delete') }}
+ 审核
+ {{ $t('delete') }}
@@ -67,7 +54,7 @@ export default {
data () {
return {
mixinViewModuleOptions: {
- getDataListURL: '/event/veterantopic/page',
+ getDataListURL: '/events/veterantopic/page',
getDataListIsPage: true,
deleteURL: '/event/veterantopic',
deleteIsBatch: true
@@ -79,6 +66,21 @@ export default {
},
components: {
AddOrUpdate
+ },
+ methods: {
+ formatState: function (row, column) {
+ let state = row.eventState
+ if (state == '9') {
+ return '待审核'
+ } else if (state == '1') {
+ return '审核不通过'
+ } else if (state == '2') {
+ return '审核通过'
+ }else{
+ return '待审核'
+ }
+}
}
+
}