1. 優化報名頁面:彈出查詢頁面、顯示剛新增資料
2. 新增報名頁面加上取消鍵 3. 優化登入頁面:按下 enter 自動換格/送出 4. 修復新增報名頁面中,不同 search_dialog 中的 page 參數相互連動之異常 5. 修改報名頁面列印格式 6. 修復報名頁面匯出功能 7. 優化報到功能 8. 報名頁面中,無查詢資料時不可點選匯出/列印按鈕 9. 匯出/列印報名管理報表時,若無資料則顯示提示 10. 修復列印管理報表後父視窗 UI 不能點擊的問題 11. 新增報名管理表單匯出 excel 功能 12. 於新增信眾、新增活動頁面加上取消鍵 13. 優化報名管理匯出功能:若篩選條件包含特定活動,自動於「匯出條件」欄位標註活動名稱 14. 優化報名查詢匯出功能:匯出之文件中加上「匯出條件」欄位 15. 修復信眾資料頁面中,使用「生日」作為篩選基準時,後續執行「列印查詢資料」與「匯出查詢資料」會報錯 16. 修復「列印信眾查詢」功能中,電話搜尋欄位未正確帶入查詢條件之異常 17. 解決中文輸入法輸入電話號碼的跳字問題 18. 新增品項管理介面排序功能
This commit is contained in:
@@ -1,9 +1,15 @@
|
||||
using DocumentFormat.OpenXml.Drawing.Charts;
|
||||
using DocumentFormat.OpenXml.Vml.Office;
|
||||
using Microsoft.Ajax.Utilities;
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using OfficeOpenXml.FormulaParsing.Excel.Functions.Text;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Helpers;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
@@ -182,8 +188,20 @@ public partial class admin_follower_print_ : System.Web.UI.Page
|
||||
|
||||
if (!string.IsNullOrEmpty(_chkHasAct) && Convert.ToBoolean(_chkHasAct))
|
||||
{
|
||||
_query += "活動報名\n";
|
||||
|
||||
if (!string.IsNullOrEmpty(_selectAct))
|
||||
{
|
||||
int selectAct = Convert.ToInt32(_selectAct);
|
||||
if (selectAct > 0)
|
||||
{
|
||||
var actSubject = _db.activities.Where(a => a.num == selectAct).Select(a => a.subject).FirstOrDefault();
|
||||
_query += $"活動報名: {actSubject}\n";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
_query += $"活動報名\n";
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(_chkNoAct) && Convert.ToBoolean(_chkNoAct))
|
||||
{
|
||||
_query += "非活動報名\n";
|
||||
@@ -200,7 +218,7 @@ public partial class admin_follower_print_ : System.Web.UI.Page
|
||||
else
|
||||
{
|
||||
qry = qry.Where(o => o.activity_num.HasValue);
|
||||
|
||||
|
||||
if (!string.IsNullOrEmpty(_selectAct))
|
||||
{
|
||||
int selectAct = Convert.ToInt32(_selectAct);
|
||||
@@ -404,16 +422,56 @@ public partial class admin_follower_print_ : System.Web.UI.Page
|
||||
actitem_numTxt.Text = row.actItem_num.HasValue && row.actItem != null ? row.actItem.subject : "";
|
||||
}
|
||||
|
||||
Literal fNumTxtLit = (Literal)e.Item.FindControl("f_numTxt");
|
||||
if (fNumTxtLit != null)
|
||||
{
|
||||
fNumTxtLit.Text = row.f_num.HasValue && row.follower != null ? row.follower.u_name : "";
|
||||
}
|
||||
//Literal fNumTxtLit = (Literal)e.Item.FindControl("f_numTxt");
|
||||
//if (fNumTxtLit != null)
|
||||
//{
|
||||
// fNumTxtLit.Text = row.f_num.HasValue && row.follower != null ? row.follower.u_name : "";
|
||||
//}
|
||||
|
||||
Literal fromIdTxtLit = (Literal)e.Item.FindControl("from_idTxt");
|
||||
if (fromIdTxtLit != null)
|
||||
string jsonString = row.f_num_tablet?.ToString() ?? "";
|
||||
if (!string.IsNullOrWhiteSpace(jsonString))
|
||||
{
|
||||
fromIdTxtLit.Text = row.from_id.HasValue && row.follower1 != null ? row.follower1.u_name : "";
|
||||
var jo = JObject.Parse(jsonString);
|
||||
List<string> allMidNames = new List<string>();
|
||||
List<string> allLeftNames = new List<string>();
|
||||
|
||||
// 標題
|
||||
var midNames = jo["mid_items"]?
|
||||
.Select(item => (string)item["fam_name"])
|
||||
.ToList();
|
||||
|
||||
if (midNames != null && midNames.Any())
|
||||
{
|
||||
allMidNames.AddRange(midNames);
|
||||
}
|
||||
|
||||
if (allMidNames.Any())
|
||||
{
|
||||
Literal midNameTextLit = (Literal)e.Item.FindControl("mid_nameTxt");
|
||||
if (midNameTextLit != null)
|
||||
{
|
||||
midNameTextLit.Text = string.Join(", ", allMidNames);
|
||||
}
|
||||
}
|
||||
|
||||
// 陽上
|
||||
var leftNames = jo["left_items"]?
|
||||
.Select(item => (string)item["fam_name"])
|
||||
.ToList();
|
||||
|
||||
if (leftNames != null && leftNames.Any())
|
||||
{
|
||||
allLeftNames.AddRange(leftNames);
|
||||
}
|
||||
|
||||
if (allLeftNames.Any())
|
||||
{
|
||||
Literal leftNameTextLit = (Literal)e.Item.FindControl("left_nameTxt");
|
||||
if (leftNameTextLit != null)
|
||||
{
|
||||
leftNameTextLit.Text = string.Join(", ", allLeftNames);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Literal dueDateLit = (Literal)e.Item.FindControl("due_date");
|
||||
@@ -422,21 +480,21 @@ public partial class admin_follower_print_ : System.Web.UI.Page
|
||||
dueDateLit.Text = row.due_date.HasValue ? row.due_date.Value.ToString("yyyy-MM-dd") : "";
|
||||
}
|
||||
|
||||
Literal extendDateLit = (Literal)e.Item.FindControl("extend_date");
|
||||
if (extendDateLit != null)
|
||||
{
|
||||
extendDateLit.Text = row.extend_date.HasValue ? row.extend_date.Value.ToString("yyyy-MM-dd") : "";
|
||||
}
|
||||
//Literal extendDateLit = (Literal)e.Item.FindControl("extend_date");
|
||||
//if (extendDateLit != null)
|
||||
//{
|
||||
// extendDateLit.Text = row.extend_date.HasValue ? row.extend_date.Value.ToString("yyyy-MM-dd") : "";
|
||||
//}
|
||||
|
||||
//劃位狀態
|
||||
int writeBedQty = _bedDt.Where(b => b.bed_order != null && b.bed_order.o_detail_id == row.num && b.checkIn_date.HasValue && b.bed_kind_detail_id.HasValue).Count();
|
||||
int notBedQty = _bedDt.Where(b => b.bed_order != null && b.bed_order.o_detail_id == row.num && (!b.checkIn_date.HasValue || !b.bed_kind_detail_id.HasValue)).Count();
|
||||
|
||||
Literal bedQtyLit = (Literal)e.Item.FindControl("BedQty");
|
||||
if (bedQtyLit != null)
|
||||
{
|
||||
bedQtyLit.Text = (row.actItem != null && row.actItem.category.HasValue && Convert.ToInt32(row.actItem.category.Value) == (int)Model.activity.category.Order) ? (notBedQty + "/" + writeBedQty) : "";
|
||||
}
|
||||
////劃位狀態
|
||||
//int writeBedQty = _bedDt.Where(b => b.bed_order != null && b.bed_order.o_detail_id == row.num && b.checkIn_date.HasValue && b.bed_kind_detail_id.HasValue).Count();
|
||||
//int notBedQty = _bedDt.Where(b => b.bed_order != null && b.bed_order.o_detail_id == row.num && (!b.checkIn_date.HasValue || !b.bed_kind_detail_id.HasValue)).Count();
|
||||
|
||||
//Literal bedQtyLit = (Literal)e.Item.FindControl("BedQty");
|
||||
//if (bedQtyLit != null)
|
||||
//{
|
||||
// bedQtyLit.Text = (row.actItem != null && row.actItem.category.HasValue && Convert.ToInt32(row.actItem.category.Value) == (int)Model.activity.category.Order) ? (notBedQty + "/" + writeBedQty) : "";
|
||||
//}
|
||||
|
||||
Literal keyin1Lit = (Literal)e.Item.FindControl("keyin1");
|
||||
if (keyin1Lit != null)
|
||||
|
||||
Reference in New Issue
Block a user