zhangweicheng 4 лет назад
Родитель
Сommit
a0a46f8c30
3 измененных файлов с 24 добавлено и 1 удалено
  1. 2 1
      types/src/interface/base.ts
  2. 5 0
      types/src/interface/process.ts
  3. 17 0
      types/src/interface/project.ts

+ 2 - 1
types/src/interface/base.ts

@@ -142,7 +142,8 @@ export enum CptModelName {
   options = 'options',
   installationFee = 'installationFee',
   financialProject = 'financialProject',
-  approval = 'approval',
+  approval = 'approval', // 后台设置的流程,相关于模板
+  projectApproval = 'projectApproval', // 上报后项目实际使用的流程
   financialProjectType = 'financialProjectType',
 }
 

+ 5 - 0
types/src/interface/process.ts

@@ -59,3 +59,8 @@ export interface IApproval {
   createdTime: number;
   process: IProcess[];
 }
+
+// 复制到项目里的流程
+export interface IProjectApproval extends IApproval {
+  projectID: string;
+}

+ 17 - 0
types/src/interface/project.ts

@@ -5,6 +5,7 @@ import { ITreeScm, DeleteEnum, INumFileRef, IColumnMeta } from './base';
 import { ICalcOption, ITenderSetting, IDistributeSetting } from './calculation';
 import { ISharePermission } from './share';
 import { IOverHeight, IOverHeightSetting } from './overHeight';
+import { IProcessAccount } from './process';
 
 // 项目类型
 export enum ProjectType {
@@ -266,6 +267,11 @@ export enum ProjectActivity {
   RECOVER = 'recover',
 }
 
+// 对项目的权限
+export enum PermissionType {
+  READONLY = 'readonly',
+  EDIT = 'edit',
+}
 export interface IProject extends ITreeScm {
   type: ProjectType;
   compilationID: string;
@@ -288,6 +294,17 @@ export interface IProject extends ITreeScm {
   deleteDate?: number;
   deleteBy?: string;
   financialProjectID?: string; // 关联财审项目ID(不用财审项目关联此表,因为可能多个项目对应一个财审项目)
+  // 流程信息
+  processInfo?: {
+    currentProcessID: string; // 当前正处于哪个环节的ID
+    processName: string; // 环节名称 冗余数据用于列表显示
+    // 当前所处流程里,哪些账号能编辑,哪些账号能查看或者审批等设置
+    processAccounts?: {
+      ID: string; // 用户ID
+      permission: PermissionType;
+    }[];
+  };
+
   // 只是为了显示,不是自身的正在数据,比如汇总信息等
   external?: {
     showShareMark?: boolean; // 是否显示分享标记