mirror of https://github.com/itflow-org/itflow
Remove Currency Selection from invoice, quote and recurring as this will be determined by your company currency in settings, the payment is what matters as this is where it will be converted
This commit is contained in:
parent
4e4455d219
commit
209bd7da4d
|
|
@ -277,7 +277,7 @@
|
|||
<div class="tab-pane fade" id="pills-notes">
|
||||
|
||||
<div class="form-group">
|
||||
<textarea class="form-control" rows="8" name="notes"></textarea>
|
||||
<textarea class="form-control" rows="8" placeholder="Enter some notes" name="notes"></textarea>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -77,21 +77,6 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label>Currency <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-money-bill"></i></span>
|
||||
</div>
|
||||
<select class="form-control select2" name="currency_code" required>
|
||||
<option value="">- Currency -</option>
|
||||
<?php foreach($currencies_array as $currency_code => $currency_name) { ?>
|
||||
<option <?php if(isset($_GET['client_id']) AND $client_currency_code == $currency_code){ echo "selected"; }elseif($config_default_currency == $currency_code){ echo "selected"; } ?> value="<?php echo $currency_code; ?>"><?php echo "$currency_code - $currency_name"; ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label>Scope</label>
|
||||
<div class="input-group">
|
||||
|
|
|
|||
|
|
@ -163,7 +163,7 @@
|
|||
<div class="tab-pane fade" id="pills-notes">
|
||||
|
||||
<div class="form-group">
|
||||
<textarea class="form-control" rows="8" name="note"></textarea>
|
||||
<textarea class="form-control" rows="8" placeholder="Enter some notes" name="note"></textarea>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -78,21 +78,6 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label>Currency <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-money-bill"></i></span>
|
||||
</div>
|
||||
<select class="form-control select2" name="currency_code" required>
|
||||
<option value="">- Currency -</option>
|
||||
<?php foreach($currencies_array as $currency_code => $currency_name) { ?>
|
||||
<option <?php if(isset($_GET['client_id']) AND $client_currency_code == $currency_code){ echo "selected"; }elseif($config_default_currency == $currency_code){ echo "selected"; } ?> value="<?php echo $currency_code; ?>"><?php echo "$currency_code - $currency_name"; ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label>Scope</label>
|
||||
<div class="input-group">
|
||||
|
|
|
|||
|
|
@ -92,21 +92,6 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label>Currency <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-money-bill"></i></span>
|
||||
</div>
|
||||
<select class="form-control select2" name="currency_code" required>
|
||||
<option value="">- Currency -</option>
|
||||
<?php foreach($currencies_array as $currency_code => $currency_name) { ?>
|
||||
<option <?php if(isset($_GET['client_id']) AND $client_currency_code == $currency_code){ echo "selected"; }elseif($config_default_currency == $currency_code){ echo "selected"; } ?> value="<?php echo $currency_code; ?>"><?php echo "$currency_code - $currency_name"; ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label>Scope</label>
|
||||
<div class="input-group">
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@
|
|||
|
||||
<div class="tab-pane fade" id="pills-notes">
|
||||
|
||||
<textarea class="form-control" rows="8" name="notes"></textarea>
|
||||
<textarea class="form-control" rows="8" placeholder="Enter some notes" name="notes"></textarea>
|
||||
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -184,7 +184,7 @@
|
|||
<div class="tab-pane fade" id="pills-notes">
|
||||
|
||||
<div class="form-group">
|
||||
<textarea class="form-control" rows="8" name="notes"></textarea>
|
||||
<textarea class="form-control" rows="8" placeholder="Enter some notes" name="notes"></textarea>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@
|
|||
$row = mysqli_fetch_array($sql);
|
||||
|
||||
$session_company_name = $row['company_name'];
|
||||
$session_company_currency = $row['company_currency'];
|
||||
|
||||
include("get_settings.php");
|
||||
|
||||
|
|
|
|||
|
|
@ -277,7 +277,7 @@
|
|||
<div class="tab-pane fade" id="pills-notes<?php echo $asset_id; ?>">
|
||||
|
||||
<div class="form-group">
|
||||
<textarea class="form-control" rows="8" name="notes"><?php echo $asset_notes; ?></textarea>
|
||||
<textarea class="form-control" rows="8" placeholder="Enter some notes" name="notes"><?php echo $asset_notes; ?></textarea>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -172,7 +172,7 @@
|
|||
<div class="tab-pane fade" id="pills-notes<?php echo $login_id; ?>">
|
||||
|
||||
<div class="form-group">
|
||||
<textarea class="form-control" rows="8" name="note"><?php echo $login_note; ?></textarea>
|
||||
<textarea class="form-control" rows="8" placeholder="Enter some notes" name="note"><?php echo $login_note; ?></textarea>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@
|
|||
|
||||
<div class="tab-pane fade" id="pills-notes<?php echo $software_id; ?>">
|
||||
|
||||
<textarea class="form-control" rows="8" name="notes"><?php echo $software_notes; ?></textarea>
|
||||
<textarea class="form-control" rows="8" placeholder="Enter some notes" name="notes"><?php echo $software_notes; ?></textarea>
|
||||
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -182,7 +182,7 @@
|
|||
<div class="tab-pane fade" id="pills-notes<?php echo $vendor_id; ?>">
|
||||
|
||||
<div class="form-group">
|
||||
<textarea class="form-control" rows="8" name="notes"><?php echo $vendor_notes; ?></textarea>
|
||||
<textarea class="form-control" rows="8" placeholder="Enter some notes" name="notes"><?php echo $vendor_notes; ?></textarea>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
|
|
|||
7
post.php
7
post.php
|
|
@ -1732,7 +1732,6 @@ if(isset($_POST['add_invoice'])){
|
|||
$client = intval($_POST['client']);
|
||||
$date = trim(strip_tags(mysqli_real_escape_string($mysqli,$_POST['date'])));
|
||||
$category = intval($_POST['category']);
|
||||
$currency_code = trim(strip_tags(mysqli_real_escape_string($mysqli,$_POST['currency_code'])));
|
||||
$scope = trim(strip_tags(mysqli_real_escape_string($mysqli,$_POST['scope'])));
|
||||
|
||||
//Get Net Terms
|
||||
|
|
@ -1748,7 +1747,7 @@ if(isset($_POST['add_invoice'])){
|
|||
//Generate a unique URL key for clients to access
|
||||
$url_key = keygen();
|
||||
|
||||
mysqli_query($mysqli,"INSERT INTO invoices SET invoice_prefix = '$config_invoice_prefix', invoice_number = $invoice_number, invoice_scope = '$scope', invoice_date = '$date', invoice_due = DATE_ADD('$date', INTERVAL $client_net_terms day), invoice_currency_code = '$currency_code', invoice_category_id = $category, invoice_status = 'Draft', invoice_url_key = '$url_key', invoice_created_at = NOW(), invoice_client_id = $client, company_id = $session_company_id");
|
||||
mysqli_query($mysqli,"INSERT INTO invoices SET invoice_prefix = '$config_invoice_prefix', invoice_number = $invoice_number, invoice_scope = '$scope', invoice_date = '$date', invoice_due = DATE_ADD('$date', INTERVAL $client_net_terms day), invoice_currency_code = '$config_default_currency', invoice_category_id = $category, invoice_status = 'Draft', invoice_url_key = '$url_key', invoice_created_at = NOW(), invoice_client_id = $client, company_id = $session_company_id");
|
||||
$invoice_id = mysqli_insert_id($mysqli);
|
||||
|
||||
mysqli_query($mysqli,"INSERT INTO history SET history_date = CURDATE(), history_status = 'Draft', history_description = 'INVOICE added!', history_created_at = NOW(), history_invoice_id = $invoice_id, company_id = $session_company_id");
|
||||
|
|
@ -1903,7 +1902,7 @@ if(isset($_POST['add_quote'])){
|
|||
//Generate a unique URL key for clients to access
|
||||
$quote_url_key = keygen();
|
||||
|
||||
mysqli_query($mysqli,"INSERT INTO quotes SET quote_prefix = '$config_quote_prefix', quote_number = $quote_number, quote_scope = '$scope', quote_date = '$date', quote_currency_code = '$currency_code', quote_category_id = $category, quote_status = 'Draft', quote_url_key = '$quote_url_key', quote_created_at = NOW(), quote_client_id = $client, company_id = $session_company_id");
|
||||
mysqli_query($mysqli,"INSERT INTO quotes SET quote_prefix = '$config_quote_prefix', quote_number = $quote_number, quote_scope = '$scope', quote_date = '$date', quote_currency_code = '$config_default_currency', quote_category_id = $category, quote_status = 'Draft', quote_url_key = '$quote_url_key', quote_created_at = NOW(), quote_client_id = $client, company_id = $session_company_id");
|
||||
|
||||
$quote_id = mysqli_insert_id($mysqli);
|
||||
|
||||
|
|
@ -2322,7 +2321,7 @@ if(isset($_POST['add_recurring'])){
|
|||
$new_config_recurring_next_number = $config_recurring_next_number + 1;
|
||||
mysqli_query($mysqli,"UPDATE settings SET config_recurring_next_number = $new_config_recurring_next_number WHERE company_id = $session_company_id");
|
||||
|
||||
mysqli_query($mysqli,"INSERT INTO recurring SET recurring_prefix = '$config_recurring_prefix', recurring_number = $recurring_number, recurring_scope = '$scope', recurring_frequency = '$frequency', recurring_next_date = '$start_date', recurring_category_id = $category, recurring_status = 1, recurring_currency_code = '$currency_code', recurring_created_at = NOW(), recurring_client_id = $client, company_id = $session_company_id");
|
||||
mysqli_query($mysqli,"INSERT INTO recurring SET recurring_prefix = '$config_recurring_prefix', recurring_number = $recurring_number, recurring_scope = '$scope', recurring_frequency = '$frequency', recurring_next_date = '$start_date', recurring_category_id = $category, recurring_status = 1, recurring_currency_code = '$config_default_currency', recurring_created_at = NOW(), recurring_client_id = $client, company_id = $session_company_id");
|
||||
|
||||
$recurring_id = mysqli_insert_id($mysqli);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue