Beispiel #1
0
        public JsonResult GetInforProps(InforProp parent)
        {
            var conn = new InforConnection(reportServerAddress: _reportserverUrl, tu: _tu, tup: _tup);

            if (AppUserState == null || AppUserState.Connected == false)
            {
                return(null);
            }
            var props = parent == null?conn.GetPropertiesWeb(AppUserState.UserName, AppUserState.Wgs, AppUserState.Ds, InforObjectype.Record, null) : conn.GetPropertiesWeb(AppUserState.UserName, AppUserState.Wgs, AppUserState.Ds, parent.Type, parent);

            return(this.Jsonp(props));
        }
Beispiel #2
0
        public JsonResult GetInforPropsForParentForRecord(long uri, InforProp parent)
        {
            if (AppUserState == null || AppUserState.Connected == false)
            {
                return(null);
            }
            var conn  = new InforConnection(tu: _tu, tup: _tup);
            var rec   = conn.GetRecordWeb(uri, AppUserState.UserName, AppUserState.Wgs, AppUserState.Ds);
            var props = parent == null?conn.GetPropertiesWeb(AppUserState.UserName, AppUserState.Wgs, AppUserState.Ds, InforObjectype.Record, null, rec, true) :
                            conn.GetPropertiesWeb(AppUserState.UserName, AppUserState.Wgs, AppUserState.Ds, parent.Type, parent, rec, true);

            return(this.Jsonp(props));
        }
Beispiel #3
0
        public PartialViewResult InforPropsForPartial(InforProp parent)
        {
            var conn = new InforConnection(reportServerAddress: _reportserverUrl, tu: _tu, tup: _tup);

            if (AppUserState == null || AppUserState.Connected == false)
            {
                return(PartialView("Properties", new InforPropsViewModel()));
            }
            var hvm = new InforPropsViewModel {
                Properties = parent == null?conn.GetPropertiesWeb(AppUserState.UserName, AppUserState.Wgs, AppUserState.Ds, InforObjectype.Record, null) : conn.GetPropertiesWeb(AppUserState.UserName, AppUserState.Wgs, AppUserState.Ds, parent.Type, parent)
            };

            return(PartialView("Properties", hvm));
        }
Beispiel #4
0
        public PartialViewResult InforPropsForRecordForPartial(long uri, InforProp parent)
        {
            var conn = new InforConnection(tu: _tu, tup: _tup);
            var rec  = conn.GetRecordWeb(uri, AppUserState.UserName, AppUserState.Wgs, AppUserState.Ds);

            if (AppUserState == null || AppUserState.Connected == false)
            {
                return(PartialView(@"~/views/Reports/Properties.cshtml", new InforPropsViewModel()));
            }

            var hvm = new InforPropsViewModel {
                Properties = (parent == null ?  conn.GetPropertiesWeb(AppUserState.UserName, AppUserState.Wgs, AppUserState.Ds, InforObjectype.Record, null, rec, true) :
                              conn.GetPropertiesWeb(AppUserState.UserName, AppUserState.Wgs, AppUserState.Ds, parent.Type, parent, rec, true)) as InforProps, IncludeAddButton = true
            };

            return(PartialView(@"~/views/Reports/Properties.cshtml", hvm));
        }