|
|
|
|
@ -1,15 +1,11 @@
|
|
|
|
|
@model BookQuery
|
|
|
|
|
@{
|
|
|
|
|
ViewData["Title"] = SR["Book "+ViewBag.Activity.Code];
|
|
|
|
|
}
|
|
|
|
|
@section header{
|
|
|
|
|
@{ await Html.RenderPartialAsync("_ValidationScriptsPartial"); }
|
|
|
|
|
@{ ViewData["Title"] = SR["Book "+ViewBag.Activity.Code]; }
|
|
|
|
|
|
|
|
|
|
<script src="https://maps.googleapis.com/maps/api/js?key=@ViewBag.GoogleSettings.BrowserApiKey"></script>
|
|
|
|
|
<script type="text/javascript" src="~/lib/moment/moment-with-locales.min.js"></script>
|
|
|
|
|
<script type="text/javascript" src="~/lib/eonasdan-bootstrap-datetimepicker/js/bootstrap-datetimepicker.min.js"></script>
|
|
|
|
|
<link rel="stylesheet" href="~/lib/eonasdan-bootstrap-datetimepicker/css/bootstrap-datetimepicker.min.css" />
|
|
|
|
|
|
|
|
|
|
@section header {
|
|
|
|
|
<style>
|
|
|
|
|
#map {
|
|
|
|
|
width: 100%;
|
|
|
|
|
@ -56,7 +52,7 @@ $(document).ready(function(){
|
|
|
|
|
$('#' + config.latId).val(lat.toLocaleString('en'));
|
|
|
|
|
$('#' + config.longId).val(lng.toLocaleString('en'));
|
|
|
|
|
gmap.setCenter(pos);
|
|
|
|
|
if (marker) {
|
|
|
|
|
if (marker) {
|
|
|
|
|
marker.setMap(null);
|
|
|
|
|
}
|
|
|
|
|
marker = new google.maps.Marker({
|
|
|
|
|
@ -97,18 +93,17 @@ $(document).ready(function(){
|
|
|
|
|
$('<li>' + element.formatted_address + '</li>')
|
|
|
|
|
.data("geoloc", element)
|
|
|
|
|
.click(function () { chooseLoc('user', $(this).data("geoloc")) })
|
|
|
|
|
.appendTo($('#'+config.locComboId));}
|
|
|
|
|
.appendTo($('#' + config.locComboId));
|
|
|
|
|
}
|
|
|
|
|
else { }
|
|
|
|
|
});
|
|
|
|
|
if ((data.status === 'OK') && (data.results.length == 1))
|
|
|
|
|
{
|
|
|
|
|
if ((data.status === 'OK') && (data.results.length == 1)) {
|
|
|
|
|
chooseLoc('google', data.results[0]);
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
return false;
|
|
|
|
|
},
|
|
|
|
|
error: function(xhr, textStatus, errorThrown)
|
|
|
|
|
{
|
|
|
|
|
error: function (xhr, textStatus, errorThrown) {
|
|
|
|
|
console.log('ajax loading error ... ' + textStatus + ' ... ' + errorThrown);
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
@ -152,30 +147,43 @@ $(document).ready(function(){
|
|
|
|
|
</span>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<label for="Location_Address" class="col-md-2 control-label">
|
|
|
|
|
@SR["Location"]
|
|
|
|
|
</label>
|
|
|
|
|
<div class="col-md-10">
|
|
|
|
|
<input asp-for="Location.Address" type="text" name="Location.Address" id="Location_Address"
|
|
|
|
|
class="form-control" data-val-required=@SR["SpecifyPlace"]
|
|
|
|
|
data-val-remote=@SR["GoogleDidntGeoLocalized"]>
|
|
|
|
|
<div class="container">
|
|
|
|
|
<div class="row">
|
|
|
|
|
<div class='col-sm-6'>
|
|
|
|
|
<div >
|
|
|
|
|
<input asp-for="Location.Address" type="text" name="Location.Address" id="Location_Address" class="form-control" data-val-required=@SR[
|
|
|
|
|
"SpecifyPlace"] data-val-remote=@SR[ "GoogleDidntGeoLocalized"]>
|
|
|
|
|
<span asp-validation-for="Location.Address" class="text-danger" id="valloc"></span>
|
|
|
|
|
<ul id="loccomb">
|
|
|
|
|
</ul>
|
|
|
|
|
<div id="map"></div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<label for="Reason" class="col-md-2 control-label">
|
|
|
|
|
@SR["GiveAnExplicitReason"]
|
|
|
|
|
</label>
|
|
|
|
|
<div class="col-md-10">
|
|
|
|
|
<div class="container">
|
|
|
|
|
<div class="row">
|
|
|
|
|
<div class='col-sm-6'>
|
|
|
|
|
<div id='reason1'>
|
|
|
|
|
<textarea rows="15" asp-for="Reason" type="text" name="Reason" id="Reason" maxlength="4096" class="form-control"></textarea>
|
|
|
|
|
<span asp-validation-for="Reason" class="text-danger"></span>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Html.HiddenFor(model=>model.Location.Latitude)
|
|
|
|
|
@Html.HiddenFor(model=>model.Location.Longitude)
|
|
|
|
|
<span asp-validation-for="Reason" class="text-danger"></span> @Html.HiddenFor(model=>model.Location.Latitude) @Html.HiddenFor(model=>model.Location.Longitude)
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</fieldset>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
@ -183,12 +191,11 @@ $(document).ready(function(){
|
|
|
|
|
<input type="submit" value="@SR[" Create "]" class="btn btn-default" />
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
@Html.HiddenFor(model=>model.Client.Id)
|
|
|
|
|
@Html.HiddenFor(model=>model.PerformerId)
|
|
|
|
|
@Html.HiddenFor(model=>model.Client.Id) @Html.HiddenFor(model=>model.PerformerId)
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@{ await Html.RenderPartialAsync("_ValidationScriptsPartial"); }
|
|
|
|
|
|