科目分类通用插件优化
This commit is contained in:
parent
f477b3ff90
commit
c6ec93c2bf
|
@ -205,8 +205,10 @@ public class ReimbursementAccountTypePlugin extends AbstractBillPlugIn implement
|
|||
switch (entryRuleRuleType) {
|
||||
case "公司":
|
||||
DynamicObject entryRuleCompanyType = entryRule.getDynamicObject("zcgj_companytype");//公司默认分类(科目分类)
|
||||
if (entryRuleCompanyType != null) {
|
||||
this.getModel().setValue("zcgj_accounttype", entryRuleCompanyType, rowIndex);
|
||||
return;
|
||||
}
|
||||
case "部门属性":
|
||||
DynamicObject dutyRelation = BusinessDataServiceHelper.loadSingle("bos_org_dutyrelation", "orgduty",
|
||||
new QFilter("org.id", QCP.equals, costDept.getLong("id")).toArray());//部门属性管理单
|
||||
|
@ -215,9 +217,11 @@ public class ReimbursementAccountTypePlugin extends AbstractBillPlugIn implement
|
|||
long id = orgDuty.getLong("id");
|
||||
DynamicObject accountType = BusinessDataServiceHelper.loadSingle("zcgj_accounttype", "id",
|
||||
new QFilter("zcgj_orgtype.fbasedataid", QCP.in, id).toArray());//科目分类单
|
||||
if (accountType != null) {
|
||||
this.getModel().setValue("zcgj_accounttype", accountType, rowIndex);
|
||||
return;
|
||||
}
|
||||
}
|
||||
case "职位":
|
||||
QFilter filter4 = new QFilter("zcgj_entryposition.zcgj_cusposition.name", QCP.equals, userMainJob);//职位
|
||||
QFilter filter5 = new QFilter("zcgj_entryposition.zcgj_expenseitem", QCP.equals, expenseItemId);//费用项目
|
||||
|
@ -293,8 +297,10 @@ public class ReimbursementAccountTypePlugin extends AbstractBillPlugIn implement
|
|||
accountType = "zcgj_yanzhou";
|
||||
break;
|
||||
}
|
||||
if (accountType != null){
|
||||
long id = orgTypeDefaultCollection.get(0).getLong("zcgj_entryexpense." + accountType);
|
||||
this.getModel().setValue("zcgj_accounttype", id, rowIndex);//科目属性
|
||||
}
|
||||
} else {
|
||||
//组织分类配置表中未查询到对应数据,说明组织分类中编码有所改变,需维护对应的组织分类配置表
|
||||
this.getModel().setValue("zcgj_accounttype", null, rowIndex);//科目属性
|
||||
|
|
Loading…
Reference in New Issue