(function() {
var appId = $.context.getCurrentApplicationId();
var currentDocument = $.context.getCurrentDocument();
var count1 = currentDocument.getElementByName("挡数").getValue();
var count2 = currentDocument.getElementByName("绩效工资系数").getFloatValue();
var count3 = currentDocument.getElementByName("部门得分系数").getFloatValue();
var formName = "员工基本信息";
//控件值键对
var conditionMap = new Packages.java.util.HashMap();
var aggregates = $.form.getDocumentsByCondition(appId, formName, conditionMap);
for (var i = 0; i < aggregates.size(); i++) {
var aggregate = aggregates.get(i);
var rank = aggregate.getElementByName("职级1").getValue();
var formName1 = "绩效基数管理";
//控件值键对
var conditionMap1 = new Packages.java.util.HashMap();
conditionMap1.put("岗位名称冗余", rank);
conditionMap1.put("挡位", count1);
var aggregate1 = $.form.getDocumentsByCondition(appId, formName1, conditionMap1);
for (var j = 0; j < aggregate1.size(); j++) {
var aggregate1s = aggregate1.get(j);
var merit = aggregate1s.getElementByName("月度绩效").getValue();
aggregate.addElement("绩效工资挡位", aggregate1s.getId());
aggregate.addElement("绩效工资基数", merit);
aggregate.addElement("绩效工资系数", count2);
aggregate.addElement("基本工资系数", count3);
$.form.saveFormDocument(aggregate, appId);
}
}
})()
如果觉得我的文章对您有用,请随意打赏。你的支持将鼓励我继续创作!