dingxin 6 years ago
parent
commit
41da9c0a5b

+ 0
- 1
VUECODE/smart-property-manage/src/views/social/announcement/details.vue View File

52
         for (let i = 0; i < imgList.length; i++) {
52
         for (let i = 0; i < imgList.length; i++) {
53
           this.ruleForm.contentImg.push({ url: imgList[i].imageUrl })
53
           this.ruleForm.contentImg.push({ url: imgList[i].imageUrl })
54
         }
54
         }
55
-        console.log('详情', resData)
56
         if (this.ruleForm.status === '0') {
55
         if (this.ruleForm.status === '0') {
57
           this.isEdi = false
56
           this.isEdi = false
58
         }
57
         }

+ 0
- 2
VUECODE/smart-property-manage/src/views/social/announcement/edit.vue View File

81
   },
81
   },
82
   methods: {
82
   methods: {
83
     submitForm(formName,status) {
83
     submitForm(formName,status) {
84
-      console.log(status)
85
       // 加载框
84
       // 加载框
86
       const loading = this.$loading({
85
       const loading = this.$loading({
87
         lock: true,
86
         lock: true,
156
     },
155
     },
157
     sortHandleChange(value) { // 权重值
156
     sortHandleChange(value) { // 权重值
158
       this.ruleForm.sort = value
157
       this.ruleForm.sort = value
159
-      console.log(value)
160
     },
158
     },
161
     getById(id) { // 页面初始化后调用此方法根据ID获取公告信息
159
     getById(id) { // 页面初始化后调用此方法根据ID获取公告信息
162
       this.ruleForm.id=this.$route.params.id
160
       this.ruleForm.id=this.$route.params.id

+ 14
- 1
VUECODE/smart-property-manage/src/views/social/announcement/index.vue View File

179
         this.$message.error('请选择一行数据进行修改!')
179
         this.$message.error('请选择一行数据进行修改!')
180
         return
180
         return
181
       }
181
       }
182
-      this.$router.push({ name: 'announcement-edit', params: { id: ids[0] }})
182
+       let ide= this.deleteIds[0]
183
+       this.listQuery.id = ide 
184
+      this.$store.dispatch('AnnouncementById', this.listQuery).then((res) => {
185
+        const resData = res.data
186
+        const announcement = resData.tpAnnouncement
187
+        const imgList = resData.studentList
188
+        this.listQuery = announcement
189
+        console.log("1",this.listQuery.status)
190
+        if(this.listQuery.status == 0){
191
+          this.$message.error('已作废不可以修改')
192
+          return
193
+        }
194
+          this.$router.push({ name: 'announcement-edit', params: { id: ids[0] }})
195
+      })
183
       },
196
       },
184
     deleteAnnouncement(){
197
     deleteAnnouncement(){
185
       const ids = this.deleteIds
198
       const ids = this.deleteIds