我有2个文本字段和1个下拉框,如果我在第一个文本框中选择了日期,那么我必须从下拉列表中选择年份。
那么如何从下拉菜单中自动填写下一年的第二个文本框中的下一个日期。
这是文本框代码
<div class="input-group">
<span class="input-group-addon"><i class="glyphicon glyphicon-tent"></i></span>
<input type="text" name="purchese_date" id="tbDate" class="pwaf form-control" value="<?php echo isset($_POST['purchese_date']) ? $_POST['purchese_date'] : '' ?>" placeholder="Enter Purchese Date eg:dd/mm/yyyy"/>
</div>
<br/>
<div class="form-group">
<select class="form-control pwafs" name="year">
<option value="#">- Select Year-</option>
<option value="1"> 1</option>
<option value="2"> 2</option>
<option value="3"> 3</option>
<option value="4"> 4</option>
<option value="5"> 5</option>
<option value="6"> 6</option>
<option value="7"> 7</option>
<option value="8"> 8</option>
<option value="9"> 9</option>
<option value="10"> 10</option>
</select>
</div>
<div class="input-group">
<span class="input-group-addon"><i class="glyphicon glyphicon-blackboard"></i></span>
<input type="text" name="renual_date" id="tbDate" class="form-control pwafr" value="<?php echo isset($_POST['renual_date']) ? $_POST['renual_date'] : '' ?>" placeholder="Enter Renual Date eg:dd/mm/yyyy"/>
</div>
<br/>
<div class="input-group">
<span class="input-group-addon"><i class="glyphicon glyphicon-th-list"></i></span>
<input type="text" name="customer_id" id="tbDate" class="form-control" value="<?php echo isset($_POST['customer_id']) ? $_POST['customer_id'] : '' ?>" placeholder="Enter Customer Id"/>
</div>
<br/>
这是php代码
<?php
$domains = new domains;
if (isset($_POST['add-domain'])) {
//print_r($_POST['email']);
//exit;
$errors = $domains->validate_domains_members();
if (count($errors)) {
$emsg = $errors;
$eclass = "alert-danger";
} else {
if ($domains->save($domains->table, $_POST)) {
unset($_POST);
$emsg = "User Added Successfully";
$eclass = "alert-success";
}
}
}
?>
<?php if (isset($emsg)) { ?>
<div class="alert <?php echo $eclass; ?>"><?php echo $emsg; ?></div>
<?php } ?>
答案 0 :(得分:0)
试试这个
@JsonInclude(Include.NON_NULL)
public class UpdateEMDRequest {
@JsonProperty("UniqueTransactionReference")
private String uniqueTransactionReference;
@JsonProperty("TransactionStatus")
private String transactionStatus;
@JsonProperty("PreAuthReference")
private String preAuthReference;
@JsonProperty("BookingReference")
private String bookingReference;
@JsonProperty("CarrierCode")
private String carrierCode;
@JsonProperty("TransactionMode")
private String transactionMode;
@JsonProperty("CallBackUrl")
private String callBackUrl;
@JsonProperty("Offers")
private List<Offers> offers;
}