Ejemplo n.º 1
0
        public string XmlOutput()
        {
            SetItem itemSetter = new SetItem();
            XmlSave xmlOutput  = new XmlSave(MagazineList.GetMagazineList(itemSetter));

            return(xmlOutput.SaveInXml());
        }
        /// <summary>
        /// 获取所有杂志内容
        /// </summary>
        /// <returns></returns>
        public IEnumerable <MagazineList> GetAllMagazine()
        {
            IList <MagazineList> allList = new List <MagazineList>();
            int y = DateTime.Now.Year;

            for (int i = y; i > (y - 3); i--)
            {
                MagazineList     ml   = new MagazineList();
                IList <Magazine> list = new List <Magazine>();
                string where = " and ischecked=1 and CONVERT(nvarchar(30),joindate,121) like '%" + i + "%'";
                IList <MagazineInfo> mList = ChuanDong.Control.BLL.Magazine.GetMagazineList(-1, 1, -1, where);
                int count = mList.Count;
                for (int j = 0; j < count; j++)
                {
                    Magazine m = new Magazine();
                    m.mid   = mList[j].ID.ToString();
                    m.name  = mList[j].Title.IndexOf("期") == -1 ? mList[j].Title.Substring(5).Replace("月", "") + "期" : mList[j].Title.Substring(5).Replace("月", "");
                    m.title = i + "年度" + mList[j].Title.Substring(5) + "刊";
                    m.img   = mList[j].FrontCover;
                    list.Add(m);
                }
                ml.Year    = i.ToString();
                ml.MazList = list;
                allList.Add(ml);
            }
            return(allList);
        }
Ejemplo n.º 3
0
        public string Output()
        {
            WinFormOutputAuthoredItem articleOutput = new WinFormOutputAuthoredItem();
            WinFormOutputMagazine     output        = new WinFormOutputMagazine(articleOutput);
            SetItem itemSetter = new SetItem();

            return(output.ListOutput(MagazineList.GetMagazineList(itemSetter).GenerateList()).ToString());
        }
Ejemplo n.º 4
0
    //private IEnumerator Start()
    private void Start()
    {
        main    = this;
        dlcPath = (Application.platform == RuntimePlatform.Android ? Application.persistentDataPath : Application.dataPath) + "/DLC/";
        MagazineList magazineListObj = WSCall.GetMagazineList();

        magazineList = magazineListObj.data;
        Init();
    }