1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
{
    "Version":"6.8.5.0",
    "Title":"8h.图表在分组-数据来自明细",
    "Author":"锐浪报表软件",
    "Description":"将图表定义在分组中,图表数据来自明细记录集:\r\n1、记录范围为当前分组项对应明细记录。\r\n2、图表记录集与明细记录集根据同名字段复制数据。",
    "Font":{
        "Name":"宋体",
        "Size":105000,
        "Weight":400,
        "Charset":134
    },
    "Printer":{
    },
    "DetailGrid":{
        "CenterView":true,
        "ColLine":{
            "Color":"646F71"
        },
        "RowLine":{
            "Color":"646F71"
        },
        "Recordset":{
            "ConnectionString":"Provider=Microsoft.Jet.OLEDB.4.0;\r\nUser ID=Admin;\r\nData Source=..\\Data\\Northwind.mdb",
            "QuerySQL":"select c.Region,c.City,c.CompanyName,t.CategoryName,sum(d.Quantity*d.UnitPrice) as Amount\r\nfrom (Orders m inner join \r\n(OrderDetails d inner join \r\n(Products p inner join Categories t on p.CategoryID=t.CategoryID)\r\non P.ProductID=D.ProductID) on m.OrderId=d.OrderId)\r\nleft join Customers c on c.CustomerID=m.CustomerID\r\nwhere m.OrderDate between #1/1/1997# and #12/31/1997#\r\ngroup by c.Region,c.City,c.CompanyName,t.CategoryName\r\norder by c.Region,c.City,c.CompanyName,t.CategoryName",
            "Field":[
                {
                    "Name":"Region"
                },
                {
                    "Name":"City"
                },
                {
                    "Name":"CompanyName"
                },
                {
                    "Name":"CategoryName"
                },
                {
                    "Name":"Amount",
                    "Type":"Currency"
                }
            ]
        },
        "Column":[
            {
                "Name":"City",
                "Width":1.98438
            },
            {
                "Name":"CompanyName",
                "Width":5.37104
            },
            {
                "Name":"CategoryName",
                "Width":4.60375
            },
            {
                "Name":"Amount",
                "Width":3.81
            }
        ],
        "ColumnContent":{
            "Height":0.582083,
            "ColumnContentCell":[
                {
                    "Column":"City",
                    "DataField":"City"
                },
                {
                    "Column":"CompanyName",
                    "DataField":"CompanyName"
                },
                {
                    "Column":"CategoryName",
                    "DataField":"CategoryName"
                },
                {
                    "Column":"Amount",
                    "TextAlign":"MiddleRight",
                    "DataField":"Amount"
                }
            ]
        },
        "ColumnTitle":{
            "BackColor":"E2EFF1",
            "Height":0.582083,
            "Font":{
                "Name":"宋体",
                "Size":105000,
                "Bold":true,
                "Charset":134
            },
            "RepeatStyle":"OnPage",
            "ColumnTitleCell":[
                {
                    "GroupTitle":false,
                    "Column":"City",
                    "TextAlign":"MiddleCenter",
                    "Text":"城市"
                },
                {
                    "GroupTitle":false,
                    "Column":"CompanyName",
                    "TextAlign":"MiddleCenter",
                    "Text":"客户名称"
                },
                {
                    "GroupTitle":false,
                    "Column":"CategoryName",
                    "TextAlign":"MiddleCenter",
                    "Text":"商品类别"
                },
                {
                    "GroupTitle":false,
                    "Column":"Amount",
                    "TextAlign":"MiddleCenter",
                    "Text":"销售金额"
                }
            ]
        },
        "Group":[
            {
                "Name":"Group1",
                "ByFields":"Region",
                "GroupHeader":{
                    "Height":0,
                    "Font":{
                        "Name":"宋体",
                        "Size":90000,
                        "Bold":true,
                        "Charset":134
                    },
                    "Control":[
                        {
                            "Type":"FieldBox",
                            "Name":"Field2",
                            "Width":5.60917,
                            "Height":0.79375,
                            "DataField":"Region"
                        }
                    ]
                },
                "GroupFooter":{
                    "Height":8.81062,
                    "Font":{
                        "Name":"宋体",
                        "Size":105000,
                        "Bold":true,
                        "Charset":134
                    },
                    "NewPage":"After",
                    "PrintGridBorder":false,
                    "Control":[
                        {
                            "Type":"SummaryBox",
                            "Name":"sumAmt",
                            "AlignColumn":"Amount",
                            "Left":11.9592,
                            "Width":3.78354,
                            "Height":0.79375,
                            "Border":{
                                "Styles":"[DrawRight|DrawBottom]"
                            },
                            "TextAlign":"MiddleRight",
                            "DataField":"Amount",
                            "Format":"#,##0.00"
                        },
                        {
                            "Type":"Chart",
                            "Name":"Chart1",
                            "BackColor":"E1FFFF",
                            "Dock":"Bottom",
                            "Top":1.00542,
                            "Height":7.80521,
                            "Font":{
                                "Name":"宋体",
                                "Size":105000,
                                "Weight":400,
                                "Charset":134
                            },
                            "ValueFont":{
                                "Name":"宋体",
                                "Size":105000,
                                "Weight":400,
                                "Charset":134
                            },
                            "LegendValueVisible":true,
                            "LegendShowSum":true,
                            "LegendAtBottom":true,
                            "SeriesField":"CategoryName",
                            "GroupField":"City",
                            "Recordset":{
                                "Field":[
                                    {
                                        "Name":"City"
                                    },
                                    {
                                        "Name":"CategoryName"
                                    },
                                    {
                                        "Name":"Amount",
                                        "Type":"Currency"
                                    }
                                ]
                            },
                            "XAxis":{
                                "TextFormat":"0.##",
                                "CoordLinePen":{
                                    "Color":"FFC4C4"
                                }
                            },
                            "YAxis":{
                                "TextFormat":"0.##",
                                "CoordLinePen":{
                                    "Color":"FFC4C4"
                                }
                            },
                            "Y2Axis":{
                                "TextFormat":"0.##",
                                "CoordLinePen":{
                                    "Color":"FFC4C4"
                                }
                            },
                            "ChartSeries":[
                                {
                                    "YValueField":"Amount",
                                    "ValueFormat":"#,##0.00",
                                    "TooltipText":"[#ChartVar(SeriesLabel)#]:[#ChartVar(YVal)#]"
                                }
                            ]
                        },
                        {
                            "Type":"MemoBox",
                            "Name":"MemoBox1",
                            "BackColor":"E1FFFF",
                            "AlignColumn":"City",
                            "Width":1.95792,
                            "Height":0.79375,
                            "Border":{
                                "Styles":"[DrawLeft|DrawRight|DrawBottom]"
                            }
                        },
                        {
                            "Type":"MemoBox",
                            "Name":"MemoBox2",
                            "BackColor":"E1FFFF",
                            "AlignColumn":"CompanyName",
                            "Left":1.98438,
                            "Width":5.34458,
                            "Height":0.79375,
                            "Border":{
                                "Styles":"[DrawRight|DrawBottom]"
                            }
                        },
                        {
                            "Type":"MemoBox",
                            "Name":"MemoBox3",
                            "BackColor":"E1FFFF",
                            "AlignColumn":"CategoryName",
                            "Left":7.35542,
                            "Width":4.57729,
                            "Height":0.79375,
                            "Border":{
                                "Styles":"[DrawRight|DrawBottom]"
                            },
                            "TextAlign":"MiddleRight",
                            "Text":"[#Region#]小计:"
                        }
                    ]
                }
            }
        ]
    },
    "ReportHeader":[
        {
            "Height":1.37583,
            "Control":[
                {
                    "Type":"StaticBox",
                    "Name":"TitleBox",
                    "Center":"Horizontal",
                    "Left":1.45521,
                    "Top":0.396875,
                    "Width":13.0969,
                    "Height":0.582083,
                    "Font":{
                        "Name":"宋体",
                        "Size":150000,
                        "Bold":true,
                        "Charset":134
                    },
                    "TextAlign":"MiddleCenter",
                    "Text":"图表在分组 - 图表数据来自明细网格"
                }
            ]
        }
    ]
}