You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
929 B
39 lines
929 B
package com.fr.plugin.xx.zyjn.handler.action; |
|
|
|
import com.fr.json.JSONObject; |
|
import com.fr.plugin.xx.zyjn.dao.SyncService; |
|
import com.fr.plugin.xx.zyjn.entity.SyncOrgEntity; |
|
import com.fr.third.springframework.web.bind.annotation.RequestMethod; |
|
import com.fr.web.utils.WebUtils; |
|
|
|
import javax.servlet.http.HttpServletResponse; |
|
|
|
/** |
|
* @Author xx |
|
* @Date 2021/11/27 |
|
* @Description |
|
**/ |
|
public class SyncOrgHandler extends BaseHandler { |
|
|
|
@Override |
|
public RequestMethod getMethod() { |
|
return RequestMethod.POST; |
|
} |
|
|
|
@Override |
|
public String getPath() { |
|
return "/sync/org"; |
|
} |
|
|
|
@Override |
|
public boolean isPublic() { |
|
return true; |
|
} |
|
|
|
|
|
@Override |
|
void sync(HttpServletResponse res, JSONObject entity) throws Exception { |
|
SyncService.saveOrg(new SyncOrgEntity(entity)); |
|
WebUtils.printAsJSON(res, new JSONObject("{\"code\":0,\"msg\":\"成功\"}")); |
|
} |
|
}
|
|
|