-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
882 lines (882 loc) · 142 KB
/
index.html
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
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
<html>
<head><meta http-equiv=Content-Type content="text/html; charset=UTF-8">
<link rel="icon" href="https://cdn4.iconfinder.com/data/icons/e-commerce-and-shopping-3/500/store-building-512.png">
<style type="text/css">
<!--
span.cls_003{font-family:Times,serif;font-size:20.1px;color:rgb(0,0,0);font-weight:bold;font-style:normal;text-decoration: none}
div.cls_003{font-family:Times,serif;font-size:20.1px;color:rgb(0,0,0);font-weight:bold;font-style:normal;text-decoration: none}
span.cls_004{font-family:Times,serif;font-size:14.1px;color:rgb(0,0,0);font-weight:bold;font-style:normal;text-decoration: none}
div.cls_004{font-family:Times,serif;font-size:14.1px;color:rgb(0,0,0);font-weight:bold;font-style:normal;text-decoration: none}
span.cls_008{font-family:Times,serif;font-size:26.1px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration: none}
div.cls_008{font-family:Times,serif;font-size:26.1px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration: none}
span.cls_009{font-family:Times,serif;font-size:18.1px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration: none}
div.cls_009{font-family:Times,serif;font-size:18.1px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration: none}
span.cls_010{font-family:"Cambria Bold",serif;font-size:14.1px;color:rgb(54,95,145);font-weight:bold;font-style:normal;text-decoration: none}
div.cls_010{font-family:"Cambria Bold",serif;font-size:14.1px;color:rgb(54,95,145);font-weight:bold;font-style:normal;text-decoration: none}
span.cls_006{font-family:Times,serif;font-size:12.1px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration: none}
div.cls_006{font-family:Times,serif;font-size:12.1px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration: none}
span.cls_012{font-family:Times,serif;font-size:11.6px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration: none}
div.cls_012{font-family:Times,serif;font-size:11.6px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration: none}
span.cls_013{font-family:Times,serif;font-size:11.6px;color:rgb(0,0,0);font-weight:bold;font-style:normal;text-decoration: none}
div.cls_013{font-family:Times,serif;font-size:11.6px;color:rgb(0,0,0);font-weight:bold;font-style:normal;text-decoration: none}
span.cls_014{font-family:Times,serif;font-size:11.6px;color:rgb(0,0,0);font-weight:normal;font-style:italic;text-decoration: none}
div.cls_014{font-family:Times,serif;font-size:11.6px;color:rgb(0,0,0);font-weight:normal;font-style:italic;text-decoration: none}
span.cls_015{font-family:Times,serif;font-size:12.1px;color:rgb(0,0,0);font-weight:bold;font-style:normal;text-decoration: none}
div.cls_015{font-family:Times,serif;font-size:12.1px;color:rgb(0,0,0);font-weight:bold;font-style:normal;text-decoration: none}
span.cls_016{font-family:Times,serif;font-size:18.1px;color:rgb(0,0,0);font-weight:bold;font-style:normal;text-decoration: none}
div.cls_016{font-family:Times,serif;font-size:18.1px;color:rgb(0,0,0);font-weight:bold;font-style:normal;text-decoration: none}
span.cls_018{font-family:Times,serif;font-size:12.1px;color:rgb(0,0,0);font-weight:bold;font-style:italic;text-decoration: none}
div.cls_018{font-family:Times,serif;font-size:12.1px;color:rgb(0,0,0);font-weight:bold;font-style:italic;text-decoration: none}
span.cls_017{font-family:Times,serif;font-size:12.1px;color:rgb(0,0,0);font-weight:normal;font-style:italic;text-decoration: none}
div.cls_017{font-family:Times,serif;font-size:12.1px;color:rgb(0,0,0);font-weight:normal;font-style:italic;text-decoration: none}
span.cls_019{font-family:Times,serif;font-size:11.6px;color:rgb(0,0,0);font-weight:bold;font-style:italic;text-decoration: none}
div.cls_019{font-family:Times,serif;font-size:11.6px;color:rgb(0,0,0);font-weight:bold;font-style:italic;text-decoration: none}
-->
</style>
<script type="text/javascript" src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/wz_jsgraphics.js"></script>
</head>
<body>
<div style="position:absolute;left:50%;margin-left:-306px;top:0px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background01.jpg" width=612 height=792></div>
<div style="position:absolute;left:313.39px;top:194.54px" class="cls_003"><span class="cls_003">Univerzitet u Novom Sadu</span></div>
<div style="position:absolute;left:313.63px;top:221.06px" class="cls_004"><span class="cls_004">Fakultet tehničkih nauka</span></div>
<div style="position:absolute;left:313.15px;top:238.49px" class="cls_004"><span class="cls_004">Inženjerstvo informacionih sistema</span></div>
<div style="position:absolute;left:178.25px;top:461.11px" class="cls_008"><span class="cls_008">Uputstvo za razvoj WPF</span></div>
<div style="position:absolute;left:253.97px;top:490.99px" class="cls_008"><span class="cls_008">aplikacije</span></div>
<div style="position:absolute;left:229.49px;top:675.70px" class="cls_009"><span class="cls_009">Novi Sad, 2017. god.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:802px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background02.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:71.18px" class="cls_010"><span class="cls_010">Sadržaj</span></div>
<div style="position:absolute;left:72.02px;top:99.50px" class="cls_006"><span class="cls_006">• Uvod</span></div>
<div style="position:absolute;left:524.76px;top:99.50px" class="cls_006"><span class="cls_006">-3</span></div>
<div style="position:absolute;left:72.02px;top:120.26px" class="cls_006"><span class="cls_006">• Zadatak</span></div>
<div style="position:absolute;left:524.76px;top:120.26px" class="cls_006"><span class="cls_006">-3</span></div>
<div style="position:absolute;left:72.02px;top:141.14px" class="cls_006"><span class="cls_006">• Kreiranje UML dijagrama</span></div>
<div style="position:absolute;left:521.98px;top:141.14px" class="cls_006"><span class="cls_006">- 4</span></div>
<div style="position:absolute;left:86.30px;top:162.62px" class="cls_006"><span class="cls_006">•</span></div>
<div style="position:absolute;left:107.30px;top:162.62px" class="cls_006"><span class="cls_006">Dijagram slučajeva upotrebe</span></div>
<div style="position:absolute;left:524.40px;top:162.62px" class="cls_006"><span class="cls_006">- 4</span></div>
<div style="position:absolute;left:85.34px;top:183.38px" class="cls_006"><span class="cls_006">•</span></div>
<div style="position:absolute;left:106.34px;top:183.38px" class="cls_006"><span class="cls_006">Dijagram klasa</span></div>
<div style="position:absolute;left:524.40px;top:183.38px" class="cls_006"><span class="cls_006">- 8</span></div>
<div style="position:absolute;left:72.02px;top:204.26px" class="cls_006"><span class="cls_006">• Kreiranje baze podataka</span></div>
<div style="position:absolute;left:524.76px;top:204.26px" class="cls_006"><span class="cls_006">-9</span></div>
<div style="position:absolute;left:72.02px;top:225.02px" class="cls_006"><span class="cls_006">• Kreiranje Studentske WPF aplikacije (desktop aplikacije)</span></div>
<div style="position:absolute;left:516.34px;top:225.02px" class="cls_006"><span class="cls_006">-21</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:1604px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background03.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:70.58px" class="cls_003"><span class="cls_003">1. Uvod</span></div>
<div style="position:absolute;left:71.30px;top:121.94px" class="cls_012"><span class="cls_012">U okviru ovog uputstva opisani su svi potrebni koraci koje neko treba da prođe kako bi razvio </span><span class="cls_013">WPF</span></div>
<div style="position:absolute;left:71.78px;top:136.58px" class="cls_012"><span class="cls_012">(engl. </span><span class="cls_014">Windows Presentation Foundation</span><span class="cls_012">) </span><span class="cls_013">aplikaciju</span><span class="cls_012"> i upoznao se sa osnovnim principima </span><span class="cls_013">UML</span></div>
<div style="position:absolute;left:71.78px;top:150.74px" class="cls_013"><span class="cls_013">modelovanja</span><span class="cls_012">, kao i rada u </span><span class="cls_013">Microsoft SQL Server</span><span class="cls_012">-u i </span><span class="cls_013">Microsoft Visual Studiju</span><span class="cls_012">.</span></div>
<div style="position:absolute;left:74.90px;top:212.78px" class="cls_003"><span class="cls_003">2. Zadatak</span></div>
<div style="position:absolute;left:72.02px;top:271.01px" class="cls_006"><span class="cls_006">Cilj zadatka je da se kreira </span><span class="cls_015">WPF aplikacija </span><span class="cls_006">koja simulira rad </span><span class="cls_015">trafike</span><span class="cls_006">. Njena komunikacija sa</span></div>
<div style="position:absolute;left:72.02px;top:285.89px" class="cls_015"><span class="cls_015">bazom podataka </span><span class="cls_006">ostvarivaće se putem ADO.NET tehnologije. </span><span class="cls_015">Aplikacija</span><span class="cls_006"> treba da pruži</span></div>
<div style="position:absolute;left:72.02px;top:300.77px" class="cls_006"><span class="cls_006">mogućnost prikazivanja podataka o obavljenim kupovinama u </span><span class="cls_015">trafici</span><span class="cls_006">, kupcima koji su te</span></div>
<div style="position:absolute;left:72.02px;top:315.65px" class="cls_006"><span class="cls_006">kupovine obavljali, prodavcima koji su ih opsluživali, proizvodima koji su bili predmet tih</span></div>
<div style="position:absolute;left:72.02px;top:330.53px" class="cls_006"><span class="cls_006">kupovina (njihovim proizvođačima, vrstama i dobavljačima) kao i o fiskalnim računima koji se</span></div>
<div style="position:absolute;left:72.02px;top:345.41px" class="cls_006"><span class="cls_006">izrađuju nakon uspešno obavljene kupovine. </span><span class="cls_012">Takođe, treba da pruža mogućnost </span><span class="cls_014">dodavanja</span><span class="cls_012">, </span><span class="cls_014">izmene</span></div>
<div style="position:absolute;left:72.02px;top:359.81px" class="cls_012"><span class="cls_012">i </span><span class="cls_014">brisanja</span><span class="cls_012"> podataka o navedenim entitetima.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:2406px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background04.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.58px" class="cls_003"><span class="cls_003">3. Kreiranje UML dijagrama</span></div>
<div style="position:absolute;left:71.30px;top:130.94px" class="cls_016"><span class="cls_016">3.1. Dijagram slučajeva upotrebe</span></div>
<div style="position:absolute;left:71.30px;top:181.58px" class="cls_006"><span class="cls_006">Na samom početku pristupamo inicijalnom modelovanju sistema odnosno kreiranju </span><span class="cls_015">dijagrama</span></div>
<div style="position:absolute;left:71.78px;top:199.94px" class="cls_015"><span class="cls_015">slučajeva upotrebe </span><span class="cls_006">na osnovu datog opisa za primer </span><span class="cls_015">trafike</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:72.02px;top:252.53px" class="cls_018"><span class="cls_018">Slučaj upotrebe</span><span class="cls_006">: Logovanje prilikom preuzimanja smene</span></div>
<div style="position:absolute;left:72.02px;top:287.45px" class="cls_018"><span class="cls_018">Kratak opis</span><span class="cls_006">: Prodavac se prilikom preuzimanja smene prijavljuje na sistem</span></div>
<div style="position:absolute;left:72.02px;top:322.49px" class="cls_018"><span class="cls_018">Učesnici</span><span class="cls_006">:</span><span class="cls_015"> </span><span class="cls_006">Prodavac</span></div>
<div style="position:absolute;left:72.02px;top:357.41px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni pre izvršavanja</span><span class="cls_006">: Prodavac je započeo svoju smenu.</span></div>
<div style="position:absolute;left:72.02px;top:392.33px" class="cls_018"><span class="cls_018">Opis</span><span class="cls_006">: Prodavac se prilikom preuzimanja smene prijavljuje na sistem unosom svog username- a i</span></div>
<div style="position:absolute;left:72.50px;top:407.83px" class="cls_006"><span class="cls_006">password- a. Ukoliko se prvi put prijavljuje na sistem ili je eventualno zaboravio svoju lozinku</span></div>
<div style="position:absolute;left:72.50px;top:423.43px" class="cls_006"><span class="cls_006">iskoristiće pomoć koju sistem pruža u takvim situacijama. [</span><span class="cls_018">Izuzetak</span><span class="cls_006">: Prodavac je pogrešno uneo</span></div>
<div style="position:absolute;left:72.50px;top:438.91px" class="cls_006"><span class="cls_006">svoj username ili password].</span></div>
<div style="position:absolute;left:72.02px;top:474.07px" class="cls_018"><span class="cls_018">Izuzeci:</span></div>
<div style="position:absolute;left:75.02px;top:508.87px" class="cls_006"><span class="cls_006">[</span><span class="cls_015">Prodavac je pogrešno uneo svoj username ili password</span><span class="cls_006">]. Ukoliko je prodavac pogrešno uneo</span></div>
<div style="position:absolute;left:72.50px;top:524.35px" class="cls_006"><span class="cls_006">svoj username ili password zatražiće se od njega da ponovo unese podatke.</span></div>
<div style="position:absolute;left:72.02px;top:559.27px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni nakon izvršavanja</span><span class="cls_006">: Prodavac se uspešno ulogovao na sistem.</span></div>
<div style="position:absolute;left:72.02px;top:611.74px" class="cls_018"><span class="cls_018">Slučaj upotrebe</span><span class="cls_006">: Pregled stanja zaliha</span></div>
<div style="position:absolute;left:72.02px;top:646.66px" class="cls_018"><span class="cls_018">Kratak opis</span><span class="cls_006">: Pregled stanja zaliha robe u trafici</span></div>
<div style="position:absolute;left:72.02px;top:681.70px" class="cls_018"><span class="cls_018">Učesnici</span><span class="cls_006">: Prodavac</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:3208px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background05.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni pre izvršavanja</span><span class="cls_006">: Prodavac je uspešno započeo prvu smenu.</span></div>
<div style="position:absolute;left:72.02px;top:105.86px" class="cls_018"><span class="cls_018">Opis</span><span class="cls_006">:</span><span class="cls_017"> </span><span class="cls_006">Prodavac koji radi u prvoj smeni pregleda trenutno stanje zaliha u trafici i u koliko postoji</span></div>
<div style="position:absolute;left:72.50px;top:121.46px" class="cls_006"><span class="cls_006">potreba, naručuje potrebnu robu u potrebnim količinama. [</span><span class="cls_018">Izuzetak</span><span class="cls_006">: Ne postoji potreba za</span></div>
<div style="position:absolute;left:72.50px;top:136.94px" class="cls_006"><span class="cls_006">naručivanjem robe].</span></div>
<div style="position:absolute;left:72.02px;top:171.86px" class="cls_018"><span class="cls_018">Izuzeci</span><span class="cls_006">:</span></div>
<div style="position:absolute;left:72.02px;top:206.78px" class="cls_006"><span class="cls_006">[</span><span class="cls_015">Ne postoji potreba za naručivanjem robe</span><span class="cls_006">]. Ukoliko trenutno ne postoji potreba za</span></div>
<div style="position:absolute;left:72.50px;top:222.38px" class="cls_006"><span class="cls_006">naručivanjem robe, porudžbina se neće obaviti.</span></div>
<div style="position:absolute;left:72.02px;top:257.33px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni nakon izvršavanja</span><span class="cls_006">: Utvrđeno je stanje zaliha i porudžbina je</span></div>
<div style="position:absolute;left:72.50px;top:272.81px" class="cls_006"><span class="cls_006">uspešno poslata odgovarajućem dobavljaču.</span></div>
<div style="position:absolute;left:72.02px;top:325.25px" class="cls_018"><span class="cls_018">Slučaj upotrebe</span><span class="cls_006">: Kupovina proizvoda</span></div>
<div style="position:absolute;left:72.02px;top:360.17px" class="cls_018"><span class="cls_018">Kratak opis</span><span class="cls_006">: Kupovina proizvoda na trafici od strane kupca</span></div>
<div style="position:absolute;left:72.02px;top:395.21px" class="cls_018"><span class="cls_018">Učesnici</span><span class="cls_006">: Prodavac, Kupac</span></div>
<div style="position:absolute;left:72.02px;top:430.15px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni pre izvršavanja</span><span class="cls_006">: U trafici se nalazi se nalazi traženi proizvod</span></div>
<div style="position:absolute;left:72.50px;top:445.63px" class="cls_006"><span class="cls_006">i kupac ima dovoljno novca za njegovu kupovinu.</span></div>
<div style="position:absolute;left:72.02px;top:480.55px" class="cls_018"><span class="cls_018">Opis</span><span class="cls_006">: Kupac potražuje određeni proizvod. Ukoliko se dati proizvod nalazi u ponudi i ukoliko</span></div>
<div style="position:absolute;left:72.50px;top:496.15px" class="cls_006"><span class="cls_006">kupac ima dovoljno novca obavlja se kupovina. U slučaju da kupac vrši elektronsku dopunu od</span></div>
<div style="position:absolute;left:72.50px;top:511.63px" class="cls_006"><span class="cls_006">njega će se tražiti broj mobilnog telefona. [</span><span class="cls_018">Izuzetak</span><span class="cls_006">: Traženi proizvod se ne nalazi u ponudi ili</span></div>
<div style="position:absolute;left:72.50px;top:527.23px" class="cls_006"><span class="cls_006">kupac nema dovoljno novca]. [</span><span class="cls_018">Izuzetak</span><span class="cls_006">: Prilikom elektronske dopune prodavac je pogrešno uneo</span></div>
<div style="position:absolute;left:72.50px;top:542.71px" class="cls_006"><span class="cls_006">broj moblinog telefona].</span></div>
<div style="position:absolute;left:72.02px;top:577.66px" class="cls_018"><span class="cls_018">Izuzeci</span><span class="cls_006">:</span></div>
<div style="position:absolute;left:72.02px;top:612.58px" class="cls_006"><span class="cls_006">[</span><span class="cls_015">Trazeni proizvod se ne nalazi u ponudi ili kupac nema dovoljno novca</span><span class="cls_006">]. Ukoliko se traženi</span></div>
<div style="position:absolute;left:72.50px;top:628.18px" class="cls_006"><span class="cls_006">proizvod ne nalazi u ponudi ili kupac nema dovoljno novca kupovina se neće obaviti.</span></div>
<div style="position:absolute;left:72.02px;top:663.10px" class="cls_006"><span class="cls_006">[</span><span class="cls_015">Prilikom elektronske dopune prodavac je pogrešno uneo broj moblinog telefona</span><span class="cls_006">]. Ukoliko</span></div>
<div style="position:absolute;left:72.50px;top:678.58px" class="cls_006"><span class="cls_006">je prodavac pogrešno uneo broj mobilnog telefona kupca dopuna neće biti ispravna.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:4010px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background06.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni nakon izvršavanja</span><span class="cls_006">: Kupovina je uspešno obavljena, odnosno</span></div>
<div style="position:absolute;left:72.50px;top:86.42px" class="cls_006"><span class="cls_006">kupac je dobio traženi proizvod, ili je uspešno dopunio kredit.</span></div>
<div style="position:absolute;left:72.02px;top:138.86px" class="cls_018"><span class="cls_018">Slučaj upotrebe</span><span class="cls_006">: Izdavanje fiskalnog računa</span></div>
<div style="position:absolute;left:72.02px;top:173.78px" class="cls_018"><span class="cls_018">Kratak opis</span><span class="cls_006">: Izdavanje fiskalnog računa nakon kupovine</span></div>
<div style="position:absolute;left:72.02px;top:208.82px" class="cls_018"><span class="cls_018">Učesnici</span><span class="cls_006">: Prodavac, Kupac</span></div>
<div style="position:absolute;left:72.02px;top:243.77px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni pre izvršavanja</span><span class="cls_006">: Kupovina je uspešno obavljena i izvršeno je</span></div>
<div style="position:absolute;left:72.50px;top:259.25px" class="cls_006"><span class="cls_006">plaćanje.</span></div>
<div style="position:absolute;left:72.02px;top:294.17px" class="cls_018"><span class="cls_018">Opis</span><span class="cls_006">: Ukoliko je uspešno izvršena kupovina, kupcu se nakon izvršenog plaćanja izdaje fiskalni</span></div>
<div style="position:absolute;left:72.50px;top:309.77px" class="cls_006"><span class="cls_006">račun od strane prodavca. [</span><span class="cls_018">Izuzetak</span><span class="cls_006">: Neuspešno izvršena kupovina].</span></div>
<div style="position:absolute;left:72.02px;top:344.69px" class="cls_018"><span class="cls_018">Izuzeci</span><span class="cls_006">:</span></div>
<div style="position:absolute;left:72.02px;top:379.61px" class="cls_006"><span class="cls_006">[</span><span class="cls_015">Neuspešno izvršena kupovina</span><span class="cls_006">]. Ukoliko kupovina nije izvršena fiskalni račun neće biti izdat.</span></div>
<div style="position:absolute;left:72.02px;top:414.67px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni nakon izvršavanja</span><span class="cls_006">: Kupcu je izdat fiskalni račun za datu</span></div>
<div style="position:absolute;left:72.50px;top:430.15px" class="cls_006"><span class="cls_006">kupovinu.</span></div>
<div style="position:absolute;left:72.02px;top:482.59px" class="cls_018"><span class="cls_018">Slučaj upotrebe</span><span class="cls_006">: Evidencija dnevne zarade</span></div>
<div style="position:absolute;left:72.02px;top:517.51px" class="cls_018"><span class="cls_018">Kratak opis</span><span class="cls_006">: Evidencija dnevne zarade na kraju radnog dana</span></div>
<div style="position:absolute;left:72.02px;top:535.03px" class="cls_006"><span class="cls_006">Učesnici: Prodavac</span></div>
<div style="position:absolute;left:72.02px;top:569.95px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni pre izvršavanja</span><span class="cls_006">: Kraj je radnog dana i prodavac je za svaku</span></div>
<div style="position:absolute;left:72.50px;top:585.46px" class="cls_006"><span class="cls_006">kupovinu uredno izdao fiskalni račun.</span></div>
<div style="position:absolute;left:72.02px;top:620.38px" class="cls_018"><span class="cls_018">Opis</span><span class="cls_006">: Prodavac koji radi u drugoj smeni na kraju radnog dana računa i vrši evidenciju zarade za</span></div>
<div style="position:absolute;left:72.50px;top:635.98px" class="cls_006"><span class="cls_006">taj dan i podatke beleži u sistem. [</span><span class="cls_018">Izuzetak</span><span class="cls_006">: Prodavac je pogrešno izračunao ili uneo podatke].</span></div>
<div style="position:absolute;left:72.50px;top:651.46px" class="cls_006"><span class="cls_006">[Izuzetak: Prodavac za neku kupovinu nije izdao fiskalni račun].</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:4812px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background07.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_018"><span class="cls_018">Izuzeci</span><span class="cls_006">:</span></div>
<div style="position:absolute;left:75.02px;top:105.86px" class="cls_006"><span class="cls_006">[</span><span class="cls_015">Pogrešno izračunati ili uneti podaci</span><span class="cls_006">]. Ukoliko je prodavac pogrešno izračunao ili uneo neke</span></div>
<div style="position:absolute;left:72.50px;top:121.46px" class="cls_006"><span class="cls_006">podatke evidencija o prihodima će biti neispravna.</span></div>
<div style="position:absolute;left:72.02px;top:156.38px" class="cls_006"><span class="cls_006">[</span><span class="cls_015">Prodavac za neku kupovinu nije izdao fiskalni račun</span><span class="cls_006">]. Ukoliko prodavac za neku kupovinu</span></div>
<div style="position:absolute;left:72.50px;top:171.86px" class="cls_006"><span class="cls_006">nije izdao fiskalni račun evidencija o prihodima će takođe biti neispravna.</span></div>
<div style="position:absolute;left:72.02px;top:206.78px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni nakon izvršavanja</span><span class="cls_006">: Uspešno je evidentirana dnevna zarada i</span></div>
<div style="position:absolute;left:72.50px;top:222.38px" class="cls_006"><span class="cls_006">podaci su uneti u sistem.</span></div>
<div style="position:absolute;left:72.02px;top:274.85px" class="cls_018"><span class="cls_018">Slučaj upotrebe</span><span class="cls_006">: Isporuka i prijem dnevne štampe</span></div>
<div style="position:absolute;left:72.02px;top:309.77px" class="cls_018"><span class="cls_018">Kratak opis</span><span class="cls_006">: Isporuka i prijem dnevne štampe za potrebe trafike</span></div>
<div style="position:absolute;left:72.02px;top:327.17px" class="cls_006"><span class="cls_006">Učesnici: Prodavac, Dobavljač</span></div>
<div style="position:absolute;left:72.02px;top:362.21px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni pre izvršavanja</span><span class="cls_006">: Dobavljač je isporučio naručene proizvode.</span></div>
<div style="position:absolute;left:72.02px;top:397.13px" class="cls_018"><span class="cls_018">Opis</span><span class="cls_006">: Dobavljač isporučuje dnevnu štampu, a ukoliko su naručeni ostali proizvodi oni će takođe</span></div>
<div style="position:absolute;left:72.50px;top:412.63px" class="cls_006"><span class="cls_006">biti isporučeni od strane istog ili drugog dobavljača. Pri prijemu robe evidentiraju se troškovi</span></div>
<div style="position:absolute;left:72.50px;top:428.23px" class="cls_006"><span class="cls_006">nabavke i ažurira se stanje zaliha robe. [</span><span class="cls_018">Izuzetak</span><span class="cls_006">: Isporučena je neispravna roba].</span></div>
<div style="position:absolute;left:72.02px;top:463.15px" class="cls_018"><span class="cls_018">Izuzeci</span><span class="cls_006">:</span></div>
<div style="position:absolute;left:72.02px;top:498.07px" class="cls_006"><span class="cls_006">[</span><span class="cls_015">Isporučena je neispravna roba</span><span class="cls_006">]. Ukoliko je dobavljač isporučio neispravnu robu i ona nije</span></div>
<div style="position:absolute;left:72.50px;top:513.55px" class="cls_006"><span class="cls_006">prošla kontrolu ne vrši se prijem robe, ona se vraća dobavljaču i kreira se reklamacioni zapisnik.</span></div>
<div style="position:absolute;left:72.02px;top:548.59px" class="cls_018"><span class="cls_018">Uslovi koji moraju biti zadovoljeni nakon izvršavanja</span><span class="cls_006">: Roba je uspešno isporučena i primljena,</span></div>
<div style="position:absolute;left:72.50px;top:564.07px" class="cls_006"><span class="cls_006">evidentirani su troškovi nabavke i ažurirano je stanje zaliha.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:5614px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background08.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.80px" class="cls_006"><span class="cls_006">Na osnovu datih opisa slučajeva upotrebe kreiran je dijagram prikazan na </span><span class="cls_017">Slici 1</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:202.85px;top:542.71px" class="cls_017"><span class="cls_017">Slika 1 - Dijagram slučajeva upotrebe</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:6416px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background09.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.70px" class="cls_016"><span class="cls_016">3.2. Dijagram klasa</span></div>
<div style="position:absolute;left:71.30px;top:118.94px" class="cls_006"><span class="cls_006">Nakon uspešno kreiranog dijagrama slučajeva upotrebe, pristupamo izradi </span><span class="cls_015">dijagrama klasa </span><span class="cls_006">koji</span></div>
<div style="position:absolute;left:71.78px;top:134.42px" class="cls_006"><span class="cls_006">predstavlja vizuelni prikaz modela statičke strukture sistema. U slučaju primera </span><span class="cls_015">trafike</span><span class="cls_006"> kreiran</span></div>
<div style="position:absolute;left:71.78px;top:149.90px" class="cls_006"><span class="cls_006">je dijagram klasa prikazan na </span><span class="cls_017">Slici 2</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:244.49px;top:569.35px" class="cls_017"><span class="cls_017">Slika 2 - Dijagram klasa</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:7218px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background10.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.58px" class="cls_003"><span class="cls_003">4. Kreiranje baze podataka</span></div>
<div style="position:absolute;left:72.02px;top:133.82px" class="cls_012"><span class="cls_012">Sledeći korak u izradi aplikacije jeste kreiranje </span><span class="cls_013">baze podataka</span><span class="cls_012">. Na samom početku, potrebno je</span></div>
<div style="position:absolute;left:72.02px;top:148.10px" class="cls_012"><span class="cls_012">pokrenuti </span><span class="cls_013">SQL Server Management Studio Express</span><span class="cls_012">. Kada se to uradi, pojaviće se prozor sa</span></div>
<div style="position:absolute;left:72.02px;top:162.38px" class="cls_012"><span class="cls_012">dijalogom, kao što je prikazano na </span><span class="cls_014">Slici 3</span><span class="cls_012">. U prikazanom dijalogu, potrebno je podesiti parametre</span></div>
<div style="position:absolute;left:72.02px;top:176.66px" class="cls_013"><span class="cls_013">Server type </span><span class="cls_012">i </span><span class="cls_013">Authentication</span><span class="cls_012">, kao što je prikazano na </span><span class="cls_014">Slici 3</span><span class="cls_012">. Napomena: </span><span class="cls_013">Server name </span><span class="cls_012">nije</span></div>
<div style="position:absolute;left:72.02px;top:191.06px" class="cls_012"><span class="cls_012">potrebno menjati, ono predstavlja naziv mašine na kojoj se radi.</span></div>
<div style="position:absolute;left:230.09px;top:469.99px" class="cls_014"><span class="cls_014">Slika 3 - Ostvarivanje konekcije na server</span></div>
<div style="position:absolute;left:72.02px;top:496.99px" class="cls_012"><span class="cls_012">Nakon podešavanja parametara, klikom na dugme </span><span class="cls_014">Connect</span><span class="cls_012">, dijalog će se zatvoriti, a otvoriće se novi</span></div>
<div style="position:absolute;left:72.02px;top:512.59px" class="cls_012"><span class="cls_012">prozor koji treba da izgleda kao što je prikazano na </span><span class="cls_014">Slici 4.</span></div>
<div style="position:absolute;left:165.02px;top:700.66px" class="cls_014"><span class="cls_014">Slika 4 - Izgled Object Explorera nakon ostvarivanja konekcije na bazu</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:8020px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background11.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:96.26px" class="cls_012"><span class="cls_012">Sada je potrebno kreirati bazu podataka za </span><span class="cls_013">Studentsku aplikaciju</span><span class="cls_012">. Baza se kreira tako što se klikne</span></div>
<div style="position:absolute;left:72.02px;top:111.86px" class="cls_014"><span class="cls_014">desnim klikom </span><span class="cls_012">na </span><span class="cls_013">Database </span><span class="cls_012">u </span><span class="cls_014">treeview</span><span class="cls_012">-u koji se nalazi sa leve strane prozora u okviru </span><span class="cls_014">Object</span></div>
<div style="position:absolute;left:72.02px;top:127.10px" class="cls_014"><span class="cls_014">Explorer</span><span class="cls_012">-a. Otvoriće se lista u kojoj je potrebno selektovati </span><span class="cls_013">New Database </span><span class="cls_014">(Slika 5).</span></div>
<div style="position:absolute;left:240.29px;top:374.21px" class="cls_017"><span class="cls_017">Slika 5 - Kreiranje baze podataka</span></div>
<div style="position:absolute;left:71.30px;top:404.45px" class="cls_012"><span class="cls_012">Otvoriće se prozor u kom će se kreirati </span><span class="cls_013">baza podataka</span><span class="cls_012">. Potrebno je dati naziv bazi, u ovom slučaju</span></div>
<div style="position:absolute;left:71.30px;top:420.07px" class="cls_012"><span class="cls_012">naziv će biti </span><span class="cls_014">Trafika</span><span class="cls_012">. Ostale parametre nije potrebno menjati. Kliknuti </span><span class="cls_013">OK</span><span class="cls_012"> (</span><span class="cls_014">Slika 6</span><span class="cls_012">).</span></div>
<div style="position:absolute;left:162.74px;top:705.22px" class="cls_014"><span class="cls_014">Slika 6 - Podešavanje parametara pri kreiranju baze podataka</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:8822px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background12.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.80px" class="cls_012"><span class="cls_012">Posle uspešnog kreiranja baze podataka u </span><span class="cls_014">Object explorer-u</span><span class="cls_012">, u folderu </span><span class="cls_014">Database </span><span class="cls_012">se pojavljuje</span></div>
<div style="position:absolute;left:72.02px;top:85.10px" class="cls_012"><span class="cls_012">kreirana baza podataka </span><span class="cls_014">Trafika </span><span class="cls_012">(</span><span class="cls_014">Slika 7</span><span class="cls_012">).</span></div>
<div style="position:absolute;left:211.49px;top:232.34px" class="cls_014"><span class="cls_014">Slika 7 - Prikaz kreirane baze podataka</span></div>
<div style="position:absolute;left:71.30px;top:285.53px" class="cls_012"><span class="cls_012">Proširivanjem baze </span><span class="cls_014">Trafika </span><span class="cls_012">u stablu </span><span class="cls_014">Object Explorer</span><span class="cls_012">-a, pojavljuje se više datoteka. Desnim klikom</span></div>
<div style="position:absolute;left:71.30px;top:301.25px" class="cls_012"><span class="cls_012">kliknuti na datoteku </span><span class="cls_014">Tables </span><span class="cls_012">i odabrati </span><span class="cls_014">Table </span><span class="cls_012">(</span><span class="cls_014">Slika 8</span><span class="cls_012">). Nakon klika na ovu opciju, sa desne strane</span></div>
<div style="position:absolute;left:71.30px;top:316.37px" class="cls_012"><span class="cls_012">otvara se prozor za definisanje tabele, pri čemu će tabela imati predefinisani naziv</span></div>
<div style="position:absolute;left:71.30px;top:332.81px" class="cls_014"><span class="cls_014">Table_1 </span><span class="cls_012">(</span><span class="cls_014">Slika 9</span><span class="cls_012">).</span></div>
<div style="position:absolute;left:189.05px;top:693.82px" class="cls_017"><span class="cls_017">Slika 8 - Kreiranje tabele unutar baze podataka</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:9624px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background13.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.80px" class="cls_012"><span class="cls_012">Sledeće što je potrebno uraditi jeste kreirati kolone tabele tako što će se popuniti polja </span><span class="cls_013">Column</span></div>
<div style="position:absolute;left:72.02px;top:85.10px" class="cls_013"><span class="cls_013">Name</span><span class="cls_012">, </span><span class="cls_013">Data Type</span><span class="cls_012">, </span><span class="cls_013">Allow Nulls</span><span class="cls_012">. U kolonu </span><span class="cls_014">Column Name </span><span class="cls_012">se upisuje naziv atributa. U koloni </span><span class="cls_014">Data</span></div>
<div style="position:absolute;left:72.02px;top:99.38px" class="cls_014"><span class="cls_014">Type </span><span class="cls_012">se bira tip podatka za željeni atribut, dok se u koloni </span><span class="cls_014">Allow Null </span><span class="cls_012">selektuje da li određeno polje</span></div>
<div style="position:absolute;left:72.02px;top:113.66px" class="cls_012"><span class="cls_012">može imat </span><span class="cls_014">null </span><span class="cls_012">vrednosti. Preporučuje se da </span><span class="cls_014">Allow Nulls </span><span class="cls_012">bude check-irano za sve kolone osim za</span></div>
<div style="position:absolute;left:72.02px;top:127.46px" class="cls_012"><span class="cls_012">primarni ključ kako bi se izbegli određeni problemi prilikom upisa rekorda u tabelu (</span><span class="cls_014">Slika 9</span><span class="cls_012">).</span></div>
<div style="position:absolute;left:214.85px;top:259.37px" class="cls_014"><span class="cls_014">Slika 9 - Dodavanje obeležja unutar tabele</span></div>
<div style="position:absolute;left:71.30px;top:312.41px" class="cls_012"><span class="cls_012">Svaka tabela neke baze podataka mora posedovati </span><span class="cls_013">primarni ključ - ID </span><span class="cls_012">i bilo koja kolona može da se</span></div>
<div style="position:absolute;left:71.30px;top:328.01px" class="cls_012"><span class="cls_012">deklariše kao primarni ključ. U ovom slučaju, kolona </span><span class="cls_014">ProizvodID</span><span class="cls_012"> treba da se deklariše kao primarni</span></div>
<div style="position:absolute;left:71.30px;top:343.73px" class="cls_012"><span class="cls_012">ključ. Kao takva, ova kolona će zbog svoje jedinstvene vrednosti imati tip podatka </span><span class="cls_014">int </span><span class="cls_012">i neće imati</span></div>
<div style="position:absolute;left:71.30px;top:358.85px" class="cls_014"><span class="cls_014">null </span><span class="cls_012">vrednosti (</span><span class="cls_014">Slika 10</span><span class="cls_012">).</span></div>
<div style="position:absolute;left:221.33px;top:645.94px" class="cls_017"><span class="cls_017">Slika 10 - Prikaz kreiranih obeležja</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:10426px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background14.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.80px" class="cls_012"><span class="cls_012">Da bi se kolona </span><span class="cls_014">ProizvodID</span><span class="cls_013"> </span><span class="cls_012">deklarisala kao primarni ključ, potrebno je kliknuti desnim klikom na</span></div>
<div style="position:absolute;left:72.02px;top:85.10px" class="cls_012"><span class="cls_012">crnu strelicu koja se nalazi pored naziva ove kolone. Otvoriće se lista u kojoj treba odabrati opciju</span></div>
<div style="position:absolute;left:72.02px;top:99.38px" class="cls_014"><span class="cls_014">Set Primary Key </span><span class="cls_012">(</span><span class="cls_014">Slika 11</span><span class="cls_012">). Ovom komandom se kolona</span><span class="cls_014"> ProizvodID</span><span class="cls_012"> deklariše kao primarni ključ.</span></div>
<div style="position:absolute;left:192.05px;top:503.11px" class="cls_017"><span class="cls_017">Slika 11 - Definisanje primarnog ključa</span></div>
<div style="position:absolute;left:72.02px;top:584.74px" class="cls_012"><span class="cls_012">Da bi </span><span class="cls_013">SUBP (Sistem za upravljanje bazom podataka) </span><span class="cls_012">automatski kreirao primarni ključ, potrebno</span></div>
<div style="position:absolute;left:72.02px;top:600.34px" class="cls_012"><span class="cls_012">je u </span><span class="cls_014">Column Properties </span><span class="cls_012">pronaći opciju </span><span class="cls_014">Identity Specification. </span><span class="cls_012">Proširivanjem opcije </span><span class="cls_014">Identity</span></div>
<div style="position:absolute;left:72.02px;top:616.06px" class="cls_014"><span class="cls_014">Specification </span><span class="cls_012">dobija se opcija </span><span class="cls_014">Is Identity, </span><span class="cls_012">koju treba promeniti na </span><span class="cls_014">Yes. </span><span class="cls_012">Ovde je, takođe, moguće</span></div>
<div style="position:absolute;left:72.02px;top:631.66px" class="cls_012"><span class="cls_012">podesiti parametre </span><span class="cls_014">Identity Increment </span><span class="cls_012">i </span><span class="cls_014">Identity Seed</span><span class="cls_012">. </span><span class="cls_014">Identity Increment-</span><span class="cls_012">om se definiše za koliko</span></div>
<div style="position:absolute;left:72.02px;top:647.26px" class="cls_012"><span class="cls_012">raste sledeća vrednost ključa, </span><span class="cls_014">Identity Seed </span><span class="cls_012">od koje vrednosti počinju da se memorišu ključevi (</span><span class="cls_014">Slika</span></div>
<div style="position:absolute;left:72.02px;top:662.98px" class="cls_014"><span class="cls_014">12</span><span class="cls_012">).</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:11228px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background15.jpg" width=612 height=792></div>
<div style="position:absolute;left:105.02px;top:449.59px" class="cls_017"><span class="cls_017">Slika 12 - Podešavanja automatske inkrementacije vrednosti obeležja primarnog ključa</span></div>
<div style="position:absolute;left:71.30px;top:508.03px" class="cls_012"><span class="cls_012">Čuvanje tabele se vrši pritiskanjem tastera </span><span class="cls_013">Ctrl </span><span class="cls_012">i </span><span class="cls_013">S </span><span class="cls_012">(Strl+S). SQL Server Managament Studio</span></div>
<div style="position:absolute;left:71.30px;top:524.35px" class="cls_012"><span class="cls_012">Express će pitati pod kojim nazivom se želi sačuvati tabela. Naziv tabele se najčešće navodi sa</span></div>
<div style="position:absolute;left:71.78px;top:539.47px" class="cls_012"><span class="cls_012">prefiksom </span><span class="cls_014">"tbl"</span><span class="cls_012">, u ovom slučaju </span><span class="cls_014">tblProizvod</span><span class="cls_012"> (</span><span class="cls_014">Slika 13</span><span class="cls_012">).</span></div>
<div style="position:absolute;left:218.33px;top:703.06px" class="cls_017"><span class="cls_017">Slika 13 - Čuvanje kreirane tabele</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:12030px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background16.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_012"><span class="cls_012">Isti proces bi se trebao ponoviti za kreiranje tabela </span><span class="cls_014">tblKupac, tblProdavac, tblVrstaProizvoda,</span></div>
<div style="position:absolute;left:72.02px;top:85.10px" class="cls_014"><span class="cls_014">tblProizvodjac, tblDobavljac </span><span class="cls_012">i </span><span class="cls_014">tblFiksalniRacun (Slike 14 - 19).</span></div>
<div style="position:absolute;left:261.89px;top:289.61px" class="cls_017"><span class="cls_017">Slika 14 - Kreiranje tabele Kupac</span></div>
<div style="position:absolute;left:258.77px;top:491.35px" class="cls_017"><span class="cls_017">Slika 15 - Kreiranje tabele Prodavac</span></div>
<div style="position:absolute;left:237.53px;top:663.94px" class="cls_017"><span class="cls_017">Slika 16 - Kreiranje tabele VrstaProizvoda</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:12832px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background17.jpg" width=612 height=792></div>
<div style="position:absolute;left:239.09px;top:222.98px" class="cls_017"><span class="cls_017">Slika 17 - Kreiranje tabele Proizvodjac</span></div>
<div style="position:absolute;left:232.49px;top:400.49px" class="cls_017"><span class="cls_017">Slika 18 - Kreiranje tabele Dobavljac</span></div>
<div style="position:absolute;left:204.53px;top:675.58px" class="cls_017"><span class="cls_017">Slika 19 - Kreiranje tabele FiskalniRacun</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:13634px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background18.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.80px" class="cls_012"><span class="cls_012">Nakon toga bi u </span><span class="cls_014">treeview</span><span class="cls_012">-u koji se nalazi sa leve strane prozora u okviru </span><span class="cls_014">Object Explorer</span><span class="cls_012">-a trebala da</span></div>
<div style="position:absolute;left:72.02px;top:85.10px" class="cls_012"><span class="cls_012">se nalazi baza podataka </span><span class="cls_014">Trafika </span><span class="cls_012">u kojoj se pored već kreirane </span><span class="cls_014">tblProizvod </span><span class="cls_012">nalaze i novokreirane</span></div>
<div style="position:absolute;left:72.02px;top:99.02px" class="cls_012"><span class="cls_012">tabele sa odgovarajućim atributima (</span><span class="cls_014">Slika 20</span><span class="cls_012">).</span></div>
<div style="position:absolute;left:201.29px;top:573.43px" class="cls_017"><span class="cls_017">Slika 20 - Object Explorer prikaz kreiranih tabela</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:14436px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background19.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.80px" class="cls_012"><span class="cls_012">Kao što se može videti na slici 12, u </span><span class="cls_014">tblProizvod </span><span class="cls_012">se nalaze tri </span><span class="cls_014">Foreign key</span><span class="cls_012">-a (</span><span class="cls_014">ProizvodjacID,</span></div>
<div style="position:absolute;left:72.02px;top:85.10px" class="cls_014"><span class="cls_014">VrstaProizvodaID </span><span class="cls_012">i </span><span class="cls_014">DobavljacID</span><span class="cls_012">). Prilikom unosa atributa u tabelu </span><span class="cls_014">tblProizvod </span><span class="cls_012">potrebno je uneti i</span></div>
<div style="position:absolute;left:72.02px;top:99.38px" class="cls_012"><span class="cls_012">atribute koji imaju nazive </span><span class="cls_014">ProizvodjacID, VrstaProizvodaID </span><span class="cls_012">i </span><span class="cls_014">DobavljacID, </span><span class="cls_012">a vrednost </span><span class="cls_014">DataType</span><span class="cls_012">-a</span></div>
<div style="position:absolute;left:72.02px;top:113.66px" class="cls_012"><span class="cls_012">za njih staviti na </span><span class="cls_019">int</span><span class="cls_012">. Zatim je potrebno kliknuti desnim klikom na crnu strelicu koja se nalazi pored</span></div>
<div style="position:absolute;left:72.02px;top:128.06px" class="cls_012"><span class="cls_012">naziva ove kolone. Otvoriće se lista u kojoj treba odabrati opciju </span><span class="cls_014">Relationships </span><span class="cls_012">(</span><span class="cls_014">Slika 21</span><span class="cls_012">)</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:240.53px;top:543.91px" class="cls_017"><span class="cls_017">Slika 21 - Dodavanje veza</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:15238px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background20.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_006"><span class="cls_006">Otvara se prozor </span><span class="cls_017">Foreign key Relationships </span><span class="cls_006">(</span><span class="cls_017">Slika 22)</span><span class="cls_006"> u kojem je potrebno prvo kliknuti na</span></div>
<div style="position:absolute;left:72.02px;top:86.42px" class="cls_006"><span class="cls_006">dugme </span><span class="cls_017">Add </span><span class="cls_006">a zatim proširiti polje </span><span class="cls_017">Tables and Columns Specification </span><span class="cls_006">i kliknuti na </span><span class="cls_017">tri tačke </span><span class="cls_006">koje</span></div>
<div style="position:absolute;left:72.02px;top:102.02px" class="cls_006"><span class="cls_006">se nalaze desno.</span></div>
<div style="position:absolute;left:234.65px;top:362.57px" class="cls_017"><span class="cls_017">Slika 22 - Dodavanje stranog ključa</span></div>
<div style="position:absolute;left:71.30px;top:413.95px" class="cls_012"><span class="cls_012">U otvorenom prozoru </span><span class="cls_014">Tables and Columns </span><span class="cls_012">potrebno je u okviru </span><span class="cls_014">Foreign key table, </span><span class="cls_012">konkretno iz</span></div>
<div style="position:absolute;left:71.78px;top:429.55px" class="cls_012"><span class="cls_012">tabele </span><span class="cls_014">tblProizvod, </span><span class="cls_012">iz padajuće liste izabrati atribut koji smo mi definisali a koji želimo da povežemo</span></div>
<div style="position:absolute;left:71.78px;top:445.15px" class="cls_012"><span class="cls_012">sa drugom tabelom. Zatim u okviru </span><span class="cls_014">Primary key table </span><span class="cls_012">biramo tabelu sa kojom vršimo povezivanje i</span></div>
<div style="position:absolute;left:71.78px;top:460.87px" class="cls_012"><span class="cls_012">iz padajuće liste biramo ključ te tabele sa kojim ćemo povezati željeni atribut. Nakon što smo sve</span></div>
<div style="position:absolute;left:71.78px;top:476.47px" class="cls_012"><span class="cls_012">ovo odradili, prozor treba da nam izgleda kao na sledećoj slici (</span><span class="cls_014">Slika 23</span><span class="cls_012">).</span></div>
<div style="position:absolute;left:234.05px;top:693.94px" class="cls_017"><span class="cls_017">Slika 23 - Kreiranje veza između tabela</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:16040px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background21.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_012"><span class="cls_012">Dodavanjem </span><span class="cls_014">relationships</span><span class="cls_012">-a atributima </span><span class="cls_014">ProizvodjacID, VrstaProizvodaID </span><span class="cls_012">i</span><span class="cls_014"> DobavljacID </span><span class="cls_012">u tabeli</span></div>
<div style="position:absolute;left:72.02px;top:86.54px" class="cls_014"><span class="cls_014">tblProizvod </span><span class="cls_012">oni postaju strani ključevi. Da li smo uspešno odradili povezivanje tabela znaćemo tako</span></div>
<div style="position:absolute;left:72.02px;top:102.26px" class="cls_012"><span class="cls_012">što ćemo proveriti da li se oni nalaze u </span><span class="cls_014">treeview</span><span class="cls_012">-u u okviru tabele </span><span class="cls_014">tblProizvod </span><span class="cls_012">pod kategorijom </span><span class="cls_014">Keys</span></div>
<div style="position:absolute;left:72.02px;top:117.38px" class="cls_012"><span class="cls_012">(</span><span class="cls_014">Slika 24</span><span class="cls_012">).</span></div>
<div style="position:absolute;left:198.77px;top:387.65px" class="cls_014"><span class="cls_014">Slika 24 - TreeView prikaz kreiranih ključeva</span></div>
<div style="position:absolute;left:72.02px;top:438.79px" class="cls_012"><span class="cls_012">Isti postupak potrebno je ponoviti za sve tabele koje u sebi sadrže strane ključeve koji su primarni</span></div>
<div style="position:absolute;left:72.02px;top:454.63px" class="cls_012"><span class="cls_012">ključevi u drugim tabelama, a to je u našem slučaju još tabela tblFiskalniRacun (</span><span class="cls_014">ProdavacID,</span></div>
<div style="position:absolute;left:72.02px;top:470.35px" class="cls_014"><span class="cls_014">ProizvodID, KupacID</span><span class="cls_012">).</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:16842px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background22.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.80px" class="cls_012"><span class="cls_012">Sada su tabele kreirane i povezane, a dodavanje novih podataka u ovu bazu se može izvršiti desnim</span></div>
<div style="position:absolute;left:72.02px;top:84.74px" class="cls_012"><span class="cls_012">klikom na naziv tabele, gde se iz liste opcija treba odabrati </span><span class="cls_013">Edit Top 200 Rows </span><span class="cls_014">(Slika 25</span><span class="cls_012">).</span></div>
<div style="position:absolute;left:186.89px;top:512.35px" class="cls_017"><span class="cls_017">Slika 25 - Prikaz kreirane tabele i dodavanje podataka</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:17644px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background23.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.58px" class="cls_003"><span class="cls_003">5. Kreiranje studentske WPF aplikacije (desktop</span></div>
<div style="position:absolute;left:72.02px;top:95.42px" class="cls_003"><span class="cls_003">aplikacije)</span></div>
<div style="position:absolute;left:71.30px;top:146.30px" class="cls_006"><span class="cls_006">U okviru ovog poglavlja objasniće se kako se kreira </span><span class="cls_015">WPF </span><span class="cls_006">(</span><span class="cls_017">Windows Presentation Foundation</span><span class="cls_006">)</span></div>
<div style="position:absolute;left:71.30px;top:161.78px" class="cls_006"><span class="cls_006">aplikacija. Nakon pokretanja </span><span class="cls_015">Visual Studija </span><span class="cls_006">potrebno je kliknuti na </span><span class="cls_017">File</span><span class="cls_006"> meni a zatim odabrati</span></div>
<div style="position:absolute;left:71.30px;top:177.14px" class="cls_017"><span class="cls_017">New Project (Slika 26).</span></div>
<div style="position:absolute;left:212.09px;top:581.38px" class="cls_014"><span class="cls_014">Slika 26 - Kreiranje novog projekta u Visual Studiju</span></div>
<div style="position:absolute;left:71.30px;top:637.18px" class="cls_006"><span class="cls_006">Odabrati </span><span class="cls_017">Windows Classic Desktop</span><span class="cls_006">, zatim </span><span class="cls_017">WPF Application</span><span class="cls_006">. Navesti ime aplikacije i kliknuti</span></div>
<div style="position:absolute;left:71.78px;top:652.78px" class="cls_015"><span class="cls_015">OK </span><span class="cls_006">(</span><span class="cls_017">Slika 27</span><span class="cls_006">).</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:18446px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background24.jpg" width=612 height=792></div>
<div style="position:absolute;left:221.81px;top:368.09px" class="cls_014"><span class="cls_014">Slika 27 - Kreiranje WPF aplikacije</span></div>
<div style="position:absolute;left:71.30px;top:397.85px" class="cls_006"><span class="cls_006">U </span><span class="cls_017">Solution Explorer</span><span class="cls_006">-u će se pojaviti napravljena aplikacija (</span><span class="cls_017">Slika 28</span><span class="cls_006">).</span></div>
<div style="position:absolute;left:176.93px;top:656.98px" class="cls_017"><span class="cls_017">Slika 28 - Solution Explorer kreirane WPF aplikacije</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:19248px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background25.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_006"><span class="cls_006">Sledeći korak je kreiranje konekcije u aplikaciji, ka bazi podataka. Za početak, kreira se klasa u</span></div>
<div style="position:absolute;left:72.02px;top:86.42px" class="cls_006"><span class="cls_006">kojoj će se nalaziti statička metoda putem koje će se ostvarivati veza na prethodno kreiranu</span></div>
<div style="position:absolute;left:72.02px;top:102.02px" class="cls_006"><span class="cls_006">bazu. Klasa se kreira desnim klikom na naziv projekta (</span><span class="cls_017">Trafika</span><span class="cls_006">), a zatim </span><span class="cls_017">Add / Class... (Slika</span></div>
<div style="position:absolute;left:72.02px;top:117.50px" class="cls_017"><span class="cls_017">29).</span></div>
<div style="position:absolute;left:263.33px;top:459.67px" class="cls_017"><span class="cls_017">Slika 29 - Kreiranje klase</span></div>
<div style="position:absolute;left:71.30px;top:511.27px" class="cls_006"><span class="cls_006">Novokreiranoj klasi se dodeljuje naziv “</span><span class="cls_017">Konekcija” </span><span class="cls_006">i njen sadržaj prikazan je na </span><span class="cls_017">Slici 30</span><span class="cls_006">. Na</span></div>
<div style="position:absolute;left:71.30px;top:526.87px" class="cls_006"><span class="cls_006">samom početku uključujemo imenski prostor </span><span class="cls_017">System.Data.SqlClient</span><span class="cls_006">. Telo klase sadrži samo</span></div>
<div style="position:absolute;left:71.30px;top:542.35px" class="cls_006"><span class="cls_006">jednu statičku metodu pod nazivom “</span><span class="cls_017">KreirajKonekciju</span><span class="cls_006">”, koja će se u kasnijem razvoju</span></div>
<div style="position:absolute;left:71.30px;top:557.83px" class="cls_006"><span class="cls_006">aplikacije pozivati po potrebi odnosno svaki put kada budemo želeli da ostvarimo vezu sa</span></div>
<div style="position:absolute;left:71.30px;top:573.43px" class="cls_006"><span class="cls_006">bazom podataka, stoga je povratni tip ove metode instanca klase </span><span class="cls_017">SqlConnection</span><span class="cls_006">. Unutar same</span></div>
<div style="position:absolute;left:71.30px;top:588.94px" class="cls_006"><span class="cls_006">metode prikazana su podešavanja parametara konekcije i to:</span></div>
<div style="position:absolute;left:72.02px;top:622.78px" class="cls_006"><span class="cls_006">• DataSource - naziv servera na kojem je baza podataka smeštena.</span></div>
<div style="position:absolute;left:72.02px;top:650.38px" class="cls_006"><span class="cls_006">• InitialCatalog - naziv baze podataka kojoj želimo da pristupimo.</span></div>
<div style="position:absolute;left:72.02px;top:677.50px" class="cls_006"><span class="cls_006">• IntegratedSecurity - ukoliko se baza nalazi na lokalnoj mašini ovaj parametar postavljamo</span></div>
<div style="position:absolute;left:85.10px;top:692.98px" class="cls_006"><span class="cls_006">na true.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:20050px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background26.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:70.92px" class="cls_006"><span class="cls_006">Nakon podešavanja ovih parametara, ceo string prosleđujemo instanci klase </span><span class="cls_017">SqlConnection</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:255.65px;top:378.41px" class="cls_017"><span class="cls_017">Slika 30 - Klasa Konekcija</span></div>
<div style="position:absolute;left:75.02px;top:418.87px" class="cls_006"><span class="cls_006">Sledeći korak u izradi aplikacije biće kreiranje </span><span class="cls_015">formi</span><span class="cls_006"> za dodavanje objekata u bazu podataka.</span></div>
<div style="position:absolute;left:72.02px;top:433.75px" class="cls_006"><span class="cls_006">Kako bi sve forme bile uredno smeštene na jednom mestu, potrebno je kreirati folder pod</span></div>
<div style="position:absolute;left:72.02px;top:448.63px" class="cls_006"><span class="cls_006">nazivom </span><span class="cls_017">Forme</span><span class="cls_006"> u kom će se nalaziti svih 7 formi za, prethodno kreiranih, 7 tabela u bazi</span></div>
<div style="position:absolute;left:72.02px;top:463.51px" class="cls_006"><span class="cls_006">podataka. Kreiranje foldera se vrši na sličan način kao kreiranje klase, desnim klikom na</span></div>
<div style="position:absolute;left:72.02px;top:478.27px" class="cls_006"><span class="cls_006">projekat, a zatim </span><span class="cls_017">Add/ New Folder</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:225.05px;top:704.98px" class="cls_017"><span class="cls_017">Slika 31 - Kreiranje novog foldera</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:20852px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background27.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_006"><span class="cls_006">Nakon kreiranja foldera, potrebno je dodati novi prozor za svaku od formi. WPF prozor, unutar</span></div>
<div style="position:absolute;left:72.02px;top:86.42px" class="cls_006"><span class="cls_006">folder, kreira se desnim klikom na folder, a zatim </span><span class="cls_017">Add/Window (Slika 32).</span></div>
<div style="position:absolute;left:231.77px;top:514.15px" class="cls_017"><span class="cls_017">Slika 32 - Dodavanje formi unutar foldera</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:21654px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background28.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_006"><span class="cls_006">Nakon toga prikazaće se prozor da dodavanje novog </span><span class="cls_017">Item</span><span class="cls_006">-a unutar kog je potrebno podesiti</span></div>
<div style="position:absolute;left:72.02px;top:86.42px" class="cls_006"><span class="cls_006">naziv i zatim kliknuti na </span><span class="cls_017">Add (Slika 33)</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:215.93px;top:429.91px" class="cls_017"><span class="cls_017">Slika 33 - Dodavanje novog prozora</span></div>
<div style="position:absolute;left:72.02px;top:455.47px" class="cls_006"><span class="cls_006">Kada je novi prozor izgenerisan, potrebno je, unutar njega, dodati određene elemente putem</span></div>
<div style="position:absolute;left:72.02px;top:470.95px" class="cls_006"><span class="cls_006">kojih će se ostvarivati potrebne funkcionalnosti. Na levoj strani prozora, klikom na </span><span class="cls_017">Toolbox</span><span class="cls_006">,</span></div>
<div style="position:absolute;left:72.02px;top:486.55px" class="cls_006"><span class="cls_006">prikazaće se lista svih ugrađenih </span><span class="cls_015">WPF komandi </span><span class="cls_006">(</span><span class="cls_017">Slika 34</span><span class="cls_006">). Jednostavnim prevlačenjem tih</span></div>
<div style="position:absolute;left:72.02px;top:502.03px" class="cls_006"><span class="cls_006">komandi na centralni prozor, izgenerisaće se kod u </span><span class="cls_015">XAML</span><span class="cls_006"> deklarativnom jeziku unutar kojeg</span></div>
<div style="position:absolute;left:72.02px;top:517.63px" class="cls_006"><span class="cls_006">će se vršiti detaljna podešavanja svih komandi unutar prozora (</span><span class="cls_017">Slika 35).</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:22456px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background29.jpg" width=612 height=792></div>
<div style="position:absolute;left:221.33px;top:470.11px" class="cls_017"><span class="cls_017">Slika 34 - Dodavanje komandi iz Toolbox-a</span></div>
<div style="position:absolute;left:71.30px;top:523.15px" class="cls_006"><span class="cls_006">Forma za dodavanje novog </span><span class="cls_017">Prodavca</span><span class="cls_006"> u bazu podataka, treba da sadrži sledeće elemente (</span><span class="cls_017">Slika</span></div>
<div style="position:absolute;left:71.78px;top:538.75px" class="cls_017"><span class="cls_017">34). </span><span class="cls_006">Dva osnovna </span><span class="cls_017">TextBox</span><span class="cls_006">-ova unutar kojih će biti upisane vrednosti obeležja. Takođe, uz svaki</span></div>
<div style="position:absolute;left:71.78px;top:554.23px" class="cls_017"><span class="cls_017">TextBox</span><span class="cls_006">, mora postojati naziv (</span><span class="cls_017">Label</span><span class="cls_006">) koji će opisivati njegovu namenu. Na kraju, svaka forma</span></div>
<div style="position:absolute;left:71.78px;top:569.83px" class="cls_006"><span class="cls_006">morati imati ugrađeno dugme </span><span class="cls_018">Sačuvaj</span><span class="cls_006">, putem kojih će se vrednosti upisivati u bazu, i dugme</span></div>
<div style="position:absolute;left:71.78px;top:585.34px" class="cls_018"><span class="cls_018">Otkaži</span><span class="cls_006"> - koje korisniku omogućava zatvaranje forme (</span><span class="cls_017">Slika 35</span><span class="cls_006">). Ove funkcionalnosti dugmića</span></div>
<div style="position:absolute;left:71.78px;top:600.82px" class="cls_006"><span class="cls_006">postižu se klikom miša na odgovarajuće dugme čime se u </span><span class="cls_017">Code Behind</span><span class="cls_006">-u generišu metode</span></div>
<div style="position:absolute;left:71.78px;top:616.42px" class="cls_017"><span class="cls_017">btnSacuvaj_Click </span><span class="cls_006"> i </span><span class="cls_017">btnZatvori.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:23258px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background30.jpg" width=612 height=792></div>
<div style="position:absolute;left:222.41px;top:283.61px" class="cls_017"><span class="cls_017">Slika 35 - XAML kod kreiranih komponenti</span></div>
<div style="position:absolute;left:71.30px;top:350.33px" class="cls_006"><span class="cls_006">Vizuelni prikaz forme za unos novog </span><span class="cls_017">Prodavca</span><span class="cls_006">, izgledaće kao na </span><span class="cls_017">Slici 36</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:204.77px;top:566.95px" class="cls_017"><span class="cls_017">Slika 36 - Vizuelni prikaz forme za dodavanje novog proizvoda</span></div>
<div style="position:absolute;left:71.30px;top:620.14px" class="cls_006"><span class="cls_006">U </span><span class="cls_017">Code Behind</span><span class="cls_006">-u ove forme, trebalo bi da se nalazi sledeća poslovna logika (</span><span class="cls_017">Slika 37</span><span class="cls_006">). Najpre je</span></div>
<div style="position:absolute;left:71.78px;top:635.62px" class="cls_006"><span class="cls_006">potrebno importovati imenski prostor </span><span class="cls_017">System.Data.SqlClient</span><span class="cls_006">. Zatim, potrebno je napraviti novi</span></div>
<div style="position:absolute;left:71.78px;top:651.22px" class="cls_006"><span class="cls_006">objekat </span><span class="cls_017">SqlConnection</span><span class="cls_006"> klase, putem kojeg će se ostvarivati veza ka bazi podataka nakon klika na</span></div>
<div style="position:absolute;left:71.78px;top:666.70px" class="cls_006"><span class="cls_006">dugme </span><span class="cls_017">Sačuvaj</span><span class="cls_006">. Takođe, u konstruktoru ovog prozora poželjno je podesiti metodu </span><span class="cls_017">Focus()</span><span class="cls_006">, koja</span></div>
<div style="position:absolute;left:71.78px;top:682.18px" class="cls_006"><span class="cls_006">pozicionira kursor na prvo polje koje korisnik popunjava pri pokretanju forme. U slučaju</span></div>
<div style="position:absolute;left:71.78px;top:697.78px" class="cls_006"><span class="cls_006">prodavca to je tekst polje za unos njegovog </span><span class="cls_017">Username - a</span><span class="cls_006">.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:24060px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background31.jpg" width=612 height=792></div>
<div style="position:absolute;left:202.85px;top:429.67px" class="cls_017"><span class="cls_017">Slika 37 - Sadržaj CodeBehind-a forme frmProdavac</span></div>
<div style="position:absolute;left:71.30px;top:481.03px" class="cls_006"><span class="cls_006">Ovakav prikaz pozadinskog koda gotovo je identičan za svaku od 7 kreiranih formi. Ono u čemu</span></div>
<div style="position:absolute;left:71.30px;top:496.51px" class="cls_006"><span class="cls_006">je svaka od ovih formi jedinstvena jeste pozadinska funkcionalnost koja se dešava u trenutku</span></div>
<div style="position:absolute;left:71.30px;top:511.99px" class="cls_006"><span class="cls_006">kada korisnik klikne na dugme </span><span class="cls_017">Sačuvaj</span><span class="cls_006">. Na</span><span class="cls_017"> Slici 38 </span><span class="cls_006">prikazan je sadržaj izgenerisane metode</span></div>
<div style="position:absolute;left:71.30px;top:527.59px" class="cls_017"><span class="cls_017">btn_Sacuvaj_Click </span><span class="cls_006">. Na samom početku, potrebno je otvoriti konekciju ka bazi podataka. Zatim,</span></div>
<div style="position:absolute;left:71.30px;top:543.07px" class="cls_006"><span class="cls_006">kreira se string koji u sebi sadrži </span><span class="cls_017">insert into </span><span class="cls_006">naredbu putem koje se dodaje nove objekat u bazu</span></div>
<div style="position:absolute;left:71.30px;top:558.55px" class="cls_006"><span class="cls_006">podataka. U </span><span class="cls_017">values </span><span class="cls_006">ove naredbe prosledjuju se pokupljene unete vrednosti iz </span><span class="cls_017">TextBox</span><span class="cls_006">-ova ove</span></div>
<div style="position:absolute;left:71.30px;top:574.15px" class="cls_006"><span class="cls_006">forme. Potrebno je voditi računa da se vrednosti stringova ograde apostrofima. Nakon upešno</span></div>
<div style="position:absolute;left:71.30px;top:589.66px" class="cls_006"><span class="cls_006">napravljene </span><span class="cls_017">insert</span><span class="cls_006"> komande, ovaj string se prosleđuje objektu klase </span><span class="cls_017">SqlCommand</span><span class="cls_006">. Ovaj objekat,</span></div>
<div style="position:absolute;left:71.30px;top:605.14px" class="cls_006"><span class="cls_006">kao parametre prima prethodno kreirani string ali i konekciju putem koje će znati u koju bazu</span></div>
<div style="position:absolute;left:71.30px;top:620.74px" class="cls_006"><span class="cls_006">podataka treba da upiše prosleđeni zapis. Nakon toga, komanda se izvršava putem metode</span></div>
<div style="position:absolute;left:71.30px;top:636.22px" class="cls_017"><span class="cls_017">ExecuteNonQuery()</span><span class="cls_006">, nakon čega se prozor zatvara. Ovaj deo koda potrebno je ograditi </span><span class="cls_017">try</span></div>
<div style="position:absolute;left:71.30px;top:651.82px" class="cls_006"><span class="cls_006">blokom iz razloga što postoji mogućnost nastanka greške usled prosleđivanja unosa pogrešnog</span></div>
<div style="position:absolute;left:71.30px;top:667.30px" class="cls_006"><span class="cls_006">tipa podatka od strane korisnika. Kako prilikom ovakvog unosa, program ne bi </span><span class="cls_015">“pukao”</span><span class="cls_006">,</span></div>
<div style="position:absolute;left:71.30px;top:682.78px" class="cls_006"><span class="cls_006">potrebno je dodati catch blok unutar kojeg će se “hvatati” izuzetak tipa </span><span class="cls_017">SqlException</span><span class="cls_006">. Na kraju,</span></div>
<div style="position:absolute;left:71.30px;top:698.38px" class="cls_006"><span class="cls_006">u finally bloku, potrebno je postarati se da se prethodno otvorena konekcija sigurno zatvori.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:24862px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background32.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:70.92px" class="cls_006"><span class="cls_006">Ukoliko konekcija ostane otvorena, niko drugi neće moći da pristupi bazi podataka na isti način</span></div>
<div style="position:absolute;left:71.30px;top:86.30px" class="cls_006"><span class="cls_006">dok se ova instanca konekcije ne zatvori.</span></div>
<div style="position:absolute;left:170.06px;top:387.77px" class="cls_017"><span class="cls_017">Slika 38 - Sadržaj metode btnSacuvaj_Click za insert novog prodavca</span></div>
<div style="position:absolute;left:71.30px;top:441.19px" class="cls_006"><span class="cls_006">U nastavku će biti prikazan izgled i kod ostalih 6 formi.</span></div>
<div style="position:absolute;left:71.30px;top:466.99px" class="cls_006"><span class="cls_006">Izgled formi za dodavanje kupca, vrste proizvoda, proizvođača i dobavljaća takođe ima veoma</span></div>
<div style="position:absolute;left:71.78px;top:482.59px" class="cls_006"><span class="cls_006">sličan dizajn (</span><span class="cls_017">Slika 39., Slika 40., Slika 41, Slika 42, Slika 43).</span></div>
<div style="position:absolute;left:249.05px;top:687.46px" class="cls_017"><span class="cls_017">Slika 39 - Dizajn forme za dodavanje kupca</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:25664px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background33.jpg" width=612 height=792></div>
<div style="position:absolute;left:219.05px;top:269.45px" class="cls_017"><span class="cls_017">Slika 40 - Dizajn forme za dodavanje nove vrste proizvoda</span></div>
<div style="position:absolute;left:234.05px;top:528.19px" class="cls_017"><span class="cls_017">Slika 41 - Dizajn forme za dodavanje novog proizvođača</span></div>
<div style="position:absolute;left:237.05px;top:704.62px" class="cls_017"><span class="cls_017">Slika 42 - Dizajn forme za dodavanje novog dobavljača</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:26466px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background34.jpg" width=612 height=792></div>
<div style="position:absolute;left:200.81px;top:307.85px" class="cls_017"><span class="cls_017">Slika 43 - XAML kod forme za dodavanje novog kupca</span></div>
<div style="position:absolute;left:164.18px;top:595.06px" class="cls_017"><span class="cls_017">Slika 42 - XAML kod forme za dodavanje nove vrste proizvoda</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:27268px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background35.jpg" width=612 height=792></div>
<div style="position:absolute;left:184.01px;top:311.57px" class="cls_017"><span class="cls_017">Slika 43 - XAML kod forme za dodavanje novog proizvođača</span></div>
<div style="position:absolute;left:170.30px;top:599.74px" class="cls_017"><span class="cls_017">Slika 44 - XAML kod forme za dodavanje novog dobavljača</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:28070px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background36.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:70.92px" class="cls_006"><span class="cls_006">Razlika se ponovo ogleda u </span><span class="cls_017">insert</span><span class="cls_006"> upitu, smeštenom unutar metode </span><span class="cls_017">Sačuvaj</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:172.46px;top:375.17px" class="cls_017"><span class="cls_017">Slika 45 - Sadržaj metode btnSacuvaj_Click za insert novog kupca</span></div>
<div style="position:absolute;left:149.90px;top:645.94px" class="cls_017"><span class="cls_017">Slika 46 - Sadržaj metode btnSacuvaj_Click za insert nove vrste proizvoda</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:28872px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background37.jpg" width=612 height=792></div>
<div style="position:absolute;left:157.10px;top:301.25px" class="cls_017"><span class="cls_017">Slika 47 - Sadržaj metode btnSacuvaj_Click za insert novog proizvođača</span></div>
<div style="position:absolute;left:163.10px;top:558.91px" class="cls_017"><span class="cls_017">Slika 48 - Sadržaj metode btnSacuvaj_Click za insert novog dobavljača</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:29674px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background38.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:70.80px" class="cls_006"><span class="cls_006">Tabele </span><span class="cls_017">tblProizvod i tblFiskalniRacun</span><span class="cls_006"> u sebi sadrže strane ključeve drugih tabela na osnovu</span></div>
<div style="position:absolute;left:71.30px;top:87.38px" class="cls_006"><span class="cls_006">kojih se pristupa sadržajima tih tabela. U samoj aplikaciji, potrebno je korisniku obezbediti</span></div>
<div style="position:absolute;left:71.30px;top:103.94px" class="cls_006"><span class="cls_006">vizuelni prikaz željenih obeležja neke od povezanih tabela. U WPF tehnologiji to se</span></div>
<div style="position:absolute;left:71.30px;top:120.50px" class="cls_006"><span class="cls_006">najjednostavniji način postiže korišćenjem </span><span class="cls_017">ComboBox</span><span class="cls_006">-a. Vizuelni prikaz forme za dodavanje</span></div>
<div style="position:absolute;left:71.30px;top:137.18px" class="cls_006"><span class="cls_006">novog proizvoda prikazan je na </span><span class="cls_017">Slici 49</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:193.49px;top:498.79px" class="cls_017"><span class="cls_017">Slika 49 - Vizuelni prikaz forme za dodavanje novog proizvoda</span></div>
<div style="position:absolute;left:71.30px;top:539.59px" class="cls_006"><span class="cls_006">XAML kod ove forme prikazan je na </span><span class="cls_017">Slici 50</span><span class="cls_006">. Prilikom kreiranje novog </span><span class="cls_017">ComboBox</span><span class="cls_006">-a, potrebno</span></div>
<div style="position:absolute;left:71.78px;top:555.19px" class="cls_006"><span class="cls_006">je da definišemo </span><span class="cls_017">DisplayMemberPath, </span><span class="cls_006">koji predstavlja obeležje povezane tabele koje će se</span></div>
<div style="position:absolute;left:71.78px;top:570.67px" class="cls_006"><span class="cls_006">prikazati u padajućoj listi kada korisnik klikne na taj </span><span class="cls_017">ComboBox</span><span class="cls_006">, kao i </span><span class="cls_017">SelectedValuePath </span><span class="cls_006">koji</span></div>
<div style="position:absolute;left:71.78px;top:586.18px" class="cls_006"><span class="cls_006">predstavlja obeležje primarnog ključa na osnovu kog će se uneta vrednost iz prikazanog</span></div>
<div style="position:absolute;left:71.78px;top:601.78px" class="cls_017"><span class="cls_017">ComboBox</span><span class="cls_006">-a povezati sa svojim identifikacionim obeležjem i kao takva proslediti u bazu</span></div>
<div style="position:absolute;left:71.78px;top:617.26px" class="cls_006"><span class="cls_006">podataka.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:30476px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background39.jpg" width=612 height=792></div>
<div style="position:absolute;left:185.93px;top:397.13px" class="cls_017"><span class="cls_017">Slika 50 - XAML kod forme za dodavanje novog proizvoda</span></div>
<div style="position:absolute;left:107.30px;top:450.31px" class="cls_017"><span class="cls_017">CodeBehind</span><span class="cls_006"> formi koje u sebi sadrže </span><span class="cls_017">ComboBox</span><span class="cls_006">-ove razlikovaće se od ostalih. U</span></div>
<div style="position:absolute;left:71.30px;top:465.67px" class="cls_006"><span class="cls_006">nastavku sagledaćemo svrhu i sadržaj označenog </span><span class="cls_017">try</span><span class="cls_006"> bloka u konstruktoru ove klase </span><span class="cls_017">(Slika 51).</span></div>
<div style="position:absolute;left:195.17px;top:704.26px" class="cls_017"><span class="cls_017">Slika 51 - Sadržaj CodeBehind-a forme frmProizvod</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:31278px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background40.jpg" width=612 height=792></div>
<div style="position:absolute;left:108.02px;top:88.22px" class="cls_017"><span class="cls_017">Try</span><span class="cls_006"> blok prikazan na </span><span class="cls_017">Slici 52</span><span class="cls_006">, smešten je unutar konstruktora ove klase s obzirom da se,</span></div>
<div style="position:absolute;left:72.02px;top:103.70px" class="cls_006"><span class="cls_006">pri instanciranju novog prozora ove forme, podaci koji će biti prikazani u </span><span class="cls_017">ComboBox</span><span class="cls_006">-ovima</span></div>
<div style="position:absolute;left:72.02px;top:119.30px" class="cls_006"><span class="cls_006">moraju negde privremeno uskladištiti. Za postizanje toga, koristi se objekat </span><span class="cls_017">DataTable</span><span class="cls_006"> klase</span></div>
<div style="position:absolute;left:72.02px;top:134.78px" class="cls_006"><span class="cls_006">koji predstavlja kopiju tabele iz baze podataka (sa obeležjima koja se proslede unutar </span><span class="cls_017">select</span></div>
<div style="position:absolute;left:72.02px;top:150.26px" class="cls_006"><span class="cls_006">upita), sačuvanu u memoriji aplikacije. Objekat klase </span><span class="cls_017">DataTable</span><span class="cls_006"> se popunjava pomoću objekta</span></div>
<div style="position:absolute;left:72.02px;top:165.86px" class="cls_006"><span class="cls_006">klase </span><span class="cls_017">SqlDataAdapter </span><span class="cls_006">kojem prosleđujemo odgovarajući </span><span class="cls_017">select</span><span class="cls_006"> upit kao i konekciju ka</span></div>
<div style="position:absolute;left:72.02px;top:181.34px" class="cls_006"><span class="cls_006">odgovarajućoj bazi podataka. Zatim se taj </span><span class="cls_017">DataTable</span><span class="cls_006"> postavlja kao </span><span class="cls_017">ItemsSource</span><span class="cls_006"> za odgovarajući</span></div>
<div style="position:absolute;left:72.02px;top:196.82px" class="cls_017"><span class="cls_017">ComboBox</span><span class="cls_006">. Na samom kraju, u </span><span class="cls_017">finally</span><span class="cls_006"> bloku, potrebno je obezbediti da se konekcija ka bazi</span></div>
<div style="position:absolute;left:72.02px;top:212.30px" class="cls_006"><span class="cls_006">bezbedno zatvori.</span></div>
<div style="position:absolute;left:144.62px;top:602.62px" class="cls_017"><span class="cls_017">Slika 52 - Sadržaj try - finally bloka unutar konstruktora forme frmProizvod</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:32080px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background41.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:70.92px" class="cls_006"><span class="cls_006">Sadržaj metode koja se aktivira na klik dugmeta </span><span class="cls_018">Sačuvaj</span><span class="cls_006">, sličan je kao i u prethodnim formama</span></div>
<div style="position:absolute;left:71.78px;top:86.42px" class="cls_006"><span class="cls_006">s tim što se za razliku od tekstualnih polja, vrednost iz ComboBox-a kupi pomoću </span><span class="cls_017">property</span><span class="cls_006">-ja</span></div>
<div style="position:absolute;left:71.78px;top:102.02px" class="cls_017"><span class="cls_017">SelectedValue</span><span class="cls_006"> (</span><span class="cls_017">Slika 53).</span></div>
<div style="position:absolute;left:134.30px;top:431.71px" class="cls_017"><span class="cls_017">Slika 53 - Sadržaj metode btnSacuvaj_Click za insert novog proizvoda</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:32882px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background42.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:87.38px" class="cls_006"><span class="cls_006">Poslednja forma koju je potrebno kreirati je forma za dodavanje novog </span><span class="cls_017">Fiskalnog računa </span><span class="cls_006">u bazu</span></div>
<div style="position:absolute;left:71.78px;top:102.86px" class="cls_006"><span class="cls_006">podataka, koja je veoma slična formi za dodavanje novog </span><span class="cls_017">Proizvoda</span><span class="cls_006">. Na </span><span class="cls_017">Slici 54</span><span class="cls_006">. prikazan je</span></div>
<div style="position:absolute;left:71.78px;top:118.46px" class="cls_006"><span class="cls_006">njen sadržaj koji se sastoji od po četiri </span><span class="cls_017">TextBox</span><span class="cls_006">-a i tri </span><span class="cls_017">ComboBoxa</span><span class="cls_006">, i jednog </span><span class="cls_017">DatePicker</span><span class="cls_006">- a.</span></div>
<div style="position:absolute;left:71.78px;top:133.82px" class="cls_006"><span class="cls_006">XAML kod ove forme prikazan je na </span><span class="cls_017">Slici 55</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:155.30px;top:585.22px" class="cls_017"><span class="cls_017">Slika 54 - Vizuelni prikaz forme za dodavanje novog fiskalnog računa</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:33684px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background43.jpg" width=612 height=792></div>
<div style="position:absolute;left:163.82px;top:371.45px" class="cls_017"><span class="cls_017">Slika 55 - XAML kod forme za dodavanje novo fiskalnog računa</span></div>
<div style="position:absolute;left:71.30px;top:424.75px" class="cls_006"><span class="cls_006">Konstruktor ove forme, prikazan na </span><span class="cls_017">Slici 56</span><span class="cls_006">, u sebi sadrži tri </span><span class="cls_017">DataTable</span><span class="cls_006">-a, koji snabdevaju</span></div>
<div style="position:absolute;left:71.78px;top:440.23px" class="cls_006"><span class="cls_006">podacima tri </span><span class="cls_017">ComboBox</span><span class="cls_006">-a.</span></div>
<div style="position:absolute;left:156.02px;top:704.74px" class="cls_017"><span class="cls_017">Slika 56 - Konstruktor forme za dodavanje novog fiskalnog računa</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:34486px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background44.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:85.82px" class="cls_006"><span class="cls_006">Metoda za čuvanje zapisa, odnosno njegovo prosleđivanje u bazu podataka, funkcioniše na</span></div>
<div style="position:absolute;left:72.50px;top:101.30px" class="cls_006"><span class="cls_006">identintičan način kao i kod prethodnih formi, s’tim što se vrednost izabrana vrednost datuma iz</span></div>
<div style="position:absolute;left:72.50px;top:116.90px" class="cls_006"><span class="cls_006">komande </span><span class="cls_017">DatePicker</span><span class="cls_006"> ubacuje u select komandu pomoću </span><span class="cls_017">property</span><span class="cls_006">-ja </span><span class="cls_017">SelectedDate</span><span class="cls_006"> (</span><span class="cls_017">Slika 57).</span></div>
<div style="position:absolute;left:123.02px;top:430.63px" class="cls_017"><span class="cls_017">Slika 57 - Sadržaj metode btnSacuvaj_Click za dodavanje novog fiskalnog računa</span></div>
<div style="position:absolute;left:72.02px;top:499.39px" class="cls_006"><span class="cls_006">Nakon kreiranja formi za svaku od tabela, potrebno je nešto slično napraviti i za glavni (</span><span class="cls_017">Main</span><span class="cls_006">)</span></div>
<div style="position:absolute;left:72.02px;top:514.99px" class="cls_006"><span class="cls_006">prozor. Main prozor predstavlja prvi, inicijalni, kontakt korisnika sa aplikacijom i ujedno i bazni</span></div>
<div style="position:absolute;left:72.02px;top:530.47px" class="cls_006"><span class="cls_006">prozor iz kojeg će se otvarati prethodno kreirane forme i u koji će se korisnik vraćati nakon</span></div>
<div style="position:absolute;left:72.02px;top:545.95px" class="cls_006"><span class="cls_006">zatvaranja tih formi. Na njemu bi trebalo da se nalazi dugme za svaku od 7 kreiranih tabela u</span></div>
<div style="position:absolute;left:72.02px;top:561.55px" class="cls_006"><span class="cls_006">bazi, čijim će se klikom, na sredini forme iščitavati ti podaci. Takođe, klikom na dugme</span></div>
<div style="position:absolute;left:72.02px;top:577.06px" class="cls_006"><span class="cls_006">određene tabele, potrebno je da se korisniku obezbede dugmići za </span><span class="cls_017">Dodavanje</span><span class="cls_006">, </span><span class="cls_017">Izmenu</span><span class="cls_006"> i </span><span class="cls_017">Brisanje</span></div>
<div style="position:absolute;left:72.02px;top:592.54px" class="cls_006"><span class="cls_006">prikazanog sadržaja. Dodavanjem odgovarajućih funkcionalnosti tim dugmićima u okviru</span></div>
<div style="position:absolute;left:72.02px;top:608.14px" class="cls_006"><span class="cls_006">glavne forme, obezbediće se izvršavanje osnovnih CRUD operacija, što je i bio cilj ovog</span></div>
<div style="position:absolute;left:72.02px;top:623.62px" class="cls_006"><span class="cls_006">zadatka. Prikaz izgleda ove forme vidimo na </span><span class="cls_017">Slici 58</span><span class="cls_006">.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:35288px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background45.jpg" width=612 height=792></div>
<div style="position:absolute;left:211.97px;top:345.53px" class="cls_017"><span class="cls_017">Slika 58 - Vizuelni prikaz glavnog prozora</span></div>
<div style="position:absolute;left:71.30px;top:397.85px" class="cls_006"><span class="cls_006">U nastavku, bliže ćemo sagledati XAML kod ove forme.</span></div>
<div style="position:absolute;left:71.30px;top:425.83px" class="cls_006"><span class="cls_006">Na samom početku, potrebno je definisati centralni </span><span class="cls_017">DataGrid </span><span class="cls_006">u okviru kojeg će biti ispisani</span></div>
<div style="position:absolute;left:71.78px;top:441.31px" class="cls_006"><span class="cls_006">učitani podaci iz baze. Podešavanja ovog grida takođe su prikazana u okviru </span><span class="cls_017">Slike 59</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:208.85px;top:700.90px" class="cls_017"><span class="cls_017">Slika 59 - XAML kod centralnog grid-a</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:36090px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background46.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:96.50px" class="cls_006"><span class="cls_006">Kako bi elementi unutar ovog prozora bili uredno raspoređeni, koristiće se poseban panel za</span></div>
<div style="position:absolute;left:71.78px;top:112.10px" class="cls_006"><span class="cls_006">njihovo smeštanje - </span><span class="cls_017">StackPanel</span><span class="cls_006">. U okviru gornjeg </span><span class="cls_017">StackPanel</span><span class="cls_006">-a (Slika 60.), biće smešteni</span></div>
<div style="position:absolute;left:71.78px;top:127.58px" class="cls_006"><span class="cls_006">dugmići za izlistavanje tabela na centralnom gridu. Potrebno je podesiti poravnanja kao što je</span></div>
<div style="position:absolute;left:71.78px;top:143.06px" class="cls_006"><span class="cls_006">prikazano na slici, a zatim izgenerisati metode koje će sprovoditi odgovarajuće akcije klikom na</span></div>
<div style="position:absolute;left:71.78px;top:158.66px" class="cls_006"><span class="cls_006">to dugme, a čija će implementacija biti dodata nešto kasnije.</span></div>
<div style="position:absolute;left:196.13px;top:398.45px" class="cls_017"><span class="cls_017">Slika 60 - Gornji StackPanel glavnog prozora</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:36892px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background47.jpg" width=612 height=792></div>
<div style="position:absolute;left:219.05px;top:398.33px" class="cls_017"><span class="cls_017">Slika 61 - Donji StackPanel glavnog prozora</span></div>
<div style="position:absolute;left:71.30px;top:439.15px" class="cls_006"><span class="cls_006">Na </span><span class="cls_017">Slici 61</span><span class="cls_006">, vidimo prikaz donjeg </span><span class="cls_017">StackPanel</span><span class="cls_006">-a u okviru kog su kreirani dugmići za </span><span class="cls_017">Dodavanje</span><span class="cls_006">,</span></div>
<div style="position:absolute;left:71.78px;top:454.63px" class="cls_017"><span class="cls_017">Izmenu</span><span class="cls_006"> i </span><span class="cls_017">Brisanje</span><span class="cls_006"> zapisa iz svake od posebnih tabela, i za svaki od dugmića kreirana je metoda</span></div>
<div style="position:absolute;left:71.78px;top:470.23px" class="cls_006"><span class="cls_006">koja će obavljati neku funkcionalnost klikom na to dugme. Prilikom kreiranja ovog</span></div>
<div style="position:absolute;left:71.78px;top:485.71px" class="cls_017"><span class="cls_017">StackPanela</span><span class="cls_006">, potrebno je obratiti pažnju na širinu i visinu </span><span class="cls_017">Panel</span><span class="cls_006">-a ali i svakog posebnog dumeta.</span></div>
<div style="position:absolute;left:71.78px;top:501.31px" class="cls_006"><span class="cls_006">U okviru širine </span><span class="cls_017">StackPanel</span><span class="cls_006">-a, potrebno je da se nađu tačno tri dugmeta za odgovarajuću formu.</span></div>
<div style="position:absolute;left:71.78px;top:516.79px" class="cls_006"><span class="cls_006">Takođe, visina </span><span class="cls_017">StackPanel</span><span class="cls_006">-a treba da bude jednaka visini dugmeta. Na ovaj način, dugmići će</span></div>
<div style="position:absolute;left:71.78px;top:532.27px" class="cls_006"><span class="cls_006">biti preklopljeni jedni preko drugih i kasnije će se prikazivati u zavisnosti od toga koje nam je</span></div>
<div style="position:absolute;left:71.78px;top:547.87px" class="cls_006"><span class="cls_006">dugme potrebno. Naravno, ovo je samo jedno od dizajerskih rešenja za ovakav raspored</span></div>
<div style="position:absolute;left:71.78px;top:563.35px" class="cls_006"><span class="cls_006">dugmića i nije nužno pridržavati se istog prilikom kreiranja i rasporeda ovih komponenti u</span></div>
<div style="position:absolute;left:71.78px;top:578.86px" class="cls_006"><span class="cls_006">XAML kodu.</span></div>
<div style="position:absolute;left:71.30px;top:610.42px" class="cls_006"><span class="cls_006">U nastavku će biti prikazan </span><span class="cls_017">CodeBehind</span><span class="cls_006"> sadržina glavnog prozora gde je smešten najveći deo</span></div>
<div style="position:absolute;left:71.78px;top:625.90px" class="cls_006"><span class="cls_006">poslovne logike.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:37694px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background48.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_006"><span class="cls_006">Na samom početku, potrebno je importovati odgovarajuće imenske prostore kao što je prikazano</span></div>
<div style="position:absolute;left:72.02px;top:86.42px" class="cls_006"><span class="cls_006">na </span><span class="cls_017">Slici 62</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:195.05px;top:245.09px" class="cls_017"><span class="cls_017">Slika 62 - Imenski prostori za glavni prozor</span></div>
<div style="position:absolute;left:71.30px;top:300.41px" class="cls_006"><span class="cls_006">Za početak, sadržina glavnog prozora trebalo bi da izgleda kao na </span><span class="cls_017">Slici 63</span><span class="cls_006">. Sadržaće instancu</span></div>
<div style="position:absolute;left:71.30px;top:319.85px" class="cls_006"><span class="cls_006">konekcije kao bazi podataka, metodu za popunjavanje početnog grida pri pokretanju prozora,</span></div>
<div style="position:absolute;left:71.30px;top:339.29px" class="cls_006"><span class="cls_006">konstruktor za kreiranje novog prozora kao izgenerisane metode iz XAML koda, putem kojih</span></div>
<div style="position:absolute;left:71.30px;top:358.73px" class="cls_006"><span class="cls_006">će se, klikom na odgovarajuće dugme, obavljati određene funkcionalnosti.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:38496px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background49.jpg" width=612 height=792></div>
<div style="position:absolute;left:211.61px;top:479.83px" class="cls_017"><span class="cls_017">Slika 63 - Sadržaj CodeBehind-a glavnog prozora</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:39298px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background50.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.80px" class="cls_006"><span class="cls_006">Nakon instanciranja konekcije, sledeća stvar je kreiranje metode koja će popunjavati početni</span></div>
<div style="position:absolute;left:72.02px;top:87.38px" class="cls_017"><span class="cls_017">DataGrid </span><span class="cls_006">pri kreiranju novog prozora. U ovom primeru, tabela </span><span class="cls_017">Proizvod </span><span class="cls_006">će biti podrazumevana</span></div>
<div style="position:absolute;left:72.02px;top:103.94px" class="cls_006"><span class="cls_006">tabela, odnosno tabela čiji će se prikaz generisati pri pokretanju ovog prozora. Na osnovu toga,</span></div>
<div style="position:absolute;left:72.02px;top:120.50px" class="cls_006"><span class="cls_006">potrebno je kreirati odgovarajući </span><span class="cls_017">Select </span><span class="cls_006">upit koji će izlistavati, korisniku bitne informacije o</span></div>
<div style="position:absolute;left:72.02px;top:137.06px" class="cls_006"><span class="cls_006">svakom proizvodu. U ovom slučaju, nakon otvaranja konekcije, prikazani upit se kreira na</span></div>
<div style="position:absolute;left:72.02px;top:153.62px" class="cls_006"><span class="cls_006">osnovu povezivanja 4 tabele iz baze podataka (</span><span class="cls_017">tblProizvod, tblProizvodjac, tblVrstaProizvoda </span><span class="cls_006">i</span></div>
<div style="position:absolute;left:72.02px;top:170.18px" class="cls_017"><span class="cls_017">tblDobavljac</span><span class="cls_006">). Zatim, na isti način kao kod popunjavanja </span><span class="cls_017">ComboBox</span><span class="cls_006">-ova pri instanciranju</span></div>
<div style="position:absolute;left:72.02px;top:186.74px" class="cls_006"><span class="cls_006">prozora neke od formi, ovi podaci se smeštaju u odgovarajući </span><span class="cls_017">DataSet</span><span class="cls_006"> kojeg zatim popunjava</span></div>
<div style="position:absolute;left:72.02px;top:203.30px" class="cls_017"><span class="cls_017">SqlDataAdapter</span><span class="cls_006">. Razlika je u tome što, ove podatke, prosledjujemo kao </span><span class="cls_017">ItemsSource</span><span class="cls_006"> gridu</span></div>
<div style="position:absolute;left:72.02px;top:219.98px" class="cls_006"><span class="cls_006">(parametru ove metode), umesto </span><span class="cls_017">ComboBox</span><span class="cls_006">-u kao u prethodno objašnjenom primeru (</span><span class="cls_017">Slika 64</span><span class="cls_006">).</span></div>
<div style="position:absolute;left:198.65px;top:515.71px" class="cls_017"><span class="cls_017">Slika 64 - Sadržaj metode PocetniDataGrid</span></div>
<div style="position:absolute;left:71.30px;top:569.71px" class="cls_006"><span class="cls_006">Sadržaj konstruktora ovog prozora je prilično jednostavan. Prilikom instanciranja novog</span></div>
<div style="position:absolute;left:71.78px;top:585.22px" class="cls_006"><span class="cls_006">prozora, pomoću prethodno kreirane metode, popunjava se </span><span class="cls_017">CentralniGrid</span><span class="cls_006"> </span><span class="cls_017">(Slika 65).</span></div>
<div style="position:absolute;left:210.17px;top:696.82px" class="cls_017"><span class="cls_017">Slika 65 - Konstruktor glavnog prozora</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:40100px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background51.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:70.92px" class="cls_006"><span class="cls_006">Sledi pregled svake od posebnih metoda vezanih za klik na dugme koje služi za ispis podataka iz</span></div>
<div style="position:absolute;left:71.30px;top:86.42px" class="cls_006"><span class="cls_006">tabele na centralnom gridu. Prva, stvar koju ova metoda treba da obezbedi jeste da se, pored</span></div>
<div style="position:absolute;left:71.30px;top:102.02px" class="cls_006"><span class="cls_006">ispisa podataka iz baze, omogući prikaz dugmića za </span><span class="cls_017">Dodavanje</span><span class="cls_006">, </span><span class="cls_017">Izmenu</span><span class="cls_006"> i </span><span class="cls_017">Brisanje</span><span class="cls_006"> podataka.</span></div>
<div style="position:absolute;left:71.30px;top:117.50px" class="cls_006"><span class="cls_006">Tako nešto postiže se pomoću komand </span><span class="cls_017">Visibility</span><span class="cls_006">, na način prikazan na </span><span class="cls_017">Slici 66</span><span class="cls_006">. Za ispis</span></div>
<div style="position:absolute;left:71.30px;top:132.98px" class="cls_006"><span class="cls_006">podataka o proizvodima, koristiće se prethodno kreirana metoda </span><span class="cls_017">PocetniDataGrid</span><span class="cls_006"> kojoj se kao</span></div>
<div style="position:absolute;left:71.30px;top:148.58px" class="cls_006"><span class="cls_006">argument prosleđuje kreirani </span><span class="cls_017">CentralniGrid</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:223.61px;top:622.54px" class="cls_017"><span class="cls_017">Slika 66 - Sadržaj metode btnProizvodi_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:40902px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background52.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:70.92px" class="cls_006"><span class="cls_006">Ispis podataka iz preostalih 6 tabela, vrši se na gotovo identičan način kao za tabelu </span><span class="cls_017">Proizvod</span><span class="cls_006">, sa</span></div>
<div style="position:absolute;left:71.78px;top:86.42px" class="cls_006"><span class="cls_006">tom razlikom da će se </span><span class="cls_017">Select</span><span class="cls_006"> upit pisati direktno u metodi.</span><span class="cls_017"> </span><span class="cls_006">Na ostalim slikama, prikazani su</span></div>
<div style="position:absolute;left:71.78px;top:102.02px" class="cls_006"><span class="cls_006">ispisi i za ostalih 6 tabela: Vrste proizvoda (</span><span class="cls_017">Slika 67</span><span class="cls_006">), Proizvođači </span><span class="cls_017">(Slika 68</span><span class="cls_006">.), Dobavljači (</span><span class="cls_017">Slika</span></div>
<div style="position:absolute;left:71.78px;top:117.50px" class="cls_017"><span class="cls_017">69), </span><span class="cls_006">Kupci (</span><span class="cls_017">Slika 70</span><span class="cls_006">), Prodavci </span><span class="cls_017">(Slika 71) </span><span class="cls_006">i</span><span class="cls_017"> </span><span class="cls_006">Fiskalni Računi (</span><span class="cls_017">Slika 72</span><span class="cls_006">).</span></div>
<div style="position:absolute;left:181.73px;top:696.94px" class="cls_017"><span class="cls_017">Slika 67 - Sadržaj metode btnVrsteProizvoda_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:41704px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background53.jpg" width=612 height=792></div>
<div style="position:absolute;left:188.45px;top:702.70px" class="cls_017"><span class="cls_017">Slika 68 - Sadržaj metode btnProizvodjaci_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:42506px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background54.jpg" width=612 height=792></div>
<div style="position:absolute;left:192.53px;top:696.70px" class="cls_017"><span class="cls_017">Slika 69 - Sadržaj metode btnDobavljaci_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:43308px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background55.jpg" width=612 height=792></div>
<div style="position:absolute;left:205.25px;top:685.54px" class="cls_017"><span class="cls_017">Slika 70 - Sadržaj metode btnKupci_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:44110px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background56.jpg" width=612 height=792></div>
<div style="position:absolute;left:197.09px;top:701.14px" class="cls_017"><span class="cls_017">Slika 71 - Sadržaj metode btnProdavci_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:44912px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background57.jpg" width=612 height=792></div>
<div style="position:absolute;left:184.13px;top:703.30px" class="cls_017"><span class="cls_017">Slika 72 - Sadržaj metode btnFiskalniRacuni_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:45714px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background58.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_006"><span class="cls_006">Sadržaj metoda generisanih na klik dugmeta </span><span class="cls_017">Dodaj</span><span class="cls_006"> je poprilično jednostavan. Pri kliku</span></div>
<div style="position:absolute;left:72.02px;top:85.82px" class="cls_006"><span class="cls_006">na to dugme, instancira se prozor odgovarajuće forme i prikazuje korisniku na ekranu.</span></div>
<div style="position:absolute;left:72.02px;top:100.70px" class="cls_006"><span class="cls_006">Nakon zatvaranja tog prozora forme, osvežava se </span><span class="cls_017">centralni grid </span><span class="cls_006">sa aktuelnim podacima</span></div>
<div style="position:absolute;left:72.02px;top:115.58px" class="cls_006"><span class="cls_006">nakon eventualnog dodavanja novog zapisa u bazu. Na narednim slikama prikazan je</span></div>
<div style="position:absolute;left:72.02px;top:130.34px" class="cls_006"><span class="cls_006">sadržaj metode za dodavanje za svih 7 tabela.</span></div>
<div style="position:absolute;left:179.33px;top:297.89px" class="cls_017"><span class="cls_017">Slika 73 - Sadržaj metode btnDodajProizvod_Click</span></div>
<div style="position:absolute;left:180.89px;top:450.19px" class="cls_017"><span class="cls_017">Slika 74 - Sadržaj metode btnDodajVrstuProizvoda_Click</span></div>
<div style="position:absolute;left:190.49px;top:597.34px" class="cls_017"><span class="cls_017">Slika 75 - Sadržaj metode btnDodajProizvodjaca_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:46516px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background59.jpg" width=612 height=792></div>
<div style="position:absolute;left:174.89px;top:176.18px" class="cls_017"><span class="cls_017">Slika 76 - Sadržaj metode btnDodajDobavljaca_Click</span></div>
<div style="position:absolute;left:171.02px;top:328.61px" class="cls_017"><span class="cls_017">Slika 77 - Sadržaj metode btnDodajKupca_Click</span></div>
<div style="position:absolute;left:175.25px;top:495.55px" class="cls_017"><span class="cls_017">Slika 78 - Sadržaj metode btnDodajProdavca_Click</span></div>
<div style="position:absolute;left:172.58px;top:635.14px" class="cls_017"><span class="cls_017">Slika 79 - Sadržaj metode btnDodajFikslaniRacun_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:47318px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background60.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:96.38px" class="cls_006"><span class="cls_006">Brisanje zapisa iz baze podataka obavlja se putem klika na dugme </span><span class="cls_017">Obriši</span><span class="cls_006"> na način prikazan na</span></div>
<div style="position:absolute;left:72.02px;top:111.62px" class="cls_017"><span class="cls_017">Slici 80</span><span class="cls_006">. Nakon otvaranja konekcije, kreira se objekat klase </span><span class="cls_017">DataRowView</span><span class="cls_006"> koji u sebi čuva</span></div>
<div style="position:absolute;left:72.02px;top:126.86px" class="cls_006"><span class="cls_006">informaciju o indeksu reda koji je korisnik prethodno selektovao. Nakon toga kreira se </span><span class="cls_017">Delete</span></div>
<div style="position:absolute;left:72.02px;top:142.10px" class="cls_006"><span class="cls_006">SQL komanda putem koje će se u samoj bazi obrisati željena stavka. Pre samog izvršavanja</span></div>
<div style="position:absolute;left:72.02px;top:157.34px" class="cls_006"><span class="cls_006">komande, kreira pred korisnikom se pojavljuje dijalog prozor (</span><span class="cls_017">MessageBox</span><span class="cls_006">) putem kojeg on</span></div>
<div style="position:absolute;left:72.02px;top:172.58px" class="cls_006"><span class="cls_006">potvrđuje ili odustaje od brisanja. Dva osnovna izuzetka koja se ovde mogu javiti su:</span></div>
<div style="position:absolute;left:72.02px;top:187.82px" class="cls_017"><span class="cls_017">ArgumentOutOfRange</span><span class="cls_006"> i </span><span class="cls_017">SqlException. </span><span class="cls_006">Prvi se javlja ukoliko korisnik nije selektovao ni jedan</span></div>
<div style="position:absolute;left:72.02px;top:203.06px" class="cls_006"><span class="cls_006">red a pritisnuo je dugme za brisanje, a drugi ukoliko pokuša da obriše enitet iz tabele čiji je</span></div>
<div style="position:absolute;left:72.02px;top:218.30px" class="cls_006"><span class="cls_006">primarni ključ distribuiran u nekoj od drugih tabela. Nakon toga, konekcija se zatvara i početna</span></div>
<div style="position:absolute;left:72.02px;top:233.66px" class="cls_006"><span class="cls_006">strana osvežava sa izmenjenim podacima.</span></div>
<div style="position:absolute;left:211.01px;top:614.38px" class="cls_017"><span class="cls_017">Slika 80 - Sadržaj metode btnObrisiProizvod_Click</span></div>
<div style="position:absolute;left:71.30px;top:655.42px" class="cls_006"><span class="cls_006">Na ostalim slikama, prikazana su brisanja zapisa i iz ostalih 6 tabela: Vrste proizvoda </span><span class="cls_017">(Slika 81</span><span class="cls_006">),</span></div>
<div style="position:absolute;left:71.78px;top:670.90px" class="cls_006"><span class="cls_006">Proizvođači (</span><span class="cls_017">Slika 82</span><span class="cls_006">), Dobavljači (</span><span class="cls_017">Slika 83</span><span class="cls_006">), Kupci </span><span class="cls_017">(Slika 84),</span><span class="cls_006"> Prodavci (</span><span class="cls_017">Slika 85</span><span class="cls_006">) i Fiskalni</span></div>
<div style="position:absolute;left:71.78px;top:686.50px" class="cls_006"><span class="cls_006">računi (</span><span class="cls_017">Slika 86</span><span class="cls_006">).</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:48120px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background61.jpg" width=612 height=792></div>
<div style="position:absolute;left:170.30px;top:328.25px" class="cls_017"><span class="cls_017">Slika 81 - Sadržaj metode btnObrisiVrstuProizvoda_Click</span></div>
<div style="position:absolute;left:183.05px;top:626.26px" class="cls_017"><span class="cls_017">Slika 82 - Sadržaj metode btnObrisiProizvodjaca_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:48922px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background62.jpg" width=612 height=792></div>
<div style="position:absolute;left:189.77px;top:314.45px" class="cls_017"><span class="cls_017">Slika 83 - Sadržaj metode btnObrisiDobavljaca_Click</span></div>
<div style="position:absolute;left:206.57px;top:608.02px" class="cls_017"><span class="cls_017">Slika 84 - Sadržaj metode btnObrisiKupca_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:49724px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background63.jpg" width=612 height=792></div>
<div style="position:absolute;left:201.05px;top:323.33px" class="cls_017"><span class="cls_017">Slika 85 - Sadržaj metode btnObrisiProdavca_Click</span></div>
<div style="position:absolute;left:192.05px;top:620.38px" class="cls_017"><span class="cls_017">Slika 87 - Sadržaj metode btnObrisiFiskalniRacun_Click</span></div>
<div style="position:absolute;left:72.02px;top:671.86px" class="cls_006"><span class="cls_006">Za modifikaciju podataka, kao i za dodavanje, potrebno je da postoji odgovarajuća forma u koju</span></div>
<div style="position:absolute;left:72.02px;top:686.74px" class="cls_006"><span class="cls_006">će korisnik menjati odnosno unositi željene vrednosti. U ovom primeru, za svaku od tabela već je</span></div>
<div style="position:absolute;left:72.02px;top:701.62px" class="cls_006"><span class="cls_006">kreirana forma putem koje se novi zapisi upisuju u bazu podataka.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:50526px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background64.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:70.92px" class="cls_006"><span class="cls_006">Kako ne bismo morali da kreiramo novu formu specijalno za modifikaciju podataka može se</span></div>
<div style="position:absolute;left:72.02px;top:85.82px" class="cls_006"><span class="cls_006">iskoristiti postojeća za dodavanje s tim što će jedina razlika biti u tome koju akciju izvršava</span></div>
<div style="position:absolute;left:72.02px;top:100.70px" class="cls_006"><span class="cls_006">dugme </span><span class="cls_017">Sačuvaj</span><span class="cls_006"> te forme kada ga korisnik klikne. Na samom početku potrebno je, u okviru</span></div>
<div style="position:absolute;left:72.02px;top:115.58px" class="cls_006"><span class="cls_006">glavnog prozora deklarisati dve promenljive (</span><span class="cls_017">Slika 88)</span><span class="cls_006">. Prva je tipa </span><span class="cls_017">boolean </span><span class="cls_006">i koristiće se kao</span></div>
<div style="position:absolute;left:72.02px;top:130.46px" class="cls_006"><span class="cls_006">uslov koji će dugmetu </span><span class="cls_017">Sačuvaj</span><span class="cls_006"> govoriti da li je potrebno podatke upisati u bazu kao novi entitet</span></div>
<div style="position:absolute;left:72.02px;top:145.34px" class="cls_006"><span class="cls_006">ili izmeniti. Druga je tipa </span><span class="cls_017">object </span><span class="cls_006">i služi za pamćenje vrednosti selektovanog reda kada iz glavnog</span></div>
<div style="position:absolute;left:72.02px;top:160.34px" class="cls_006"><span class="cls_006">prozora pređemo u neku drugu formu.</span></div>
<div style="position:absolute;left:233.45px;top:295.85px" class="cls_017"><span class="cls_017">Slika 88 - Deklaracija promenljivih</span></div>
<div style="position:absolute;left:72.02px;top:347.09px" class="cls_006"><span class="cls_006">Na </span><span class="cls_017">Slici 89 </span><span class="cls_006">prikazana je metoda za izmenu </span><span class="cls_017">proizvođača</span><span class="cls_006">. Na samom početku, deklarisana</span></div>
<div style="position:absolute;left:72.02px;top:362.57px" class="cls_006"><span class="cls_006">promenljiva se postavlja na </span><span class="cls_017">true. </span><span class="cls_006">Nakon toga instancira se prozor njene forme i otvara</span></div>
<div style="position:absolute;left:72.02px;top:378.17px" class="cls_006"><span class="cls_006">konekcija. Pomoću </span><span class="cls_017">DataRowView</span><span class="cls_006"> objekta, kao i kod brisanja, pamti se koji je red je selektovan.</span></div>
<div style="position:absolute;left:72.02px;top:393.65px" class="cls_006"><span class="cls_006">Razlika je u tome što se sada, u drugu promenjivu (</span><span class="cls_017">pomocniRed</span><span class="cls_006">) dodaje ta vrednost kako bi se</span></div>
<div style="position:absolute;left:72.02px;top:409.15px" class="cls_006"><span class="cls_006">iskoristila u drugoj formi. Nakon toga se, pomoću </span><span class="cls_017">Select</span><span class="cls_006"> upita kojem se u </span><span class="cls_017">Where</span><span class="cls_006"> uslovu zadaje</span></div>
<div style="position:absolute;left:72.02px;top:424.75px" class="cls_006"><span class="cls_006">vrednost primarnog ključa zapisa koji se modifikuje, potrebni podaci smeštaju u odgovarajuća</span></div>
<div style="position:absolute;left:72.02px;top:440.23px" class="cls_006"><span class="cls_006">polja forme pomoću </span><span class="cls_017">SqlDataReader</span><span class="cls_006">-a. Nakon toga, poziva se metoda prozora </span><span class="cls_017">ShowDialog</span><span class="cls_006"> i on</span></div>
<div style="position:absolute;left:72.02px;top:455.71px" class="cls_006"><span class="cls_006">se prikazuje na ekranu sa popunjenim vrednostima traženog zapisa. Dalja funkcionalnost</span></div>
<div style="position:absolute;left:72.02px;top:471.31px" class="cls_006"><span class="cls_006">obavlja se unutar te forme i dugmeta </span><span class="cls_017">Sačuvaj</span><span class="cls_006"> i biće objašnjena kasnije. U okviru ove metode, u</span></div>
<div style="position:absolute;left:72.02px;top:486.79px" class="cls_017"><span class="cls_017">finally</span><span class="cls_006"> bloku, konekcija se zatvara, osvežava se početna strana sa izmenjenim proizvođačima, a</span></div>
<div style="position:absolute;left:72.02px;top:502.27px" class="cls_006"><span class="cls_006">promenljiva izmena vraća na </span><span class="cls_017">false</span><span class="cls_006"> u slučaju da nakon izmene korisnik želi da doda novi zapis u</span></div>
<div style="position:absolute;left:72.02px;top:517.75px" class="cls_006"><span class="cls_006">bazu podataka.</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:51328px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background65.jpg" width=612 height=792></div>
<div style="position:absolute;left:147.26px;top:286.85px" class="cls_017"><span class="cls_017">Slika 89 - Sadržaj metode btnIzmeniProizvodjaca_Click</span></div>
<div style="position:absolute;left:72.02px;top:338.57px" class="cls_006"><span class="cls_006">Na ostalim slikama, prikazane su metode za izmenu zapisa i iz ostalih 6 tabela: Dobavljači (</span><span class="cls_017">Slika</span></div>
<div style="position:absolute;left:72.02px;top:353.45px" class="cls_017"><span class="cls_017">90</span><span class="cls_006">), Kupci </span><span class="cls_017">(Slika 91</span><span class="cls_006">.), Prodavci (</span><span class="cls_017">Slika 92),</span><span class="cls_006"> Fiskalni računi (</span><span class="cls_017">Slika 93</span><span class="cls_006">), Proizvodi </span><span class="cls_017">(Slika 94</span><span class="cls_006">) i</span></div>
<div style="position:absolute;left:72.02px;top:368.33px" class="cls_006"><span class="cls_006">Vrste proizvoda </span><span class="cls_017">(Slika 95).</span></div>
<div style="position:absolute;left:174.50px;top:667.78px" class="cls_017"><span class="cls_017">Slika 90 - Sadržaj metode btnIzmeniDobavljaca_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:52130px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background66.jpg" width=612 height=792></div>
<div style="position:absolute;left:183.05px;top:329.57px" class="cls_017"><span class="cls_017">Slika 91 - Sadržaj metode btnIzmeniKupca_Click</span></div>
<div style="position:absolute;left:179.21px;top:680.14px" class="cls_017"><span class="cls_017">Slika 92 - Sadržaj metode btnIzmeniProdavca_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:52932px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background67.jpg" width=612 height=792></div>
<div style="position:absolute;left:174.02px;top:336.29px" class="cls_017"><span class="cls_017">Slika 93 - Sadržaj metode btnIzmeniFiskalniRacun_Click</span></div>
<div style="position:absolute;left:189.05px;top:703.30px" class="cls_017"><span class="cls_017">Slika 94 - Sadržaj metode btnIzmeniProizvod_Click</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:53734px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background68.jpg" width=612 height=792></div>
<div style="position:absolute;left:164.30px;top:381.89px" class="cls_017"><span class="cls_017">Slika 95 - Sadržaj metode btnIzmeniVrstuProizvoda_Click</span></div>
<div style="position:absolute;left:72.02px;top:429.55px" class="cls_006"><span class="cls_006">Nakon što su željene vrednosti prikupljene unutar same forme, korisnik klikom na dugme</span></div>
<div style="position:absolute;left:72.02px;top:444.43px" class="cls_017"><span class="cls_017">Sačuvaj</span><span class="cls_006"> prosleđuje te zapise u bazu. U okviru </span><span class="cls_017">try</span><span class="cls_006"> bloka metode ovog dugmeta, nalazi se </span><span class="cls_017">if</span><span class="cls_006"> uslov</span></div>
<div style="position:absolute;left:72.02px;top:459.31px" class="cls_006"><span class="cls_006">na osnovu kojeg se, ukoliko je promenljiva </span><span class="cls_017">izmena</span><span class="cls_006"> postavljena na </span><span class="cls_017">true</span><span class="cls_006"> - zapis modifikuje</span></div>
<div style="position:absolute;left:72.02px;top:474.19px" class="cls_006"><span class="cls_006">odnosno ako je </span><span class="cls_017">false</span><span class="cls_006"> - upise u bazu kao novi zapis. Ključ selektovanog reda nalazi se u</span></div>
<div style="position:absolute;left:72.02px;top:489.07px" class="cls_006"><span class="cls_006">promenljivoj </span><span class="cls_017">pomocniRed</span><span class="cls_006"> i njegova vrednost se smešta u objekat </span><span class="cls_017">DataRowView</span><span class="cls_006">-a. Zatim se</span></div>
<div style="position:absolute;left:72.02px;top:503.95px" class="cls_006"><span class="cls_006">kreira odgovarajući </span><span class="cls_017">Update</span><span class="cls_006"> upit na osnovu kojeg se podaci u bazi modifikuju. Na kraju,</span></div>
<div style="position:absolute;left:72.02px;top:518.83px" class="cls_006"><span class="cls_006">promenljiva </span><span class="cls_017">pomocniRed </span><span class="cls_006">se postavlja na </span><span class="cls_017">NULL</span><span class="cls_006">, kako bi sledeća modifkacija mogla da se dogodi</span></div>
<div style="position:absolute;left:72.02px;top:533.71px" class="cls_006"><span class="cls_006">na isti način, a prozor forme zatvara.</span></div>
<div style="position:absolute;left:71.30px;top:564.67px" class="cls_006"><span class="cls_006">Sledi primer za Dobavljača </span><span class="cls_017">(Slika 96). </span><span class="cls_006">Na ostalim slikama, prikazane su izmene metode</span></div>
<div style="position:absolute;left:71.30px;top:580.66px" class="cls_017"><span class="cls_017">Sačuvaj</span><span class="cls_006"> i za ostalih 6 tabela: Fiskalni račun (</span><span class="cls_017">Slika 97), </span><span class="cls_006">Kupac (</span><span class="cls_017">Slika 98</span><span class="cls_006">), Prodavac </span><span class="cls_017">(Slika 99</span><span class="cls_006">),</span></div>
<div style="position:absolute;left:71.78px;top:596.14px" class="cls_006"><span class="cls_006">Proizvod (</span><span class="cls_017">Slika 1</span><span class="cls_006">00), Proizvođač (</span><span class="cls_017">Slika 101</span><span class="cls_006">) i Vrsta proizvoda (</span><span class="cls_017">Slika 102</span><span class="cls_006">).</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:54536px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background69.jpg" width=612 height=792></div>
<div style="position:absolute;left:160.46px;top:366.65px" class="cls_017"><span class="cls_017">Slika 96 - Izmene metode btnSacuvaj_Click u formi frmDobavljac</span></div>
<div style="position:absolute;left:131.30px;top:690.82px" class="cls_017"><span class="cls_017">Slika 97 - Izmene metode btnSacuvaj_Click u formi frmFiskalniRacun</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:55338px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background70.jpg" width=612 height=792></div>
<div style="position:absolute;left:164.30px;top:373.13px" class="cls_017"><span class="cls_017">Slika 98 - Izmene metode btnSacuvaj_Click u formi frmKupac</span></div>
<div style="position:absolute;left:162.02px;top:697.78px" class="cls_017"><span class="cls_017">Slika 99 - Izmene metode btnSacuvaj_Click u formi frmProdavac</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:56140px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background71.jpg" width=612 height=792></div>
<div style="position:absolute;left:168.38px;top:339.89px" class="cls_017"><span class="cls_017">Slika 100 - Izmene metode btnSacuvaj_Click u formi frmProizvod</span></div>
<div style="position:absolute;left:154.22px;top:685.30px" class="cls_017"><span class="cls_017">Slika 101 - Izmene metode btnSacuvaj_Click u formi frmProizvodjac</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:56942px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background72.jpg" width=612 height=792></div>
<div style="position:absolute;left:149.18px;top:351.41px" class="cls_017"><span class="cls_017">Slika 102 - Izmene metode btnSacuvaj_Click u formi frmVrstaProizvoda</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:57744px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background73.jpg" width=612 height=792></div>
<div style="position:absolute;left:75.02px;top:70.58px" class="cls_003"><span class="cls_003">5. Testiranje aplikacije</span></div>
<div style="position:absolute;left:71.30px;top:137.66px" class="cls_006"><span class="cls_006">Pri pokretanju aplikacije, generiše se početni prozor kao na </span><span class="cls_017">Slici 103</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:183.05px;top:526.27px" class="cls_017"><span class="cls_017">Slika 103- Početni prozor pri pokretanju aplikacije</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:58546px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background74.jpg" width=612 height=792></div>
<div style="position:absolute;left:71.30px;top:70.92px" class="cls_006"><span class="cls_006">Klikom na dugmiće iz gornjeg StackPanel-a, vrši se prikaz podataka željene tabele na</span></div>
<div style="position:absolute;left:71.78px;top:86.42px" class="cls_006"><span class="cls_006">centralnom gridu (</span><span class="cls_017">Slika 104)</span><span class="cls_006">.</span></div>
<div style="position:absolute;left:170.30px;top:430.51px" class="cls_017"><span class="cls_017">Slika 104 - Izlistavanje podataka o prodavcima na početnom gridu</span></div>
<div style="position:absolute;left:71.30px;top:473.47px" class="cls_006"><span class="cls_006">Klikom na dugme </span><span class="cls_017">Dodaj</span><span class="cls_006">, otvara se forma za dodavanje novog zapisa u bazu podataka (</span><span class="cls_017">Slika</span></div>
<div style="position:absolute;left:71.78px;top:489.07px" class="cls_017"><span class="cls_017">105</span><span class="cls_006">).</span></div>
<div style="position:absolute;left:171.02px;top:685.42px" class="cls_017"><span class="cls_017">Slika 105 - Dodavanje novog prodavca u bazu podataka</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:59348px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background75.jpg" width=612 height=792></div>
<div style="position:absolute;left:75.02px;top:70.92px" class="cls_006"><span class="cls_006">Klikom na dugme </span><span class="cls_017">Sačuvaj</span><span class="cls_006">, novi zapis se dodaje u bazu podataka i prikazuje na centralnom</span></div>
<div style="position:absolute;left:72.02px;top:91.58px" class="cls_006"><span class="cls_006">gridu (</span><span class="cls_017">Slika 106</span><span class="cls_006">).</span></div>
<div style="position:absolute;left:212.33px;top:387.29px" class="cls_017"><span class="cls_017">Slika 106 - Ispis dodatog prodavca</span></div>
<div style="position:absolute;left:71.30px;top:428.11px" class="cls_006"><span class="cls_006">Klik na dugme </span><span class="cls_017">Izmeni</span><span class="cls_006"> ili </span><span class="cls_017">Obriši</span><span class="cls_006">, a da pritom nije selektovan ni jedan red, uzrokuje sledeću</span></div>
<div style="position:absolute;left:71.78px;top:443.71px" class="cls_006"><span class="cls_006">grešku/obaveštenje (</span><span class="cls_017">Slika 107</span><span class="cls_006">).</span></div>
<div style="position:absolute;left:129.02px;top:693.70px" class="cls_017"><span class="cls_017">Slika 107 - Pokušaj klika na dugme izmeni ili obriši bez selektovanja reda</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:60150px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background76.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:96.86px" class="cls_006"><span class="cls_006">Selektovanjem odgovarajućeg reda otvara se forma sa popunjenim vrednostima prethodnog</span></div>
<div style="position:absolute;left:72.02px;top:112.46px" class="cls_006"><span class="cls_006">zapisa koje korisnik dalje može modifikovati (</span><span class="cls_017">Slika 108</span><span class="cls_006">).</span></div>
<div style="position:absolute;left:197.81px;top:403.25px" class="cls_017"><span class="cls_017">Slika 108 - Otvaranje forme za modifikaciju</span></div>
<div style="position:absolute;left:71.30px;top:444.43px" class="cls_006"><span class="cls_006">Nakon izmene željenih podataka, ažužirani zapis se prikazuje na ekranu (</span><span class="cls_017">Slika 109</span><span class="cls_006">).</span></div>
<div style="position:absolute;left:174.50px;top:701.26px" class="cls_017"><span class="cls_017">Slika 109 - Ažužiran sadržaj nakon promene podataka</span></div>
</div>
<div style="position:absolute;left:50%;margin-left:-306px;top:60952px;width:612px;height:792px;border-style:outset;overflow:hidden">
<div style="position:absolute;left:0px;top:0px">
<img src="44a529ee-cb3e-11e8-b59b-0cc47a792c0a_id_44a529ee-cb3e-11e8-b59b-0cc47a792c0a_files/background77.jpg" width=612 height=792></div>
<div style="position:absolute;left:72.02px;top:88.58px" class="cls_006"><span class="cls_006">Brisanje podataka vrši se klikom na dugme </span><span class="cls_017">Obriši</span><span class="cls_006">, nakon što je korisnik prethodno selektovao</span></div>
<div style="position:absolute;left:72.02px;top:104.06px" class="cls_006"><span class="cls_006">željeni zapis za brisanje (</span><span class="cls_017">Slika 110</span><span class="cls_006">). Klikom na dugme </span><span class="cls_017">Yes</span><span class="cls_006">, korisnik povrđuje brisanje, a na</span></div>
<div style="position:absolute;left:72.02px;top:119.54px" class="cls_006"><span class="cls_006">ekranu se generiše ažužiran ispis.</span></div>
<div style="position:absolute;left:280.85px;top:505.75px" class="cls_017"><span class="cls_017">Slika 110 - Brisanje zapisa</span></div>
</div>
</body>
</html>