【调度系统】广东民航医疗快线调度系统源代码
wanglizhong
2025-05-05 2a11acffdd3df927be6abace9e8155e370b49681
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
<%Session.CodePage=65001%>  
<!--#include file="JsonPost_user.gds"-->
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<%
Set rs = Server.CreateObject("ADODB.Recordset")
 
appUrl="https://qyapi.weixin.qq.com/cgi-bin/department/update?access_token="&access_token
 
method="department_update"
 
Origin="access_token="&access_token
 
ID    =    trim(Request("ID"))
If ID="" Then Response.Redirect "/AdminUser_Department.gds?h_menu1="&session("h_menu1")&"&SystemMessageType=1&SMT=1"
 
ID_SP    = SPLIT(ID,", ")
for i=0 to ubound(ID_SP) 
    id    = ID_SP(i)
    departmentID    = trim(Request("departmentID_"&ID))
    departmentName    = trim(Request("departmentName_"&ID))
    departmentOrder    = trim(Request("departmentOrder_"&ID))
    If departmentID="" Or departmentName="" Or departmentOrder="" Then Response.Redirect "/AdminUser_Department.gds?h_menu1="&session("h_menu1")&"&SystemMessageType=4&SMT=1"
    args1="{"
    args1=args1&"""id"": "&departmentID&","
    args1=args1&"""name"": """&departmentName&""","
    args1=args1&"""order"": """&departmentOrder&""","
    args1=args1&"}"
    
    HTMLCODE= PostBody(appUrl,args1)
    If Mid(HTMLCODE,12,1)="0" Then
        sql="select vtext from dictionary where vtitle='OA_Department' and id="&ID
        rs.open sql,objConn,1,1
        if not rs.Eof then
            vtext=rs("vtext")
            sql="update dictionary set vtext='"&departmentName&"',vOrder="&departmentOrder&" where id="&ID
            objConn.Execute sql
            sql="update OA_User set OA_User='"&departmentName&"_部门',OA_Name='"&departmentName&"_部门' where OA_execLevel=3 and OA_User='"&vtext&"_部门'"
            objConn.Execute sql
        End If
        rs.close()
    Else
        Response.Redirect "/AdminUser_Department.gds?h_menu1="&session("h_menu1")&"&SystemMessageType=4&SMT=2"
    End if
Next
 
Response.Redirect "/AdminUser_Department.gds?h_menu1="&session("h_menu1")&"&SystemMessageType=3&SMT=2"
%>