Commit 2d08aaa2 authored by 张毅辰's avatar 张毅辰

工作流(组织审批提交)

parent cb8d766a
...@@ -68,8 +68,8 @@ export default { ...@@ -68,8 +68,8 @@ export default {
}, },
deptTree: [ deptTree: [
{ {
deptName: '部门1', deptName: '铸造部',
deptId: 1 deptId: 103
}, },
{ {
deptName: '部门2', deptName: '部门2',
......
...@@ -28,10 +28,10 @@ ...@@ -28,10 +28,10 @@
<ul> <ul>
<li v-for="(item,index) in myApprovalList" :key="index" class="my_approval_li"> <li v-for="(item,index) in myApprovalList" :key="index" class="my_approval_li">
<uni-swipe-action-item :right-options="options" @click="bindClick($event,item.eventId)" @change="swipeChange($event, index)"> <uni-swipe-action-item :right-options="options" @click="bindClick($event,item.eventId)" @change="swipeChange($event, index)">
<view class="my_approval_item" @click="toNav(item.businessId, item.nodeId)"> <view class="my_approval_item" @click="toNav(item.businessId, item.nodeId, item)">
<h3 class="my_approval_title"> <h3 class="my_approval_title">
<text>[{{item.businessTypeName}}]--{{item.createUserName}}</text> <text>[{{item.businessTypeName}}]--{{item.createUserName}}</text>
<text class="approval_title_right">{{item.status === '10' ? '待审批' :item.status === '2' ? '已审批':item.status === '5' ? '驳回' : ''}}</text> <text class="approval_title_right">{{item.status === '10' ? '待审批' :item.status === '5' ? '驳回' : item.status === '3' ? '驳回' : item.status === '2' ? '已通过' : ''}}</text>
</h3> </h3>
<view class="my_approval_info"> <view class="my_approval_info">
...@@ -85,20 +85,35 @@ export default{ ...@@ -85,20 +85,35 @@ export default{
] ]
} }
}, },
created() { onLoad() {
this.getDocumentList() this.getDocumentList()
}, },
created() {
},
methods:{ methods:{
/** 详情页跳转*/ /** 详情页跳转*/
toNav(id, nodeId) { toNav(id, nodeId, item) {
uni.navigateTo({ if (item.status === '3') {
url: `/pages/flow/work?businessId=${id}&nodeId=${nodeId}&type=see`, if (item.businessType === '1001') {
success:(res) =>{ uni.navigateTo({
}, url: `/pages/classes/classesInfo?businessId=${item.businessDocumentId}`,
fail:(err) =>{ success:(res) =>{
console.log(err) },
fail:(err) =>{
console.log(err)
}
});
} }
}); } else {
uni.navigateTo({
url: `/pages/flow/work?businessId=${id}&nodeId=${nodeId}&type=see`,
success:(res) =>{
},
fail:(err) =>{
console.log(err)
}
});
}
}, },
/** 查询单据列表*/ /** 查询单据列表*/
getDocumentList() { getDocumentList() {
......
<template> <template>
<view style="padding: 10px;"> <view style="padding: 10px;">
<ClassForm v-if="processType === '1001'" :newBusinessDocument="newBusinessDocument" :oldBusinessDocument="oldBusinessDocument"></ClassForm> <ClassForm v-if="processType === '1001'" :newBusinessDocument="newBusinessDocument" :oldBusinessDocument="oldBusinessDocument"></ClassForm>
<OrganizationForm v-if="processType === '0003'" :newBusinessDocument="newBusinessDocument" :oldBusinessDocument="oldBusinessDocument"></OrganizationForm>
</view> </view>
</template> </template>
<script> <script>
import ClassForm from './form/ClassForm.vue' import ClassForm from './form/ClassForm.vue'
import OrganizationForm from './form/OrganizationForm.vue'
export default { export default {
name: "BusinessDocument", name: "BusinessDocument",
......
<template>
<view>
<uni-forms :modelValue="{}" label-width="120" border label-align="left">
<view v-for="(item, index) in dataList" :key="index" class="show_form">
<view class="show_form_border">
<uni-forms-item :label="item.label" :name="item.key">
<view class="show_form_info">
<view>
{{ item.newData || '-' }}
</view>
<view v-show="item.showFlag" style="color: red;">
{{ item.oldData || '-' }}
</view>
</view>
</uni-forms-item>
<!-- <uni-forms-item :label="' '" :name="item.key" v-if="item.showFlag">-->
<!-- <view class="show_form_info" style="color: red;">-->
<!-- {{ item.oldData || '-' }}-->
<!-- </view>-->
<!-- </uni-forms-item>-->
</view>
</view>
</uni-forms>
</view>
</template>
<script>
export default {
name: "OrganizationForm",
props: {
newBusinessDocument: {
type: Object,
default: () => {
return {}
}
},
oldBusinessDocument: {
type: Object,
default: () => {
return {}
}
}
},
data() {
return {
dataList: []
}
},
created() {
this.initData()
},
methods: {
initData() {
const list = [
{
label: '组织名称',
key: 'deptName'
},
{
label: '组织简称',
key: 'deptShortName'
},
{
label: '组织Id',
key: 'businessId'
},
{
label: '上游组织',
key: 'parentId'
},
{
label: '上游组织Id',
key: 'parentId'
},
{
label: '组织层级',
key: 'deptLevelName'
},
{
label: '对应管理层级层级',
key: 'managerLevelName'
},
{
label: '权重',
key: 'weight'
},
{
label: '状态',
key: 'flag'
},
{
label: '备注',
key: 'remarks'
},
]
list.forEach(item => {
this.dataList.push({
showFlag: this.oldBusinessDocument[item.key] !== this.newBusinessDocument[item.key],
label: item.label,
key: item.key,
oldData: this.oldBusinessDocument[item.key],
newData: this.newBusinessDocument[item.key]
})
})
console.log(this.dataList)
},
}
}
</script>
<style scoped lang="scss">
</style>
<template> <template>
<view class="container my-flow-work"> <view class="container my-flow-work">
<uni-nav-bar dark :fixed="true" shadow background-color="#007AFF" status-bar left-icon="left" left-text="返回" :title="basicDataForm.processType" @clickLeft="goBack" /> <uni-nav-bar dark :fixed="true" shadow background-color="#007AFF" status-bar :title="basicDataForm.processType" />
<view style="width:100%;position:fixed;top:60px;"> <view style="width:100%;position:fixed;top:60px;">
<ul> <ul>
<li class="my_approval_li"> <li class="my_approval_li">
...@@ -126,7 +126,11 @@ export default { ...@@ -126,7 +126,11 @@ export default {
{ {
type: '1001', type: '1001',
api: '/wx/aeclassesinfo/flow' api: '/wx/aeclassesinfo/flow'
} },
{
type: '0003',
api: '/organization/wxProcessDept'
},
] ]
} }
}, },
......
<template> <template>
<view class="normal-login-container"> <view class="normal-login-container">
<view class="logo-content align-center justify-center flex"> <view class="logo-content align-center justify-center flex">
<image style="width: 100rpx;height: 100rpx;" :src="globalConfig.appInfo.logo" mode="widthFix">
</image>
<text class="title">移动端登录</text> <text class="title">移动端登录</text>
</view> </view>
<view class="login-form-content"> <view class="login-form-content">
......
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