MCPcopy Create free account
hub / github.com/aaPanel/BaoTa / remove_crontab

Method remove_crontab

mod/project/php/php_asyncMod.py:1549–1559  ·  view source on GitHub ↗
(self, get)

Source from the content-addressed store, hash-verified

1547 return public.returnResult(False, traceback.format_exc())
1548
1549 def remove_crontab(self, get):
1550 try:
1551 if not hasattr(get, 'id'):
1552 return public.returnResult(False, 'ID不能为空')
1553 import crontab
1554 res = crontab.crontab().DelCrontab(get)
1555 if res['status']:
1556 return public.returnResult(True, '删除成功')
1557 return public.returnResult(False, res['msg'])
1558 except:
1559 return public.returnResult(False, traceback.format_exc())
1560
1561 def modify_crontab(self, get):
1562 try:

Callers 2

modify_crontabMethod · 0.95
test_remove_crontabMethod · 0.45

Calls 3

returnResultMethod · 0.80
DelCrontabMethod · 0.80
crontabMethod · 0.80

Tested by 1

test_remove_crontabMethod · 0.36