﻿// JScript 文件

//个人站通用Ajax

/******************************************
*
*   关注相关操作
*
*   传入参数
*   type                add:添加 del:删除 cancel:屏蔽
*   Attention_Type      关注类型 1:用户 2:网游 3:小游戏
*   Related_ID          相关ID
*   Related_Name        相关名称
*   Info                是否取得操作后关注信息 true/false
*
*   返回参数
*   json.flag           -1:未来登录 0:完成 1:传入参数错误 其它:错误代码
*   json.message        当 json.flag = 其它 时 错误内容
*   json.info           当 json.flag = 0 时 传入参数 Info = true 时 操作后关注信息 0:未关注 1:已经关注 2:已被关注 3:相互关注
*   json.Attention_Type 当 json.flag = 0 时 传入参数 Info = true 时 关注类型 1:用户 2:网游 3:小游戏
*   json.Related_ID     当 json.flag = 0 时 传入参数 Info = true 时 相关ID
*   json.Related_Name   当 json.flag = 0 时 传入参数 Info = true 时 相关名称
*
******************************************/

function Ajax_Common_ShareUserAttentionManage(type, Attention_Type, Related_ID, Related_Name, Info, Callback)
{
    $.getJSON(Virtual_Path_Personal_User + "AjaxService.koc?callback=?"
        ,{AjaxType:"Common_ShareUserAttentionManage"
        ,type:type
        ,Attention_Type:Attention_Type
        ,Related_ID:Related_ID
        ,Related_Name:Related_Name
        ,Info:Info
        ,time:new Date()}
        ,function(json){
            try{Callback(json);}catch(ex){}
        }
    );
}
