2026-04-09供销社OA项目初始化上传
This commit is contained in:
@@ -0,0 +1,46 @@
|
|||||||
|
package com.seeyon.apps.src_leasebill;
|
||||||
|
|
||||||
|
import com.seeyon.apps.common.plugin.api.APluginInfoApi;
|
||||||
|
import com.seeyon.apps.common.plugin.vo.ConfigVo;
|
||||||
|
import com.seeyon.apps.src_leasebill.constant.LeaseBillConstant;
|
||||||
|
|
||||||
|
|
||||||
|
public class LeaseBillPluginApi extends APluginInfoApi {
|
||||||
|
public LeaseBillPluginApi() {
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPluginId() {
|
||||||
|
System.out.println(LeaseBillConstant.getPluginId());
|
||||||
|
return LeaseBillConstant.getPluginId();
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCreateUser() {
|
||||||
|
return "橙阳科技";
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDescription() {
|
||||||
|
return "租赁账单生成";
|
||||||
|
}
|
||||||
|
|
||||||
|
public ConfigVo getDefaultConfig() {
|
||||||
|
ConfigVo configVo = new ConfigVo();
|
||||||
|
LeaseBillConstant[] var2 = LeaseBillConstant.values();
|
||||||
|
int var3 = var2.length;
|
||||||
|
|
||||||
|
for(int var4 = 0; var4 < var3; ++var4) {
|
||||||
|
LeaseBillConstant value = var2[var4];
|
||||||
|
if (value != LeaseBillConstant.plugin) {
|
||||||
|
configVo.getDevParams().put(value.name(), value.getDefaultValue());
|
||||||
|
configVo.getProdParams().put(value.name(), value.getDefaultValue());
|
||||||
|
configVo.getParamMap().put(value.name(), value.getDescription());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return configVo;
|
||||||
|
}
|
||||||
|
|
||||||
|
// public void registerCustomEvent(Map eventAndNodes) {
|
||||||
|
// eventAndNodes.put("propertyDispose", "资产管理待办推送");
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
package com.seeyon.apps.src_leasebill.constant;
|
||||||
|
|
||||||
|
public enum LeaseBillConstant {
|
||||||
|
|
||||||
|
|
||||||
|
plugin("src_leasebill","插件ID"),
|
||||||
|
loginName("shenxian","辅助表创建人");
|
||||||
|
// u8cUrl("http://ip:port", "U8C地址"),
|
||||||
|
|
||||||
|
LeaseBillConstant(String defaultValue, String description) {
|
||||||
|
this.defaultValue = defaultValue;
|
||||||
|
this.description = description;
|
||||||
|
}
|
||||||
|
|
||||||
|
private String defaultValue;
|
||||||
|
private String description;
|
||||||
|
|
||||||
|
public String getDefaultValue() {
|
||||||
|
return defaultValue;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDescription() {
|
||||||
|
return description;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String getPluginId() {
|
||||||
|
return plugin.defaultValue;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,207 @@
|
|||||||
|
package com.seeyon.apps.src_leasebill.controller;
|
||||||
|
|
||||||
|
import cn.hutool.log.Log;
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import com.seeyon.apps.common.config.ICstConfigApi;
|
||||||
|
import com.seeyon.apps.common.plugin.vo.ConfigVo;
|
||||||
|
import com.seeyon.apps.src_leasebill.constant.LeaseBillConstant;
|
||||||
|
import com.seeyon.apps.src_leasebill.dao.ILeaseBillDao;
|
||||||
|
import com.seeyon.apps.src_leasebill.util.DateUtil;
|
||||||
|
import com.seeyon.apps.src_leasebill.util.FormExportUtil;
|
||||||
|
import com.seeyon.apps.src_leasebill.util.LeaseBillUtil;
|
||||||
|
import com.seeyon.ctp.common.AppContext;
|
||||||
|
import com.seeyon.ctp.common.controller.BaseController;
|
||||||
|
import com.seeyon.ctp.util.json.JSONUtil;
|
||||||
|
import com.seeyon.v3x.services.form.FormFactory;
|
||||||
|
import com.seeyon.v3x.services.form.bean.FormExport;
|
||||||
|
import com.seeyon.v3x.services.form.bean.SubordinateFormExport;
|
||||||
|
import com.seeyon.v3x.services.form.bean.ValueExport;
|
||||||
|
import nc.vo.jcom.lang.StringUtil;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.io.BufferedReader;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.net.URLDecoder;
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
public class LeaseBillController extends BaseController {
|
||||||
|
|
||||||
|
private static Log log = Log.get(LeaseBillController.class);
|
||||||
|
protected ICstConfigApi cstConfigApi = (ICstConfigApi) AppContext.getBean("cstConfigApi");
|
||||||
|
|
||||||
|
private FormFactory formFactory;
|
||||||
|
|
||||||
|
public FormFactory getFormFactory() {
|
||||||
|
if (formFactory == null) {
|
||||||
|
formFactory = (FormFactory) AppContext.getBean("formFactory");
|
||||||
|
}
|
||||||
|
return formFactory;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setFormFactory(FormFactory formFactory) {
|
||||||
|
this.formFactory = formFactory;
|
||||||
|
}
|
||||||
|
|
||||||
|
private ILeaseBillDao leaseBillDao;
|
||||||
|
public void setLeaseBillDao(ILeaseBillDao leaseBillDao) {
|
||||||
|
this.leaseBillDao = leaseBillDao;
|
||||||
|
}
|
||||||
|
public ILeaseBillDao getLeaseBillDao() {
|
||||||
|
if (leaseBillDao == null) {
|
||||||
|
leaseBillDao = (ILeaseBillDao) AppContext.getBean("leaseBillDao");
|
||||||
|
}
|
||||||
|
return leaseBillDao;
|
||||||
|
}
|
||||||
|
|
||||||
|
public ModelAndView index(HttpServletRequest request, HttpServletResponse response) throws Exception {
|
||||||
|
log.info("进入ajax方法");
|
||||||
|
ConfigVo configVo = getYdctLeaseBillConfig();
|
||||||
|
DateUtil dateUtil = new DateUtil();
|
||||||
|
LeaseBillUtil leaseBillUtil = new LeaseBillUtil();
|
||||||
|
FormExportUtil formExportUtil = new FormExportUtil();
|
||||||
|
// 设置返回值对象
|
||||||
|
Map<String, Object> res = new HashMap<>();
|
||||||
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||||
|
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyyMMddHHmmsssss");
|
||||||
|
request.setCharacterEncoding("UTF-8");
|
||||||
|
response.setCharacterEncoding("UTF-8");
|
||||||
|
|
||||||
|
BufferedReader reader = request.getReader();
|
||||||
|
String line;
|
||||||
|
StringBuilder requestBody = new StringBuilder();
|
||||||
|
while((line = reader.readLine())!=null){
|
||||||
|
requestBody.append(line);
|
||||||
|
}
|
||||||
|
String data = requestBody.toString();
|
||||||
|
String decodedParam = URLDecoder.decode(data, "UTF-8");
|
||||||
|
String[] datas = decodedParam.split("&");
|
||||||
|
JSONObject jsonObject = new JSONObject();
|
||||||
|
for(int i = 0 ; i < datas.length ; i ++ ){
|
||||||
|
String[] params = datas[i].split("=");
|
||||||
|
if(params.length>1){
|
||||||
|
jsonObject.put(params[0],params[1]);
|
||||||
|
}else{
|
||||||
|
if(params[0].equals("bdid")){
|
||||||
|
jsonObject.put("bdid","0");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
String bdidValue = jsonObject.getString("bdid");
|
||||||
|
log.info("当前账单编号为:"+bdidValue);
|
||||||
|
if("0".equals(bdidValue)){
|
||||||
|
Date formDate = new Date();
|
||||||
|
String formId = simpleDateFormat.format(formDate);
|
||||||
|
// 账单编号
|
||||||
|
bdidValue = formId;
|
||||||
|
// formDataVo.getNewFieldDataMap().put("账单编号", formId);
|
||||||
|
}else {
|
||||||
|
List<String> ids = leaseBillDao.leaseBillByCode(bdidValue);
|
||||||
|
for (int i = 0; i < ids.size(); i++) {
|
||||||
|
// 删除明细账单
|
||||||
|
leaseBillDao.deleteBillsByBillId(ids.get(i));
|
||||||
|
// 删除主表数据
|
||||||
|
leaseBillDao.deleteBillById(ids.get(i));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
String code = bdidValue;
|
||||||
|
// 开始日期
|
||||||
|
String startDateStr = jsonObject.getString("startDate");
|
||||||
|
Date startDate = sdf.parse(startDateStr);
|
||||||
|
// 结束日期
|
||||||
|
String endDateStr = jsonObject.getString("endDate");
|
||||||
|
Date endDate = sdf.parse(endDateStr);
|
||||||
|
// 设置面积
|
||||||
|
String jifeifs = jsonObject.getString("jifeifs");
|
||||||
|
// 设置合同开始日期
|
||||||
|
Calendar startTime = Calendar.getInstance();
|
||||||
|
startTime.setTime(startDate);
|
||||||
|
// 判断合同开始时间是否为月底
|
||||||
|
boolean isMaxDay = false;
|
||||||
|
int currentDay = startTime.get(Calendar.DAY_OF_MONTH);
|
||||||
|
int maxDay = startTime.getActualMaximum(Calendar.DAY_OF_MONTH);
|
||||||
|
if(currentDay==maxDay){
|
||||||
|
isMaxDay = true;
|
||||||
|
}
|
||||||
|
// 设置合同结束日期
|
||||||
|
Calendar endTime = Calendar.getInstance();
|
||||||
|
endTime.setTime(endDate);
|
||||||
|
endTime.add(Calendar.DAY_OF_MONTH, 1);
|
||||||
|
|
||||||
|
// 根据缴费方式设置开始结束时间
|
||||||
|
String jiaofeifs = jsonObject.getString("jiaofeifs");
|
||||||
|
int jfzqNum = dateUtil.getCycleNum(jiaofeifs);
|
||||||
|
|
||||||
|
FormExport formExport = new FormExport();
|
||||||
|
// 租金
|
||||||
|
List<Map<String,String>> rents = new ArrayList<Map<String,String>>();
|
||||||
|
if(jfzqNum==12){
|
||||||
|
String njiaofeifs = jsonObject.getString("njiaofeifs");
|
||||||
|
if(StringUtil.isEmpty(njiaofeifs)){
|
||||||
|
res.put("success", true);
|
||||||
|
res.put("name", AppContext.currentUserLoginName());
|
||||||
|
res.put("s", "请选择年缴费计算方式");
|
||||||
|
res.put("num", "");
|
||||||
|
render(response, JSONUtil.toJSONString(res));
|
||||||
|
return null;
|
||||||
|
}else{
|
||||||
|
if(njiaofeifs.equals("正常年度")){
|
||||||
|
// 采用方式一/正常年度
|
||||||
|
rents = leaseBillUtil.getLeaseBillYers1(startTime,endTime,isMaxDay,jfzqNum,jsonObject,jifeifs);
|
||||||
|
}else if(njiaofeifs.equals("非正常年度")){
|
||||||
|
// 采用方式二/非正常年度
|
||||||
|
rents = leaseBillUtil.getLeaseBillYers2(startTime,endTime,isMaxDay,jfzqNum,jsonObject,jifeifs);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
// 根据标准方法生成
|
||||||
|
rents = leaseBillUtil.getLeaseBill(startTime,endTime,isMaxDay,jfzqNum,jsonObject,jifeifs);
|
||||||
|
}
|
||||||
|
log.info("创建档案");
|
||||||
|
List<SubordinateFormExport> subordinateFormExports = formExportUtil.setSubordinateFormValue(rents);
|
||||||
|
Map<String , String > billMap = new HashMap<String, String>();
|
||||||
|
billMap.put("账单编号", code);
|
||||||
|
List<ValueExport> valueExports = formExportUtil.setFormValue(billMap);
|
||||||
|
formExport.setSubordinateForms(subordinateFormExports);
|
||||||
|
formExport.setValues(valueExports);
|
||||||
|
String loginName = configVo.getParamVal(LeaseBillConstant.loginName.name());
|
||||||
|
getFormFactory().importBusinessFormData(loginName, "ZJZDMX",
|
||||||
|
formExport, new String[] {});
|
||||||
|
res.put("success", true);
|
||||||
|
res.put("name", AppContext.currentUserLoginName());
|
||||||
|
res.put("s", "");
|
||||||
|
res.put("num", code);
|
||||||
|
}catch (Exception e){
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
render(response, JSONUtil.toJSONString(res));
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 给前台渲染json数据
|
||||||
|
* @param response
|
||||||
|
* @param text
|
||||||
|
*/
|
||||||
|
private void render(HttpServletResponse response, String text) {
|
||||||
|
response.setContentType("application/json;charset=UTF-8");
|
||||||
|
try {
|
||||||
|
response.setContentLength(text.getBytes("UTF-8").length);
|
||||||
|
response.getWriter().write(text);
|
||||||
|
} catch (IOException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public ConfigVo getYdctLeaseBillConfig() {
|
||||||
|
return cstConfigApi.getConfig(getPluginId());
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPluginId() {
|
||||||
|
return LeaseBillConstant.getPluginId();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
package com.seeyon.apps.src_leasebill.dao;
|
||||||
|
|
||||||
|
import com.seeyon.ctp.common.exceptions.BusinessException;
|
||||||
|
|
||||||
|
import java.sql.SQLException;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface ILeaseBillDao {
|
||||||
|
|
||||||
|
// 查询账单底表id
|
||||||
|
public List<String> leaseBillByCode(String code) throws BusinessException, SQLException;
|
||||||
|
|
||||||
|
// 删除账单底表
|
||||||
|
public int deleteBillById(String id) throws BusinessException, SQLException;
|
||||||
|
|
||||||
|
// 删除账单明细表
|
||||||
|
public int deleteBillsByBillId(String formmainId) throws BusinessException, SQLException;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,84 @@
|
|||||||
|
package com.seeyon.apps.src_leasebill.dao.impl;
|
||||||
|
|
||||||
|
import com.seeyon.apps.src_leasebill.dao.ILeaseBillDao;
|
||||||
|
import com.seeyon.ctp.common.exceptions.BusinessException;
|
||||||
|
import com.seeyon.ctp.util.JDBCAgent;
|
||||||
|
|
||||||
|
import java.sql.SQLException;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
public class LeaseBillDaoImpl implements ILeaseBillDao {
|
||||||
|
//本地
|
||||||
|
// private String leaseBillByCode = "SELECT id FROM formmain_0231 WHERE field0004 = ? ";
|
||||||
|
// private String deleteBillById = "delete from formmain_0231 where id=?";
|
||||||
|
// private String deleteBillsByBillId = "delete from formson_0232 where formmain_id=?";
|
||||||
|
// 正式
|
||||||
|
private String leaseBillByCode = "SELECT id FROM formmain_0031 WHERE field0004 = ? ";
|
||||||
|
private String deleteBillById = "delete from formmain_0031 where id=?";
|
||||||
|
private String deleteBillsByBillId = "delete from formson_0032 where formmain_id=?";
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<String> leaseBillByCode(String code) throws BusinessException, SQLException {
|
||||||
|
List<String> lists = new ArrayList<String>();
|
||||||
|
JDBCAgent agent = new JDBCAgent();
|
||||||
|
try {
|
||||||
|
StringBuilder sql = new StringBuilder(leaseBillByCode);
|
||||||
|
// StringBuilder sql = new StringBuilder("SELECT id FROM formmain_0536 WHERE field0013 = ? ");
|
||||||
|
List<Object> p = new ArrayList<Object>();
|
||||||
|
p.add(code);
|
||||||
|
agent.execute(sql.toString(), p);
|
||||||
|
List<Map> list = agent.resultSetToList();
|
||||||
|
if (list != null && list.size() > 0) {
|
||||||
|
for(int i = 0 ; i < list.size() ; i++) {
|
||||||
|
Map map = list.get(i);
|
||||||
|
Object object = map.get("id");
|
||||||
|
lists.add(object.toString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}finally {
|
||||||
|
if (agent != null) {
|
||||||
|
agent.close();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return lists;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int deleteBillById(String id) throws BusinessException, SQLException {
|
||||||
|
int i = 0 ;
|
||||||
|
JDBCAgent agent = new JDBCAgent();
|
||||||
|
try {
|
||||||
|
StringBuilder sql = new StringBuilder(deleteBillById);
|
||||||
|
// StringBuilder sql = new StringBuilder("delete from formmain_0536 where id=?");
|
||||||
|
List<Object> p = new ArrayList<Object>();
|
||||||
|
p.add(id);
|
||||||
|
i=agent.execute(sql.toString(), p);
|
||||||
|
}finally {
|
||||||
|
if (agent != null) {
|
||||||
|
agent.close();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return i;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int deleteBillsByBillId(String formmainId) throws BusinessException, SQLException {
|
||||||
|
int i = 0 ;
|
||||||
|
JDBCAgent agent = new JDBCAgent();
|
||||||
|
try {
|
||||||
|
StringBuilder sql = new StringBuilder(deleteBillsByBillId);
|
||||||
|
// StringBuilder sql = new StringBuilder("delete from formson_0538 where formmain_id=?");
|
||||||
|
List<Object> p = new ArrayList<Object>();
|
||||||
|
p.add(formmainId);
|
||||||
|
i=agent.execute(sql.toString(), p);
|
||||||
|
}finally {
|
||||||
|
if (agent != null) {
|
||||||
|
agent.close();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return i;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,85 @@
|
|||||||
|
package com.seeyon.apps.src_leasebill.fieldCtrl;
|
||||||
|
|
||||||
|
import com.seeyon.cap4.form.bean.ParamDefinition;
|
||||||
|
import com.seeyon.cap4.form.bean.fieldCtrl.FormFieldCustomCtrl;
|
||||||
|
import com.seeyon.cap4.form.util.Enums.ParamType;
|
||||||
|
import www.seeyon.com.utils.UUIDUtil;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* 自定义控件:调用接口
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public class LeaseBillFieldCtrl extends FormFieldCustomCtrl {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UUIDLong.longUUID()
|
||||||
|
* UUIDUtil.getUUIDString()
|
||||||
|
*/
|
||||||
|
public String getKey() {
|
||||||
|
return "5209586381190735608";
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void main(String[] args) {
|
||||||
|
System.out.println(UUIDUtil.getUUIDLong());
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getFieldLength() {
|
||||||
|
return "20";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 控件初始化接口,此接口在控件初始化的时候,会调用,主要用于定义控件所属插件id、在表单编辑器中的图标、表单编辑器中有哪些属性可以设置。
|
||||||
|
* 使用举例:在接口中定义自定义控件在在表单编辑器中有哪些控件属性需要配置
|
||||||
|
*/
|
||||||
|
public void init() {
|
||||||
|
setPluginId("ydctLeaseBill");
|
||||||
|
setIcon("cap-icon-interestMeasurement");
|
||||||
|
// 自定义参数
|
||||||
|
ParamDefinition templateIdParam = new ParamDefinition();
|
||||||
|
templateIdParam.setParamType(ParamType.button);
|
||||||
|
addDefinition(templateIdParam);
|
||||||
|
}
|
||||||
|
|
||||||
|
/** (non-Javadoc)
|
||||||
|
* @see FormFieldCustomCtrl#getPCInjectionInfo()
|
||||||
|
* PC端的资源文件路径
|
||||||
|
*/
|
||||||
|
public String getPCInjectionInfo() {
|
||||||
|
return "{path:'apps_res/cap/customCtrlResources/leaseBillResources/',jsUri:'js/openUnflow.js',initMethod:'init',nameSpace:'field_" + getKey() + "'}";
|
||||||
|
}
|
||||||
|
|
||||||
|
/** (non-Javadoc)
|
||||||
|
* @see FormFieldCustomCtrl#getMBInjectionInfo()
|
||||||
|
* 移动端的资源地址
|
||||||
|
*/
|
||||||
|
public String getMBInjectionInfo() {
|
||||||
|
return "{path:'http://newwidget.v5.cmp/v1.0.0/',weixinpath:'newwidget',jsUri:'js/newwidget.js',initMethod:'init',nameSpace:'field_" + this.getKey() + "'}";
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getText() {
|
||||||
|
return "租金计算按钮";
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean canBathUpdate() {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<String[]> getListShowDefaultVal(Integer externalType) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 初始值生成接口
|
||||||
|
*/
|
||||||
|
public String[] getDefaultVal(String defaultValue) {
|
||||||
|
return new String[0];
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean canInjectionWord() {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,135 @@
|
|||||||
|
package com.seeyon.apps.src_leasebill.util;
|
||||||
|
|
||||||
|
import java.text.ParseException;
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.Calendar;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
public class DateUtil {
|
||||||
|
|
||||||
|
// 查询两个时间相差多少月
|
||||||
|
public int betweenMonthByTwoCalendar(Calendar startCalendar,Calendar endCalendar) {
|
||||||
|
if(startCalendar.after(endCalendar)){
|
||||||
|
Calendar temp = startCalendar;
|
||||||
|
startCalendar = endCalendar;
|
||||||
|
endCalendar = temp;
|
||||||
|
}
|
||||||
|
// int startYear = startCalendar.get(Calendar.YEAR);
|
||||||
|
// int endYear = endCalendar.get(Calendar.YEAR);
|
||||||
|
// int startMonth = startCalendar.get(Calendar.MONTH);
|
||||||
|
// int endMonth = endCalendar.get(Calendar.MONTH);
|
||||||
|
// int monthNum = (endYear - startYear)*12+(endMonth-startMonth);
|
||||||
|
// return monthNum;
|
||||||
|
|
||||||
|
int yearsDiff = endCalendar.get(Calendar.YEAR) - startCalendar.get(Calendar.YEAR);
|
||||||
|
int monthsDiff = yearsDiff * 12 + endCalendar.get(Calendar.MONTH)- startCalendar.get(Calendar.MONTH);
|
||||||
|
if (endCalendar.get(Calendar.DAY_OF_MONTH) > startCalendar.get(Calendar.DAY_OF_MONTH)) {
|
||||||
|
monthsDiff++;
|
||||||
|
}
|
||||||
|
return monthsDiff;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public String discrepancyDay(String str1,String str2) throws ParseException {
|
||||||
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||||
|
// 将字符串转换成日期
|
||||||
|
Date start = sdf.parse(str1);
|
||||||
|
Date end = sdf.parse(str2);
|
||||||
|
// Date end = new Date();
|
||||||
|
Date d3 = null;
|
||||||
|
if(start.getTime()-end.getTime()>0){
|
||||||
|
d3 = start;
|
||||||
|
start = end;
|
||||||
|
end = d3;
|
||||||
|
}
|
||||||
|
Calendar c1 = Calendar.getInstance();
|
||||||
|
|
||||||
|
Calendar c2 = Calendar.getInstance();
|
||||||
|
c1.setTime(start);
|
||||||
|
c2.setTime(end);
|
||||||
|
c2.add(c2.DATE,1);
|
||||||
|
end = c2.getTime();
|
||||||
|
// System.out.println(sdf.format( c2.getTime()));
|
||||||
|
int year1 = c1.get(Calendar.YEAR);
|
||||||
|
|
||||||
|
int year2 = c2.get(Calendar.YEAR);
|
||||||
|
|
||||||
|
int month1 = c1.get(Calendar.MONTH);
|
||||||
|
|
||||||
|
int month2 = c2.get(Calendar.MONTH);
|
||||||
|
|
||||||
|
int day1 = c1.get(Calendar.DAY_OF_MONTH);
|
||||||
|
|
||||||
|
int day2 = c2.get(Calendar.DAY_OF_MONTH);
|
||||||
|
|
||||||
|
int yearInterval = year1 - year2;
|
||||||
|
|
||||||
|
if (month1 < month2 || month1 == month2 && day1 < day2)
|
||||||
|
|
||||||
|
yearInterval--;
|
||||||
|
|
||||||
|
int monthInterval = (month1 + 12) - month2;
|
||||||
|
|
||||||
|
if (day1 < day2)
|
||||||
|
|
||||||
|
monthInterval--;
|
||||||
|
|
||||||
|
monthInterval %= 12;
|
||||||
|
|
||||||
|
int monthsDiff = Math.abs(yearInterval * 12 + monthInterval);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
int nian = monthsDiff/12;
|
||||||
|
int yue = monthsDiff - (nian*12);
|
||||||
|
c1.add(Calendar.YEAR, nian);
|
||||||
|
if(day1==day2){
|
||||||
|
c1.add(Calendar.MONTH, yue);
|
||||||
|
}else {
|
||||||
|
|
||||||
|
c1.add(Calendar.MONTH, yue-1);
|
||||||
|
if(yue-1<0) {
|
||||||
|
nian--;
|
||||||
|
yue=11;
|
||||||
|
}else {
|
||||||
|
yue -=1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// System.out.println(nian+"年");
|
||||||
|
// System.out.println(yue+"月");
|
||||||
|
Date dt1 = c1.getTime();
|
||||||
|
long l = dt1.getTime() - end.getTime();
|
||||||
|
long tian = l/-(24*60*60*1000);
|
||||||
|
return nian+"-"+yue+"-"+tian;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public int getCycleNum (String cycle){
|
||||||
|
int cycleNum = 1;
|
||||||
|
if("月".equals(cycle)||"月付".equals(cycle)){
|
||||||
|
cycleNum = 1;
|
||||||
|
}else if("季".equals(cycle)||"季付".equals(cycle)){
|
||||||
|
cycleNum = 3;
|
||||||
|
}else if("半年".equals(cycle)||"半年付".equals(cycle)){
|
||||||
|
cycleNum = 6;
|
||||||
|
}else if("年".equals(cycle)||"年付".equals(cycle)){
|
||||||
|
cycleNum = 12;
|
||||||
|
}else if("一次性".equals(cycle)||"其他".equals(cycle)){
|
||||||
|
cycleNum = 99;
|
||||||
|
}
|
||||||
|
return cycleNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double stringToNum(String str){
|
||||||
|
double i = 0 ;
|
||||||
|
String[] strs = str.split(",");
|
||||||
|
StringBuilder numString = new StringBuilder();
|
||||||
|
for (String value: strs) {
|
||||||
|
numString.append(value);
|
||||||
|
}
|
||||||
|
i = Double.parseDouble(numString.toString());
|
||||||
|
return i;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
package com.seeyon.apps.src_leasebill.util
|
||||||
|
;
|
||||||
|
|
||||||
|
import com.seeyon.v3x.services.form.bean.RecordExport;
|
||||||
|
import com.seeyon.v3x.services.form.bean.SubordinateFormExport;
|
||||||
|
import com.seeyon.v3x.services.form.bean.ValueExport;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.Set;
|
||||||
|
|
||||||
|
//创建无流程表单数据处理工具类
|
||||||
|
public class FormExportUtil {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设置主表信息
|
||||||
|
* @param map 设置主表字段。Map<主表显示名称,主表数据>
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public List<ValueExport> setFormValue(Map<String, String> map){
|
||||||
|
// 创建返回值对象
|
||||||
|
List<ValueExport> valueExports = new ArrayList<ValueExport>();
|
||||||
|
ValueExport valueExport ;
|
||||||
|
// 获取参数信息(显示名称)
|
||||||
|
Set<String> keys = map.keySet();
|
||||||
|
if(keys.size()>0) {
|
||||||
|
// 对控件赋值
|
||||||
|
for (String key : keys) {
|
||||||
|
valueExport = new ValueExport();
|
||||||
|
valueExport.setDisplayName(key);
|
||||||
|
valueExport.setValue(map.get(key));
|
||||||
|
valueExports.add(valueExport);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return valueExports;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设置从表信息
|
||||||
|
* @param map 设置主表字段。List<Map<显示名称,数据值>>
|
||||||
|
*/
|
||||||
|
public List<SubordinateFormExport> setSubordinateFormValue(List<Map<String, String>> lists){
|
||||||
|
List<SubordinateFormExport> subordinateFormExports = new ArrayList<SubordinateFormExport>();
|
||||||
|
SubordinateFormExport subordinateFormExport = new SubordinateFormExport();
|
||||||
|
List<RecordExport> recordExports = new ArrayList<RecordExport>();
|
||||||
|
List<ValueExport> valueExports;
|
||||||
|
RecordExport recordExport;
|
||||||
|
for(int i = 0 ; i < lists.size() ; i++) {
|
||||||
|
recordExport = new RecordExport();
|
||||||
|
valueExports = setFormValue(lists.get(i));
|
||||||
|
recordExport.setRecord(valueExports);
|
||||||
|
recordExports.add(recordExport);
|
||||||
|
}
|
||||||
|
subordinateFormExport.setValues(recordExports);
|
||||||
|
subordinateFormExports.add(subordinateFormExport);
|
||||||
|
|
||||||
|
return subordinateFormExports;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,277 @@
|
|||||||
|
package com.seeyon.apps.src_leasebill.util;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
public class LeaseBillUtil {
|
||||||
|
|
||||||
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生成租金账单
|
||||||
|
* @param startTime 开始时间
|
||||||
|
* @param endTime 结束时间
|
||||||
|
* @param isMaxDay 是否每月最后一天
|
||||||
|
* @param jfzqNum 缴费周期月
|
||||||
|
* @param jsonObject 请求参数
|
||||||
|
* @param jifeifs 计费方式
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public List<Map<String,String>> getLeaseBill(Calendar startTime, Calendar endTime, boolean isMaxDay, int jfzqNum,
|
||||||
|
JSONObject jsonObject,String jifeifs){
|
||||||
|
List<Map<String,String>> rents = new ArrayList<>();
|
||||||
|
DateUtil dateUtil = new DateUtil();
|
||||||
|
// 两个日期相差多少月
|
||||||
|
int monthNum = dateUtil.betweenMonthByTwoCalendar(startTime,endTime);
|
||||||
|
if(jfzqNum==99){
|
||||||
|
// 一次性账单生成
|
||||||
|
Map<String,String> rent = new HashMap<>();
|
||||||
|
float zlmjFloat = 0;
|
||||||
|
double zf = 0;
|
||||||
|
if("面积计费".equals(jifeifs)){
|
||||||
|
String mjStr = jsonObject.getString("mj");
|
||||||
|
zlmjFloat = Float.parseFloat(mjStr);
|
||||||
|
String mjzjStr = jsonObject.getString("mjzj");
|
||||||
|
double mjzj = dateUtil.stringToNum(mjzjStr);
|
||||||
|
zf = mjzj*zlmjFloat*monthNum;
|
||||||
|
}else if ("固定租金".equals(jifeifs)){
|
||||||
|
zlmjFloat = 1;
|
||||||
|
String gdzjStr = jsonObject.getString("gdzj");
|
||||||
|
double gdzj = dateUtil.stringToNum(gdzjStr);
|
||||||
|
// zf = gdzj*zlmjFloat*monthNum;
|
||||||
|
zf = gdzj*zlmjFloat;
|
||||||
|
}
|
||||||
|
rent.put("开始日期",sdf.format(startTime.getTime()));
|
||||||
|
endTime.add(Calendar.DATE, -1);
|
||||||
|
rent.put("结束日期",sdf.format(endTime.getTime()));
|
||||||
|
rent.put("租费",zf+"");
|
||||||
|
rents.add(rent);
|
||||||
|
}else{
|
||||||
|
// 月,季,半年,账单生成
|
||||||
|
int termNum = monthNum/jfzqNum;
|
||||||
|
int mo = monthNum%jfzqNum;
|
||||||
|
if(mo!=0){
|
||||||
|
termNum++;
|
||||||
|
}
|
||||||
|
float zlmjFloat = 0;
|
||||||
|
double zf = 0;
|
||||||
|
if("面积计费".equals(jifeifs)){
|
||||||
|
String mjStr = jsonObject.getString("mj");
|
||||||
|
zlmjFloat = Float.parseFloat(mjStr);
|
||||||
|
String mjzjStr = jsonObject.getString("mjzj");
|
||||||
|
double mjzj = dateUtil.stringToNum(mjzjStr);
|
||||||
|
zf = mjzj*zlmjFloat;
|
||||||
|
}else if ("固定租金".equals(jifeifs)){
|
||||||
|
zlmjFloat = 1;
|
||||||
|
String gdzjStr = jsonObject.getString("gdzj");
|
||||||
|
double gdzj = dateUtil.stringToNum(gdzjStr);
|
||||||
|
zf = gdzj*zlmjFloat;
|
||||||
|
}
|
||||||
|
for(int i = 0 ; i < termNum ; i ++) {
|
||||||
|
if (startTime.getTime().getTime() < endTime.getTime().getTime()) {
|
||||||
|
Map<String, String> rentMap = new HashMap<String, String>();
|
||||||
|
// 设置租费时间
|
||||||
|
rentMap.put("开始日期", sdf.format(startTime.getTime()));
|
||||||
|
if (!isMaxDay) {
|
||||||
|
startTime.add(Calendar.MONTH, jfzqNum);
|
||||||
|
startTime.add(Calendar.DAY_OF_MONTH, -1);
|
||||||
|
}else{
|
||||||
|
startTime.add(Calendar.MONTH, jfzqNum);
|
||||||
|
startTime.set(Calendar.DAY_OF_MONTH, startTime.getActualMaximum(Calendar.DAY_OF_MONTH)-1);
|
||||||
|
}
|
||||||
|
if (startTime.getTime().getTime() < endTime.getTime().getTime()) {
|
||||||
|
// rentMap.put("期间月数-租金",jfzqNum+"");
|
||||||
|
// rentMap.put("租费", (zf * jfzqNum) + "");
|
||||||
|
if("面积计费".equals(jifeifs)){
|
||||||
|
rentMap.put("租费", (zf * jfzqNum) + "");
|
||||||
|
}else if ("固定租金".equals(jifeifs)){
|
||||||
|
rentMap.put("租费", (zf * 1) + "");
|
||||||
|
}
|
||||||
|
rentMap.put("结束日期", sdf.format(startTime.getTime()));
|
||||||
|
} else {
|
||||||
|
//两个日期相差多少月
|
||||||
|
startTime.add(Calendar.MONTH, jfzqNum*-1);
|
||||||
|
startTime.add(Calendar.DAY_OF_MONTH, 1);
|
||||||
|
int qijianyueshu = dateUtil.betweenMonthByTwoCalendar(startTime, endTime);
|
||||||
|
// rentMap.put("期间月数-租金",qijianyueshu+"");
|
||||||
|
if("面积计费".equals(jifeifs)){
|
||||||
|
rentMap.put("租费", (zf * qijianyueshu) + "");
|
||||||
|
}else if ("固定租金".equals(jifeifs)){
|
||||||
|
rentMap.put("租费", (zf * 1) + "");
|
||||||
|
}
|
||||||
|
|
||||||
|
endTime.add(Calendar.DAY_OF_MONTH, -1);
|
||||||
|
rentMap.put("结束日期", sdf.format(endTime.getTime()));
|
||||||
|
}
|
||||||
|
startTime.add(Calendar.DAY_OF_MONTH, 1);
|
||||||
|
if (isMaxDay) {
|
||||||
|
startTime.set(Calendar.DAY_OF_MONTH, startTime.getActualMaximum(Calendar.DAY_OF_MONTH));
|
||||||
|
}
|
||||||
|
rents.add(rentMap);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return rents;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生成租金账单
|
||||||
|
* @param startTime 开始时间
|
||||||
|
* @param endTime 结束时间
|
||||||
|
* @param isMaxDay 是否每月最后一天
|
||||||
|
* @param jfzqNum 缴费周期月
|
||||||
|
* @param jsonObject 请求参数
|
||||||
|
* @param jifeifs 计费方式
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public List<Map<String,String>> getLeaseBillYers1(Calendar startTime, Calendar endTime, boolean isMaxDay, int jfzqNum,
|
||||||
|
JSONObject jsonObject,String jifeifs){
|
||||||
|
List<Map<String,String>> rents = new ArrayList<>();
|
||||||
|
DateUtil dateUtil = new DateUtil();
|
||||||
|
// 两个日期相差多少月
|
||||||
|
int monthNum = dateUtil.betweenMonthByTwoCalendar(startTime,endTime);
|
||||||
|
int termNum = monthNum/jfzqNum;
|
||||||
|
int mo = monthNum%jfzqNum;
|
||||||
|
if(mo!=0){
|
||||||
|
termNum++;
|
||||||
|
}
|
||||||
|
float zlmjFloat = 0;
|
||||||
|
double zf = 0;
|
||||||
|
if("面积计费".equals(jifeifs)){
|
||||||
|
String mjStr = jsonObject.getString("mj");
|
||||||
|
zlmjFloat = Float.parseFloat(mjStr);
|
||||||
|
String mjzjStr = jsonObject.getString("mjzj");
|
||||||
|
double mjzj = dateUtil.stringToNum(mjzjStr);
|
||||||
|
zf = mjzj*zlmjFloat;
|
||||||
|
}else if ("固定租金".equals(jifeifs)){
|
||||||
|
zlmjFloat = 1;
|
||||||
|
String gdzjStr = jsonObject.getString("gdzj");
|
||||||
|
double gdzj = dateUtil.stringToNum(gdzjStr);
|
||||||
|
zf = gdzj*zlmjFloat;
|
||||||
|
}
|
||||||
|
for(int i = 0 ; i < termNum ; i ++) {
|
||||||
|
if (startTime.getTime().getTime() < endTime.getTime().getTime()) {
|
||||||
|
Map<String, String> rentMap = new HashMap<String, String>();
|
||||||
|
// 设置租费时间
|
||||||
|
rentMap.put("开始日期", sdf.format(startTime.getTime()));
|
||||||
|
startTime.add(Calendar.MONTH, jfzqNum);
|
||||||
|
startTime.add(Calendar.DAY_OF_MONTH, -1);
|
||||||
|
if (startTime.getTime().getTime() < endTime.getTime().getTime()) {
|
||||||
|
// rentMap.put("期间月数-租金",jfzqNum+"");
|
||||||
|
// rentMap.put("租费", (zf * jfzqNum) + "");
|
||||||
|
if("固定租金".equals(jifeifs)){
|
||||||
|
rentMap.put("租费", (zf * 1) + "");
|
||||||
|
}else{
|
||||||
|
rentMap.put("租费", (zf * jfzqNum) + "");
|
||||||
|
}
|
||||||
|
rentMap.put("结束日期", sdf.format(startTime.getTime()));
|
||||||
|
} else {
|
||||||
|
//两个日期相差多少月
|
||||||
|
startTime.add(Calendar.MONTH, jfzqNum*-1);
|
||||||
|
startTime.add(Calendar.DAY_OF_MONTH, 1);
|
||||||
|
int qijianyueshu = dateUtil.betweenMonthByTwoCalendar(startTime, endTime);
|
||||||
|
// rentMap.put("期间月数-租金",qijianyueshu+"");
|
||||||
|
// rentMap.put("租费", (zf * qijianyueshu) + "");
|
||||||
|
if("固定租金".equals(jifeifs)){
|
||||||
|
rentMap.put("租费", (zf * 1) + "");
|
||||||
|
}else{
|
||||||
|
rentMap.put("租费", (zf * qijianyueshu) + "");
|
||||||
|
}
|
||||||
|
endTime.add(Calendar.DAY_OF_MONTH, -1);
|
||||||
|
rentMap.put("结束日期", sdf.format(endTime.getTime()));
|
||||||
|
}
|
||||||
|
startTime.add(Calendar.DAY_OF_MONTH, 1);
|
||||||
|
if (isMaxDay) {
|
||||||
|
startTime.set(Calendar.DAY_OF_MONTH, startTime.getActualMaximum(Calendar.DAY_OF_MONTH));
|
||||||
|
}
|
||||||
|
rents.add(rentMap);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return rents;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生成租金账单
|
||||||
|
* @param startTime 开始时间
|
||||||
|
* @param endTime 结束时间
|
||||||
|
* @param isMaxDay 是否每月最后一天
|
||||||
|
* @param jfzqNum 缴费周期月
|
||||||
|
* @param jsonObject 请求参数
|
||||||
|
* @param jifeifs 计费方式
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public List<Map<String,String>> getLeaseBillYers2(Calendar startTime, Calendar endTime, boolean isMaxDay, int jfzqNum,
|
||||||
|
JSONObject jsonObject,String jifeifs){
|
||||||
|
List<Map<String,String>> rents = new ArrayList<>();
|
||||||
|
DateUtil dateUtil = new DateUtil();
|
||||||
|
// 两个日期相差多少年
|
||||||
|
Calendar calendar = Calendar.getInstance();
|
||||||
|
calendar.setTime(startTime.getTime());
|
||||||
|
int starYear = startTime.get(Calendar.YEAR);
|
||||||
|
int endYear = endTime.get(Calendar.YEAR);
|
||||||
|
int termNum = endYear-starYear+1;
|
||||||
|
float zlmjFloat = 0;
|
||||||
|
double zf = 0;
|
||||||
|
if("面积计费".equals(jifeifs)){
|
||||||
|
String mjStr = jsonObject.getString("mj");
|
||||||
|
zlmjFloat = Float.parseFloat(mjStr);
|
||||||
|
String mjzjStr = jsonObject.getString("mjzj");
|
||||||
|
double mjzj = dateUtil.stringToNum(mjzjStr);
|
||||||
|
zf = mjzj*zlmjFloat;
|
||||||
|
}else if ("固定租金".equals(jifeifs)){
|
||||||
|
zlmjFloat = 1;
|
||||||
|
String gdzjStr = jsonObject.getString("gdzj");
|
||||||
|
double gdzj = dateUtil.stringToNum(gdzjStr);
|
||||||
|
zf = gdzj*zlmjFloat;
|
||||||
|
}
|
||||||
|
|
||||||
|
for(int i = 0 ; i < termNum ; i ++) {
|
||||||
|
if (startTime.getTime().getTime() < endTime.getTime().getTime()) {
|
||||||
|
Map<String, String> rentMap = new HashMap<String, String>();
|
||||||
|
// 设置租费时间
|
||||||
|
rentMap.put("开始日期", sdf.format(startTime.getTime()));
|
||||||
|
startTime.set(Calendar.MONTH, 11);
|
||||||
|
startTime.set(Calendar.DATE, 31);
|
||||||
|
if (startTime.getTime().getTime() < endTime.getTime().getTime()) {
|
||||||
|
// rentMap.put("期间月数-租金",jfzqNum+"");
|
||||||
|
startTime.add(Calendar.DAY_OF_MONTH, 1);
|
||||||
|
int qijianyueshu = dateUtil.betweenMonthByTwoCalendar(calendar, startTime);
|
||||||
|
startTime.add(Calendar.DAY_OF_MONTH, -1);
|
||||||
|
// rentMap.put("租费", (zf * qijianyueshu) + "");
|
||||||
|
if ("固定租金".equals(jifeifs)){
|
||||||
|
rentMap.put("租费", (zf * 1) + "");
|
||||||
|
}else{
|
||||||
|
rentMap.put("租费", (zf * qijianyueshu) + "");
|
||||||
|
}
|
||||||
|
rentMap.put("结束日期", sdf.format(startTime.getTime()));
|
||||||
|
calendar.set(Calendar.MONTH, 11);
|
||||||
|
calendar.set(Calendar.DATE, 31);
|
||||||
|
} else {
|
||||||
|
//两个日期相差多少月
|
||||||
|
int qijianyueshu = dateUtil.betweenMonthByTwoCalendar(calendar, endTime);
|
||||||
|
// rentMap.put("期间月数-租金",qijianyueshu+"");
|
||||||
|
// rentMap.put("租费", (zf * qijianyueshu) + "");
|
||||||
|
if ("固定租金".equals(jifeifs)){
|
||||||
|
rentMap.put("租费", (zf * 1) + "");
|
||||||
|
}else{
|
||||||
|
rentMap.put("租费", (zf * qijianyueshu) + "");
|
||||||
|
}
|
||||||
|
endTime.add(Calendar.DAY_OF_MONTH, -1);
|
||||||
|
rentMap.put("结束日期", sdf.format(endTime.getTime()));
|
||||||
|
}
|
||||||
|
startTime.add(Calendar.DAY_OF_MONTH, 1);
|
||||||
|
calendar.add(Calendar.DAY_OF_MONTH, 1);
|
||||||
|
if (isMaxDay) {
|
||||||
|
startTime.set(Calendar.DAY_OF_MONTH, startTime.getActualMaximum(Calendar.DAY_OF_MONTH));
|
||||||
|
}
|
||||||
|
rents.add(rentMap);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return rents;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
322
v5/apps-customize/src/main/resources/needless_check_login.xml
Normal file
322
v5/apps-customize/src/main/resources/needless_check_login.xml
Normal file
@@ -0,0 +1,322 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<beans>
|
||||||
|
<bean>
|
||||||
|
<id>/qrCodeForm.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
<method>newMain</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/sc.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>qr</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/elearning.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>error</method>
|
||||||
|
<method>m3Redirect</method>
|
||||||
|
<method>message</method>
|
||||||
|
<method>pcRedirect</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/phoneLogin/phoneLogin.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>getMessageCode</method>
|
||||||
|
<method>validateMessageCode</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/wechat/miniprogram.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>a8home</method>
|
||||||
|
<method>bind</method>
|
||||||
|
<method>bindMemberPhone</method>
|
||||||
|
<method>login</method>
|
||||||
|
<method>unbind</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/portal/spaceController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>showThemSpace</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/identification.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>getSessionId</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/fileUpload.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>showRTE</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/fileDownload.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>showRTE</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/form/formUpgrade.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>toUpgrade</method>
|
||||||
|
<method>upgrade</method>
|
||||||
|
<method>viewUpgrade</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>formtalkFormMapperController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>importFormtalkData</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/thirdpartyController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>access</method>
|
||||||
|
<method>index</method>
|
||||||
|
<method>logoutNotify</method>
|
||||||
|
<method>show</method>
|
||||||
|
<method>mailAuth</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/main.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>changeLocale</method>
|
||||||
|
<method>hangup</method>
|
||||||
|
<method>headerjs</method>
|
||||||
|
<method>index</method>
|
||||||
|
<method>login</method>
|
||||||
|
<method>login4Ucpc</method>
|
||||||
|
<method>login4Ucpc3</method>
|
||||||
|
<method>login4Vjoin</method>
|
||||||
|
<method>logout</method>
|
||||||
|
<method>logout4Session</method>
|
||||||
|
<method>logout4Vjoin</method>
|
||||||
|
<method>logout4ZX</method>
|
||||||
|
<method>main</method>
|
||||||
|
<method>login4QrCode</method>
|
||||||
|
<method>qrCodeHelp</method>
|
||||||
|
<method>updateLoginSeed</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/trustdo/A8/XRD.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>getLoginAccount</method>
|
||||||
|
<method>getLoginAcctoken</method>
|
||||||
|
<method>webLogin</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/share.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/genericController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/edoc/edocUpgradeControllor.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>upgrade</method>
|
||||||
|
<method>download</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/uploadService.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>processUploadService</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/autoinstall.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>ieSetDown</method>
|
||||||
|
<method>regInstallDown</method>
|
||||||
|
<method>regInstallDown64</method>
|
||||||
|
<method>downloadAssistant</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/personalBind.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>getBindTypeByLoginName</method>
|
||||||
|
<method>isCanUse</method>
|
||||||
|
<method>retrievePassword</method>
|
||||||
|
<method>sendVerificationCodeToBindEmail</method>
|
||||||
|
<method>sendVerificationCodeToBindNum</method>
|
||||||
|
<method>validateVerificationCode</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<!-- <bean>白名单清理-->
|
||||||
|
<!-- <id>/meetingPanel.do</id>-->
|
||||||
|
<!-- <methods>-->
|
||||||
|
<!-- <method>meetingPanelDisplay</method>-->
|
||||||
|
<!-- <method>meetingPanelView</method>-->
|
||||||
|
<!-- </methods>-->
|
||||||
|
<!-- </bean>-->
|
||||||
|
<bean>
|
||||||
|
<id>/commonimage.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>showImage</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/individualManager.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>resetPassword</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/wechat/dingding.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>binding</method>
|
||||||
|
<method>index</method>
|
||||||
|
<method>main</method>
|
||||||
|
<method>newIndex</method>
|
||||||
|
<method>newMain</method>
|
||||||
|
<method>viewh5Message</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/uc/rest.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>commonPierce</method>
|
||||||
|
<method>downloadImage</method>
|
||||||
|
<method>getBgTimeStamp</method>
|
||||||
|
<method>getLoginsecurityMsg</method>
|
||||||
|
<method>sendsms</method>
|
||||||
|
<method>smsrequired</method>
|
||||||
|
<method>testIp</method>
|
||||||
|
<method>isQrLogin</method>
|
||||||
|
<method>getDigitalCodeInfo</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>portalManager</id>
|
||||||
|
<methods>
|
||||||
|
<method>sendSMSLoginCode</method>
|
||||||
|
<method>smsLoginEnabled</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>loginUserManager</id>
|
||||||
|
<methods>
|
||||||
|
<method>getLockTime</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>qrCodeLoginManager</id>
|
||||||
|
<methods>
|
||||||
|
<method>isLogin</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>meetingAjaxManager</id>
|
||||||
|
<methods>
|
||||||
|
<method>meetingPanelData</method>
|
||||||
|
<method>meetingPanelDisplay</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/m3/loginController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>transLogin</method>
|
||||||
|
<method>transLogout</method>
|
||||||
|
<method>getProfile</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/m3/mClientBindController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>bindApply</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>m3ProductManager</id>
|
||||||
|
<methods>
|
||||||
|
<method>productInfo</method>
|
||||||
|
<method>productStatus</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/m3/homeSkinController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>downloadImage</method>
|
||||||
|
<method>getSkinImageUrl</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/m3/transModeController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>getTransModeForMobile</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/media/media.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>mediaShow</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/ocipEdoc.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/colView.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/caAccountManagerController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>findKeyNumByLoginName</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/fddCallbackController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>asynch</method>
|
||||||
|
<method>synch</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/seeyonReport/seeyonReportController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>redirectSeeyonReport</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/imc.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
<method>logout</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
|
||||||
|
<bean>
|
||||||
|
<id>/cloudbuild.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>download</method>
|
||||||
|
<method>getDownloadPageInfo</method>
|
||||||
|
<method>getLatestVersionInfo</method>
|
||||||
|
<method>getDownloadQrUrl</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
</beans>
|
||||||
@@ -0,0 +1,426 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
|
||||||
|
<beans>
|
||||||
|
|
||||||
|
<bean>
|
||||||
|
<id>/qrCodeForm.do</id>
|
||||||
|
<name>com.seeyon.apps.qrCodeForm.controller.QrCodeFormController</name>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
<method>newMain</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
|
||||||
|
<bean>
|
||||||
|
<id>/sc.do</id>
|
||||||
|
<name>com.seeyon.cap4.form.modules.smartCode.controller.SmartCodeController</name>
|
||||||
|
<methods>
|
||||||
|
<method>qr</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/media/media.do</id>
|
||||||
|
<name>com.seeyon.ctp.common.media.controller.MediaController</name>
|
||||||
|
<methods>
|
||||||
|
<method>mediaShow</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/phoneLogin/phoneLogin.do</id>
|
||||||
|
<name>com.seeyon.ctp.login.controller.PhoneLoginController</name>
|
||||||
|
<methods>
|
||||||
|
<method>getMessageCode</method>
|
||||||
|
<method>validateMessageCode</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>portalManager</id>
|
||||||
|
<name>com.seeyon.ctp.portal.manager.PortalManagerImpl</name>
|
||||||
|
<methods>
|
||||||
|
<method>sendSMSLoginCode</method>
|
||||||
|
<method>smsLoginEnabled</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/fileDownload.do</id>
|
||||||
|
<name>com.seeyon.ctp.common.fileupload.FileUploadController</name>
|
||||||
|
<methods>
|
||||||
|
<method>showRTE</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>loginUserManager</id>
|
||||||
|
<name>com.seeyon.ctp.login.LoginUserManagerImpl</name>
|
||||||
|
<methods>
|
||||||
|
<method>getLockTime</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/main.do</id>
|
||||||
|
<name>com.seeyon.ctp.login.controller.MainController</name>
|
||||||
|
<methods>
|
||||||
|
<method>changeLocale</method>
|
||||||
|
<method>hangup</method>
|
||||||
|
<method>headerjs</method>
|
||||||
|
<method>index</method>
|
||||||
|
<method>login</method>
|
||||||
|
<method>login4Ucpc</method>
|
||||||
|
<method>login4Ucpc3</method>
|
||||||
|
<method>login4Vjoin</method>
|
||||||
|
<method>logout</method>
|
||||||
|
<method>logout4Session</method>
|
||||||
|
<method>logout4Vjoin</method>
|
||||||
|
<method>logout4ZX</method>
|
||||||
|
<method>main</method>
|
||||||
|
<method>login4QrCode</method>
|
||||||
|
<method>qrCodeHelp</method>
|
||||||
|
<method>updateLoginSeed</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/trustdo/A8/XRD.do</id>
|
||||||
|
<name>com.seeyon.apps.trustdo.controller.XRDController</name>
|
||||||
|
<methods>
|
||||||
|
<method>getLoginAccount</method>
|
||||||
|
<method>getLoginAcctoken</method>
|
||||||
|
<method>webLogin</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/share.do</id>
|
||||||
|
<name>com.seeyon.v3x.system.share.controller.ShareController</name>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/edoc/edocUpgradeControllor.do</id>
|
||||||
|
<name>com.seeyon.v3x.edoc.controller.EdocUpgradeControllor</name>
|
||||||
|
<methods>
|
||||||
|
<method>upgrade</method>
|
||||||
|
<method>download</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/m3/mClientBindController.do</id>
|
||||||
|
<name>com.seeyon.apps.m3.bind.controller.M3ClientBindController</name>
|
||||||
|
<methods>
|
||||||
|
<method>bindApply</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/uploadService.do</id>
|
||||||
|
<name>com.seeyon.ctp.services.FileUploadService</name>
|
||||||
|
<methods>
|
||||||
|
<method>processUploadService</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/uc/rest.do</id>
|
||||||
|
<name>com.seeyon.apps.zx.controller.ZxRestController</name>
|
||||||
|
<methods>
|
||||||
|
<method>commonPierce</method>
|
||||||
|
<method>downloadImage</method>
|
||||||
|
<method>getBgTimeStamp</method>
|
||||||
|
<method>getLoginsecurityMsg</method>
|
||||||
|
<method>sendsms</method>
|
||||||
|
<method>smsrequired</method>
|
||||||
|
<method>testIp</method>
|
||||||
|
<method>isQrLogin</method>
|
||||||
|
<method>getDigitalCodeInfo</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/m3/homeSkinController.do</id>
|
||||||
|
<name>com.seeyon.apps.m3.skin.controller.M3HomeSkinController</name>
|
||||||
|
<methods>
|
||||||
|
<method>downloadImage</method>
|
||||||
|
<method>getSkinImageUrl</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/colView.do</id>
|
||||||
|
<name>com.seeyon.apps.ocip.exchange.collaboration.controller.CollViewController</name>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/autoinstall.do</id>
|
||||||
|
<name>com.seeyon.apps.autoinstall.controller.AutoInstallController</name>
|
||||||
|
<methods>
|
||||||
|
<method>ieSetDown</method>
|
||||||
|
<method>regInstallDown</method>
|
||||||
|
<method>regInstallDown64</method>
|
||||||
|
<method>downloadAssistant</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<!-- <bean> 白名单清理-->
|
||||||
|
<!-- <id>/meetingPanel.do</id>-->
|
||||||
|
<!-- <name>com.seeyon.apps.meeting.controller.MeetingPanelController</name>-->
|
||||||
|
<!-- <methods>-->
|
||||||
|
<!-- <method>meetingPanelDisplay</method>-->
|
||||||
|
<!-- <method>meetingPanelView</method>-->
|
||||||
|
<!-- </methods>-->
|
||||||
|
<!-- </bean>-->
|
||||||
|
<bean>
|
||||||
|
<id>/caAccountManagerController.do</id>
|
||||||
|
<name>com.seeyon.v3x.ca.caaccount.controller.CAAccountManagerController</name>
|
||||||
|
<methods>
|
||||||
|
<method>findKeyNumByLoginName</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/elearning.do</id>
|
||||||
|
<name>com.seeyon.apps.elearning.controller.ElearningController</name>
|
||||||
|
<methods>
|
||||||
|
<method>error</method>
|
||||||
|
<method>m3Redirect</method>
|
||||||
|
<method>message</method>
|
||||||
|
<method>pcRedirect</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/wechat/miniprogram.do</id>
|
||||||
|
<name>com.seeyon.apps.weixin.controller.MiniProgramController</name>
|
||||||
|
<methods>
|
||||||
|
<method>a8home</method>
|
||||||
|
<method>bind</method>
|
||||||
|
<method>bindMemberPhone</method>
|
||||||
|
<method>login</method>
|
||||||
|
<method>unbind</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/portal/spaceController.do</id>
|
||||||
|
<name>com.seeyon.ctp.portal.space.controller.SpaceController</name>
|
||||||
|
<methods>
|
||||||
|
<method>showThemSpace</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/identification.do</id>
|
||||||
|
<name>com.seeyon.v3x.identification.controller.IdentificationController</name>
|
||||||
|
<methods>
|
||||||
|
<method>getSessionId</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/fddCallbackController.do</id>
|
||||||
|
<name>com.seeyon.apps.econtract.fdd.controller.FddCallbackController</name>
|
||||||
|
<methods>
|
||||||
|
<method>asynch</method>
|
||||||
|
<method>synch</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>m3ProductManager</id>
|
||||||
|
<name>com.seeyon.apps.m3.product.manager.impl.M3ProductManagerImpl</name>
|
||||||
|
<methods>
|
||||||
|
<method>productInfo</method>
|
||||||
|
<method>productStatus</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/ocipEdoc.do</id>
|
||||||
|
<name>com.seeyon.apps.ocip.exchange.edoc.OCIPEdocController</name>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/m3/loginController.do</id>
|
||||||
|
<methods>
|
||||||
|
<method>transLogin</method>
|
||||||
|
<method>transLogout</method>
|
||||||
|
<method>getProfile</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/fileUpload.do</id>
|
||||||
|
<name>com.seeyon.ctp.common.fileupload.FileUploadController</name>
|
||||||
|
<methods>
|
||||||
|
<method>showRTE</method>
|
||||||
|
<method>processUpload</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>qrCodeLoginManager</id>
|
||||||
|
<name>com.seeyon.ctp.login.manager.QrCodeLoginManagerImpl</name>
|
||||||
|
<methods>
|
||||||
|
<method>isLogin</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/form/formUpgrade.do</id>
|
||||||
|
<name>com.seeyon.ctp.form.service.FormUpgradeController</name>
|
||||||
|
<methods>
|
||||||
|
<method>toUpgrade</method>
|
||||||
|
<method>upgrade</method>
|
||||||
|
<method>viewUpgrade</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/seeyonReport/seeyonReportController.do</id>
|
||||||
|
<name>com.seeyon.apps.seeyonreport.controller.SeeyonReportController</name>
|
||||||
|
<methods>
|
||||||
|
<method>redirectSeeyonReport</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>formtalkFormMapperController.do</id>
|
||||||
|
<name>com.seeyon.apps.formtalk.controller.FormtalkImportController</name>
|
||||||
|
<methods>
|
||||||
|
<method>importFormtalkData</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/thirdpartyController.do</id>
|
||||||
|
<name>com.seeyon.ctp.portal.sso.thirdpartyintegration.controller.ThirdpartyController</name>
|
||||||
|
<methods>
|
||||||
|
<method>access</method>
|
||||||
|
<method>index</method>
|
||||||
|
<method>logoutNotify</method>
|
||||||
|
<method>show</method>
|
||||||
|
<method>mailAuth</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/m3/transModeController.do</id>
|
||||||
|
<name>com.seeyon.apps.m3.transmissionmode.controller.M3TransModeController</name>
|
||||||
|
<methods>
|
||||||
|
<method>getTransModeForMobile</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/genericController.do</id>
|
||||||
|
<name>com.seeyon.v3x.common.controller.GenericController</name>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/personalBind.do</id>
|
||||||
|
<name>com.seeyon.v3x.personalaffair.controller.PersonalBindController</name>
|
||||||
|
<methods>
|
||||||
|
<method>getBindTypeByLoginName</method>
|
||||||
|
<method>isCanUse</method>
|
||||||
|
<method>retrievePassword</method>
|
||||||
|
<method>sendVerificationCodeToBindEmail</method>
|
||||||
|
<method>sendVerificationCodeToBindNum</method>
|
||||||
|
<method>validateVerificationCode</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/commonimage.do</id>
|
||||||
|
<name>com.seeyon.apps.common.image.controller.ImageController</name>
|
||||||
|
<methods>
|
||||||
|
<method>showImage</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/individualManager.do</id>
|
||||||
|
<name>com.seeyon.v3x.personalaffair.controller.IndividualManagerController</name>
|
||||||
|
<methods>
|
||||||
|
<method>resetPassword</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>meetingAjaxManager</id>
|
||||||
|
<name>com.seeyon.apps.meeting.manager.MeetingAjaxManagerImpl</name>
|
||||||
|
<methods>
|
||||||
|
<method>meetingPanelData</method>
|
||||||
|
<method>meetingPanelDisplay</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/wechat/dingding.do</id>
|
||||||
|
<name>com.seeyon.apps.weixin.controller.DingDingController</name>
|
||||||
|
<methods>
|
||||||
|
<method>binding</method>
|
||||||
|
<method>index</method>
|
||||||
|
<method>main</method>
|
||||||
|
<method>newIndex</method>
|
||||||
|
<method>newMain</method>
|
||||||
|
<method>viewh5Message</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/imc.do</id>
|
||||||
|
<name>com.seeyon.apps.imc.controller.ImcLoginController</name>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
<method>logout</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/wechat/feishu.do</id>
|
||||||
|
<name>com.seeyon.apps.weixin.controller.FeishuController</name>
|
||||||
|
<methods>
|
||||||
|
<method>newMain</method>
|
||||||
|
<method>viewh5Message</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<!-- <bean>-->
|
||||||
|
<!-- <id>/wechat/pcapp.do</id>-->
|
||||||
|
<!-- <name>com.seeyon.apps.zhifei.controller.ZhifeiPcAppController</name>-->
|
||||||
|
<!-- <methods>-->
|
||||||
|
<!-- <method>transferPageFromWxCoreServer</method>-->
|
||||||
|
<!-- <method>gotoPcApp</method>-->
|
||||||
|
<!-- <method>checkCodeTurnToRightPage</method>-->
|
||||||
|
<!-- <method>transfer</method>-->
|
||||||
|
<!-- <method>transferMsg</method>-->
|
||||||
|
<!-- </methods>-->
|
||||||
|
<!-- </bean>-->
|
||||||
|
<bean>
|
||||||
|
<id>/wechat/pcapp.do</id>
|
||||||
|
<name>com.seeyon.apps.weixin.controller.PcAppController</name>
|
||||||
|
<methods>
|
||||||
|
<method>transferPageFromWxCoreServer</method>
|
||||||
|
<method>gotoPcApp</method>
|
||||||
|
<method>checkCodeTurnToRightPage</method>
|
||||||
|
<method>transfer</method>
|
||||||
|
<method>transferMsg</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/wechat/feishu/approvalData.do</id>
|
||||||
|
<name>com.seeyon.apps.zhifei.feishu.approval.controller.ApprovalDataController</name>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/zhifei/feishu.do</id>
|
||||||
|
<name>com.seeyon.apps.zhifei.controller.FeishuController</name>
|
||||||
|
<methods>
|
||||||
|
<method>newMain</method>
|
||||||
|
<method>viewh5Message</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/zhifei/pcapp.do</id>
|
||||||
|
<name>com.seeyon.apps.zhifei.controller.ZhifeiPcAppController</name>
|
||||||
|
<methods>
|
||||||
|
<method>transferPageFromWxCoreServer</method>
|
||||||
|
<method>gotoPcApp</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/zhifei/feishu/approvalData.do</id>
|
||||||
|
<name>com.seeyon.apps.zhifei.feishu.approval.controller.ApprovalDataController</name>
|
||||||
|
<methods>
|
||||||
|
<method>index</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
<bean>
|
||||||
|
<id>/cloudbuild.do</id>
|
||||||
|
<name>com.seeyon.apps.cloudbuild.controller.CloudBuildController</name>
|
||||||
|
<methods>
|
||||||
|
<method>download</method>
|
||||||
|
<method>getDownloadPageInfo</method>
|
||||||
|
<method>getLatestVersionInfo</method>
|
||||||
|
<method>getDownloadQrUrl</method>
|
||||||
|
</methods>
|
||||||
|
</bean>
|
||||||
|
</beans>
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<plugin>
|
||||||
|
<id>src_leasebill</id>
|
||||||
|
<name>租赁账单生成</name>
|
||||||
|
<category>20250905</category>
|
||||||
|
</plugin>
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
xmlns:aop="http://www.springframework.org/schema/aop"
|
||||||
|
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop.xsd" default-autowire="byName">
|
||||||
|
<bean name="/leaseBillController.do" class="com.seeyon.apps.src_leasebill.controller.LeaseBillController" />
|
||||||
|
|
||||||
|
|
||||||
|
</beans>
|
||||||
|
|
||||||
@@ -0,0 +1,5 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
|
||||||
|
<beans default-autowire="byName">
|
||||||
|
<bean id="leaseBillDao" class="com.seeyon.apps.src_leasebill.dao.impl.LeaseBillDaoImpl" />
|
||||||
|
</beans>
|
||||||
@@ -0,0 +1,5 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
|
||||||
|
<beans default-autowire="byName">
|
||||||
|
<bean id="leaseBillFieldCtrl" class="com.seeyon.apps.src_leasebill.fieldCtrl.LeaseBillFieldCtrl" />
|
||||||
|
</beans>
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
xmlns:aop="http://www.springframework.org/schema/aop"
|
||||||
|
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop.xsd" default-autowire="byName">
|
||||||
|
<bean id="LeaseBillPluginApi" class="com.seeyon.apps.src_leasebill.LeaseBillPluginApi" />
|
||||||
|
|
||||||
|
</beans>
|
||||||
|
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
.customButton_class_box {
|
||||||
|
width: 100%;
|
||||||
|
line-height: 24px;
|
||||||
|
height:24px;
|
||||||
|
color: #1f85ec;
|
||||||
|
cursor: pointer;
|
||||||
|
font-family: "Microsoft YaHei"!important;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
|
word-break:keep-all;
|
||||||
|
}
|
||||||
|
.customButton_box_content{
|
||||||
|
width: 100%;
|
||||||
|
height: 24px;
|
||||||
|
box-sizing: border-box;
|
||||||
|
-webkit-box-sizing : border-box;
|
||||||
|
-moz-box-sizing : border-box;
|
||||||
|
text-align: center;
|
||||||
|
outline: none;
|
||||||
|
border: 1px solid #1f85ec;
|
||||||
|
background-color: #fff;
|
||||||
|
border-radius: 15px;
|
||||||
|
-webkit-border-radius: 15px;
|
||||||
|
-moz-border-radius: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
Binary file not shown.
|
After Width: | Height: | Size: 101 KiB |
@@ -0,0 +1,13 @@
|
|||||||
|
.relation_container .panel_bottom .zidong_guanlian .guanlian_map{
|
||||||
|
padding-left: 10px;
|
||||||
|
}
|
||||||
|
.relation_container .panel_bottom .zidong_guanlian .guanlian_map .error-title{
|
||||||
|
margin: 0 2px;
|
||||||
|
visibility: hidden;
|
||||||
|
}
|
||||||
|
.relation_container .panel_bottom .zidong_guanlian .guanlian_map .error-title.active{
|
||||||
|
visibility: visible;
|
||||||
|
}
|
||||||
|
.relation_container .biz_groupguanlian .div_sel3.active{
|
||||||
|
border-color: red;
|
||||||
|
}
|
||||||
@@ -0,0 +1,87 @@
|
|||||||
|
body{
|
||||||
|
font-family: "microsoft yahei";
|
||||||
|
}
|
||||||
|
#tab {
|
||||||
|
height: 26px;
|
||||||
|
width: 100%;
|
||||||
|
border-bottom: 1px solid #666666;
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
#tab span {
|
||||||
|
height: 30px;
|
||||||
|
line-height: 30px;
|
||||||
|
width: 50%;
|
||||||
|
font-size: 14px;
|
||||||
|
text-align: center;
|
||||||
|
color: #666666;
|
||||||
|
margin-right: 20px;
|
||||||
|
padding: 0 5px 0 5px;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
#tab span.select {
|
||||||
|
border-bottom: 2px solid #2453b3;
|
||||||
|
color: #2453b3;
|
||||||
|
}
|
||||||
|
|
||||||
|
.list{
|
||||||
|
list-style: none;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
font-size: 14px;
|
||||||
|
height: 310px;
|
||||||
|
overflow: auto;
|
||||||
|
}
|
||||||
|
.list .active{
|
||||||
|
background-color: #1F85EC;
|
||||||
|
border: 1px solid #1F85EC;
|
||||||
|
color: #ffffff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.list li{
|
||||||
|
cursor: pointer;
|
||||||
|
margin: 3px 0 3px 0;
|
||||||
|
}
|
||||||
|
.list span{
|
||||||
|
display: inline-block;
|
||||||
|
background: url("img/icon16.png") -32px -240px no-repeat scroll transparent;
|
||||||
|
margin-right: 2px;
|
||||||
|
vertical-align: middle;
|
||||||
|
width: 16px;
|
||||||
|
height: 16px;
|
||||||
|
}
|
||||||
|
.search-box {
|
||||||
|
height: 20px;
|
||||||
|
margin: 10px 0 10px 0;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
.cap-icon-sousuo {
|
||||||
|
position: absolute;
|
||||||
|
top: 2px;
|
||||||
|
left: 170px;
|
||||||
|
color: #1F85EC;
|
||||||
|
font-size: 20px;
|
||||||
|
line-height: 20px;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
.cap-icon-sousuo:before {
|
||||||
|
content: "";
|
||||||
|
background: url("img/icon16.png") -192px -176px no-repeat;
|
||||||
|
height: 16px;
|
||||||
|
line-height: 16px;
|
||||||
|
width: 16px;
|
||||||
|
font-size: 12px;
|
||||||
|
display: block;
|
||||||
|
position: absolute;
|
||||||
|
top: 5px;
|
||||||
|
margin-left: 2px;
|
||||||
|
}
|
||||||
|
.search-input {
|
||||||
|
background: #FFFFFF;
|
||||||
|
border: 1px solid #D4D4D4;
|
||||||
|
border-radius: 100px;
|
||||||
|
min-height: 20px;
|
||||||
|
width: 150px;
|
||||||
|
padding-right: 35px;
|
||||||
|
padding-left: 10px;
|
||||||
|
outline: none;
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<link rel="stylesheet" href="../css/setTemplate.css"/>
|
||||||
|
<script src="/seeyon/m3/apps/v5/commons/jquery/jquery-2.1.4.min.js"></script>
|
||||||
|
<script src="../js/setTemplate.js"></script>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div id="tab">
|
||||||
|
<span id="tab_queryList" class="select">选择底表</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="queryList">
|
||||||
|
<div class="search-box">
|
||||||
|
<i class="cap-icon-sousuo" onclick="search()"></i>
|
||||||
|
<input type="text" class="search-input" id="search_query">
|
||||||
|
</div>
|
||||||
|
<ul class="list"></ul>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
|
<script type="text/javascript">
|
||||||
|
|
||||||
|
//----------------------------------
|
||||||
|
</script>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,188 @@
|
|||||||
|
//==本JS是加载Lodop插件或Web打印服务CLodop/Lodop7的综合示例,可直接使用,建议理解后融入自己程序==
|
||||||
|
|
||||||
|
//用双端口加载主JS文件Lodop.js(或CLodopfuncs.js兼容老版本)以防其中某端口被占:
|
||||||
|
var MainJS ="CLodopfuncs.js",
|
||||||
|
URL_WS1 = "ws://localhost:8000/"+MainJS, //ws用8000/18000
|
||||||
|
URL_WS2 = "ws://localhost:18000/"+MainJS,
|
||||||
|
URL_HTTP1 = "http://localhost:8000/"+MainJS, //http用8000/18000
|
||||||
|
URL_HTTP2 = "http://localhost:18000/"+MainJS,
|
||||||
|
URL_HTTP3 = "https://localhost.lodop.net:8443/"+MainJS; //https用8000/8443
|
||||||
|
|
||||||
|
var CreatedOKLodopObject, CLodopIsLocal, LoadJsState;
|
||||||
|
|
||||||
|
//==判断是否需要CLodop(那些不支持插件的浏览器):==
|
||||||
|
function needCLodop() {
|
||||||
|
try {
|
||||||
|
var ua = navigator.userAgent;
|
||||||
|
if (ua.match(/Windows\sPhone/i) ||
|
||||||
|
ua.match(/iPhone|iPod|iPad/i) ||
|
||||||
|
ua.match(/Android/i) ||
|
||||||
|
ua.match(/Edge\D?\d+/i))
|
||||||
|
return true;
|
||||||
|
var verTrident = ua.match(/Trident\D?\d+/i);
|
||||||
|
var verIE = ua.match(/MSIE\D?\d+/i);
|
||||||
|
var verOPR = ua.match(/OPR\D?\d+/i);
|
||||||
|
var verFF = ua.match(/Firefox\D?\d+/i);
|
||||||
|
var x64 = ua.match(/x64/i);
|
||||||
|
if ((!verTrident) && (!verIE) && (x64)) return true;
|
||||||
|
else if (verFF) {
|
||||||
|
verFF = verFF[0].match(/\d+/);
|
||||||
|
if ((verFF[0] >= 41) || (x64)) return true;
|
||||||
|
} else if (verOPR) {
|
||||||
|
verOPR = verOPR[0].match(/\d+/);
|
||||||
|
if (verOPR[0] >= 32) return true;
|
||||||
|
} else if ((!verTrident) && (!verIE)) {
|
||||||
|
var verChrome = ua.match(/Chrome\D?\d+/i);
|
||||||
|
if (verChrome) {
|
||||||
|
verChrome = verChrome[0].match(/\d+/);
|
||||||
|
if (verChrome[0] >= 41) return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
} catch (err) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//==检查加载成功与否,如没成功则用http(s)再试==
|
||||||
|
//==低版本CLODOP6.561/Lodop7.043及前)用本方法==
|
||||||
|
function checkOrTryHttp() {
|
||||||
|
if (window.getCLodop) {
|
||||||
|
LoadJsState = "complete";
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (LoadJsState == "loadingB" || LoadJsState == "complete") return;
|
||||||
|
LoadJsState = "loadingB";
|
||||||
|
var head = document.head || document.getElementsByTagName("head")[0] || document.documentElement;
|
||||||
|
var JS1 = document.createElement("script")
|
||||||
|
,JS2 = document.createElement("script")
|
||||||
|
,JS3 = document.createElement("script");
|
||||||
|
JS1.src = URL_HTTP1;
|
||||||
|
JS2.src = URL_HTTP2;
|
||||||
|
JS3.src = URL_HTTP3;
|
||||||
|
JS1.onload = JS2.onload = JS3.onload = JS2.onerror = JS3.onerror=function(){LoadJsState = "complete";}
|
||||||
|
JS1.onerror = function(e) {
|
||||||
|
if (window.location.protocol !== 'https:')
|
||||||
|
head.insertBefore(JS2, head.firstChild); else
|
||||||
|
head.insertBefore(JS3, head.firstChild);
|
||||||
|
}
|
||||||
|
head.insertBefore(JS1,head.firstChild);
|
||||||
|
}
|
||||||
|
|
||||||
|
//==加载Lodop对象的主过程:==
|
||||||
|
(function loadCLodop(){
|
||||||
|
if (!needCLodop()) return;
|
||||||
|
CLodopIsLocal = !!((URL_WS1 + URL_WS2).match(/\/\/localho|\/\/127.0.0./i));
|
||||||
|
LoadJsState = "loadingA";
|
||||||
|
if (!window.WebSocket && window.MozWebSocket) window.WebSocket=window.MozWebSocket;
|
||||||
|
//ws方式速度快(小于200ms)且可避免CORS错误,但要求Lodop版本足够新:
|
||||||
|
try {
|
||||||
|
var WSK1=new WebSocket(URL_WS1);
|
||||||
|
WSK1.onopen = function(e) { setTimeout("checkOrTryHttp();",200); }
|
||||||
|
WSK1.onmessage = function(e) {if (!window.getCLodop) eval(e.data);}
|
||||||
|
WSK1.onerror = function(e) {
|
||||||
|
var WSK2=new WebSocket(URL_WS2);
|
||||||
|
WSK2.onopen = function(e) {setTimeout("checkOrTryHttp();",200);}
|
||||||
|
WSK2.onmessage = function(e) {if (!window.getCLodop) eval(e.data);}
|
||||||
|
WSK2.onerror= function(e) {checkOrTryHttp();}
|
||||||
|
}
|
||||||
|
} catch(e){
|
||||||
|
checkOrTryHttp();
|
||||||
|
}
|
||||||
|
})();
|
||||||
|
|
||||||
|
//==获取LODOP对象主过程,判断是否安装、需否升级:==
|
||||||
|
function getLodop(oOBJECT, oEMBED) {
|
||||||
|
var strFontTag = "<br><font color='#FF00FF'>打印控件";
|
||||||
|
var strLodopInstall = strFontTag + "未安装!点击这里<a href='install_lodop32.exe' target='_self'>执行安装</a>";
|
||||||
|
var strLodopUpdate = strFontTag + "需要升级!点击这里<a href='install_lodop32.exe' target='_self'>执行升级</a>";
|
||||||
|
var strLodop64Install = strFontTag + "未安装!点击这里<a href='install_lodop64.exe' target='_self'>执行安装</a>";
|
||||||
|
var strLodop64Update = strFontTag + "需要升级!点击这里<a href='install_lodop64.exe' target='_self'>执行升级</a>";
|
||||||
|
var strCLodopInstallA = "<br><font color='#FF00FF'>Web打印服务CLodop未安装启动,点击这里<a href='CLodop_Setup_for_Win32NT.exe' target='_self'>下载执行安装</a>";
|
||||||
|
var strCLodopInstallB = "<br>(若此前已安装过,可<a href='CLodop.protocol:setup' target='_self'>点这里直接再次启动</a>)";
|
||||||
|
var strCLodopUpdate = "<br><font color='#FF00FF'>Web打印服务CLodop需升级!点击这里<a href='CLodop_Setup_for_Win32NT.exe' target='_self'>执行升级</a>";
|
||||||
|
var strLodop7FontTag = "<br><font color='#FF00FF'>Web打印服务Lodop7";
|
||||||
|
var strLodop7HrefX86 = "点击这里<a href='Lodop7_Linux_X86_64.tar.gz' target='_self'>下载安装</a>(下载后解压,点击lodop文件开始执行)";
|
||||||
|
var strLodop7HrefARM = "点击这里<a href='Lodop7_Linux_ARM64.tar.gz' target='_self'>下载安装</a>(下载后解压,点击lodop文件开始执行)";
|
||||||
|
var strLodop7Install_X86 = strLodop7FontTag + "未安装启动," + strLodop7HrefX86;
|
||||||
|
var strLodop7Install_ARM = strLodop7FontTag + "未安装启动," + strLodop7HrefARM;
|
||||||
|
var strLodop7Update_X86 = strLodop7FontTag + "需升级," + strLodop7HrefX86;
|
||||||
|
var strLodop7Update_ARM = strLodop7FontTag + "需升级," + strLodop7HrefARM;
|
||||||
|
var strInstallOK = ",成功后请刷新本页面或重启浏览器。</font>";
|
||||||
|
var LODOP;
|
||||||
|
try {
|
||||||
|
var isWinIE = (/MSIE/i.test(navigator.userAgent)) || (/Trident/i.test(navigator.userAgent));
|
||||||
|
var isWinIE64 = isWinIE && (/x64/i.test(navigator.userAgent));
|
||||||
|
var isLinuxX86 = (/Linux/i.test(navigator.platform)) && (/x86/i.test(navigator.platform));
|
||||||
|
var isLinuxARM = (/Linux/i.test(navigator.platform)) && (/aarch/i.test(navigator.platform));
|
||||||
|
|
||||||
|
if (needCLodop() || isLinuxX86 || isLinuxARM) {
|
||||||
|
try {
|
||||||
|
LODOP = window.getCLodop();
|
||||||
|
} catch (err) {}
|
||||||
|
if (!LODOP && LoadJsState !== "complete") {
|
||||||
|
if (!LoadJsState)
|
||||||
|
alert("未曾加载Lodop主JS文件,请先调用loadCLodop过程."); else
|
||||||
|
alert("网页还没下载完毕,请稍等一下再操作.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
var strAlertMessage;
|
||||||
|
if (!LODOP) {
|
||||||
|
if (isLinuxX86)
|
||||||
|
strAlertMessage = strLodop7Install_X86;
|
||||||
|
else if (isLinuxARM)
|
||||||
|
strAlertMessage = strLodop7Install_ARM;
|
||||||
|
else
|
||||||
|
strAlertMessage = strCLodopInstallA + (CLodopIsLocal ? strCLodopInstallB : "");
|
||||||
|
document.body.innerHTML = strAlertMessage + strInstallOK + document.body.innerHTML;
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
if (isLinuxX86 && LODOP.CVERSION < "7.0.4.3")
|
||||||
|
strAlertMessage = strLodop7Update_X86;
|
||||||
|
else if (isLinuxARM && LODOP.CVERSION < "7.0.4.3")
|
||||||
|
strAlertMessage = strLodop7Update_ARM;
|
||||||
|
else if (CLODOP.CVERSION < "6.5.7.1")
|
||||||
|
strAlertMessage = strCLodopUpdate;
|
||||||
|
|
||||||
|
if (strAlertMessage)
|
||||||
|
document.body.innerHTML = strAlertMessage + strInstallOK + document.body.innerHTML;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
//==如果页面有Lodop插件就直接使用,否则新建:==
|
||||||
|
if (oOBJECT || oEMBED) {
|
||||||
|
if (isWinIE)
|
||||||
|
LODOP = oOBJECT;
|
||||||
|
else
|
||||||
|
LODOP = oEMBED;
|
||||||
|
} else if (!CreatedOKLodopObject) {
|
||||||
|
LODOP = document.createElement("object");
|
||||||
|
LODOP.setAttribute("width", 0);
|
||||||
|
LODOP.setAttribute("height", 0);
|
||||||
|
LODOP.setAttribute("style", "position:absolute;left:0px;top:-100px;width:0px;height:0px;");
|
||||||
|
if (isWinIE)
|
||||||
|
LODOP.setAttribute("classid", "clsid:2105C259-1E0C-4534-8141-A753534CB4CA");
|
||||||
|
else
|
||||||
|
LODOP.setAttribute("type", "application/x-print-lodop");
|
||||||
|
document.documentElement.appendChild(LODOP);
|
||||||
|
CreatedOKLodopObject = LODOP;
|
||||||
|
} else
|
||||||
|
LODOP = CreatedOKLodopObject;
|
||||||
|
//==Lodop插件未安装时提示下载地址:==
|
||||||
|
if ((!LODOP) || (!LODOP.VERSION)) {
|
||||||
|
document.body.innerHTML = (isWinIE64 ? strLodop64Install : strLodopInstall) + strInstallOK + document.body.innerHTML;
|
||||||
|
return LODOP;
|
||||||
|
}
|
||||||
|
if (LODOP.VERSION < "6.2.2.6") {
|
||||||
|
document.body.innerHTML = (isWinIE64 ? strLodop64Update : strLodopUpdate) + strInstallOK + document.body.innerHTML;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//===如下空白位置适合调用统一功能(如注册语句、语言选择等):=======================
|
||||||
|
|
||||||
|
|
||||||
|
//===============================================================================
|
||||||
|
return LODOP;
|
||||||
|
} catch (err) {
|
||||||
|
alert("getLodop出错:" + err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@@ -0,0 +1,206 @@
|
|||||||
|
(function(f){
|
||||||
|
var nameSpace = 'field_5209586381190735608';
|
||||||
|
if(!window[nameSpace]){
|
||||||
|
var Builder = f();
|
||||||
|
window[nameSpace] = {
|
||||||
|
instance: {}
|
||||||
|
};
|
||||||
|
window[nameSpace].init = function (options) {
|
||||||
|
window[nameSpace].instance[options.privateId] = new Builder(options);
|
||||||
|
};
|
||||||
|
}
|
||||||
|
})(function(){
|
||||||
|
/**
|
||||||
|
* 构造函数
|
||||||
|
* @param options
|
||||||
|
* @constructor
|
||||||
|
*/
|
||||||
|
function App(options) {
|
||||||
|
var self = this;
|
||||||
|
//初始化参数
|
||||||
|
self.initParams(options);
|
||||||
|
//初始化dom
|
||||||
|
self.initDom();
|
||||||
|
//事件
|
||||||
|
self.events();
|
||||||
|
}
|
||||||
|
|
||||||
|
App.prototype = {
|
||||||
|
initParams : function (options) {
|
||||||
|
var self = this;
|
||||||
|
self.adaptation = options.adaptation;
|
||||||
|
self.adaptation.formMessage = options.formMessage;
|
||||||
|
self.privateId = options.privateId;
|
||||||
|
self.messageObj = options.getData;
|
||||||
|
self.preUrl = options.url_prefix;
|
||||||
|
},
|
||||||
|
initDom : function () {
|
||||||
|
var self = this;
|
||||||
|
dynamicLoading.css(self.preUrl + 'css/formQueryBtn.css');
|
||||||
|
self.appendChildDom();
|
||||||
|
},
|
||||||
|
events : function () {
|
||||||
|
var self = this;
|
||||||
|
// 监听是否数据刷新
|
||||||
|
|
||||||
|
$(".field0215__").css("background-color","#008BFF");
|
||||||
|
$(".field0215__").css("color","#FFFFFF");
|
||||||
|
$(".field0215__").css("border-radius","10px");
|
||||||
|
$(".field0215__").mouseover(function (e) {
|
||||||
|
var $this = $(this);// 当前触发事件的标签对象
|
||||||
|
}).mouseout(function (e) {
|
||||||
|
$(".field0215__").css("background-color","#008BFF");
|
||||||
|
}).mousemove(function (e) {
|
||||||
|
$(".field0215__").css("background-color","#005297");
|
||||||
|
});
|
||||||
|
|
||||||
|
},
|
||||||
|
appendChildDom : function () {
|
||||||
|
var self = this;
|
||||||
|
var domStructure = '<section class="customButton_box_content">'+
|
||||||
|
'<div class="customButton_class_box '+ self.privateId + '" title="' + self.messageObj.display.escapeHTML() + '">'+ self.messageObj.display.escapeHTML() +'</div>'+
|
||||||
|
'</section>';
|
||||||
|
document.querySelector('#' + self.privateId).innerHTML = domStructure;
|
||||||
|
var jumpFun = function() {
|
||||||
|
var url2 = window.location.origin;
|
||||||
|
var s = self;
|
||||||
|
// var recordId = self.messageObj.formdata.formsons.front_formson_7.records[0].recordId;
|
||||||
|
// 计费方式
|
||||||
|
var jifeifsfield = {fieldId: 'field0032'};
|
||||||
|
var jifeifs = csdk.core.getFieldData(jifeifsfield).showValue;
|
||||||
|
// 缴费方式
|
||||||
|
var jiaofeifsfield = {fieldId: 'field0033'};
|
||||||
|
var jiaofeifs = csdk.core.getFieldData(jiaofeifsfield).showValue;
|
||||||
|
// 年缴费方式类型
|
||||||
|
var njiaofeifsfield = {fieldId: 'field0034'};
|
||||||
|
var njiaofeifs = csdk.core.getFieldData(njiaofeifsfield).showValue;
|
||||||
|
// 面积单价
|
||||||
|
var mjzjfield = {fieldId: 'field0035'};
|
||||||
|
var mjzj = csdk.core.getFieldData(mjzjfield).value;
|
||||||
|
// 固定租金单价
|
||||||
|
var gdzjfield = {fieldId: 'field0038'};
|
||||||
|
var gdzj = csdk.core.getFieldData(gdzjfield).value;
|
||||||
|
// 合同开始日期
|
||||||
|
var startDatefield = {fieldId: 'field0041'};
|
||||||
|
var startDate = csdk.core.getFieldData(startDatefield).value;
|
||||||
|
// 合同结束日期
|
||||||
|
var endDatefield = {fieldId: 'field0042'};
|
||||||
|
var endDate = csdk.core.getFieldData(endDatefield).value;
|
||||||
|
// 租赁面积
|
||||||
|
var mjfield = {fieldId: 'field0081'};
|
||||||
|
var mj = csdk.core.getFieldData(mjfield).value;
|
||||||
|
// 账单编号
|
||||||
|
// var field0083 = {fieldId: 'field0083'};
|
||||||
|
// var field0083value = csdk.core.getFieldData(field0083).value;
|
||||||
|
var bdidfield = {fieldId: 'field0101'};
|
||||||
|
var bdid = csdk.core.getFieldData(bdidfield).value;
|
||||||
|
|
||||||
|
// 判断合同开始日期是否在合同结束日期之前
|
||||||
|
if(!isEmpty(startDate)|| !isEmpty(endDate)){
|
||||||
|
if(Date.parse(startDate)>Date.parse(endDate)){
|
||||||
|
$.alert("请正确填写合同日期");
|
||||||
|
return ;
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
$.alert("请填写合同日期");
|
||||||
|
return ;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 当缴费方式为年缴费时年缴费类型必填
|
||||||
|
if(jiaofeifs=='年'){
|
||||||
|
if(isEmpty(njiaofeifs)){
|
||||||
|
$.alert("请选择年缴费方式选项");
|
||||||
|
return ;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
console.log(url2);
|
||||||
|
var str = "";
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
type : 'post',
|
||||||
|
async : true,
|
||||||
|
// 记得加随机数,不然如果ajax轮询请求会不执行
|
||||||
|
url : encodeURI('/seeyon/leaseBillController.do?datetime=' + Math.random()),
|
||||||
|
data:{
|
||||||
|
"jifeifs":jifeifs,
|
||||||
|
"jiaofeifs":jiaofeifs,
|
||||||
|
"njiaofeifs":njiaofeifs,
|
||||||
|
"startDate":startDate,
|
||||||
|
"endDate":endDate,
|
||||||
|
"mj":mj,
|
||||||
|
"mjzj":mjzj,
|
||||||
|
"gdzj":gdzj,
|
||||||
|
"bdid":bdid
|
||||||
|
},
|
||||||
|
dataType : 'json',
|
||||||
|
contentType : 'application/json; charset=UTF-8',
|
||||||
|
success : function(res) {
|
||||||
|
var randomNum = Math.floor(Math.random() * 10001);
|
||||||
|
if(res.success){
|
||||||
|
// $.alert("账单明细生成完成");
|
||||||
|
if(bdid=="" ){
|
||||||
|
var data = {
|
||||||
|
fieldId: 'field0101',
|
||||||
|
fieldData: {
|
||||||
|
value: res.num+'', //数据值,存入数据库中的value值
|
||||||
|
display: res.num+'', //字段渲染在页面上的显示值,通常是经过format后的值
|
||||||
|
auth: ''
|
||||||
|
}
|
||||||
|
};
|
||||||
|
csdk.core.setFieldData(data);
|
||||||
|
}
|
||||||
|
// self.adaptation.formdata.field0095.formmains.formmain_0228.field0064.value = randomNum;
|
||||||
|
self.adaptation.formdata.field0100__.formmains.formmain_0033.field0102.value = randomNum;
|
||||||
|
}else{
|
||||||
|
$.alert(res.s);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
var content = self.messageObj.formdata.content;
|
||||||
|
|
||||||
|
};
|
||||||
|
document.querySelector('.' + self.privateId).removeEventListener('click', jumpFun);
|
||||||
|
document.querySelector('.' + self.privateId).addEventListener('click', jumpFun);
|
||||||
|
//渲染隐藏权限
|
||||||
|
if (self.messageObj.auth === 'hide') {
|
||||||
|
document.querySelector('#' + self.privateId).innerHTML = '<div class="cap4-text__browse" style="line-height: 1.8; color: rgb(0, 0, 0) !important;">***</div>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
function test() {
|
||||||
|
console.log("明细行生成成功");;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function isEmpty(text) {
|
||||||
|
return !text || text.trim() === '';
|
||||||
|
}
|
||||||
|
|
||||||
|
var dynamicLoading = {
|
||||||
|
css: function(path) {
|
||||||
|
if(!path || path.length === 0) {
|
||||||
|
throw new Error('argument "path" is required !');
|
||||||
|
}
|
||||||
|
var head = document.getElementsByTagName('head')[0];
|
||||||
|
var link = document.createElement('link');
|
||||||
|
link.href = path;
|
||||||
|
link.rel = 'stylesheet';
|
||||||
|
link.type = 'text/css';
|
||||||
|
head.appendChild(link);
|
||||||
|
},
|
||||||
|
js: function(path) {
|
||||||
|
if(!path || path.length === 0) {
|
||||||
|
throw new Error('argument "path" is required !');
|
||||||
|
}
|
||||||
|
var head = document.getElementsByTagName('head')[0];
|
||||||
|
var script = document.createElement('script');
|
||||||
|
script.src = path;
|
||||||
|
script.type = 'text/javascript';
|
||||||
|
head.appendChild(script);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return App;
|
||||||
|
});
|
||||||
@@ -0,0 +1,134 @@
|
|||||||
|
(function(f){
|
||||||
|
var nameSpace = 'field_6664988151731237757';
|
||||||
|
if(!window[nameSpace]){
|
||||||
|
var Builder = f();
|
||||||
|
window[nameSpace] = {
|
||||||
|
instance: {}
|
||||||
|
};
|
||||||
|
window[nameSpace].init = function (options) {
|
||||||
|
window[nameSpace].instance[options.privateId] = new Builder(options);
|
||||||
|
};
|
||||||
|
}
|
||||||
|
})(function(){
|
||||||
|
/**
|
||||||
|
* 构造函数
|
||||||
|
* @param options
|
||||||
|
* @constructor
|
||||||
|
*/
|
||||||
|
function App(options) {
|
||||||
|
var self = this;
|
||||||
|
//初始化参数
|
||||||
|
self.initParams(options);
|
||||||
|
//初始化dom
|
||||||
|
self.initDom();
|
||||||
|
//事件
|
||||||
|
self.events();
|
||||||
|
}
|
||||||
|
|
||||||
|
App.prototype = {
|
||||||
|
initParams : function (options) {
|
||||||
|
var self = this;
|
||||||
|
self.adaptation = options.adaptation;
|
||||||
|
self.adaptation.formMessage = options.formMessage;
|
||||||
|
self.privateId = options.privateId;
|
||||||
|
self.messageObj = options.getData;
|
||||||
|
self.preUrl = options.url_prefix;
|
||||||
|
},
|
||||||
|
initDom : function () {
|
||||||
|
var self = this;
|
||||||
|
dynamicLoading.css(self.preUrl + 'css/formQueryBtn.css');
|
||||||
|
self.appendChildDom();
|
||||||
|
},
|
||||||
|
events : function () {
|
||||||
|
var self = this;
|
||||||
|
// 监听是否数据刷新
|
||||||
|
|
||||||
|
//$(".field0313__").css("background-color","#008BFF");
|
||||||
|
//$(".field0313__").css("color","#FFFFFF");
|
||||||
|
//$(".field0313__").css("border-radius","10px");
|
||||||
|
//$(".field0313__").mouseover(function (e) {
|
||||||
|
// var $this = $(this);// 当前触发事件的标签对象
|
||||||
|
//}).mouseout(function (e) {
|
||||||
|
// $(".field0313__").css("background-color","#008BFF");
|
||||||
|
//}).mousemove(function (e) {
|
||||||
|
// $(".field0313__").css("background-color","#005297");
|
||||||
|
//});
|
||||||
|
|
||||||
|
},
|
||||||
|
appendChildDom : function () {
|
||||||
|
var self = this;
|
||||||
|
var domStructure = '<section class="customButton_box_content">'+
|
||||||
|
'<div class="customButton_class_box '+ self.privateId + '" title="' + self.messageObj.display.escapeHTML() + '">'+ self.messageObj.display.escapeHTML() +'</div>'+
|
||||||
|
'</section>';
|
||||||
|
document.querySelector('#' + self.privateId).innerHTML = domStructure;
|
||||||
|
var jumpFun = function() {
|
||||||
|
var url2 = window.location.origin;
|
||||||
|
var s = self;
|
||||||
|
|
||||||
|
var field0206 = {fieldId: 'field0206'};
|
||||||
|
var field0206value = csdk.core.getFieldData(field0206).value;
|
||||||
|
var field0068 = {fieldId: 'field0068'};
|
||||||
|
var field0068value = csdk.core.getFieldData(field0068).value;
|
||||||
|
var field0212 = {fieldId: 'field0212'};
|
||||||
|
var field0212value = csdk.core.getFieldData(field0212).value;
|
||||||
|
var field0213 = {fieldId: 'field0213'};
|
||||||
|
var field0213value = csdk.core.getFieldData(field0213).value;
|
||||||
|
var field0214 = {fieldId: 'field0214'};
|
||||||
|
var field0214value = csdk.core.getFieldData(field0214).value;
|
||||||
|
var field0207 = {fieldId: 'field0207'};
|
||||||
|
var field0207value = csdk.core.getFieldData(field0207).showValue;
|
||||||
|
|
||||||
|
var str = "";
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
type : 'post',
|
||||||
|
async : true,
|
||||||
|
// 记得加随机数,不然如果ajax轮询请求会不执行
|
||||||
|
url : encodeURI('/seeyon/interestMeasurementController.do?datetime=' + Math.random()),
|
||||||
|
data:{"startDate":field0206value,"cycle":field0207value,"credit":field0068,"principal":field0212,"money":field0213,"interestRate":field0214,},
|
||||||
|
dataType : 'json',
|
||||||
|
contentType : 'application/json; charset=UTF-8',
|
||||||
|
success : function(res) {
|
||||||
|
alert("123123123");
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
var content = self.messageObj.formdata.content;
|
||||||
|
|
||||||
|
};
|
||||||
|
document.querySelector('.' + self.privateId).removeEventListener('click', jumpFun);
|
||||||
|
document.querySelector('.' + self.privateId).addEventListener('click', jumpFun);
|
||||||
|
//渲染隐藏权限
|
||||||
|
if (self.messageObj.auth === 'hide') {
|
||||||
|
document.querySelector('#' + self.privateId).innerHTML = '<div class="cap4-text__browse" style="line-height: 1.8; color: rgb(0, 0, 0) !important;">***</div>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
var dynamicLoading = {
|
||||||
|
css: function(path) {
|
||||||
|
if(!path || path.length === 0) {
|
||||||
|
throw new Error('argument "path" is required !');
|
||||||
|
}
|
||||||
|
var head = document.getElementsByTagName('head')[0];
|
||||||
|
var link = document.createElement('link');
|
||||||
|
link.href = path;
|
||||||
|
link.rel = 'stylesheet';
|
||||||
|
link.type = 'text/css';
|
||||||
|
head.appendChild(link);
|
||||||
|
},
|
||||||
|
js: function(path) {
|
||||||
|
if(!path || path.length === 0) {
|
||||||
|
throw new Error('argument "path" is required !');
|
||||||
|
}
|
||||||
|
var head = document.getElementsByTagName('head')[0];
|
||||||
|
var script = document.createElement('script');
|
||||||
|
script.src = path;
|
||||||
|
script.type = 'text/javascript';
|
||||||
|
head.appendChild(script);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return App;
|
||||||
|
});
|
||||||
@@ -0,0 +1,99 @@
|
|||||||
|
var unflowList, param, loading, process;
|
||||||
|
$(document).ready(function() {
|
||||||
|
param = initParam().params;// 获取页面参数
|
||||||
|
// 处理进度条
|
||||||
|
process = top.$.progressBar({
|
||||||
|
text : "加载中..."
|
||||||
|
});
|
||||||
|
loading = true;
|
||||||
|
getUnflowList();
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
// 获取底表
|
||||||
|
function getUnflowList() {
|
||||||
|
$.ajax({
|
||||||
|
url : "/seeyon/rest/cap4/unflow/select",
|
||||||
|
async : true,
|
||||||
|
success : function(data) {
|
||||||
|
// 处理进度条
|
||||||
|
if (loading)
|
||||||
|
process.close();
|
||||||
|
loading = false;
|
||||||
|
//data = JSON.parse(data);
|
||||||
|
var result = data.data;
|
||||||
|
unflowList = result;
|
||||||
|
for (var i = 0; i < result.length; i++) {
|
||||||
|
$("#queryList ul").append(
|
||||||
|
$("<li id='"
|
||||||
|
+ result[i].id
|
||||||
|
+ "'><span class='icon'></span>"
|
||||||
|
+ result[i].name
|
||||||
|
+ "</li>").attr("info",
|
||||||
|
JSON.stringify(result[i])));
|
||||||
|
}
|
||||||
|
$("#queryList ul").delegate(
|
||||||
|
"li",
|
||||||
|
"click",
|
||||||
|
function() {
|
||||||
|
$(this).siblings().removeClass('active').end()
|
||||||
|
.addClass('active');
|
||||||
|
});
|
||||||
|
if (param && param.id) { // 激活当前项
|
||||||
|
$('#' + param.id).trigger('click');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// 搜索
|
||||||
|
function search() {
|
||||||
|
var searchValue = $("#search_query").val();
|
||||||
|
$("#queryList ul").empty();
|
||||||
|
for (var i = 0; i < unflowList.length; i++) {
|
||||||
|
if (unflowList[i].name.indexOf(searchValue) != -1) {
|
||||||
|
$("#queryList ul").append(
|
||||||
|
$("<li><span class='icon'></span>"
|
||||||
|
+ unflowList[i].name + "</li>").attr(
|
||||||
|
"info", JSON.stringify(unflowList[i])));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 返回参数获取
|
||||||
|
function getResult() {
|
||||||
|
return JSON.parse($("#queryList ul").find(".active").attr("info")
|
||||||
|
|| "{}");
|
||||||
|
}
|
||||||
|
|
||||||
|
// --------------------以下为固定方法,需要实现返回参数获取--------------
|
||||||
|
|
||||||
|
// 获取弹窗传递过来的参数
|
||||||
|
function initParam() {
|
||||||
|
var obj = window.parentDialogObj && (window.parentDialogObj["ctrlDialog"]);// 获取窗口对象
|
||||||
|
if (obj && obj.getTransParams) {
|
||||||
|
// 然后通过V5方法获取弹窗传递过来的参数
|
||||||
|
return obj.getTransParams();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 确定按钮调用方法,返回需要的json数据
|
||||||
|
function OK() {
|
||||||
|
var result = getResult();
|
||||||
|
|
||||||
|
if (param && param.designId !== result.designId)
|
||||||
|
return {
|
||||||
|
valid : true,
|
||||||
|
data : {
|
||||||
|
customParam : {
|
||||||
|
templateId : result,
|
||||||
|
mapping : null
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
return {
|
||||||
|
valid : true,
|
||||||
|
data : result
|
||||||
|
};
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user