168 lines
8.6 KiB
Plaintext
168 lines
8.6 KiB
Plaintext
@using Resources
|
|
@model Qcarbon.ViewModels.DTO.RiskMaterialViewModel
|
|
@{
|
|
ViewBag.Title = "Index";
|
|
Layout = "~/Areas/Lca/Views/Shared/_LcaRiskLayout.cshtml";
|
|
}
|
|
|
|
@* the detail modal form *@
|
|
@using (Html.BeginForm())
|
|
{
|
|
@Html.AntiForgeryToken()
|
|
@Html.HiddenFor(x=>x.cmd, new { @id="cmd"})
|
|
@Html.HiddenFor(x=>x.singleRec.LCAID)
|
|
<div class="survey_form container" style="padding: 0 16px;">
|
|
<div class="add_survey_body">
|
|
<div class="add_survey_header_title"></div>
|
|
<div class="survey_info">
|
|
<div class="title">
|
|
新增原物料
|
|
</div>
|
|
<div class="survey_content">
|
|
@Html.ValidationSummary(false, "", new { @class="text-danger", style="margin-left:15px;font-weight: bold;" })
|
|
</div>
|
|
<div class="survey_content">
|
|
<div class="row">
|
|
<label class="col-sm-4 col-form-label">@Resource.MaterialNo</label>
|
|
<div class="col col-sm-8">
|
|
@Html.EditorFor(x=>x.singleRec.MaterialNo, new { htmlAttributes = new { placeholder = Resource.RequiredMessage}})
|
|
@*<input name="materialNo"
|
|
type="text"
|
|
placeholder="@Resource.RequiredMessage"
|
|
required
|
|
ng-model="selectRow.toBeEdit.MaterialNo">*@
|
|
</div>
|
|
</div>
|
|
|
|
<div class="row">
|
|
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialName</label>
|
|
<div class="col col-sm-8">
|
|
@Html.EditorFor(x => x.singleRec.MaterialName, new { htmlAttributes = new { placeholder = Resource.RequiredMessage } })
|
|
@*<input type="text" ng-model="selectRow.toBeEdit.MaterialName" />*@
|
|
</div>
|
|
<div class="validation_block"></div>
|
|
</div>
|
|
<div class="row">
|
|
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialSpec</label>
|
|
<div class="col col-sm-8">
|
|
@Html.EditorFor(x => x.singleRec.MaterialSpec, new { htmlAttributes = new { onchange = "onVarChange()", placeholder = Resource.RequiredMessage, type="number", step="any" } })
|
|
@*<input name="materialSpec"
|
|
type="number" step="any"
|
|
max="{{CONSTANTS.MAXNUMVALUE}}"
|
|
placeholder="@Resource.RequiredMessage"
|
|
required
|
|
ng-model="selectRow.toBeEdit.MaterialSpec"
|
|
ng-change="calcActivityAndEmission(selectRow.toBeEdit)">*@
|
|
</div>
|
|
</div>
|
|
|
|
<div class="row">
|
|
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialPCS</label>
|
|
<div class="col col-sm-8">
|
|
@Html.EditorFor(x => x.singleRec.AnnualPurchaseAmount, new { htmlAttributes = new { onchange = "onVarChange()", placeholder = Resource.RequiredMessage, type = "number", step = "any" } })
|
|
@*<input name="annualPurchaseAmount"
|
|
type="number" step="any"
|
|
placeholder="@Resource.RequiredMessage"
|
|
required
|
|
max="{{CONSTANTS.MAXNUMVALUE}}"
|
|
ng-model="selectRow.toBeEdit.AnnualPurchaseAmount"
|
|
ng-change="calcActivityAndEmission(selectRow.toBeEdit)">*@
|
|
</div>
|
|
</div>
|
|
|
|
<div class="row">
|
|
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialScalar (@Resource.KgCO2e)</label>
|
|
<div class="col col-sm-8">
|
|
@Html.EditorFor(x => x.singleRec.KgCO2e, new { htmlAttributes = new { onchange = "onVarChange()", placeholder = Resource.RequiredMessage, type = "number", step = "any" } })
|
|
@*<input name="kgCO2e"
|
|
type="number" step="any"
|
|
max="{{CONSTANTS.MAXNUMVALUE}}"
|
|
placeholder="@Resource.RequiredMessage"
|
|
required
|
|
ng-model="selectRow.toBeEdit.KgCO2e"
|
|
ng-change="calcEmission(selectRow.toBeEdit)">*@
|
|
<div class="header_image_button simapro-image-button"
|
|
click="selectSimaproProcess(selectRow.toBeEdit)">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="row">
|
|
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialActivity</label>
|
|
<div class="col col-sm-8">
|
|
@Html.EditorFor(x => x.singleRec.ActivityIntensity, new { htmlAttributes = new {@readonly = "readonly" } })
|
|
@*<input name="activityIntensity"
|
|
type="number" step="any"
|
|
readonly="readonly"
|
|
ng-model="selectRow.toBeEdit.ActivityIntensity">*@
|
|
</div>
|
|
</div>
|
|
|
|
<div class="row">
|
|
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialQty (@Resource.KgCO2e)</label>
|
|
<div class="col col-sm-8">
|
|
@Html.EditorFor(x => x.singleRec.Emission, new { htmlAttributes = new { @readonly = "readonly" } })
|
|
@*<input name="emission"
|
|
type="number" step="any"
|
|
readonly="readonly"
|
|
ng-model="selectRow.toBeEdit.Emission">*@
|
|
</div>
|
|
</div>
|
|
|
|
@*<div class="row">
|
|
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialAddressUnit</label>
|
|
<div class="col col-sm-8">
|
|
<input name="unit"
|
|
type="text"
|
|
required
|
|
placeholder="@Resource.RequiredMessage"
|
|
ng-model="selectRow.toBeEdit.Unit">
|
|
</div>
|
|
</div>*@
|
|
|
|
<div class="row">
|
|
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialActivityUnit</label>
|
|
<div class="col col-sm-8">
|
|
@Html.EditorFor(x => x.singleRec.Unit, new { htmlAttributes = new { placeholder = Resource.RequiredMessage } })
|
|
@*<input name="activityIntensityUnit"
|
|
type="text"
|
|
required
|
|
placeholder="@Resource.RequiredMessage"
|
|
ng-model="selectRow.toBeEdit.ActivityIntensityUnit">*@
|
|
</div>
|
|
</div>
|
|
|
|
<div class="row">
|
|
<label class="col-sm-4 col-form-label">@Resource.RAIntlTravelRemark</label>
|
|
<div class="col col-sm-8">
|
|
@Html.EditorFor(x => x.singleRec.Comment)
|
|
@*<input type="text"
|
|
ng-model="selectRow.toBeEdit.Comment">*@
|
|
</div>
|
|
</div>
|
|
|
|
<div class="row">
|
|
<div class="survey_content" >
|
|
<button class="header_button"
|
|
type="button" onclick="$('#cmd').val('儲存');$('form').submit();">
|
|
@Resource.StaticLabelGlobal_Save
|
|
</button>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
}
|
|
<script>
|
|
function onVarChange() {
|
|
console.log('onVarChange');
|
|
}
|
|
//活動強度=採購數量(PCS)*物料規格
|
|
|
|
//排放量=活動強度*係數
|
|
|
|
//係數選擇icon
|
|
</script>
|