Subversion Repositories wpShopGermany4

Rev

Rev 5760 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5760 Rev 5767
Line 1... Line 1...
1
<?php
1
<?php
2
 
2
 
3
    /**
3
    /**
4
     * Integration der Variantenauswahl in die Produktverwaltung
4
     * Integration der Variantenauswahl in die Produktverwaltung
5
     */
5
     */
6
 
6
   
7
?>
7
?>
8
 
8
 
9
<div class="wpsg_mod_variants_product_wrap">
9
<div class="wpsg_mod_productvariants_product_wrap" id="wpsg_mod_productvariants_product_wrap_<?php echo $GLOBALS['wpsg_produkt_index']; ?>" wpsg-productindex="<?php echo $GLOBALS['wpsg_produkt_index']; ?>">
10
    <?php foreach ($this->view['wpsg_mod_productvariants']['arVariants'] as $var) { ?>
10
    <?php foreach ($this->view['wpsg_mod_productvariants']['arVariants'] as $var) { ?>
11
    
11
    
-
 
12
        <div class=wpsg_mod_productvariants_product wpsg_mod_productvariants_type_<?php echo $var['type']; ?>">
-
 
13
                
12
        <div class="wpsg_mod_variants_product">
14
            <?php if ($var['type'] == wpsg_mod_productvariants::TYPE_SELECT) { ?>            
13
            
15
            
-
 
16
                <label class="wpsg_mod_productvariants_label" for="wpsg_mod_productvariants_<?php echo $this->view['wpsg_mod_productvariants']['product_id']; ?>_<?php echo $var['id']; ?>"><?php echo wpsg_hspc($var['name']); ?></label>
-
 
17
                    
-
 
18
                <select class="wpsg_mod_productvariants_change" id="wpsg_mod_productvariants_<?php echo $this->view['wpsg_mod_productvariants']['product_id']; ?>_<?php echo $var['id']; ?>" name="wpsg_mod_productvariants[<?php echo $var['id']; ?>]">
-
 
19
                    <?php foreach ($var['arVariation'] as $vari) { ?>
-
 
20
                    <option <?php echo (($this->view['wpsg_mod_productvariants']['product_variants'][$var['id']] == $vari['id'])?'selected="selected"':''); ?> value="<?php echo $vari['id']; ?>"><?php echo wpsg_hspc($vari['name']); ?></option>
-
 
21
                    <?php } ?>
-
 
22
                </select>
14
            
23
            
-
 
24
            <?php } else if ($var['type'] == wpsg_mod_productvariants::TYPE_RADIO) { ?>
-
 
25
    
-
 
26
                <label class="wpsg_mod_productvariants_label"><?php echo wpsg_hspc($var['name']); ?></label>
-
 
27
                    
-
 
28
                <?php foreach ($var['arVariation'] as $vari) { ?>
-
 
29
                <label class="wpsg_mod_productvariants_variation_label">
-
 
30
                    <input class="wpsg_mod_productvariants_change" <?php echo (($this->view['wpsg_mod_productvariants']['product_variants'][$var['id']] == $vari['id'])?'checked="checked"':''); ?> type="radio" name="wpsg_mod_productvariants[<?php echo $var['id']; ?>]" value="<?php echo $vari['id']; ?>" />
-
 
31
                    <span><?php echo wpsg_hspc($vari['name']); ?></span>
-
 
32
                </label>
-
 
33
                <?php } ?>
-
 
34
                    
-
 
35
            <?php } ?>            
15
            
36
            
16
        </div>        
37
        </div>        
17
        
38
        
18
    <?php } ?>
39
    <?php } ?>
-
 
40
 
-
 
41
    <script type="text/javascript">/* <![CDATA[ */
-
 
42
    
-
 
43
        jQuery(document).ready(function() {
-
 
44
        
-
 
45
            jQuery('#wpsg_mod_productvariants_product_wrap_<?php echo $GLOBALS['wpsg_produkt_index']; ?>').bind('change', wpsg_mod_productvariants_reload); 
-
 
46
                    
-
 
47
        } );
-
 
48
    
-
 
49
    /* ]]> */</script>
-
 
50
 
19
</div>
51
</div>