create.office.html.php 1.3 KB

1234567891011121314151617181920212223242526272829303132
  1. <?php
  2. /**
  3. * The create view file of doc module of ZenTaoPMS.
  4. * @copyright Copyright 2024 禅道软件(青岛)有限公司(ZenTao Software (Qingdao) Co., Ltd. www.zentao.net)
  5. * @license ZPL(https://zpl.pub/page/zplv12.html) or AGPL(https://www.gnu.org/licenses/agpl-3.0.en.html)
  6. * @author Sun Hao<sunhao@easycorp.ltd>
  7. * @package doc
  8. * @link https://www.zentao.net
  9. */
  10. namespace zin;
  11. set::title($lang->doc->create);
  12. if($this->config->edition != 'open')
  13. {
  14. $setOfficeLink = common::hasPriv('custom', 'libreoffice') ? $this->createLink('custom', 'libreoffice') : '###';
  15. $officeNotice = sprintf($lang->doc->notSetOffice, zget($lang->doc->typeList, $docType), $setOfficeLink);
  16. if(!empty($config->file->libreOfficeTurnon) and $config->file->convertType != 'collabora') $officeNotice = sprintf($lang->doc->notSetCollabora, zget($lang->doc->typeList, $docType), $setOfficeLink);
  17. if($config->requestType != 'PATH_INFO') $officeNotice = $lang->doc->requestTypeError;
  18. div
  19. (
  20. setClass('alert warning-pale bd bd-warning'),
  21. html($officeNotice)
  22. );
  23. }
  24. else
  25. {
  26. div
  27. (
  28. setClass('alert warning-pale bd bd-warning'),
  29. html(sprintf($lang->doc->cannotCreateOffice, zget($lang->doc->typeList, $docType)))
  30. );
  31. }