diff --git a/src/api/workflow/businesstrip/index.ts b/src/api/workflow/businesstrip/index.ts new file mode 100644 index 0000000..840b68e --- /dev/null +++ b/src/api/workflow/businesstrip/index.ts @@ -0,0 +1,63 @@ +import request from '@/utils/request'; +import { AxiosPromise } from 'axios'; +import { BusinessTripVO, BusinessTripQuery, BusinessTripForm } from '@/api/workflow/businessTrip/types'; + +/** + * 查询请假列表 + * @param query + * @returns {*} + */ + +export const listBusinessTrip = (query?: BusinessTripQuery): AxiosPromise => { + return request({ + url: '/workflow/businessTrip/list', + method: 'get', + params: query + }); +}; + +/** + * 查询请假详细 + * @param id + */ +export const getBusinessTrip = (id: string | number): AxiosPromise => { + return request({ + url: '/workflow/businessTrip/' + id, + method: 'get' + }); +}; + +/** + * 新增请假 + * @param data + */ +export const addBusinessTrip = (data: BusinessTripForm): AxiosPromise => { + return request({ + url: '/workflow/businessTrip', + method: 'post', + data: data + }); +}; + +/** + * 修改请假 + * @param data + */ +export const updateBusinessTrip = (data: BusinessTripForm): AxiosPromise => { + return request({ + url: '/workflow/businessTrip', + method: 'put', + data: data + }); +}; + +/** + * 删除请假 + * @param id + */ +export const delBusinessTrip = (id: string | number | Array) => { + return request({ + url: '/workflow/businessTrip/' + id, + method: 'delete' + }); +}; diff --git a/src/api/workflow/businesstrip/types.ts b/src/api/workflow/businesstrip/types.ts new file mode 100644 index 0000000..6f9d573 --- /dev/null +++ b/src/api/workflow/businesstrip/types.ts @@ -0,0 +1,24 @@ +export interface BusinessTripVO { + id: string | number; + leaveType: string; + startDate: string; + endDate: string; + leaveDays: number; + remark: string; + status?: string; +} + +export interface BusinessTripForm extends BaseEntity { + id?: string | number; + leaveType?: string; + startDate?: string; + endDate?: string; + leaveDays?: number; + remark?: string; + status?: string; +} + +export interface BusinessTripQuery extends PageQuery { + startBusinessTripDays?: number; + endBusinessTripDays?: number; +} diff --git a/src/api/workflow/leave/types.ts b/src/api/workflow/leave/types.ts index a44d35d..8c2bb66 100644 --- a/src/api/workflow/leave/types.ts +++ b/src/api/workflow/leave/types.ts @@ -4,6 +4,9 @@ export interface LeaveVO { startDate: string; endDate: string; leaveDays: number; + currentProjects?: string; + attachment?: string; + reason?: string; remark: string; status?: string; } @@ -14,6 +17,9 @@ export interface LeaveForm extends BaseEntity { startDate?: string; endDate?: string; leaveDays?: number; + currentProjects?: string; + attachment?: string; + reason?: string; remark?: string; status?: string; } diff --git a/src/views/workflow/businesstrip/index.vue b/src/views/workflow/businesstrip/index.vue new file mode 100644 index 0000000..b9dcd32 --- /dev/null +++ b/src/views/workflow/businesstrip/index.vue @@ -0,0 +1,236 @@ + + + diff --git a/src/views/workflow/businesstrip/tripEdit.vue b/src/views/workflow/businesstrip/tripEdit.vue new file mode 100644 index 0000000..0a0660a --- /dev/null +++ b/src/views/workflow/businesstrip/tripEdit.vue @@ -0,0 +1,312 @@ + + + diff --git a/src/views/workflow/leave copy/index.vue b/src/views/workflow/leave copy/index.vue new file mode 100644 index 0000000..2c8da0e --- /dev/null +++ b/src/views/workflow/leave copy/index.vue @@ -0,0 +1,236 @@ + + + diff --git a/src/views/workflow/leave copy/leaveEdit.vue b/src/views/workflow/leave copy/leaveEdit.vue new file mode 100644 index 0000000..78d5079 --- /dev/null +++ b/src/views/workflow/leave copy/leaveEdit.vue @@ -0,0 +1,312 @@ + + + diff --git a/src/views/workflow/leave/index.vue b/src/views/workflow/leave/index.vue index 2c8da0e..02bdd15 100644 --- a/src/views/workflow/leave/index.vue +++ b/src/views/workflow/leave/index.vue @@ -34,10 +34,10 @@ - + + + - + + + +