showsynccommit.html.php 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. <?php
  2. /**
  3. * The showsynccommit view file of repo module of ZenTaoPMS.
  4. *
  5. * @copyright Copyright 2009-2023 禅道软件(青岛)有限公司(ZenTao Software (Qingdao) Co., Ltd. www.zentao.net)
  6. * @license ZPL(https://zpl.pub/page/zplv12.html) or AGPL(https://www.gnu.org/licenses/agpl-3.0.en.html)
  7. * @author Ke Zhao<zhaoke@easycorp.ltd>
  8. * @package repo
  9. * @link https://www.zentao.net
  10. */
  11. namespace zin;
  12. \zin\featureBar();
  13. if(empty($branch))
  14. {
  15. $link = helper::createLink('repo', 'ajaxSyncCommit', "repoID=$repoID");
  16. }
  17. else
  18. {
  19. $link = helper::createLink('repo', 'ajaxSyncBranchCommit', "repoID=$repoID&branch=" . helper::safe64Encode(base64_encode($branch)));
  20. }
  21. jsVar('link', $link);
  22. jsVar('browseLink', $browseLink);
  23. jsVar('syncComplete', $lang->repo->notice->syncComplete);
  24. div
  25. (
  26. setClass('sync-main-content'),
  27. div
  28. (
  29. set::className('sync-content'),
  30. div
  31. (
  32. setClass('alert light-pale flex items-center'),
  33. icon(setClass('icon icon-info-sign icon-2x alert-icon'), 'check-sign'),
  34. div
  35. (
  36. h3($lang->repo->notice->syncing),
  37. div(setClass('sync-line')),
  38. !in_array($repo->SCM, $this->config->repo->notSyncSCM) ? p($lang->repo->notice->syncedCount, span($version, set::id('commits'))) : null
  39. )
  40. )
  41. )
  42. );
  43. render();