Exemple #1
0
    static public List <FormScheme> getlstdata(string id, ADODB db)
    {
        List <FormScheme> lst = null;
        DataTable         dt  = db.exec_dataset(FormScheme.getquerysql(id));

        if (dt != null)
        {
            lst = new List <FormScheme>();

            foreach (DataRow row in dt.Rows)
            {
                FormScheme obj = new FormScheme(row, db);
                lst.Add(obj);
            }
        }
        return(lst);
    }
Exemple #2
0
    public Summary(DataRow row, ADODB db)
    {
        tf_moduleName = row.IsNull("tf_moduleName") ? "" : (string)row["tf_moduleName"];
        tf_title      = row.IsNull("tf_title") ? "" : (string)row["tf_title"];


        tf_glyph = row.IsNull("tf_glyph") ? 0 : Convert.ToInt32((string)row["tf_glyph"], 16);

        tf_shortname        = row.IsNull("tf_shortname") ? "" : (string)row["tf_shortname"];
        tf_englishName      = row.IsNull("tf_englishName") ? "" : (string)row["tf_englishName"];
        tf_englishShortName = row.IsNull("tf_englishShortName") ? "" : (string)row["tf_englishShortName"];
        tf_description      = row.IsNull("tf_description") ? "" : (string)row["tf_description"];
        tf_primaryKey       = row.IsNull("tf_primaryKey") ? "" : (string)row["tf_primaryKey"];
        tf_nameFields       = row.IsNull("tf_nameFields") ? "" : (string)row["tf_nameFields"];

        tf_fields      = Fields.getlstdata(tf_moduleName, db);
        tf_gridSchemes = GridScheme.getlstdata(tf_moduleName, db);
        tf_formSchemes = FormScheme.getlstdata(tf_moduleName, db);
    }
Exemple #3
0
 public static FormScheme MapToModel(this FormSchemeAddOrUpdateViewModel model, FormScheme existing)
 {
     return(Mapper.Map(model, existing));
 }
Exemple #4
0
 public static FormSchemeViewModel MapToViewModel(this FormScheme model)
 {
     return(Mapper.Map <FormSchemeViewModel>(model));
 }