소스 검색

提交改写后的代码

main
hulei 1 개월 전
부모
커밋
b426467351

+ 3
- 0
ant-design-pro-vue3/src/views/front/develop/Communication/Message.ts 파일 보기

@@ -615,6 +615,9 @@ export default class Message {
615 615
     get Fd116_1(): string { return this.getFdVaule('0100').toString() }
616 616
     set Fd116_1(value: string) { this.setFdValue('0100', value) }
617 617
 
618
+    get Fd100_1(): string { return this.getFdVaule('0100').toString() }
619
+    set Fd100_1(value: string) { this.setFdValue('0100', value) }
620
+
618 621
 
619 622
     /**
620 623
   * 通讯外端

+ 9
- 0
ant-design-pro-vue3/src/views/front/develop/Constract/ContractBase/PageBase.ts 파일 보기

@@ -22,6 +22,15 @@ import TradeModel from '@/views/front/platfrom/common/BasicFunctions/PageFunctio
22 22
  * 注意:该对象需要支持序列化/反序列化
23 23
  */
24 24
 export abstract class PageBase implements TradePage, ITradeHelper {
25
+    GetTradeInfoData(): unknown {
26
+        throw new Error('Method not implemented.')
27
+    }
28
+    dispose(): void {
29
+        throw new Error('Method not implemented.')
30
+    }
31
+    [Symbol.dispose](): void {
32
+        throw new Error('Method not implemented.')
33
+    }
25 34
     get TradeModel(): TradeModel {
26 35
         throw new Error('Method not implemented.')
27 36
     }

+ 471
- 451
ant-design-pro-vue3/src/views/front/develop/Constract/ContractBase/TradeAPIsHelper.ts
파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
파일 보기


+ 7
- 12
ant-design-pro-vue3/src/views/front/develop/Constract/ContractBase/TradeBusHelper.ts 파일 보기

@@ -1,16 +1,11 @@
1 1
 // 假设 PageBase 和 TradeBusData 类型在其他文件中定义,这里先做类型声明
2
-type PageBase = any;
3
-type TradeBusData = {
4
-    [key: string]: string;
5
-};
6 2
 
7
-// 假设 TradeInfoData 类在其他文件中定义,这里先做类型声明
8
-class TradeInfoData {
9
-    static getTradeInfo(page: PageBase): { TradeBus: TradeBusData } {
10
-        // 这里只是占位实现,实际需要根据业务逻辑完善
11
-        return { TradeBus: {} };
12
-    }
13
-}
3
+import { TradeBusData } from "../../Library.Ext/TradeExtension/TradeInfo/TradeBusData";
4
+import { TradeInfoData } from "../../Library.Ext/TradeExtension/TradeInfo/TradeInfoData";
5
+
6
+import { PageBase } from "./PageBase";
7
+
8
+
14 9
 
15 10
 /**
16 11
  * 业务总线的访问辅助类
@@ -24,7 +19,7 @@ export class TradeBusHelper {
24 19
     }
25 20
     // 构造函数
26 21
     constructor(private page: PageBase) {
27
-        this._tradeBusData = TradeInfoData.getTradeInfo(page).TradeBus;
22
+        // this._tradeBusData = TradeInfoData.GetTradeInfo(page).TradeBus;
28 23
     }
29 24
 
30 25
     // 页面属性

+ 69
- 3
ant-design-pro-vue3/src/views/front/develop/Library.Ext/Function/SystemFunction.ts 파일 보기

@@ -6,6 +6,8 @@ import { TransitType } from "@/views/front/develop/Communication/MessageHelper/T
6 6
 import { MainPageManager } from "@/views/front/develop/Library.Ext/TradeInterface/MainPage/MainPageManager";
7 7
 import TransitErrorCodeMap from "../../Communication/MessageHelper/TransitErrorCodeMap";
8 8
 import { PageBase } from "../../Constract/ContractBase/PageBase";
9
+import { message } from "ant-design-vue";
10
+import Result from "../Variables/Result";
9 11
 // interface IPage {
10 12
 //     // 这里需要根据实际情况补充IPage接口的属性和方法
11 13
 //     OwnerContainer: any;
@@ -103,12 +105,76 @@ const LoginAuthentication = {
103 105
 };
104 106
 
105 107
 export default class SystemFunction {
108
+    static Getfiletxt(fileName: string): string {
109
+        throw new Error("Method not implemented.");
110
+    }
111
+    static Savefiletxt(fileName: string, fileContent: string, append: boolean): boolean {
112
+        throw new Error("Method not implemented.");
113
+    }
114
+    static AnalyseExcelData(RowCount: number, columnCount: number) {
115
+        throw new Error("Method not implemented.");
116
+    }
117
+    static AnalyzeTxtData(txt_RowSplit: string[], txt_ColumnSlit: string, txt_EnCode: string, isColumnHeader: boolean) {
118
+        throw new Error("Method not implemented.");
119
+    }
120
+    static SetSel(fileData: string, formatString: string): boolean {
121
+        throw new Error("Method not implemented.");
122
+    }
123
+    static ChangeToCNY(Page: PageBase, num: number): string {
124
+        throw new Error("Method not implemented.");
125
+    }
126
+    static Space(Page: PageBase, lenght: number, c: string): string {
127
+        throw new Error("Method not implemented.");
128
+    }
129
+    static PadRight(Page: PageBase, sourcedata: string, length: number, varChar: string): string {
130
+        throw new Error("Method not implemented.");
131
+    }
132
+    static PadLeft(Page: PageBase, sourcedata: string, length: number, varChar: string): string {
133
+        throw new Error("Method not implemented.");
134
+    }
135
+    static Delspace(Page: PageBase, sourceData: string): string {
136
+        throw new Error("Method not implemented.");
137
+    }
138
+    static RTrim(Page: PageBase, sourceData: string): string {
139
+        throw new Error("Method not implemented.");
140
+    }
141
+    static Val(Page: PageBase, sourceData: string, weight: number): number {
142
+        throw new Error("Method not implemented.");
143
+    }
144
+    static Comma(Page: PageBase, sourceData: string, length: number): string {
145
+        throw new Error("Method not implemented.");
146
+    }
147
+    static Mod(number1: number, number2: number): number {
148
+        throw new Error("Method not implemented.");
149
+    }
150
+    static Chr(number: number): string {
151
+        throw new Error("Method not implemented.");
152
+    }
153
+    static SubStr(Page: PageBase, sourceData: string, start: number, length: number): string {
154
+        throw new Error("Method not implemented.");
155
+    }
156
+    static CallAgnRun(message: Message): boolean {
157
+        throw new Error("Method not implemented.");
158
+    }
159
+    static CallAgnTips(message: Message): boolean {
160
+        throw new Error("Method not implemented.");
161
+    }
162
+    static CallComboBoxData(message: Message, formatString: string, defalutCombox: string): Result {
163
+        return new Result("0001", "错误发生");
164
+    }
106 165
     static Len(Password: any) {
107 166
         return 6;
108 167
     }
109
-    static GetError(errorCode: string): string {
110
-        return TransitErrorCodeMap.GetInstance().GetErrorMessage(errorCode);
168
+
169
+    static GetError(errorCode: string | Message): string {
170
+        if (typeof (errorCode) == "string") {
171
+            return TransitErrorCodeMap.GetInstance().GetErrorMessage(errorCode);
172
+        } else {
173
+
174
+            return "";//获取message错误信息
175
+        }
111 176
     }
177
+
112 178
     static SubSwipeCardData(dataString: string): string {
113 179
         // todo
114 180
         return dataString;
@@ -301,7 +367,7 @@ export default class SystemFunction {
301 367
     }
302 368
 
303 369
     static CallAgn(message: Message): boolean {
304
-        return this.DoTransit(message, "TransitType.CallAgn");//target: IPage hulei-s改为字符   Ipage 对象 不适用于vue
370
+        return this.DoTransit(message, "TransitType.CallAgn");//target: IPagehulei-s改为字符   Ipage 对象 不适用于vue
305 371
     }
306 372
 
307 373
     // 其他方法...

+ 2
- 6
ant-design-pro-vue3/src/views/front/develop/Library.Ext/TradeExtension/TradeInfo/TradeBusData.ts 파일 보기

@@ -1,8 +1,4 @@
1 1
 // 模拟 ISerializable 接口
2
-interface ISerializable {
3
-    serialize(): string;
4
-    static deserialize(data: string): any;
5
-}
6 2
 
7 3
 class TradeBusData {
8 4
     private tradeBusData: { [key: string]: any } = {};
@@ -83,7 +79,7 @@ class DemoItem implements ISerializable {
83 79
     public A: string = '';
84 80
     public B: string = '';
85 81
 
86
-    constructor() {}
82
+    constructor() { }
87 83
 
88 84
     public serialize(): string {
89 85
         return JSON.stringify({ A: this.A, B: this.B });
@@ -98,4 +94,4 @@ class DemoItem implements ISerializable {
98 94
     }
99 95
 }
100 96
 
101
-export { TradeBusData, DemoItem };
97
+export { TradeBusData, DemoItem };

+ 1563
- 1584
ant-design-pro-vue3/src/views/front/develop/Library.Ext/Variables/Feild8583.ts
파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
파일 보기


+ 11
- 0
ant-design-pro-vue3/src/views/front/develop/Library.Ext/Variables/Result.ts 파일 보기

@@ -0,0 +1,11 @@
1
+export default class Result {
2
+
3
+    /**
4
+  * 返回代码
5
+  * 建议使用 "0000" 表示成功
6
+  */
7
+    constructor(
8
+        public Code: string = "0000",
9
+        public Desc: string = ""
10
+    ) { }
11
+}

+ 3
- 0
ant-design-pro-vue3/src/views/front/develop/ServiceProxy.Ext/ServiceHelper/TradeHandle.ts 파일 보기

@@ -23,6 +23,9 @@ export enum Transit {
23 23
 }
24 24
 
25 25
 export default class TradeHandle {
26
+    static ExcuteShell(cmd: string): boolean {
27
+        throw new Error("Method not implemented.");
28
+    }
26 29
     static WriteImportantLog(arg0: string, SerialNumber: any, arg2: string, arg3: string, arg4: string, arg5: any) {
27 30
         //hulei 需要实现该方法
28 31
     }

+ 20
- 0
ant-design-pro-vue3/src/views/front/develop/demo.ts 파일 보기

@@ -0,0 +1,20 @@
1
+// 重载签名(声明不同的参数和返回类型)
2
+function greet(name: string): string;        // 接收字符串
3
+function greet(age: number): string;        // 接收数字
4
+function greet(isMorning: boolean): string; // 接收布尔值
5
+
6
+// 实现签名(必须兼容所有重载)
7
+function greet(value: string | number | boolean): string {
8
+    if (typeof value === "string") {
9
+        return `Hello, ${value}!`;
10
+    } else if (typeof value === "number") {
11
+        return `You are ${value} years old!`;
12
+    } else {
13
+        return `Good ${value ? "morning" : "day"}!`;
14
+    }
15
+}
16
+
17
+// 调用测试
18
+console.log(greet("Alice"));  // "Hello, Alice!"
19
+console.log(greet(25));       // "You are 25 years old!"
20
+console.log(greet(true));     // "Good morning!"

+ 3
- 0
ant-design-pro-vue3/src/views/front/platfrom/common/RunningParameters/PlatformSettings.ts 파일 보기

@@ -24,6 +24,9 @@ enum ConfigType {
24 24
 
25 25
 
26 26
 export default class PlatformSettings {
27
+    static SystemErrorInfo(arg0: string, arg1: Error) {
28
+        throw new Error("Method not implemented.");
29
+    }
27 30
     private static _encoding: BufferEncoding;
28 31
 
29 32
     /**

+ 63
- 63
ant-design-pro-vue3/src/views/front/platfrom/controls/ControlsHelper/ItemsControlHelper.ts 파일 보기

@@ -16,27 +16,27 @@ class ComboBoxHelper {
16 16
     }
17 17
 }
18 18
 
19
-// 模拟 ItemsControl 类
20
-class ItemsControl {
21
-    items: any[] = [];
22
-    itemsSource: any[] | null = null;
23
-    isLoaded: boolean = false;
24
-    isAutoComplete: boolean = false;
25
-
26
-    constructor() {
27
-        this.items = [];
28
-    }
29
-
30
-    addEventListener(event: string, callback: (event: any) => void) {
31
-        // 模拟实现,实际使用时需根据业务逻辑修改
32
-    }
33
-}
34
-
35
-// 模拟 Selector 类
36
-class Selector extends ItemsControl {
37
-    selectedIndex: number = -1;
38
-    selectedItem: any = null;
39
-}
19
+// 模拟 ItemsControl 类 hulei-/ 模拟类型
20
+// class ItemsControl {
21
+//     items: any[] = [];
22
+//     itemsSource: any[] | null = null;
23
+//     isLoaded: boolean = false;
24
+//     isAutoComplete: boolean = false;
25
+
26
+//     constructor() {
27
+//         this.items = [];
28
+//     }
29
+
30
+//     addEventListener(event: string, callback: (event: any) => void) {
31
+//         // 模拟实现,实际使用时需根据业务逻辑修改
32
+//     }
33
+// }
34
+
35
+// 模拟 Selector 类 hulei-s 模拟加载事件 需要重构
36
+// class Selector extends ItemsControl {
37
+//     selectedIndex: number = -1;
38
+//     selectedItem: any = null;
39
+// }
40 40
 
41 41
 // ItemsControlHelper 类
42 42
 class ItemsControlHelper {
@@ -50,58 +50,58 @@ class ItemsControlHelper {
50 50
         obj[this.ComboBoxHelperPropertyKey] = value;
51 51
     }
52 52
 
53
-    static AddItems(target: ItemsControl, items: any[]) {
53
+    static AddItems(items: any[]) {//target: ItemsControl,hulei-s windows自带框架
54 54
         if (!items) return;
55 55
 
56 56
         for (const item of items) {
57 57
             if (this.isKeyValuePair(item)) {
58
-                target.items.push(item);
58
+                //target.items.push(item);
59 59
             }
60 60
         }
61 61
     }
62 62
 
63
-    static SetItems(target: ItemsControl, items: any[]) {
64
-        if (!items) return;
65
-
66
-        if (ComboBoxHelper.GetIsAutoComplete(target)) {
67
-            const cbx = target as Selector;
68
-            if (!cbx) return;
69
-
70
-            if (cbx.itemsSource) {
71
-                const helper = this.GetComboBoxHelper(cbx);
72
-                if (helper) {
73
-                    helper.RefreshSource(cbx, items);
74
-                }
75
-            } else {
76
-                const helper = new ComboBoxHelper();
77
-                this.SetComboBoxHelper(cbx, helper);
78
-                if (cbx.isLoaded) {
79
-                    helper.RegisteAutoComplete(cbx, items);
80
-                } else {
81
-                    cbx.addEventListener('loaded', () => {
82
-                        helper.RegisteAutoComplete(cbx, items);
83
-                    });
84
-                }
85
-            }
86
-        } else {
87
-            target.items = [];
88
-            this.AddItems(target, items);
89
-            const selector = target as Selector;
90
-            if (selector) {
91
-                selector.selectedIndex = 0;
92
-            }
93
-            // 模拟刷新操作
94
-            target.itemsSource = [...target.items];
95
-        }
63
+    static SetItems(items: any[]) {//target: ItemsControl,hulei-s windows自带框架
64
+        // if (!items) return;
65
+
66
+        // if (ComboBoxHelper.GetIsAutoComplete(target)) {
67
+        //     const cbx = target as Selector;
68
+        //     if (!cbx) return;
69
+
70
+        //     if (cbx.itemsSource) {
71
+        //         const helper = this.GetComboBoxHelper(cbx);
72
+        //         if (helper) {
73
+        //             helper.RefreshSource(cbx, items);
74
+        //         }
75
+        //     } else {
76
+        //         const helper = new ComboBoxHelper();
77
+        //         this.SetComboBoxHelper(cbx, helper);
78
+        //         if (cbx.isLoaded) {
79
+        //             helper.RegisteAutoComplete(cbx, items);
80
+        //         } else {
81
+        //             cbx.addEventListener('loaded', () => {
82
+        //                 helper.RegisteAutoComplete(cbx, items);
83
+        //             });
84
+        //         }
85
+        //     }
86
+        // } else {
87
+        //     target.items = [];
88
+        //     this.AddItems(target, items);
89
+        //     const selector = target as Selector;
90
+        //     if (selector) {
91
+        //         selector.selectedIndex = 0;
92
+        //     }
93
+        //     // 模拟刷新操作
94
+        //     target.itemsSource = [...target.items];
95
+        // }
96 96
     }
97 97
 
98
-    static GetSelectedKey(target: Selector): string {
98
+    static GetSelectedKey(): string {//hulei-s 系统自带target: Selector
99 99
         let result = '';
100
-        if (target.selectedItem) {
101
-            if (this.isKeyValuePair(target.selectedItem)) {
102
-                result = target.selectedItem.key;
103
-            }
104
-        }
100
+        // if (target.selectedItem) {
101
+        //     if (this.isKeyValuePair(target.selectedItem)) {
102
+        //         result = target.selectedItem.key;
103
+        //     }
104
+        // }
105 105
         return result;
106 106
     }
107 107
 
@@ -110,4 +110,4 @@ class ItemsControlHelper {
110 110
     }
111 111
 }
112 112
 
113
-export { ItemsControlHelper, ItemsControl, Selector, ComboBoxHelper };
113
+export { ItemsControlHelper, ComboBoxHelper }; //hulei-s  ItemsControl, Selector,

+ 13
- 12
ant-design-pro-vue3/src/views/front/platfrom/presentation/FocusCheck/Adorner/FocusAdorner.ts 파일 보기

@@ -17,9 +17,9 @@ class UIElement {
17 17
     IsVisible: boolean = true;
18 18
 }
19 19
 
20
-class FrameworkElement extends UIElement {
21
-    RenderSize = { width: 0, height: 0 };
22
-}
20
+// class FrameworkElement extends UIElement {
21
+//     RenderSize = { width: 0, height: 0 };
22
+// } hulei-s windows自带框架
23 23
 
24 24
 class DrawingContext {
25 25
     constructor(private canvasContext: CanvasRenderingContext2D) { }
@@ -56,12 +56,13 @@ class Application {
56 56
 }
57 57
 
58 58
 class Adorner {
59
-    constructor(public AdornedElement: FrameworkElement) { }
59
+    constructor() { }//去掉构造 hulei-/public AdornedElement: FrameworkElement
60 60
     InvalidateVisual() { }
61 61
 }
62 62
 
63 63
 class FocusAdorner extends Adorner {
64 64
     static FocusAdornerPen: Pen;
65
+    AdornedElement: any;
65 66
 
66 67
     // static BorderBrushProperty = DependencyProperty.Register("BorderBrush", Brush, FocusAdorner, new FrameworkPropertyMetadata(new SolidColorBrush()));
67 68
     // static BorderThicknessProperty = DependencyProperty.Register("BorderThickness", Number, FocusAdorner, new FrameworkPropertyMetadata(2));
@@ -74,8 +75,8 @@ class FocusAdorner extends Adorner {
74 75
 
75 76
     private _close: () => void;
76 77
 
77
-    constructor(adornedElement: FrameworkElement, private canvasContext: CanvasRenderingContext2D) {
78
-        super(adornedElement);
78
+    constructor(private canvasContext: CanvasRenderingContext2D) {//adornedElement: FrameworkElement,hulei-/去掉构造
79
+        super();//adornedElement
79 80
         const dpd = {
80 81
             AddValueChanged: (element: UIElement, handler: () => void) => { },
81 82
             RemoveValueChanged: (element: UIElement, handler: () => void) => { }
@@ -83,10 +84,10 @@ class FocusAdorner extends Adorner {
83 84
         const handler = () => {
84 85
             this.InvalidateVisual();
85 86
         };
86
-        dpd.AddValueChanged(adornedElement, handler);
87
-        this._close = () => {
88
-            dpd.RemoveValueChanged(adornedElement, handler);
89
-        };
87
+        // dpd.AddValueChanged(adornedElement, handler);
88
+        // this._close = () => {
89
+        //     dpd.RemoveValueChanged(adornedElement, handler);
90
+        // }; hulei—/不知道这里有没有用暂时注调
90 91
     }
91 92
 
92 93
     static {
@@ -106,9 +107,9 @@ class FocusAdorner extends Adorner {
106 107
     }
107 108
 
108 109
     protected OnRender(drawingContext: DrawingContext) {
109
-        if (!this.AdornedElement || !this.AdornedElement.IsVisible) return;
110
+        // if (!this.AdornedElement || !this.AdornedElement.IsVisible) return;//hulei-/vue上没有这个属性 暂时县先注调
110 111
 
111
-        const adornedElementRect = new Rect(this.AdornedElement.RenderSize);
112
+        const adornedElementRect = new Rect(this.AdornedElement.RenderSize);//hulei
112 113
 
113 114
         drawingContext.DrawLine(FocusAdorner.FocusAdornerPen, new Point(adornedElementRect.TopLeft.x - 3, adornedElementRect.TopLeft.y - 3), new Point(adornedElementRect.TopLeft.x + 5, adornedElementRect.TopLeft.y - 3));
114 115
         drawingContext.DrawLine(FocusAdorner.FocusAdornerPen, new Point(adornedElementRect.TopLeft.x - 3, adornedElementRect.TopLeft.y - 3), new Point(adornedElementRect.TopLeft.x - 3, adornedElementRect.TopLeft.y + 5));

Loading…
취소
저장