
21 changed files with 617 additions and 114 deletions
@ -0,0 +1,111 @@ |
|||
package com.yxt.anrui.fin.api.kingdee; |
|||
|
|||
import com.alibaba.fastjson.annotation.JSONField; |
|||
import com.alibaba.fastjson.annotation.JSONType; |
|||
|
|||
import java.util.List; |
|||
|
|||
@JSONType(orders={"Creator","NeedUpDateFields","NeedReturnFields","IsDeleteEntry","SubSystemId", |
|||
"IsVerifyBaseDataField","IsEntryBatchFill","ValidateFlag","NumberSearch","InterationFlags","Model"}) |
|||
public class Data { |
|||
@JSONField(name = "Creator") |
|||
private String Creator; |
|||
@JSONField(name = "NeedUpDateFields") |
|||
private List<String> NeedUpDateFields; |
|||
@JSONField(name = "NeedReturnFields") |
|||
private List<String> NeedReturnFields; |
|||
@JSONField(name = "IsDeleteEntry") |
|||
private String IsDeleteEntry; |
|||
@JSONField(name = "SubSystemId") |
|||
private String SubSystemId; |
|||
@JSONField(name = "IsVerifyBaseDataField") |
|||
private String IsVerifyBaseDataField; |
|||
@JSONField(name = "IsEntryBatchFill") |
|||
private String IsEntryBatchFill; |
|||
@JSONField(name = "ValidateFlag") |
|||
private String ValidateFlag; |
|||
@JSONField(name = "NumberSearch") |
|||
private String NumberSearch; |
|||
@JSONField(name = "InterationFlags") |
|||
private String InterationFlags; |
|||
/* @JSONField(name = "Model") |
|||
private Model Model;*/ |
|||
public void setCreator(String Creator) { |
|||
this.Creator = Creator; |
|||
} |
|||
public String getCreator() { |
|||
return Creator; |
|||
} |
|||
|
|||
public void setNeedUpDateFields(List<String> NeedUpDateFields) { |
|||
this.NeedUpDateFields = NeedUpDateFields; |
|||
} |
|||
public List<String> getNeedUpDateFields() { |
|||
return NeedUpDateFields; |
|||
} |
|||
|
|||
public void setNeedReturnFields(List<String> NeedReturnFields) { |
|||
this.NeedReturnFields = NeedReturnFields; |
|||
} |
|||
public List<String> getNeedReturnFields() { |
|||
return NeedReturnFields; |
|||
} |
|||
|
|||
public void setIsDeleteEntry(String IsDeleteEntry) { |
|||
this.IsDeleteEntry = IsDeleteEntry; |
|||
} |
|||
public String getIsDeleteEntry() { |
|||
return IsDeleteEntry; |
|||
} |
|||
|
|||
public void setSubSystemId(String SubSystemId) { |
|||
this.SubSystemId = SubSystemId; |
|||
} |
|||
public String getSubSystemId() { |
|||
return SubSystemId; |
|||
} |
|||
|
|||
public void setIsVerifyBaseDataField(String IsVerifyBaseDataField) { |
|||
this.IsVerifyBaseDataField = IsVerifyBaseDataField; |
|||
} |
|||
public String getIsVerifyBaseDataField() { |
|||
return IsVerifyBaseDataField; |
|||
} |
|||
|
|||
public void setIsEntryBatchFill(String IsEntryBatchFill) { |
|||
this.IsEntryBatchFill = IsEntryBatchFill; |
|||
} |
|||
public String getIsEntryBatchFill() { |
|||
return IsEntryBatchFill; |
|||
} |
|||
|
|||
public void setValidateFlag(String ValidateFlag) { |
|||
this.ValidateFlag = ValidateFlag; |
|||
} |
|||
public String getValidateFlag() { |
|||
return ValidateFlag; |
|||
} |
|||
|
|||
public void setNumberSearch(String NumberSearch) { |
|||
this.NumberSearch = NumberSearch; |
|||
} |
|||
public String getNumberSearch() { |
|||
return NumberSearch; |
|||
} |
|||
|
|||
public void setInterationFlags(String InterationFlags) { |
|||
this.InterationFlags = InterationFlags; |
|||
} |
|||
public String getInterationFlags() { |
|||
return InterationFlags; |
|||
} |
|||
|
|||
/*public void setModel(Model model) { |
|||
this.Model = model; |
|||
} |
|||
public Model getModel() { |
|||
return Model; |
|||
}*/ |
|||
|
|||
} |
|||
|
@ -0,0 +1,29 @@ |
|||
package com.yxt.anrui.fin.api.kingdee; |
|||
|
|||
import com.yxt.anrui.fin.api.kingdee.entrybill.EntryBillDto; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import io.swagger.annotations.Api; |
|||
import io.swagger.annotations.ApiOperation; |
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
import org.springframework.web.bind.annotation.PostMapping; |
|||
import org.springframework.web.bind.annotation.RequestBody; |
|||
|
|||
/** |
|||
* 财务模块调用金蝶保存业务单据的接口 |
|||
*/ |
|||
@Api(tags = "财务模块调用金蝶保存业务单据的接口") |
|||
@FeignClient( |
|||
contextId = "anrui-fin-FinKingDeeFeign", |
|||
name = "anrui-kingdee", |
|||
path = "v1/finKingDee", |
|||
fallback =FinKingDeeFeignFallBack.class |
|||
) |
|||
public interface FinKingDeeFeign { |
|||
/** |
|||
* 入账保存应付单的接口 |
|||
* @return |
|||
*/ |
|||
@ApiOperation("入账保存应付单的接口") |
|||
@PostMapping("/draftEntryBill") |
|||
ResultBean draftEntryBill(@RequestBody EntryBillDto entryBillDto); |
|||
} |
@ -0,0 +1,12 @@ |
|||
package com.yxt.anrui.fin.api.kingdee; |
|||
|
|||
import com.yxt.anrui.fin.api.kingdee.entrybill.EntryBillDto; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
|
|||
public class FinKingDeeFeignFallBack |
|||
implements FinKingDeeFeign{ |
|||
@Override |
|||
public ResultBean draftEntryBill(EntryBillDto entryBillDto) { |
|||
return null; |
|||
} |
|||
} |
@ -0,0 +1,116 @@ |
|||
package com.yxt.anrui.fin.api.kingdee.entrybill; |
|||
|
|||
import com.yxt.common.core.dto.Dto; |
|||
import io.swagger.annotations.ApiModelProperty; |
|||
import lombok.Data; |
|||
|
|||
import javax.validation.constraints.NotBlank; |
|||
import javax.validation.constraints.Pattern; |
|||
import java.math.BigDecimal; |
|||
import java.util.List; |
|||
|
|||
@Data |
|||
public class EntryBillDto { |
|||
|
|||
@ApiModelProperty("车辆入账单sid") |
|||
private String sid; |
|||
|
|||
@ApiModelProperty("用户sid") |
|||
@NotBlank(message = "用户sid不能为空") |
|||
private String userSid; |
|||
|
|||
@ApiModelProperty("申请编号") |
|||
@NotBlank(message = "申请编号不能为空") |
|||
private String applicationCode; |
|||
|
|||
@ApiModelProperty("申请人sid") |
|||
@NotBlank(message = "申请人不能为空") |
|||
private String applicationSid; |
|||
|
|||
@ApiModelProperty("申请人名称") |
|||
@NotBlank(message = "申请人不能为空") |
|||
private String applicationName; |
|||
|
|||
@ApiModelProperty("申请日期") |
|||
@Pattern(regexp = "^(\\s*)|([1-9]\\d{3}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1]))$", message = "申请日期日期格式不正确") |
|||
private String applicationDate; |
|||
|
|||
@ApiModelProperty("采购订单sid") |
|||
@NotBlank(message = "采购订单不能为空") |
|||
private String vehicleOrderSid; |
|||
|
|||
@ApiModelProperty("采购订单编号") |
|||
@NotBlank(message = "采购订单编号不能为空") |
|||
private String purchaseOrderNo; |
|||
|
|||
@ApiModelProperty("车型sid ") |
|||
@NotBlank(message = "车型不能为空") |
|||
private String modelSid; |
|||
|
|||
@ApiModelProperty("车型名称 ") |
|||
@NotBlank(message = "车型名称不能为空") |
|||
private String modelName; |
|||
|
|||
@ApiModelProperty("常用配置 ") |
|||
private String configName; |
|||
@ApiModelProperty("常用配置Sid") |
|||
private String configSid; |
|||
|
|||
@ApiModelProperty("厂家合同价") |
|||
private BigDecimal contractPrice; |
|||
@ApiModelProperty("其中上装价格") |
|||
private BigDecimal amongSzPrice; |
|||
@ApiModelProperty("上装价格计算依据") |
|||
private String szPriceCalBasis; |
|||
@ApiModelProperty("一次运费") |
|||
private BigDecimal onceFreight; |
|||
@ApiModelProperty("二次运费") |
|||
private BigDecimal secondaryFreight; |
|||
@ApiModelProperty("下浮比例") |
|||
private String lowerProportion; |
|||
@ApiModelProperty("下浮金额") |
|||
private BigDecimal lowerMoney; |
|||
@ApiModelProperty("下浮合计") |
|||
private BigDecimal lowerTotal; |
|||
@ApiModelProperty("下浮备注") |
|||
private String lowerRemarks; |
|||
@ApiModelProperty("厂家结算价") |
|||
private BigDecimal costPrice; |
|||
@ApiModelProperty("内部编码") |
|||
private String insideCode; |
|||
|
|||
@ApiModelProperty("厂家入库日期") |
|||
private String priceDate; |
|||
@ApiModelProperty("厂家发车日期") |
|||
private String departureDate; |
|||
|
|||
@ApiModelProperty("备注") |
|||
private String remarks; |
|||
|
|||
@ApiModelProperty("流程状态") |
|||
private String nodeState; |
|||
|
|||
@ApiModelProperty("车辆台数") |
|||
private String num; |
|||
|
|||
@ApiModelProperty("车辆列表") |
|||
private List<ScmApplyInboundVehicleDto> vehicleList; |
|||
|
|||
class ScmApplyInboundVehicleDto implements Dto { |
|||
|
|||
@ApiModelProperty("车辆信息sid") |
|||
private String sid; |
|||
|
|||
@ApiModelProperty("车辆入库单sid") |
|||
private String applySid; |
|||
|
|||
@ApiModelProperty("车型sid") |
|||
private String modelSid; |
|||
|
|||
@ApiModelProperty("车架号(VIN)") |
|||
private String vinNo; |
|||
|
|||
@ApiModelProperty("备注") |
|||
private String remarks; |
|||
} |
|||
} |
@ -0,0 +1,21 @@ |
|||
package com.yxt.anrui.fin.biz.kingdee; |
|||
|
|||
import com.yxt.anrui.fin.api.kingdee.FinKingDeeFeign; |
|||
import com.yxt.anrui.fin.api.kingdee.FinKingDeeFeignFallBack; |
|||
import com.yxt.anrui.fin.api.kingdee.entrybill.EntryBillDto; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import io.swagger.annotations.Api; |
|||
import org.springframework.web.bind.annotation.RequestMapping; |
|||
import org.springframework.web.bind.annotation.RestController; |
|||
|
|||
@Api(tags = "单据调用金蝶的保存接口") |
|||
@RestController("com.yxt.anrui.fin.biz.kingdee.FinKingDeeFeignRest") |
|||
@RequestMapping("/finKingDee") |
|||
public class FinKingDeeFeignRest implements FinKingDeeFeign { |
|||
|
|||
@Override |
|||
public ResultBean draftEntryBill(EntryBillDto entryBillDto) { |
|||
|
|||
return null; |
|||
} |
|||
} |
@ -0,0 +1,24 @@ |
|||
import request from '@/utils/request' |
|||
import qs from 'qs' |
|||
// 读取xml文件
|
|||
export function readXml (deployId) { |
|||
return request({ |
|||
url: '/portal/v1/flow/readXml/' + deployId, |
|||
method: 'get' |
|||
}) |
|||
} |
|||
// 读取image文件
|
|||
export function getFlowViewer (procInsId) { |
|||
return request({ |
|||
url: '/portal/v1/flow/flowViewer/' + procInsId, |
|||
method: 'get' |
|||
}) |
|||
} |
|||
// 任务流转记录
|
|||
export function flowRecord(query) { |
|||
return request({ |
|||
url: '/portal/v1/flow/task/flowRecord/' + query.procInsId + "/" + query.deployId, |
|||
method: 'get', |
|||
params: query |
|||
}) |
|||
} |
@ -0,0 +1,91 @@ |
|||
<template> |
|||
<div> |
|||
<!--流程流转记录--> |
|||
<el-card > |
|||
<el-col :span="24" > |
|||
<div > |
|||
<div style="width:50%;float:left; border:1px solid #000;"> |
|||
<span class="el-icon-picture-outline">流程图</span> |
|||
<flow :xmlData="xmlData" :taskData="taskData"></flow> |
|||
</div> |
|||
<div style="width:50%;;float:left; border:1px solid #000;" > |
|||
<el-timeline> |
|||
<el-timeline-item |
|||
v-for="(item,index ) in flowRecordList" |
|||
:key="index" |
|||
:icon="setIcon(item.finishTime)" |
|||
:color="setColor(item.finishTime)" |
|||
> |
|||
<p style="font-weight: 700">{{item.taskName}}</p> |
|||
<el-card :body-style="{ padding: '10px' }"> |
|||
<label v-if="item.assigneeName" style="font-weight: normal;margin-right: 30px;">实际办理: |
|||
{{item.assigneeName}} |
|||
<el-tag type="info" size="mini">{{item.deptName}}</el-tag> |
|||
</label> |
|||
<label v-if="item.candidate" |
|||
style="font-weight: normal;margin-right: 30px;">候选办理:{{item.candidate}}</label><br> |
|||
<label style="font-weight: normal">接收时间: </label><label style="color:#8a909c;font-weight: normal">{{item.createTime}}</label><br> |
|||
<label v-if="item.finishTime" style="font-weight: normal">办结时间: </label> |
|||
<label style="color:#8a909c;font-weight: normal">{{item.finishTime}}</label><br> |
|||
<label v-if="item.duration" style="font-weight: normal">耗时:</label> |
|||
<label style="color:#8a909c;font-weight: normal">{{item.duration}}</label> |
|||
<p v-if="item.comment"> |
|||
<el-tag type="success" v-if="item.comment.type === '1'"> {{item.comment.comment}}</el-tag> |
|||
<el-tag type="warning" v-if="item.comment.type === '2'"> {{item.comment.comment}}</el-tag> |
|||
<el-tag type="danger" v-if="item.comment.type === '3'"> {{item.comment.comment}}</el-tag> |
|||
<el-tag type="danger" v-if="item.comment.type === '7'"> {{item.comment.comment}}</el-tag> |
|||
<el-tag type="danger" v-if="item.comment.type === '6'"> {{item.comment.comment}}</el-tag> |
|||
</p> |
|||
</el-card> |
|||
</el-timeline-item> |
|||
</el-timeline> |
|||
</div> |
|||
</div> |
|||
</el-col> |
|||
</el-card> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import flow from "@C/flow/flow"; |
|||
export default { |
|||
name: "flowRecords", |
|||
components: { |
|||
flow |
|||
}, |
|||
props: { |
|||
xmlData: { |
|||
type: String, |
|||
default: '' |
|||
}, |
|||
taskData: { |
|||
type: Array, |
|||
default: () => [] |
|||
}, |
|||
flowRecordList: { |
|||
type: Array, |
|||
default: () => [] |
|||
} |
|||
}, |
|||
data() { |
|||
return {}; |
|||
}, |
|||
created() { |
|||
}, |
|||
methods:{ |
|||
setIcon(val) { |
|||
if (val) { |
|||
return "el-icon-check"; |
|||
} else { |
|||
return "el-icon-time"; |
|||
} |
|||
}, |
|||
setColor(val) { |
|||
if (val) { |
|||
return "#2bc418"; |
|||
} else { |
|||
return "#b3bdbb"; |
|||
} |
|||
} |
|||
} |
|||
}; |
|||
</script> |
@ -0,0 +1,73 @@ |
|||
<template> |
|||
<div> |
|||
<flow-records :xmlData="xmlData" :taskData="taskList" :flowRecordList="flowRecordList"></flow-records> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import flowRecords from "@C/flow/flowRecord"; |
|||
import {setStorage} from "@/utils/auth"; |
|||
import {getFlowViewer, readXml} from '@/api/flow/todo'; |
|||
import {flowRecord} from "@/api/workflow/finished"; |
|||
export default { |
|||
name: "flowRecordForBusiness", |
|||
components: { |
|||
flowRecords |
|||
}, |
|||
data() { |
|||
return { |
|||
taskList: [], |
|||
xmlData: "", |
|||
flowRecordList :[] |
|||
}; |
|||
}, |
|||
created() { |
|||
var one = window.location.href.indexOf('?data') + 6 |
|||
const data = window.location.href.substr(one) // url解码unescape()已从web中移除,尽量不使用 |
|||
const obj = JSON.parse(decodeURIComponent(data)) |
|||
this.obj = obj; |
|||
var token = obj.token;//getStorage(); |
|||
setStorage(token) |
|||
console.log(obj) |
|||
this.getFlowViewer(obj.procInsId) |
|||
this.getModelDetail(obj.deployId) |
|||
this.getFlowRecordList(obj.procInsId,obj.deployId) |
|||
window.parent.postMessage({ |
|||
cmd: 'returnHeight', |
|||
params: { |
|||
//告诉父级页面,子页面的弹框高度。 |
|||
code: 2, |
|||
data: 600 + 'px' |
|||
} |
|||
}, '*') |
|||
}, |
|||
methods:{ |
|||
/** xml 文件 */ |
|||
getModelDetail(deployId) { |
|||
// 发送请求,获取xml |
|||
readXml(deployId).then(res =>{ |
|||
this.xmlData = res.data |
|||
}) |
|||
}, |
|||
//已办环节的节点 |
|||
getFlowViewer(procInsId){ |
|||
getFlowViewer(procInsId).then(res =>{ |
|||
this.taskList = res.data |
|||
}) |
|||
}, |
|||
/** 流程流转记录 */ |
|||
getFlowRecordList(procInsId, deployId) { |
|||
const params = {procInsId: procInsId, deployId: deployId} |
|||
flowRecord(params).then(res => { |
|||
this.flowRecordList = res.data.flowList; |
|||
// 流程过程中不存在初始化表单 直接读取的流程变量中存储的表单值 |
|||
if (res.data.formData) { |
|||
this.formConf = res.data.formData; |
|||
this.formConfOpen = true |
|||
} |
|||
}).catch(res => { |
|||
this.getList(); |
|||
}) |
|||
} |
|||
} |
|||
}; |
|||
</script> |
Loading…
Reference in new issue