This commit is contained in:
xd 2024-08-12 14:29:37 +08:00
parent 79daa7b591
commit 398f6add0b
34 changed files with 1070 additions and 467 deletions

View File

@ -2,7 +2,10 @@
<project version="4">
<component name="ChangeListManager">
<list default="true" id="1ea72584-8a6e-4fb7-9928-17671c0b6e92" name="Default Changelist" comment="">
<change beforePath="$PROJECT_DIR$/ruoyi-admin/target/classes/com/ruoyi/web/controller/quot/QuotController.class" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-admin/target/classes/com/ruoyi/web/controller/quot/QuotController.class" afterDir="false" />
<change afterPath="$PROJECT_DIR$/ruoyi-ui/src/utils/number-cn.js" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ABAP_AS_WITH_POOL.jcoDestination" beforeDir="false" afterPath="$PROJECT_DIR$/ABAP_AS_WITH_POOL.jcoDestination" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-admin/src/main/java/com/ruoyi/web/controller/expenses/ExpensesController.java" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-admin/src/main/java/com/ruoyi/web/controller/expenses/ExpensesController.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-admin/target/classes/com/ruoyi/web/controller/expenses/ExpensesController.class" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-admin/target/classes/com/ruoyi/web/controller/expenses/ExpensesController.class" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-admin/target/maven-archiver/pom.properties" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-admin/target/maven-archiver/pom.properties" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-admin/target/ruoyi-admin.jar" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-admin/target/ruoyi-admin.jar" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-admin/target/ruoyi-admin.jar.original" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-admin/target/ruoyi-admin.jar.original" afterDir="false" />
@ -14,10 +17,24 @@
<change beforePath="$PROJECT_DIR$/ruoyi-generator/target/ruoyi-generator-3.8.7.jar" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-generator/target/ruoyi-generator-3.8.7.jar" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-quartz/target/maven-archiver/pom.properties" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-quartz/target/maven-archiver/pom.properties" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-quartz/target/ruoyi-quartz-3.8.7.jar" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-quartz/target/ruoyi-quartz-3.8.7.jar" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/target/classes/com/ruoyi/quot/service/impl/QuotServiceImpl.class" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/target/classes/com/ruoyi/quot/service/impl/QuotServiceImpl.class" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/src/main/java/com/ruoyi/expenses/domain/Expenses.java" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/src/main/java/com/ruoyi/expenses/domain/Expenses.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/src/main/java/com/ruoyi/expenses/mapper/ExpensesMapper.java" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/src/main/java/com/ruoyi/expenses/mapper/ExpensesMapper.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/src/main/java/com/ruoyi/expenses/service/IExpensesService.java" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/src/main/java/com/ruoyi/expenses/service/IExpensesService.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/src/main/java/com/ruoyi/expenses/service/impl/ExpensesServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/src/main/java/com/ruoyi/expenses/service/impl/ExpensesServiceImpl.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/src/main/resources/mapper/authorize/AuthorizeMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/src/main/resources/mapper/authorize/AuthorizeMapper.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/src/main/resources/mapper/expenses/ExpensesMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/src/main/resources/mapper/expenses/ExpensesMapper.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/target/classes/com/ruoyi/expenses/domain/Expenses.class" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/target/classes/com/ruoyi/expenses/domain/Expenses.class" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/target/classes/com/ruoyi/expenses/mapper/ExpensesMapper.class" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/target/classes/com/ruoyi/expenses/mapper/ExpensesMapper.class" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/target/classes/com/ruoyi/expenses/service/IExpensesService.class" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/target/classes/com/ruoyi/expenses/service/IExpensesService.class" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/target/classes/com/ruoyi/expenses/service/impl/ExpensesServiceImpl.class" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/target/classes/com/ruoyi/expenses/service/impl/ExpensesServiceImpl.class" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/target/classes/mapper/authorize/AuthorizeMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/target/classes/mapper/authorize/AuthorizeMapper.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/target/classes/mapper/expenses/ExpensesMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/target/classes/mapper/expenses/ExpensesMapper.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/target/maven-archiver/pom.properties" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/target/maven-archiver/pom.properties" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-system/target/ruoyi-system-3.8.7.jar" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-system/target/ruoyi-system-3.8.7.jar" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-ui/src/views/bid/bid/index.vue" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-ui/src/views/bid/bid/index.vue" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-ui/src/api/expenses/expenses.js" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-ui/src/api/expenses/expenses.js" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-ui/src/views/authorize/authorize/index.vue" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-ui/src/views/authorize/authorize/index.vue" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-ui/src/views/components/Tools/PeopleSelect/index.vue" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-ui/src/views/components/Tools/PeopleSelect/index.vue" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ruoyi-ui/src/views/expenses/expenses/index.vue" beforeDir="false" afterPath="$PROJECT_DIR$/ruoyi-ui/src/views/expenses/expenses/index.vue" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
@ -114,7 +131,8 @@
<workItem from="1723186498493" duration="62000" />
<workItem from="1723188538030" duration="717000" />
<workItem from="1723192814263" duration="1896000" />
<workItem from="1723420788933" duration="419000" />
<workItem from="1723420788933" duration="2164000" />
<workItem from="1723422983942" duration="13968000" />
</task>
<servers />
</component>
@ -127,16 +145,16 @@
</state>
<state x="267" y="27" key="#Project_Structure/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723104735076" />
<state x="2120" y="23" key="#Project_Structure/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1722590259734" />
<state x="765" y="203" key="#com.intellij.ide.util.MemberChooser" timestamp="1723180202517">
<screen x="0" y="0" width="1920" height="1040" />
<state x="2494" y="176" key="#com.intellij.ide.util.MemberChooser" timestamp="1723442836803">
<screen x="1920" y="0" width="1440" height="900" />
</state>
<state x="765" y="203" key="#com.intellij.ide.util.MemberChooser/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723180202517" />
<state x="2494" y="176" key="#com.intellij.ide.util.MemberChooser/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723017851339" />
<state x="393" y="12" width="1379" height="879" key="CommitChangelistDialog2" timestamp="1723105028964">
<screen x="0" y="0" width="1920" height="1040" />
<state x="2494" y="176" key="#com.intellij.ide.util.MemberChooser/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723442836803" />
<state x="2215" y="10" width="1379" height="879" key="CommitChangelistDialog2" timestamp="1723422366837">
<screen x="1920" y="0" width="1440" height="900" />
</state>
<state x="393" y="12" width="1379" height="879" key="CommitChangelistDialog2/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723105028964" />
<state x="2215" y="10" key="CommitChangelistDialog2/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1722590562023" />
<state x="2215" y="10" key="CommitChangelistDialog2/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723422366837" />
<state width="1090" height="539" key="DebuggerActiveHint" timestamp="1723100577304">
<screen x="0" y="0" width="1920" height="1040" />
</state>
@ -147,46 +165,46 @@
</state>
<state x="740" y="274" key="FileChooserDialogImpl/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1722996900988" />
<state x="2475" y="237" key="FileChooserDialogImpl/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723017044285" />
<state width="1396" height="249" key="GridCell.Tab.0.bottom" timestamp="1723195614379">
<state width="1396" height="76" key="GridCell.Tab.0.bottom" timestamp="1723443985608">
<screen x="1920" y="0" width="1440" height="900" />
</state>
<state width="1876" height="39" key="GridCell.Tab.0.bottom/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723185397662" />
<state width="1396" height="249" key="GridCell.Tab.0.bottom/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723195614379" />
<state width="1396" height="249" key="GridCell.Tab.0.center" timestamp="1723195614379">
<state width="938" height="423" key="GridCell.Tab.0.bottom/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723442658053" />
<state width="1396" height="76" key="GridCell.Tab.0.bottom/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723443985608" />
<state width="1396" height="76" key="GridCell.Tab.0.center" timestamp="1723443985608">
<screen x="1920" y="0" width="1440" height="900" />
</state>
<state width="1876" height="39" key="GridCell.Tab.0.center/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723185397662" />
<state width="1396" height="249" key="GridCell.Tab.0.center/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723195614379" />
<state width="1396" height="249" key="GridCell.Tab.0.left" timestamp="1723195614379">
<state width="938" height="423" key="GridCell.Tab.0.center/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723442658053" />
<state width="1396" height="76" key="GridCell.Tab.0.center/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723443985608" />
<state width="1396" height="76" key="GridCell.Tab.0.left" timestamp="1723443985608">
<screen x="1920" y="0" width="1440" height="900" />
</state>
<state width="1876" height="39" key="GridCell.Tab.0.left/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723185397662" />
<state width="1396" height="249" key="GridCell.Tab.0.left/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723195614379" />
<state width="1396" height="249" key="GridCell.Tab.0.right" timestamp="1723195614379">
<state width="938" height="423" key="GridCell.Tab.0.left/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723442658053" />
<state width="1396" height="76" key="GridCell.Tab.0.left/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723443985608" />
<state width="1396" height="76" key="GridCell.Tab.0.right" timestamp="1723443985608">
<screen x="1920" y="0" width="1440" height="900" />
</state>
<state width="1876" height="39" key="GridCell.Tab.0.right/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723185397662" />
<state width="1396" height="249" key="GridCell.Tab.0.right/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723195614379" />
<state width="1396" height="249" key="GridCell.Tab.1.bottom" timestamp="1723195614380">
<state width="938" height="423" key="GridCell.Tab.0.right/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723442658053" />
<state width="1396" height="76" key="GridCell.Tab.0.right/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723443985608" />
<state width="1396" height="76" key="GridCell.Tab.1.bottom" timestamp="1723443985608">
<screen x="1920" y="0" width="1440" height="900" />
</state>
<state width="1876" height="39" key="GridCell.Tab.1.bottom/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723185397663" />
<state width="1396" height="249" key="GridCell.Tab.1.bottom/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723195614380" />
<state width="1396" height="249" key="GridCell.Tab.1.center" timestamp="1723195614380">
<state width="938" height="423" key="GridCell.Tab.1.bottom/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723442658053" />
<state width="1396" height="76" key="GridCell.Tab.1.bottom/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723443985608" />
<state width="1396" height="76" key="GridCell.Tab.1.center" timestamp="1723443985608">
<screen x="1920" y="0" width="1440" height="900" />
</state>
<state width="1876" height="39" key="GridCell.Tab.1.center/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723185397662" />
<state width="1396" height="249" key="GridCell.Tab.1.center/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723195614380" />
<state width="1396" height="249" key="GridCell.Tab.1.left" timestamp="1723195614380">
<state width="938" height="423" key="GridCell.Tab.1.center/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723442658053" />
<state width="1396" height="76" key="GridCell.Tab.1.center/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723443985608" />
<state width="1396" height="76" key="GridCell.Tab.1.left" timestamp="1723443985608">
<screen x="1920" y="0" width="1440" height="900" />
</state>
<state width="1876" height="39" key="GridCell.Tab.1.left/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723185397662" />
<state width="1396" height="249" key="GridCell.Tab.1.left/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723195614380" />
<state width="1396" height="249" key="GridCell.Tab.1.right" timestamp="1723195614380">
<state width="938" height="423" key="GridCell.Tab.1.left/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723442658053" />
<state width="1396" height="76" key="GridCell.Tab.1.left/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723443985608" />
<state width="1396" height="76" key="GridCell.Tab.1.right" timestamp="1723443985608">
<screen x="1920" y="0" width="1440" height="900" />
</state>
<state width="1876" height="39" key="GridCell.Tab.1.right/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723185397663" />
<state width="1396" height="249" key="GridCell.Tab.1.right/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723195614380" />
<state width="938" height="423" key="GridCell.Tab.1.right/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723442658053" />
<state width="1396" height="76" key="GridCell.Tab.1.right/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723443985608" />
<state width="1876" height="39" key="GridCell.Tab.2.bottom" timestamp="1723185397663">
<screen x="0" y="0" width="1920" height="1040" />
</state>
@ -227,16 +245,16 @@
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="753" y="432" key="com.intellij.openapi.vcs.update.UpdateOrStatusOptionsDialogupdate-v2/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1722823330683" />
<state x="1305" y="146" width="1456" height="989" key="dock-window-1" timestamp="1723094183714">
<screen x="1920" y="0" width="1440" height="900" />
<state x="0" y="0" width="1132" height="875" maximized="true" key="dock-window-1" timestamp="1723423062840">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="1305" y="146" width="1456" height="989" key="dock-window-1/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723094183714" />
<state x="295" y="0" width="965" height="875" maximized="true" key="dock-window-1/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723017838407" />
<state x="128" y="-15" width="1092" height="856" maximized="true" key="dock-window-2" timestamp="1723108970295">
<state x="0" y="0" width="1132" height="875" maximized="true" key="dock-window-1/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723423062840" />
<state x="90" y="0" width="1142" height="875" maximized="true" key="dock-window-2" timestamp="1723440330686">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="128" y="-15" width="1092" height="856" maximized="true" key="dock-window-2/0.0.1920.1040/1920.0.1440.900@0.0.1920.1040" timestamp="1723108970295" />
<state x="222" y="0" width="1213" height="875" maximized="true" key="dock-window-2/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723018653242" />
<state x="90" y="0" width="1142" height="875" maximized="true" key="dock-window-2/0.0.1920.1040/1920.0.1440.900@1920.0.1440.900" timestamp="1723440330686" />
<state x="1920" y="0" width="1456" height="989" key="dock-window-3" timestamp="1723100033361">
<screen x="1920" y="0" width="1440" height="900" />
</state>

View File

@ -1,7 +1,7 @@
#for tests only !
#Fri Aug 09 14:26:27 CST 2024
#Mon Aug 12 13:58:32 CST 2024
jco.client.lang=ZH
jco.client.passwd=654321
jco.client.passwd=vAHHLPyr/O(DD#l(USpypoVFsBd}{mL?hFwfR/oNp/RvS,LI
jco.client.sysnr=00
jco.destination.pool_capacity=10
jco.client.client=800

View File

@ -2,6 +2,14 @@ package com.ruoyi.web.controller.expenses;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
import com.ruoyi.common.core.domain.entity.SysDept;
import com.ruoyi.common.utils.SecurityUtils;
import com.ruoyi.common.utils.StringUtils;
import com.ruoyi.common.utils.uuid.UUID;
import com.ruoyi.framework.changeRecord.ChangeRecordLog;
import com.ruoyi.system.service.ISysDeptService;
import com.ruoyi.system.service.ISysUserService;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
@ -34,6 +42,36 @@ public class ExpensesController extends BaseController
@Autowired
private IExpensesService expensesService;
@Autowired
private ISysUserService userService;
@Autowired
private ISysDeptService deptService;
/**
* 分派
*/
@PreAuthorize("@ss.hasPermi('expenses:expenses:assign')")
@ChangeRecordLog(serviceImplclass = "com.ruoyi.expenses.service.impl.ExpensesServiceImpl",
serviceImplMethod="selectExpensesByExpId",
tableId = "expId",codeName = "expCode",title = "费用支出单据分派")
@PostMapping("/expAssign")
public AjaxResult expAssign(@RequestBody Expenses expenses)
{
String[] expIds = expenses.getExpIds();
String expReceiveUserId = expenses.getExpReceiveUserId();
for(String expId:expIds){
Expenses entity = expensesService.selectExpensesByExpId(expId);
if(!"1".equals(entity.getExpApprovalStatus())){
return error("费用支出信息:"+entity.getExpCode()+" 当前状态不是协助中");
}
entity.setExpDispatchStatus("1");//更新 是否已分派 为已分派
entity.setExpReceiveUserId(expReceiveUserId);
expensesService.updateExpenses(entity);
}
return success();
}
/**
* 查询费用支出列表
*/
@ -42,6 +80,14 @@ public class ExpensesController extends BaseController
public TableDataInfo list(Expenses expenses)
{
startPage();
Boolean bidJlRoleFlag = SecurityUtils.hasRole("BID_BSZZY")||SecurityUtils.hasRole("BID_ZHGLY");
Boolean adminRoleFlag = SecurityUtils.hasRole("admin");
if(bidJlRoleFlag&&!adminRoleFlag){
expenses.setExpDispatchStatus("1");//查询已分派的单据
expenses.setExpReceiveUserId(getUserId()+"");
}
List<Expenses> list = expensesService.selectExpensesList(expenses);
return getDataTable(list);
}
@ -50,7 +96,6 @@ public class ExpensesController extends BaseController
* 导出费用支出列表
*/
@PreAuthorize("@ss.hasPermi('expenses:expenses:export')")
@Log(title = "费用支出", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(HttpServletResponse response, Expenses expenses)
{
@ -73,24 +118,126 @@ public class ExpensesController extends BaseController
* 新增费用支出
*/
@PreAuthorize("@ss.hasPermi('expenses:expenses:add')")
@Log(title = "费用支出", businessType = BusinessType.INSERT)
@ChangeRecordLog(serviceImplclass = "com.ruoyi.expenses.service.impl.ExpensesServiceImpl",
serviceImplMethod="selectExpensesByExpId",
tableId = "expId",codeName = "expCode",title = "费用支出新增")
@PostMapping
public AjaxResult add(@RequestBody Expenses expenses)
{
return toAjax(expensesService.insertExpenses(expenses));
expenses.setExpId(UUID.fastUUID().toString());
String bidCode = expensesService.getCode("TBFYZC");
expenses.setExpCode(bidCode);
// 获取用户角色 --判断是否有新建权限
Boolean bidJlRoleFlag = SecurityUtils.hasRole("BID")||SecurityUtils.hasRole("BID_BSZZY")||SecurityUtils.hasRole("BID_ZHGLY");
if(bidJlRoleFlag){
Long deptId = userService.selectUserByUserName(expenses.getExpSalesmanCode()).getDeptId();
expenses.setExpSalesmanDeptId(String.valueOf(deptId));
SysDept sysDept = deptService.selectDeptById(deptId);
expenses.setExpSalesmanDeptName(sysDept.getDeptName());
//获取用户ID
String userId = String.valueOf(userService.selectUserByUserName(expenses.getExpSalesmanCode()).getUserId());
expenses.setCreateBy(userId);
expenses.setUpdateBy(userId);
}else{
expenses.setCreateBy(String.valueOf(getUserId()));
expenses.setUpdateBy(String.valueOf(getUserId()));
}
expensesService.insertExpenses(expenses);
return success(expenses);
}
/**
* 修改费用支出
*/
@PreAuthorize("@ss.hasPermi('expenses:expenses:edit')")
@Log(title = "费用支出", businessType = BusinessType.UPDATE)
@ChangeRecordLog(serviceImplclass = "com.ruoyi.expenses.service.impl.ExpensesServiceImpl",
serviceImplMethod="selectExpensesByExpId",
tableId = "expId",codeName = "expCode",title = "费用支出新增")
@PutMapping
public AjaxResult edit(@RequestBody Expenses expenses)
{
// 获取用户角色 --判断是否有新建权限
Boolean bidJlRoleFlag = SecurityUtils.hasRole("BID")||SecurityUtils.hasRole("BID_BSZZY")||SecurityUtils.hasRole("BID_ZHGLY");
if(bidJlRoleFlag){
Long deptId = userService.selectUserByUserName(expenses.getExpSalesmanCode()).getDeptId();
expenses.setExpSalesmanDeptId(String.valueOf(deptId));
SysDept sysDept = deptService.selectDeptById(deptId);
expenses.setExpSalesmanDeptName(sysDept.getDeptName());
//获取用户ID
String userId = String.valueOf(userService.selectUserByUserName(expenses.getExpSalesmanCode()).getUserId());
expenses.setCreateBy(userId);
expenses.setUpdateBy(userId);
}else{
expenses.setUpdateBy(String.valueOf(getUserId()));
}
return toAjax(expensesService.updateExpenses(expenses));
}
/**
* 提交投标办按钮
*/
@PreAuthorize("@ss.hasPermi('expenses:expenses:commit')")
@ChangeRecordLog(serviceImplclass = "com.ruoyi.expenses.service.impl.ExpensesServiceImpl",
serviceImplMethod="selectExpensesByExpId",
tableId = "expId",codeName = "expCode",title = "业务员提交投标办")
@PostMapping("/commitExp")
public AjaxResult commitExp(@RequestBody Expenses expenses)
{
try{
expenses.setExpApprovalStatus("1");
Long deptId = getLoginUser().getUser().getDeptId();
// 获取用户角色 --判断是否有新建权限
Boolean bidJlRoleFlag = SecurityUtils.hasRole("BID")||SecurityUtils.hasRole("BID_BSZZY")||SecurityUtils.hasRole("BID_ZHGLY");
if(bidJlRoleFlag){
deptId = userService.selectUserByUserName(expenses.getExpSalesmanCode()).getDeptId();
}
SysDept sysDept = deptService.selectDeptById(deptId);
String doa_id = expenses.getExpId();
String doaNumber = expensesService.getCodeExp("FZ");
expenses.setExpNumber(doaNumber);
if(StringUtils.isEmpty(doa_id)){
expenses.setExpId(UUID.fastUUID().toString());
String doaCode = expensesService.getCode("TBFYZC");
expenses.setExpCode(doaCode);
if(bidJlRoleFlag){
expenses.setExpSalesmanDeptId(String.valueOf(deptId));
expenses.setExpSalesmanDeptName(sysDept.getDeptName());
String userId = String.valueOf(userService.selectUserByUserName(expenses.getExpSalesmanCode()).getUserId());
expenses.setCreateBy(userId);
}else{
expenses.setCreateBy(String.valueOf(getUserId()));
}
expensesService.insertExpenses(expenses);
return success();
}else{
if(bidJlRoleFlag){
expenses.setExpSalesmanDeptId(String.valueOf(deptId));
expenses.setExpSalesmanDeptName(sysDept.getDeptName());
String userId = String.valueOf(userService.selectUserByUserName(expenses.getExpSalesmanCode()).getUserId());
expenses.setCreateBy(userId);
expenses.setUpdateBy(userId);
}else{
expenses.setUpdateBy(String.valueOf(getUserId()));
}
expenses.setExpReturnRemark("");//驳回后再次提交清除驳回原因
expensesService.updateExpenses(expenses);
return success();
}
}catch (Exception e){
return error("系统异常");
}
}
/**
* 删除费用支出
*/

View File

@ -1,5 +1,5 @@
#Generated by Maven
#Mon Aug 12 08:02:54 CST 2024
#Mon Aug 12 14:13:40 CST 2024
version=3.8.7
groupId=com.ruoyi
artifactId=ruoyi-admin

Binary file not shown.

View File

@ -1,5 +1,5 @@
#Generated by Maven
#Mon Aug 12 08:02:41 CST 2024
#Mon Aug 12 14:13:23 CST 2024
version=3.8.7
groupId=com.ruoyi
artifactId=ruoyi-common

View File

@ -1,5 +1,5 @@
#Generated by Maven
#Mon Aug 12 08:02:48 CST 2024
#Mon Aug 12 14:13:31 CST 2024
version=3.8.7
groupId=com.ruoyi
artifactId=ruoyi-framework

View File

@ -1,5 +1,5 @@
#Generated by Maven
#Mon Aug 12 08:02:49 CST 2024
#Mon Aug 12 14:13:34 CST 2024
version=3.8.7
groupId=com.ruoyi
artifactId=ruoyi-generator

View File

@ -1,5 +1,5 @@
#Generated by Maven
#Mon Aug 12 08:02:49 CST 2024
#Mon Aug 12 14:13:33 CST 2024
version=3.8.7
groupId=com.ruoyi
artifactId=ruoyi-quartz

View File

@ -1,5 +1,6 @@
package com.ruoyi.expenses.domain;
import com.ruoyi.common.annotation.DataName;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
@ -17,20 +18,30 @@ public class Expenses extends BaseEntity
/** */
private String expId;
private String[] expIds;
/** 支出编号 */
@Excel(name = "支出编号")
@DataName(name = "费用支出单号")
@Excel(name = "费用支出单号")
private String expCode;
/** 标书编号 */
@DataName(name = "费用支出编号")
@Excel(name = "费用支出编号")
private String expNumber;
/** 资格预审编号 */
@DataName(name = "资格预审编号")
@Excel(name = "资格预审编号")
private String expPqCode;
/** 标书编号 */
@DataName(name = "标书编号")
@Excel(name = "标书编号")
private String expBidCode;
/** 支出形式 */
@DataName(name = "支出形式")
@Excel(name = "支出形式")
private String expExpenditureMode;
@ -38,41 +49,52 @@ public class Expenses extends BaseEntity
private String expCustomerBm;
/** 客户名称(必选) */
@DataName(name = "客户名称")
@Excel(name = "客户名称")
private String expCustomerName;
/** 支出人 */
@DataName(name = "支出人")
@Excel(name = "支出人")
private String expExpenditurePeople;
/** 项目名称 */
@DataName(name = "项目名称")
private String expProject;
/** 预计归还日期 */
@DataName(name = "预计归还日期")
private String expReturnDate;
/** 支出类别 */
@DataName(name = "支出类别")
@Excel(name = "支出类别")
private String expExpenditureType;
/** 支出金额 */
@DataName(name = "支出金额")
@Excel(name = "支出金额")
private Long expExpenditureAmount;
/** 投标区域 */
@DataName(name = "投标区域")
private String expBidArea;
/** 支出时间 */
@DataName(name = "支出时间")
@Excel(name = "支出时间")
private String expExpenditureDate;
/** 支出金额 (大写) */
@DataName(name = "支出金额 (大写)")
private String expExpenditureAmountUppercase;
/** 是否有内勤 */
@DataName(name = "是否有内勤",readConverterExp="0=是,1=否")
private String expStaffTureorfales;
/** 选择内勤 */
@DataName(name = "选择内勤")
private String expBackOffice;
/** 业务员账号 */
@ -82,6 +104,7 @@ public class Expenses extends BaseEntity
private String expSalesmanBm;
/** 业务员 */
@DataName(name = "业务员")
@Excel(name = "业务员")
private String expSalesmanName;
@ -89,47 +112,72 @@ public class Expenses extends BaseEntity
private String expSalesmanDeptId;
/** 部门名 */
@DataName(name = "部门")
private String expSalesmanDeptName;
/** 分派状态 */
@Excel(name = "分派状态")
@DataName(name = "分派状态",readConverterExp="0=未分派,1=已分派")
@Excel(name = "分派状态",dictType = "exp_dispatch_status")
private String expDispatchStatus;
/** 账户名 */
@DataName(name = "账户名")
private String expAccountName;
/** 账号 */
@DataName(name = "账号")
private String expAccountNumber;
/** 开户银行 */
@DataName(name = "开户银行")
private String expDepositBank;
/** 行号及其他 */
@DataName(name = "行号及其他")
private String expLineNumberAndOthres;
/** 申请说明 */
@DataName(name = "申请说明")
private String expRequestRemark;
/** OA返回备注 */
/** OA反馈说明 */
@DataName(name = "OA反馈说明")
private String expOaRemark;
/** 驳回原因 */
@DataName(name = "驳回原因")
private String expReturnRemark;
/** 业务员提交状态 */
@Excel(name = "提交状态")
@DataName(name = "提交状态",readConverterExp="0=待提交,1=协助中,2=已完成,3=已驳回")
@Excel(name = "提交状态",dictType = "exp_approval_status")
private String expApprovalStatus;
/** OA审批状态 */
@Excel(name = "OA审批状态")
@DataName(name = "OA审批状态",readConverterExp="0=待提交,1=审批中,2=已通过,3=已驳回")
@Excel(name = "OA审批状态",dictType = "exp_oa_approval_status")
private String expOaApprovalStatus;
/** 分派接收人ID */
private String expReceiveUserId;
/** 分派接收人 */
@DataName(name = "分派接收人")
private String expReceiveUserNickName;
public void setExpId(String expId)
{
this.expId = expId;
}
public String getExpId()
{
return expId;
}
public String[] getExpIds() { return expIds; }
public void setExpIds(String[] expIds) { this.expIds = expIds; }
public void setExpCode(String expCode)
{
this.expCode = expCode;
@ -139,6 +187,9 @@ public class Expenses extends BaseEntity
{
return expCode;
}
public String getExpNumber() { return expNumber; }
public void setExpNumber(String expNumber) { this.expNumber = expNumber; }
public void setExpPqCode(String expPqCode)
{
this.expPqCode = expPqCode;
@ -355,15 +406,15 @@ public class Expenses extends BaseEntity
{
return expDepositBank;
}
public void setExpLineNumberAndOthres(String expLineNumberAndOthres)
{
this.expLineNumberAndOthres = expLineNumberAndOthres;
}
public void setExpLineNumberAndOthres(String expLineNumberAndOthres) { this.expLineNumberAndOthres = expLineNumberAndOthres; }
public String getExpLineNumberAndOthres()
{
return expLineNumberAndOthres;
}
public String getExpOaRemark() { return expOaRemark; }
public void setExpOaRemark(String expOaRemark) { this.expOaRemark = expOaRemark; }
public void setExpRequestRemark(String expRequestRemark)
{
this.expRequestRemark = expRequestRemark;
@ -400,45 +451,10 @@ public class Expenses extends BaseEntity
{
return expOaApprovalStatus;
}
public String getExpReceiveUserId() { return expReceiveUserId; }
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("expId", getExpId())
.append("expCode", getExpCode())
.append("expPqCode", getExpPqCode())
.append("expBidCode", getExpBidCode())
.append("expExpenditureMode", getExpExpenditureMode())
.append("expCustomerBm", getExpCustomerBm())
.append("expCustomerName", getExpCustomerName())
.append("expExpenditurePeople", getExpExpenditurePeople())
.append("expProject", getExpProject())
.append("expReturnDate", getExpReturnDate())
.append("expExpenditureType", getExpExpenditureType())
.append("expExpenditureAmount", getExpExpenditureAmount())
.append("expBidArea", getExpBidArea())
.append("expExpenditureDate", getExpExpenditureDate())
.append("expExpenditureAmountUppercase", getExpExpenditureAmountUppercase())
.append("expStaffTureorfales", getExpStaffTureorfales())
.append("expBackOffice", getExpBackOffice())
.append("expSalesmanCode", getExpSalesmanCode())
.append("expSalesmanBm", getExpSalesmanBm())
.append("expSalesmanName", getExpSalesmanName())
.append("expSalesmanDeptId", getExpSalesmanDeptId())
.append("expSalesmanDeptName", getExpSalesmanDeptName())
.append("expDispatchStatus", getExpDispatchStatus())
.append("expAccountName", getExpAccountName())
.append("expAccountNumber", getExpAccountNumber())
.append("expDepositBank", getExpDepositBank())
.append("expLineNumberAndOthres", getExpLineNumberAndOthres())
.append("expRequestRemark", getExpRequestRemark())
.append("expReturnRemark", getExpReturnRemark())
.append("expApprovalStatus", getExpApprovalStatus())
.append("expOaApprovalStatus", getExpOaApprovalStatus())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.toString();
}
public void setExpReceiveUserId(String expReceiveUserId) { this.expReceiveUserId = expReceiveUserId; }
public String getExpReceiveUserNickName() { return expReceiveUserNickName; }
public void setExpReceiveUserNickName(String expReceiveUserNickName) { this.expReceiveUserNickName = expReceiveUserNickName; }
}

View File

@ -1,6 +1,8 @@
package com.ruoyi.expenses.mapper;
import java.util.List;
import com.ruoyi.common.core.domain.entity.SysDept;
import com.ruoyi.expenses.domain.Expenses;
/**
@ -58,4 +60,18 @@ public interface ExpensesMapper
* @return 结果
*/
public int deleteExpensesByExpIds(String[] expIds);
/**
* 获取系统单据编号
* @param type
* @return
*/
String getCode(String type);
/**
* 获取系统单据业务编号
* @param type
* @return
*/
String getCodeExp(String type);
}

View File

@ -1,6 +1,8 @@
package com.ruoyi.expenses.service;
import java.util.List;
import com.ruoyi.common.core.domain.entity.SysDept;
import com.ruoyi.expenses.domain.Expenses;
/**
@ -58,4 +60,18 @@ public interface IExpensesService
* @return 结果
*/
public int deleteExpensesByExpId(String expId);
/**
* 获取系统单据编号
* @param type
* @return
*/
String getCode(String type);
/**
* 获取系统单据业务编号
* @param type
* @return
*/
String getCodeExp(String type);
}

View File

@ -1,12 +1,16 @@
package com.ruoyi.expenses.service.impl;
import java.util.List;
import com.ruoyi.common.annotation.DataScope;
import com.ruoyi.common.core.domain.entity.SysDept;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.expenses.mapper.ExpensesMapper;
import com.ruoyi.expenses.domain.Expenses;
import com.ruoyi.expenses.service.IExpensesService;
import org.springframework.transaction.annotation.Transactional;
/**
* 费用支出Service业务层处理
@ -38,6 +42,7 @@ public class ExpensesServiceImpl implements IExpensesService
* @param expenses 费用支出
* @return 费用支出
*/
@DataScope(deptAlias = "d", userAlias = "u")
@Override
public List<Expenses> selectExpensesList(Expenses expenses)
{
@ -50,6 +55,7 @@ public class ExpensesServiceImpl implements IExpensesService
* @param expenses 费用支出
* @return 结果
*/
@Transactional
@Override
public int insertExpenses(Expenses expenses)
{
@ -63,6 +69,7 @@ public class ExpensesServiceImpl implements IExpensesService
* @param expenses 费用支出
* @return 结果
*/
@Transactional
@Override
public int updateExpenses(Expenses expenses)
{
@ -93,4 +100,24 @@ public class ExpensesServiceImpl implements IExpensesService
{
return expensesMapper.deleteExpensesByExpId(expId);
}
/**
* 获取系统单据编号
* @param type
* @return
*/
@Override
public String getCode(String type) {
return expensesMapper.getCode(type);
}
/**
* 获取系统单据业务编号
* @param type
* @return
*/
@Override
public String getCodeExp(String type) {
return expensesMapper.getCodeExp(type);
}
}

View File

@ -7,6 +7,7 @@
<resultMap type="Expenses" id="ExpensesResult">
<result property="expId" column="exp_id" />
<result property="expCode" column="exp_code" />
<result property="expNumber" column="exp_number" />
<result property="expPqCode" column="exp_pq_code" />
<result property="expBidCode" column="exp_bid_code" />
<result property="expExpenditureMode" column="exp_expenditure_mode" />
@ -36,20 +37,40 @@
<result property="expReturnRemark" column="exp_return_remark" />
<result property="expApprovalStatus" column="exp_approval_status" />
<result property="expOaApprovalStatus" column="exp_oa_approval_status" />
<result property="expOaRemark" column="exp_oa_remark" />
<result property="expReceiveUserId" column="exp_receive_user_id" />
<result property="expReceiveUserNickName" column="exp_receive_user_nick_name" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
</resultMap>
<sql id="expJoins">
left join sys_user u on u.user_id=a.create_by
left join sys_user u2 on u2.user_id=a.exp_receive_user_id
left join sys_dept d on u.dept_id = d.dept_id
</sql>
<sql id="selectExpensesVo">
select exp_id, exp_code, exp_pq_code, exp_bid_code, exp_expenditure_mode, exp_customer_bm, exp_customer_name, exp_expenditure_people, exp_project, exp_return_date, exp_expenditure_type, exp_expenditure_amount, exp_bid_area, exp_expenditure_date, exp_expenditure_amount_uppercase, exp_staff_tureorfales, exp_back_office, exp_salesman_code, exp_salesman_bm, exp_salesman_name, exp_salesman_dept_id, exp_salesman_dept_name, exp_dispatch_status, exp_account_name, exp_account_number, exp_deposit_bank, exp_line_number_and_othres, exp_request_remark, exp_return_remark, exp_approval_status, exp_oa_approval_status, create_by, create_time, update_by, update_time from expenses
select a.exp_id, a.exp_code, a.exp_pq_code, a.exp_number, a.exp_bid_code, a.exp_expenditure_mode, a.exp_customer_bm,
a.exp_customer_name, a.exp_expenditure_people, a.exp_project, a.exp_return_date,
a.exp_expenditure_type, a.exp_expenditure_amount, a.exp_bid_area, a.exp_expenditure_date,
a.exp_expenditure_amount_uppercase, a.exp_staff_tureorfales, a.exp_back_office,
a.exp_salesman_code, a.exp_salesman_bm, a.exp_salesman_name, a.exp_salesman_dept_id,
a.exp_salesman_dept_name, a.exp_dispatch_status, a.exp_account_name, a.exp_account_number,
a.exp_deposit_bank, a.exp_line_number_and_othres, a.exp_request_remark, a.exp_return_remark,
a.exp_approval_status, a.exp_oa_approval_status,a.exp_oa_remark, a.exp_receive_user_id, u2.nick_name exp_receive_user_nick_name,
a.create_by, a.create_time, a.update_by, a.update_time
from expenses a
<include refid="expJoins"/>
</sql>
<select id="selectExpensesList" parameterType="Expenses" resultMap="ExpensesResult">
<include refid="selectExpensesVo"/>
<where>
<if test="expCode != null and expCode != ''"> and exp_code like concat('%', #{expCode}, '%')</if>
<if test="expNumber != null and expNumber != ''"> and exp_number like concat('%', #{expNumber}, '%')</if>
<if test="expExpenditureMode != null and expExpenditureMode != ''"> and exp_expenditure_mode = #{expExpenditureMode}</if>
<if test="expCustomerName != null and expCustomerName != ''"> and exp_customer_name like concat('%', #{expCustomerName}, '%')</if>
<if test="expProject != null and expProject != ''"> and exp_project like concat('%', #{expProject}, '%')</if>
@ -59,6 +80,11 @@
<if test="expSalesmanName != null and expSalesmanName != ''"> and exp_salesman_name like concat('%', #{expSalesmanName}, '%')</if>
<if test="expRequestRemark != null and expRequestRemark != ''"> and exp_request_remark like concat('%', #{expRequestRemark}, '%')</if>
<if test="expApprovalStatus != null and expApprovalStatus != ''"> and exp_approval_status = #{expApprovalStatus}</if>
<if test="expDispatchStatus != null and expDispatchStatus != ''"> and exp_dispatch_status = #{expDispatchStatus}</if>
<if test="expReceiveUserId != null and expReceiveUserId != ''"> and exp_receive_user_id = #{expReceiveUserId}</if>
<!-- 数据范围过滤 -->
${params.dataScope}
</where>
</select>
@ -72,35 +98,40 @@
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="expId != null">exp_id,</if>
<if test="expCode != null">exp_code,</if>
<if test="expNumber != null">exp_number,</if>
<if test="expPqCode != null">exp_pq_code,</if>
<if test="expBidCode != null">exp_bid_code,</if>
<if test="expExpenditureMode != null and expExpenditureMode != ''">exp_expenditure_mode,</if>
<if test="expExpenditureMode != null">exp_expenditure_mode,</if>
<if test="expCustomerBm != null">exp_customer_bm,</if>
<if test="expCustomerName != null and expCustomerName != ''">exp_customer_name,</if>
<if test="expExpenditurePeople != null and expExpenditurePeople != ''">exp_expenditure_people,</if>
<if test="expProject != null and expProject != ''">exp_project,</if>
<if test="expReturnDate != null and expReturnDate != ''">exp_return_date,</if>
<if test="expExpenditureType != null and expExpenditureType != ''">exp_expenditure_type,</if>
<if test="expCustomerName != null">exp_customer_name,</if>
<if test="expExpenditurePeople != null">exp_expenditure_people,</if>
<if test="expProject != null">exp_project,</if>
<if test="expReturnDate != null">exp_return_date,</if>
<if test="expExpenditureType != null">exp_expenditure_type,</if>
<if test="expExpenditureAmount != null">exp_expenditure_amount,</if>
<if test="expBidArea != null">exp_bid_area,</if>
<if test="expExpenditureDate != null and expExpenditureDate != ''">exp_expenditure_date,</if>
<if test="expExpenditureDate != null">exp_expenditure_date,</if>
<if test="expExpenditureAmountUppercase != null">exp_expenditure_amount_uppercase,</if>
<if test="expStaffTureorfales != null and expStaffTureorfales != ''">exp_staff_tureorfales,</if>
<if test="expBackOffice != null and expBackOffice != ''">exp_back_office,</if>
<if test="expStaffTureorfales != null">exp_staff_tureorfales,</if>
<if test="expBackOffice != null">exp_back_office,</if>
<if test="expSalesmanCode != null">exp_salesman_code,</if>
<if test="expSalesmanBm != null">exp_salesman_bm,</if>
<if test="expSalesmanName != null and expSalesmanName != ''">exp_salesman_name,</if>
<if test="expSalesmanName != null">exp_salesman_name,</if>
<if test="expSalesmanDeptId != null">exp_salesman_dept_id,</if>
<if test="expSalesmanDeptName != null">exp_salesman_dept_name,</if>
<if test="expDispatchStatus != null">exp_dispatch_status,</if>
<if test="expAccountName != null and expAccountName != ''">exp_account_name,</if>
<if test="expAccountNumber != null and expAccountNumber != ''">exp_account_number,</if>
<if test="expDepositBank != null and expDepositBank != ''">exp_deposit_bank,</if>
<if test="expAccountName != null">exp_account_name,</if>
<if test="expAccountNumber != null">exp_account_number,</if>
<if test="expDepositBank != null">exp_deposit_bank,</if>
<if test="expLineNumberAndOthres != null">exp_line_number_and_othres,</if>
<if test="expRequestRemark != null">exp_request_remark,</if>
<if test="expReturnRemark != null">exp_return_remark,</if>
<if test="expApprovalStatus != null">exp_approval_status,</if>
<if test="expOaApprovalStatus != null">exp_oa_approval_status,</if>
<if test="expOaRemark != null">exp_oa_remark,</if>
<if test="expReceiveUserId != null">exp_receive_user_id,</if>
<if test="expReceiveUserNickName != null">exp_receive_user_nick_name,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
@ -109,35 +140,40 @@
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="expId != null">#{expId},</if>
<if test="expCode != null">#{expCode},</if>
<if test="expNumber != null">#{expNumber},</if>
<if test="expPqCode != null">#{expPqCode},</if>
<if test="expBidCode != null">#{expBidCode},</if>
<if test="expExpenditureMode != null and expExpenditureMode != ''">#{expExpenditureMode},</if>
<if test="expExpenditureMode != null">#{expExpenditureMode},</if>
<if test="expCustomerBm != null">#{expCustomerBm},</if>
<if test="expCustomerName != null and expCustomerName != ''">#{expCustomerName},</if>
<if test="expExpenditurePeople != null and expExpenditurePeople != ''">#{expExpenditurePeople},</if>
<if test="expProject != null and expProject != ''">#{expProject},</if>
<if test="expReturnDate != null and expReturnDate != ''">#{expReturnDate},</if>
<if test="expExpenditureType != null and expExpenditureType != ''">#{expExpenditureType},</if>
<if test="expCustomerName != null">#{expCustomerName},</if>
<if test="expExpenditurePeople != null">#{expExpenditurePeople},</if>
<if test="expProject != null">#{expProject},</if>
<if test="expReturnDate != null">#{expReturnDate},</if>
<if test="expExpenditureType != null">#{expExpenditureType},</if>
<if test="expExpenditureAmount != null">#{expExpenditureAmount},</if>
<if test="expBidArea != null">#{expBidArea},</if>
<if test="expExpenditureDate != null and expExpenditureDate != ''">#{expExpenditureDate},</if>
<if test="expExpenditureDate != null">#{expExpenditureDate},</if>
<if test="expExpenditureAmountUppercase != null">#{expExpenditureAmountUppercase},</if>
<if test="expStaffTureorfales != null and expStaffTureorfales != ''">#{expStaffTureorfales},</if>
<if test="expBackOffice != null and expBackOffice != ''">#{expBackOffice},</if>
<if test="expStaffTureorfales != null">#{expStaffTureorfales},</if>
<if test="expBackOffice != null">#{expBackOffice},</if>
<if test="expSalesmanCode != null">#{expSalesmanCode},</if>
<if test="expSalesmanBm != null">#{expSalesmanBm},</if>
<if test="expSalesmanName != null and expSalesmanName != ''">#{expSalesmanName},</if>
<if test="expSalesmanName != null">#{expSalesmanName},</if>
<if test="expSalesmanDeptId != null">#{expSalesmanDeptId},</if>
<if test="expSalesmanDeptName != null">#{expSalesmanDeptName},</if>
<if test="expDispatchStatus != null">#{expDispatchStatus},</if>
<if test="expAccountName != null and expAccountName != ''">#{expAccountName},</if>
<if test="expAccountNumber != null and expAccountNumber != ''">#{expAccountNumber},</if>
<if test="expDepositBank != null and expDepositBank != ''">#{expDepositBank},</if>
<if test="expAccountName != null">#{expAccountName},</if>
<if test="expAccountNumber != null">#{expAccountNumber},</if>
<if test="expDepositBank != null">#{expDepositBank},</if>
<if test="expLineNumberAndOthres != null">#{expLineNumberAndOthres},</if>
<if test="expRequestRemark != null">#{expRequestRemark},</if>
<if test="expReturnRemark != null">#{expReturnRemark},</if>
<if test="expApprovalStatus != null">#{expApprovalStatus},</if>
<if test="expOaApprovalStatus != null">#{expOaApprovalStatus},</if>
<if test="expOaRemark != null">#{expOaRemark},</if>
<if test="expReceiveUserId != null">#{expReceiveUserId},</if>
<if test="expReceiveUserNickName != null">#{expReceiveUserNickName},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
@ -150,34 +186,39 @@
<trim prefix="SET" suffixOverrides=",">
<if test="expCode != null">exp_code = #{expCode},</if>
<if test="expPqCode != null">exp_pq_code = #{expPqCode},</if>
<if test="expNumber != null">exp_number = #{expNumber},</if>
<if test="expBidCode != null">exp_bid_code = #{expBidCode},</if>
<if test="expExpenditureMode != null and expExpenditureMode != ''">exp_expenditure_mode = #{expExpenditureMode},</if>
<if test="expExpenditureMode != null">exp_expenditure_mode = #{expExpenditureMode},</if>
<if test="expCustomerBm != null">exp_customer_bm = #{expCustomerBm},</if>
<if test="expCustomerName != null and expCustomerName != ''">exp_customer_name = #{expCustomerName},</if>
<if test="expExpenditurePeople != null and expExpenditurePeople != ''">exp_expenditure_people = #{expExpenditurePeople},</if>
<if test="expProject != null and expProject != ''">exp_project = #{expProject},</if>
<if test="expReturnDate != null and expReturnDate != ''">exp_return_date = #{expReturnDate},</if>
<if test="expExpenditureType != null and expExpenditureType != ''">exp_expenditure_type = #{expExpenditureType},</if>
<if test="expCustomerName != null">exp_customer_name = #{expCustomerName},</if>
<if test="expExpenditurePeople != null">exp_expenditure_people = #{expExpenditurePeople},</if>
<if test="expProject != null">exp_project = #{expProject},</if>
<if test="expReturnDate != null">exp_return_date = #{expReturnDate},</if>
<if test="expExpenditureType != null">exp_expenditure_type = #{expExpenditureType},</if>
<if test="expExpenditureAmount != null">exp_expenditure_amount = #{expExpenditureAmount},</if>
<if test="expBidArea != null">exp_bid_area = #{expBidArea},</if>
<if test="expExpenditureDate != null and expExpenditureDate != ''">exp_expenditure_date = #{expExpenditureDate},</if>
<if test="expExpenditureDate != null">exp_expenditure_date = #{expExpenditureDate},</if>
<if test="expExpenditureAmountUppercase != null">exp_expenditure_amount_uppercase = #{expExpenditureAmountUppercase},</if>
<if test="expStaffTureorfales != null and expStaffTureorfales != ''">exp_staff_tureorfales = #{expStaffTureorfales},</if>
<if test="expBackOffice != null and expBackOffice != ''">exp_back_office = #{expBackOffice},</if>
<if test="expStaffTureorfales != null">exp_staff_tureorfales = #{expStaffTureorfales},</if>
<if test="expBackOffice != null">exp_back_office = #{expBackOffice},</if>
<if test="expSalesmanCode != null">exp_salesman_code = #{expSalesmanCode},</if>
<if test="expSalesmanBm != null">exp_salesman_bm = #{expSalesmanBm},</if>
<if test="expSalesmanName != null and expSalesmanName != ''">exp_salesman_name = #{expSalesmanName},</if>
<if test="expSalesmanName != null">exp_salesman_name = #{expSalesmanName},</if>
<if test="expSalesmanDeptId != null">exp_salesman_dept_id = #{expSalesmanDeptId},</if>
<if test="expSalesmanDeptName != null">exp_salesman_dept_name = #{expSalesmanDeptName},</if>
<if test="expDispatchStatus != null">exp_dispatch_status = #{expDispatchStatus},</if>
<if test="expAccountName != null and expAccountName != ''">exp_account_name = #{expAccountName},</if>
<if test="expAccountNumber != null and expAccountNumber != ''">exp_account_number = #{expAccountNumber},</if>
<if test="expDepositBank != null and expDepositBank != ''">exp_deposit_bank = #{expDepositBank},</if>
<if test="expAccountName != null">exp_account_name = #{expAccountName},</if>
<if test="expAccountNumber != null">exp_account_number = #{expAccountNumber},</if>
<if test="expDepositBank != null">exp_deposit_bank = #{expDepositBank},</if>
<if test="expLineNumberAndOthres != null">exp_line_number_and_othres = #{expLineNumberAndOthres},</if>
<if test="expRequestRemark != null">exp_request_remark = #{expRequestRemark},</if>
<if test="expReturnRemark != null">exp_return_remark = #{expReturnRemark},</if>
<if test="expApprovalStatus != null">exp_approval_status = #{expApprovalStatus},</if>
<if test="expOaApprovalStatus != null">exp_oa_approval_status = #{expOaApprovalStatus},</if>
<if test="expOaRemark != null">exp_oa_remark = #{expOaRemark},</if>
<if test="expReceiveUserId != null">exp_receive_user_id = #{expReceiveUserId},</if>
<if test="expReceiveUserNickName != null">exp_receive_user_nick_name = #{expReceiveUserNickName},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
@ -196,4 +237,11 @@
#{expId}
</foreach>
</delete>
<select id="getCode" resultType="String" statementType="CALLABLE">
{call GetSerialNo(#{type,mode=IN,jdbcType=VARCHAR})}
</select>
<select id="getCodeExp" resultType="String" statementType="CALLABLE">
{call GetSerialNo_Business(#{type,mode=IN,jdbcType=VARCHAR})}
</select>
</mapper>

View File

@ -7,6 +7,7 @@
<resultMap type="Expenses" id="ExpensesResult">
<result property="expId" column="exp_id" />
<result property="expCode" column="exp_code" />
<result property="expNumber" column="exp_number" />
<result property="expPqCode" column="exp_pq_code" />
<result property="expBidCode" column="exp_bid_code" />
<result property="expExpenditureMode" column="exp_expenditure_mode" />
@ -36,20 +37,40 @@
<result property="expReturnRemark" column="exp_return_remark" />
<result property="expApprovalStatus" column="exp_approval_status" />
<result property="expOaApprovalStatus" column="exp_oa_approval_status" />
<result property="expOaRemark" column="exp_oa_remark" />
<result property="expReceiveUserId" column="exp_receive_user_id" />
<result property="expReceiveUserNickName" column="exp_receive_user_nick_name" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
</resultMap>
<sql id="expJoins">
left join sys_user u on u.user_id=a.create_by
left join sys_user u2 on u2.user_id=a.exp_receive_user_id
left join sys_dept d on u.dept_id = d.dept_id
</sql>
<sql id="selectExpensesVo">
select exp_id, exp_code, exp_pq_code, exp_bid_code, exp_expenditure_mode, exp_customer_bm, exp_customer_name, exp_expenditure_people, exp_project, exp_return_date, exp_expenditure_type, exp_expenditure_amount, exp_bid_area, exp_expenditure_date, exp_expenditure_amount_uppercase, exp_staff_tureorfales, exp_back_office, exp_salesman_code, exp_salesman_bm, exp_salesman_name, exp_salesman_dept_id, exp_salesman_dept_name, exp_dispatch_status, exp_account_name, exp_account_number, exp_deposit_bank, exp_line_number_and_othres, exp_request_remark, exp_return_remark, exp_approval_status, exp_oa_approval_status, create_by, create_time, update_by, update_time from expenses
select a.exp_id, a.exp_code, a.exp_pq_code, a.exp_number, a.exp_bid_code, a.exp_expenditure_mode, a.exp_customer_bm,
a.exp_customer_name, a.exp_expenditure_people, a.exp_project, a.exp_return_date,
a.exp_expenditure_type, a.exp_expenditure_amount, a.exp_bid_area, a.exp_expenditure_date,
a.exp_expenditure_amount_uppercase, a.exp_staff_tureorfales, a.exp_back_office,
a.exp_salesman_code, a.exp_salesman_bm, a.exp_salesman_name, a.exp_salesman_dept_id,
a.exp_salesman_dept_name, a.exp_dispatch_status, a.exp_account_name, a.exp_account_number,
a.exp_deposit_bank, a.exp_line_number_and_othres, a.exp_request_remark, a.exp_return_remark,
a.exp_approval_status, a.exp_oa_approval_status,a.exp_oa_remark, a.exp_receive_user_id, u2.nick_name exp_receive_user_nick_name,
a.create_by, a.create_time, a.update_by, a.update_time
from expenses a
<include refid="expJoins"/>
</sql>
<select id="selectExpensesList" parameterType="Expenses" resultMap="ExpensesResult">
<include refid="selectExpensesVo"/>
<where>
<if test="expCode != null and expCode != ''"> and exp_code like concat('%', #{expCode}, '%')</if>
<if test="expNumber != null and expNumber != ''"> and exp_number like concat('%', #{expNumber}, '%')</if>
<if test="expExpenditureMode != null and expExpenditureMode != ''"> and exp_expenditure_mode = #{expExpenditureMode}</if>
<if test="expCustomerName != null and expCustomerName != ''"> and exp_customer_name like concat('%', #{expCustomerName}, '%')</if>
<if test="expProject != null and expProject != ''"> and exp_project like concat('%', #{expProject}, '%')</if>
@ -59,6 +80,11 @@
<if test="expSalesmanName != null and expSalesmanName != ''"> and exp_salesman_name like concat('%', #{expSalesmanName}, '%')</if>
<if test="expRequestRemark != null and expRequestRemark != ''"> and exp_request_remark like concat('%', #{expRequestRemark}, '%')</if>
<if test="expApprovalStatus != null and expApprovalStatus != ''"> and exp_approval_status = #{expApprovalStatus}</if>
<if test="expDispatchStatus != null and expDispatchStatus != ''"> and exp_dispatch_status = #{expDispatchStatus}</if>
<if test="expReceiveUserId != null and expReceiveUserId != ''"> and exp_receive_user_id = #{expReceiveUserId}</if>
<!-- 数据范围过滤 -->
${params.dataScope}
</where>
</select>
@ -72,35 +98,40 @@
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="expId != null">exp_id,</if>
<if test="expCode != null">exp_code,</if>
<if test="expNumber != null">exp_number,</if>
<if test="expPqCode != null">exp_pq_code,</if>
<if test="expBidCode != null">exp_bid_code,</if>
<if test="expExpenditureMode != null and expExpenditureMode != ''">exp_expenditure_mode,</if>
<if test="expExpenditureMode != null">exp_expenditure_mode,</if>
<if test="expCustomerBm != null">exp_customer_bm,</if>
<if test="expCustomerName != null and expCustomerName != ''">exp_customer_name,</if>
<if test="expExpenditurePeople != null and expExpenditurePeople != ''">exp_expenditure_people,</if>
<if test="expProject != null and expProject != ''">exp_project,</if>
<if test="expReturnDate != null and expReturnDate != ''">exp_return_date,</if>
<if test="expExpenditureType != null and expExpenditureType != ''">exp_expenditure_type,</if>
<if test="expCustomerName != null">exp_customer_name,</if>
<if test="expExpenditurePeople != null">exp_expenditure_people,</if>
<if test="expProject != null">exp_project,</if>
<if test="expReturnDate != null">exp_return_date,</if>
<if test="expExpenditureType != null">exp_expenditure_type,</if>
<if test="expExpenditureAmount != null">exp_expenditure_amount,</if>
<if test="expBidArea != null">exp_bid_area,</if>
<if test="expExpenditureDate != null and expExpenditureDate != ''">exp_expenditure_date,</if>
<if test="expExpenditureDate != null">exp_expenditure_date,</if>
<if test="expExpenditureAmountUppercase != null">exp_expenditure_amount_uppercase,</if>
<if test="expStaffTureorfales != null and expStaffTureorfales != ''">exp_staff_tureorfales,</if>
<if test="expBackOffice != null and expBackOffice != ''">exp_back_office,</if>
<if test="expStaffTureorfales != null">exp_staff_tureorfales,</if>
<if test="expBackOffice != null">exp_back_office,</if>
<if test="expSalesmanCode != null">exp_salesman_code,</if>
<if test="expSalesmanBm != null">exp_salesman_bm,</if>
<if test="expSalesmanName != null and expSalesmanName != ''">exp_salesman_name,</if>
<if test="expSalesmanName != null">exp_salesman_name,</if>
<if test="expSalesmanDeptId != null">exp_salesman_dept_id,</if>
<if test="expSalesmanDeptName != null">exp_salesman_dept_name,</if>
<if test="expDispatchStatus != null">exp_dispatch_status,</if>
<if test="expAccountName != null and expAccountName != ''">exp_account_name,</if>
<if test="expAccountNumber != null and expAccountNumber != ''">exp_account_number,</if>
<if test="expDepositBank != null and expDepositBank != ''">exp_deposit_bank,</if>
<if test="expAccountName != null">exp_account_name,</if>
<if test="expAccountNumber != null">exp_account_number,</if>
<if test="expDepositBank != null">exp_deposit_bank,</if>
<if test="expLineNumberAndOthres != null">exp_line_number_and_othres,</if>
<if test="expRequestRemark != null">exp_request_remark,</if>
<if test="expReturnRemark != null">exp_return_remark,</if>
<if test="expApprovalStatus != null">exp_approval_status,</if>
<if test="expOaApprovalStatus != null">exp_oa_approval_status,</if>
<if test="expOaRemark != null">exp_oa_remark,</if>
<if test="expReceiveUserId != null">exp_receive_user_id,</if>
<if test="expReceiveUserNickName != null">exp_receive_user_nick_name,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
@ -109,35 +140,40 @@
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="expId != null">#{expId},</if>
<if test="expCode != null">#{expCode},</if>
<if test="expNumber != null">#{expNumber},</if>
<if test="expPqCode != null">#{expPqCode},</if>
<if test="expBidCode != null">#{expBidCode},</if>
<if test="expExpenditureMode != null and expExpenditureMode != ''">#{expExpenditureMode},</if>
<if test="expExpenditureMode != null">#{expExpenditureMode},</if>
<if test="expCustomerBm != null">#{expCustomerBm},</if>
<if test="expCustomerName != null and expCustomerName != ''">#{expCustomerName},</if>
<if test="expExpenditurePeople != null and expExpenditurePeople != ''">#{expExpenditurePeople},</if>
<if test="expProject != null and expProject != ''">#{expProject},</if>
<if test="expReturnDate != null and expReturnDate != ''">#{expReturnDate},</if>
<if test="expExpenditureType != null and expExpenditureType != ''">#{expExpenditureType},</if>
<if test="expCustomerName != null">#{expCustomerName},</if>
<if test="expExpenditurePeople != null">#{expExpenditurePeople},</if>
<if test="expProject != null">#{expProject},</if>
<if test="expReturnDate != null">#{expReturnDate},</if>
<if test="expExpenditureType != null">#{expExpenditureType},</if>
<if test="expExpenditureAmount != null">#{expExpenditureAmount},</if>
<if test="expBidArea != null">#{expBidArea},</if>
<if test="expExpenditureDate != null and expExpenditureDate != ''">#{expExpenditureDate},</if>
<if test="expExpenditureDate != null">#{expExpenditureDate},</if>
<if test="expExpenditureAmountUppercase != null">#{expExpenditureAmountUppercase},</if>
<if test="expStaffTureorfales != null and expStaffTureorfales != ''">#{expStaffTureorfales},</if>
<if test="expBackOffice != null and expBackOffice != ''">#{expBackOffice},</if>
<if test="expStaffTureorfales != null">#{expStaffTureorfales},</if>
<if test="expBackOffice != null">#{expBackOffice},</if>
<if test="expSalesmanCode != null">#{expSalesmanCode},</if>
<if test="expSalesmanBm != null">#{expSalesmanBm},</if>
<if test="expSalesmanName != null and expSalesmanName != ''">#{expSalesmanName},</if>
<if test="expSalesmanName != null">#{expSalesmanName},</if>
<if test="expSalesmanDeptId != null">#{expSalesmanDeptId},</if>
<if test="expSalesmanDeptName != null">#{expSalesmanDeptName},</if>
<if test="expDispatchStatus != null">#{expDispatchStatus},</if>
<if test="expAccountName != null and expAccountName != ''">#{expAccountName},</if>
<if test="expAccountNumber != null and expAccountNumber != ''">#{expAccountNumber},</if>
<if test="expDepositBank != null and expDepositBank != ''">#{expDepositBank},</if>
<if test="expAccountName != null">#{expAccountName},</if>
<if test="expAccountNumber != null">#{expAccountNumber},</if>
<if test="expDepositBank != null">#{expDepositBank},</if>
<if test="expLineNumberAndOthres != null">#{expLineNumberAndOthres},</if>
<if test="expRequestRemark != null">#{expRequestRemark},</if>
<if test="expReturnRemark != null">#{expReturnRemark},</if>
<if test="expApprovalStatus != null">#{expApprovalStatus},</if>
<if test="expOaApprovalStatus != null">#{expOaApprovalStatus},</if>
<if test="expOaRemark != null">#{expOaRemark},</if>
<if test="expReceiveUserId != null">#{expReceiveUserId},</if>
<if test="expReceiveUserNickName != null">#{expReceiveUserNickName},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
@ -150,34 +186,39 @@
<trim prefix="SET" suffixOverrides=",">
<if test="expCode != null">exp_code = #{expCode},</if>
<if test="expPqCode != null">exp_pq_code = #{expPqCode},</if>
<if test="expNumber != null">exp_number = #{expNumber},</if>
<if test="expBidCode != null">exp_bid_code = #{expBidCode},</if>
<if test="expExpenditureMode != null and expExpenditureMode != ''">exp_expenditure_mode = #{expExpenditureMode},</if>
<if test="expExpenditureMode != null">exp_expenditure_mode = #{expExpenditureMode},</if>
<if test="expCustomerBm != null">exp_customer_bm = #{expCustomerBm},</if>
<if test="expCustomerName != null and expCustomerName != ''">exp_customer_name = #{expCustomerName},</if>
<if test="expExpenditurePeople != null and expExpenditurePeople != ''">exp_expenditure_people = #{expExpenditurePeople},</if>
<if test="expProject != null and expProject != ''">exp_project = #{expProject},</if>
<if test="expReturnDate != null and expReturnDate != ''">exp_return_date = #{expReturnDate},</if>
<if test="expExpenditureType != null and expExpenditureType != ''">exp_expenditure_type = #{expExpenditureType},</if>
<if test="expCustomerName != null">exp_customer_name = #{expCustomerName},</if>
<if test="expExpenditurePeople != null">exp_expenditure_people = #{expExpenditurePeople},</if>
<if test="expProject != null">exp_project = #{expProject},</if>
<if test="expReturnDate != null">exp_return_date = #{expReturnDate},</if>
<if test="expExpenditureType != null">exp_expenditure_type = #{expExpenditureType},</if>
<if test="expExpenditureAmount != null">exp_expenditure_amount = #{expExpenditureAmount},</if>
<if test="expBidArea != null">exp_bid_area = #{expBidArea},</if>
<if test="expExpenditureDate != null and expExpenditureDate != ''">exp_expenditure_date = #{expExpenditureDate},</if>
<if test="expExpenditureDate != null">exp_expenditure_date = #{expExpenditureDate},</if>
<if test="expExpenditureAmountUppercase != null">exp_expenditure_amount_uppercase = #{expExpenditureAmountUppercase},</if>
<if test="expStaffTureorfales != null and expStaffTureorfales != ''">exp_staff_tureorfales = #{expStaffTureorfales},</if>
<if test="expBackOffice != null and expBackOffice != ''">exp_back_office = #{expBackOffice},</if>
<if test="expStaffTureorfales != null">exp_staff_tureorfales = #{expStaffTureorfales},</if>
<if test="expBackOffice != null">exp_back_office = #{expBackOffice},</if>
<if test="expSalesmanCode != null">exp_salesman_code = #{expSalesmanCode},</if>
<if test="expSalesmanBm != null">exp_salesman_bm = #{expSalesmanBm},</if>
<if test="expSalesmanName != null and expSalesmanName != ''">exp_salesman_name = #{expSalesmanName},</if>
<if test="expSalesmanName != null">exp_salesman_name = #{expSalesmanName},</if>
<if test="expSalesmanDeptId != null">exp_salesman_dept_id = #{expSalesmanDeptId},</if>
<if test="expSalesmanDeptName != null">exp_salesman_dept_name = #{expSalesmanDeptName},</if>
<if test="expDispatchStatus != null">exp_dispatch_status = #{expDispatchStatus},</if>
<if test="expAccountName != null and expAccountName != ''">exp_account_name = #{expAccountName},</if>
<if test="expAccountNumber != null and expAccountNumber != ''">exp_account_number = #{expAccountNumber},</if>
<if test="expDepositBank != null and expDepositBank != ''">exp_deposit_bank = #{expDepositBank},</if>
<if test="expAccountName != null">exp_account_name = #{expAccountName},</if>
<if test="expAccountNumber != null">exp_account_number = #{expAccountNumber},</if>
<if test="expDepositBank != null">exp_deposit_bank = #{expDepositBank},</if>
<if test="expLineNumberAndOthres != null">exp_line_number_and_othres = #{expLineNumberAndOthres},</if>
<if test="expRequestRemark != null">exp_request_remark = #{expRequestRemark},</if>
<if test="expReturnRemark != null">exp_return_remark = #{expReturnRemark},</if>
<if test="expApprovalStatus != null">exp_approval_status = #{expApprovalStatus},</if>
<if test="expOaApprovalStatus != null">exp_oa_approval_status = #{expOaApprovalStatus},</if>
<if test="expOaRemark != null">exp_oa_remark = #{expOaRemark},</if>
<if test="expReceiveUserId != null">exp_receive_user_id = #{expReceiveUserId},</if>
<if test="expReceiveUserNickName != null">exp_receive_user_nick_name = #{expReceiveUserNickName},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
@ -196,4 +237,11 @@
#{expId}
</foreach>
</delete>
<select id="getCode" resultType="String" statementType="CALLABLE">
{call GetSerialNo(#{type,mode=IN,jdbcType=VARCHAR})}
</select>
<select id="getCodeExp" resultType="String" statementType="CALLABLE">
{call GetSerialNo_Business(#{type,mode=IN,jdbcType=VARCHAR})}
</select>
</mapper>

View File

@ -1,5 +1,5 @@
#Generated by Maven
#Mon Aug 12 08:02:44 CST 2024
#Mon Aug 12 14:13:27 CST 2024
version=3.8.7
groupId=com.ruoyi
artifactId=ruoyi-system

View File

@ -1,5 +1,14 @@
import request from '@/utils/request'
// 分派
export function expAssign(query) {
return request({
url: '/expenses/expenses/expAssign',
method: 'post',
data: query
})
}
// 查询费用支出列表
export function listExpenses(query) {
return request({
@ -42,3 +51,12 @@ export function delExpenses(expId) {
method: 'delete'
})
}
//提交投标办按钮
export function commitExp(data) {
return request({
url: '/expenses/expenses/commitExp',
method: 'post',
data: data
})
}

View File

@ -0,0 +1,51 @@
/*
数字转中文
@number {Integer} 形如123的数字
@return {String} 返回转换成的形如 一百二十三 的字符串
*/
export function numberToChinese (number) {
/*单位*/
const units = '个拾佰仟萬@#%億^&~';
/*字符*/
const chars = '零壹贰叁肆伍陆柒捌玖';
const a = (number + '').split(''), s = [], t = this;
if (a.length > 12) {
throw new Error('too big');
} else {
for (var i = 0, j = a.length - 1; i <= j; i++) {
if (j == 1 || j == 5 || j == 9) {//两位数 处理特殊的 1*
if (i == 0) {
if (a[i] != '1') s.push(chars.charAt(a[i]));
} else {
s.push(chars.charAt(a[i]));
}
} else {
s.push(chars.charAt(a[i]));
}
if (i != j) {
s.push(units.charAt(j - i));
}
}
}
//return s;
return s.join('').replace(/零([十百千万亿@#%^&~])/g, function (m, d, b) {//优先处理 零百 零千 等
b = units.indexOf(d);
if (b != -1) {
if (d == '亿') return d;
if (d == '万') return d;
if (a[j - b] == '0') return '零';
}
return '';
}).replace(/零+/g, '零').replace(/零([万亿])/g, function (m, b) {// 零百 零千处理后 可能出现 零零相连的 再处理结尾为零的
return b;
}).replace(/亿[万千百]/g, '亿').replace(/[零]$/, '').replace(/[@#%^&~]/g, function (m) {
return {'@': '十', '#': '百', '%': '千', '^': '十', '&': '百', '~': '千'}[m];
}).replace(/([亿万])([一-九])/g, function (m, d, b, c) {
c = units.indexOf(d);
if (c != -1) {
if (a[j - c] == '0') return d + '零' + b;
}
return m;
});
}

View File

@ -565,8 +565,8 @@ export default {
},
watch: {
/** 授权期限日期控件 清空null转“ ” */
"form.doaAuthorizationDuration"(newVal1) {
if (newVal1 == null) {
"form.doaAuthorizationDuration"(newVal) {
if (newVal == null) {
this.form.doaAuthorizationDuration = "";
}
}

View File

@ -248,7 +248,8 @@
let result = [];
uns.forEach(item => {
if(this.allUserMap.has(item)) {
var json = {};
const json = {};
json.userId = this.allUserMap.get(item).userId || '';
json.userName = this.allUserMap.get(item).userName || '';
json.nickName = this.allUserMap.get(item).nickName || '';
json.sapUserBm = this.allUserMap.get(item).sapUserBm || '';

View File

@ -3,7 +3,7 @@
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="150px">
<el-form-item label="支出编号" prop="expCode">
<el-input
v-model="queryParams.expCode"
v-model="queryParams.expNumber"
placeholder="请输入支出编号"
clearable
@keyup.enter.native="handleQuery"
@ -139,6 +139,28 @@
v-hasPermi="['expenses:expenses:export']"
>导出</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-user-solid"
size="mini"
:disabled="multiple"
@click="handleAssign"
v-hasPermi="['expenses:expenses:assign']"
>分派</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-user-solid"
size="mini"
:disabled="single"
@click="handleChangeRecord"
v-hasPermi="['expenses:expenses:changeRecord']"
>变更记录</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
@ -146,7 +168,12 @@
<el-table height="100%" v-loading="loading" :data="expensesList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="费用支出id" align="center" prop="expId" v-if="false"/>
<el-table-column fixed label="费用支出单号" align="center" prop="expCode" width="200px"/>
<el-table-column fixed label="费用支出单号" align="center" prop="expCode" width="200px">
<template slot-scope="scope">
<el-link :underline="false" type="primary" @click="handleUpdate(scope.row)">{{scope.row.expCode}}</el-link>
</template>
</el-table-column>
<el-table-column fixed label="费用支出编号" align="center" prop="expNumber" width="120px"/>
<el-table-column fixed label="提交状态" align="center" prop="expApprovalStatus">
<template slot-scope="scope">
<dict-tag :options="dict.type.exp_approval_status" :value="scope.row.expApprovalStatus"/>
@ -182,6 +209,7 @@
<dict-tag :options="dict.type.exp_dispatch_status" :value="scope.row.expDispatchStatus"/>
</template>
</el-table-column>
<el-table-column label="分派接收人" align="center" prop="expReceiveUserNickName" width="100px"/>
<el-table-column label="OA审批状态" align="center" prop="expOaApprovalStatus" width="100px">
<template slot-scope="scope">
<dict-tag :options="dict.type.exp_oa_approval_status" :value="scope.row.expOaApprovalStatus"/>
@ -212,12 +240,22 @@
<dict-tag :options="dict.type.exp_approval_status" :value="this.form.expApprovalStatus"/>
</el-form-item>
</el-col>
<el-col :span="4" v->
<el-form-item label="分派状态" prop="expDispatchStatus">
<dict-tag :options="dict.type.exp_dispatch_status" :value="this.form.expDispatchStatus"/>
</el-form-item>
</el-col>
<el-col :span="4">
<el-form-item label="OA审批状态" prop="expOaApprovalStatus">
<dict-tag :options="dict.type.exp_oa_approval_status" :value="this.form.expOaApprovalStatus"/>
</el-form-item>
</el-col>
</el-row>
<el-divider content-position="left" class="customer_divider_text">基本信息</el-divider>
<el-row :gutter="8">
<el-col :span="8">
<el-form-item label="支出编号" prop="expCode">
<el-form-item label="费用支出单号" prop="expCode">
<el-input v-model="form.expCode" placeholder="系统自动生成" :disabled="true"/>
</el-form-item>
</el-col>
@ -226,6 +264,9 @@
<el-input v-model="form.expSalesmanCode" v-if="false"/>
<el-input v-model="form.expSalesmanBm" v-if="false"/>
<el-input v-model="form.expSalesmanName" :disabled="true" style="width: 60%"/>
<span v-if="checkRole(['BID','BID_BSZZY','BID_ZHGLY'])">
<el-button type="primary" icon="el-icon-search" style="margin-left: 10px" @click="openPeopleSelectYwy" size="mini" v-if="!ywyDis&&!tbDis"></el-button>
</span>
</el-form-item>
</el-col>
<el-col :span="8">
@ -238,17 +279,17 @@
<el-row :gutter="8">
<el-col :span="8">
<el-form-item label="资格预审编号" prop="expPqCode">
<el-input v-model="form.expPqCode" placeholder="请输入资格预审编号" />
<el-input v-model="form.expPqCode" placeholder="请输入资格预审编号" :disabled="ywyDis||tbDis"/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="标书编号" prop="expBidCode">
<el-input v-model="form.expBidCode" placeholder="请输入标书编号" />
<el-input v-model="form.expBidCode" placeholder="请输入标书编号" :disabled="ywyDis||tbDis"/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="支出形式" prop="expExpenditureMode">
<el-select v-model="form.expExpenditureMode" placeholder="请选择支出形式">
<el-select v-model="form.expExpenditureMode" placeholder="请选择支出形式" :disabled="ywyDis||tbDis">
<el-option
v-for="dict in dict.type.exp_expenditure_mode"
:key="dict.value"
@ -263,12 +304,14 @@
<el-col :span="8">
<el-form-item label="客户名称" prop="expCustomerName">
<el-input v-model="form.expCustomerBm" v-if="false"/>
<el-input v-model="form.expCustomerName" placeholder="请输入客户名称" :disabled="true"/>
<el-input v-model="form.expCustomerName" placeholder="请输入客户名称" :disabled="true">
<el-button slot="append" icon="el-icon-search" @click="openCustomer" v-if="!ywyDis&&!tbDis"></el-button>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="支出人" prop="expExpenditurePeople">
<el-select v-model="form.expExpenditurePeople" placeholder="请选择支出人">
<el-select v-model="form.expExpenditurePeople" placeholder="请选择支出人" :disabled="ywyDis||tbDis">
<el-option
v-for="dict in dict.type.exp_expenditure_people"
:key="dict.value"
@ -280,7 +323,7 @@
</el-col>
<el-col :span="8">
<el-form-item label="支出类别" prop="expExpenditureType">
<el-select v-model="form.expExpenditureType" placeholder="请选择支出类别">
<el-select v-model="form.expExpenditureType" placeholder="请选择支出类别" :disabled="ywyDis||tbDis">
<el-option
v-for="dict in dict.type.exp_expenditure_type"
:key="dict.value"
@ -294,19 +337,19 @@
<el-row :gutter="8">
<el-col :span="24">
<el-form-item label="项目名称" prop="expProject">
<el-input type="textarea" autosize v-model="form.expProject" placeholder="请输入项目名称" />
<el-input type="textarea" autosize v-model="form.expProject" placeholder="请输入项目名称" :disabled="ywyDis||tbDis"/>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="8">
<el-col :span="8">
<el-form-item label="支出金额" prop="expExpenditureAmount">
<el-input v-model="form.expExpenditureAmount" placeholder="请输入支出金额" />
<el-input v-model="form.expExpenditureAmount" placeholder="请输入支出金额" :disabled="ywyDis||tbDis"/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="投标区域" prop="expBidArea">
<el-select v-model="form.expBidArea" placeholder="请选择投标区域">
<el-select v-model="form.expBidArea" placeholder="请选择投标区域" :disabled="ywyDis||tbDis">
<el-option
v-for="dict in dict.type.exp_bid_area"
:key="dict.value"
@ -322,7 +365,8 @@
v-model="form.expExpenditureDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择支出时间">
placeholder="请选择支出时间"
:disabled="ywyDis||tbDis">
</el-date-picker>
</el-form-item>
</el-col>
@ -335,19 +379,19 @@
</el-col>
<el-col :span="8">
<el-form-item label="是否有内勤" prop="expStaffTureorfales">
<el-select v-model="form.expStaffTureorfales" placeholder="请选择是否有内勤">
<el-select v-model="form.expStaffTureorfales" placeholder="请选择是否有内勤" :disabled="ywyDis||tbDis">
<el-option
v-for="dict in dict.type.exp_staff_tureorfales"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
@click.native="expStaffTureorfalesChange(dict.value)"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="选择内勤" prop="expBackOffice">
<el-input v-model="form.expBackOffice" placeholder="请输入选择内勤" />
<el-input v-model="form.expBackOffice" placeholder="请输入内勤" :disabled="ywyDis||tbDis"/>
</el-form-item>
</el-col>
</el-row>
@ -356,52 +400,70 @@
<el-row :gutter="8">
<el-col :span="8">
<el-form-item label="账户名" prop="expAccountName">
<el-input v-model="form.expAccountName" placeholder="请输入账户名" />
<el-input v-model="form.expAccountName" placeholder="请输入账户名" :disabled="ywyDis||tbDis"/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="账号" prop="expAccountNumber">
<el-input v-model="form.expAccountNumber" placeholder="请输入账号" />
<el-input v-model="form.expAccountNumber" placeholder="请输入账号" :disabled="ywyDis||tbDis"/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="开户银行" prop="expDepositBank">
<el-input v-model="form.expDepositBank" placeholder="请输入开户银行" />
<el-input v-model="form.expDepositBank" placeholder="请输入开户银行" :disabled="ywyDis||tbDis"/>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="8">
<el-col :span="8">
<el-form-item label="行号及其他" prop="expLineNumberAndOthres">
<el-input v-model="form.expLineNumberAndOthres" placeholder="请输入行号及其他" />
<el-input v-model="form.expLineNumberAndOthres" placeholder="请输入行号及其他" :disabled="ywyDis||tbDis"/>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="8">
<el-col :span="24">
<el-form-item label="申请说明" prop="expRequestRemark">
<el-input type="textarea" autosize v-model="form.expRequestRemark" placeholder="请输入申请说明" />
<el-input type="textarea" autosize v-model="form.expRequestRemark" placeholder="请输入申请说明" :disabled="ywyDis||tbDis"/>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="8">
<el-col :span="24">
<el-form-item label="OA反馈说明" prop="expReturnRemark">
<el-input type="textarea" autosize v-model="form.expReturnRemark" placeholder="OA反馈说明" />
<el-col :span="24" v-if="this.form.expApprovalStatus != '0' && this.form.expApprovalStatus != null">
<el-form-item label="驳回原因" prop="expReturnRemark">
<el-input type="textarea" autosize v-model="form.expReturnRemark" placeholder="投标办填写" :disabled="checkRole(['SALES_MAN']) || (this.form.expApprovalStatus == '2' || this.form.expApprovalStatus == '3')"/>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="8">
<el-col :span="24" v-if="this.form.expApprovalStatus != '0' && this.form.expApprovalStatus != null">
<el-form-item label="OA反馈说明" prop="expOaRemark">
<el-input type="textarea" autosize v-model="form.expOaRemark" :disabled="true"/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
<!-- 业务员提交保存-->
<span v-hasPermi="['expenses:expenses:save']"><el-button @click="saveForm" v-if="this.form.expApprovalStatus == '0' || this.form.expApprovalStatus == null || this.form.expApprovalStatus == '3'"> </el-button></span>
<span style="margin-left: 10px" v-hasPermi="['expenses:expenses:commit']"><el-button type="primary" plain @click="commitForm" v-if="this.form.expApprovalStatus == '0' || this.form.expApprovalStatus == null || this.form.expApprovalStatus == '3'"> </el-button></span>
</div>
<!--选择业务员对话框-->
<PeopleSelect v-if="checkRole(['BID','BID_BSZZY','BID_ZHGLY'])" ref="peopleSelect" :type="'single'" :isCheck="true" :open="peopleOpenSelectYwy" @cancel="peopleOpenSelectYwy=false" @submit="submitPeopleSelectYwy"></PeopleSelect>
<!-- 客户选择对话框-->
<CustomerSelect ref="customerSelect" :open="customerOpen" @submit="submitCustomer" @cancel="customerOpen=false"></CustomerSelect>
</el-dialog>
<!--费用支出信息变更记录对话框-->
<el-dialog :title="changeRecordTitle" :visible.sync="openChangeRecord" v-if="openChangeRecord" width="1200px" append-to-body>
<ChangeRecord :codeProp="codeProp"></ChangeRecord>
</el-dialog>
<!--投标信息分派选择人员对话框-->
<PeopleSelect v-if="checkRole(['BID'])" ref="peopleSelect" :type="'single'" :isCheck="true" :open="peopleOpenFp" @cancel="peopleOpenFp=false" @submit="submitPeopleFp"></PeopleSelect>
</div>
</template>
<style>
@ -423,12 +485,17 @@
</style>
<script>
import { getToken } from "@/utils/auth";
import { numberToChinese } from "@/utils/number-cn";
import { checkPermi,checkRole } from '@/utils/permission';//
import { listExpenses, getExpenses, delExpenses, addExpenses, updateExpenses } from "@/api/expenses/expenses";
import { listExpenses, getExpenses, delExpenses, addExpenses, updateExpenses, commitExp, expAssign } from "@/api/expenses/expenses";
/** 弹窗放大、拖拽 */
import elDragDialog from "@/directive/dialog/dragDialog";
/** 导入变更记录组件 */
import ChangeRecord from "@/views/components/Tools/ChangeRecord/index.vue";
/** 导入选人组件 */
import PeopleSelect from "@/views/components/Tools/PeopleSelect/index.vue";
/** 导入客户选择组件 */
import CustomerSelect from "@/views/components/Tools/CustomerSelect/index.vue";
export default {
name: "Expenses",
directives: {
@ -436,6 +503,8 @@ export default {
},
components: {
//
'CustomerSelect': CustomerSelect,
'PeopleSelect': PeopleSelect,
'ChangeRecord':ChangeRecord
},
dicts: ['exp_expenditure_type', 'exp_oa_approval_status', 'exp_staff_tureorfales', 'exp_expenditure_mode', 'exp_dispatch_status', 'exp_approval_status', 'exp_bid_area', 'exp_expenditure_people'],
@ -459,13 +528,15 @@ export default {
title: "",
//
open: false,
//
customerOpen: false,
// OA
daterangeExpExpenditureDate: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
expCode: null,
expNumber: null,
expExpenditureMode: null,
expCustomerName: null,
expProject: null,
@ -499,7 +570,12 @@ export default {
{ required: true, message: "支出类别不能为空", trigger: "change" }
],
expExpenditureAmount: [
{ required: true, message: "支出金额不能为空", trigger: "blur" }
{ required: true, message: "支出金额不能为空", trigger: "blur" },
{
pattern: /^(([1-9]{1}\d{0,9})|(0{1}))(\.\d{1,2})?$/,
message: "请输入合法的支出金额,最多两位小数",
trigger: "blur"
}
],
expExpenditureDate: [
{ required: true, message: "支出时间不能为空", trigger: "blur" }
@ -507,9 +583,6 @@ export default {
expStaffTureorfales: [
{ required: true, message: "是否有内勤不能为空", trigger: "change" }
],
expBackOffice: [
{ required: true, message: "选择内勤不能为空", trigger: "blur" }
],
expSalesmanName: [
{ required: true, message: "业务员不能为空", trigger: "blur" }
],
@ -523,17 +596,45 @@ export default {
{ required: true, message: "开户银行不能为空", trigger: "blur" }
],
},
expOtherRule: {
expBackOffice: [{ required: true, message: '选择内勤不能为空', trigger: 'blur' }],
},
//
changeRecordTitle: "",
openChangeRecord:false,
codeProp: "",
//
peopleOpenFp:false, //
peopleOpenSelectYwy:false, //
selectedPeoples:[],
//
ywyDis: false,
//
tbDis: false,
};
},
watch:{
"form.expExpenditureAmount":{
handler(newval,oldval){
if(newval){
this.form.expExpenditureAmountUppercase=numberToChinese(newval);
}
},
immediate:true
}
},
created() {
this.getList();
},
methods: {
/** 权限控制 */
checkPermi,
checkRole,
/** 查询费用支出列表 */
getList() {
this.loading = true;
@ -585,6 +686,7 @@ export default {
expLineNumberAndOthres: null,
expRequestRemark: null,
expReturnRemark: null,
expOaRemark: null,
expApprovalStatus: null,
expOaApprovalStatus: null,
createBy: null,
@ -630,12 +732,24 @@ export default {
const expId = row.expId || this.ids
getExpenses(expId).then(response => {
this.form = response.data;
this.expStaffTureorfalesChange(this.form.expStaffTureorfales);
this.open = true;
this.title = "费用支出";
const expApprovalStatus = this.form.expApprovalStatus;
const expOaApprovalStatus = this.form.expOaApprovalStatus;
//
if(checkRole(['SALES_MAN'])&&("1"==expApprovalStatus||"2"==expApprovalStatus)){
this.ywyDis = true;
}
// OA
if(checkRole(['BID','BID_BSZZY','BID_ZHGLY'])&&"1"==expOaApprovalStatus){
this.tbDis = true;
}
});
},
/** 提交按钮 */
submitForm() {
/** 保存修改按钮 */
saveForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.expId != null) {
@ -647,11 +761,23 @@ export default {
} else {
addExpenses(this.form).then(response => {
this.$modal.msgSuccess("创建成功");
const row = {'expId':response.data.expId}
this.handleUpdate(row);
});
}
}
});
},
/** 提交投标办按钮 */
commitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
commitExp(this.form).then(response => {
this.$modal.msgSuccess("提交成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
@ -669,7 +795,78 @@ export default {
this.download('expenses/expenses/export', {
...this.queryParams
}, `expenses_${new Date().getTime()}.xlsx`)
},
/** 打开变更记录 */
handleChangeRecord(){
const expId = this.ids
this.openChangeRecord=true;
this.changeRecordTitle="变更记录";
this.codeProp = expId[0];
},
/** 是否选择内勤事件 */
expStaffTureorfalesChange(val) {
this.form.expBackOffice = (val != '0'?'':this.form.expBackOffice)
if (val == '0') {
this.rules = { ...this.rules, expBackOffice: this.expOtherRule.expBackOffice };
} else {
this.$delete(this.rules, 'expBackOffice');
}
},
/** 分派按钮 */
handleAssign() {
this.openPeopleSelect();
},
/** 打开客户选择弹窗 */
openCustomer(){
this.customerOpen=true;
},
/** 客户选择确定按钮事件 */
submitCustomer(customer){
this.form.expCustomerBm = customer.value;
this.form.expCustomerName = customer.label;
this.customerOpen=false;
},
/*********************************打开选人弹窗-分派*****************************************/
//-
openPeopleSelect(){
this.peopleOpenFp=true;
},
//- submitPeople(nikeNamelist) submitPeople(peopleList,nikeNamelist)
submitPeopleFp(peopleList,nickNameList){
const expReceiveUserId = nickNameList[0].userId;
const expIds = this.ids;
const param = {'expReceiveUserId':expReceiveUserId,'expIds':expIds}
expAssign(param).then(response => {
this.$modal.msgSuccess("分派成功");
this.peopleOpenFp=false;
this.getList();
})
},
//-
openPeopleSelectYwy(){
this.peopleOpenSelectYwy=true;
},
//-
submitPeopleSelectYwy(peopleList,nickNameList){
this.selectedPeoples = this.selectedPeoples.concat(nickNameList)
this.selectedPeoples = this.unique(this.selectedPeoples)
this.form.expSalesmanName = this.selectedPeoples[0].nickName;
this.form.expSalesmanBm = this.selectedPeoples[0].sapUserBm;
this.form.expSalesmanCode = this.selectedPeoples[0].userName;
this.peopleOpenSelectYwy=false;
},
//
unique(arr) {
const res = new Map();
return arr.filter((arr) => !res.has(arr.userName) && res.set(arr.userName, 1));
},
/*********************************打开选人弹窗-分派*****************************************/
}
};
</script>