| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109 |
- <template>
- <basic-container>
- <avue-form ref="form" :option="option" v-model="form" @submit="handleSubmit"/>
- </basic-container>
- </template>
- <script>
- import { examineApproveSubmit } from "@/api/examineApprove/interface";
- export default {
- name: "start",
- props:{
- processDefinitionId:{
- type:String
- },
- itemId:{
- type:String
- }
- },
- data(){
- return {
- form: {},
- option: {
- group: [
- {
- labelWidth: 120,
- column: [
- {
- label: '第一级审批人',
- prop: 'checkUser',
- type: 'select',
- dicUrl: `/api/blade-user/user-list`,
- row:true,
- props: {
- label: "account",
- value: "id"
- },
- span: 22,
- rules: [
- {
- required: true,
- message: '请选择第一级审批人',
- trigger: 'blur'
- }
- ]
- },
- {
- label: '第二级审批人',
- prop: 'checkSecondsUser',
- type: 'select',
- row:true,
- dicUrl: `/api/blade-user/user-list`,
- props: {
- label: "account",
- value: "id"
- },
- span: 22,
- rules: [
- {
- required: true,
- message: '请选择第二级审批人',
- trigger: 'blur'
- }
- ]
- },
- {
- label: '备注',
- row:true,
- prop: 'reason',
- type: 'textarea',
- span: 22,
- rules: [
- {
- required: true,
- message: '请输入请假理由',
- trigger: 'blur'
- }
- ]
- },
- ]
- },
- ],
- }
- }
- },
- methods:{
- handleSubmit(){
- this.$refs["form"].validate((valid) => {
- if(valid){
- this.form.processDefinitionId = this.processDefinitionId
- this.form.itemId = this.itemId
- examineApproveSubmit(this.form).then(res =>{
- if(res.data.success){
- this.$message.success("请核成功!")
- this.$emit('dialogClose');
- }
- })
- }
- })
- }
- }
- }
- </script>
- <style scoped>
- .startFrom-input{
- display:flex;
- justify-content:center;
- }
- </style>
|