示例#1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromSasosetupfuncsecset(ref DataRow row, Sasosetupfuncsecset entity)
 {
     row.SetField("functionname", entity.functionname);
     row.SetField("menutitle", entity.menutitle);
     row.SetField("folderfunctionnames", entity.folderfunctionnames);
     row.SetField("folderfunctionnamesfl", entity.folderfunctionnamesfl);
     row.SetField("folderfunctionsecurity", entity.folderfunctionsecurity);
     row.SetField("functionsecurity", entity.functionsecurity);
     row.SetField("functiontype-long", entity.functiontypeLong);
     row.SetField("folderdelimiter", entity.folderdelimiter);
     row.SetField("folderlabels", entity.folderlabels);
     row.SetField("menuset", entity.menuset);
     row.SetField("extrafield", entity.extrafield);
     row.SetField("pvsassmrowid", entity.pvsassmrowid.ToByteArray());
     row.SetField("userfield", entity.userfield);
 }
示例#2
0
        public static Sasosetupfuncsecset BuildSasosetupfuncsecsetFromRow(DataRow row)
        {
            Sasosetupfuncsecset entity = new Sasosetupfuncsecset();

            entity.functionname           = row.IsNull("functionname") ? string.Empty : row.Field <string>("functionname");
            entity.menutitle              = row.IsNull("menutitle") ? string.Empty : row.Field <string>("menutitle");
            entity.folderfunctionnames    = row.IsNull("folderfunctionnames") ? string.Empty : row.Field <string>("folderfunctionnames");
            entity.folderfunctionnamesfl  = row.Field <bool>("folderfunctionnamesfl");
            entity.folderfunctionsecurity = row.IsNull("folderfunctionsecurity") ? string.Empty : row.Field <string>("folderfunctionsecurity");
            entity.functionsecurity       = row.IsNull("functionsecurity") ? 0 : row.Field <int>("functionsecurity");
            entity.functiontypeLong       = row.IsNull("functiontype-long") ? string.Empty : row.Field <string>("functiontype-long");
            entity.folderdelimiter        = row.IsNull("folderdelimiter") ? string.Empty : row.Field <string>("folderdelimiter");
            entity.folderlabels           = row.IsNull("folderlabels") ? string.Empty : row.Field <string>("folderlabels");
            entity.menuset      = row.IsNull("menuset") ? string.Empty : row.Field <string>("menuset");
            entity.extrafield   = row.IsNull("extrafield") ? string.Empty : row.Field <string>("extrafield");
            entity.pvsassmrowid = row.Field <byte[]>("pvsassmrowid").ToStringEncoded();
            entity.userfield    = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }