|
|
|
@ -5,14 +5,25 @@ import com.fr.license.exception.RegistEditionException;
|
|
|
|
|
import com.fr.regist.FRCoreContext; |
|
|
|
|
import com.fr.regist.FunctionPoint; |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 获取Lic相关信息的类 |
|
|
|
|
*/ |
|
|
|
|
public class LicKit { |
|
|
|
|
public LicKit() { |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 获取Lic的JSON信息 |
|
|
|
|
* @return JSONObject |
|
|
|
|
*/ |
|
|
|
|
public static JSONObject getJsonFromLic() { |
|
|
|
|
return FRCoreContext.getLicense().getJSONObject(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 检查某个功能点的lic权限,如果没有权限就跳转到没有lic权限的报错页面 |
|
|
|
|
* @param point 功能点 |
|
|
|
|
*/ |
|
|
|
|
public static void checkFunctionPointSupport(FunctionPoint point) { |
|
|
|
|
if (!point.isSupport()) { |
|
|
|
|
throw new RegistEditionException(point); |
|
|
|
|