提交 d2b4586a 编写于 作者: ibizdev's avatar ibizdev

ibiz4j 发布系统代码 [ ibiz-pay,支付]

上级 3b5f84da
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
"vue-amap": "^0.5.10", "vue-amap": "^0.5.10",
"vue-class-component": "^7.0.2", "vue-class-component": "^7.0.2",
"vue-grid-layout": "^2.3.7", "vue-grid-layout": "^2.3.7",
"vue-i18n": "^8.15.3", "vue-i18n": "^8.23.0",
"vue-property-decorator": "^9.1.2", "vue-property-decorator": "^9.1.2",
"vue-router": "^3.1.3", "vue-router": "^3.1.3",
"vuex": "^3.1.2", "vuex": "^3.1.2",
......
...@@ -229,9 +229,9 @@ export default class AppSpan extends Vue { ...@@ -229,9 +229,9 @@ export default class AppSpan extends Vue {
public dateFormat(){ public dateFormat(){
if(this.valueFormat){ if(this.valueFormat){
if(this.valueFormat.indexOf('%1$t') !== -1){ if(this.valueFormat.indexOf('%1$t') !== -1){
this.text= moment(this.data).format("YYYY-MM-DD HH:mm:ss"); this.text= moment(this.value).format("YYYY-MM-DD HH:mm:ss");
}else if(this.valueFormat.indexOf('%1$s') == -1){ }else if(this.valueFormat.indexOf('%1$s') == -1){
this.text= moment(this.data).format(this.valueFormat); this.text= moment(this.value).format(this.valueFormat);
}else{ }else{
this.text= this.value; this.text= this.value;
} }
......
...@@ -41,7 +41,7 @@ export default class TabExpViewEngine extends ViewEngine { ...@@ -41,7 +41,7 @@ export default class TabExpViewEngine extends ViewEngine {
if (!Object.is(_item.type, 'TABEXPPANEL')) { if (!Object.is(_item.type, 'TABEXPPANEL')) {
return; return;
} }
if(this.view.context && this.view.context[(this.keyPSDEField as string)]){ if(this.view.context && !this.view.context[(this.keyPSDEField as string)]){
return; return;
} }
this.setViewState2({ tag: _item.name, action: 'load', viewdata: this.view.context }); this.setViewState2({ tag: _item.name, action: 'load', viewdata: this.view.context });
......
...@@ -1303,25 +1303,122 @@ export default class PayOpenAccessEditViewBase extends Vue { ...@@ -1303,25 +1303,122 @@ export default class PayOpenAccessEditViewBase extends Vue {
* @memberof PayOpenAccessEditViewBase * @memberof PayOpenAccessEditViewBase
*/ */
public SaveAndStart(args: any[],contextJO?:any, params?: any, $event?: any, xData?: any,actionContext?:any,srfParentDeName?:string) { public SaveAndStart(args: any[],contextJO?:any, params?: any, $event?: any, xData?: any,actionContext?:any,srfParentDeName?:string) {
const _this: any = this; const that: any = this;
if (!xData || !(xData.wfstart instanceof Function)) { if (!xData || !(xData.wfstart instanceof Function)) {
return; return;
} }
xData.wfstart(args).then((response: any) => { let validateStatus: boolean = true;
if (!response || response.status !== 200) { if (xData.formValidateStatus && xData.formValidateStatus instanceof Function) {
return; validateStatus = xData.formValidateStatus();
}
if (!validateStatus) {
if(xData.errorMessages && xData.errorMessages.length > 0) {
let descMessage: string = '';
xData.errorMessages.forEach((message: any) => {
descMessage = descMessage + '<p>' + message.error + '<p>';
})
xData.$Notice.error({ title: (xData.$t('app.commonWords.wrong') as string), desc: descMessage });
} else {
xData.$Notice.error({ title: (xData.$t('app.commonWords.wrong') as string), desc: (xData.$t('app.formpage.valuecheckex') as string) });
} }
const { data: _data } = response; return;
if(window.parent){ }
window.parent.postMessage({ ..._data },'*'); const startWorkFlow: Function = (param: any, localdata: any) => {
xData.wfstart(args).then((response: any) => {
if (!response || response.status !== 200) {
return;
}
const { data: _data } = response;
that.closeView(_data);
});
}
const openStartView: Function = async (item: any, localdata: any) => {
if (item['wfversion']) {
const targetView: any = that.viewRefData ? that.viewRefData[`WFSTART@${item['wfversion']}`] : null;
if (targetView) {
const tempContext = Util.deepCopy(that.context);
const tempViewParams = { actionView: `WFSTART@${item['wfversion']}`, actionForm: item['process-form'] };
const container: Subject<any> = that.$appmodal.openModal(targetView, tempContext, tempViewParams);
container.subscribe((result: any) => {
if (!result || !Object.is(result.ret, 'OK')) {
return;
}
const tempSubmitData: any = Util.deepCopy(args[0]);
if (result.datas && result.datas[0]) {
const resultData: any = result.datas[0];
if (Object.keys(resultData).length > 0) {
let tempData: any = {};
Object.keys(resultData).forEach((key: any) => {
if (resultData[key] || (resultData[key] === 0) || (resultData[key] === false)) {
tempData[key] = resultData[key];
}
})
Object.assign(tempSubmitData, tempData);
}
}
startWorkFlow([tempSubmitData], localdata);
})
} else {
startWorkFlow(args, localdata);
}
} else {
startWorkFlow(args, localdata);
} }
if (_this.viewdata) { }
_this.$emit('viewdataschange', [{ ..._data }]); let localData: any;
_this.$emit('close'); const localContext = Util.deepCopy(that.context);
}else if (this.$tabPageExp) { const requestResult: Promise<any> = that.appEntityService.getStandWorkflow(localContext);
this.$tabPageExp.onClose(this.$route.fullPath); requestResult.then((response: any) => {
const { data: targetData, status } = response;
if (status !== 200 || targetData.length === 0) {
return;
} }
}); if (targetData && targetData.length > 1) {
const h = that.$createElement;
targetData.forEach((element: any) => {
Object.assign(element, { value: element.definitionkey, label: element.definitionname });
})
that.$msgbox({
title: '请选择流程版本',
message: h('i-select', {
key: Util.createUUID(),
props: {
value: localData,
placeholder: "请选择流程版本...",
transfer: true,
transferClassName: "start-workflow-select-wraper"
},
on: {
'on-change': ($event: any) => {
localData = { processDefinitionKey: $event };
}
}
}, targetData.map((item: any) => {
return h('i-option', {
key: item.value,
props: {
value: item.value,
label: item.label
}
})
})),
showCancelButton: true,
confirmButtonText: '确定',
cancelButtonText: '取消'
}).then((action: string) => {
if (Object.is(action, 'confirm') && localData && Object.keys(localData).length > 0) {
let targetItem: any = targetData.find((item: any) => {
return item.definitionkey === localData.processDefinitionKey;
})
openStartView(targetItem, localData);
}
})
} else {
localData = { processDefinitionKey: targetData[0]['definitionkey'] }
targetData[0]['process-view'] = "WFSTART@1";
openStartView(targetData[0], localData);
}
})
} }
/** /**
* 当前流程步骤 * 当前流程步骤
......
...@@ -1303,25 +1303,122 @@ export default class PayTradeEditViewBase extends Vue { ...@@ -1303,25 +1303,122 @@ export default class PayTradeEditViewBase extends Vue {
* @memberof PayTradeEditViewBase * @memberof PayTradeEditViewBase
*/ */
public SaveAndStart(args: any[],contextJO?:any, params?: any, $event?: any, xData?: any,actionContext?:any,srfParentDeName?:string) { public SaveAndStart(args: any[],contextJO?:any, params?: any, $event?: any, xData?: any,actionContext?:any,srfParentDeName?:string) {
const _this: any = this; const that: any = this;
if (!xData || !(xData.wfstart instanceof Function)) { if (!xData || !(xData.wfstart instanceof Function)) {
return; return;
} }
xData.wfstart(args).then((response: any) => { let validateStatus: boolean = true;
if (!response || response.status !== 200) { if (xData.formValidateStatus && xData.formValidateStatus instanceof Function) {
return; validateStatus = xData.formValidateStatus();
}
if (!validateStatus) {
if(xData.errorMessages && xData.errorMessages.length > 0) {
let descMessage: string = '';
xData.errorMessages.forEach((message: any) => {
descMessage = descMessage + '<p>' + message.error + '<p>';
})
xData.$Notice.error({ title: (xData.$t('app.commonWords.wrong') as string), desc: descMessage });
} else {
xData.$Notice.error({ title: (xData.$t('app.commonWords.wrong') as string), desc: (xData.$t('app.formpage.valuecheckex') as string) });
} }
const { data: _data } = response; return;
if(window.parent){ }
window.parent.postMessage({ ..._data },'*'); const startWorkFlow: Function = (param: any, localdata: any) => {
xData.wfstart(args).then((response: any) => {
if (!response || response.status !== 200) {
return;
}
const { data: _data } = response;
that.closeView(_data);
});
}
const openStartView: Function = async (item: any, localdata: any) => {
if (item['wfversion']) {
const targetView: any = that.viewRefData ? that.viewRefData[`WFSTART@${item['wfversion']}`] : null;
if (targetView) {
const tempContext = Util.deepCopy(that.context);
const tempViewParams = { actionView: `WFSTART@${item['wfversion']}`, actionForm: item['process-form'] };
const container: Subject<any> = that.$appmodal.openModal(targetView, tempContext, tempViewParams);
container.subscribe((result: any) => {
if (!result || !Object.is(result.ret, 'OK')) {
return;
}
const tempSubmitData: any = Util.deepCopy(args[0]);
if (result.datas && result.datas[0]) {
const resultData: any = result.datas[0];
if (Object.keys(resultData).length > 0) {
let tempData: any = {};
Object.keys(resultData).forEach((key: any) => {
if (resultData[key] || (resultData[key] === 0) || (resultData[key] === false)) {
tempData[key] = resultData[key];
}
})
Object.assign(tempSubmitData, tempData);
}
}
startWorkFlow([tempSubmitData], localdata);
})
} else {
startWorkFlow(args, localdata);
}
} else {
startWorkFlow(args, localdata);
} }
if (_this.viewdata) { }
_this.$emit('viewdataschange', [{ ..._data }]); let localData: any;
_this.$emit('close'); const localContext = Util.deepCopy(that.context);
}else if (this.$tabPageExp) { const requestResult: Promise<any> = that.appEntityService.getStandWorkflow(localContext);
this.$tabPageExp.onClose(this.$route.fullPath); requestResult.then((response: any) => {
const { data: targetData, status } = response;
if (status !== 200 || targetData.length === 0) {
return;
} }
}); if (targetData && targetData.length > 1) {
const h = that.$createElement;
targetData.forEach((element: any) => {
Object.assign(element, { value: element.definitionkey, label: element.definitionname });
})
that.$msgbox({
title: '请选择流程版本',
message: h('i-select', {
key: Util.createUUID(),
props: {
value: localData,
placeholder: "请选择流程版本...",
transfer: true,
transferClassName: "start-workflow-select-wraper"
},
on: {
'on-change': ($event: any) => {
localData = { processDefinitionKey: $event };
}
}
}, targetData.map((item: any) => {
return h('i-option', {
key: item.value,
props: {
value: item.value,
label: item.label
}
})
})),
showCancelButton: true,
confirmButtonText: '确定',
cancelButtonText: '取消'
}).then((action: string) => {
if (Object.is(action, 'confirm') && localData && Object.keys(localData).length > 0) {
let targetItem: any = targetData.find((item: any) => {
return item.definitionkey === localData.processDefinitionKey;
})
openStartView(targetItem, localData);
}
})
} else {
localData = { processDefinitionKey: targetData[0]['definitionkey'] }
targetData[0]['process-view'] = "WFSTART@1";
openStartView(targetData[0], localData);
}
})
} }
/** /**
* 当前流程步骤 * 当前流程步骤
......
...@@ -902,6 +902,23 @@ export default class EntityService { ...@@ -902,6 +902,23 @@ export default class EntityService {
} }
} }
/**
* 获取标准工作流版本信息
*
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @param {*} [localdata]
* @returns {Promise<any>}
* @memberof EntityService
*/
public async getStandWorkflow(context: any = {}, data: any = {}, isloading?: boolean): Promise<any> {
return Http.getInstance().get(
`/wfcore/${this.SYSTEMNAME}-app-${this.APPNAME}/${this.APPDENAME}/process-definitions`,
isloading,
);
}
/** /**
* WFGetProxyData接口方法 * WFGetProxyData接口方法
* *
......
...@@ -274,6 +274,11 @@ ...@@ -274,6 +274,11 @@
} }
} }
// 工作流流程版本选择
.start-workflow-select-wraper {
z-index: 3000 !important;
}
/*** END:多数据视图属性布局 ***/ /*** END:多数据视图属性布局 ***/
// 看板视图,卡片模式 // 看板视图,卡片模式
......
...@@ -103,6 +103,22 @@ export default class MainModel { ...@@ -103,6 +103,22 @@ export default class MainModel {
prop: 'srffrontuf', prop: 'srffrontuf',
dataType: 'TEXT', dataType: 'TEXT',
}, },
// 预置工作流数据字段
{
name: 'srfprocessdefinitionkey',
prop: 'srfprocessdefinitionkey',
dataType: 'TEXT'
},
{
name: 'srftaskdefinitionkey',
prop: 'srftaskdefinitionkey',
dataType: 'TEXT'
},
{
name: 'srftaskid',
prop: 'srftaskid',
dataType: 'TEXT'
}
] ]
} }
} }
......
...@@ -113,6 +113,22 @@ export default class MainModel { ...@@ -113,6 +113,22 @@ export default class MainModel {
prop: 'srffrontuf', prop: 'srffrontuf',
dataType: 'TEXT', dataType: 'TEXT',
}, },
// 预置工作流数据字段
{
name: 'srfprocessdefinitionkey',
prop: 'srfprocessdefinitionkey',
dataType: 'TEXT'
},
{
name: 'srftaskdefinitionkey',
prop: 'srftaskdefinitionkey',
dataType: 'TEXT'
},
{
name: 'srftaskid',
prop: 'srftaskid',
dataType: 'TEXT'
}
] ]
} }
} }
......
...@@ -9,6 +9,7 @@ ...@@ -9,6 +9,7 @@
"esModuleInterop": true, "esModuleInterop": true,
"experimentalDecorators": true, "experimentalDecorators": true,
"allowSyntheticDefaultImports": true, "allowSyntheticDefaultImports": true,
"skipLibCheck": true,
"sourceMap": true, "sourceMap": true,
"baseUrl": ".", "baseUrl": ".",
"types": [ "types": [
......
...@@ -31,6 +31,7 @@ import cn.ibizlab.core.pay.service.IPayOpenAccessService; ...@@ -31,6 +31,7 @@ import cn.ibizlab.core.pay.service.IPayOpenAccessService;
import cn.ibizlab.util.helper.CachedBeanCopier; import cn.ibizlab.util.helper.CachedBeanCopier;
import cn.ibizlab.util.helper.DEFieldCacheMap; import cn.ibizlab.util.helper.DEFieldCacheMap;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
...@@ -38,7 +39,6 @@ import cn.ibizlab.core.pay.mapper.PayOpenAccessMapper; ...@@ -38,7 +39,6 @@ import cn.ibizlab.core.pay.mapper.PayOpenAccessMapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.baomidou.mybatisplus.core.conditions.Wrapper; import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.alibaba.fastjson.JSONObject;
import org.springframework.util.StringUtils; import org.springframework.util.StringUtils;
/** /**
...@@ -223,6 +223,8 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P ...@@ -223,6 +223,8 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P
public IPayOpenAccessService getProxyService() { public IPayOpenAccessService getProxyService() {
return cn.ibizlab.util.security.SpringContextHolder.getBean(this.getClass()); return cn.ibizlab.util.security.SpringContextHolder.getBean(this.getClass());
} }
......
...@@ -31,6 +31,7 @@ import cn.ibizlab.core.pay.service.IPayTradeService; ...@@ -31,6 +31,7 @@ import cn.ibizlab.core.pay.service.IPayTradeService;
import cn.ibizlab.util.helper.CachedBeanCopier; import cn.ibizlab.util.helper.CachedBeanCopier;
import cn.ibizlab.util.helper.DEFieldCacheMap; import cn.ibizlab.util.helper.DEFieldCacheMap;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
...@@ -38,7 +39,6 @@ import cn.ibizlab.core.pay.mapper.PayTradeMapper; ...@@ -38,7 +39,6 @@ import cn.ibizlab.core.pay.mapper.PayTradeMapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.baomidou.mybatisplus.core.conditions.Wrapper; import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.alibaba.fastjson.JSONObject;
import org.springframework.util.StringUtils; import org.springframework.util.StringUtils;
/** /**
...@@ -256,6 +256,8 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i ...@@ -256,6 +256,8 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i
public IPayTradeService getProxyService() { public IPayTradeService getProxyService() {
return cn.ibizlab.util.security.SpringContextHolder.getBean(this.getClass()); return cn.ibizlab.util.security.SpringContextHolder.getBean(this.getClass());
} }
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<!--输出实体[PAY_OPEN_ACCESS]数据结构 --> <!--输出实体[PAY_OPEN_ACCESS]数据结构 -->
<changeSet author="a_A_5d9d78509" id="tab-pay_open_access-11-1"> <changeSet author="root" id="tab-pay_open_access-11-1">
<createTable tableName="IBZOPENACCESS"> <createTable tableName="IBZOPENACCESS">
<column name="ACCESSID" remarks="" type="VARCHAR(100)"> <column name="ACCESSID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_PAY_OPEN_ACCESS_ACCESSID"/> <constraints primaryKey="true" primaryKeyName="PK_PAY_OPEN_ACCESS_ACCESSID"/>
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
<!--输出实体[PAY_TRADE]数据结构 --> <!--输出实体[PAY_TRADE]数据结构 -->
<changeSet author="a_A_5d9d78509" id="tab-pay_trade-11-2"> <changeSet author="root" id="tab-pay_trade-11-2">
<createTable tableName="IBZPAYTRADE"> <createTable tableName="IBZPAYTRADE">
<column name="SUBJECT" remarks="" type="VARCHAR(100)"> <column name="SUBJECT" remarks="" type="VARCHAR(100)">
</column> </column>
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册