@ningboyz/types 1.3.139 → 1.3.141

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@ningboyz/types",
3
3
  "type": "module",
4
- "version": "1.3.139",
4
+ "version": "1.3.141",
5
5
  "private": false,
6
6
  "description": "宁波甬政类型库",
7
7
  "author": "nbyt-syq",
@@ -0,0 +1,41 @@
1
+ import _ from "lodash";
2
+
3
+ export interface IWebSocketResponse {
4
+ entityid: string;
5
+ notified: string;
6
+ shiftpwd: string;
7
+ shiftusr: string;
8
+ username: string;
9
+ fromuuid: string;
10
+ billuuid: string;
11
+ notimemo: string;
12
+ onstatus: boolean;
13
+ path4url: string;
14
+ }
15
+
16
+ export class TWebSocketResponse implements IWebSocketResponse {
17
+ entityid: string = "";
18
+ notified: string = "";
19
+ shiftpwd: string = "";
20
+ shiftusr: string = "";
21
+ username: string = "";
22
+ fromuuid: string = "";
23
+ billuuid: string = "";
24
+ notimemo: string = "";
25
+ onstatus: boolean = false;
26
+ path4url: string = "";
27
+
28
+ static parseJson(data: string) {
29
+ let result = new TWebSocketResponse();
30
+ if (_.isEmpty(data)) {
31
+ return result;
32
+ }
33
+ try {
34
+ const temp = JSON.parse(data) as TWebSocketResponse;
35
+ return _.merge(result, temp);
36
+ } catch (e: any) {
37
+ console.error(e.message);
38
+ }
39
+ return result;
40
+ }
41
+ }
package/src/core/index.ts CHANGED
@@ -21,6 +21,7 @@ import { IUserPartResponse, TUserPartResponse } from "./IUserPartResponse";
21
21
  import { IUserSzdwResponse, TUserSzdwResponse } from "./IUserSzdwResponse";
22
22
  import { ICoreValidResponse, TCoreValidResponse } from "./ICoreValidResponse";
23
23
  import { ISysTravelResponse, TSysTravelResponse, ISysTravelWithParaResponse, TSysTravelWithParaResponse } from "./ISysTravelResponse";
24
+ import { IWebSocketResponse, TWebSocketResponse } from "./IWebSocketResponse"
24
25
 
25
26
  export {
26
27
  type ICoreValidResponse,
@@ -48,6 +49,7 @@ export {
48
49
  type IUserResponse,
49
50
  type IUserSzdwResponse,
50
51
  type IUserPartResponse,
52
+ type IWebSocketResponse,
51
53
 
52
54
  // 类
53
55
  TCoreValidResponse,
@@ -73,5 +75,6 @@ export {
73
75
  TUserLiteResponse,
74
76
  TUserResponse,
75
77
  TUserSzdwResponse,
76
- TUserPartResponse
78
+ TUserPartResponse,
79
+ TWebSocketResponse
77
80
  };
@@ -88,6 +88,8 @@ export interface IHznjXmsyWtdwResponse {
88
88
  batchTxt: string;
89
89
  /**规格型号 */
90
90
  ggxhText: string;
91
+ /**样品来源 */
92
+ fromText: string;
91
93
 
92
94
  /**
93
95
  * 虚拟字段
@@ -149,6 +151,8 @@ export class THznjXmsyWtdwResponse implements IHznjXmsyWtdwResponse {
149
151
  batchTxt: string = "";
150
152
  ggxhText: string = "";
151
153
  baseIndx: number = 0;
154
+ /**样品来源 */
155
+ fromText: string = "";
152
156
 
153
157
  constructor(data: Partial<IHznjXmsyWtdwResponse> = {}) {
154
158
  if (data) {