Progress on order progress to provisioning

This commit is contained in:
Deon George
2020-04-23 17:38:09 +10:00
parent 3b168af492
commit 4935a9f5ff
8 changed files with 229 additions and 15 deletions

View File

@@ -0,0 +1,92 @@
@extends('adminlte::layouts.app')
@section('htmlheader_title')
{{ $o->sid }}
@endsection
@section('page_title')
{{ $o->sid }}
@endsection
@section('contentheader_title')
Service: {{ $o->sid }} <strong>{{ $o->product->name }}</strong>
@endsection
@section('contentheader_description')
{{ $o->sname }}: {{ $o->sdesc }}
@endsection
@section('main-content')
<div class="row">
<div class="col-6">
<div class="card">
<div class="card-header">
<div class="card-title">Update Order Status: {{ $o->order_status }}</div>
</div>
<form class="form-horizontal" method="post" action="{{ url('r/service/update',$o->id) }}">
{{ csrf_field() }}
<div class="card-body">
<div class="form-group row">
<label for="reference" class="col-sm-3 col-form-label text-right">Pending Connection</label>
<div class="col-sm-6">
<div class="input-group">
<div class="input-group-prepend">
<span class="input-group-text"><i class="fa fa-fw fa-calendar"></i></span>
</div>
<input type="text" class="form-control" id="datestart" name="date_start" value="{{ ($x=$o->date_start) ? $x->format('Y-m-d') : '' }}">
</div>
</div>
</div>
@includeIf('u.service.widgets.'.$o->stype.'.order',['o'=>$o->type])
<div class="form-group row">
<label for="notes" class="col-sm-2 col-form-label text-right">Notes</label>
<div class="col-sm-10">
<textarea class="textarea" name="provision_notes">{{ $o->order_provision_notes ?? '' }}</textarea>
</div>
</div>
</div>
<div class="card-footer">
<button type="reset" class="btn btn-secondary mr-2" onclick="window.history.go(-1); return false;">Cancel</button>
<button type="submit" class="btn btn-success">Submit</button>
</div>
</form>
</div>
</div>
</div>
@endsection
@section('page-scripts')
@css('//cdnjs.cloudflare.com/ajax/libs/summernote/0.8.12/summernote-bs4.css','summernote-css')
@js('//cdnjs.cloudflare.com/ajax/libs/summernote/0.8.12/summernote-bs4.js','summernote-js')
@js('//cdn.jsdelivr.net/momentjs/latest/moment.min.js','moment-js')
@js('//cdn.jsdelivr.net/npm/daterangepicker/daterangepicker.min.js','daterange-js')
@css('//cdn.jsdelivr.net/npm/daterangepicker/daterangepicker.css','daterange-css')
<script>
$(document).ready(function() {
$('#datestart').daterangepicker({
singleDatePicker: true,
showDropdowns: true,
locale: {
format: 'YYYY-MM-DD'
}
});
$('.textarea').summernote({
minHeight: 350,
toolbar: [
['style', ['style']],
['font', ['bold', 'underline', 'clear']],
['color', ['color']],
['para', ['ul', 'ol', 'paragraph']],
['table', ['table']],
['view', ['codeview', 'help']],
],
});
});
</script>
@append

View File

@@ -29,9 +29,17 @@
<td>{{ $o->name_short }}</td>
<td>
{{ $o->status }}
@if ($o->status == 'ORDER-SENT')
(#{{$o->order_info_reference}})
@endif
@switch($o->status)
@case ('ORDER-SENT')
<br>(#{{ $o->order_info_reference }})
@break;
@case ('PROVISION-PLANNED')
<br>({{ ($xx=$o->date_start) ? $xx->format('Y-m-d') : 'No Date' }})
@break;
@case ('CANCEL-PENDING')
<br>({{ ($xx=$o->date_end) ? $xx->format('Y-m-d') : 'No Date' }})
@break;
@endswitch
</td>
<td>{{ $o->product->name }}</td>
</tr>

View File

@@ -38,7 +38,7 @@
<div class="input-group-prepend">
<span class="input-group-text"><i class="fa fa-fw fa-calendar"></i></span>
</div>
<input type="text" class="form-control" id="datestop" name="date_end" value="{{ ($x=$o->date_end) && $x->format('Y-m-d') ?? '' }}">
<input type="text" class="form-control" id="datestop" name="date_end" value="{{ ($x=$o->date_end) ? $x->format('Y-m-d') : '' }}">
</div>
</div>
</div>

View File

@@ -1,5 +1,5 @@
<div class="form-group row">
<label for="reference" class="col-sm-2 col-form-label text-right">Service Number</label>
<label for="reference" class="col-sm-3 col-form-label text-right">Service Number</label>
<div class="col-sm-6">
<div class="input-group">
<div class="input-group-prepend">
@@ -8,4 +8,28 @@
<input type="text" class="form-control" name="broadband[service_number]" value="{{ $o->service_number ?? '' }}">
</div>
</div>
</div>
<div class="form-group row">
<label for="reference" class="col-sm-3 col-form-label text-right">Service Username</label>
<div class="col-sm-6">
<div class="input-group">
<div class="input-group-prepend">
<span class="input-group-text"><i class="fa fa-fw fa-user"></i></span>
</div>
<input type="text" class="form-control" name="broadband[service_username]" value="{{ $o->service_username ?? '' }}">
</div>
</div>
</div>
<div class="form-group row">
<label for="reference" class="col-sm-3 col-form-label text-right">Service Password</label>
<div class="col-sm-6">
<div class="input-group">
<div class="input-group-prepend">
<span class="input-group-text"><i class="fa fa-fw fa-lock"></i></span>
</div>
<input type="text" class="form-control" name="broadband[service_password]" value="{{ $o->service_password ?? '' }}">
</div>
</div>
</div>

View File

@@ -27,6 +27,12 @@
<td>{{ $o->order_info_reference ?? '' }}</td>
</tr>
@endif
@if ($o->date_start AND $o->isPending())
<tr>
<th>Pending Connection</th>
<td>{{ $o->date_start->format('Y-m-d') }}</td>
</tr>
@endif
@if ($o->date_end)
<tr>
<th>Cancellation Date</th>