| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121 | @extends('admin/layout')@section('header')    <link href="{{asset('css/plugins/chosen/chosen.css')}}" rel="stylesheet">    <link href="{{asset('css/plugins/switchery/switchery.css')}}" rel="stylesheet">    {{--<link href="{{asset('js/plugins/bootstrap-select-1.13.5/css/bootstrap-select.min.css')}}" rel="stylesheet">--}}    <link rel="stylesheet"          href="https://cdn.jsdelivr.net/npm/bootstrap-select@1.13.9/dist/css/bootstrap-select.min.css">@endsection@section('content')    <body class="gray-bg">    <div class="wrapper wrapper-content animated fadeInRight">        <div class="row">            <div class="col-sm-12">                <div class="ibox float-e-margins">                    <div class="ibox-content">                        <form method="get" class="form-horizontal" id="form">                            <div class="form-group">                                <label class="col-sm-2 control-label" for="nickname">完成时间:</label>                                <div class="col-sm-6">                                    <input type="hidden" id="id" name="id" value="{{$flowPlan->id??''}}">                                    <input type="text" class="form-control" id="done_date" name="done_date"                                           autocomplete="off"                                           value="{{$flowPlan->done_date??''}}">                                </div>                            </div>                            <div class="form-group">                                <label class="col-sm-2 control-label" for="username_new">                                    事项:</label>                                <div class="col-sm-6">                                    <input type="text" class="form-control" id="title" name="title"                                           value="{{$flowPlan->title??''}}" autocomplete="off">                                </div>                            </div>                            <div class="form-group">                                <label class="col-sm-2 control-label" for="username_new">                                    临时人员:</label>                                <div class="col-sm-6">                                    <input type="text" class="form-control" id="username" name="username"                                           value="{{$flowPlan->username??''}}" autocomplete="off">                                </div>                            </div>                            <div class="form-group">                                <label class="col-sm-2 control-label" for="type">编内人员:</label>                                <div class="col-sm-8">                                    <select name="user_ids" class="my-select" multiple                                            data-container="body" data-live-search="true">                                        @foreach($userList as $user)                                            <option value="{{$user['id']}}"                                                    @if(is_array($flowPlan->user_ids??'') && in_array($user['id'],$flowPlan->user_ids)) selected @endif>                                                {{$user['nickname']}}                                                【{{\App\Http\Models\FlowInfoTpl::RoleScope[$user['role_id']]??''}}】                                            </option>                                        @endforeach                                    </select>                                </div>                            </div>                            <div class="form-group">                                <label class="col-sm-2 control-label" for="username_new">                                    备注:</label>                                <div class="col-sm-6">                                    <input type="text" class="form-control" id="remark" name="remark"                                           value="{{$flowPlan->remark??''}}">                                </div>                            </div>                            <div class="form-group">                                <div class="col-sm-4 col-sm-offset-2">                                    <button class="btn btn-primary" type="button" data-id="{{$flowPlan->id??0}}"                                            id="save">                                        保存                                    </button>                                    <button class="btn btn-white" type="button" id="cancel">取消</button>                                </div>                            </div>                        </form>                    </div>                </div>            </div>        </div>    </div>    </body>@endsection@section('footer')    <script src="{{asset('js/plugins/switchery/switchery.js')}}"></script>    <script src="https://cdn.jsdelivr.net/npm/bootstrap-select@1.13.9/dist/js/bootstrap-select.min.js"></script>    <script>        $(function () {            $(".my-date").trigger('click'); //触发laydate绑定            $('.my-select').selectpicker();        });        $(document).on('click', '#cancel', function () {            tips.closeParentLayer();        });        $(document).on('click', '#save', function () {            var user_ids = $("[name=user_ids]").val();            var data = tips.getFormValues('#form');            data.user_ids = user_ids;            var url = '/admin/flow-plan-history-update/' + 0;            var type = 'get';            var ajaxConfig = {                url: url,                type: type,                data: data,                success: function (result) {                    layer.msg(result.message, {icon: 6, time: 1500}, function () {                        tips.closeParentLayer();                    });                }            };            tips.ajax(ajaxConfig);        });    </script>@endsection
 |