ludc
2025-01-16 986aa62ed00bee39363bab41b4eeb8259d446efd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
package com.vci.client.portal.test;
 
import org.junit.Assert;
import org.junit.Test;
 
import com.vci.client.portal.utility.UITools;
import com.vci.common.utility.ObjectUtility;
import com.vci.corba.common.VCIError;
import com.vci.corba.portal.data.PLTabPage;
 
public class TestPLTabPage {
    
    //test保存PLTabPage
    @org.junit.Test
    public void testSavePLTabPage(){
        PLTabPage plTabPage = new PLTabPage();
        plTabPage.plOId = ObjectUtility.getNewObjectID36();
        System.out.println(plTabPage.plOId);
        plTabPage.plCode = "StandardManagementTabs";
        plTabPage.plName = "标准管理";
        plTabPage.plIsOpen = 1;
        plTabPage.plLabel = "标准管理";
        plTabPage.plDesc = "标准管理"; 
        plTabPage.plSeq = 1;
        plTabPage.plContextOId = "A4ECC7F9-CC90-CB94-4463-BB139C98A5B6";
        plTabPage.plCreateUser = "developer";
        plTabPage.plModifyUser = "developer";
        plTabPage.plLicensOrs = "";
        plTabPage.plOpenExpression = "";
        
        try {
            boolean flag = UITools.getService().savePLTabPage(plTabPage);
            Assert.assertTrue(flag);
        } catch (VCIError e) {
            e.printStackTrace();
        }
    }
//    
//    // test更新PLTabPage
//    @org.junit.Test
//    public void testUpdatePLTabPage() {
//        PLTabPage plTabPage = new PLTabPage();
//        plTabPage.plOId = "2DC83F3F-2636-9D81-EE80-68FFF5264685";
//        plTabPage.plCode = "update2";
//        plTabPage.plName = "update2";
//        plTabPage.plIsOpen = 2;
//        plTabPage.plLabel = "plLabel";
//        plTabPage.plDesc = "plDesc";
//        plTabPage.plSeq = 2;
//        plTabPage.plPageDefinationOId = "plPageDefinationOId";
//        plTabPage.plCreateUser = "plCreateUser";
//        plTabPage.plModifyUser = "plModifyUser";
//        plTabPage.plLicensOrs = "plLicensOrs";
//        
//        try {
//            boolean flag = Tool.getService().updatePLTabPage(plTabPage);
//            Assert.assertTrue(flag);
//        } catch (PLMError e) {
//            e.printStackTrace();
//        }
//    }
//    
//    // test删除PLTabPage
//    @org.junit.Test
//    public void testDeletePLTabPage() {
//        PLTabPage plTabPage = new PLTabPage();
//        plTabPage.plOId = "963A49D3-D1C5-B8D5-201A-C9C986F85265";
//        try {
//            boolean flag = Tool.getService().deletePLTabPage(plTabPage);
//            Assert.assertTrue(flag);
//        } catch (PLMError e) {
//            e.printStackTrace();
//        }
//    }
//    
//    // test删除PLTabPage
//    @org.junit.Test
//    public void testDeletePLTabPageById() {
//        try {
//            boolean flag = Tool.getService().deletePLTabPageByID("3CD7BF9E-16E0-2CD8-D0F0-DFDA2E1CDFB2");
//            Assert.assertTrue(flag);
//        } catch (PLMError e) {
//            e.printStackTrace();
//        }
//    }
    
    @Test
    public void testGetPLTabPageById() throws VCIError{
        PLTabPage o = UITools.getService().getPLTabPageById("0FEF4812-9FF4-5594-D013-A58E6E088C3F");
        System.out.println();
    }
    
    @Test
    public void testGetPLTabPageByPageDefinationOId() throws VCIError{
        PLTabPage[] o = UITools.getService().getPLTabPagesByPageDefinationOId("plPageDefinationOId");
        System.out.println();
    }
    
    @Test
    public void testGetPLTabPagesByTypeANDCode() throws VCIError{
        PLTabPage[] o = UITools.getService().getPLTabPagesByTypeANDCode("plRelatedType", "plCode");
        System.out.println();
    }
}