21819 2 years ago
parent
commit
89e498e3fb
  1. 4
      src/api/mail.ts
  2. 23
      src/views/work/Query.vue
  3. 8
      src/views/work/components/ConfirmedCompletion.vue

4
src/api/mail.ts

@ -23,3 +23,7 @@ export function addMail(body) {
export function addCoHandling(body) { export function addCoHandling(body) {
return request.post({ url: '/mail/coHandling/add', body}) return request.post({ url: '/mail/coHandling/add', body})
} }
export function deleteMail(body) {
return request.post({ url: '/mail/delete', body})
}

23
src/views/work/Query.vue

@ -184,6 +184,8 @@
<el-button type="primary" link @click="handleMailLabel(row.id)">标签</el-button> <el-button type="primary" link @click="handleMailLabel(row.id)">标签</el-button>
<el-button type="primary" link @click="handleTodoByChange(row.id)" <el-button type="primary" link @click="handleTodoByChange(row.id)"
v-show="handleMailCategory(row)">转为待办</el-button> v-show="handleMailCategory(row)">转为待办</el-button>
<el-button type="primary" link @click="handleDelete(row.id)"
v-show="IsdeleteMail(row)">删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -230,6 +232,8 @@ import { getToken } from '@/utils/auth'
import axios from 'axios' import axios from 'axios'
import { useRouterParamsStore } from "@/stores/modules/routerParams"; import { useRouterParamsStore } from "@/stores/modules/routerParams";
import { useRoute } from "vue-router"; import { useRoute } from "vue-router";
import feedback from "@/utils/feedback";
import {deleteMail} from "@/api/mail";
const rowKey = "id"; const rowKey = "id";
const loading = ref(false) const loading = ref(false)
@ -507,12 +511,31 @@ const handleTodoByChange = (mailId: any) => {
showTodoByChange.value = true showTodoByChange.value = true
activeMailId.value = mailId activeMailId.value = mailId
} }
const handleDelete = async (mailId: any) => {
if(mailId == ""||mailId == null){
return;
}
await feedback.confirm("确定要删除?");
await deleteMail({id:mailId});
feedback.msgSuccess("删除成功");
getList()
};
const handleMailCategory = (row: any) => { const handleMailCategory = (row: any) => {
const allowChangeList = ['终止类', '无效类'] const allowChangeList = ['终止类', '无效类']
return allowChangeList.includes(row.mailCategory) return allowChangeList.includes(row.mailCategory)
} }
const IsdeleteMail = (row: any) => {
const allowChangeList = ['first_sign', 'first_distribute']
return allowChangeList.includes(row.flowKey)
}
getList() getList()
</script> </script>

8
src/views/work/components/ConfirmedCompletion.vue

@ -253,7 +253,13 @@ function isSatisfactionNonConsistent() {
if (!props.mail.satisfaction || !props.mail.verifyFeedback) { if (!props.mail.satisfaction || !props.mail.verifyFeedback) {
return false return false
} }
return getSatisfaction() !== props.mail.verifyFeedback if(getSatisfaction()!== props.mail.verifyFeedback){
if(getSatisfaction()=="满意"&&props.mail.verifyFeedback=="非常满意"){
return false;
}else{
return true;
}
}
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>

Loading…
Cancel
Save