Пример #1
0
 /// <summary>
 /// 保存字符串到本地文件中
 /// </summary>
 /// <param name="data"></param>
 /// <param name="fileName"></param>
 public void SaveStringToLocalFile(string data, string fileName)
 {
     if (Wapper != null)
     {
         Wapper.SaveStringToLocalFile(data, fileName);
     }
 }
        /// <summary>
        /// 保存智能批改脚本
        /// </summary>
        public void SaveIgcsData()
        {
            _restoreSystem.SaveIgcsData();

#if Local_Mode
#if UNITY_WEBGL
            _webApiService.SaveStringToLocalFile(IgcsXmlGenerator.SavedXml, "IgcsXmlGenerator.Xml");
#elif UNITY_STANDALONE_WIN
            _storgaeDataWrapper.DataToFile(igcsPath, IgcsXmlGenerator.SavedXml);
#endif
#endif

#if Lab_Mode
            //平台模式
            JObject jo = labInterSystem.SetRequestInfo();
            jo.Add("intelligentGuidanceInitScript", IgcsXmlGenerator.SavedXml);
            labInterSystem.LabRequest(LabInterType.uploadIgcs, jo.ToString());
#endif
        }