FIC_Solar/SolarPower/Views/PowerStation/PowerStationAdd.cshtml
2021-06-14 15:35:02 +08:00

163 lines
11 KiB
Plaintext

<!-- Your main content goes below here: -->
<div class="row">
<div class="col-xl-12">
<div id="panel-5" class="panel">
<div class="panel-container show">
<div class="panel-content">
<div class="tab-content p-3">
<div class="row mb-5">
<div class="card border mb-g w-100">
<!-- notice the additions of utility paddings and display properties on .card-header -->
<div class="card-header bg-fusion-50 pr-3 d-flex align-items-center flex-wrap justify-content-between">
<!-- we wrap header title inside a div tag with utility padding -->
<div class="card-title font-weight-bold">電站基本資料</div>
<div class="text-right">
<a href="javascript:;" class="btn btn-sm btn-info ml-auto waves-effect waves-themed">
<span class="fal fa-cog mr-1"></span> 儲存
</a>
</div>
</div>
<div class="card-body">
<div class="row d-flex justify-content-between">
<div class="col-xl-2 justify-content-center">
<label class="form-label" for="power_station_id">電站編號</label>
<input type="text" id="power_station_id" name="power_station_id" disabled="disabled" class="form-control">
</div>
<div class="col-xl-2 justify-content-center">
<label class="form-label" for="power_station_name">電站名稱</label>
<input type="text" id="power_station_name" name="power_station_name" class="form-control">
</div>
<div class="col-xl-2 justify-content-center">
<p>是否為代管:</p>
<p class="color-info-600">
<div class="custom-control custom-switch">
<input type="checkbox" class="custom-control-input" id="IsEscrow" name="IsEscrow">
<label class="custom-control-label" for="IsEscrow" id="IsEscrowLabel">No</label>
</div>
</p>
</div>
<div class="col-xl-2 justify-content-center">
<label class="form-label" for="ElectricityMeterAt">台電掛錶日</label>
<input type="date" id="ElectricityMeterAt" name="ElectricityMeterAt" class="form-control">
</div>
<div class="col-xl-2 justify-content-center">
<label class="form-label" for="EstimatedRecoveryTime">預計回收年限</label>
<input type="text" id="EstimatedRecoveryTime" name="EstimatedRecoveryTime" class="form-control">
</div>
</div>
<div class="row d-flex justify-content-between mb-5">
<div class="col-xl-2 justify-content-center">
<label class="form-label" for="GeneratingCapacity">電廠發電容量</label>
<input type="text" id="GeneratingCapacity" name="GeneratingCapacity" class="form-control">
</div>
<div class="col-xl-2 justify-content-center">
<label class="form-label" for="power_station_operation_personnel">運維人員</label>
<br />
<select class="js-example-basic-multiple form-control" id="power_station_operation_personnel" multiple="multiple">
</select>
</div>
<div class="col-xl-2 justify-content-center">
<label class="form-label" for="EscrowName">被代管公司</label>
<input type="text" id="EscrowName" name="EscrowName" class="form-control" disabled="disabled">
</div>
<div class="col-xl-2 justify-content-center">
<label class="form-label" for="PowerRate">授電費率</label>
<input type="text" id="PowerRate" name="PowerRate" class="form-control">
</div>
<div class="col-xl-2 justify-content-center">
<label class="form-label" for="Coordinate">座標</label>
<input type="text" id="Coordinate" name="Coordinate" class="form-control">
</div>
</div>
<div class="row">
<div class="col-xl-6">
<h5 class="border-bottom font-weight-bold mb-3 pl-5 pb-3">逆變器</h5>
<div class="row d-flex justify-content-between px-5">
<div class="col-xl-4">
<label class="form-label" for="InverterBrand">廠牌</label>
<input type="text" id="InverterBrand" name="InverterBrand" class="form-control">
</div>
<div class="col-xl-4">
<label class="form-label" for="InverterProductModel">型號</label>
<input type="text" id="InverterProductModel" name="InverterProductModel" class="form-control">
</div>
<div class="col-xl-4">
<label class="form-label" for="InverterAmount">數量</label>
<input type="text" id="InverterAmount" name="InverterAmount" class="form-control">
</div>
</div>
</div>
<div class="col-xl-6">
<h5 class="border-bottom font-weight-bold mb-3 pl-5 pb-3">光電板</h5>
<div class="row d-flex justify-content-between px-5">
<div class="col-xl-4">
<label class="form-label" for="PhotovoltaicPanelBrand">廠牌</label>
<input type="text" id="PhotovoltaicPanelBrand" name="PhotovoltaicPanelBrand" class="form-control">
</div>
<div class="col-xl-4">
<label class="form-label" for="PhotovoltaicPanelSpecification">規格</label>
<input type="text" id="PhotovoltaicPanelSpecification" name="PhotovoltaicPanelSpecification" class="form-control">
</div>
<div class="col-xl-4">
<label class="form-label" for="PhotovoltaicPanelAmount">數量</label>
<input type="text" id="PhotovoltaicPanelAmount" name="PhotovoltaicPanelAmount" class="form-control">
</div>
<div class="col-xl-4">
<label class="form-label" for="PhotovoltaicPanelProductModel">型號</label>
<input type="text" id="PhotovoltaicPanelProductModel" name="PhotovoltaicPanelProductModel" class="form-control">
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
@section Scripts{
<script>
//#region 預先載入公司下拉式選單select_option
var url_user_select_option = "/PowerStation/GetUserSelectOptionList";
$.get(url_user_select_option, function (rel) {
if (rel.code != "0000") {
toast_error(rel.msg);
return;
}
$("#power_station_operation_personnel").empty();
$.each(rel.data, function (index, val) {
$("#power_station_operation_personnel").append($("<option />").val(val.value).text(val.text));
});
//預設查詢第一個
$("#power_station_operation_personnel").val($("#power_station_operation_personnel option:first").val());
});
//#endregion
$('.js-example-basic-multiple').select2();
$("#IsEscrow").click(function () {
if ($(this).prop("checked")) {
$('#IsEscrowLabel').html("Yes");
$("#EscrowName").attr('disabled', false)
} else {
$('#IsEscrowLabel').html("No");
$("#EscrowName").attr('disabled', true)
}
});
</script>
}