diff --git a/src/api/contract/contract.js b/src/api/contract/contract.js
index 92c9c44..b072edb 100644
--- a/src/api/contract/contract.js
+++ b/src/api/contract/contract.js
@@ -81,3 +81,22 @@ export function updateStatus(params,noloading = true){
noloading
})
}
+
+export function oaSelect(params,noloading = true){
+ return request({
+ method:'get',
+ url:'api/oa/flow/no-link-list',
+ params,
+ noloading
+ })
+}
+
+export function oaSave(data){
+ return request({
+ method:'post',
+ url:'api/oa/flow/save-foreign',
+ data
+ })
+}
+
+
diff --git a/src/components/PlanPicker/otherPlan.vue b/src/components/PlanPicker/otherPlan.vue
new file mode 100644
index 0000000..e9d46ce
--- /dev/null
+++ b/src/components/PlanPicker/otherPlan.vue
@@ -0,0 +1,378 @@
+
+
+
+
+
+
+ {
+ planSelect.year = e
+ getBudgets()
+ }"
+ >
+
+
+
+
+ {
+ planSelect.type = e[e.length - 1] || '';
+ getBudgets();
+ }"
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 取消
+ 确定
+
+
+
+
+
+
+
+
diff --git a/src/components/XyTable/index.vue b/src/components/XyTable/index.vue
index 5b57cfa..6d8ed8c 100644
--- a/src/components/XyTable/index.vue
+++ b/src/components/XyTable/index.vue
@@ -48,6 +48,11 @@ export default {
type:Function,
default:()=>{}
},
+ headerCellClassName:{
+ type:Function,
+ default:()=>{}
+ },
+
defaultExpandAll:{
type:Boolean,
default:true
@@ -154,7 +159,7 @@ export default {
mounted() {
},
render(h) {
- let {highlightCurrentRow,rowKey,expandRowKeys,selectChange,selectAllClick,summaryMethod,cellClick,btnWidth,selectClick,height,createIndexRow,tableStyle,treeProps,showSummary,showHeader,$scopedSlots,showIndex,defaultExpandAll,headerCellStyle,headerRowStyle,rowStyle,cellStyle,indent,tableHeight,tableItem,list,deleteClick,editorClick,rowClick,objectSpanMethod} = this
+ let {highlightCurrentRow,rowKey,expandRowKeys,selectChange,selectAllClick,summaryMethod,cellClick,btnWidth,selectClick,height,createIndexRow,tableStyle,treeProps,showSummary,showHeader,$scopedSlots,showIndex,defaultExpandAll,headerCellStyle,headerCellClassName,headerRowStyle,rowStyle,cellStyle,indent,tableHeight,tableItem,list,deleteClick,editorClick,rowClick,objectSpanMethod} = this
return (
{tableItem && tableItem.length > 0 ?
@@ -167,6 +172,7 @@ export default {
summary-method={summaryMethod}
header-row-style={headerRowStyle}
header-cell-style={headerCellStyle}
+ header-cell-class-name={headerCellClassName}
row-style={rowStyle}
cell-style={cellStyle}
indent={indent}
diff --git a/src/views/contract/components/oaLink.vue b/src/views/contract/components/oaLink.vue
new file mode 100644
index 0000000..2868689
--- /dev/null
+++ b/src/views/contract/components/oaLink.vue
@@ -0,0 +1,167 @@
+
+
+
+
+
+
+
+ 取消
+ 确定
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/contract/contractEdit.vue b/src/views/contract/contractEdit.vue
index bbbaf5e..784714b 100644
--- a/src/views/contract/contractEdit.vue
+++ b/src/views/contract/contractEdit.vue
@@ -199,6 +199,57 @@
/>
(无需采购流程,如水电邮寄费等)
+
+
+
+
+
+
+
+ {{weixiuSelection?weixiuSelection:'选择预算计划'}}
+
+ 选择预算计划
+
+
+
+
+
i.custom_model_id === row.flow_mod_id)
+ url += other[0]?.flow_id
break;
default:
url = `${process.env.VUE_APP_OUT_URL}/flow/list/todo`
@@ -1854,8 +1864,33 @@ export default {
}
},
- //采购流程
- async buyProcess(row,type=1) {
+ // 发起流程
+ createOa(row,flow){
+ console.log("oa",row,flow)
+ if(flow==='buyProcess'){
+
+ this.buyProcess(row,flow)
+ }else if(flow==='signProcess'){
+ this.signProcess(row,flow)
+ }else if(flow==='paying'){
+ this.paying(row,flow)
+ }
+ },
+ async buyProcess(row,flow) {
+ // flow 关联后的回调,打开哪种流程创建
+ // 获取可以 oa自动发起的流程
+ const hasMatch = this.flowConfig.some(item =>
+ item.custom_model_id === row.flow_model_id
+ );
+ console.log("row,flow",row,flow)
+ if(!flow){
+ if(true){
+ this.$refs.oaLink.row = row
+ this.$refs.oaLink.flow = 'buyProcess'
+ this.$refs.oaLink.isShowOaLinkModal = true
+ return
+ }
+ }
let baseInfo = {}
if (row.is_common_purchase) {
baseInfo = {
@@ -1888,14 +1923,25 @@ export default {
}
break;
}
- let url = `${process.env.VUE_APP_OUT_OLD}/#/flow/create?auth_token=${window.encodeURIComponent(getToken())}&module_name=oa&isSinglePage=1&module_id=${row.is_common_purchase ? 99 : row.flow_mod_id}&out_contract_id=${row.id}&default_json=${window.encodeURIComponent(JSON.stringify(baseInfo))}`;
+ let url = `${process.env.VUE_APP_OUT_OLD}/#/flow/create?auth_token=${window.encodeURIComponent(getToken())}&form_canal=contract&module_name=oa&isSinglePage=1&module_id=${row.is_common_purchase ? 99 : row.flow_mod_id}&out_contract_id=${row.id}&default_json=${window.encodeURIComponent(JSON.stringify(baseInfo))}`;
console.log('url',url)
this.oaUrl = url
this.isShowOaModal = true
},
//会签流程
- async signProcess(row) {
+ async signProcess(row,flow) {
// 72
+ const hasMatch = this.flowConfig.some(item =>
+ item.custom_model_id === row.flow_model_id
+ );
+ if(!flow){
+ if(hasMatch){
+ this.$refs.oaLink.row = row
+ this.$refs.oaLink.flow = 'signProcess'
+ this.$refs.oaLink.isShowOaLinkModal = true
+ return
+ }
+ }
this.setNowContract(row, "hetong");
let baseInfo = {
"hetongmingcheng": row?.name,
@@ -1905,14 +1951,25 @@ export default {
"jiafang": row.supply,
"xiangguanliucheng": [row.contract_flow_links?.find(i => i.custom_model_id === (row.is_common_purchase ? 99 : row.flow_mod_id))?.flow_id]
};
- let url = `${process.env.VUE_APP_OUT_OLD}/#/flow/create?auth_token=${window.encodeURIComponent(getToken())}&module_name=oa&isSinglePage=1&module_id=72&out_contract_id=${row.id}&default_json=${window.encodeURIComponent(JSON.stringify(baseInfo))}`;
+ let url = `${process.env.VUE_APP_OUT_OLD}/#/flow/create?auth_token=${window.encodeURIComponent(getToken())}&form_canal=contract&module_name=oa&isSinglePage=1&module_id=72&out_contract_id=${row.id}&default_json=${window.encodeURIComponent(JSON.stringify(baseInfo))}`;
this.oaUrl = url;
this.isShowOaModal = true;
},
//付款流程
- async paying(row) {
+ async paying(row,flow) {
// 75
+ const hasMatch = this.flowConfig.some(item =>
+ item.custom_model_id === row.flow_model_id
+ );
+ if(!flow){
+ if(hasMatch){
+ this.$refs.oaLink.row = row
+ this.$refs.oaLink.flow = 'paying'
+ this.$refs.oaLink.isShowOaLinkModal = true
+ return
+ }
+ }
let payments = [];
const actNumsTotal = () => {
return payments.reduce((pre,cur) => {
@@ -1946,16 +2003,16 @@ export default {
"contractno": contract?.number,
"guanlianliucheng": contract?.contract_flow_links?.map(i => i.flow_id)
};
- let url = `${process.env.VUE_APP_OUT_OLD}/#/flow/create?auth_token=${window.encodeURIComponent(getToken())}&module_name=oa&isSinglePage=1&module_id=75&out_away_id=${row.id}&default_json=${window.encodeURIComponent(JSON.stringify(baseInfo))}`;
+ let url = `${process.env.VUE_APP_OUT_OLD}/#/flow/create?auth_token=${window.encodeURIComponent(getToken())}&form_canal=contract&module_name=oa&isSinglePage=1&module_id=75&out_away_id=${row.id}&default_json=${window.encodeURIComponent(JSON.stringify(baseInfo))}`;
this.oaUrl = url;
this.isShowOaModal = true;
this.$router.push('/contract/paymentRegistrationList_1')
},
//请示流程
- async askProcess(row) {
+ async askProcess(row,flow) {
let res = await getOatoken();
- let url = `${process.env.VUE_APP_OUT_URL}/admin/flow/create/17?auth_token=${this.$store.getters.oa_token}&out_contract_id=${row.id}`;
+ let url = `${process.env.VUE_APP_OUT_URL}/admin/flow/create/17?auth_token=${this.$store.getters.oa_token}&form_canal=contract&out_contract_id=${row.id}`;
let askProcess = window.open(
url,
"askProcess",
diff --git a/src/views/finance/components/examineRegistration.vue b/src/views/finance/components/examineRegistration.vue
index 2058fbf..dfb0ad5 100644
--- a/src/views/finance/components/examineRegistration.vue
+++ b/src/views/finance/components/examineRegistration.vue
@@ -806,7 +806,7 @@ import {listdeptNoAuth} from "@/api/system/department";
if (res.list.data) {
this.plans = res.list.data.map(i => ({
use_money:0,
- // use_money: this.paymentRegistrationForm.applyMoney,
+ // use_money: this.paymentRegistrationForm.applyMoney?this.paymentRegistrationForm.actMoney:0,
...i
})).reduce((accumulator, current) => {
const duplicate = accumulator.find(item => item.id === current.id);
@@ -870,6 +870,7 @@ import {listdeptNoAuth} from "@/api/system/department";
toggleSelection(plans) {
if (plans) {
this.plans.filter(plan => {
+ console.log("this.plans",plans,this.plans,this.paymentRegistrationForm)
// if (plans.includes(plan.pid.toString())) {
// // plan.use_money = this.paymentRegistrationForm.plan[plans.indexOf(plan.pid)].use_money
// plan.use_money = this.paymentRegistrationForm.applyMoney
@@ -881,6 +882,8 @@ import {listdeptNoAuth} from "@/api/system/department";
if (plans.includes(plan.pid)) {
plan.use_money = this.paymentRegistrationForm.plan[plans.indexOf(plan.pid)].use_money
return true
+ }else{
+ plan.use_money = this.paymentRegistrationForm.actMoney
}
// plan.use_money = this.paymentRegistrationForm.applyMoney