Просмотр исходного кода

Merge branch 'master' of http://192.168.1.41:3000/SmartCost/SCCommon

qinlaiqiao 4 лет назад
Родитель
Сommit
5c523f9f03

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

@@ -164,8 +164,8 @@ export enum ActionType {
 export enum ActionName {
   // 项目属性相关
   RESET_COL_METAS = 'resetColMetas', // 重置默认列设置
-
-  // ration相关
+  UPDATE_PROPERTY='updateProperty',  //更新项目属性
+  // ration相关property
   ADD_LIB_RATIONS = 'addLibRations', // 添加标准/补充定额
   ADD_GLJ_RATIONS = 'addGljRations', // 插入工料机类型的定额
   CLEAN_ZMHS = 'cleanZmhs', // 清空子目换算

+ 4 - 0
types/src/interface/message.ts

@@ -3,6 +3,10 @@ export enum SocketEvent {
   JOIN = 'join',
   LEAVE = 'leave',
   NOTIFY = 'notify',
+  // 正在查看项目有用户进入
+  VIEW_PROJECT_ENTER = 'viewProjectEnter',
+  // 正在查看项目有用户离开
+  VIEW_PROJECT_LEAVE = 'viewProjectLeave',
 }
 
 export enum MessageName {

+ 22 - 1
types/src/interface/project.ts

@@ -39,6 +39,7 @@ export interface IDecimal {
 export interface IBillsQuantityDecimal {
   unit: string;
   decimal: number;
+  ID:string;
 }
 
 // 呈现选项
@@ -124,6 +125,12 @@ export interface IInfoItem {
   items?: IInfoItem[];
 }
 
+//基本信息类型
+export interface IBasicInfo extends IInfoItem{
+  ID:string, 
+  parentID:string,
+  seq:number
+}
 // 工程特征指标
 interface IBaseEngineerFeature {
   value: string;
@@ -209,7 +216,7 @@ export interface IProperty {
   tenderSetting?: ITenderSetting; // 调价设置
   overHeight?: IOverHeight[]; // 超高降效数据
   overHeightOption?: OverHeightOption; // 超高降效选项
-  basicInfo?: IInfoItem[]; // 基本信息
+  basicInfo?: IBasicInfo[]; // 基本信息
   feature?: IInfoItem[]; // 工程特征
   progressiveInterval?: IProgressiveInterval[]; // 累进区间
   gljAdjustType?: GLJAdjustType; // 承包人材料调整类型
@@ -347,3 +354,17 @@ export interface IProjectLog {
   // 活动者ID
   activityUserID: string;
 }
+
+// 导入状态
+export enum ImportStatus {
+  IMPORTING = 0,
+  FINISH = 1,
+  FAIL = 3,
+}
+
+// 导入log
+export interface IImportLog {
+  status: ImportStatus;
+  errorMsg: string;
+  stack?: any;
+}

+ 10 - 0
types/src/interface/user.ts

@@ -79,3 +79,13 @@ export interface IUser {
 export interface IRecentUser extends IUser {
   recentDate: number;
 }
+
+// 正在查看项目的用户
+export interface IViewingProjectUser {
+  projectID: string;
+  userID: string;
+  userName: string;
+  mobile: string;
+  enterpriseID: string;
+  enterpriseName: string;
+}

+ 2 - 2
wise-cost-connect/package.json

@@ -18,8 +18,7 @@
     "dist/**/*.d.ts"
   ],
   "dependencies": {
-    "mongoose": "^5.10.9",
-    "@types/mongoose": "^5.3.24"
+    "mongoose": "5.12.13"
   },
   "devDependencies": {
     "@midwayjs/cli": "^1.2.38",
@@ -28,6 +27,7 @@
     "@types/jest": "^26.0.10",
     "@types/node": "14",
     "cross-env": "^6.0.0",
+    "@types/mongoose": "5.11.97",
     "globby": "8.0.2",
     "jest": "^26.4.0",
     "mwts": "^1.0.5",