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

git.tmpl 3.8KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. {{template "base/head" .}}
  2. <div role="main" aria-label="{{.Title}}" class="page-content repository new migrate">
  3. <div class="ui middle very relaxed page grid">
  4. <div class="column">
  5. <form class="ui form" action="{{.Link}}" method="post">
  6. {{template "base/disable_form_autofill"}}
  7. {{.CsrfTokenHtml}}
  8. <h3 class="ui top attached header">
  9. {{.locale.Tr "repo.migrate.migrate" .service.Title}}
  10. <input id="service_type" type="hidden" name="service" value="{{.service}}">
  11. </h3>
  12. <div class="ui attached segment">
  13. {{template "base/alert" .}}
  14. <div class="inline required field {{if .Err_CloneAddr}}error{{end}}">
  15. <label for="clone_addr">{{.locale.Tr "repo.migrate.clone_address"}}</label>
  16. <input id="clone_addr" name="clone_addr" value="{{.clone_addr}}" autofocus required>
  17. <span class="help">
  18. {{.locale.Tr "repo.migrate.clone_address_desc"}}{{if .ContextUser.CanImportLocal}} {{.locale.Tr "repo.migrate.clone_local_path"}}{{end}}
  19. </span>
  20. </div>
  21. <div class="inline field {{if .Err_Auth}}error{{end}}">
  22. <label for="auth_username">{{.locale.Tr "username"}}</label>
  23. <input id="auth_username" name="auth_username" value="{{.auth_username}}" {{if not .auth_username}}data-need-clear="true"{{end}}>
  24. </div>
  25. <div class="inline field {{if .Err_Auth}}error{{end}}">
  26. <label for="auth_password">{{.locale.Tr "password"}}</label>
  27. <input id="auth_password" name="auth_password" type="password" value="{{.auth_password}}">
  28. </div>
  29. {{template "repo/migrate/options" .}}
  30. <div class="ui divider"></div>
  31. <div class="inline required field {{if .Err_Owner}}error{{end}}">
  32. <label>{{.locale.Tr "repo.owner"}}</label>
  33. <div class="ui selection owner dropdown">
  34. <input type="hidden" id="uid" name="uid" value="{{.ContextUser.ID}}" required>
  35. <span class="text truncated-item-container" title="{{.ContextUser.Name}}">
  36. {{avatar .ContextUser}}
  37. <span class="truncated-item-name">{{.ContextUser.ShortName 40}}</span>
  38. </span>
  39. {{svg "octicon-triangle-down" 14 "dropdown icon"}}
  40. <div class="menu" title="{{.SignedUser.Name}}">
  41. <div class="item truncated-item-container" data-value="{{.SignedUser.ID}}">
  42. {{avatar .SignedUser}}
  43. <span class="truncated-item-name">{{.SignedUser.ShortName 40}}</span>
  44. </div>
  45. {{range .Orgs}}
  46. <div class="item truncated-item-container" data-value="{{.ID}}" title="{{.Name}}">
  47. {{avatar .}}
  48. <span class="truncated-item-name">{{.ShortName 40}}</span>
  49. </div>
  50. {{end}}
  51. </div>
  52. </div>
  53. </div>
  54. <div class="inline required field {{if .Err_RepoName}}error{{end}}">
  55. <label for="repo_name">{{.locale.Tr "repo.repo_name"}}</label>
  56. <input id="repo_name" name="repo_name" value="{{.repo_name}}" required>
  57. </div>
  58. <div class="inline field">
  59. <label>{{.locale.Tr "repo.visibility"}}</label>
  60. <div class="ui checkbox">
  61. {{if .IsForcedPrivate}}
  62. <input name="private" type="checkbox" checked readonly>
  63. <label>{{.locale.Tr "repo.visibility_helper_forced" | Safe}}</label>
  64. {{else}}
  65. <input name="private" type="checkbox" {{if .private}}checked{{end}}>
  66. <label>{{.locale.Tr "repo.visibility_helper" | Safe}}</label>
  67. {{end}}
  68. </div>
  69. </div>
  70. <div class="inline field {{if .Err_Description}}error{{end}}">
  71. <label for="description">{{.locale.Tr "repo.repo_desc"}}</label>
  72. <textarea id="description" name="description">{{.description}}</textarea>
  73. </div>
  74. <div class="inline field">
  75. <label></label>
  76. <button class="ui green button">
  77. {{.locale.Tr "repo.migrate_repo"}}
  78. </button>
  79. </div>
  80. </div>
  81. </form>
  82. </div>
  83. </div>
  84. </div>
  85. {{template "base/footer" .}}