You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

dashboard.tmpl 3.5 kB

10 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. {{template "base/head" .}}
  2. <div class="dashboard feeds">
  3. {{template "user/dashboard/navbar" .}}
  4. <div class="ui container">
  5. {{template "base/alert" .}}
  6. <div class="ui mobile reversed stackable grid">
  7. <div class="ui container ten wide column">
  8. <div class="default" id = 'default_page' style="display: none;">
  9. <div class="w_title">
  10. {{.i18n.Tr "home.wecome_AI_plt"}}
  11. </div>
  12. <div class="content">
  13. <p class="ui text grey">{{.i18n.Tr "home.explore_AI"}} <a href="{{AppSubUrl}}/explore/repos"> {{.i18n.Tr "home.repositories"}}</a> {{.i18n.Tr "home.or_t"}} <a href="{{AppSubUrl}}/explore/datasets">{{.i18n.Tr "home.datasets"}}</a></p>
  14. <p><span class="ui text grey">{{.i18n.Tr "home.use_plt__fuction"}}</span>&nbsp;<a class="mini ui blue button" href="{{AppSubUrl}}/repo/create{{if .ContextUser.IsOrganization}}?org={{.ContextUser.ID}}{{end}}" >{{.i18n.Tr "repo.create_repo"}}</a></p>
  15. <p class="ui text grey">{{.i18n.Tr "home.provide_resoure"}}</p>
  16. </div>
  17. <div class="guide ">
  18. <a class="mini ui blue basic button" style="font-weight:700" href="https://openi.pcl.ac.cn/zeizei/OpenI_Learning" target="_blank">{{.i18n.Tr "custom.Platform_Tutorial"}} <i class="ri-arrow-right-line" ></i></a>
  19. </div>
  20. </div>
  21. {{if .EnableHeatmap}}
  22. {{template "user/dashboard/heatmap" .}}
  23. {{end}}
  24. {{template "user/dashboard/feeds" .}}
  25. {{ if eq (len .Feeds) 0 }}
  26. <diV ss="{{(len .Feeds)}}" id = "activity_cont" style="display: block;">
  27. <div class="ui placeholder segment bgtask-none padding_none line" >
  28. <div class="act_title" style="padding-left: 0px ;">
  29. {{.i18n.Tr "home.activity"}} :
  30. </div>
  31. <div class="ui icon header bgtask-header-pic"></div>
  32. <p class="p_hint">
  33. {{.i18n.Tr "home.no_events"}}
  34. </p>
  35. </div>
  36. </diV>
  37. {{ end }}
  38. </div>
  39. {{template "user/dashboard/repolist" .}}
  40. </div>
  41. </div>
  42. </div>
  43. {{template "base/footer" .}}
  44. <script>
  45. const {AppSubUrl, StaticUrlPrefix, csrf} = window.config;
  46. uid_ = Number((document.querySelector('meta[name=_context_uid]') || {}).content)
  47. // console.log("uid:",uid_)
  48. let URL = AppSubUrl + '/api/v1/repos/search?sort=updated&order=desc&uid='+uid_ +'&q=&page=1&limit=10&mode= ';
  49. $.getJSON(URL, (result, _textStatus, request) => {
  50. const counts_pro = request.getResponseHeader('X-Total-Count');
  51. console.log("count:",counts_pro)
  52. if (counts_pro == 0 && {{ (len .Feeds) }} == 0) {
  53. document.getElementById("default_page").style.display = "block";
  54. }
  55. })
  56. </script>
  57. <style>
  58. .default{
  59. background-color: rgba(24, 144, 255, 0.1);
  60. margin-bottom: 20px;
  61. border-radius: 15px;
  62. line-height: 20px;
  63. padding:0px 25px;
  64. }
  65. .w_title{
  66. padding-top: 25px;
  67. margin-bottom: 20px;
  68. color: rgba(16, 16, 16, 100);
  69. font-size: 20px;
  70. text-align: left;
  71. font-weight: 700;
  72. }
  73. .guide{
  74. margin-top:30px;
  75. padding-bottom: 30px;
  76. }
  77. .activity{
  78. margin-top: 20px;
  79. }
  80. .act_title{
  81. color: rgba(16, 16, 16, 100) !important;
  82. font-size: 20px;
  83. text-align: left;
  84. background-color: #fff !important;
  85. font-weight: 700;
  86. }
  87. .p_hint{
  88. color: rgba(136, 136, 136, 100);
  89. font-size: 14px;
  90. text-align: center;
  91. font-family: SourceHanSansSC-regular;
  92. }
  93. .padding_none{
  94. padding: 0px !important;
  95. }
  96. .ui.placeholder.segment {
  97. min-height: 15rem !important;
  98. }
  99. .line{
  100. border-top: 1px solid rgba(187, 187, 187, 0.5) !important;
  101. margin-top: 20px !important;
  102. }
  103. </style>