| 203 | | <CommandText>SELECT R.ReklamaID, R.TYTUÅ, R.[ID REKLAMY], R.SZER, R.WYS, R.KOLOR, R.[NICK NAME], R.MOD_TYP, R.RABAT, R.STRONA AS lokalizacja, |
| 204 | | [UKAÅ»E SIÄ W NR].[Nr Wydania] AS NR, R.[ZATWIERDZONO DO DRUKU], R.GRZBIET, REKLAMA_STRONA.STRONA, A.Symbol AS agencja, |
| 205 | | R.[SYMBOL AKWIZYTORA], R.KROTNOÅÄ, R.NETTO, G.Nazwa AS nazwaGrzbietu, A2.ID_AGENTA, R.[CENA JEDN], R.[RABAT WARTOÅÄ], |
| 206 | | [UKAÅ»E SIÄ W NR].netto AS nettoZEmisji, [UKAÅ»E SIÄ W NR].zafakturowana |
| 207 | | FROM AGENCI AS A2 LEFT OUTER JOIN |
| 208 | | AGENCJE AS A ON A.Id_agencji = A2.ID_AGENCJI INNER JOIN |
| 209 | | REKLAMA AS R ON A2.Symbol = R.[SYMBOL AKWIZYTORA] INNER JOIN |
| 210 | | [UKAÅ»E SIÄ W NR] ON R.ReklamaID = [UKAÅ»E SIÄ W NR].ReklamaId LEFT OUTER JOIN |
| 211 | | REKLAMA_STRONA ON R.ReklamaID = REKLAMA_STRONA.ReklamaId AND |
| 212 | | [UKAÅ»E SIÄ W NR].[Nr Wydania] = REKLAMA_STRONA.NR_WYDANIA LEFT OUTER JOIN |
| 213 | | GRZBIETY AS G ON R.GRZBIET = G.ID |
| 214 | | WHERE (R.[ZATWIERDZONO DO DRUKU] = 1) AND (R.TYTUÅ = @tytul) AND ([UKAÅ»E SIÄ W NR].[Nr Wydania] = @nrwydania) AND (@agencja IS NULL) AND |
| 215 | | (@agent IS NULL) AND (@grzbiet IS NULL) AND ([UKAÅ»E SIÄ W NR].status <> 2) OR |
| 216 | | (R.[ZATWIERDZONO DO DRUKU] = 1) AND (R.TYTUÅ = @tytul) AND ([UKAÅ»E SIÄ W NR].[Nr Wydania] = @nrwydania) AND (@agencja IS NULL) AND |
| 217 | | (@agent IS NULL) AND ([UKAÅ»E SIÄ W NR].status <> 2) AND (R.GRZBIET = @grzbiet) OR |
| 218 | | (R.[ZATWIERDZONO DO DRUKU] = 1) AND (R.TYTUÅ = @tytul) AND ([UKAÅ»E SIÄ W NR].[Nr Wydania] = @nrwydania) AND (@agencja IS NULL) AND |
| 219 | | (@grzbiet IS NULL) AND ([UKAÅ»E SIÄ W NR].status <> 2) AND (A2.ID_AGENTA = @agent) OR |
| 220 | | (R.[ZATWIERDZONO DO DRUKU] = 1) AND (R.TYTUÅ = @tytul) AND ([UKAÅ»E SIÄ W NR].[Nr Wydania] = @nrwydania) AND (@agencja IS NULL) AND |
| 221 | | ([UKAÅ»E SIÄ W NR].status <> 2) AND (R.GRZBIET = @grzbiet) AND (A2.ID_AGENTA = @agent) OR |
| 222 | | (R.[ZATWIERDZONO DO DRUKU] = 1) AND (R.TYTUÅ = @tytul) AND ([UKAÅ»E SIÄ W NR].[Nr Wydania] = @nrwydania) AND (@agent IS NULL) AND |
| 223 | | (@grzbiet IS NULL) AND ([UKAÅ»E SIÄ W NR].status <> 2) AND (A.Id_agencji = @agencja) OR |
| 224 | | (R.[ZATWIERDZONO DO DRUKU] = 1) AND (R.TYTUÅ = @tytul) AND ([UKAÅ»E SIÄ W NR].[Nr Wydania] = @nrwydania) AND (@agent IS NULL) AND |
| 225 | | ([UKAÅ»E SIÄ W NR].status <> 2) AND (R.GRZBIET = @grzbiet) AND (A.Id_agencji = @agencja) OR |
| 226 | | (R.[ZATWIERDZONO DO DRUKU] = 1) AND (R.TYTUÅ = @tytul) AND ([UKAÅ»E SIÄ W NR].[Nr Wydania] = @nrwydania) AND (@grzbiet IS NULL) AND |
| 227 | | ([UKAÅ»E SIÄ W NR].status <> 2) AND (A2.ID_AGENTA = @agent) AND (A.Id_agencji = @agencja) OR |
| 228 | | (R.[ZATWIERDZONO DO DRUKU] = 1) AND (R.TYTUÅ = @tytul) AND ([UKAÅ»E SIÄ W NR].[Nr Wydania] = @nrwydania) AND |
| 229 | | ([UKAÅ»E SIÄ W NR].status <> 2) AND (R.GRZBIET = @grzbiet) AND (A2.ID_AGENTA = @agent) AND (A.Id_agencji = @agencja) |
| 230 | | ORDER BY R.[ID REKLAMY]</CommandText> |
| | 226 | <CommandType>StoredProcedure</CommandType> |
| | 227 | <CommandText>sp_GetListaReklamNaWydanie</CommandText> |
| 334 | | union |
| 335 | | select NULL ,'Wszystkie' |
| 336 | | order by Nazwa</CommandText> |
| | 338 | WHERE Active=1 AND TytulId=@tytul |
| | 339 | UNION |
| | 340 | SELECT NULL ,'Wszystkie' |
| | 341 | ORDER BY Nazwa</CommandText> |
| | 342 | <QueryParameters> |
| | 343 | <QueryParameter Name="@tytul"> |
| | 344 | <Value>=Parameters!tytul.Value</Value> |
| | 345 | </QueryParameter> |
| | 346 | </QueryParameters> |
| | 347 | <rd:UseGenericDesigner>true</rd:UseGenericDesigner> |
| | 348 | </Query> |
| | 349 | </DataSet> |
| | 350 | <DataSet Name="ListaDzialow"> |
| | 351 | <Fields> |
| | 352 | <Field Name="Id"> |
| | 353 | <DataField>Id</DataField> |
| | 354 | <rd:TypeName>System.Int32</rd:TypeName> |
| | 355 | </Field> |
| | 356 | <Field Name="Name"> |
| | 357 | <DataField>Name</DataField> |
| | 358 | <rd:TypeName>System.String</rd:TypeName> |
| | 359 | </Field> |
| | 360 | </Fields> |
| | 361 | <Query> |
| | 362 | <DataSourceName>BAZA_REKLAM</DataSourceName> |
| | 363 | <CommandText>DECLARE @Dzialy Table |
| | 364 | ( |
| | 365 | Id INT, |
| | 366 | Name NVARCHAR(50) |
| | 367 | ) |
| | 368 | |
| | 369 | INSERT INTO @Dzialy |
| | 370 | SELECT Id, Name FROM Dzial WHERE Active=1 AND TitleId=@tytul |
| | 371 | |
| | 372 | IF (SELECT COUNT(Id) FROM @Dzialy)<1 |
| | 373 | INSERT INTO @Dzialy |
| | 374 | SELECT 0, 'Wszystkie dziaÅy' |
| | 375 | |
| | 376 | SELECT * FROM @Dzialy</CommandText> |
| | 377 | <QueryParameters> |
| | 378 | <QueryParameter Name="@tytul"> |
| | 379 | <Value>=Parameters!tytul.Value</Value> |
| | 380 | </QueryParameter> |
| | 381 | </QueryParameters> |
| 556 | | </Textbox> |
| 557 | | </ReportItems> |
| 558 | | </TableCell> |
| 559 | | <TableCell> |
| 560 | | <ReportItems> |
| 561 | | <Textbox Name="KOLOR"> |
| 562 | | <rd:DefaultName>KOLOR</rd:DefaultName> |
| 563 | | <Style> |
| 564 | | <BorderColor> |
| 565 | | <Default>LightGrey</Default> |
| 566 | | </BorderColor> |
| 567 | | <BorderStyle> |
| 568 | | <Default>Solid</Default> |
| 569 | | </BorderStyle> |
| 570 | | <BorderWidth> |
| 571 | | <Default>0.5pt</Default> |
| 572 | | </BorderWidth> |
| 573 | | <FontSize>7pt</FontSize> |
| 574 | | <TextAlign>Center</TextAlign> |
| 575 | | <VerticalAlign>Middle</VerticalAlign> |
| 576 | | <PaddingLeft>2pt</PaddingLeft> |
| 577 | | <PaddingRight>2pt</PaddingRight> |
| 578 | | <PaddingTop>2pt</PaddingTop> |
| 579 | | <PaddingBottom>2pt</PaddingBottom> |
| 580 | | <Language>pl-PL</Language> |
| 581 | | </Style> |
| 582 | | <ZIndex>8</ZIndex> |
| 583 | | <CanGrow>true</CanGrow> |
| 584 | | <Value>=Fields!KOLOR.Value</Value> |
| 731 | | </Textbox> |
| 732 | | </ReportItems> |
| 733 | | </TableCell> |
| 734 | | <TableCell> |
| 735 | | <ReportItems> |
| 736 | | <Textbox Name="textbox18"> |
| 737 | | <rd:DefaultName>textbox18</rd:DefaultName> |
| 738 | | <Style> |
| 739 | | <BorderColor> |
| 740 | | <Default>LightGrey</Default> |
| 741 | | </BorderColor> |
| 742 | | <BorderStyle> |
| 743 | | <Default>Solid</Default> |
| 744 | | </BorderStyle> |
| 745 | | <BorderWidth> |
| 746 | | <Default>0.5pt</Default> |
| 747 | | </BorderWidth> |
| 748 | | <FontSize>7pt</FontSize> |
| 749 | | <FontWeight>700</FontWeight> |
| 750 | | <TextAlign>Center</TextAlign> |
| 751 | | <VerticalAlign>Middle</VerticalAlign> |
| 752 | | <PaddingLeft>2pt</PaddingLeft> |
| 753 | | <PaddingRight>2pt</PaddingRight> |
| 754 | | <PaddingTop>2pt</PaddingTop> |
| 755 | | <PaddingBottom>2pt</PaddingBottom> |
| 756 | | </Style> |
| 757 | | <ZIndex>2</ZIndex> |
| 758 | | <CanGrow>true</CanGrow> |
| 759 | | <Value>=iif(Fields!zafakturowana.Value = true,1,"")</Value> |
| | 950 | </Style> |
| | 951 | <ZIndex>31</ZIndex> |
| | 952 | <CanGrow>true</CanGrow> |
| | 953 | <Value /> |
| | 954 | </Textbox> |
| | 955 | </ReportItems> |
| | 956 | </TableCell> |
| | 957 | <TableCell> |
| | 958 | <ReportItems> |
| | 959 | <Textbox Name="textbox16"> |
| | 960 | <rd:DefaultName>textbox16</rd:DefaultName> |
| | 961 | <Style> |
| | 962 | <BackgroundColor>Gainsboro</BackgroundColor> |
| | 963 | <BorderColor> |
| | 964 | <Default>LightGrey</Default> |
| | 965 | </BorderColor> |
| | 966 | <BorderStyle> |
| | 967 | <Left>None</Left> |
| | 968 | <Right>Solid</Right> |
| | 969 | <Top>Solid</Top> |
| | 970 | <Bottom>Solid</Bottom> |
| | 971 | </BorderStyle> |
| | 972 | <BorderWidth> |
| | 973 | <Default>0.5pt</Default> |
| | 974 | </BorderWidth> |
| | 975 | <FontSize>7pt</FontSize> |
| | 976 | <FontWeight>700</FontWeight> |
| | 977 | <Format>C</Format> |
| | 978 | <TextAlign>Center</TextAlign> |
| | 979 | <VerticalAlign>Middle</VerticalAlign> |
| | 980 | <PaddingLeft>2pt</PaddingLeft> |
| | 981 | <PaddingRight>2pt</PaddingRight> |
| | 982 | <PaddingTop>2pt</PaddingTop> |
| | 983 | <PaddingBottom>2pt</PaddingBottom> |
| | 984 | </Style> |
| | 985 | <ZIndex>30</ZIndex> |
| | 986 | <CanGrow>true</CanGrow> |
| | 987 | <Value /> |
| | 988 | </Textbox> |
| | 989 | </ReportItems> |
| | 990 | </TableCell> |
| | 991 | <TableCell> |
| | 992 | <ReportItems> |
| | 993 | <Textbox Name="textbox15"> |
| | 994 | <rd:DefaultName>textbox15</rd:DefaultName> |
| | 995 | <Style> |
| | 996 | <BackgroundColor>Gainsboro</BackgroundColor> |
| | 997 | <BorderColor> |
| | 998 | <Default>LightGrey</Default> |
| | 999 | </BorderColor> |
| | 1000 | <BorderStyle> |
| | 1001 | <Left>None</Left> |
| | 1002 | <Right>Solid</Right> |
| | 1003 | <Top>Solid</Top> |
| | 1004 | <Bottom>Solid</Bottom> |
| | 1005 | </BorderStyle> |
| | 1006 | <BorderWidth> |
| | 1007 | <Default>0.5pt</Default> |
| | 1008 | </BorderWidth> |
| | 1009 | <FontSize>7pt</FontSize> |
| | 1010 | <FontWeight>700</FontWeight> |
| | 1011 | <Format>C</Format> |
| | 1012 | <TextAlign>Center</TextAlign> |
| | 1013 | <VerticalAlign>Middle</VerticalAlign> |
| | 1014 | <PaddingLeft>2pt</PaddingLeft> |
| | 1015 | <PaddingRight>2pt</PaddingRight> |
| | 1016 | <PaddingTop>2pt</PaddingTop> |
| | 1017 | <PaddingBottom>2pt</PaddingBottom> |
| | 1020 | <ZIndex>29</ZIndex> |
| | 1021 | <CanGrow>true</CanGrow> |
| | 1022 | <Value>=Sum(Fields!nettoZEmisji.Value)</Value> |
| | 1023 | </Textbox> |
| | 1024 | </ReportItems> |
| | 1025 | </TableCell> |
| | 1026 | <TableCell> |
| | 1027 | <ReportItems> |
| | 1028 | <Textbox Name="textbox20"> |
| | 1029 | <rd:DefaultName>textbox20</rd:DefaultName> |
| | 1030 | <Style> |
| | 1031 | <BackgroundColor>Gainsboro</BackgroundColor> |
| | 1032 | <BorderColor> |
| | 1033 | <Default>LightGrey</Default> |
| | 1034 | </BorderColor> |
| | 1035 | <BorderStyle> |
| | 1036 | <Left>None</Left> |
| | 1037 | <Right>Solid</Right> |
| | 1038 | <Top>Solid</Top> |
| | 1039 | <Bottom>Solid</Bottom> |
| | 1040 | </BorderStyle> |
| | 1041 | <BorderWidth> |
| | 1042 | <Default>0.5pt</Default> |
| | 1043 | </BorderWidth> |
| | 1044 | <FontSize>7pt</FontSize> |
| | 1045 | <FontWeight>700</FontWeight> |
| | 1046 | <Format>C</Format> |
| | 1047 | <TextAlign>Center</TextAlign> |
| | 1048 | <VerticalAlign>Middle</VerticalAlign> |
| | 1049 | <PaddingLeft>2pt</PaddingLeft> |
| | 1050 | <PaddingRight>2pt</PaddingRight> |
| | 1051 | <PaddingTop>2pt</PaddingTop> |
| | 1052 | <PaddingBottom>2pt</PaddingBottom> |
| | 1053 | </Style> |
| 941 | | <Value>=Sum(Fields!nettoZEmisji.Value)</Value> |
| | 1056 | <Value /> |
| | 1057 | </Textbox> |
| | 1058 | </ReportItems> |
| | 1059 | </TableCell> |
| | 1060 | <TableCell> |
| | 1061 | <ReportItems> |
| | 1062 | <Textbox Name="textbox23"> |
| | 1063 | <rd:DefaultName>textbox23</rd:DefaultName> |
| | 1064 | <Style> |
| | 1065 | <BackgroundColor>Gainsboro</BackgroundColor> |
| | 1066 | <BorderColor> |
| | 1067 | <Default>LightGrey</Default> |
| | 1068 | </BorderColor> |
| | 1069 | <BorderStyle> |
| | 1070 | <Left>None</Left> |
| | 1071 | <Right>Solid</Right> |
| | 1072 | <Top>Solid</Top> |
| | 1073 | <Bottom>Solid</Bottom> |
| | 1074 | </BorderStyle> |
| | 1075 | <BorderWidth> |
| | 1076 | <Default>0.5pt</Default> |
| | 1077 | </BorderWidth> |
| | 1078 | <FontSize>7pt</FontSize> |
| | 1079 | <FontWeight>700</FontWeight> |
| | 1080 | <Format>C</Format> |
| | 1081 | <TextAlign>Center</TextAlign> |
| | 1082 | <VerticalAlign>Middle</VerticalAlign> |
| | 1083 | <PaddingLeft>2pt</PaddingLeft> |
| | 1084 | <PaddingRight>2pt</PaddingRight> |
| | 1085 | <PaddingTop>2pt</PaddingTop> |
| | 1086 | <PaddingBottom>2pt</PaddingBottom> |
| | 1087 | </Style> |
| | 1088 | <ZIndex>27</ZIndex> |
| | 1089 | <CanGrow>true</CanGrow> |
| | 1090 | <Value /> |
| | 1091 | </Textbox> |
| | 1092 | </ReportItems> |
| | 1093 | </TableCell> |
| | 1094 | <TableCell> |
| | 1095 | <ReportItems> |
| | 1096 | <Textbox Name="textbox24"> |
| | 1097 | <rd:DefaultName>textbox24</rd:DefaultName> |
| | 1098 | <Style> |
| | 1099 | <BackgroundColor>Gainsboro</BackgroundColor> |
| | 1100 | <BorderColor> |
| | 1101 | <Default>LightGrey</Default> |
| | 1102 | </BorderColor> |
| | 1103 | <BorderStyle> |
| | 1104 | <Left>None</Left> |
| | 1105 | <Right>Solid</Right> |
| | 1106 | <Top>Solid</Top> |
| | 1107 | <Bottom>Solid</Bottom> |
| | 1108 | </BorderStyle> |
| | 1109 | <BorderWidth> |
| | 1110 | <Default>0.5pt</Default> |
| | 1111 | </BorderWidth> |
| | 1112 | <FontSize>7pt</FontSize> |
| | 1113 | <FontWeight>700</FontWeight> |
| | 1114 | <Format>C</Format> |
| | 1115 | <TextAlign>Center</TextAlign> |
| | 1116 | <VerticalAlign>Middle</VerticalAlign> |
| | 1117 | <PaddingLeft>2pt</PaddingLeft> |
| | 1118 | <PaddingRight>2pt</PaddingRight> |
| | 1119 | <PaddingTop>2pt</PaddingTop> |
| | 1120 | <PaddingBottom>2pt</PaddingBottom> |
| | 1121 | </Style> |
| | 1122 | <ZIndex>26</ZIndex> |
| | 1123 | <CanGrow>true</CanGrow> |
| | 1124 | <Value /> |
| 1102 | | </Textbox> |
| 1103 | | </ReportItems> |
| 1104 | | </TableCell> |
| 1105 | | <TableCell> |
| 1106 | | <ReportItems> |
| 1107 | | <Textbox Name="textbox16"> |
| 1108 | | <rd:DefaultName>textbox16</rd:DefaultName> |
| 1109 | | <Style> |
| 1110 | | <BackgroundColor>WhiteSmoke</BackgroundColor> |
| 1111 | | <BorderColor> |
| 1112 | | <Default>LightGrey</Default> |
| 1113 | | </BorderColor> |
| 1114 | | <BorderStyle> |
| 1115 | | <Default>Solid</Default> |
| 1116 | | </BorderStyle> |
| 1117 | | <BorderWidth> |
| 1118 | | <Default>0.5pt</Default> |
| 1119 | | </BorderWidth> |
| 1120 | | <FontSize>7pt</FontSize> |
| 1121 | | <FontWeight>700</FontWeight> |
| 1122 | | <TextAlign>Center</TextAlign> |
| 1123 | | <VerticalAlign>Middle</VerticalAlign> |
| 1124 | | <PaddingLeft>2pt</PaddingLeft> |
| 1125 | | <PaddingRight>2pt</PaddingRight> |
| 1126 | | <PaddingTop>2pt</PaddingTop> |
| 1127 | | <PaddingBottom>2pt</PaddingBottom> |
| 1128 | | <Language>pl-PL</Language> |
| 1129 | | </Style> |
| 1130 | | <ZIndex>22</ZIndex> |
| 1131 | | <CanGrow>true</CanGrow> |
| 1132 | | <Value>KOLOR</Value> |
| | 1347 | </Textbox> |
| | 1348 | </ReportItems> |
| | 1349 | </TableCell> |
| | 1350 | <TableCell> |
| | 1351 | <ReportItems> |
| | 1352 | <Textbox Name="textbox27"> |
| | 1353 | <rd:DefaultName>textbox27</rd:DefaultName> |
| | 1354 | <Style> |
| | 1355 | <BackgroundColor>WhiteSmoke</BackgroundColor> |
| | 1356 | <BorderColor> |
| | 1357 | <Default>LightGrey</Default> |
| | 1358 | </BorderColor> |
| | 1359 | <BorderStyle> |
| | 1360 | <Default>Solid</Default> |
| | 1361 | </BorderStyle> |
| | 1362 | <BorderWidth> |
| | 1363 | <Default>0.5pt</Default> |
| | 1364 | </BorderWidth> |
| | 1365 | <FontSize>7pt</FontSize> |
| | 1366 | <FontWeight>700</FontWeight> |
| | 1367 | <TextAlign>Center</TextAlign> |
| | 1368 | <VerticalAlign>Middle</VerticalAlign> |
| | 1369 | <PaddingLeft>2pt</PaddingLeft> |
| | 1370 | <PaddingRight>2pt</PaddingRight> |
| | 1371 | <PaddingTop>2pt</PaddingTop> |
| | 1372 | <PaddingBottom>2pt</PaddingBottom> |
| | 1373 | </Style> |
| | 1374 | <ZIndex>18</ZIndex> |
| | 1375 | <CanGrow>true</CanGrow> |
| | 1376 | <Value>Uwagi</Value> |
| 1286 | | </Textbox> |
| 1287 | | </ReportItems> |
| 1288 | | </TableCell> |
| 1289 | | <TableCell> |
| 1290 | | <ReportItems> |
| 1291 | | <Textbox Name="textbox14"> |
| 1292 | | <rd:DefaultName>textbox14</rd:DefaultName> |
| 1293 | | <Style> |
| 1294 | | <BackgroundColor>WhiteSmoke</BackgroundColor> |
| 1295 | | <BorderColor> |
| 1296 | | <Default>LightGrey</Default> |
| 1297 | | </BorderColor> |
| 1298 | | <BorderStyle> |
| 1299 | | <Default>Solid</Default> |
| 1300 | | </BorderStyle> |
| 1301 | | <BorderWidth> |
| 1302 | | <Default>0.5pt</Default> |
| 1303 | | </BorderWidth> |
| 1304 | | <FontSize>7pt</FontSize> |
| 1305 | | <FontWeight>700</FontWeight> |
| 1306 | | <TextAlign>Center</TextAlign> |
| 1307 | | <VerticalAlign>Middle</VerticalAlign> |
| 1308 | | <PaddingLeft>2pt</PaddingLeft> |
| 1309 | | <PaddingRight>2pt</PaddingRight> |
| 1310 | | <PaddingTop>2pt</PaddingTop> |
| 1311 | | <PaddingBottom>2pt</PaddingBottom> |
| 1312 | | </Style> |
| 1313 | | <ZIndex>16</ZIndex> |
| 1314 | | <CanGrow>true</CanGrow> |
| 1315 | | <Value>FV</Value> |