示例#1
0
        private static void LoadEthicsBusinessOwnership(string csvFile, string outputPath)
        {
            var colNums = new int[] { 7, 9, 11, 13 };
            int count   = 9;

            foreach (int col in colNums)
            {
                EthicsTable table = new EthicsTable(
                    "0" + count.ToString(),
                    "BusinessOwnership",
                    csvFile,
                    outputPath,
                    new List <Column>()
                {
                    new Column(col, "OwnerID", "Business", "Name"),
                    new Column(5, "OwneeID", "Business", "Name"),
                    new Column(col + 1, "OwnershipPercentage")
                },
                    "Name",
                    ImportType.Reload,
                    col == colNums[0]  // If it is the first of these, Delete the records
                    );
                table.Load();
                count++;
            }
        }
示例#2
0
        private static void LoadEthicsBusinessConflicts(string csvFile, string outputPath)
        {
            EthicsTable table = new EthicsTable(
                "07",
                "BusinessConflict",
                csvFile,
                outputPath,
                new List <Column>()
            {
                new Column(4, "ConflictID", "Conflict", "Name"),
                new Column(5, "BusinessID", "Business", "Name"),
            },
                "Name",
                ImportType.Reload,
                true  // Delete
                );

            table.Load();
        }
示例#3
0
        private static void LoadEthicsFamilyMemberBusiness(string csvFile, string outputPath)
        {
            EthicsTable table = new EthicsTable(
                "08",
                "FamilyMemberBusiness",
                csvFile,
                outputPath,
                new List <Column>()
            {
                new Column(6, "FamilyMemberID", "FamilyMember", "Name"),
                new Column(5, "BusinessID", "Business", "Name"),
                new Column(16, "FamilyMemberConflictStatusID", "FamilyMemberConflictStatus", "Name"),
                new Column(3, "Description")
            },
                "Name",
                ImportType.Reload,
                true  // Delete
                );

            table.Load();
        }
示例#4
0
        private static void LoadEthicsConflicts(string csvFile, string outputPath)
        {
            EthicsTable table = new EthicsTable(
                "01",
                "Conflict",
                csvFile,
                outputPath,
                new List <Column>()
            {
                new Column(4, "Name"),
                new Column(-1, "Description"),
                new Column(-1, "Notes"),
                new Column(-1, "ConflictPublicationStatusID", "ConflictPublicationStatus"),     // !
                new Column(-1, "InternalNotes"),
            },
                "Name",
                ImportType.Insert
                );

            table.Load();
        }
示例#5
0
        private static void LoadEthicsBusiness(string csvFile, string outputPath)
        {
            var colNums = new int[] { 5, 7, 9, 11, 13 };
            int count   = 2;

            foreach (int col in colNums)
            {
                EthicsTable table = new EthicsTable(
                    "0" + count.ToString(),
                    "Business",
                    csvFile,
                    outputPath,
                    new List <Column>()
                {
                    new Column(col, "Name"),
                },
                    "Name",
                    ImportType.Reload,
                    col == colNums[0] // Delete before first script
                    );
                table.Load();
                count++;
            }
        }