123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130 |
- @extends('admin/layout')
- @section('header')
- <link href="{{asset('css/plugins/chosen/chosen.css')}}" rel="stylesheet">
- <link href="{{asset('js/plugins/bootstrap-select-1.13.5/css/bootstrap-select.min.css')}}" rel="stylesheet">
- @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" id="siteAssign">
- <label class="col-sm-2 control-label" for="link_id">外链类型:</label>
- <div class="col-sm-8">
- <select class="chosen-select form-control" data-placeholder="选择类型..."
- id="link_id" name="link_id">
- <option value="">请选择</option>
- @foreach ($allLinks as $item)
- <option value="{{$item->id}}"
- @if(($data->link_id??null)==$item->id) selected @endif>{{$item->url}}</option>
- @endforeach
- </select>
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-2 control-label" for="username">用户名:</label>
- <div class="col-sm-8">
- <input type="text" class="form-control" id="username" name="username"
- value="{{$data->username??''}}">
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-2 control-label" for="password">密码:</label>
- <div class="col-sm-8">
- <input type="text" class="form-control" id="password" name="password" value="{{$data->password??''}}">
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-2 control-label" for="email">邮箱:</label>
- <div class="col-sm-8">
- <input type="text" class="form-control" id="email" name="email" value="{{$data->email??''}}">
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-2 control-label" for="url">演示地址:</label>
- <div class="col-sm-8">
- <input type="text" class="form-control" id="url" name="url" value="{{$data->url??''}}">
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-2 control-label" for="url">上传时间:</label>
- <div class="col-sm-8">
- <input type="text" class="form-control" id="created_at" name="created_at" value="{{$data->created_at??''}}">
- </div>
- </div>
- <div class="hr-line-dashed"></div>
- <div class="form-group">
- <div class="col-sm-4 col-sm-offset-2">
- <button class="btn btn-primary" type="button" onclick="units.save()">
- 保存
- </button>
- </div>
- </div>
- </form>
- </div>
- </div>
- </div>
- </div>
- </div>
- </body>
- @endsection
- @section('footer')
- <script src="{{asset('js/plugins/chosen/chosen.jquery.js')}}"></script>
- <script src="{{asset('js/plugins/layDate-v5.0.9/laydate/laydate.js')}}"></script>
- <script>
- var config = {".chosen-select": {}};
- for (var selector in config) $(selector).chosen(config[selector]);
- laydate.render({
- elem: '#created_at', //指定元素
- type: 'datetime'
- });
- var units = {
- save: function () {
- var data = tips.getFormValues('#form');
- // data.redundant_site_id =
- var ajaxConfig = {
- url: '/admin/link/link-count/{{$data->id??0}}?siteId={{$siteId}}',
- type: 'post',
- data: data,
- success: function (result) {
- layer.msg(result.message, {icon: 6, time: 1000}, function () {
- tips.closeParentLayer();
- window.parent.tips.tableRefresh('#table');
- });
- }
- };
- tips.ajax(ajaxConfig);
- }
- };
- </script>
- @endsection
|