|
@@ -2,12 +2,15 @@
|
|
|
using EyeSoft.Extensions;
|
|
|
using OASystem.API.OAMethodLib;
|
|
|
using OASystem.API.OAMethodLib.QiYeWeChatAPI.AppNotice;
|
|
|
+using OASystem.Domain.Dtos.CRM;
|
|
|
using OASystem.Domain.Dtos.Groups;
|
|
|
+using OASystem.Domain.Dtos.PersonnelModule;
|
|
|
using OASystem.Domain.Entities.Groups;
|
|
|
using OASystem.Domain.ViewModels.Groups;
|
|
|
using OASystem.Domain.ViewModels.QiYeWeChat;
|
|
|
using OASystem.Infrastructure.Repositories.Groups;
|
|
|
using Org.BouncyCastle.Utilities.Encoders;
|
|
|
+using System.Data;
|
|
|
using static OASystem.API.OAMethodLib.JWTHelper;
|
|
|
|
|
|
namespace OASystem.API.Controllers
|
|
@@ -2596,24 +2599,16 @@ Inner Join Sys_Department as d With(Nolock) On u.DepId=d.Id Where m.Id={0} ", _m
|
|
|
[ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
|
|
|
public async Task<IActionResult> QueryAskData(QueryAskDataDto dto)
|
|
|
{
|
|
|
- try
|
|
|
- {
|
|
|
- Result groupData = await _askDataRep.QueryAskData(dto);
|
|
|
- if (groupData.Code != 0)
|
|
|
- {
|
|
|
- return Ok(JsonView(false, groupData.Msg));
|
|
|
- }
|
|
|
- return Ok(JsonView(true, groupData.Msg, groupData.Data));
|
|
|
- }
|
|
|
- catch (Exception ex)
|
|
|
+ Result groupData = await _askDataRep.QueryAskData(dto);
|
|
|
+ if (groupData.Code != 0)
|
|
|
{
|
|
|
- return Ok(JsonView(false, "程序错误!"));
|
|
|
- throw;
|
|
|
+ return Ok(JsonView(false, groupData.Msg));
|
|
|
}
|
|
|
+ return Ok(JsonView(true, groupData.Msg, groupData.Data));
|
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
|
- /// 根据Id查询请示数据库单挑数据
|
|
|
+ /// 根据Id查询请示数据库单条数据
|
|
|
/// </summary>
|
|
|
/// <param name="dto"></param>
|
|
|
/// <returns></returns>
|
|
@@ -2621,20 +2616,12 @@ Inner Join Sys_Department as d With(Nolock) On u.DepId=d.Id Where m.Id={0} ", _m
|
|
|
[ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
|
|
|
public async Task<IActionResult> QueryAskDataById(QueryAskDataByIdDto dto)
|
|
|
{
|
|
|
- try
|
|
|
- {
|
|
|
- Res_AskData _AskData = await _sqlSugar.Queryable<Res_AskData>().FirstAsync(a => a.IsDel == 0 && a.Id == dto.id);
|
|
|
- if (_AskData == null)
|
|
|
- {
|
|
|
- return Ok(JsonView(true, "暂无数据!", _AskData));
|
|
|
- }
|
|
|
- return Ok(JsonView(true, "查询成功!", _AskData));
|
|
|
- }
|
|
|
- catch (Exception ex)
|
|
|
+ Res_AskData _AskData = await _sqlSugar.Queryable<Res_AskData>().FirstAsync(a => a.IsDel == 0 && a.Id == dto.id);
|
|
|
+ if (_AskData == null)
|
|
|
{
|
|
|
- return Ok(JsonView(false, "程序错误!"));
|
|
|
- throw;
|
|
|
+ return Ok(JsonView(true, "暂无数据!", _AskData));
|
|
|
}
|
|
|
+ return Ok(JsonView(true, "查询成功!", _AskData));
|
|
|
}
|
|
|
/// <summary>
|
|
|
/// 请示数据库操作(Status:1.新增,2.修改)
|
|
@@ -2645,21 +2632,14 @@ Inner Join Sys_Department as d With(Nolock) On u.DepId=d.Id Where m.Id={0} ", _m
|
|
|
[ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
|
|
|
public async Task<IActionResult> OpAskData(OpAskDataDto dto)
|
|
|
{
|
|
|
- try
|
|
|
- {
|
|
|
- Result groupData = await _askDataRep.OpAskData(dto);
|
|
|
- if (groupData.Code != 0)
|
|
|
- {
|
|
|
- return Ok(JsonView(false, groupData.Msg));
|
|
|
- }
|
|
|
- return Ok(JsonView(true, groupData.Msg, groupData.Data));
|
|
|
- }
|
|
|
- catch (Exception ex)
|
|
|
+ Result groupData = await _askDataRep.OpAskData(dto);
|
|
|
+ if (groupData.Code != 0)
|
|
|
{
|
|
|
- return Ok(JsonView(false, "程序错误!"));
|
|
|
- throw;
|
|
|
+ return Ok(JsonView(false, groupData.Msg));
|
|
|
}
|
|
|
+ return Ok(JsonView(true, groupData.Msg, groupData.Data));
|
|
|
}
|
|
|
+
|
|
|
/// <summary>
|
|
|
/// 删除请示资料信息
|
|
|
/// </summary>
|
|
@@ -2669,22 +2649,426 @@ Inner Join Sys_Department as d With(Nolock) On u.DepId=d.Id Where m.Id={0} ", _m
|
|
|
[ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
|
|
|
public async Task<IActionResult> DelAskData(DelBaseDto dto)
|
|
|
{
|
|
|
+ var res = await _askDataRep.SoftDeleteByIdAsync<Res_AskData>(dto.Id.ToString(), dto.DeleteUserId);
|
|
|
+ if (!res)
|
|
|
+ {
|
|
|
+ return Ok(JsonView(false, "删除失败"));
|
|
|
+ }
|
|
|
+ return Ok(JsonView(true, "删除成功!"));
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ /// 请示资料信息
|
|
|
+ /// 省外办下载
|
|
|
+ /// </summary>
|
|
|
+ /// <param name="dto"></param>
|
|
|
+ /// <returns></returns>
|
|
|
+ [HttpPost]
|
|
|
+ [ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
|
|
|
+ public async Task<IActionResult> AskDataProvinceFile(AskDataProvinceFileDto dto)
|
|
|
+ {
|
|
|
+ if (dto.DataIdItem.Length < 1) return Ok(JsonView(false,$"请传入有效的数据Id集合!"));
|
|
|
+ if (dto.DiId < 1) return Ok(JsonView(false, $"请传入有效的数据DiId参数!"));
|
|
|
+
|
|
|
+ //大写数字序号
|
|
|
+ string[] num = { "一", "二", "三", "四", "五", "六", "七", "八", "九", "十" ,
|
|
|
+ "十一","十二","十三","十四","十五","十六","十七","十八","十九","二十",
|
|
|
+ "二十一","二十二","二十三","二十四","二十五","二十六","二十七","二十八","二十九","三十",
|
|
|
+ "三十一","三十二","三十三","三十四","三十五","三十六","三十七","三十八","三十九","四十"};
|
|
|
+
|
|
|
+ //数据源
|
|
|
+ var idItem = dto.DataIdItem.OrderBy(x => x);
|
|
|
+ var askDatas = await _sqlSugar.Queryable<Res_AskData>().Where(x => x.IsDel == 0 && idItem.Contains(x.Id)).ToListAsync();
|
|
|
+ //团组信息
|
|
|
+ var groupInfo = await _sqlSugar.Queryable<Grp_DelegationInfo>().Where(x => x.IsDel == 0 && x.Id == dto.DiId).FirstAsync();
|
|
|
+
|
|
|
+ //书签名
|
|
|
+ string Area = "",
|
|
|
+ Official = "";
|
|
|
+
|
|
|
+ //表格数据源
|
|
|
+ DataTable dt = new DataTable();
|
|
|
+ dt.Columns.Add("Country", typeof(string));
|
|
|
+ dt.Columns.Add("TalkCase", typeof(string));
|
|
|
+
|
|
|
+ int id = 0;
|
|
|
+ int TalkcaseOrder = 0;
|
|
|
+ int RowOrder = 0;
|
|
|
+ //填充数据
|
|
|
+ for (int i = 0; i < askDatas.Count; i++)
|
|
|
+ {
|
|
|
+ var ad = askDatas[i];
|
|
|
+
|
|
|
+ Area = Area + ad.Country + ad.Area + "、";
|
|
|
+ Official = Official + ad.UnitName + "、";
|
|
|
+
|
|
|
+ //填充表格数据源
|
|
|
+
|
|
|
+ DataRow dr = dt.NewRow();
|
|
|
+ if (i > 0)
|
|
|
+ {
|
|
|
+ var adtemp = askDatas[i - 1];
|
|
|
+
|
|
|
+ if (ad.Country == adtemp.Country)
|
|
|
+ {
|
|
|
+ TalkcaseOrder++;
|
|
|
+ dt.Rows[RowOrder]["TalkCase"] = dt.Rows[RowOrder]["TalkCase"] + "\r\n" + (1 + TalkcaseOrder).ToString() + "、" + ad.TalkCase;
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ RowOrder++;
|
|
|
+ dr = dt.NewRow();
|
|
|
+ dr["Country"] = "(" + num[RowOrder] + ")" + ad.Country;
|
|
|
+ dr["TalkCase"] = "1、" + ad.TalkCase;
|
|
|
+ dt.Rows.Add(dr);
|
|
|
+ TalkcaseOrder = 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ dr["Country"] = "(" + num[i] + ")" + ad.Country;
|
|
|
+ dr["TalkCase"] = "1、" + ad.TalkCase;
|
|
|
+ dt.Rows.Add(dr);
|
|
|
+ }
|
|
|
+ id = ad.Id;
|
|
|
+ }
|
|
|
+
|
|
|
+ //模板路径
|
|
|
+ var tempPath = AppSettingsHelper.Get("WordBasePath") + "Template/省外办出访请示模板.doc";
|
|
|
+ //载入模板
|
|
|
+ Aspose.Words.Document doc = new Aspose.Words.Document(tempPath);
|
|
|
+
|
|
|
+ #region 填充word内容
|
|
|
+
|
|
|
+ #region 填充请示内容
|
|
|
+ //利用DocumentBuilder处理表格或是书签
|
|
|
+ Aspose.Words.DocumentBuilder builder = new DocumentBuilder(doc);
|
|
|
+ string bookmark = "";
|
|
|
try
|
|
|
{
|
|
|
- var res = await _askDataRep.SoftDeleteByIdAsync<Res_AskData>(dto.Id.ToString(), dto.DeleteUserId);
|
|
|
- if (!res)
|
|
|
+ for (int i = 0; i < dt.Rows.Count; i++)
|
|
|
{
|
|
|
- return Ok(JsonView(false, "删除失败"));
|
|
|
+ bookmark = bookmark
|
|
|
+ + dt.Rows[i]["Country"].ToString() + "\r\n"
|
|
|
+ + dt.Rows[i]["TalkCase"].ToString() + "\r\n";
|
|
|
}
|
|
|
- return Ok(JsonView(true, "删除成功!"));
|
|
|
}
|
|
|
- catch (Exception ex)
|
|
|
+ catch
|
|
|
{
|
|
|
- return Ok(JsonView(false, "程序错误!"));
|
|
|
- throw;
|
|
|
}
|
|
|
+
|
|
|
+
|
|
|
+ #endregion
|
|
|
+
|
|
|
+ //#region 填充word模板书签内容
|
|
|
+
|
|
|
+ ////接团客户名单实例
|
|
|
+ //List<DeleClient> clientList = new DeleClientService().GetAll(Convert.ToInt32(ddlTourCode.SelectedValue));
|
|
|
+ ////机票代码实例
|
|
|
+ //DataTable airTable = PublicCode.GetTableByBlackCode(Convert.ToInt32(ddlTourCode.SelectedValue));
|
|
|
+ ////三字码dal
|
|
|
+ //ThreeCodeServices ts = new ThreeCodeServices();
|
|
|
+
|
|
|
+ ////团名
|
|
|
+ //if (doc.Range.Bookmarks["TeamName"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["TeamName"];
|
|
|
+ // mark.Text = groupInfo.TeamName;
|
|
|
+ //}
|
|
|
+
|
|
|
+ ////团长名
|
|
|
+ //if (doc.Range.Bookmarks["ClientName2"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["ClientName2"];
|
|
|
+ // if (clientList == null || clientList.Count == 0)
|
|
|
+ // {
|
|
|
+ // mark.Text = "【本团尚未录入客户名单,请联系主管!】";
|
|
|
+ // }
|
|
|
+ // else
|
|
|
+ // {
|
|
|
+ // mark.Text = clientList[0].Company + clientList[0].Job + clientList[0].LastName + clientList[0].Name;
|
|
|
+ // }
|
|
|
+ //}
|
|
|
+ //if (doc.Range.Bookmarks["ClientName"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["ClientName"];
|
|
|
+ // if (clientList == null || clientList.Count == 0)
|
|
|
+ // {
|
|
|
+ // mark.Text = "【本团尚未录入客户名单,请联系主管!】";
|
|
|
+ // }
|
|
|
+ // else
|
|
|
+ // {
|
|
|
+ // mark.Text = clientList[0].Company + clientList[0].Job + clientList[0].LastName + clientList[0].Name;
|
|
|
+ // }
|
|
|
+ //}
|
|
|
+
|
|
|
+ ////跟团人数
|
|
|
+ //if (doc.Range.Bookmarks["ClientNumber2"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["ClientNumber2"];
|
|
|
+ // mark.Text = di.VisitPNumber.ToString();
|
|
|
+ //}
|
|
|
+ //if (doc.Range.Bookmarks["ClientNumber"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["ClientNumber"];
|
|
|
+ // mark.Text = di.VisitPNumber.ToString();
|
|
|
+ //}
|
|
|
+
|
|
|
+ ////地区
|
|
|
+ //if (doc.Range.Bookmarks["Area"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Area"];
|
|
|
+ // mark.Text = Area.TrimEnd('、');
|
|
|
+ //}
|
|
|
+ //if (doc.Range.Bookmarks["Area2"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Area2"];
|
|
|
+ // mark.Text = Area.TrimEnd('、');
|
|
|
+ //}
|
|
|
+
|
|
|
+ ////出访目的
|
|
|
+ //if (doc.Range.Bookmarks["Destination2"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Destination2"];
|
|
|
+ // mark.Text = di.VisitPurpose;
|
|
|
+ //}
|
|
|
+ //if (doc.Range.Bookmarks["Destination"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Destination"];
|
|
|
+ // mark.Text = di.VisitPurpose;
|
|
|
+ //}
|
|
|
+
|
|
|
+ ////邀请方
|
|
|
+ //if (doc.Range.Bookmarks["Official"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Official"];
|
|
|
+ // mark.Text = Official.TrimEnd('、');
|
|
|
+ //}
|
|
|
+
|
|
|
+ ////出访日期
|
|
|
+ //if (doc.Range.Bookmarks["VisitDate"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["VisitDate"];
|
|
|
+ // mark.Text = mark.Text = di.VisitStartDate.Split('-')[0] + "年"
|
|
|
+ // + di.VisitStartDate.Split('-')[1] + "月"
|
|
|
+ // + di.VisitStartDate.Split('-')[2] + "日"
|
|
|
+ // + "至"
|
|
|
+ // + di.VisitEndDate.Split('-')[1] + "月"
|
|
|
+ // + di.VisitEndDate.Split('-')[2] + "日";
|
|
|
+ //}
|
|
|
+
|
|
|
+ ////请示范例
|
|
|
+ //if (doc.Range.Bookmarks["Temp"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Temp"];
|
|
|
+ // mark.Text = bookmark;
|
|
|
+ //}
|
|
|
+
|
|
|
+ ////出访起止日期
|
|
|
+ //if (doc.Range.Bookmarks["Duration"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Duration"];
|
|
|
+ // mark.Text = di.VisitStartDate.Split('-')[0] + "年"
|
|
|
+ // + di.VisitStartDate.Split('-')[1] + "月"
|
|
|
+ // + di.VisitStartDate.Split('-')[2] + "日"
|
|
|
+ // + "至"
|
|
|
+ // + di.VisitEndDate.Split('-')[1] + "月"
|
|
|
+ // + di.VisitEndDate.Split('-')[2] + "日";
|
|
|
+ //}
|
|
|
+
|
|
|
+ ////出访天数
|
|
|
+ //if (doc.Range.Bookmarks["Durationdays"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Durationdays"];
|
|
|
+ // mark.Text = di.VisitDays.ToString();
|
|
|
+ //}
|
|
|
+ //if (doc.Range.Bookmarks["Durationdays2"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Durationdays2"];
|
|
|
+ // mark.Text = di.VisitDays.ToString();
|
|
|
+ //}
|
|
|
+ //#region 根据黑屏代码获取国家呆的天数;获取路线
|
|
|
+ //string result_CountryAndDay = "", result_Air = "";
|
|
|
+
|
|
|
+ //if (airTable.Rows[airTable.Rows.Count - 1]["Day"].ToString() == "")
|
|
|
+ //{
|
|
|
+ // result_CountryAndDay = airTable.Rows[airTable.Rows.Count - 1]["Fliagtcode"].ToString();
|
|
|
+ // result_Air = result_CountryAndDay;
|
|
|
+ //}
|
|
|
+ //else
|
|
|
+ //{
|
|
|
+ // string place_start, place_end;
|
|
|
+ // DateTime time_start, time_end;
|
|
|
+ // ThreeCode three = null;
|
|
|
+ // for (int i = 0; i < airTable.Rows.Count; i++)
|
|
|
+ // {
|
|
|
+ // //三字码实例
|
|
|
+ // three = ts.getByThree(airTable.Rows[i]["Three"].ToString().Substring(0, 3));
|
|
|
+ // if (three == null)
|
|
|
+ // {
|
|
|
+ // place_start = "【未收录三字码" + airTable.Rows[i]["Three"].ToString().Substring(0, 3) + ",请联系机票同事】";
|
|
|
+ // }
|
|
|
+ // else
|
|
|
+ // {
|
|
|
+ // if (three.Country == "" || string.IsNullOrEmpty(three.Country))
|
|
|
+ // {
|
|
|
+ // place_start = "【本三字码" + airTable.Rows[i]["Three"].ToString().Substring(0, 3) + "未录入国家信息,请联系机票同事】";
|
|
|
+ // }
|
|
|
+ // else
|
|
|
+ // {
|
|
|
+ // place_start = three.City;
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+
|
|
|
+ // three = ts.getByThree(airTable.Rows[i]["Three"].ToString().Substring(3, 3));
|
|
|
+ // if (three == null)
|
|
|
+ // {
|
|
|
+ // place_end = "【未收录" + airTable.Rows[i]["Three"].ToString().Substring(0, 3) + ",请联系机票同事】";
|
|
|
+ // }
|
|
|
+ // else
|
|
|
+ // {
|
|
|
+ // if (three.Country == "" || string.IsNullOrEmpty(three.Country))
|
|
|
+ // {
|
|
|
+ // place_end = "【本三字码" + airTable.Rows[i]["Three"].ToString().Substring(0, 3) + "未录入国家信息,请联系机票同事】";
|
|
|
+ // }
|
|
|
+ // else
|
|
|
+ // {
|
|
|
+ // place_end = three.City;
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+ // result_Air += place_start + "一" + place_end + "一";
|
|
|
+
|
|
|
+
|
|
|
+ // //获取国家和呆的天数
|
|
|
+ // if (i > 0 && i < airTable.Rows.Count - 1)
|
|
|
+ // {
|
|
|
+ // time_start = Convert.ToDateTime(airTable.Rows[i - 1]["Day"]);
|
|
|
+ // time_end = Convert.ToDateTime(airTable.Rows[i]["Day"]);
|
|
|
+ // TimeSpan daycount = time_end.Subtract(time_start);
|
|
|
+ // result_CountryAndDay += place_start + daycount.Days + "天" + ",";
|
|
|
+ // }
|
|
|
+
|
|
|
+
|
|
|
+ // }
|
|
|
+ //}
|
|
|
+ //#endregion
|
|
|
+
|
|
|
+ ////每个国家呆的天数
|
|
|
+ //if (doc.Range.Bookmarks["CountryAndDay"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["CountryAndDay"];
|
|
|
+ // mark.Text = result_CountryAndDay.TrimEnd(',');
|
|
|
+
|
|
|
+ //}
|
|
|
+
|
|
|
+ //#region 出访路线城市字符串去重
|
|
|
+ //result_Air = result_Air.TrimEnd('一');
|
|
|
+ //string[] airTemp = result_Air.Split('一');
|
|
|
+ //airTemp = airTemp.Distinct().ToArray();
|
|
|
+ //result_Air = "";
|
|
|
+ //foreach (string str in airTemp)
|
|
|
+ //{
|
|
|
+ // result_Air += str + "一";
|
|
|
+ //}
|
|
|
+ //result_Air = result_Air + airTemp[0];
|
|
|
+ //#endregion
|
|
|
+
|
|
|
+ ////出访路线
|
|
|
+ //if (doc.Range.Bookmarks["Air"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Air"];
|
|
|
+ // mark.Text = result_Air;
|
|
|
+ //}
|
|
|
+ //#endregion
|
|
|
+
|
|
|
+ //#region 客户名单
|
|
|
+
|
|
|
+ //NodeCollection allTables = doc.GetChildNodes(NodeType.Table, true);
|
|
|
+ //Aspose.Words.Tables.Table tableClient = allTables[0] as Aspose.Words.Tables.Table;
|
|
|
+
|
|
|
+ //if (clientList == null || clientList.Count == 0)
|
|
|
+ //{
|
|
|
+ // builder.MoveToCell(0, 1, 0, 0);
|
|
|
+ // builder.Write("【本团尚未录入客户名单,请联系主管!】");
|
|
|
+ //}
|
|
|
+ //else
|
|
|
+ //{
|
|
|
+ // for (int i = 0; i < clientList.Count(); i++)
|
|
|
+ // {
|
|
|
+ // builder.MoveToCell(0, i + 1, 0, 0);
|
|
|
+ // builder.Write((i + 1).ToString());
|
|
|
+
|
|
|
+ // builder.MoveToCell(0, i + 1, 1, 0);
|
|
|
+ // builder.Write(clientList[i].LastName.ToString() + clientList[i].Name.ToString());
|
|
|
+
|
|
|
+ // builder.MoveToCell(0, i + 1, 2, 0);
|
|
|
+ // builder.Write(clientList[i].Sex.ToString());
|
|
|
+
|
|
|
+ // builder.MoveToCell(0, i + 1, 3, 0);
|
|
|
+ // builder.Write(clientList[i].Birthday.ToString());
|
|
|
+
|
|
|
+ // builder.MoveToCell(0, i + 1, 4, 0);
|
|
|
+ // builder.Write(clientList[i].Company.ToString() + clientList[i].Job.ToString());
|
|
|
+
|
|
|
+ // }
|
|
|
+ //}
|
|
|
+
|
|
|
+ //while (tableClient.Rows.Count > clientList.Count + 1)
|
|
|
+ //{
|
|
|
+ // tableClient.Rows.RemoveAt(clientList.Count + 1);
|
|
|
+ //}
|
|
|
+ //#endregion
|
|
|
+
|
|
|
+ //#region 商邀行程
|
|
|
+ //string content = "", temp1 = "", temp2 = "";
|
|
|
+
|
|
|
+ ////获取数据,放到datatable
|
|
|
+ //List<ApprovalTravel> listapt = new ApprovalTravelService().GetByDiid(di.Id);
|
|
|
+
|
|
|
+ //if (listapt == null || listapt.Count == 0)
|
|
|
+ //{
|
|
|
+ // content = "尚未生成商邀行程";
|
|
|
+ //}
|
|
|
+ //else
|
|
|
+ //{
|
|
|
+ // for (int i = 0; i < listapt.Count; i++)
|
|
|
+ // {
|
|
|
+ // content = content + " " + listapt[i].Date + "\r\n";
|
|
|
+ // temp1 = listapt[i].Time;
|
|
|
+ // temp2 = listapt[i].Detail;
|
|
|
+ // if (temp1 != "")
|
|
|
+ // {
|
|
|
+ // string[] str = temp1.Replace("\r\n", " ").Split(new char[] { ' ' }, StringSplitOptions.RemoveEmptyEntries);
|
|
|
+ // string[] str2 = temp2.Replace("\r\n", " ").Split(new char[] { ' ' }, StringSplitOptions.RemoveEmptyEntries);
|
|
|
+ // for (int j = 0; j < str.Count(); j++)
|
|
|
+ // {
|
|
|
+ // content = content + " " + str[j] + str2[j] + "\r\n";
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+ //}
|
|
|
+
|
|
|
+ //if (doc.Range.Bookmarks["Content"] != null)
|
|
|
+ //{
|
|
|
+ // Bookmark mark = doc.Range.Bookmarks["Content"];
|
|
|
+ // mark.Text = content;
|
|
|
+ //}
|
|
|
+
|
|
|
+ //while (tableClient.Rows.Count > 1 + clientList.Count)
|
|
|
+ //{
|
|
|
+ // tableClient.Rows.RemoveAt(1 + clientList.Count);
|
|
|
+ //}
|
|
|
+ //#endregion
|
|
|
+
|
|
|
+ #endregion
|
|
|
+
|
|
|
+
|
|
|
+ return Ok(JsonView(false));
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
#endregion
|
|
|
|
|
|
#region 机票黑屏代码
|