Commit 4b2ed69a authored by xioln's avatar xioln

问题修改

parent 81d7711e
......@@ -59,6 +59,7 @@
</template>
<slot name="button"></slot>
</van-form>
<van-popup round v-model="popupShow" :style="{ height: '50%',width: '80%',padding: '20px'}" >{{popupShowText}}</van-popup>
</div>
</template>
<script>
......@@ -83,7 +84,10 @@ export default {
components: {},
// 数据源 给组件分发数据用
data () {
return {}
return {
popupShow: false,
popupShowText: ''
}
},
computed: {
formValue () {
......@@ -200,24 +204,6 @@ export default {
</script>
<style lang="scss">
.form {
// .sub-title {
// font-weight: bold;
// color: #212121;
// padding: 10px 0 10px 5px;
// display: flex;
// flex-direction: row;
// box-sizing: border-box;
// border-bottom: 1px solid #ebedf0;
// &:before {
// content: '';
// width: 4px;
// height: 13px;
// background: #096aff;
// border-radius: 2px;
// align-self: center;
// margin-right: 7px
// }
// }
.sub-title {
text-align: left;
border: none;
......
<template>
<div class="input">
<div class="van-Readable">
<van-field
v-if="itemObj"
v-model="inputValue"
......@@ -8,8 +8,11 @@
:readonly="itemObj.name === 'readable' ? true : false"
:name="name"
:label="label"
:type="itemObj.type"
:type="itemObj.type||'textarea'"
:formatter="item.formatter"
rows="1"
autosize
max-row="0"
>
<div v-if="itemObj.verifyIcon" slot="button">
<img :src="itemObj.verifyIcon" @click="getVerifyCode" />
......@@ -94,11 +97,10 @@ export default {
}
</script>
<style lang="scss" scoped>
.input {
.van-Readable {
::v-deep .van-field__label {
width: auto;
}
img {
width: 70px;
height: 30px;
......@@ -107,5 +109,9 @@ export default {
right: 0%;
transform: translate(-0%, -50%);
}
::v-deep .van-field__control{
display: flex !important;
}
}
</style>
......@@ -7,7 +7,7 @@ const state = {
{ key: 'DeeFlowDxDocumentAttrsEdit', title: '是否归档' },
{ key: 'DeeFlowSecretConfirm', title: '密级确认' },
{ key: 'DeeFlowDxDocumentEditReplyComments', title: '答复意见' },
{ key: 'DeeFlowExtSendOrderEditFeedBack', title: '答复意见' },
// { key: 'DeeFlowExtSendOrderEditFeedBack', title: '答复意见' },
{ key: 'DeeFlowDxDocumentAttrsEditWhetherApplied', title: '封面贴皮' },
{ key: 'taskHistory', title: '签审历史' }
......
......@@ -47,11 +47,16 @@ export default {
},
async mounted () {
console.log('this.$route.query.type', this.$route.query.type)
if (this.$route.query.type === 'ISTART') {
this.tabs = [{ title: '基本信息', key: 'baseInfo' }]
this.activeTab = 'baseInfo'
await this.getIstartFormData()
console.log('222', JSON.parse(localStorage.getItem('taskInfo')))
} else if (['ExtActionItem', 'ExtActionInfo'].includes(this.$route.query.dxClassname)) {
this.tabs = [{ title: '基本信息', key: 'baseInfo' }]
this.activeTab = 'baseInfo'
await this.getFormData()
await this.getForm()
} else {
await this.getFormData()
await this.getForm()
......@@ -153,9 +158,43 @@ export default {
})
},
fiiterData (formData) {
console.log('formData', formData)
formData.forEach(item => {
if (item.title && item.title !== '关联文档') {
// eslint-disable-next-line no-unused-vars
console.log('item.title', item.title)
if (item.title && item.title !== '关联文档' && item.title !== '附件') {
// eslint-disable-next-line no-unused-vars
const that = this
const fd = {
title: item.title,
split: 1,
data: item.data.map(d => {
let show = false
if (d.component?.obscure) {
// eslint-disable-next-line no-eval
show = eval(d.component?.obscure.replace(/this/g, 'that'))
}
return {
title: d.title,
key: d.key,
disabled: d.disabled,
formatter: function (row) {
if (row && ['true', 'false'].includes(row)) {
return row === 'true' ? '是' : '否'
} else {
return row
}
},
component: {
name: d?.component?.name,
// options: d.component.options,
dictTypeCode: d?.fildProp?.type === 'DictDataVO' ? d?.fildProp?.rule?.dictTypeCode : '',
show: show
}
}
})
}
this.formData.push(fd)
} else if (item.title !== '附件') {
const that = this
const fd = {
title: item.title,
......@@ -163,7 +202,7 @@ export default {
data: item.data.map(d => {
let show = false
if (d.component?.obscure) {
// eslint-disable-next-line no-eval
// eslint-disable-next-line no-eval
show = eval(d.component?.obscure.replace(/this/g, 'that'))
}
return {
......@@ -178,9 +217,9 @@ export default {
}
},
component: {
name: d.component.name,
name: d?.component?.name,
// options: d.component.options,
dictTypeCode: d.fildProp.type === 'DictDataVO' ? d.fildProp.rule.dictTypeCode : '',
dictTypeCode: d?.fildProp?.type === 'DictDataVO' ? d?.fildProp?.rule?.dictTypeCode : '',
show: show
}
}
......
<template>
<div class="choose-person">
<van-dialog
v-model="show"
title="委派"
show-cancel-button
confirm-button-color="#5282f0"
:before-close="beforeClose"
>
<div class="dialog-box">
<van-search v-model="search_value" placeholder="请输入关键字进行搜索" />
<div class="select-box">
<van-radio-group v-if="selectList.length > 0" v-model="value">
<van-radio
checked-color="#5282f0"
v-for="item in selectList"
:name="item.id"
:key="item.id"
@click="SelectEvent(item)"
>
{{ item.label }}
</van-radio>
</van-radio-group>
</div>
</div>
</van-dialog>
</div>
</template>
<script>
import { getUsersByAccount } from '@/api/userSystem'
import { completeTask } from '@/api/taskDetail'
export default {
props: {
basicData: {
type: Object,
require: true
}
},
data () {
return {
show: false,
search_value: '',
value: '',
selectList: []
}
},
components: {
},
watch: {
search_value (value) {
if (value && value.length > 1) {
this.SearchFilterEvent(value)
}
}
},
created () {
},
mounted () {
},
methods: {
SearchFilterEvent (value) {
let array = []
getUsersByAccount({ userAccount: value }).then(res => {
array = res.items.map(item => {
return {
id: item.id,
label: `${item.name}(${item.num})`
}
})
this.selectList = array
})
},
async beforeClose (action, done) {
// if (action === 'confirm') {
// setTimeout(done, 1000)
// } else {
// done()
// }
await this.delegateTask(this.value)
},
SelectEvent (item) {
// this.delegateTask(item.id)
},
// 重新指派
delegateTask (userId) {
const params = {
operationName: 'delegateTask',
operator: localStorage.getItem('userId'),
id: this.basicData.id,
targetUserId: userId,
processDefinitionId: this.basicData.processDefinitionId,
processInstId: this.basicData.processInstanceId,
taskDefinitionKey: this.basicData.taskDefinitionKey
}
this.handleFinish(params)
},
handleFinish (params, callback, errCallBack) {
completeTask(params).then(res => {
this.$router.go(-1)
}).catch(res => {
if (errCallBack instanceof Function) errCallBack(res)
})
}
}
}
</script>
<style lang="scss">
.choose-person {
padding: 15px 0px 30px;
box-sizing: border-box;
.dialog-box {
height: 200px;
}
.select-box {
padding: 0px 15px 0px;
}
.van-radio {
padding: 10px 0px;
border-bottom: 1px solid #efefef;
}
}
</style>
......@@ -2,8 +2,8 @@
<div class="task-btn">
<!-- <van-button type="info" round size="small" @click="reassign">重新指派</van-button>
<van-button type="info" round size="small" @click="finishTask">完成任务</van-button> -->
<van-button type="default" size="small" round @click="reassign">
重新指
<van-button v-if="appointShow" type="default" size="small" round @click="reassign">
</van-button>
<van-button
type="info"
......@@ -13,9 +13,12 @@
@click="finishTask"
>完成任务</van-button
>
<choose-person :basicData="basicData" ref="choosePerson"></choose-person>
</div>
</template>
<script>
import choosePerson from './components/choosePerson.vue'
export default {
props: {
basicData: {
......@@ -23,16 +26,29 @@ export default {
require: true
}
},
components: {
choosePerson
},
data () {
return {
comLoading: false
}
},
computed: {
appointShow: {
get () {
return this.basicData?.operationInfo?.find(item => item?.pluginInfo?.label === '委派')
}
}
},
watch: {
},
created () { },
mounted () { },
mounted () {
},
methods: {
reassign () {
console.log('重新指派!')
this.$refs.choosePerson.show = true
},
finishTask () {
this.comLoading = true
......
......@@ -64,7 +64,6 @@ export default {
methods: {
// 跳转详情页面
goDetailsInfo (item) {
console.log('item', item)
if (this.$route.query.title === '我发起的任务') {
localStorage.setItem('taskInfo', JSON.stringify(item))
this.$router.push({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment