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

ibiz4j 发布系统代码

上级 e6164e98
## v7.0.0-alpha.19 [2020-9-13]
### Bug修复
修复表单动态隐藏和权限控制冲突问题
修复向导面板上一步去除表单校验逻辑
修复行为逻辑和附加后逻辑共同使用异常问题
修复树导航数据变化刷新当前节点问题
### 功能新增及优化
#### 模板
新增首页统一待办组件
新增实体工作流动态导航表格视图批量提交流程数据
新增菜单、工具栏、表单分组按钮、表单按钮、表格操作列单机模式支持
新增挂载外部配置文件
新增支持静态代码表样式表
新增增加树视图节点、日历项上下文菜单权限支持
新增支持表格导航、列表导航、卡片导航支持快速分组
新增部门人员选择器组件、文件上传(磁盘)组件、图片上传(磁盘)组件、动态表单组件
新增列表、数据视图回到顶部功能
新增表格分组、列表分组、数据视图分组功能
新增数据选择编辑器自填模式文本属性、值属性支持
新增附加逻辑外部逻辑支持
新增应用主题配置
优化项布局面板功能
优化列表样式
优化计数器支持
优化表格行编辑新建行追加在第一行
#### 基础文件
修复表单动态隐藏和权限控制冲突问题
修复嵌入视图组件初始化导航数据和抛值问题
修复app-format-data组件时间格式化转化异常
优化工作流审批组件
优化穿梭框组件样式
优化app-span精度逻辑
优化计数器处理逻辑
优化快速分组代码表抛值逻辑
优化debug组件和头部菜单增加开发环境配置
新增统一待办组件
新增实体工作流动态导航表格视图批量提交数据
新增菜单、工具栏、表单分组按钮、表单按钮、表格操作列单机模式支持
新增挂载外部配置文件
新增支持静态代码表样式表
新增部门人员选择器组件、文件上传(磁盘)组件、图片上传(磁盘)组件、动态表单组件
新增应用主题配置
## v7.0.0-alpha.18 [2020-8-23] ## v7.0.0-alpha.18 [2020-8-23]
### Bug修复 ### Bug修复
......
...@@ -86,6 +86,12 @@ import AppLockScren from './components/app-lock-scren/app-lock-scren.vue' ...@@ -86,6 +86,12 @@ import AppLockScren from './components/app-lock-scren/app-lock-scren.vue'
import ActionTimeline from './components/action-timeline/action-timeline.vue' import ActionTimeline from './components/action-timeline/action-timeline.vue'
import CronEditor from './components/cron-editor/cron-editor.vue' import CronEditor from './components/cron-editor/cron-editor.vue'
import AppMessagePopover from './components/app-message-popover/app-message-popover.vue' import AppMessagePopover from './components/app-message-popover/app-message-popover.vue'
import AppPanelField from './components/app-panel-field/app-panel-field.vue'
import AppPanelItem from './components/app-panel-item/app-panel-item.vue'
import AppDepartmentPersonnel from './components/app-department-personnel/app-department-personnel.vue'
import DiskFileUpload from './components/disk-file-upload/disk-file-upload.vue'
import AvueCustomForm from './components/avue-custom-form/avue-custom-form.vue'
import DiskImageUpload from './components/disk-image-upload/disk-image-upload.vue'
// 全局挂载UI实体服务注册中心 // 全局挂载UI实体服务注册中心
window['uiServiceRegister'] = uiServiceRegister; window['uiServiceRegister'] = uiServiceRegister;
...@@ -111,6 +117,9 @@ export const AppComponents = { ...@@ -111,6 +117,9 @@ export const AppComponents = {
v.prototype.$verify = Verify; v.prototype.$verify = Verify;
v.prototype.$viewTool = ViewTool; v.prototype.$viewTool = ViewTool;
v.prototype.$uiActionTool = UIActionTool; v.prototype.$uiActionTool = UIActionTool;
v.component('app-department-personnel',AppDepartmentPersonnel);
v.component('app-panel-item',AppPanelItem);
v.component('app-panel-field',AppPanelField);
v.component('app-full-scren',AppFullScren); v.component('app-full-scren',AppFullScren);
v.component('app-lock-scren',AppLockScren); v.component('app-lock-scren',AppLockScren);
v.component('input-box', InputBox); v.component('input-box', InputBox);
...@@ -186,5 +195,8 @@ export const AppComponents = { ...@@ -186,5 +195,8 @@ export const AppComponents = {
v.component('action-timeline', ActionTimeline); v.component('action-timeline', ActionTimeline);
v.component('cron-editor', CronEditor); v.component('cron-editor', CronEditor);
v.component('app-message-popover', AppMessagePopover); v.component('app-message-popover', AppMessagePopover);
v.component('disk-file-upload', DiskFileUpload);
v.component('avue-custom-form', AvueCustomForm);
v.component('disk-image-upload', DiskImageUpload);
}, },
}; };
\ No newline at end of file
...@@ -112,6 +112,9 @@ export default class AuthService { ...@@ -112,6 +112,9 @@ export default class AuthService {
* @memberof AuthService * @memberof AuthService
*/ */
public getMenusPermission(item: any): boolean { public getMenusPermission(item: any): boolean {
if(!this.$store.getters['authresource/getEnablePermissionValid']) {
return true;
}
return this.$store.getters['authresource/getAuthMenu'](item); return this.$store.getters['authresource/getAuthMenu'](item);
} }
...@@ -123,6 +126,9 @@ export default class AuthService { ...@@ -123,6 +126,9 @@ export default class AuthService {
* @memberof AuthService * @memberof AuthService
*/ */
public getResourcePermission(tag: any): boolean { public getResourcePermission(tag: any): boolean {
if(!this.$store.getters['authresource/getEnablePermissionValid']) {
return true;
}
return this.$store.getters['authresource/getResourceData'](tag); return this.$store.getters['authresource/getResourceData'](tag);
} }
......
...@@ -100,7 +100,6 @@ export default class AppActionBar extends Vue { ...@@ -100,7 +100,6 @@ export default class AppActionBar extends Vue {
* @memberof AppActionBar * @memberof AppActionBar
*/ */
public calcActionItemAuthState(data:any,ActionModel:any,UIService:any){ public calcActionItemAuthState(data:any,ActionModel:any,UIService:any){
if(Environment.enablePermissionValid){
for (const key in ActionModel) { for (const key in ActionModel) {
if (!ActionModel.hasOwnProperty(key)) { if (!ActionModel.hasOwnProperty(key)) {
return; return;
...@@ -134,7 +133,6 @@ export default class AppActionBar extends Vue { ...@@ -134,7 +133,6 @@ export default class AppActionBar extends Vue {
} }
} }
} }
}
/** /**
* 组件销毁 * 组件销毁
......
...@@ -18,4 +18,7 @@ ...@@ -18,4 +18,7 @@
font-family: '微软雅黑','黑体','宋体'; font-family: '微软雅黑','黑体','宋体';
font-size: 16px; font-size: 16px;
} }
.progress {
margin-top: -15px;
}
} }
\ No newline at end of file
<template> <template>
<div class="app-data-upload-view"> <div class="app-data-upload-view" v-loading.fullscreen="isUploading" element-loading-background="rgba(57, 57, 57, 0.2)">
<el-row style="margin-top:24px" :gutter="20"> <el-row style="margin-top:24px" :gutter="20">
<el-col :span="4"> <el-col :span="4">
<el-button type="primary" @click="handleUpLoad">{{$t('components.appDataUploadView.selectfile')}}</el-button> <el-button type="primary" @click="handleUpLoad">{{$t('components.appDataUploadView.selectfile')}}</el-button>
...@@ -13,6 +13,7 @@ ...@@ -13,6 +13,7 @@
</el-col> </el-col>
</el-row> </el-row>
<el-divider></el-divider> <el-divider></el-divider>
<el-progress class="progress" v-show="isUploading" :text-inside="true" :stroke-width="14" :percentage="uploadProgress"></el-progress>
<el-row style="height:480px;padding: 0px 12px;"> <el-row style="height:480px;padding: 0px 12px;">
<div class="data-info-content" > <div class="data-info-content" >
<template v-if="importDataArray.length >0 && isUploading === false"> <template v-if="importDataArray.length >0 && isUploading === false">
...@@ -50,6 +51,7 @@ import XLSX from 'xlsx'; ...@@ -50,6 +51,7 @@ import XLSX from 'xlsx';
import CodeListService from "@service/app/codelist-service"; import CodeListService from "@service/app/codelist-service";
import EntityService from '@/service/entity-service'; import EntityService from '@/service/entity-service';
import { Vue, Component, Prop, Provide, Emit, Watch } from 'vue-property-decorator'; import { Vue, Component, Prop, Provide, Emit, Watch } from 'vue-property-decorator';
import { Environment } from '@/environments/environment';
@Component({ @Component({
}) })
...@@ -192,6 +194,22 @@ export default class AppDataUploadView extends Vue { ...@@ -192,6 +194,22 @@ export default class AppDataUploadView extends Vue {
*/ */
public allFieldMap:Map<string,any> = new Map(); public allFieldMap:Map<string,any> = new Map();
/**
* 上传服务器数据切片数
*
* @type {number}
* @memberof AppDataUploadView
*/
public sliceUploadCnt: number = Environment.sliceUploadCnt;
/**
* 上传服务器进度条百分比
*
* @type {number}
* @memberof AppDataUploadView
*/
public uploadProgress: number = 0;
/** /**
* 视图参数变化 * 视图参数变化
* *
...@@ -282,10 +300,29 @@ export default class AppDataUploadView extends Vue { ...@@ -282,10 +300,29 @@ export default class AppDataUploadView extends Vue {
this.transformData(this.importDataArray,tempDataArray); this.transformData(this.importDataArray,tempDataArray);
this.hasImported = true; this.hasImported = true;
this.isUploading = true; this.isUploading = true;
this.uploadProgress = 0;
this.importDataArray = []; this.importDataArray = [];
this.sliceUploadService(tempDataArray, 0);
}
/**
* 数据切片上传
*
* @memberof AppDataUploadView
*/
public sliceUploadService(dataArray: Array<any>, cnt: number) {
if(cnt > dataArray.length) {
this.isUploading = false;
this.uploadProgress = 100;
return;
}
let sliceArray: Array<any> = [];
if(dataArray) {
sliceArray = dataArray.slice(cnt, cnt+this.sliceUploadCnt);
}
try{ try{
this.entityService.getService(this.viewparams.serviceName).then((service:any) =>{ this.entityService.getService(this.viewparams.serviceName).then((service:any) =>{
service.ImportData(this.viewdata,{name:this.importId,importData:tempDataArray}).then((res:any) =>{ service.ImportData(this.viewdata,{name:this.importId,importData:sliceArray}).then((res:any) =>{
const result:any = res.data; const result:any = res.data;
if(result && result.rst !== 0){ if(result && result.rst !== 0){
this.promptInfo = (this.$t('components.appDataUploadView.importfailed') as string); this.promptInfo = (this.$t('components.appDataUploadView.importfailed') as string);
...@@ -294,7 +331,8 @@ export default class AppDataUploadView extends Vue { ...@@ -294,7 +331,8 @@ export default class AppDataUploadView extends Vue {
} }
this.importSuccessData = result.data; this.importSuccessData = result.data;
this.promptInfo = (this.$t('components.appDataUploadView.completed') as string); this.promptInfo = (this.$t('components.appDataUploadView.completed') as string);
this.isUploading = false; this.uploadProgress = Number((cnt / dataArray.length * 100).toFixed(2));
this.sliceUploadService(dataArray, cnt + this.sliceUploadCnt);
}).catch((error:any) =>{ }).catch((error:any) =>{
this.isUploading = false; this.isUploading = false;
this.promptInfo = (this.$t('components.appDataUploadView.importfailed') as string); this.promptInfo = (this.$t('components.appDataUploadView.importfailed') as string);
...@@ -311,7 +349,6 @@ export default class AppDataUploadView extends Vue { ...@@ -311,7 +349,6 @@ export default class AppDataUploadView extends Vue {
console.error(error); console.error(error);
}; };
} }
/** /**
* 导出excel * 导出excel
* *
......
<template> <template>
<div class="app-debug-actions"> <div class="app-debug-actions" v-if="isShow">
<div class="actions"> <div class="actions">
<button-group vertical> <button-group vertical>
<i-button :title="$t('components.appDebugActions.button')" :type="sdc.isShowTool ? 'warning' : 'info'" ghost @click="() => sdc.showToolChange()" :icon="sdc.isShowTool ? 'ios-bug' : 'ios-bug-outline'" ></i-button> <i-button :title="$t('components.appDebugActions.button')" :type="sdc.isShowTool ? 'warning' : 'info'" ghost @click="() => sdc.showToolChange()" :icon="sdc.isShowTool ? 'ios-bug' : 'ios-bug-outline'" ></i-button>
...@@ -25,6 +25,14 @@ import { Environment } from '@/environments/environment'; ...@@ -25,6 +25,14 @@ import { Environment } from '@/environments/environment';
}) })
export default class AppDebugActions extends Vue { export default class AppDebugActions extends Vue {
/**
* 是否显示
*
* @type {boolean}
* @memberof AppDebugActions
*/
public isShow:boolean = Environment.devMode;
/** /**
* 配置平台操作控制器 * 配置平台操作控制器
* *
......
.app-department-personnel{
position: relative;
.ivu-select-selection{
position: relative;
padding: 0;
.ivu-select-selected-value{
padding-left: 15px;
font-size: 13px;
}
.ivu-tag.ivu-tag-checked{
top: 1px;
font-size: 12px;
height: 24px;
line-height: 22px;
margin: 2px 0px 2px 6px;
padding: 0 3px 0 8px;
background-color: #f4f4f5;
border-color: #e9e9eb;
color: #909399;
.ivu-tag-text{
padding: 0 8px 0 0;
}
}
.ivu-icon.ivu-icon-ios-close{
position: absolute;
width: 10px;
line-height: 10px;
height: 10px;
top: 6px;
margin-left: 8px;
font-size: 4px;
color: #909399;
background-color: #c0c4cc;
border-radius: 50%;
}
.ivu-icon.ivu-icon-ios-close:hover{
color: #fff;
background-color: #909399;
}
.ivu-icon-ios-close:before {
position: absolute;
left: -1px;
}
}
.el-icon-search{
position: absolute;
top: 10px;
right: 27px;
color: #c0c4cc;
}
}
\ No newline at end of file
...@@ -158,7 +158,6 @@ export default class AppFormGroup extends Vue { ...@@ -158,7 +158,6 @@ export default class AppFormGroup extends Vue {
* @memberof AppFormGroup * @memberof AppFormGroup
*/ */
public calcActionItemAuthState(data:any,ActionModel:any,UIService:any){ public calcActionItemAuthState(data:any,ActionModel:any,UIService:any){
if(Environment.enablePermissionValid){
for (const key in ActionModel) { for (const key in ActionModel) {
if (!ActionModel.hasOwnProperty(key)) { if (!ActionModel.hasOwnProperty(key)) {
return; return;
...@@ -192,7 +191,6 @@ export default class AppFormGroup extends Vue { ...@@ -192,7 +191,6 @@ export default class AppFormGroup extends Vue {
} }
} }
} }
}
/** /**
* 是否为管理容器 * 是否为管理容器
......
...@@ -72,10 +72,14 @@ export default class AppFormatData extends Vue { ...@@ -72,10 +72,14 @@ export default class AppFormatData extends Vue {
return result; return result;
} }
} else if (this.format){ } else if (this.format){
let date: any = moment(this.data);
if(!date._isValid) {
return this.data;
}
if(this.format.indexOf('%1$t') !== -1){ if(this.format.indexOf('%1$t') !== -1){
return moment(this.data).format("YYYY-MM-DD HH:mm:ss"); return date.format("YYYY-MM-DD HH:mm:ss");
}else{ }else{
return moment(this.data).format(this.format); return date.format(this.format);
} }
}else{ }else{
return this.data; return this.data;
......
...@@ -176,7 +176,12 @@ export default class AppGroupPicker extends Vue { ...@@ -176,7 +176,12 @@ export default class AppGroupPicker extends Vue {
*/ */
public loadTree() { public loadTree() {
let orgid = this.viewParam.filtervalue; let orgid = this.viewParam.filtervalue;
let tempTreeUrl:string = this.treeurl.replace('${orgid}',orgid); let tempTreeUrl: string = '';
if(this.viewParam.selectType && Object.is(this.viewParam.selectType,"dept")){
tempTreeUrl = this.treeurl.replace('{deptId}',orgid);
}else{
tempTreeUrl = this.treeurl.replace('${orgid}',orgid);
}
let get = Http.getInstance().get(tempTreeUrl, true); let get = Http.getInstance().get(tempTreeUrl, true);
get.then((response: any) => { get.then((response: any) => {
if(response.status === 200) { if(response.status === 200) {
...@@ -194,7 +199,12 @@ export default class AppGroupPicker extends Vue { ...@@ -194,7 +199,12 @@ export default class AppGroupPicker extends Vue {
* @memberof AppGroupPicker * @memberof AppGroupPicker
*/ */
public loadGroupData(key: string) { public loadGroupData(key: string) {
let tempUrl = this.url.replace('${selected-orgid}',key); let tempUrl: string = '';
if(this.viewParam.selectType && Object.is(this.viewParam.selectType,"dept")){
tempUrl = this.url.replace('{deptId}',key);
}else{
tempUrl = this.url.replace('${selected-orgid}',key);
}
let get = Http.getInstance().get(tempUrl, true); let get = Http.getInstance().get(tempUrl, true);
get.then((response: any) => { get.then((response: any) => {
if(response.status === 200) { if(response.status === 200) {
......
.ibiz-group-select {
width: 100%;
display: flex;
border: 1px solid #DCDFE6;
height: 32px;
border-radius: 4px;
.ibiz-group-content {
flex-grow: 1;
height: 32px;
.group-item-text{
padding-left: 15px;
font-size: 13px;
}
.ibiz-group-item {
display: inline-block;
border: 1px solid #bbb;
border-radius: 5px;
font-size: 12px;
height: 24px;
line-height: 22px;
margin: 2px 0px 2px 6px;
padding: 1px 3px 0 8px;
background-color: #f4f4f5;
border-color: #e9e9eb;
color: #909399;
.group-item-multiple{
margin: 0 8px 0 0;
}
.el-icon-close{
color: #909399;
background-color: #c0c4cc;
border-radius: 50%;
top: 0;
}
.el-icon-close:hover{
color: #fff;
background-color: #909399;
}
}
}
.ibiz-group-open {
display: flex;
text-align: center;
align-items: center;
padding: 0 5px;
}
}
.ibiz-group-select:hover {
border-color: #108cee;
}
\ No newline at end of file
<template> <template>
<div class="ibiz-group-select"> <div class="ibiz-group-select">
<div class="ibiz-group-content"> <div class="ibiz-group-content">
<span v-if="!multiple"> <span class="group-item-text" v-if="!multiple">
{{ selectName }} {{ selectName }}
</span> </span>
<template v-else v-for="(select, index) of selects"> <template v-else v-for="(select, index) of selects">
<div :key="index" class="ibiz-group-item"> <div :key="index" class="ibiz-group-item">
{{ select.label }} <span class="group-item-multiple">{{ select.label }}</span>
<i v-if="!disabled" class="el-icon-close" @click="remove(select)"></i> <i v-if="!disabled" class="el-icon-close" @click="remove(select)"></i>
</div> </div>
</template> </template>
</div> </div>
<div v-if="!disabled" class="ibiz-group-open"> <div v-if="!disabled" class="ibiz-group-open">
<i v-if="!disabled && !multiple && selects.length > 0" class="el-icon-close" @click="remove(selects[0])"></i> <i v-if="!disabled && !multiple && selects.length > 0" class="el-icon-close" @click="remove(selects[0])"></i>
<i class="el-icon-search" @click="openView"></i> <i class="el-icon-search" @click="openView" style="color: #c0c4cc;"></i>
</div> </div>
</div> </div>
</template> </template>
...@@ -147,9 +147,7 @@ export default class AppGroupSelect extends Vue { ...@@ -147,9 +147,7 @@ export default class AppGroupSelect extends Vue {
if (newVal) { if (newVal) {
let item: any = {}; let item: any = {};
item.label = this.data[this.name]?this.data[this.name].split(','):[]; item.label = this.data[this.name]?this.data[this.name].split(','):[];
if(this.valueitem) {
item.id = this.data[this.valueitem] ? this.data[this.valueitem].split(',') : []; item.id = this.data[this.valueitem] ? this.data[this.valueitem].split(',') : [];
}
if(this.fillmap) { if(this.fillmap) {
for(let key in this.fillmap) { for(let key in this.fillmap) {
item[this.fillmap[key]] = this.data[key] ? this.data[key].split(',') : []; item[this.fillmap[key]] = this.data[key] ? this.data[key].split(',') : [];
...@@ -219,7 +217,7 @@ export default class AppGroupSelect extends Vue { ...@@ -219,7 +217,7 @@ export default class AppGroupSelect extends Vue {
treeurl:this.treeurl, treeurl:this.treeurl,
filtervalue: filtervalue, filtervalue: filtervalue,
multiple: this.multiple, multiple: this.multiple,
selects: this.selects selects: this.selects,
}); });
let container: Subject<any> = this.$appmodal.openModal(view, context, param); let container: Subject<any> = this.$appmodal.openModal(view, context, param);
container.subscribe((result: any) => { container.subscribe((result: any) => {
...@@ -330,32 +328,5 @@ export default class AppGroupSelect extends Vue { ...@@ -330,32 +328,5 @@ export default class AppGroupSelect extends Vue {
</script> </script>
<style lang="less"> <style lang="less">
.ibiz-group-select { @import './app-group-select.less';
width: 100%;
display: flex;
border: 1px solid #DCDFE6;
min-height: 32px;
border-radius: 4px;
.ibiz-group-content {
flex-grow: 1;
padding: 0 16px;
.ibiz-group-item {
display: inline-block;
border: 1px solid #bbb;
line-height: 24px;
border-radius: 5px;
margin-right: 5px;
padding: 0 5px;
}
}
.ibiz-group-open {
display: flex;
text-align: center;
align-items: center;
padding: 0 5px;
}
}
.ibiz-group-select:hover {
border-color: #108cee;
}
</style> </style>
\ No newline at end of file
<template> <template>
<div class="app-header-menus"> <div class="app-header-menus" v-if="isShow">
<div v-for="(menu,index) in menus" :key="index" class="app-header-menu-item text" @click="openWindow(menu)"> <div v-for="(menu,index) in menus" :key="index" class="app-header-menu-item text" @click="openWindow(menu)">
<div class="app-header-menu-item-icon"> <div class="app-header-menu-item-icon">
<i :class="menu.iconcls" :aria-hidden="true" /> <i :class="menu.iconcls" :aria-hidden="true" />
...@@ -19,6 +19,14 @@ import { Environment } from '@/environments/environment'; ...@@ -19,6 +19,14 @@ import { Environment } from '@/environments/environment';
}) })
export default class AppHeaderMenus extends Vue { export default class AppHeaderMenus extends Vue {
/**
* 是否显示
*
* @type {boolean}
* @memberof AppHeaderMenus
*/
public isShow:boolean = Environment.devMode;
/** /**
* 菜单数据 * 菜单数据
* *
...@@ -41,7 +49,7 @@ export default class AppHeaderMenus extends Vue { ...@@ -41,7 +49,7 @@ export default class AppHeaderMenus extends Vue {
{ {
name: "ibizstudio", name: "ibizstudio",
title: "components.appHeaderMenus.ibizstudio.title", title: "components.appHeaderMenus.ibizstudio.title",
url: `${Environment.StudioUrl}?#/common_slnindex/srfkeys=${Environment.SlnId}/sysdesign_psdevslnsysmodeltreeexpview`, url: `${Environment.StudioUrl}?#/common_mosindex/srfkeys=${Environment.SysId}`,
iconcls: 'fa fa-wrench', iconcls: 'fa fa-wrench',
}, },
{ {
......
.item { .item {
height: 24px; height: 24px;
line-height: 24px; line-height: 24px;
padding: 0 5px 0 0;
} }
.show-more { .show-more {
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
</el-col> </el-col>
<el-col :span="21" class="column2" :draggable="false"> <el-col :span="21" class="column2" :draggable="false">
<el-row :draggable="false"> <el-row :draggable="false">
<el-col :span="16" :draggable="false"> <el-col :span="16" :draggable="false" style="width: 65%;">
<div class="process-definition-name" :draggable="false"><strong>{{myTask.processDefinitionName}}</strong></div> <div class="process-definition-name" :draggable="false"><strong>{{myTask.processDefinitionName}}</strong></div>
<div class="description" :draggable="false">{{myTask.description}}</div> <div class="description" :draggable="false">{{myTask.description}}</div>
<div class="createtime" :draggable="false">{{ formatDate(myTask.createTime, 'MM-DD hh:mm') }}</div> <div class="createtime" :draggable="false">{{ formatDate(myTask.createTime, 'MM-DD hh:mm') }}</div>
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
<el-col :span="5" :draggable="false" style='display: flex; align-items: center'> <el-col :span="5" :draggable="false" style='display: flex; align-items: center'>
<el-tag :type="myTask.name.indexOf('驳回')!=-1?'danger':(myTask.name.indexOf('成功')!=-1?'success':(myTask.name.indexOf('取消')!=-1?'info':'-'))" <el-tag :type="myTask.name.indexOf('驳回')!=-1?'danger':(myTask.name.indexOf('成功')!=-1?'success':(myTask.name.indexOf('取消')!=-1?'info':'-'))"
size="small" @click="handleTag(myTask)" size="small" @click="handleTag(myTask)"
style="cursor: pointer;" :draggable="false"> style="cursor: pointer;overflow: hidden;text-overflow: ellipsis;" :draggable="false">
{{myTask.name}} {{myTask.name}}
</el-tag> </el-tag>
</el-col> </el-col>
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
</el-col> </el-col>
<el-col :span="21" class="column2" :draggable="false"> <el-col :span="21" class="column2" :draggable="false">
<el-row :draggable="false"> <el-row :draggable="false">
<el-col :span="16" :draggable="false"> <el-col :span="16" :draggable="false" style="width: 65%;">
<div class="process-definition-name" :draggable="false"><strong>{{myMsg.processDefinitionName}}</strong></div> <div class="process-definition-name" :draggable="false"><strong>{{myMsg.processDefinitionName}}</strong></div>
<div class="description" :draggable="false">{{myMsg.description}}</div> <div class="description" :draggable="false">{{myMsg.description}}</div>
<div class="createtime" :draggable="false">{{ formatDate(myMsg.createTime, 'MM-DD hh:mm') }}</div> <div class="createtime" :draggable="false">{{ formatDate(myMsg.createTime, 'MM-DD hh:mm') }}</div>
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
<el-col :span="5" :draggable="false" style='display: flex; align-items: center'> <el-col :span="5" :draggable="false" style='display: flex; align-items: center'>
<el-tag :type="myMsg.name.indexOf('驳回')!=-1?'danger':(myMsg.name.indexOf('成功')!=-1?'success':(myMsg.name.indexOf('取消')!=-1?'info':'-'))" <el-tag :type="myMsg.name.indexOf('驳回')!=-1?'danger':(myMsg.name.indexOf('成功')!=-1?'success':(myMsg.name.indexOf('取消')!=-1?'info':'-'))"
size="small" @click="handleTag(myMsg)" size="small" @click="handleTag(myMsg)"
style="cursor: pointer;" :draggable="false"> style="cursor: pointer;overflow: hidden;text-overflow: ellipsis;" :draggable="false">
{{myMsg.name}} {{myMsg.name}}
</el-tag> </el-tag>
</el-col> </el-col>
...@@ -149,7 +149,7 @@ ...@@ -149,7 +149,7 @@
this.getMyMsgs(); this.getMyMsgs();
} }
}).catch((error: any) => { }).catch((error: any) => {
this.$Notice.error({title: '错误', desc: error}); console.warn("加载数据错误");
}) })
} }
......
...@@ -5,14 +5,14 @@ ...@@ -5,14 +5,14 @@
<i v-if=" item.iconcls && !Object.is(item.iconcls, '')" :class="item.iconcls"></i> <i v-if=" item.iconcls && !Object.is(item.iconcls, '')" :class="item.iconcls"></i>
<img v-else-if="item.icon && !Object.is(item.icon, '')" :src="item.icon" /> <img v-else-if="item.icon && !Object.is(item.icon, '')" :src="item.icon" />
<span class="app-quick-item-label">{{item.label}}</span> <span class="app-quick-item-label">{{item.label}}</span>
<span v-show="isSelectedItem(item) && counterService && counterService.counterData && counterService.counterData[item.codename]" class="app-quick-item-counter">{{itemTag(item)}}</span> <span v-show="isSelectedItem(item) && counterService && counterService.counterData && counterService.counterData[item.codename.toLowerCase()]" class="app-quick-item-counter">{{itemTag(item)}}</span>
</span> </span>
<el-dropdown v-if="item.children" style="outline: none !important;" trigger="click" @command="handleCommand($event,item)"> <el-dropdown v-if="item.children" style="outline: none !important;" trigger="click" @command="handleCommand($event,item)">
<span :style="{color:item.color}" :class="{'app-seleted-item':isSelectedItem(item)}"> <span :style="{color:item.color}" :class="{'app-seleted-item':isSelectedItem(item)}">
<i v-if=" item.iconcls && !Object.is(item.iconcls, '')" :class="item.iconcls"></i> <i v-if=" item.iconcls && !Object.is(item.iconcls, '')" :class="item.iconcls"></i>
<img v-else-if="item.icon && !Object.is(item.icon, '')" :src="item.icon" /> <img v-else-if="item.icon && !Object.is(item.icon, '')" :src="item.icon" />
<span class="app-quick-item-label">{{item.label}}</span> <span class="app-quick-item-label">{{item.label}}</span>
<span v-show="isSelectedItem(item) && counterService && counterService.counterData && counterService.counterData[item.codename]" class="app-quick-item-counter">{{itemTag(item)}}</span> <span v-show="isSelectedItem(item) && counterService && counterService.counterData && counterService.counterData[item.codename.toLowerCase()]" class="app-quick-item-counter">{{itemTag(item)}}</span>
</span> </span>
<el-dropdown-menu slot="dropdown"> <el-dropdown-menu slot="dropdown">
<el-dropdown-item v-for="childitem in item.children" :command="childitem" :key="childitem.id"> <el-dropdown-item v-for="childitem in item.children" :command="childitem" :key="childitem.id">
...@@ -65,7 +65,6 @@ export default class AppQuickGroup extends Vue { ...@@ -65,7 +65,6 @@ export default class AppQuickGroup extends Vue {
*/ */
get renderArray(){ get renderArray(){
if(this.items && this.items.length >0){ if(this.items && this.items.length >0){
this.selectedUiItem = this.items[0];
this.handleClick(this.items[0]); this.handleClick(this.items[0]);
return this.handleDataSet(this.items) return this.handleDataSet(this.items)
}else{ }else{
...@@ -75,7 +74,7 @@ export default class AppQuickGroup extends Vue { ...@@ -75,7 +74,7 @@ export default class AppQuickGroup extends Vue {
public itemTag(item:any){ public itemTag(item:any){
if(this.counterService && this.counterService.counterData && item.codename){ if(this.counterService && this.counterService.counterData && item.codename){
return this.counterService.counterData[item.codename]; return this.counterService.counterData[item.codename.toLowerCase()];
}else{ }else{
return ""; return "";
} }
...@@ -145,6 +144,9 @@ export default class AppQuickGroup extends Vue { ...@@ -145,6 +144,9 @@ export default class AppQuickGroup extends Vue {
* @memberof AppQuickGroup * @memberof AppQuickGroup
*/ */
public handleClick($event:any,isswitch:boolean = true){ public handleClick($event:any,isswitch:boolean = true){
if(this.selectedUiItem && (this.selectedUiItem.id === $event.id)){
return;
}
this.$emit('valuechange',$event); this.$emit('valuechange',$event);
if(isswitch){ if(isswitch){
this.selectedUiItem = $event; this.selectedUiItem = $event;
......
...@@ -214,7 +214,8 @@ export default class AppSpan extends Vue { ...@@ -214,7 +214,8 @@ export default class AppSpan extends Vue {
this.text = Number(number.toFixed(this.precision)).toLocaleString('en-US')+ ' '+ this.unitName; this.text = Number(number.toFixed(this.precision)).toLocaleString('en-US')+ ' '+ this.unitName;
}else if(Object.is(this.dataType,"FLOAT") || Object.is(this.dataType,"DECIMAL")){ }else if(Object.is(this.dataType,"FLOAT") || Object.is(this.dataType,"DECIMAL")){
let number:any = Number(this.value); let number:any = Number(this.value);
this.text = number.toFixed(this.precision); const decimalCnt:number = this.value.toString().split('.').length > 1 ? this.value.toString().split('.')[1].length : 0;
this.text = (Number(this.precision) === 0 && decimalCnt !== 0) ? number.toFixed(decimalCnt) : number.toFixed(this.precision);
}else { }else {
this.text = this.value; this.text = this.value;
} }
......
.app-theme{ .app-theme{
width: auto !important;
padding: 0 5px;
/*** BRGIN:主题选择框样式 ***/ /*** BRGIN:主题选择框样式 ***/
.app-app-theme { .app-app-theme {
.app-theme-color { .app-theme-color {
......
...@@ -48,6 +48,7 @@ ...@@ -48,6 +48,7 @@
<script lang = 'ts'> <script lang = 'ts'>
import { Component, Vue } from 'vue-property-decorator'; import { Component, Vue } from 'vue-property-decorator';
import { appConfig } from '@/config/appConfig';
@Component({ @Component({
}) })
...@@ -75,23 +76,7 @@ export default class AppTheme extends Vue { ...@@ -75,23 +76,7 @@ export default class AppTheme extends Vue {
* @type {Array<any>} * @type {Array<any>}
* @memberof AppTheme * @memberof AppTheme
*/ */
defaultThemes: Array<any> = [ defaultThemes: Array<any> = appConfig.themes;
{
tag: 'app-default-theme',
title: 'light',
color: '#f6f6f6',
},
{
title: 'Blue',
tag: 'app_theme_blue',
color: '#6ba1d1'
},
{
title: 'Dark Blue',
tag: 'app_theme_darkblue',
color: '#606d80'
}
];
/** /**
* 所选择的字体 * 所选择的字体
...@@ -106,20 +91,7 @@ export default class AppTheme extends Vue { ...@@ -106,20 +91,7 @@ export default class AppTheme extends Vue {
* *
* @memberof AppTheme * @memberof AppTheme
*/ */
public fontFamilys = [ public fontFamilys = appConfig.fonts;
{
label: 'MicrosoftYaHei',
value: 'Microsoft YaHei',
},
{
label: 'SimHei',
value: 'SimHei',
},
{
label: 'YouYuan',
value: 'YouYuan',
},
];
/** /**
* 挂载元素事件 * 挂载元素事件
...@@ -130,12 +102,12 @@ export default class AppTheme extends Vue { ...@@ -130,12 +102,12 @@ export default class AppTheme extends Vue {
if (localStorage.getItem('theme-class')) { if (localStorage.getItem('theme-class')) {
this.selectTheme = localStorage.getItem('theme-class'); this.selectTheme = localStorage.getItem('theme-class');
} else { } else {
this.selectTheme = 'app-default-theme'; this.selectTheme = appConfig.defaultTheme;
} }
if (localStorage.getItem('font-family')) { if (localStorage.getItem('font-family')) {
this.selectFont = localStorage.getItem('font-family'); this.selectFont = localStorage.getItem('font-family');
} else { } else {
this.selectFont = 'Microsoft YaHei'; this.selectFont = appConfig.defaultFont;
} }
} }
...@@ -146,7 +118,7 @@ export default class AppTheme extends Vue { ...@@ -146,7 +118,7 @@ export default class AppTheme extends Vue {
* @memberof AppTheme * @memberof AppTheme
*/ */
public themeChange(val: any) { public themeChange(val: any) {
if (!Object.is(this.activeTheme, val)) { if (!Object.is(this.selectTheme, val)) {
this.selectTheme = val; this.selectTheme = val;
localStorage.setItem('theme-class', val); localStorage.setItem('theme-class', val);
this.$router.app.$store.commit('setCurrentSelectTheme', val); this.$router.app.$store.commit('setCurrentSelectTheme', val);
......
<template>
<div v-if="formOption!=null" class="app-custom-form">
<avue-form :option="formOption" v-model="formvalue"></avue-form>
</div>
</template>
<script lang="ts">
import {Vue,Component,Prop,Model,Emit,Watch,} from "vue-property-decorator";
import { Subject, Subscription } from "rxjs";
@Component({})
export default class AvueCustomForm extends Vue {
/**
* 编辑器参数传入组件配置
*
* @type {any}
* @memberof AvueCustomForm
*/
@Prop()
public options?: any;
/**
* 是否需要转换为string类型
*
* @type {boolean}
* @memberof AvueCustomForm
*/
@Prop()
public isParseString?: boolean;
/**
* 远端地址
*
* @type {string}
* @memberof AvueCustomForm
*/
@Prop() public url?: string;
/**
* 表单项值
*
* @type {any}
* @memberof AvueCustomForm
*/
@Prop() public value: any;
/**
* 是否将表单数据通过组件配置带入组件中
*
* @type {boolean}
* @memberof AvueCustomForm
*/
@Prop() public isFormData?: boolean;
/**
* 监听事件
*
* @param {*} newVal
* @param {*} oldVal
* @memberof AvueCustomForm
*/
@Watch("value")
public onValueChange(newVal: any, oldVal: any) {
if (newVal) {
let obj: any = {};
if (newVal && newVal != null) {
if (this.isParseString) obj = JSON.parse(newVal);
else obj = newVal;
}
if (obj) this.formvalue = JSON.parse(JSON.stringify(obj));
}
}
/**
* 表单数据
*
* @type {any}
* @memberof AvueCustomForm
*/
@Prop()
public formData: any;
/**
* 表单状态
*
* @type {Subject<any>}
* @memberof AvueCustomForm
*/
@Prop() public formState!: Subject<any>;
/**
* 视图状态事件
*
* @protected
* @type {(Subscription | undefined)}
* @memberof AvueCustomForm
*/
protected formStateEvent: Subscription | undefined;
/**
* 当前组件配置设置属性
*
* @type {any}
* @memberof AvueCustomForm
*/
public formOption: any = null;
/**
* avue-form绑定值
*
* @type {any}
* @memberof AvueCustomForm
*/
public formvalue: any = {};
/**
* avue-form默认配置
*
* @type {any}
* @memberof AvueCustomForm
*/
public defaultOptions: any = {
column: [
{
type: "dynamic",
label: "子表单",
span: 24,
display: true,
children: {
align: "center",
headerAlign: "center",
index: false,
addBtn: true,
delBtn: true,
column: [
{
type: "input",
label: "属性",
span: 24,
display: true,
prop: "property",
},
{
type: "input",
label: "值",
span: 24,
display: true,
prop: "value",
},
],
},
prop: "1599476281048_17916",
},
],
labelPosition: "left",
labelSuffix: ":",
labelWidth: 120,
gutter: 0,
menuBtn: false,
submitBtn: false,
submitText: "提交",
emptyBtn: false,
emptyText: "清空",
menuPosition: "center",
};
/**
* vue生命周期
*
* @memberof AvueCustomForm
*/
public mounted() {
let that: any = this;
if (this.formState) {
this.formStateEvent = this.formState.subscribe(({ type, data }) => {
if (Object.is("load", type)) that.load();
});
}
}
/**
* 加载表单配置,配置优先级,依次按优先级加载(表单项值 > 远端请求 > 默认值)
*
* @memberof AvueCustomForm
*/
public load() {
let that: any = this;
if (!this.options && this.options == null) {
if (this.url && this.options == null) {
const get: Promise<any> = this.$http.get(this.url);
get.then((response: any) => {
if (response && response.data && response.data.view_config) {
that.formOption = JSON.parse(response.data.view_config)[
"formConfig"
];
if (this.isFormData) that.getFormData();
}
});
} else {
this.formOption = this.defaultOptions;
if (this.isFormData) that.getFormData();
}
} else {
this.formOption = this.options;
if (this.isFormData) that.getFormData();
}
}
/**
* 当组件配置中的属性与表单属性重复时,表单值塞入组件中
*
* @memberof AvueCustomForm
*/
public getFormData() {
let that: any = this;
let obj: any;
if (this.value) obj = JSON.parse(JSON.stringify(this.value));
else obj = {};
let recursionOption: any = function (group: any) {
group.column.forEach((gItem: any) => {
if (group.column && group.column.length > 0) {
if (that.formData[gItem.prop])
obj[gItem.prop] = that.formData[gItem.prop];
}
});
if (group.group && group.group.length > 0)
group.group.forEach((gItem: any) => {
recursionOption(gItem);
});
};
recursionOption(this.formOption);
this.setValue(obj);
}
/**
* 设置表单值
*
* @param {*} value
* @memberof AvueCustomForm
*/
public setValue(value: any) {
if (this.isParseString) this.$emit("change", JSON.stringify(value));
else this.$emit("change", value);
}
}
</script>
\ No newline at end of file
...@@ -293,12 +293,13 @@ export default class ContextMenuDrag extends Vue { ...@@ -293,12 +293,13 @@ export default class ContextMenuDrag extends Vue {
mounted() { mounted() {
let that: any = this; let that: any = this;
const get: Promise<any> = this.entityService.getAllApp(null,{}); const get: Promise<any> = this.entityService.getAllApp(null,{});
get get.then((response: any) => {
.then((response: any) => {
if (response) { if (response) {
that.list = response.data.model; that.list = response.data.model;
that.listFilter(); that.listFilter();
} }
}).catch((error:any) =>{
console.warn("加载数据错误")
}); });
} }
} }
......
...@@ -92,6 +92,14 @@ export default class ContextMenu extends Vue { ...@@ -92,6 +92,14 @@ export default class ContextMenu extends Vue {
*/ */
@Prop() @Prop()
public menus?: any[] public menus?: any[]
/**
* 是否阻止默认绘制上下文菜单
*
* @type {any}
* @memberof ContextMenu
*/
@Prop({default:false})
public isBlocked?:any;
/** /**
* 显示右键菜单 * 显示右键菜单
...@@ -195,7 +203,10 @@ export default class ContextMenu extends Vue { ...@@ -195,7 +203,10 @@ export default class ContextMenu extends Vue {
if (contextRef) { if (contextRef) {
contextRef.oncontextmenu = (event: MouseEvent) => { contextRef.oncontextmenu = (event: MouseEvent) => {
event.preventDefault(); event.preventDefault();
if(!this.isBlocked){
this.showContextMenu(event.clientX, event.clientY); this.showContextMenu(event.clientX, event.clientY);
}
this.$emit("showContext",event);
}; };
} }
} }
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
:clearable="true" :clearable="true"
:filterable="filterable" :filterable="filterable"
@on-open-change="onClick" @on-open-change="onClick"
:placeholder="$t('components.dropDownListDynamic.placeholder')"> :placeholder="placeholder?placeholder:$t('components.dropDownListDynamic.placeholder')">
<i-option v-for="(item, index) in items" :key="index" :class="item.class" :value="item.value">{{($t('userCustom.'+tag+'.'+item.value)!== ('userCustom.'+tag+'.'+item.value))?$t('userCustom.'+tag+'.'+item.value) : item.text}}</i-option> <i-option v-for="(item, index) in items" :key="index" :class="item.class" :value="item.value">{{($t('userCustom.'+tag+'.'+item.value)!== ('userCustom.'+tag+'.'+item.value))?$t('userCustom.'+tag+'.'+item.value) : item.text}}</i-option>
</i-select> </i-select>
</template> </template>
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
:clearable="true" :clearable="true"
:filterable="filterable" :filterable="filterable"
@on-open-change="onClick" @on-open-change="onClick"
:placeholder="$t('components.dropDownListMpicker.placeholder')"> :placeholder="placeholder?placeholder:$t('components.dropDownListMpicker.placeholder')">
<i-option v-for="(item, index) in items" :key="index" :class="item.class" :value="item.value.toString()" :label="item.text"> <i-option v-for="(item, index) in items" :key="index" :class="item.class" :value="item.value.toString()" :label="item.text">
<Checkbox :value = "(currentVal.indexOf(item.value.toString()))==-1?false:true"> <Checkbox :value = "(currentVal.indexOf(item.value.toString()))==-1?false:true">
{{Object.is(codelistType,'STATIC') ? $t('codelist.'+tag+'.'+item.value) : item.text}} {{Object.is(codelistType,'STATIC') ? $t('codelist.'+tag+'.'+item.value) : item.text}}
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
:clearable="true" :clearable="true"
:filterable="filterable" :filterable="filterable"
@on-open-change="onClick" @on-open-change="onClick"
:placeholder="$t('components.dropDownList.placeholder')"> :placeholder="placeholder?placeholder:$t('components.dropDownList.placeholder')">
<i-option v-for="(item, index) in items" :key="index" :class="item.class" :value="item.value">{{($t('codelist.'+tag+'.'+item.value)!== ('codelist.'+tag+'.'+item.value))?$t('codelist.'+tag+'.'+item.value) : item.text}}</i-option> <i-option v-for="(item, index) in items" :key="index" :class="item.class" :value="item.value">{{($t('codelist.'+tag+'.'+item.value)!== ('codelist.'+tag+'.'+item.value))?$t('codelist.'+tag+'.'+item.value) : item.text}}</i-option>
</i-select> </i-select>
<ibiz-select-tree v-if="hasChildren" class="tree-dropdown-list" :disabled="disabled" :NodesData="items" v-model="currentVal" :multiple="false"></ibiz-select-tree> <ibiz-select-tree v-if="hasChildren" class="tree-dropdown-list" :disabled="disabled" :NodesData="items" v-model="currentVal" :multiple="false"></ibiz-select-tree>
......
export const appConfig = {
//默认主题
defaultTheme: 'app-default-theme',
//默认字体
defaultFont: 'Microsoft YaHei',
//主题集合
themes: [
{
tag: 'app-default-theme',
title: 'light',
color: '#f6f6f6',
},
{
tag: 'app_theme_blue',
title: 'Blue',
color: '#6ba1d1'
},
{
tag: 'app_theme_darkblue',
title: 'Dark Blue',
color: '#606d80'
},
],
//字体集合
fonts: [
{
label: 'MicrosoftYaHei',
value: 'Microsoft YaHei',
},
{
label: 'SimHei',
value: 'SimHei',
},
{
label: 'YouYuan',
value: 'YouYuan',
},
]
}
\ No newline at end of file
import { Store } from 'vuex'; import { Store } from 'vuex';
import EntityService from '@/service/entity-service';
/** /**
* 计数器服务基类 * 计数器服务基类
...@@ -17,6 +19,51 @@ export default class CounterService { ...@@ -17,6 +19,51 @@ export default class CounterService {
*/ */
private $store: Store<any> | null = null; private $store: Store<any> | null = null;
/**
* 当前计数器数据
*
* @protected
* @type {*}
* @memberof CounterService
*/
protected counterData:any ={};
/**
* 应用实体数据服务
*
* @protected
* @type {EntityService}
* @memberof CounterService
*/
protected appEntityService:EntityService = new EntityService();
/**
* 当前计数器导航上下文
*
* @protected
* @type {*}
* @memberof CounterService
*/
protected context:any ={};
/**
* 当前计数器导航参数
*
* @protected
* @type {*}
* @memberof CounterService
*/
protected viewparams:any ={};
/**
* 当前计数器定时器对象
*
* @protected
* @type {*}
* @memberof CounterService
*/
protected timer:any;
/** /**
* Creates an instance of CounterService. * Creates an instance of CounterService.
* *
...@@ -25,6 +72,8 @@ export default class CounterService { ...@@ -25,6 +72,8 @@ export default class CounterService {
*/ */
constructor(opts: any = {}) { constructor(opts: any = {}) {
this.$store = opts.$store; this.$store = opts.$store;
this.context = opts.context?opts.context:{};
this.viewparams = opts.viewparams?opts.viewparams:{};
} }
/** /**
...@@ -49,5 +98,13 @@ export default class CounterService { ...@@ -49,5 +98,13 @@ export default class CounterService {
return (window as any)['counterServiceRegister'].getService(name); return (window as any)['counterServiceRegister'].getService(name);
} }
/**
* 销毁计数器
*
* @memberof ActionCounterCounterServiceBase
*/
public destroyCounter(){
if(this.timer) clearInterval(this.timer);
}
} }
\ No newline at end of file
...@@ -144,6 +144,9 @@ export default class MDViewEngine extends ViewEngine { ...@@ -144,6 +144,9 @@ export default class MDViewEngine extends ViewEngine {
if (Object.is(eventName, 'beforeload')) { if (Object.is(eventName, 'beforeload')) {
this.MDCtrlBeforeLoad(args) this.MDCtrlBeforeLoad(args)
} }
if (Object.is(eventName, 'remove')) {
this.MDCtrlRemove(args)
}
} }
/** /**
...@@ -454,5 +457,13 @@ export default class MDViewEngine extends ViewEngine { ...@@ -454,5 +457,13 @@ export default class MDViewEngine extends ViewEngine {
return this.getMDCtrl().transformData(arg); return this.getMDCtrl().transformData(arg);
} }
/**
* 多数据部件删除后
*
* @param {*} [arg={}]
* @memberof MDViewEngine
*/
public MDCtrlRemove(arg: any = {}): void {
this.view.$emit('drdatasremove', arg);
}
} }
\ No newline at end of file
...@@ -186,7 +186,6 @@ export default class ViewEngine { ...@@ -186,7 +186,6 @@ export default class ViewEngine {
* @memberof ViewEngine * @memberof ViewEngine
*/ */
public calcToolbarItemAuthState(data:any){ public calcToolbarItemAuthState(data:any){
if(Environment.enablePermissionValid){
const _this: any = this; const _this: any = this;
for (const key in _this.view.toolBarModels) { for (const key in _this.view.toolBarModels) {
if (!_this.view.toolBarModels.hasOwnProperty(key)) { if (!_this.view.toolBarModels.hasOwnProperty(key)) {
...@@ -221,6 +220,5 @@ export default class ViewEngine { ...@@ -221,6 +220,5 @@ export default class ViewEngine {
} }
} }
} }
}
} }
\ No newline at end of file
...@@ -49,6 +49,7 @@ export default class WFDynaExpGridViewEngine extends GridViewEngine { ...@@ -49,6 +49,7 @@ export default class WFDynaExpGridViewEngine extends GridViewEngine {
public onCtrlEvent(ctrlName: string, eventName: string, args: any): void { public onCtrlEvent(ctrlName: string, eventName: string, args: any): void {
if (Object.is(ctrlName, 'grid')) { if (Object.is(ctrlName, 'grid')) {
this.GridEvent(eventName, args); this.GridEvent(eventName, args);
return;
} }
super.onCtrlEvent(ctrlName, eventName, args); super.onCtrlEvent(ctrlName, eventName, args);
} }
......
...@@ -15,6 +15,8 @@ export const Environment = { ...@@ -15,6 +15,8 @@ export const Environment = {
ExportFile: '/ibizutil/download', ExportFile: '/ibizutil/download',
// 文件上传 // 文件上传
UploadFile: '/ibizutil/upload', UploadFile: '/ibizutil/upload',
// 数据导入单次上传最大数量
sliceUploadCnt: 100,
// 是否为pc端应用 // 是否为pc端应用
isAppMode:true, isAppMode:true,
//统一地址 //统一地址
......
...@@ -24,7 +24,10 @@ export default { ...@@ -24,7 +24,10 @@ export default {
deleteError: "Failed to delete", deleteError: "Failed to delete",
delDataFail: "Failed to delete data", delDataFail: "Failed to delete data",
noData: "No data", noData: "No data",
startsuccess:"Start successful" startsuccess:"Start successful",
loadmore:"Load more",
nomore:"No more",
other:"other"
}, },
local:{ local:{
new: "New", new: "New",
...@@ -38,6 +41,8 @@ export default { ...@@ -38,6 +41,8 @@ export default {
totle: "totle", totle: "totle",
noData: "No data", noData: "No data",
valueVail: "Value cannot be empty", valueVail: "Value cannot be empty",
group:"Group",
other:"Other",
notConfig: { notConfig: {
fetchAction: "The view table fetchaction parameter is not configured", fetchAction: "The view table fetchaction parameter is not configured",
removeAction: "The view table removeaction parameter is not configured", removeAction: "The view table removeaction parameter is not configured",
......
...@@ -24,7 +24,10 @@ export default { ...@@ -24,7 +24,10 @@ export default {
deleteError: "删除失败", deleteError: "删除失败",
delDataFail: "删除数据失败", delDataFail: "删除数据失败",
noData: "暂无数据", noData: "暂无数据",
startsuccess:"启动成功" startsuccess:"启动成功",
loadmore:"加载更多",
nomore:"没有更多了",
other:"其他"
}, },
local:{ local:{
new: "新建", new: "新建",
...@@ -38,6 +41,8 @@ export default { ...@@ -38,6 +41,8 @@ export default {
totle: "共", totle: "共",
noData: "无数据", noData: "无数据",
valueVail: "值不能为空", valueVail: "值不能为空",
group:"分组",
other:"其他",
notConfig: { notConfig: {
fetchAction: "视图表格fetchAction参数未配置", fetchAction: "视图表格fetchAction参数未配置",
removeAction: "视图表格removeAction参数未配置", removeAction: "视图表格removeAction参数未配置",
......
...@@ -328,5 +328,48 @@ export default { ...@@ -328,5 +328,48 @@ export default {
appMessagePopover: { appMessagePopover: {
loadMore: 'Load more', loadMore: 'Load more',
noMore: 'No more' noMore: 'No more'
},
diskFileUpload:{
fileDrag: 'Drag the file here, or',
clickUpload: 'Click on the upload',
load: 'Load',
preview: 'preview',
edit: 'Edit',
delete: 'Delete',
clues: 'Individual file sizes do not exceed',
clues1: 'Documents not exceeding',
getFileFailure: 'Failed to get file list',
loadFailure: 'Upload file failed',
loadFailure1: 'Upload failed, individual file cannot exceed',
downloadFile: 'Download file failed',
downloadFile1: 'Download file failed, not get file!',
deleteFile: 'This action will permanently delete the file. Do you want to continue?',
deleteFilePrompt: 'Prompt',
true: 'True',
false: 'False',
deleteFileFailure: 'File deletion failed',
updateFailure: 'Batch update file failed',
},
diskImageUpload:{
preview: 'Preview',
OCRdiscern: 'OCRdiscern',
load: 'Load',
delete: 'Delete',
getImageFailure: 'Failed to get list of images',
loadImageFailure: 'Failed to download thumbnails',
loadImageFailure1: 'Failed to download thumbnail, failed to get file!',
loadImageFailure2:'Download image failed',
loadImageFailure3:'Download picture failed, no picture found!',
ImageIdNone: 'Picture ID does not exist!',
uploadImageFailure: 'Failed to upload image',
uploadImageFailure1: "Upload failed, only support 'GIF, JPG, PNG, BMP' format images!",
uploadFailure: 'Upload failed, individual image must not exceed',
notImageUrl: 'The image URL does not exist',
deleteFile: 'This action will permanently delete the file. Do you want to continue?',
deleteFilePrompt: 'Prompt',
true: 'True',
false: 'False',
deleteImageFailure:'Image deletion failed',
updateFailure: 'Batch update file failed',
} }
}; };
\ No newline at end of file
...@@ -329,5 +329,48 @@ export default { ...@@ -329,5 +329,48 @@ export default {
appMessagePopover: { appMessagePopover: {
loadMore: '加载更多', loadMore: '加载更多',
noMore: '没有更多了' noMore: '没有更多了'
},
diskFileUpload:{
fileDrag: '将文件拖到此处,或',
clickUpload: '点击上传',
load: '下载',
preview: '预览',
edit: '编辑',
delete: '删除',
clues: '单个文件大小不超过',
clues1: '文件不超过',
getFileFailure: '获取文件列表失败',
loadFailure: '上传文件失败',
loadFailure1: '上传失败,单个文件不得超过',
downloadFile: '下载文件失败',
downloadFile1: '下载文件失败,未获取到文件!',
deleteFile: '此操作将永久删除该文件, 是否继续?',
deleteFilePrompt: '提示',
true: '确定',
false: '取消',
deleteFileFailure: '删除文件失败',
updateFailure: '批量更新文件失败',
},
diskImageUpload:{
preview: '预览',
OCRdiscern: 'ORC识别',
load: '下载',
delete: '删除',
getImageFailure: '获取图片列表失败',
loadImageFailure: '下载缩略图失败',
loadImageFailure1: '下载缩略图失败,未获取到文件!',
loadImageFailure2:'下载图片失败',
loadImageFailure3:'下载图片失败,未找到图片!',
ImageIdNone: '图片id不存在!',
uploadImageFailure: '上传图片失败',
uploadImageFailure1: '上传失败,仅支持'gif,jpg,png,bmp'格式的图片!',
uploadFailure: '上传失败,单个图片不得超过',
notImageUrl: '图片url不存在',
deleteFile: '此操作将永久删除该文件, 是否继续?',
deleteFilePrompt: '提示',
true: '确定',
false: '取消',
deleteImageFailure:'删除图片失败',
updateFailure: '批量更新文件失败',
} }
}; };
\ No newline at end of file
...@@ -33,6 +33,7 @@ mock.onGet('/appdata').reply((config: any) => { ...@@ -33,6 +33,7 @@ mock.onGet('/appdata').reply((config: any) => {
// 当前用户条线代码 // 当前用户条线代码
srfsectorbc:"" srfsectorbc:""
}, },
enablepermissionvalid:false,
unires:["RESOURCE1","RESOURCE2"], unires:["RESOURCE1","RESOURCE2"],
//当前用户所有组织部门标识 //当前用户所有组织部门标识
srforgsections:[{"srforgsectorid":"5bd1ecf4d3c31e31cb66373df56b852f","srforgsectorname":"项目一部"},{"srforgsectorid":"2ad1ecf4d3c31e31cb66373df56b852f","srforgsectorname":"项目二部"}] srforgsections:[{"srforgsectorid":"5bd1ecf4d3c31e31cb66373df56b852f","srforgsectorname":"项目一部"},{"srforgsectorid":"2ad1ecf4d3c31e31cb66373df56b852f","srforgsectorname":"项目二部"}]
......
...@@ -63,6 +63,7 @@ ...@@ -63,6 +63,7 @@
</template> </template>
<script lang='tsx'> <script lang='tsx'>
import { Vue, Component, Prop, Provide, Emit, Watch,Inject } from 'vue-property-decorator'; import { Vue, Component, Prop, Provide, Emit, Watch,Inject } from 'vue-property-decorator';
import { UIActionTool,Util } from '@/utils'; import { UIActionTool,Util } from '@/utils';
...@@ -71,6 +72,8 @@ import { Subject,Subscription } from 'rxjs'; ...@@ -71,6 +72,8 @@ import { Subject,Subscription } from 'rxjs';
import { appConfig } from '@/config/appConfig';
@Component({ @Component({
components: { components: {
...@@ -78,15 +81,6 @@ import { Subject,Subscription } from 'rxjs'; ...@@ -78,15 +81,6 @@ import { Subject,Subscription } from 'rxjs';
}) })
export default class PayIndexViewBase extends Vue { export default class PayIndexViewBase extends Vue {
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayIndexViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 数据变化 * 数据变化
* *
...@@ -197,6 +191,8 @@ export default class PayIndexViewBase extends Vue { ...@@ -197,6 +191,8 @@ export default class PayIndexViewBase extends Vue {
_this.engine.load(); _this.engine.load();
}); });
} else if(!Object.is(newVal, oldVal) && _this.refresh() && Object.is(_this.$util.typeOf(_this.refresh()), 'function')) {
_this.refresh();
} }
} }
...@@ -288,6 +284,15 @@ export default class PayIndexViewBase extends Vue { ...@@ -288,6 +284,15 @@ export default class PayIndexViewBase extends Vue {
*/ */
public viewCacheData:any; public viewCacheData:any;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayIndexViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 解析视图参数 * 解析视图参数
* *
...@@ -575,7 +580,7 @@ export default class PayIndexViewBase extends Vue { ...@@ -575,7 +580,7 @@ export default class PayIndexViewBase extends Vue {
} else if (localStorage.getItem('theme-class')) { } else if (localStorage.getItem('theme-class')) {
return localStorage.getItem('theme-class'); return localStorage.getItem('theme-class');
} else { } else {
return 'app-default-theme'; return appConfig.defaultTheme;
} }
} }
...@@ -591,7 +596,7 @@ export default class PayIndexViewBase extends Vue { ...@@ -591,7 +596,7 @@ export default class PayIndexViewBase extends Vue {
} else if (localStorage.getItem('font-family')) { } else if (localStorage.getItem('font-family')) {
return localStorage.getItem('font-family'); return localStorage.getItem('font-family');
} else { } else {
return 'Microsoft YaHei'; return appConfig.defaultFont;
} }
} }
...@@ -644,12 +649,8 @@ export default class PayIndexViewBase extends Vue { ...@@ -644,12 +649,8 @@ export default class PayIndexViewBase extends Vue {
* @type {string[]} * @type {string[]}
* @memberof PayIndexViewBase * @memberof PayIndexViewBase
*/ */
get themeClasses(): string[] { get themeClasses(): string {
return [ return this.selectTheme;
Object.is(this.selectTheme, 'app_theme_blue') ? 'app_theme_blue' : '',
Object.is(this.selectTheme, 'app-default-theme') ? 'app-default-theme' : '',
Object.is(this.selectTheme, 'app_theme_darkblue') ? 'app_theme_darkblue' : '',
];
} }
/** /**
......
...@@ -153,15 +153,6 @@ export default class PayOpenAccessEditViewBase extends Vue { ...@@ -153,15 +153,6 @@ export default class PayOpenAccessEditViewBase extends Vue {
*/ */
public appUIService: PayOpenAccessUIService = new PayOpenAccessUIService(this.$store); public appUIService: PayOpenAccessUIService = new PayOpenAccessUIService(this.$store);
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayOpenAccessEditViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 数据变化 * 数据变化
* *
...@@ -280,6 +271,8 @@ export default class PayOpenAccessEditViewBase extends Vue { ...@@ -280,6 +271,8 @@ export default class PayOpenAccessEditViewBase extends Vue {
_this.engine.load(); _this.engine.load();
}); });
} else if(!Object.is(newVal, oldVal) && _this.refresh() && Object.is(_this.$util.typeOf(_this.refresh()), 'function')) {
_this.refresh();
} }
} }
...@@ -424,6 +417,15 @@ export default class PayOpenAccessEditViewBase extends Vue { ...@@ -424,6 +417,15 @@ export default class PayOpenAccessEditViewBase extends Vue {
*/ */
public viewCacheData:any; public viewCacheData:any;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayOpenAccessEditViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 解析视图参数 * 解析视图参数
* *
...@@ -1555,6 +1557,14 @@ export default class PayOpenAccessEditViewBase extends Vue { ...@@ -1555,6 +1557,14 @@ export default class PayOpenAccessEditViewBase extends Vue {
this.serviceStateEvent.unsubscribe(); this.serviceStateEvent.unsubscribe();
} }
} }
// 销毁计数器定时器
if(this.counterServiceArray && this.counterServiceArray.length >0){
this.counterServiceArray.forEach((item:any) =>{
if(item.destroyCounter && item.destroyCounter instanceof Function){
item.destroyCounter();
}
})
}
} }
......
...@@ -183,15 +183,6 @@ export default class PayOpenAccessGridViewBase extends Vue { ...@@ -183,15 +183,6 @@ export default class PayOpenAccessGridViewBase extends Vue {
*/ */
public appUIService: PayOpenAccessUIService = new PayOpenAccessUIService(this.$store); public appUIService: PayOpenAccessUIService = new PayOpenAccessUIService(this.$store);
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayOpenAccessGridViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 数据变化 * 数据变化
* *
...@@ -310,6 +301,8 @@ export default class PayOpenAccessGridViewBase extends Vue { ...@@ -310,6 +301,8 @@ export default class PayOpenAccessGridViewBase extends Vue {
_this.engine.load(); _this.engine.load();
}); });
} else if(!Object.is(newVal, oldVal) && _this.refresh() && Object.is(_this.$util.typeOf(_this.refresh()), 'function')) {
_this.refresh();
} }
} }
...@@ -459,6 +452,15 @@ export default class PayOpenAccessGridViewBase extends Vue { ...@@ -459,6 +452,15 @@ export default class PayOpenAccessGridViewBase extends Vue {
*/ */
public viewCacheData:any; public viewCacheData:any;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayOpenAccessGridViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 解析视图参数 * 解析视图参数
* *
...@@ -1578,6 +1580,14 @@ export default class PayOpenAccessGridViewBase extends Vue { ...@@ -1578,6 +1580,14 @@ export default class PayOpenAccessGridViewBase extends Vue {
this.serviceStateEvent.unsubscribe(); this.serviceStateEvent.unsubscribe();
} }
} }
// 销毁计数器定时器
if(this.counterServiceArray && this.counterServiceArray.length >0){
this.counterServiceArray.forEach((item:any) =>{
if(item.destroyCounter && item.destroyCounter instanceof Function){
item.destroyCounter();
}
})
}
} }
/** /**
......
...@@ -80,15 +80,6 @@ export default class PayOpenAccessPickupGridViewBase extends Vue { ...@@ -80,15 +80,6 @@ export default class PayOpenAccessPickupGridViewBase extends Vue {
*/ */
public appUIService: PayOpenAccessUIService = new PayOpenAccessUIService(this.$store); public appUIService: PayOpenAccessUIService = new PayOpenAccessUIService(this.$store);
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayOpenAccessPickupGridViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 数据变化 * 数据变化
* *
...@@ -207,6 +198,8 @@ export default class PayOpenAccessPickupGridViewBase extends Vue { ...@@ -207,6 +198,8 @@ export default class PayOpenAccessPickupGridViewBase extends Vue {
_this.engine.load(); _this.engine.load();
}); });
} else if(!Object.is(newVal, oldVal) && _this.refresh() && Object.is(_this.$util.typeOf(_this.refresh()), 'function')) {
_this.refresh();
} }
} }
...@@ -314,6 +307,15 @@ export default class PayOpenAccessPickupGridViewBase extends Vue { ...@@ -314,6 +307,15 @@ export default class PayOpenAccessPickupGridViewBase extends Vue {
*/ */
public viewCacheData:any; public viewCacheData:any;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayOpenAccessPickupGridViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 解析视图参数 * 解析视图参数
* *
...@@ -661,6 +663,14 @@ export default class PayOpenAccessPickupGridViewBase extends Vue { ...@@ -661,6 +663,14 @@ export default class PayOpenAccessPickupGridViewBase extends Vue {
this.serviceStateEvent.unsubscribe(); this.serviceStateEvent.unsubscribe();
} }
} }
// 销毁计数器定时器
if(this.counterServiceArray && this.counterServiceArray.length >0){
this.counterServiceArray.forEach((item:any) =>{
if(item.destroyCounter && item.destroyCounter instanceof Function){
item.destroyCounter();
}
})
}
} }
/** /**
* 选中数据字符串 * 选中数据字符串
......
...@@ -65,15 +65,6 @@ export default class PayOpenAccessPickupViewBase extends Vue { ...@@ -65,15 +65,6 @@ export default class PayOpenAccessPickupViewBase extends Vue {
*/ */
public appUIService: PayOpenAccessUIService = new PayOpenAccessUIService(this.$store); public appUIService: PayOpenAccessUIService = new PayOpenAccessUIService(this.$store);
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayOpenAccessPickupViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 数据变化 * 数据变化
* *
...@@ -195,6 +186,8 @@ export default class PayOpenAccessPickupViewBase extends Vue { ...@@ -195,6 +186,8 @@ export default class PayOpenAccessPickupViewBase extends Vue {
_this.engine.load(); _this.engine.load();
}); });
} else if(!Object.is(newVal, oldVal) && _this.refresh() && Object.is(_this.$util.typeOf(_this.refresh()), 'function')) {
_this.refresh();
} }
} }
...@@ -307,6 +300,15 @@ export default class PayOpenAccessPickupViewBase extends Vue { ...@@ -307,6 +300,15 @@ export default class PayOpenAccessPickupViewBase extends Vue {
*/ */
public viewCacheData:any; public viewCacheData:any;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayOpenAccessPickupViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 解析视图参数 * 解析视图参数
* *
...@@ -609,6 +611,14 @@ export default class PayOpenAccessPickupViewBase extends Vue { ...@@ -609,6 +611,14 @@ export default class PayOpenAccessPickupViewBase extends Vue {
this.serviceStateEvent.unsubscribe(); this.serviceStateEvent.unsubscribe();
} }
} }
// 销毁计数器定时器
if(this.counterServiceArray && this.counterServiceArray.length >0){
this.counterServiceArray.forEach((item:any) =>{
if(item.destroyCounter && item.destroyCounter instanceof Function){
item.destroyCounter();
}
})
}
} }
/** /**
* 选中数据的字符串 * 选中数据的字符串
......
...@@ -153,15 +153,6 @@ export default class PayTradeEditViewBase extends Vue { ...@@ -153,15 +153,6 @@ export default class PayTradeEditViewBase extends Vue {
*/ */
public appUIService: PayTradeUIService = new PayTradeUIService(this.$store); public appUIService: PayTradeUIService = new PayTradeUIService(this.$store);
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayTradeEditViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 数据变化 * 数据变化
* *
...@@ -280,6 +271,8 @@ export default class PayTradeEditViewBase extends Vue { ...@@ -280,6 +271,8 @@ export default class PayTradeEditViewBase extends Vue {
_this.engine.load(); _this.engine.load();
}); });
} else if(!Object.is(newVal, oldVal) && _this.refresh() && Object.is(_this.$util.typeOf(_this.refresh()), 'function')) {
_this.refresh();
} }
} }
...@@ -424,6 +417,15 @@ export default class PayTradeEditViewBase extends Vue { ...@@ -424,6 +417,15 @@ export default class PayTradeEditViewBase extends Vue {
*/ */
public viewCacheData:any; public viewCacheData:any;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayTradeEditViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 解析视图参数 * 解析视图参数
* *
...@@ -1555,6 +1557,14 @@ export default class PayTradeEditViewBase extends Vue { ...@@ -1555,6 +1557,14 @@ export default class PayTradeEditViewBase extends Vue {
this.serviceStateEvent.unsubscribe(); this.serviceStateEvent.unsubscribe();
} }
} }
// 销毁计数器定时器
if(this.counterServiceArray && this.counterServiceArray.length >0){
this.counterServiceArray.forEach((item:any) =>{
if(item.destroyCounter && item.destroyCounter instanceof Function){
item.destroyCounter();
}
})
}
} }
......
...@@ -183,15 +183,6 @@ export default class PayTradeGridViewBase extends Vue { ...@@ -183,15 +183,6 @@ export default class PayTradeGridViewBase extends Vue {
*/ */
public appUIService: PayTradeUIService = new PayTradeUIService(this.$store); public appUIService: PayTradeUIService = new PayTradeUIService(this.$store);
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayTradeGridViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 数据变化 * 数据变化
* *
...@@ -310,6 +301,8 @@ export default class PayTradeGridViewBase extends Vue { ...@@ -310,6 +301,8 @@ export default class PayTradeGridViewBase extends Vue {
_this.engine.load(); _this.engine.load();
}); });
} else if(!Object.is(newVal, oldVal) && _this.refresh() && Object.is(_this.$util.typeOf(_this.refresh()), 'function')) {
_this.refresh();
} }
} }
...@@ -459,6 +452,15 @@ export default class PayTradeGridViewBase extends Vue { ...@@ -459,6 +452,15 @@ export default class PayTradeGridViewBase extends Vue {
*/ */
public viewCacheData:any; public viewCacheData:any;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof PayTradeGridViewBase
*/
public counterServiceArray:Array<any> = [];
/** /**
* 解析视图参数 * 解析视图参数
* *
...@@ -1578,6 +1580,14 @@ export default class PayTradeGridViewBase extends Vue { ...@@ -1578,6 +1580,14 @@ export default class PayTradeGridViewBase extends Vue {
this.serviceStateEvent.unsubscribe(); this.serviceStateEvent.unsubscribe();
} }
} }
// 销毁计数器定时器
if(this.counterServiceArray && this.counterServiceArray.length >0){
this.counterServiceArray.forEach((item:any) =>{
if(item.destroyCounter && item.destroyCounter instanceof Function){
item.destroyCounter();
}
})
}
} }
/** /**
......
/**
* 获取部门成员
*
* @param state
*/
export const getDepartmentPersonnel = (state: any) => () => {
return state.departmentPersonnel;
}
/** /**
* 获取代码表对象 * 获取代码表对象
* *
......
import { Environment } from '@/environments/environment'; import { Environment } from '@/environments/environment';
/**
* 添加部门成员
*
* @param state
* @param codelists
*/
export const addDepartmentPersonnel = (state: any, departmentPersonnel: Array<any>) => {
state.departmentPersonnel = [];
state.departmentPersonnel = [...departmentPersonnel];
}
/** /**
* 添加代码表 * 添加代码表
* *
...@@ -101,7 +112,7 @@ export const addPage = (state: any, arg: any) => { ...@@ -101,7 +112,7 @@ export const addPage = (state: any, arg: any) => {
// 视图类型为REDIRECTVIEW和NOTAB的视图不添加缓存 // 视图类型为REDIRECTVIEW和NOTAB的视图不添加缓存
if(Object.is(arg.meta.viewType, 'REDIRECTVIEW') || Object.is(arg.meta.viewType, 'NOTAB')){ if(Object.is(arg.meta.viewType, 'REDIRECTVIEW') || Object.is(arg.meta.viewType, 'NOTAB')){
return; return;
}else if(Object.is(arg.meta.viewType, 'APPINDEX')) { }else if (Object.is(arg.meta.viewType, 'APPINDEX')) {
window.sessionStorage.setItem(Environment.AppName, arg.fullPath); window.sessionStorage.setItem(Environment.AppName, arg.fullPath);
} else { } else {
const page: any = {}; const page: any = {};
......
...@@ -7,6 +7,7 @@ export const rootstate: any = { ...@@ -7,6 +7,7 @@ export const rootstate: any = {
pageMetas: [], pageMetas: [],
historyPathList: [], historyPathList: [],
codelists: [], codelists: [],
departmentPersonnel:[],
selectTheme: '', selectTheme: '',
selectFont: '', selectFont: '',
appdata: '', appdata: '',
......
...@@ -580,7 +580,7 @@ export default class PayIndexViewBase extends Vue implements ControlInterface { ...@@ -580,7 +580,7 @@ export default class PayIndexViewBase extends Vue implements ControlInterface {
* @memberof PayIndexViewBase * @memberof PayIndexViewBase
*/ */
public handleMenusResource(inputMenus:Array<any>){ public handleMenusResource(inputMenus:Array<any>){
if(Environment.enablePermissionValid){ if(this.$store.getters['authresource/getEnablePermissionValid']){
this.computedEffectiveMenus(inputMenus); this.computedEffectiveMenus(inputMenus);
this.computeParentMenus(inputMenus); this.computeParentMenus(inputMenus);
} }
......
...@@ -498,7 +498,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -498,7 +498,7 @@ export default class MainBase extends Vue implements ControlInterface {
public saveState:any ; public saveState:any ;
/** /**
* 属性值规则 * 值规则
* *
* @type {*} * @type {*}
* @memberof MainBase * @memberof MainBase
...@@ -1215,7 +1215,6 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -1215,7 +1215,6 @@ export default class MainBase extends Vue implements ControlInterface {
* @memberof MainBase * @memberof MainBase
*/ */
public computeButtonState(data:any){ public computeButtonState(data:any){
if(Environment.enablePermissionValid){
let targetData:any = this.transformData(data); let targetData:any = this.transformData(data);
if(this.detailsModel && Object.keys(this.detailsModel).length >0){ if(this.detailsModel && Object.keys(this.detailsModel).length >0){
Object.keys(this.detailsModel).forEach((name:any) =>{ Object.keys(this.detailsModel).forEach((name:any) =>{
...@@ -1230,7 +1229,6 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -1230,7 +1229,6 @@ export default class MainBase extends Vue implements ControlInterface {
}) })
} }
} }
}
......
...@@ -116,7 +116,61 @@ ...@@ -116,7 +116,61 @@
} }
} }
} }
.cell-indeterminate {
>div>label {
>span {
.el-checkbox__inner {
background-color: #409eff;
border-color: #409eff;
}
.el-checkbox__inner:before {
content: "";
position: absolute;
display: block;
background-color: #fff;
height: 2px;
transform: scale(.5);
left: 0;
right: 0;
top: 5px;
}
}
>span.is-checked {
.el-checkbox__inner {
background-color: #409eff;
border-color: #409eff;
}
.el-checkbox__inner:after {
border: 0px;
}
}
}
}
.cell-select-all {
>div>label {
>span {
.el-checkbox__inner {
background-color: #409eff;
border-color: #409eff;
}
.el-checkbox__inner:after {
box-sizing: content-box;
content: "";
border: 1px solid #fff;
border-left: 0;
border-top: 0;
height: 7px;
left: 4px;
position: absolute;
top: 1px;
transform: rotate(45deg) scaleY(1);
width: 3px;
transition: transform .15s ease-in .05s;
transform-origin: center;
}
}
}
}
// this is less // this is less
...@@ -255,7 +255,7 @@ export default class PickupViewpickupviewpanelBase extends Vue implements Contro ...@@ -255,7 +255,7 @@ export default class PickupViewpickupviewpanelBase extends Vue implements Contro
public onViewDatasChange($event: any): void { public onViewDatasChange($event: any): void {
if($event.length>0){ if($event.length>0){
$event.forEach((item:any,index:any) => { $event.forEach((item:any,index:any) => {
let srfmajortext = item['name']; let srfmajortext = item.srfmajortext?item.srfmajortext:item['name'];
if(srfmajortext){ if(srfmajortext){
Object.assign($event[index],{srfmajortext: srfmajortext}); Object.assign($event[index],{srfmajortext: srfmajortext});
} }
......
...@@ -468,7 +468,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -468,7 +468,7 @@ export default class MainBase extends Vue implements ControlInterface {
public saveState:any ; public saveState:any ;
/** /**
* 属性值规则 * 值规则
* *
* @type {*} * @type {*}
* @memberof MainBase * @memberof MainBase
...@@ -1143,7 +1143,6 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -1143,7 +1143,6 @@ export default class MainBase extends Vue implements ControlInterface {
* @memberof MainBase * @memberof MainBase
*/ */
public computeButtonState(data:any){ public computeButtonState(data:any){
if(Environment.enablePermissionValid){
let targetData:any = this.transformData(data); let targetData:any = this.transformData(data);
if(this.detailsModel && Object.keys(this.detailsModel).length >0){ if(this.detailsModel && Object.keys(this.detailsModel).length >0){
Object.keys(this.detailsModel).forEach((name:any) =>{ Object.keys(this.detailsModel).forEach((name:any) =>{
...@@ -1158,7 +1157,6 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -1158,7 +1157,6 @@ export default class MainBase extends Vue implements ControlInterface {
}) })
} }
} }
}
......
...@@ -116,7 +116,61 @@ ...@@ -116,7 +116,61 @@
} }
} }
} }
.cell-indeterminate {
>div>label {
>span {
.el-checkbox__inner {
background-color: #409eff;
border-color: #409eff;
}
.el-checkbox__inner:before {
content: "";
position: absolute;
display: block;
background-color: #fff;
height: 2px;
transform: scale(.5);
left: 0;
right: 0;
top: 5px;
}
}
>span.is-checked {
.el-checkbox__inner {
background-color: #409eff;
border-color: #409eff;
}
.el-checkbox__inner:after {
border: 0px;
}
}
}
}
.cell-select-all {
>div>label {
>span {
.el-checkbox__inner {
background-color: #409eff;
border-color: #409eff;
}
.el-checkbox__inner:after {
box-sizing: content-box;
content: "";
border: 1px solid #fff;
border-left: 0;
border-top: 0;
height: 7px;
left: 4px;
position: absolute;
top: 1px;
transform: rotate(45deg) scaleY(1);
width: 3px;
transition: transform .15s ease-in .05s;
transform-origin: center;
}
}
}
}
// this is less // this is less
...@@ -22,6 +22,7 @@ import org.springframework.data.domain.PageImpl; ...@@ -22,6 +22,7 @@ import org.springframework.data.domain.PageImpl;
import org.springframework.data.domain.Pageable; import org.springframework.data.domain.Pageable;
import org.springframework.util.ObjectUtils; import org.springframework.util.ObjectUtils;
import org.springframework.beans.factory.annotation.Value; import org.springframework.beans.factory.annotation.Value;
import cn.ibizlab.util.errors.BadRequestAlertException;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.springframework.context.annotation.Lazy; import org.springframework.context.annotation.Lazy;
import cn.ibizlab.core.pay.domain.PayOpenAccess; import cn.ibizlab.core.pay.domain.PayOpenAccess;
...@@ -35,6 +36,7 @@ import cn.ibizlab.util.helper.DEFieldCacheMap; ...@@ -35,6 +36,7 @@ import cn.ibizlab.util.helper.DEFieldCacheMap;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import cn.ibizlab.core.pay.mapper.PayOpenAccessMapper; 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.Wrapper; import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import org.springframework.util.StringUtils; import org.springframework.util.StringUtils;
...@@ -62,6 +64,7 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P ...@@ -62,6 +64,7 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P
} }
@Override @Override
@Transactional
public void createBatch(List<PayOpenAccess> list) { public void createBatch(List<PayOpenAccess> list) {
this.saveBatch(list,batchSize); this.saveBatch(list,batchSize);
} }
...@@ -76,6 +79,7 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P ...@@ -76,6 +79,7 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P
} }
@Override @Override
@Transactional
public void updateBatch(List<PayOpenAccess> list) { public void updateBatch(List<PayOpenAccess> list) {
updateBatchById(list,batchSize); updateBatchById(list,batchSize);
} }
...@@ -88,6 +92,7 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P ...@@ -88,6 +92,7 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P
} }
@Override @Override
@Transactional
public void removeBatch(Collection<String> idList) { public void removeBatch(Collection<String> idList) {
removeByIds(idList); removeByIds(idList);
} }
...@@ -133,12 +138,14 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P ...@@ -133,12 +138,14 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P
} }
@Override @Override
@Transactional
public boolean saveBatch(Collection<PayOpenAccess> list) { public boolean saveBatch(Collection<PayOpenAccess> list) {
saveOrUpdateBatch(list,batchSize); saveOrUpdateBatch(list,batchSize);
return true; return true;
} }
@Override @Override
@Transactional
public void saveBatch(List<PayOpenAccess> list) { public void saveBatch(List<PayOpenAccess> list) {
saveOrUpdateBatch(list,batchSize); saveOrUpdateBatch(list,batchSize);
} }
...@@ -185,6 +192,7 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P ...@@ -185,6 +192,7 @@ public class PayOpenAccessServiceImpl extends ServiceImpl<PayOpenAccessMapper, P
} }
} }
......
...@@ -22,6 +22,7 @@ import org.springframework.data.domain.PageImpl; ...@@ -22,6 +22,7 @@ import org.springframework.data.domain.PageImpl;
import org.springframework.data.domain.Pageable; import org.springframework.data.domain.Pageable;
import org.springframework.util.ObjectUtils; import org.springframework.util.ObjectUtils;
import org.springframework.beans.factory.annotation.Value; import org.springframework.beans.factory.annotation.Value;
import cn.ibizlab.util.errors.BadRequestAlertException;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.springframework.context.annotation.Lazy; import org.springframework.context.annotation.Lazy;
import cn.ibizlab.core.pay.domain.PayTrade; import cn.ibizlab.core.pay.domain.PayTrade;
...@@ -35,6 +36,7 @@ import cn.ibizlab.util.helper.DEFieldCacheMap; ...@@ -35,6 +36,7 @@ import cn.ibizlab.util.helper.DEFieldCacheMap;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import cn.ibizlab.core.pay.mapper.PayTradeMapper; 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.Wrapper; import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import org.springframework.util.StringUtils; import org.springframework.util.StringUtils;
...@@ -63,6 +65,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i ...@@ -63,6 +65,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i
} }
@Override @Override
@Transactional
public void createBatch(List<PayTrade> list) { public void createBatch(List<PayTrade> list) {
list.forEach(item->fillParentData(item)); list.forEach(item->fillParentData(item));
this.saveOrUpdateBatch(list,batchSize); this.saveOrUpdateBatch(list,batchSize);
...@@ -79,6 +82,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i ...@@ -79,6 +82,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i
} }
@Override @Override
@Transactional
public void updateBatch(List<PayTrade> list) { public void updateBatch(List<PayTrade> list) {
list.forEach(item->fillParentData(item)); list.forEach(item->fillParentData(item));
updateBatchById(list,batchSize); updateBatchById(list,batchSize);
...@@ -92,6 +96,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i ...@@ -92,6 +96,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i
} }
@Override @Override
@Transactional
public void removeBatch(Collection<String> idList) { public void removeBatch(Collection<String> idList) {
removeByIds(idList); removeByIds(idList);
} }
...@@ -138,6 +143,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i ...@@ -138,6 +143,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i
} }
@Override @Override
@Transactional
public boolean saveBatch(Collection<PayTrade> list) { public boolean saveBatch(Collection<PayTrade> list) {
list.forEach(item->fillParentData(item)); list.forEach(item->fillParentData(item));
saveOrUpdateBatch(list,batchSize); saveOrUpdateBatch(list,batchSize);
...@@ -145,6 +151,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i ...@@ -145,6 +151,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i
} }
@Override @Override
@Transactional
public void saveBatch(List<PayTrade> list) { public void saveBatch(List<PayTrade> list) {
list.forEach(item->fillParentData(item)); list.forEach(item->fillParentData(item));
saveOrUpdateBatch(list,batchSize); saveOrUpdateBatch(list,batchSize);
...@@ -219,6 +226,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i ...@@ -219,6 +226,7 @@ public class PayTradeServiceImpl extends ServiceImpl<PayTradeMapper, PayTrade> i
} }
} }
......
...@@ -12,6 +12,9 @@ import com.fasterxml.jackson.annotation.JsonIgnore; ...@@ -12,6 +12,9 @@ import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonFormat; import com.fasterxml.jackson.annotation.JsonFormat;
import com.alibaba.fastjson.annotation.JSONField; import com.alibaba.fastjson.annotation.JSONField;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import cn.ibizlab.util.domain.DTOBase; import cn.ibizlab.util.domain.DTOBase;
import cn.ibizlab.util.domain.DTOClient; import cn.ibizlab.util.domain.DTOClient;
import lombok.Data; import lombok.Data;
...@@ -30,6 +33,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable { ...@@ -30,6 +33,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "id") @JSONField(name = "id")
@JsonProperty("id") @JsonProperty("id")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String id; private String id;
/** /**
...@@ -38,6 +42,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable { ...@@ -38,6 +42,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "name") @JSONField(name = "name")
@JsonProperty("name") @JsonProperty("name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String name; private String name;
/** /**
...@@ -46,6 +51,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable { ...@@ -46,6 +51,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "open_type") @JSONField(name = "open_type")
@JsonProperty("open_type") @JsonProperty("open_type")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String openType; private String openType;
/** /**
...@@ -54,6 +60,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable { ...@@ -54,6 +60,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "access_key") @JSONField(name = "access_key")
@JsonProperty("access_key") @JsonProperty("access_key")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String accessKey; private String accessKey;
/** /**
...@@ -62,6 +69,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable { ...@@ -62,6 +69,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "secret_key") @JSONField(name = "secret_key")
@JsonProperty("secret_key") @JsonProperty("secret_key")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String secretKey; private String secretKey;
/** /**
...@@ -70,6 +78,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable { ...@@ -70,6 +78,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "region_id") @JSONField(name = "region_id")
@JsonProperty("region_id") @JsonProperty("region_id")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String regionId; private String regionId;
/** /**
...@@ -78,6 +87,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable { ...@@ -78,6 +87,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "access_token") @JSONField(name = "access_token")
@JsonProperty("access_token") @JsonProperty("access_token")
@Size(min = 0, max = 1000, message = "内容长度必须小于等于[1000]")
private String accessToken; private String accessToken;
/** /**
...@@ -103,6 +113,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable { ...@@ -103,6 +113,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "redirect_uri") @JSONField(name = "redirect_uri")
@JsonProperty("redirect_uri") @JsonProperty("redirect_uri")
@Size(min = 0, max = 500, message = "内容长度必须小于等于[500]")
private String redirectUri; private String redirectUri;
/** /**
...@@ -111,6 +122,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable { ...@@ -111,6 +122,7 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "notify_url") @JSONField(name = "notify_url")
@JsonProperty("notify_url") @JsonProperty("notify_url")
@Size(min = 0, max = 500, message = "内容长度必须小于等于[500]")
private String notifyUrl; private String notifyUrl;
...@@ -197,3 +209,4 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable { ...@@ -197,3 +209,4 @@ public class PayOpenAccessDTO extends DTOBase implements Serializable {
} }
...@@ -12,6 +12,9 @@ import com.fasterxml.jackson.annotation.JsonIgnore; ...@@ -12,6 +12,9 @@ import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonFormat; import com.fasterxml.jackson.annotation.JsonFormat;
import com.alibaba.fastjson.annotation.JSONField; import com.alibaba.fastjson.annotation.JSONField;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import cn.ibizlab.util.domain.DTOBase; import cn.ibizlab.util.domain.DTOBase;
import cn.ibizlab.util.domain.DTOClient; import cn.ibizlab.util.domain.DTOClient;
import lombok.Data; import lombok.Data;
...@@ -30,6 +33,7 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -30,6 +33,7 @@ public class PayTradeDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "subject") @JSONField(name = "subject")
@JsonProperty("subject") @JsonProperty("subject")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String subject; private String subject;
/** /**
...@@ -38,6 +42,7 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -38,6 +42,7 @@ public class PayTradeDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "total_amount") @JSONField(name = "total_amount")
@JsonProperty("total_amount") @JsonProperty("total_amount")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String totalAmount; private String totalAmount;
/** /**
...@@ -46,6 +51,7 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -46,6 +51,7 @@ public class PayTradeDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "trade_name") @JSONField(name = "trade_name")
@JsonProperty("trade_name") @JsonProperty("trade_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String tradeName; private String tradeName;
/** /**
...@@ -54,6 +60,7 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -54,6 +60,7 @@ public class PayTradeDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "trade_type") @JSONField(name = "trade_type")
@JsonProperty("trade_type") @JsonProperty("trade_type")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String tradeType; private String tradeType;
/** /**
...@@ -62,6 +69,7 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -62,6 +69,7 @@ public class PayTradeDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "trade_status") @JSONField(name = "trade_status")
@JsonProperty("trade_status") @JsonProperty("trade_status")
@Size(min = 0, max = 60, message = "内容长度必须小于等于[60]")
private String tradeStatus; private String tradeStatus;
/** /**
...@@ -70,6 +78,7 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -70,6 +78,7 @@ public class PayTradeDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "out_trade_no") @JSONField(name = "out_trade_no")
@JsonProperty("out_trade_no") @JsonProperty("out_trade_no")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String outTradeNo; private String outTradeNo;
/** /**
...@@ -78,6 +87,7 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -78,6 +87,7 @@ public class PayTradeDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "trade_id") @JSONField(name = "trade_id")
@JsonProperty("trade_id") @JsonProperty("trade_id")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String tradeId; private String tradeId;
/** /**
...@@ -86,6 +96,7 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -86,6 +96,7 @@ public class PayTradeDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "app_id") @JSONField(name = "app_id")
@JsonProperty("app_id") @JsonProperty("app_id")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String appId; private String appId;
/** /**
...@@ -94,6 +105,7 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -94,6 +105,7 @@ public class PayTradeDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "access_name") @JSONField(name = "access_name")
@JsonProperty("access_name") @JsonProperty("access_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String accessName; private String accessName;
/** /**
...@@ -102,6 +114,7 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -102,6 +114,7 @@ public class PayTradeDTO extends DTOBase implements Serializable {
*/ */
@JSONField(name = "access_id") @JSONField(name = "access_id")
@JsonProperty("access_id") @JsonProperty("access_id")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String accessId; private String accessId;
...@@ -180,3 +193,4 @@ public class PayTradeDTO extends DTOBase implements Serializable { ...@@ -180,3 +193,4 @@ public class PayTradeDTO extends DTOBase implements Serializable {
} }
...@@ -22,6 +22,7 @@ import org.springframework.util.StringUtils; ...@@ -22,6 +22,7 @@ import org.springframework.util.StringUtils;
import org.springframework.context.annotation.Lazy; import org.springframework.context.annotation.Lazy;
import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.security.access.prepost.PostAuthorize; import org.springframework.security.access.prepost.PostAuthorize;
import org.springframework.validation.annotation.Validated;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiResponse; import io.swagger.annotations.ApiResponse;
...@@ -49,7 +50,7 @@ public class PayOpenAccessResource { ...@@ -49,7 +50,7 @@ public class PayOpenAccessResource {
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzpay-PayOpenAccess-Create-all')") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzpay-PayOpenAccess-Create-all')")
@ApiOperation(value = "新建支付平台", tags = {"支付平台" }, notes = "新建支付平台") @ApiOperation(value = "新建支付平台", tags = {"支付平台" }, notes = "新建支付平台")
@RequestMapping(method = RequestMethod.POST, value = "/payopenaccesses") @RequestMapping(method = RequestMethod.POST, value = "/payopenaccesses")
public ResponseEntity<PayOpenAccessDTO> create(@RequestBody PayOpenAccessDTO payopenaccessdto) { public ResponseEntity<PayOpenAccessDTO> create(@Validated @RequestBody PayOpenAccessDTO payopenaccessdto) {
PayOpenAccess domain = payopenaccessMapping.toDomain(payopenaccessdto); PayOpenAccess domain = payopenaccessMapping.toDomain(payopenaccessdto);
payopenaccessService.create(domain); payopenaccessService.create(domain);
PayOpenAccessDTO dto = payopenaccessMapping.toDto(domain); PayOpenAccessDTO dto = payopenaccessMapping.toDto(domain);
......
...@@ -22,6 +22,7 @@ import org.springframework.util.StringUtils; ...@@ -22,6 +22,7 @@ import org.springframework.util.StringUtils;
import org.springframework.context.annotation.Lazy; import org.springframework.context.annotation.Lazy;
import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.security.access.prepost.PostAuthorize; import org.springframework.security.access.prepost.PostAuthorize;
import org.springframework.validation.annotation.Validated;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiResponse; import io.swagger.annotations.ApiResponse;
...@@ -49,7 +50,7 @@ public class PayTradeResource { ...@@ -49,7 +50,7 @@ public class PayTradeResource {
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzpay-PayTrade-Create-all')") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzpay-PayTrade-Create-all')")
@ApiOperation(value = "新建支付交易1", tags = {"支付交易1" }, notes = "新建支付交易1") @ApiOperation(value = "新建支付交易1", tags = {"支付交易1" }, notes = "新建支付交易1")
@RequestMapping(method = RequestMethod.POST, value = "/paytrades") @RequestMapping(method = RequestMethod.POST, value = "/paytrades")
public ResponseEntity<PayTradeDTO> create(@RequestBody PayTradeDTO paytradedto) { public ResponseEntity<PayTradeDTO> create(@Validated @RequestBody PayTradeDTO paytradedto) {
PayTrade domain = paytradeMapping.toDomain(paytradedto); PayTrade domain = paytradeMapping.toDomain(paytradedto);
paytradeService.create(domain); paytradeService.create(domain);
PayTradeDTO dto = paytradeMapping.toDto(domain); PayTradeDTO dto = paytradeMapping.toDto(domain);
......
...@@ -213,7 +213,7 @@ public class DEFieldDefaultValueAspect ...@@ -213,7 +213,7 @@ public class DEFieldDefaultValueAspect
private void fillPreFieldValue(String fieldname , DEPredefinedFieldType preFieldType ,EntityBase et , String actionName,String logicValue ,AuthenticationUser curUser) throws Exception { private void fillPreFieldValue(String fieldname , DEPredefinedFieldType preFieldType ,EntityBase et , String actionName,String logicValue ,AuthenticationUser curUser) throws Exception {
Object fieldValue = et.get(fieldname); Object fieldValue = et.get(fieldname);
//为预置属性进行赋值 //为预置属性进行赋值
if( actionName.equalsIgnoreCase("create")|| if( actionName.toLowerCase().startsWith("create") ||
preFieldType== DEPredefinedFieldType.UPDATEDATE|| preFieldType== DEPredefinedFieldType.UPDATEMAN|| preFieldType== DEPredefinedFieldType.UPDATEDATE|| preFieldType== DEPredefinedFieldType.UPDATEMAN||
preFieldType== DEPredefinedFieldType.UPDATEMANNAME){ preFieldType== DEPredefinedFieldType.UPDATEMANNAME){
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册