Exemple #1
0
        public static SqlessConfig GetOwnerAccessConfig(string authUid = null)
        {
            var result = SqlessConfig.GetOwnerConfig(SqlConStr, authUid);

            result.AuthUid = authUid;

            result.OwnerAuths.Add(new SqlessFieldAuth()
            {
                Readable = true,
                Writable = true,
                Table    = Tables.User,
                Field    = "Uid"
            });

            result.OwnerAuths.Add(new SqlessFieldAuth()
            {
                Readable = true,
                Writable = true,
                Table    = Tables.Order,
                Field    = "Uid"
            });

            result.FieldAuths.Add(new SqlessFieldAuth()
            {
                Readable = false,
                Writable = false,
                Table    = Tables.User,
                Field    = "Password"
            });

            result.FreeAuths.Add(new SqlessAuth()
            {
                Readable = true,
                Writable = false,
                Table    = Tables.Product
            });

            return(result);
        }
Exemple #2
0
 public SqlessBaseController(SqlessConfig sqlessConfig)
 {
     SqlessConfig = sqlessConfig;
 }
 public SqlessAccessController(SqlessAccess sqlessAccess, SqlessConfig sqlessConfig)
     : base(sqlessConfig)
 {
     SqlessAccess = sqlessAccess;
 }