07._yablokov._otchety.ot_prostogo_k_uzhasu

advertisement
«Центр Разработки и Внедрения
Террасофт Поволжье»
Отчеты. От простого к ужасу
Содержание
Piece of Cake
Let’s Rock
Come Get Some
Piece of Cake
S . M . A . R . T.
Piece Of Cake
Раздел «Аналитика»
Графики
Печатные формы MS Word
Графики в разделе «Аналитика»
Перейти в режим настройки (для 5.Х)
Добавить график
Печатные формы MS Word
BPMOnline MS Word Report Designer
Let’s Rock
S . M . A . R . T.
Let’s Rock
Раздел «Итоги»
DevExpress Report
ESQ (EntitySchemaQuery)
Вычисляемые поля
Раздел «Итоги»
Страницы
Графики
DevExpress Report
EntitySchemaQuery
EntitySchemaQuery query = new EntitySchemaQuery(userConnection.EntitySchemaManager, "Contact");
query.AddColumn("Id");
query.AddColumn("Name").OrderByAsc();
query.AddColumn("Country.Name");
query.Filters.Add(query.CreateFilterWithParameters(FilterComparisonType.Equal, “Id”, userGuid));
ds.Tables["Contact"].Load(userConnection, query);
report.DataSource = ds;
DEMO
S . M . A . R . T.
Come Get Some
S . M . A . R . T.
Come Get Some
Виртуальные объекты и View
Custom Query, Select
Связывание объектов
Вложенные отчеты
Виртуальные объекты и представления
CustomQuery
//CustomQuery
string query = string.Format(@”
SELECT
[OwnerId] [ContactId],
COUNT(DISTINCT [Account].[Id])
FROM
[Account]
GROUP BY
[OwnerId]”);
DataTable dt = ds.Tables["VwUsrBonusReportLog"];
dt.Load(userConnection.EnsureDBConnection().ExecuteReader(query));
report.DataSource = ds;
//Select
Select selContacts = (Select)new Select(UserConnection).
Column("SysAdminUnit", "ContactId").
From("SysAdminUnit").Where("SysAdminUnit", "Id").In(new Select(UserConnection).
Column("SysUserInRole", "SysUserId").
From("SysUserInRole").Where("SysUserInRole", "SysRoleId").In(new Select(UserConnection).
Column("SysAdminUnit", "Id").From("SysAdminUnit").Where("SysAdminUnit", "Name").IsLike(new QueryParameter("Менед%"))));
DEMO
S . M . A . R . T.
Связывание объектов
<xs:annotation>
<xs:appinfo>
<msdata:Relationship name="Department_VwUsrBonusReportLog" msdata:parent="Department" msdata:child="VwUsrBonusReportLog"
msdata:parentkey="Id" msdata:childkey="Department.Id" msprop:Generator_UserParentTable="Department"
msprop:Generator_UserChildTable="VwUsrBonusReportLog" msprop:Generator_RelationVarName="relationDepartment_VwUsrBonusReportLog"
msprop:Generator_ChildPropName="GetVwUsrBonusReportLogRows" msprop:Generator_ParentPropName="DepartmentRow"
msprop:Generator_UserRelationName="Department_VwUsrBonusReportLog" />
</xs:appinfo>
</xs:annotation>
DEMO
S . M . A . R . T.
Россия:
443035 Самара,
Московское шоссе 4а
+7 (846) 266-55-69
info@terrasoft..ru
123090, Москва,
Ул. Каланчевская, д. 16
+7 (495) 280-16-80
info@terrasoft.ru
Украина:
03118, Киев, пр-т.
Краснозвездный, 115-А
+38 (044) 363-31-33
info@terrasoft.ua
UK:
PORTLAND HOUSE,
BRESSENDAN PLACE,
LONDON SW1E 5RS
+44 (2) 0338 40040
info@tscrm.com
Alexandria:
901 N Pitt Street, Suite 325 +1 (917) 383-27-70
Alexandria
info@bpmonline.com
Download