Subversion Repositories wpShopGermany4

Rev

Rev 6005 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
5439 daniel 1
<div class="form-group form-group-sm form-checkbox <?php echo ((wpsg_isSizedString($this->view['field_config']['help']))?'has-feedback':''); ?>">
5266 daniel 2
 
5792 daniel 3
    <?php if (wpsg_isSizedString($this->view['field_config']['label'])) { $value_class = 'col-sm-6'; ?>
4
    <label class="col-sm-6 control-label">
5
        <?php echo wpsg_hspc($this->view['field_config']['label']); ?>
6
    </label>
7
    <?php } else {
8
 
9
        if (wpsg_isTrue($this->view['field_config']['fullWidth'])) $value_class = 'col-sm-12';
10
		else $value_class = 'col-sm-offset-6 col-sm-6';
11
 
12
    } ?>
13
 
14
	<div class="<?php echo $value_class; ?>">
5266 daniel 15
 
16
		<div class="checkbox">
17
			<label>
5450 daniel 18
 
5439 daniel 19
				<div class="wpsg_field_wrap">
5896 daniel 20
 
21
					<?php if (!isset($this->view['field_config']['noHidden'])) { ?>
5439 daniel 22
					<input type="hidden" name="<?php echo $this->view['field_name']; ?>" value="0" />
5896 daniel 23
					<?php } ?>
24
 
5450 daniel 25
					<input type="checkbox" id="<?php echo $this->view['field_id']; ?>" name="<?php echo $this->view['field_name']; ?>" value="<?php echo wpsg_getStr($this->view['field_config']['value'], '1'); ?>" <?php echo (($this->view['field_checked'] > 0)?'checked="checked"':''); ?> />
5266 daniel 26
 
5439 daniel 27
					<?php echo $this->view['field_label']; ?>
28
 
29
					<?php if (wpsg_isSizedString($this->view['field_config']['help'])) { ?>
6005 hartmut 30
						<?php if (wpsg_isTrue($this->view['field_config']['rAlign'])) { ?>
31
							<a href="#" data-wpsg-tip="<?php echo $this->view['field_config']['help']; ?>" rel="?page=wpsg-Admin&subaction=loadHelp&noheader=1&field=<?php echo $this->view['field_config']['help']; ?>"
32
							class="glyphicon glyphicon wpsg_glyphicon_right glyphicon-question-sign form-control-feedback" aria-hidden="true" style="float:right;"></a>
33
						<?php } else { ?>
34
							<a href="#" data-wpsg-tip="<?php echo $this->view['field_config']['help']; ?>" rel="?page=wpsg-Admin&subaction=loadHelp&noheader=1&field=<?php echo $this->view['field_config']['help']; ?>"
35
							class="glyphicon glyphicon glyphicon-question-sign form-control-feedback" aria-hidden="true"></a>
36
						<?php } ?>
5439 daniel 37
					<?php } ?>
38
 
6830 daniel 39
					<?php if (wpsg_isSizedString($this->view['field_config']['hint'])) { ?>
40
						<div class="hint info"><?php echo $this->view['field_config']['hint']; ?></div>
41
					<?php } ?>
42
 
5439 daniel 43
				</div>
5266 daniel 44
 
45
			</label>
6005 hartmut 46
 
5266 daniel 47
		</div>
48
 
49
	</div>
50
 
5896 daniel 51
	<?php if (wpsg_isTrue($this->view['field_config']['inlineEdit'])) { ?>
52
    <script type="text/javascript">/* <![CDATA[ */
53
 
54
        jQuery(document).ready(function() {
55
 
56
			jQuery('#<?php echo $this->view['field_id']; ?>').on('change', function() {
57
 
58
				var value = '0';
59
				if (jQuery(this).prop('checked')) value = '1';
60
 
61
				jQuery.ajax( {
62
					url: '<?php echo $this->view['field_config']['inlineEdit_url']; ?>',
63
					data: {
64
						'name': '<?php echo $this->view['field_name']; ?>',
65
						'value': value
66
					}
67
				} );
68
 
69
			} );
70
 
71
        } );
72
 
73
    /* ]]> */</script>
74
    <?php } ?>
75
 
5391 daniel 76
	<div class="clearfix wpsg_clear"></div>
77
 
5266 daniel 78
</div>