归档
This commit is contained in:
41
includes/user/depmain.php
Normal file
41
includes/user/depmain.php
Normal file
@@ -0,0 +1,41 @@
|
||||
<?php
|
||||
|
||||
namespace user;
|
||||
|
||||
class depmain
|
||||
{
|
||||
public function reg($name,$duid,$upid='0'){
|
||||
global $medoo;
|
||||
return $medoo->insert("dep_info",[
|
||||
"name" =>$name,
|
||||
"orders"=>$duid,
|
||||
"upn"=>$upid
|
||||
]);
|
||||
}
|
||||
|
||||
public function del($did){
|
||||
global $medoo;
|
||||
return $medoo->delete("dep_info",[
|
||||
"did"=>$did
|
||||
]);
|
||||
}
|
||||
|
||||
public function cha($did){
|
||||
global $medoo;
|
||||
return $medoo->get("dep_info","*",[
|
||||
"did"=>$did
|
||||
]);
|
||||
}
|
||||
|
||||
public function update($did,$name){
|
||||
global $medoo;
|
||||
return $medoo->update("dep_info",[
|
||||
"name"=>$name
|
||||
],[
|
||||
"did"=>$did
|
||||
]);
|
||||
}
|
||||
public function hello(){
|
||||
return "hello";
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user