Post by jadenronnie » Mon Jul 04, 2016 1:05 am

Helo!

I have edited return.tpl by removing reason to return and opened or not check boxes, Now the problem is as i have removed those codes but controller is noticing as those were rquired fields which can't be empty so the form is not working, can you help me to modify that code so that controller start working. Thanks in advance :)

Newbie

Posts

Joined
Mon Jun 20, 2016 8:41 pm

Post by cyclops12 » Mon Jul 04, 2016 1:45 am

jadenronnie wrote:Helo!

I have edited return.tpl
what version are you using and what file exactly did you edit as i cant see a return.tpl

also what code did you remove?

Expert Member

Posts

Joined
Sun Sep 27, 2015 1:10 am

Post by OSWorX » Mon Jul 04, 2016 2:01 am

Simply remove the checks inside the controller too.

Full Stack Web Developer :: Dedicated OpenCart Development & Support DACH Region
Contact for Custom Work / Fast Support.


User avatar
Administrator

Posts

Joined
Mon Jan 11, 2010 10:52 pm
Location - Austria

Post by jadenronnie » Mon Jul 04, 2016 2:48 am

Hi Thanks guys here is code i edited inside template/account/return_form.tpl

<div class="form-group">
<label class="col-sm-2 control-label" for="input-quantity"><?php echo $entry_quantity; ?></label>
<div class="col-sm-10">
<input type="text" name="quantity" value="<?php echo $quantity; ?>" placeholder="<?php echo $entry_quantity; ?>" id="input-quantity" class="form-control" />
</div>
</div>
DELETED FROM HERE TO:
<div class="form-group required">
<label class="col-sm-2 control-label"><?php echo $entry_reason; ?></label>
<div class="col-sm-10">
<?php foreach ($return_reasons as $return_reason) { ?>
<?php if ($return_reason['return_reason_id'] == $return_reason_id) { ?>
<div class="radio">
<label>
<input type="radio" name="return_reason_id" value="<?php echo $return_reason['return_reason_id']; ?>" checked="checked" />
<?php echo $return_reason['name']; ?></label>
</div>
<?php } else { ?>
<div class="radio">
<label>
<input type="radio" name="return_reason_id" value="<?php echo $return_reason['return_reason_id']; ?>" />
<?php echo $return_reason['name']; ?></label>
</div>
<?php } ?>
<?php } ?>
<?php if ($error_reason) { ?>
<div class="text-danger"><?php echo $error_reason; ?></div>
<?php } ?>
</div>
</div>
<div class="form-group required">
<label class="col-sm-2 control-label"><?php echo $entry_opened; ?></label>
<div class="col-sm-10">
<label class="radio-inline">
<?php if ($opened) { ?>
<input type="radio" name="opened" value="1" checked="checked" />
<?php } else { ?>
<input type="radio" name="opened" value="1" />
<?php } ?>
<?php echo $text_yes; ?></label>
<label class="radio-inline">
<?php if (!$opened) { ?>
<input type="radio" name="opened" value="0" checked="checked" />
<?php } else { ?>
<input type="radio" name="opened" value="0" />
<?php } ?>
<?php echo $text_no; ?></label>
</div>
</div>
TO HERE
<div class="form-group">
<label class="col-sm-2 control-label" for="input-comment"><?php echo $entry_fault_detail; ?></label>
<div class="col-sm-10">
<textarea name="comment" rows="10" placeholder="<?php echo $entry_fault_detail; ?>" id="input-comment" class="form-control"><?php echo $comment; ?></textarea>

and changed into

Code: Select all

          <div class="form-group">
            <label class="col-sm-2 control-label" for="input-quantity"><?php echo $entry_quantity; ?></label>
            <div class="col-sm-9">
              <input type="text" name="quantity" value="<?php echo $quantity; ?>" placeholder="<?php echo $entry_quantity; ?>" id="input-quantity" class="form-control" />
            </div>
          </div>
          <div class="form-group" required>
            <label class="col-sm-2 control-label" for="input-comment"><?php echo $entry_fault_detail; ?></label>
            <div class="col-sm-9">
              <textarea name="comment" rows="10" placeholder="<?php echo $entry_fault_detail; ?>" id="input-comment" class="form-control"><?php echo $comment; ?></textarea>

Newbie

Posts

Joined
Mon Jun 20, 2016 8:41 pm

Post by jadenronnie » Mon Jul 04, 2016 2:53 am

Also OC version is 2.0.1.0

Newbie

Posts

Joined
Mon Jun 20, 2016 8:41 pm

Post by jadenronnie » Mon Jul 04, 2016 2:55 am

OSWorX wrote:Simply remove the checks inside the controller too.
I'm not sure about which codes do i have to remove, i tried but not working

Newbie

Posts

Joined
Mon Jun 20, 2016 8:41 pm

Post by straightlight » Mon Jul 04, 2016 7:35 am

The subject you're reporting is not about a bug but modifications you wish to add.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON
Who is online

Users browsing this forum: No registered users and 4 guests