CopyKeyForDataTable.php 821 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. namespace ThurData\Servers\KerioEmail\Core\UI\Widget\Others;
  3. use ThurData\Servers\KerioEmail\Core\UI\Builder\BaseContainer;
  4. /**
  5. * CopyKeyForDataTable - a copy on click ui element
  6. *
  7. * @autor ThurData <info@thurdata.ch>
  8. */
  9. class CopyKeyForDataTable extends BaseContainer
  10. {
  11. protected $id = 'copyKeyForDataTable';
  12. protected $name = 'copyKeyForDataTable';
  13. protected $vueComponent = true;
  14. protected $defaultVueComponentName = 'ds-copy-on-click';
  15. protected $textToCopy = null;
  16. public function setCopyText($textToCopy)
  17. {
  18. if (is_string($textToCopy) && $textToCopy !== '')
  19. {
  20. $this->textToCopy = $textToCopy;
  21. }
  22. return $this;
  23. }
  24. public function getCopyText()
  25. {
  26. return $this->textToCopy;
  27. }
  28. }