12345678910111213141516171819202122232425262728293031323334353637383940414243444546 |
- <div class="form-group col-sm-12">
- <div class="table-responsive">
- <table class="table table-striped table-bordered table-hover">
- <thead>
- <tr>
- @foreach ($specAttr as $value)
- <th>{{$value['spec_name']}}</th>
- @endforeach
- <th>配图</th>
- <th>价格</th>
- <th>库存</th>
- <th>课程节数</th>
- <th>是否上架</th>
- <th>操作</th>
- </tr>
- </thead>
- <tbody>
- @foreach ($skuList as $key=>$value)
- <tr>
- @foreach (explode(',',$value['attr_names']) as $v)
- <td>{{$v}}</td>
- @endforeach
- <td>
- <div id="sku_thumb{{$key}}">
- <a id="sku_thumb-image{{$key}}" href="#" data-toggle="image" class="img-thumb">
- <img src="{{path_compat($value['sku_thumb']??'')}}" height="30" />
- </a>
- <input type="hidden" name="sku[{{$value['attr_names']}}][sku_thumb]" laceholder="缩略图" value="{{$value['sku_thumb']??''}}" id="input-sku_thumb{{$key}}" />
- </div>
- </td>
- <td><input type="text" name="sku[{{$value['attr_names']}}][price]" placeholder="价格" value="{{$value['price']}}"></td>
- <td><input type="number" name="sku[{{$value['attr_names']}}][stock]" placeholder="库存" value="{{$value['stock']}}"></td>
- <td><input type="number" name="sku[{{$value['attr_names']}}][course_number]" placeholder="课程节数" value="{{$value['course_number']}}"></td>
- <td>
- <select name="sku[{{$value['attr_names']}}][status]" >
- <option value="0" @if( $value['status'] == 0) selected @endif >上架</option>
- <option value="1" @if( $value['status'] == 1) selected @endif >下架</option>
- </select>
- </td>
- <td><button type="button" class="btn btn-xs btn-danger remove_sku">删除 </button> </td>
- </tr>
- @endforeach
- </tbody>
- </table>
- </div>
- </div>
|