Subversion Repositories wpShopGermany4

Rev

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

Rev 5439 Rev 5751
Line 3... Line 3...
3
	/**
3
	/**
4
	 * Template für das Anlegen und Bearbeiten einer Kundengruppe im Backend
4
	 * Template für das Anlegen und Bearbeiten einer Kundengruppe im Backend
5
	 */
5
	 */
6
 
6
 
7
?>
7
?>
8
<div class="wrap wpsg_mod_kundenverwaltung_customergroup_addedit wpsg_customergroup_view wpsg_produkt_addedit wrap columns-2">
8
<div class="wpsg_customergroup wpsg_customergroup_add" id="wpsg-bs">
9
	<div class="icon32 icon32-posts-post" id="icon-add"><br /></div>
-
 
10
	
9
 
11
	<h2>
-
 
12
		<?php if ($this->view['mode'] == 'edit') { ?>
-
 
13
			<?php echo __('Kundengruppe bearbeiten', 'wpsg'); ?>
-
 
14
		<?php } else { ?>
-
 
15
			<?php echo __('Kundengruppe anlegen', 'wpsg'); ?>
-
 
16
		<?php } ?>
-
 
17
	</h2>
-
 
18
	<br />
-
 
19
	
-
 
20
	<?php echo $this->writeBackendMessage(); ?>
10
    <nav class="navbar navbar-default">
21
	
-
 
22
	<form method="POST" action="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Customergroup&action=save&noheader=1" enctype="multipart/form-data">
-
 
23
		
11
 
24
		<?php if ($this->view['mode'] == 'edit') { ?>
12
		<div class="container-fluid">
25
		<input type="hidden" name="edit_id" value="<?php echo $this->view['data']->id; ?>" />
-
 
26
		<?php } ?>
-
 
27
		
-
 
28
		<div id="postbox" class="metabox-holder has-right-sidebar">
13
			<div class="navbar-header">
29
			
-
 
30
			<div id="side-info-column" class="inner-sidebar" style="width:386px;">
-
 
31
				
-
 
32
				<div id="side-sortables" class="meta-box-sortables ui-sortable" style="width:380px;">
14
				<a class="navbar-brand" href="#"><?php echo __('wpShopGermany', 'wpsg'); ?></a>
33
				
-
 
34
					<?php $this->callMods('customergroup_edit', array(&$this->view['data'])); ?>
-
 
35
				
-
 
36
				</div>
-
 
37
				
-
 
38
			</div>
15
			</div>
39
			
-
 
40
			<div id="post-body">	
-
 
41
			
-
 
42
				<div id="normal-sortables" class="meta-box-sortables" style="margin-right:400px;">
16
			<div class="collapse navbar-collapse" id="bs-customergroup-navbar-collapse-1">
43
				
-
 
44
					<div id="wpsg_customergroup_general" class="postbox">								
-
 
45
						<h3 class="wpsg_handlediv">
17
				<ul class="nav navbar-nav">
46
							<span title="<?php echo __('Zum Ein/Ausklappen hier klicken', 'wpsg'); ?>" class="handlediv"><br /></span>
18
					<li role="presentation" class="wpsg-customergroup-tab-a"><a href="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Customergroup&action=index"><?php echo __("Kundengruppenverwaltung", "wpsg"); ?></a></li>
47
							<span><?php echo __('Allgemein', 'wpsg'); ?></span>
19
					<li role="presentation" class="<?php echo ((wpsg_isSizedString($_REQUEST['action'], 'add'))?'active':''); ?>"><a href="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Customergroup&action=add"><span class="glyphicon glyphicon-plus"></span><?php echo __("Hinzufügen", "wpsg"); ?></a></li>
48
						</h3>
20
				</ul>
49
						<div class="inside">
-
 
50
						
-
 
51
							<?php echo wpsg_drawForm_Input('wpsg_mod_kundenverwaltung[name]', __('Name', 'wpsg'), $this->view['data']->name); ?> 
-
 
52
							<?php echo wpsg_drawForm_Select('wpsg_mod_kundenverwaltung[calculation]', __('Preisangaben im Shop (Frontend)', 'wpsg'), array(
-
 
53
								-1 => __('Standard', 'wpsg'),
-
 
54
								WPSG_BRUTTO => __('Brutto (inkl. Steuer)', 'wpsg'), 
-
 
55
								WPSG_NETTO => __('Netto (zzgl. Steuer)', 'wpsg')
-
 
56
							), $this->view['data']->calculation); ?>
21
				<ul class="nav navbar-nav navbar-right">
57
						
-
 
58
						</div>
-
 
59
					</div>
-
 
60
					
-
 
61
				</div>
-
 
62
				
22
 
63
				<p class="submit">
-
 
64
					<input type="submit" value="<?php echo __('Kundengruppe speichern', 'wpsg'); ?>" class="button-primary" id="submit" name="submit" />
-
 
65
					<input type="submit" value="<?php echo __('Kundengruppe speichern und zur Übersicht', 'wpsg'); ?>" class="button-primary" id="submit_index" name="submit_index" />
-
 
66
				</p>
23
				</ul>
67
				
-
 
68
			</div>
24
			</div>
69
			
-
 
70
		</div>
25
		</div>
71
		
-
 
72
	</form>
-
 
73
	
-
 
74
</div>
-
 
75
 
-
 
76
<script type="text/javascript">/* <![CDATA[ */
-
 
77
                                            
-
 
78
	jQuery(document).ready( function() {
-
 
79
 
-
 
80
	    jQuery("#normal-sortables, #side-sortables").sortable({
-
 
81
			connectWith: ".meta-box-sortables",
-
 
82
			placeholder: 'wpsg_placeholder',
-
 
83
			dropOnEmpty: true,
-
 
84
			cursor: 'move',
-
 
85
			handle: '.wpsg_handlediv',
-
 
86
			grid: [50, 20],
-
 
87
			forceHelperSize: true,
-
 
88
			forcePlaceholderSize: true,
-
 
89
			opacity: 0.8,
-
 
90
			stop: function(e,ui) {
-
 
91
 
-
 
92
				var ser = jQuery("#normal-sortables").sortable("serialize");				
-
 
93
				ser = ser.replace(/\&wpsg\[\]\=/g, ',').replace(/wpsg\[\]\=/g, '');
-
 
94
 
-
 
95
				jQuery.cookie('wpsg_customergroup_view_normal', ser);
-
 
96
 
-
 
97
				var ser = jQuery("#side-sortables").sortable("serialize");				
-
 
98
				ser = ser.replace(/\&wpsg\[\]\=/g, ',').replace(/wpsg\[\]\=/g, '');
-
 
99
 
-
 
100
				jQuery.cookie('wpsg_customergroup_view_side', ser);
-
 
101
				
-
 
102
			},
-
 
103
			receive: function(e, ui) {
-
 
104
			}
-
 
105
		}); 
-
 
106
 
-
 
107
	    if (jQuery.cookie('wpsg_customergroup_view_normal') != null)
-
 
108
		{
-
 
109
 
-
 
110
			var divs = jQuery.cookie('wpsg_customergroup_view_normal').split(',').reverse();
-
 
111
 
-
 
112
			for (index in divs)
-
 
113
			{
-
 
114
 
-
 
115
				jQuery('#normal-sortables').prepend(jQuery('#wpsg_' + divs[index]));
-
 
116
				
-
 
117
			}
-
 
118
			
-
 
119
		}
-
 
120
 
-
 
121
		if (jQuery.cookie('wpsg_customergroup_view_side') != null)
-
 
122
		{
-
 
123
 
-
 
124
			var divs = jQuery.cookie('wpsg_customergroup_view_side').split(',').reverse();
-
 
125
 
-
 
126
			for (index in divs)
-
 
127
			{
-
 
128
				 
-
 
129
				jQuery('#side-sortables').prepend(jQuery('#wpsg_' + divs[index]));
-
 
130
				
-
 
131
			}
-
 
132
			
-
 
133
		}
-
 
134
 
-
 
135
		jQuery('.wpsg_handlediv').bind('click', function() {
-
 
136
			jQuery(this).next().toggle();
-
 
137
 
-
 
138
			var arClose = new Array();
-
 
139
			jQuery('.wpsg_customergroup_view .postbox .inside:hidden').each(function() {
-
 
140
				arClose.push(jQuery(this).parent().attr("id"));
-
 
141
			} );
-
 
142
 
-
 
143
			jQuery.cookie('wpsg_customergroup_closed', arClose.join(','));
-
 
144
			
-
 
145
		} );
-
 
146
 
-
 
147
		if (jQuery.cookie('wpsg_customergroup_closed') != null)
-
 
148
		{
-
 
149
 
-
 
150
			var arClose = jQuery.cookie('wpsg_customergroup_closed').split(',');
-
 
151
 
-
 
152
			for (index in arClose)
-
 
153
			{
-
 
154
				
-
 
155
				jQuery('#' + arClose[index] + ' .inside').hide();
-
 
156
							
-
 
157
			}
-
 
158
			
-
 
159
		}
-
 
160
		
-
 
161
	} );
-
 
162
	
-
 
163
/* ]]> */</script>
-
 
164
26
 
-
 
27
    </nav>
-
 
28
 
-
 
29
	<div class="wpsg_clear"></div>
-
 
30
 
-
 
31
	<?php echo $this->writeBackendMessage(); ?>
-
 
32
 
-
 
33
	<div class="content">
-
 
34
 
-
 
35
        <form method="POST" action="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Customergroup&action=save&noheader=1" enctype="multipart/form-data">
-
 
36
            <?php echo wpsg_drawForm_AdminboxStart(__('Allgemein', 'wpsg')); ?>
-
 
37
 
-
 
38
                <?php if ($this->view['mode'] == 'edit') { ?>
-
 
39
                <input type="hidden" name="edit_id" value="<?php echo $this->view['data']->id; ?>" />
-
 
40
                <?php } ?>
-
 
41
 
-
 
42
                <?php $this->callMods('customergroup_edit', array(&$this->view['data'])); ?>
-
 
43
 
-
 
44
                <?php echo wpsg_drawForm_Input('wpsg_mod_kundenverwaltung[name]', __('Name', 'wpsg'), @$this->view['data']->name); ?>
-
 
45
                <?php echo wpsg_drawForm_Select('wpsg_mod_kundenverwaltung[calculation]', __('Preisangaben im Shop (Frontend)', 'wpsg'), array(
-
 
46
                    -1 => __('Standard', 'wpsg'),
-
 
47
                    WPSG_BRUTTO => __('Brutto (inkl. Steuer)', 'wpsg'),
-
 
48
                    WPSG_NETTO => __('Netto (zzgl. Steuer)', 'wpsg')
-
 
49
                ), @$this->view['data']->calculation); ?>
-
 
50
 
-
 
51
            <?php echo wpsg_drawForm_AdminboxEnd(); ?>
-
 
52
 
-
 
53
            <input type="submit" value="<?php echo __('Kundengruppe speichern', 'wpsg'); ?>" class="button-primary" id="submit" name="submit" />
-
 
54
			<input type="submit" value="<?php echo __('Kundengruppe speichern und zur Übersicht', 'wpsg'); ?>" class="button-primary" id="submit_index" name="submit_index" />
-
 
55
 
-
 
56
        </form>
-
 
57
 
-
 
58
    </div>
-
 
59
 
-
 
60
</div>
-
 
61
165
62