mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-02-24 02:46:56 -05:00
Sales register and Receiving with new dropdown and relayout (#116)
This commit is contained in:
@@ -65,7 +65,7 @@
|
||||
<![endif]-->
|
||||
<!-- start mincss template tags -->
|
||||
<link rel="stylesheet" type="text/css" href="dist/bootstrap.min.css?rel=9ed20b1ee8"/>
|
||||
<link rel="stylesheet" type="text/css" href="dist/opensourcepos.min.css?rel=aabc76522f"/>
|
||||
<link rel="stylesheet" type="text/css" href="dist/opensourcepos.min.css?rel=1d6d6ab1bf"/>
|
||||
<!-- end mincss template tags -->
|
||||
<!-- start minjs template tags -->
|
||||
<script type="text/javascript" src="dist/opensourcepos.min.js?rel=dd4a56997a" language="javascript"></script>
|
||||
|
||||
@@ -10,47 +10,61 @@ if (isset($error))
|
||||
?>
|
||||
|
||||
<div id="register_wrapper">
|
||||
<?php echo form_open("receivings/change_mode", array('id'=>'mode_form')); ?>
|
||||
<label><?php echo $this->lang->line('recvs_mode') ?></label>
|
||||
<?php
|
||||
echo form_dropdown('mode', $modes, $mode, 'onchange="$(\'#mode_form\').submit();"');
|
||||
|
||||
if ($show_stock_locations)
|
||||
{
|
||||
echo $this->lang->line('recvs_stock_source');
|
||||
echo form_dropdown('stock_source', $stock_locations, $stock_source, 'onchange="$(\'#mode_form\').submit();"');
|
||||
<?php echo form_open("receivings/change_mode", array('id'=>'mode_form', 'class'=>'form-horizontal panel panel-default')); ?>
|
||||
<div class="panel-body form-group-sm">
|
||||
<label class='col-sm-2 control-label'><?php echo $this->lang->line('recvs_mode'); ?></label>
|
||||
<div class="col-sm-2">
|
||||
<?php echo form_dropdown('mode', $modes, $mode, array('onchange'=>"$('#mode_form').submit();", 'class'=>'selectpicker show-menu-arrow', 'data-style'=>'btn-default btn-sm', 'data-width'=>'fit')); ?>
|
||||
</div>
|
||||
|
||||
if($mode=='requisition')
|
||||
<?php
|
||||
if ($show_stock_locations)
|
||||
{
|
||||
echo $this->lang->line('recvs_stock_destination');
|
||||
echo form_dropdown('stock_destination', $stock_locations, $stock_destination, 'onchange="$(\'#mode_form\').submit();"');
|
||||
}
|
||||
}
|
||||
?>
|
||||
<?php echo form_close(); ?>
|
||||
|
||||
<?php echo form_open("receivings/add",array('id'=>'add_item_form')); ?>
|
||||
<label id="item_label" for="item">
|
||||
?>
|
||||
<label class='col-sm-2 control-label'><?php echo $this->lang->line('recvs_stock_source'); ?></label>
|
||||
<div class="col-sm-2">
|
||||
<?php echo form_dropdown('stock_source', $stock_locations, $stock_source, array('onchange'=>"$('#mode_form').submit();", 'class'=>'selectpicker show-menu-arrow', 'data-style'=>'btn-default btn-sm', 'data-width'=>'fit')); ?>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
if($mode=='requisition')
|
||||
{
|
||||
?>
|
||||
<label class='col-sm-2 control-label'><?php echo $this->lang->line('recvs_stock_destination'); ?></label>
|
||||
<div class="col-sm-2">
|
||||
<?php echo form_dropdown('stock_destination', $stock_locations, $stock_destination, array('onchange'=>"$('#mode_form').submit();", 'class'=>'selectpicker show-menu-arrow', 'data-style'=>'btn-default btn-sm', 'data-width'=>'fit')); ?>
|
||||
</div>
|
||||
<?php
|
||||
if($mode=='receive' or $mode=='requisition')
|
||||
{
|
||||
echo $this->lang->line('recvs_find_or_scan_item');
|
||||
}
|
||||
else
|
||||
{
|
||||
echo $this->lang->line('recvs_find_or_scan_item_or_receipt');
|
||||
}
|
||||
}
|
||||
?>
|
||||
</label>
|
||||
|
||||
<?php
|
||||
echo form_input(array('name'=>'item','id'=>'item','size'=>'40'));
|
||||
|
||||
echo anchor("items/view/-1/width:450", $this->lang->line('sales_new_item'),
|
||||
array('class'=>'btn btn-info btn-sm pull-right modal-dlg modal-btn-new', 'id'=>'new_item_button', 'title'=>$this->lang->line('sales_new_item')));
|
||||
?>
|
||||
</div>
|
||||
<?php echo form_close(); ?>
|
||||
|
||||
<?php echo form_open("receivings/add", array('id'=>'add_item_form', 'class'=>'form-horizontal panel panel-default')); ?>
|
||||
<div class="panel-body form-group-sm">
|
||||
<label id="item_label" for="item", class='col-sm-2 control-label'>
|
||||
<?php
|
||||
if($mode=='receive' or $mode=='requisition')
|
||||
{
|
||||
echo $this->lang->line('recvs_find_or_scan_item');
|
||||
}
|
||||
else
|
||||
{
|
||||
echo $this->lang->line('recvs_find_or_scan_item_or_receipt');
|
||||
}
|
||||
?>
|
||||
</label>
|
||||
|
||||
<div class="col-sm-6">
|
||||
<?php echo form_input(array('name'=>'item', 'id'=>'item', 'class'=>'form-control input-sm', 'tabindex'=>'1')); ?>
|
||||
</div>
|
||||
|
||||
<?php echo anchor("items/view/-1", $this->lang->line('sales_new_item'),
|
||||
array('class'=>'btn btn-info btn-sm pull-right modal-dlg modal-btn-new', 'id'=>'new_item_button', 'title'=>$this->lang->line('sales_new_item'))); ?>
|
||||
</div>
|
||||
<?php echo form_close(); ?>
|
||||
|
||||
<!-- Receiving Items List -->
|
||||
|
||||
<table id="register">
|
||||
|
||||
@@ -20,36 +20,48 @@ if (isset($success))
|
||||
?>
|
||||
|
||||
<div id="register_wrapper">
|
||||
<?php echo form_open("sales/change_mode", array('id'=>'mode_form')); ?>
|
||||
<label id="mode_label"><?php echo $this->lang->line('sales_mode') ?></label>
|
||||
<?php
|
||||
echo form_dropdown('mode', $modes, $mode, 'onchange="$(\'#mode_form\').submit();"');
|
||||
<?php echo form_open("sales/change_mode", array('id'=>'mode_form', 'class'=>'form-horizontal panel panel-default')); ?>
|
||||
<div class="panel-body form-group-sm">
|
||||
<label class='col-sm-2 control-label'><?php echo $this->lang->line('sales_mode'); ?></label>
|
||||
<div class="col-sm-2">
|
||||
<?php echo form_dropdown('mode', $modes, $mode, array('onchange'=>"$('#mode_form').submit();", 'class'=>'selectpicker show-menu-arrow', 'data-style'=>'btn-default btn-sm', 'data-width'=>'fit')); ?>
|
||||
</div>
|
||||
|
||||
if (count($stock_locations) > 1)
|
||||
{
|
||||
echo $this->lang->line('sales_stock_location');
|
||||
echo form_dropdown('stock_location', $stock_locations, $stock_location, 'onchange="$(\'#mode_form\').submit();"');
|
||||
}
|
||||
<?php
|
||||
if (count($stock_locations) > 1)
|
||||
{
|
||||
?>
|
||||
<label class='col-sm-2 control-label'><?php echo $this->lang->line('sales_stock_location'); ?></label>
|
||||
<div class="col-sm-2">
|
||||
<?php echo form_dropdown('stock_location', $stock_locations, $stock_location, array('onchange'=>"$('#mode_form').submit();", 'class'=>'selectpicker show-menu-arrow', 'data-style'=>'btn-default btn-sm', 'data-width'=>'fit')); ?>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
|
||||
echo anchor("sales/suspended/width:425", $this->lang->line('sales_suspended_sales'),
|
||||
array('class'=>'btn btn-default btn-sm pull-right modal-dlg none', 'id'=>'show_suspended_sales_button', 'title'=>$this->lang->line('sales_suspended_sales')));
|
||||
|
||||
if ($this->Employee->has_grant('reports_sales', $this->session->userdata('person_id')))
|
||||
{
|
||||
echo anchor("sales/manage", $this->lang->line('sales_takings'),
|
||||
array('class'=>'btn btn-primary btn-sm pull-right', 'id'=>'sales_takings_button', 'title'=>$this->lang->line('sales_takings')));
|
||||
}
|
||||
?>
|
||||
<?php echo anchor("sales/suspended", $this->lang->line('sales_suspended_sales'),
|
||||
array('class'=>'btn btn-default btn-sm pull-right modal-dlg none', 'id'=>'show_suspended_sales_button', 'title'=>$this->lang->line('sales_suspended_sales'))); ?>
|
||||
|
||||
<?php
|
||||
if ($this->Employee->has_grant('reports_sales', $this->session->userdata('person_id')))
|
||||
{
|
||||
echo anchor("sales/manage", $this->lang->line('sales_takings'),
|
||||
array('class'=>'btn btn-primary btn-sm pull-right', 'id'=>'sales_takings_button', 'title'=>$this->lang->line('sales_takings')));
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<?php echo form_close(); ?>
|
||||
|
||||
<?php echo form_open("sales/add", array('id'=>'add_item_form')); ?>
|
||||
<label id="item_label" for="item"><?php echo $this->lang->line('sales_find_or_scan_item_or_receipt'); ?></label>
|
||||
<?php
|
||||
echo form_input(array('name'=>'item', 'id'=>'item', 'size'=>'40', 'tabindex'=>'1'));
|
||||
<?php echo form_open("sales/add", array('id'=>'add_item_form', 'class'=>'form-horizontal panel panel-default')); ?>
|
||||
<div class="panel-body form-group-sm">
|
||||
<label id="item_label" for="item", class='col-sm-2 control-label'><?php echo $this->lang->line('sales_find_or_scan_item_or_receipt'); ?></label>
|
||||
<div class="col-sm-6">
|
||||
<?php echo form_input(array('name'=>'item', 'id'=>'item', 'class'=>'form-control input-sm', 'tabindex'=>'1')); ?>
|
||||
</div>
|
||||
|
||||
echo anchor("items/view/-1/width:450", $this->lang->line('sales_new_item'),
|
||||
array('class'=>'btn btn-info btn-sm pull-right modal-dlg modal-btn-new', 'id'=>'new_item_button', 'title'=>$this->lang->line('sales_new_item')));
|
||||
?>
|
||||
<?php echo anchor("items/view/-1", $this->lang->line('sales_new_item'),
|
||||
array('class'=>'btn btn-info btn-sm pull-right modal-dlg modal-btn-new', 'id'=>'new_item_button', 'title'=>$this->lang->line('sales_new_item'))); ?>
|
||||
</div>
|
||||
<?php echo form_close(); ?>
|
||||
|
||||
<!-- Sale Items List -->
|
||||
@@ -265,7 +277,7 @@ if (isset($success))
|
||||
?>
|
||||
<div id="finish_sale">
|
||||
<label id="comment_label" for="comment"><?php echo $this->lang->line('common_comments'); ?>:</label>
|
||||
<?php echo form_textarea(array('name'=>'comment', 'id'=>'comment', 'value'=>$comment, 'rows'=>'4', 'cols'=>'23'));?>
|
||||
<?php echo form_textarea(array('name'=>'comment', 'id'=>'comment', 'value'=>$comment, 'rows'=>'4', 'cols'=>'23')); ?>
|
||||
<br />
|
||||
<br />
|
||||
<?php
|
||||
@@ -286,7 +298,7 @@ if (isset($success))
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<?php
|
||||
<?php
|
||||
echo form_close();
|
||||
}
|
||||
?>
|
||||
@@ -451,8 +463,7 @@ $(document).ready(function()
|
||||
|
||||
var clear_fields = function()
|
||||
{
|
||||
if ($(this).val().match("<?php echo $this->lang->line('sales_start_typing_item_name') . '|' .
|
||||
$this->lang->line('sales_start_typing_customer_name'); ?>"))
|
||||
if ($(this).val().match("<?php echo $this->lang->line('sales_start_typing_item_name') . '|' . $this->lang->line('sales_start_typing_customer_name'); ?>"))
|
||||
{
|
||||
$(this).val('');
|
||||
}
|
||||
@@ -552,7 +563,7 @@ $(document).ready(function()
|
||||
}
|
||||
});
|
||||
|
||||
$( "#finish_sale_button" ).keypress(function( event ) {
|
||||
$("#finish_sale_button").keypress(function( event ) {
|
||||
if ( event.which == 13 ) {
|
||||
if (confirm('<?php echo $this->lang->line("sales_confirm_finish_sale"); ?>'))
|
||||
{
|
||||
|
||||
@@ -7,32 +7,17 @@
|
||||
|
||||
#mode_form, #add_item_form
|
||||
{
|
||||
position: relative;
|
||||
width: 100%;
|
||||
padding: 10px 5px 10px 5px;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
#mode_form .panel-body, #add_item_form .panel-body
|
||||
{
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
#mode_form
|
||||
{
|
||||
background-color: #DDD;
|
||||
padding-bottom: 15px;
|
||||
}
|
||||
|
||||
#mode_form label
|
||||
{
|
||||
font-weight: bold;
|
||||
margin: 0px 5px 0px 5px;
|
||||
}
|
||||
|
||||
#sales_takings_button, #show_suspended_sales_button, #new_item_button
|
||||
{
|
||||
position: relative;
|
||||
bottom: 4px;
|
||||
}
|
||||
|
||||
#sales_takings_button
|
||||
{
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
#add_item_form
|
||||
@@ -40,21 +25,14 @@
|
||||
background-color: #BBB;
|
||||
}
|
||||
|
||||
#add_item_form input
|
||||
#item_label
|
||||
{
|
||||
border: 1px solid #CCC;
|
||||
padding: 2px;
|
||||
padding-top: 0;
|
||||
}
|
||||
|
||||
#add_item_form label
|
||||
#sales_takings_button
|
||||
{
|
||||
font-weight: bold;
|
||||
margin: 0px 5px 0px 5px;
|
||||
}
|
||||
|
||||
#customer_label
|
||||
{
|
||||
font-weight: bold;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
#register
|
||||
|
||||
6
dist/opensourcepos.min.css
vendored
6
dist/opensourcepos.min.css
vendored
File diff suppressed because one or more lines are too long
@@ -65,7 +65,7 @@
|
||||
<![endif]-->
|
||||
<link rel="stylesheet" type="text/css" href="templates/spacelab/css/bootstrap.min.css?rel=9ed20b1ee8"/>
|
||||
<!-- start mincss template tags -->
|
||||
<link rel="stylesheet" type="text/css" href="dist/opensourcepos.min.css?rel=aabc76522f"/>
|
||||
<link rel="stylesheet" type="text/css" href="dist/opensourcepos.min.css?rel=1d6d6ab1bf"/>
|
||||
<!-- end mincss template tags -->
|
||||
<link rel="stylesheet" type="text/css" href="templates/spacelab/css/style.css"/>
|
||||
<!-- start minjs template tags -->
|
||||
|
||||
Reference in New Issue
Block a user