小编tci*_*and的帖子

语义UI - 滚动tbody时保持thead可见

我正在试图弄清楚滚动时如何保持桌面可见.这个语义ui中有一个设置吗?或者我只需要使用非语义ui解决方案?

您需要查看"整页"才能正确查看表格.

<script src="https://cdnjs.cloudflare.com/ajax/libs/semantic-ui/1.12.0/semantic.js"></script>
<link href="https://cdnjs.cloudflare.com/ajax/libs/semantic-ui/1.12.0/semantic.css" rel="stylesheet" />

<div style="height:200px;overflow:auto">
  <table class="ui small celled striped table" sytle="width:100%">
    <thead>
      <tr>
        <th>Date</th>
        <th>Status</th>
        <th>Facility Name</th>
        <th>Phone</th>
      </tr>
    </thead>
    <tbody data-bind="foreach:FollowupEntries">
      <tr>
        <td>Date</td>
        <td>Status</td>
        <td>Facility Name</td>
        <td>Phone</td>
      </tr>
      <tr>
        <td>Date</td>
        <td>Status</td>
        <td>Facility Name</td>
        <td>Phone</td>
      </tr>
      <tr>
        <td>Date</td>
        <td>Status</td>
        <td>Facility Name</td>
        <td>Phone</td>
      </tr>
      <tr>
        <td>Date</td>
        <td>Status</td>
        <td>Facility Name</td>
        <td>Phone</td>
      </tr>
      <tr>
        <td>Date</td>
        <td>Status</td>
        <td>Facility Name</td>
        <td>Phone</td>
      </tr>
      <tr>
        <td>Date</td>
        <td>Status</td>
        <td>Facility Name</td>
        <td>Phone</td>
      </tr>
      <tr>
        <td>Date</td>
        <td>Status</td>
        <td>Facility Name</td>
        <td>Phone</td>
      </tr>
      <tr>
        <td>Date</td>
        <td>Status</td> …
Run Code Online (Sandbox Code Playgroud)

html css semantic-ui

7
推荐指数
1
解决办法
1万
查看次数

C#+ EntityFramework:按查询将多个组转换为嵌套的JSON

我做了以下linq声明

C#

var list = from row in repository.GetAllEntities()
                       group row by new { row.RegionString, row.SubRegionString, row.CountryString } into g
                       select new { g.Key.RegionString, g.Key.SubRegionString, g.Key.CountryString, Count = g.Count() };

return Json(list, JsonRequestBehavior.AllowGet);
Run Code Online (Sandbox Code Playgroud)

那回来了

[
  {
    "RegionString":"Americas",
    "SubRegionString":"",
    "CountryString":"",
    "Count":2
  },
  {
    "RegionString":"Americas",
    "SubRegionString":"NorthAmerica",
    "CountryString":"Canada",
    "Count":5
  },
  {
    "RegionString":"Americas",
    "SubRegionString":"NorthAmerica",
    "CountryString":"US",
    "Count":3
  },
  {
    "RegionString":"Americas",
    "SubRegionString":"SouthAmerica",
    "CountryString":"Chile",
    "Count":3
  },
  {
    "RegionString":"EMEA",
    "SubRegionString":"AsiaPacific",
    "CountryString":"Australia",
    "Count":2
  },
  {
    "RegionString":"EMEA",
    "SubRegionString":"AsiaPacific",
    "CountryString":"Japan",
    "Count":1
  },
  {
    "RegionString":"EMEA",
    "SubRegionString":"SouthernEurope",
    "CountryString":"Turkey",
    "Count":1
  },
  {
    "RegionString":"EMEA",
    "SubRegionString":"WesternEurope", …
Run Code Online (Sandbox Code Playgroud)

c# linq asp.net json entity-framework

6
推荐指数
1
解决办法
921
查看次数

Angular2 + Babel + Gulp - 装饰器不会转换为es5

将装饰器(@Component + @View)转换为es5时,Babel会出错.我在gulp文件中遗漏了什么或者我怎么能让它工作?

ES2015文件(App.es6)

import {Component, View, bootstrap} from 'angular2/angular2';

@Component({
  selector: 'my-app'
})
@View({
  template: '<h1>Hello {{ name }}</h1>'
})
// Component controller
class MyAppComponent {
  name: string;
  constructor() {
    this.name = 'Alice';
  }
}

bootstrap(MyAppComponent);
Run Code Online (Sandbox Code Playgroud)

Gulp文件

var gulp = require('gulp');
var babel = require('gulp-babel');

gulp.task('default', function () {
    return gulp.src('App.es6')
        .pipe(babel())
        .pipe(gulp.dest('dist'));
});
Run Code Online (Sandbox Code Playgroud)

javascript gulp babeljs angular

2
推荐指数
1
解决办法
944
查看次数

标签 统计

angular ×1

asp.net ×1

babeljs ×1

c# ×1

css ×1

entity-framework ×1

gulp ×1

html ×1

javascript ×1

json ×1

linq ×1

semantic-ui ×1