protected override void ajax(AutoCSer.Memory.CharStream _js_) { _js_.Write(@"{Items:"); { AutoCSer.Web.SearchServer.SearchItem[] _value1_ = Items; if (_value1_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"["); { int _loopIndex1_ = _loopIndex_; _loopIndex_ = 0; foreach (AutoCSer.Web.SearchServer.SearchItem _value2_ in _value1_) { if (_loopIndex_ == 0) { _js_.Write('"'); _js_.Write("@.AutoCSerWeb.SearchItem,,DataKey[Id,Type]Html[Title,Url]Indexs[[Key,Value]]Remote[ImageUrl]Text"); _js_.Write('"'); } _js_.Write(','); _js_.Write(@"["); { AutoCSer.Web.SearchServer.DataKey _value3_ = _value2_.DataKey; _js_.Write(@"["); { int _value4_ = _value3_.Id; _js_.WriteWebViewJson((int)_value4_); } _js_.Write(@","); { AutoCSer.Web.SearchServer.DataType _value4_ = _value3_.Type; _js_.WriteQuote(_value4_.ToString()); } _js_.Write(@"]"); } _js_.Write(@","); { AutoCSer.Web.SearchServer.Html _value3_ = _value2_.Html; if (_value3_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"["); { string _value4_ = _value3_.Title; if (_value4_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value4_); } } _js_.Write(@","); { string _value4_ = _value3_.Url; if (_value4_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value4_); } } _js_.Write(@"]"); } } _js_.Write(@","); { AutoCSer.KeyValue <int, int>[] _value3_ = _value2_.Indexs; if (_value3_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"[["); { int _loopIndex3_ = _loopIndex_; _loopIndex_ = 0; foreach (AutoCSer.KeyValue <int, int> _value4_ in _value3_) { if (_loopIndex_ != 0) { _js_.Write(','); } _js_.Write('['); _js_.Write(@""); { int _value5_ = _value4_.Key; _js_.WriteWebViewJson((int)_value5_); } _js_.Write(@","); { int _value5_ = _value4_.Value; _js_.WriteWebViewJson((int)_value5_); } _js_.Write(@"]"); ++_loopIndex_; } _loopIndex_ = _loopIndex3_; } _js_.Write(@"]]"); } } _js_.Write(@","); { AutoCSer.Web.SearchServer.SearchItem.RemoteExtension _value3_ = _value2_.Remote; _js_.Write(@"["); { string _value4_ = _value3_.ImageUrl; if (_value4_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value4_); } } _js_.Write(@"]"); } _js_.Write(@","); { AutoCSer.SubString _value3_ = _value2_.Text; _js_.WriteWebViewJson(_value3_); } _js_.Write(@"]"); ++_loopIndex_; } _loopIndex_ = _loopIndex1_; } _js_.Write(@"].FormatView()"); } } _js_.Write(@",Key:"); { string _value1_ = Key; if (_value1_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value1_); } } _js_.Write(@"}"); }
protected override void ajax(AutoCSer.Memory.CharStream _js_) { _js_.Write(@"{Classes:"); { AutoCSer.TestCase.SqlTableCacheServer.Class[] _value1_ = Classes; if (_value1_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"["); { int _loopIndex1_ = _loopIndex_; _loopIndex_ = 0; foreach (AutoCSer.TestCase.SqlTableCacheServer.Class _value2_ in _value1_) { if (_loopIndex_ == 0) { _js_.Write('"'); _js_.Write("@.Demo.Class,,DateRange[Start[DateTime,Value]]Discipline,Id,Name,Remote[StudentCount,Students[[@.Demo.Student,,Id,Name]]]"); _js_.Write('"'); } _js_.Write(','); if (_value2_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"["); { AutoCSer.TestCase.SqlModel.Member.DateRange _value3_ = _value2_.DateRange; _js_.Write(@"["); { AutoCSer.Sql.Member.IntDate _value4_ = _value3_.Start; _js_.Write(@"["); { System.DateTime _value5_ = _value4_.DateTime; _js_.WriteWebViewJson((System.DateTime)_value5_); } _js_.Write(@","); { int _value5_ = _value4_.Value; _js_.WriteWebViewJson((int)_value5_); } _js_.Write(@"]"); } _js_.Write(@"]"); } _js_.Write(@","); { AutoCSer.TestCase.SqlModel.Member.Discipline _value3_ = _value2_.Discipline; _js_.WriteQuote(_value3_.ToString()); } _js_.Write(@","); { int _value3_ = _value2_.Id; _js_.WriteWebViewJson((int)_value3_); } _js_.Write(@","); { string _value3_ = _value2_.Name; if (_value3_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value3_); } } _js_.Write(@","); { AutoCSer.TestCase.SqlTableCacheServer.Class.RemoteExtension _value3_ = _value2_.Remote; _js_.Write(@"["); { int _value4_ = _value3_.StudentCount; _js_.WriteWebViewJson((int)_value4_); } _js_.Write(@","); { AutoCSer.TestCase.SqlTableCacheServer.Student[] _value4_ = _value3_.Students; if (_value4_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"[["); { int _loopIndex4_ = _loopIndex_; _loopIndex_ = 0; foreach (AutoCSer.TestCase.SqlTableCacheServer.Student _value5_ in _value4_) { if (_loopIndex_ != 0) { _js_.Write(','); } if (_value5_ == null) { _js_.WriteJsonNull(); } else { _js_.Write('['); _js_.Write(@""); { int _value6_ = _value5_.Id; _js_.WriteWebViewJson((int)_value6_); } _js_.Write(@","); { string _value6_ = _value5_.Name; if (_value6_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value6_); } } _js_.Write(@"]"); } ++_loopIndex_; } _loopIndex_ = _loopIndex4_; } _js_.Write(@"]]"); } } _js_.Write(@"]"); } _js_.Write(@"]"); } ++_loopIndex_; } _loopIndex_ = _loopIndex1_; } _js_.Write(@"].FormatView()"); } } _js_.Write(@",IsClassList:"); { bool _value1_ = IsClassList; _js_.WriteWebViewJson((bool)_value1_); } _js_.Write(@",PubPath:"); { AutoCSer.TestCase.SqlModel.WebPath.Pub _value1_ = PubPath; _js_.Write(@"new AutoCSerPath.Pub({})"); } _js_.Write(@"}"); }
protected override void ajax(AutoCSer.Memory.CharStream _js_) { _js_.Write(@"{PubPath:"); { AutoCSer.TestCase.SqlModel.WebPath.Pub _value1_ = PubPath; _js_.Write(@"new AutoCSerPath.Pub({})"); } _js_.Write(@",StudentInfo:"); { AutoCSer.TestCase.SqlTableCacheServer.Student _value1_ = StudentInfo; if (_value1_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"Demo.Student.Get({Birthday:"); { AutoCSer.Sql.Member.IntDate _value2_ = _value1_.Birthday; _js_.Write(@"{DateTime:"); { System.DateTime _value3_ = _value2_.DateTime; _js_.WriteWebViewJson((System.DateTime)_value3_); } _js_.Write(@",Value:"); { int _value3_ = _value2_.Value; _js_.WriteWebViewJson((int)_value3_); } _js_.Write(@"}"); } _js_.Write(@",Email:"); { string _value2_ = _value1_.Email; if (_value2_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value2_); } } _js_.Write(@",Gender:"); { AutoCSer.TestCase.SqlModel.Member.Gender _value2_ = _value1_.Gender; _js_.WriteQuote(_value2_.ToString()); } _js_.Write(@",Id:"); { int _value2_ = _value1_.Id; _js_.WriteWebViewJson((int)_value2_); } _js_.Write(@",Name:"); { string _value2_ = _value1_.Name; if (_value2_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value2_); } } _js_.Write(@",Remote:"); { AutoCSer.TestCase.SqlTableCacheServer.Student.RemoteExtension _value2_ = _value1_.Remote; _js_.Write(@"{Classes:"); { AutoCSer.TestCase.SqlTableCacheServer.Student.RemoteExtension.JoinClassDate[] _value3_ = _value2_.Classes; if (_value3_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"["); { int _loopIndex3_ = _loopIndex_; _loopIndex_ = 0; foreach (AutoCSer.TestCase.SqlTableCacheServer.Student.RemoteExtension.JoinClassDate _value4_ in _value3_) { if (_loopIndex_ == 0) { _js_.Write('"'); _js_.Write("Class[@.Demo.Class,,Discipline,Id,Name]ClassDate[Date[DateTime,Value]]"); _js_.Write('"'); } _js_.Write(','); _js_.Write(@"["); { AutoCSer.TestCase.SqlTableCacheServer.Class _value5_ = _value4_.Class; if (_value5_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"["); { AutoCSer.TestCase.SqlModel.Member.Discipline _value6_ = _value5_.Discipline; _js_.WriteQuote(_value6_.ToString()); } _js_.Write(@","); { int _value6_ = _value5_.Id; _js_.WriteWebViewJson((int)_value6_); } _js_.Write(@","); { string _value6_ = _value5_.Name; if (_value6_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value6_); } } _js_.Write(@"]"); } } _js_.Write(@","); { AutoCSer.TestCase.SqlModel.Member.ClassDate _value5_ = _value4_.ClassDate; _js_.Write(@"["); { AutoCSer.Sql.Member.IntDate _value6_ = _value5_.Date; _js_.Write(@"["); { System.DateTime _value7_ = _value6_.DateTime; _js_.WriteWebViewJson((System.DateTime)_value7_); } _js_.Write(@","); { int _value7_ = _value6_.Value; _js_.WriteWebViewJson((int)_value7_); } _js_.Write(@"]"); } _js_.Write(@"]"); } _js_.Write(@"]"); ++_loopIndex_; } _loopIndex_ = _loopIndex3_; } _js_.Write(@"].FormatView()"); } } _js_.Write(@"}"); } _js_.Write(@"})"); } } _js_.Write(@"}"); }
protected override void ajax(AutoCSer.Memory.CharStream _js_) { _js_.Write(@"{ClassInfo:"); { AutoCSer.TestCase.SqlTableCacheServer.Class _value1_ = ClassInfo; if (_value1_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"Demo.Class.Get({DateRange:"); { AutoCSer.TestCase.SqlModel.Member.DateRange _value2_ = _value1_.DateRange; _js_.Write(@"{Start:"); { AutoCSer.Sql.Member.IntDate _value3_ = _value2_.Start; _js_.Write(@"{DateTime:"); { System.DateTime _value4_ = _value3_.DateTime; _js_.WriteWebViewJson((System.DateTime)_value4_); } _js_.Write(@",Value:"); { int _value4_ = _value3_.Value; _js_.WriteWebViewJson((int)_value4_); } _js_.Write(@"}"); } _js_.Write(@"}"); } _js_.Write(@",Discipline:"); { AutoCSer.TestCase.SqlModel.Member.Discipline _value2_ = _value1_.Discipline; _js_.WriteQuote(_value2_.ToString()); } _js_.Write(@",Id:"); { int _value2_ = _value1_.Id; _js_.WriteWebViewJson((int)_value2_); } _js_.Write(@",Name:"); { string _value2_ = _value1_.Name; if (_value2_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value2_); } } _js_.Write(@",Remote:"); { AutoCSer.TestCase.SqlTableCacheServer.Class.RemoteExtension _value2_ = _value1_.Remote; _js_.Write(@"{StudentCount:"); { int _value3_ = _value2_.StudentCount; _js_.WriteWebViewJson((int)_value3_); } _js_.Write(@",Students:"); { AutoCSer.TestCase.SqlTableCacheServer.Student[] _value3_ = _value2_.Students; if (_value3_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"["); { int _loopIndex3_ = _loopIndex_; _loopIndex_ = 0; foreach (AutoCSer.TestCase.SqlTableCacheServer.Student _value4_ in _value3_) { if (_loopIndex_ == 0) { _js_.Write('"'); _js_.Write("@.Demo.Student,,Birthday[DateTime,Value]Email,Gender,Id,Name"); _js_.Write('"'); } _js_.Write(','); if (_value4_ == null) { _js_.WriteJsonNull(); } else { _js_.Write(@"["); { AutoCSer.Sql.Member.IntDate _value5_ = _value4_.Birthday; _js_.Write(@"["); { System.DateTime _value6_ = _value5_.DateTime; _js_.WriteWebViewJson((System.DateTime)_value6_); } _js_.Write(@","); { int _value6_ = _value5_.Value; _js_.WriteWebViewJson((int)_value6_); } _js_.Write(@"]"); } _js_.Write(@","); { string _value5_ = _value4_.Email; if (_value5_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value5_); } } _js_.Write(@","); { AutoCSer.TestCase.SqlModel.Member.Gender _value5_ = _value4_.Gender; _js_.WriteQuote(_value5_.ToString()); } _js_.Write(@","); { int _value5_ = _value4_.Id; _js_.WriteWebViewJson((int)_value5_); } _js_.Write(@","); { string _value5_ = _value4_.Name; if (_value5_ == null) { _js_.WriteJsonNull(); } else { _js_.WriteWebViewJson(_value5_); } } _js_.Write(@"]"); } ++_loopIndex_; } _loopIndex_ = _loopIndex3_; } _js_.Write(@"].FormatView()"); } } _js_.Write(@"}"); } _js_.Write(@"})"); } } _js_.Write(@",PubPath:"); { AutoCSer.TestCase.SqlModel.WebPath.Pub _value1_ = PubPath; _js_.Write(@"new AutoCSerPath.Pub({})"); } _js_.Write(@"}"); }