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

Method _check_project_exist

class/projectModel/pythonModel.py:390–399  ·  view source on GitHub ↗

检查项目是否存在 @author baozi <202-02-22> @param: pjname ( str ): 项目名称 path ( str ): 项目路径 @return bool : 返回验证结果

(project_name)

Source from the content-addressed store, hash-verified

388
389 @staticmethod
390 def _check_project_exist(project_name):
391 """检查项目是否存在
392 @author baozi <202-02-22>
393 @param:
394 pjname ( str ): 项目名称
395 path ( str ): 项目路径
396 @return bool : 返回验证结果
397 """
398 data = public.M('sites').where('name=?', (project_name,)).field('id').find()
399 return bool(data)
400
401 @staticmethod
402 def _check_project_path_exist(path=None):

Callers 1

__check_argsMethod · 0.95

Calls 4

findMethod · 0.45
fieldMethod · 0.45
whereMethod · 0.45
MMethod · 0.45

Tested by

no test coverage detected