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

ibiz4j 发布系统代码

上级 7e25c3ea
## v7.0.0-alpha.20 [2020-10-18]
### Bug修复
修复获取数据对象的主状态值统一转字符串处理逻辑
修复表单空输入异常问题
修复下拉数据数据加载异常问题
修复表单分页图标重复发布异常
修复数据选择增加外键值附加数据回填逻辑
修复表格行编辑可设置数据主键和清空仿真主键问题
修复代码表返回数据不合法抛出的异常
修复表单值规则部分逻辑
修复导航类视图修改右侧表单数据时,只能跳转第一条数据BUG
### 功能新增及优化
#### 模板
新增动态表单支持
新增视图消息支持
新增表单、面板、工具栏、数据看板直接内容项支持
新增日历项支持标识属性和文本属性
新增应用组件包支持
新增导航工具栏权限控制支持
新增图表绘制最终参数
新增门户部件界面行为组权限校验
新增表单、表格数据对象方式新建、更新默认值
新增导航视图搜索框提示可搜索字段名称
新增部件逻辑插件支持
新增工具栏、工具栏项插件支持
优化调整代码表服务基类位置
#### 基础文件
新增动态表单组件、直接内容项组件、视图消息组组件和视图消息组件
优化导航类部件工具栏状态逻辑
修复表单空输入异常问题
修复下拉数据数据加载异常
修复关系页第一次进入不加载问题
## v7.0.0-alpha.19 [2020-9-13] ## v7.0.0-alpha.19 [2020-9-13]
### Bug修复 ### Bug修复
......
import store from '@/store'; import store from '@/store';
import { Environment } from '@/environments/environment';
/** /**
* 实体权限服务 * 实体权限服务
* *
...@@ -115,8 +117,14 @@ export default class AuthService { ...@@ -115,8 +117,14 @@ export default class AuthService {
if(!this.$store.getters['authresource/getEnablePermissionValid']) { if(!this.$store.getters['authresource/getEnablePermissionValid']) {
return true; return true;
} }
if(Object.is(Environment.menuPermissionMode,"RT")){
return this.$store.getters['authresource/getAuthMenuWithRT'](item);
}else if(Object.is(Environment.menuPermissionMode,"RESOURCE")){
return this.$store.getters['authresource/getAuthMenuWithResource'](item);
}else{
return this.$store.getters['authresource/getAuthMenu'](item); return this.$store.getters['authresource/getAuthMenu'](item);
} }
}
/** /**
* 根据统一资源标识获取统一资源权限 * 根据统一资源标识获取统一资源权限
......
...@@ -149,10 +149,11 @@ export default class CodeListService { ...@@ -149,10 +149,11 @@ export default class CodeListService {
// 启用缓存 // 启用缓存
if(isEnableCache){ if(isEnableCache){
const callback:Function = (context:any ={},data:any ={},tag:string,promise:Promise<any>) =>{ const callback:Function = (context:any ={},data:any ={},tag:string,promise:Promise<any>) =>{
const callbackKey:string = `${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`;
promise.then((result:any) =>{ promise.then((result:any) =>{
if(result.length > 0){ if(result.length > 0){
CodeListService.codelistCached.set(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`,{items:result}); CodeListService.codelistCached.set(callbackKey,{items:result});
CodeListService.codelistCache.delete(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`); CodeListService.codelistCache.delete(callbackKey);
return resolve(result); return resolve(result);
}else{ }else{
return resolve([]); return resolve([]);
...@@ -162,8 +163,9 @@ export default class CodeListService { ...@@ -162,8 +163,9 @@ export default class CodeListService {
}) })
} }
// 加载完成,从本地缓存获取 // 加载完成,从本地缓存获取
if(CodeListService.codelistCached.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`)){ const key:string = `${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`;
let items:any = CodeListService.codelistCached.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`).items; if(CodeListService.codelistCached.get(key)){
let items:any = CodeListService.codelistCached.get(key).items;
if(items.length >0){ if(items.length >0){
if(new Date().getTime() <= codelist.getExpirationTime()){ if(new Date().getTime() <= codelist.getExpirationTime()){
return resolve(items); return resolve(items);
...@@ -172,11 +174,11 @@ export default class CodeListService { ...@@ -172,11 +174,11 @@ export default class CodeListService {
} }
if (codelist) { if (codelist) {
// 加载中,UI又需要数据,解决连续加载同一代码表问题 // 加载中,UI又需要数据,解决连续加载同一代码表问题
if(CodeListService.codelistCache.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`)){ if(CodeListService.codelistCache.get(key)){
callback(context,data,tag,CodeListService.codelistCache.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`)); callback(context,data,tag,CodeListService.codelistCache.get(key));
}else{ }else{
let result:Promise<any> = codelist.getItems(context,data,isloading); let result:Promise<any> = codelist.getItems(context,data,isloading);
CodeListService.codelistCache.set(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`,result); CodeListService.codelistCache.set(key,result);
codelist.setExpirationTime(new Date().getTime() + cacheTimeout); codelist.setExpirationTime(new Date().getTime() + cacheTimeout);
callback(context,data,tag,result); callback(context,data,tag,result);
} }
......
...@@ -66,7 +66,7 @@ export default class AppActionBar extends Vue { ...@@ -66,7 +66,7 @@ export default class AppActionBar extends Vue {
public created(){ public created(){
if (this.viewState) { if (this.viewState) {
this.viewStateEvent = this.viewState.subscribe(({ tag, action, data }) => { this.viewStateEvent = this.viewState.subscribe(({ tag, action, data }) => {
if (!Object.is(tag, "app-actionbar")) { if (!Object.is(tag, "all-portlet")) {
return; return;
} }
if(Object.is(action,'loadmodel')){ if(Object.is(action,'loadmodel')){
...@@ -107,7 +107,7 @@ export default class AppActionBar extends Vue { ...@@ -107,7 +107,7 @@ export default class AppActionBar extends Vue {
const _item = ActionModel[key]; const _item = ActionModel[key];
if(_item && _item['dataaccaction'] && UIService){ if(_item && _item['dataaccaction'] && UIService){
let dataActionResult:any; let dataActionResult:any;
if(Object.is(_item['actiontarget'],"NONE")){ if(Object.is(_item['actiontarget'],"NONE") || Object.is(_item['actiontarget'],"")){
dataActionResult = UIService.getResourceOPPrivs(_item['dataaccaction']); dataActionResult = UIService.getResourceOPPrivs(_item['dataaccaction']);
}else{ }else{
if(data && Object.keys(data).length >0){ if(data && Object.keys(data).length >0){
......
...@@ -4,7 +4,11 @@ ...@@ -4,7 +4,11 @@
<app-alert <app-alert
:key="index" :key="index"
:tag="item.tag" :tag="item.tag"
:position="item.position"/> :context="context"
:viewparam="viewparam"
:position="item.position"
:infoGroup="infoGroup"
:viewname="viewname"/>
</template> </template>
</div> </div>
...@@ -32,6 +36,23 @@ export default class AppAlertGroup extends Vue { ...@@ -32,6 +36,23 @@ export default class AppAlertGroup extends Vue {
*/ */
@Prop() infoGroup: any; @Prop() infoGroup: any;
/**
* 应用上下文
*
* @type {any}
* @memberof AppAlertGroup
*/
@Prop() context: any;
/**
* 视图参数
*
* @type {any}
* @memberof AppAlertGroup
*/
@Prop() viewparam: any;
/** /**
* 视图消息组显示位置 * 视图消息组显示位置
* *
...@@ -40,6 +61,14 @@ export default class AppAlertGroup extends Vue { ...@@ -40,6 +61,14 @@ export default class AppAlertGroup extends Vue {
*/ */
@Prop() position: any; @Prop() position: any;
/**
* 视图名称
*
* @type {any}
* @memberof AppAlertGroup
*/
@Prop() viewname: any;
/** /**
* 当前位置视图消息集合 * 当前位置视图消息集合
* *
......
...@@ -44,6 +44,39 @@ export default class AppAlert extends Vue { ...@@ -44,6 +44,39 @@ export default class AppAlert extends Vue {
*/ */
@Prop() position: any; @Prop() position: any;
/**
* 应用上下文
*
* @type {any}
* @memberof AppAlert
*/
@Prop() context: any;
/**
* 视图参数
*
* @type {any}
* @memberof AppAlert
*/
@Prop() viewparam: any;
/**
* 视图消息组tag
*
* @type {any}
* @memberof AppAlert
*/
@Prop() infoGroup!: any;
/**
* 视图名称
*
* @type {any}
* @memberof AppAlert
*/
@Prop() viewname!: any;
/** /**
* 视图消息对象 * 视图消息对象
* *
...@@ -79,7 +112,7 @@ export default class AppAlert extends Vue { ...@@ -79,7 +112,7 @@ export default class AppAlert extends Vue {
* @memberof AppAlert * @memberof AppAlert
*/ */
public async getData() { public async getData() {
let response: any = await this.viewMessageService.getViewMessageByTag(this.tag, null, null) let response: any = await this.viewMessageService.getViewMessageByTag(this.tag, this.context, this.viewparam);
if(response && response.length > 0) { if(response && response.length > 0) {
response.forEach((item: any) => { response.forEach((item: any) => {
let tempData: any = JSON.parse(JSON.stringify(item)); let tempData: any = JSON.parse(JSON.stringify(item));
...@@ -118,7 +151,8 @@ export default class AppAlert extends Vue { ...@@ -118,7 +151,8 @@ export default class AppAlert extends Vue {
data.showState = true; data.showState = true;
if(data.closeMode || data.closeMode == 0) { if(data.closeMode || data.closeMode == 0) {
if(data.closeMode == 1) { if(data.closeMode == 1) {
const id = this.$store.getters.getViewMessage(data.codename); const tag = this.viewname + '_' + this.infoGroup + '_' + data.codename;
const id = localStorage.getItem(tag);
if(id) { if(id) {
data.showState = false; data.showState = false;
flag = false; flag = false;
...@@ -182,14 +216,14 @@ export default class AppAlert extends Vue { ...@@ -182,14 +216,14 @@ export default class AppAlert extends Vue {
let tempArr: any[] = data.customClass.toString().split(','); let tempArr: any[] = data.customClass.toString().split(',');
if(tempArr && tempArr.length > 0) { if(tempArr && tempArr.length > 0) {
if(Object.is("1", tempArr[1])) { if(Object.is("1", tempArr[1])) {
const args = { tag: tempArr[0], id: data.customClass }; const tag = this.viewname + '_' + this.infoGroup + '_' + tempArr[0];
this.$store.commit('addViewMessage', args); localStorage.setItem(tag, data.customClass);
} }
} }
} }
if(data.closeMode && data.closeMode == 1) { if(data.closeMode && data.closeMode == 1) {
const args = {tag: data.codename, id: data.id}; const tag = this.viewname + '_' + this.infoGroup + '_' + data.codename;
this.$store.commit('addViewMessage', args); localStorage.setItem(tag,data.id);
} }
} }
......
<template> <template>
<el-breadcrumb class="app-breadcrumb" separator="/"> <el-breadcrumb class="app-breadcrumb" :separator="separator">
<transition-group name="breadcrumb"> <transition-group name="breadcrumb">
<template v-if="Object.is(this.navModel,'route')"> <template v-if="Object.is(this.navModel,'route')">
<el-breadcrumb-item v-for="(item, index) in breadcrumbs" :key="item.id"> <el-breadcrumb-item v-for="(item, index) in breadcrumbs" :key="item.id">
...@@ -34,6 +34,7 @@ ...@@ -34,6 +34,7 @@
import { Component, Vue, Watch, Prop } from 'vue-property-decorator' import { Component, Vue, Watch, Prop } from 'vue-property-decorator'
import { RouteRecord, Route } from 'vue-router' import { RouteRecord, Route } from 'vue-router'
import { Environment } from "@/environments/environment"; import { Environment } from "@/environments/environment";
import { appConfig } from '@/config/appConfig';
import NavDataService from '@/service/app/navdata-service'; import NavDataService from '@/service/app/navdata-service';
import {Subscription } from 'rxjs'; import {Subscription } from 'rxjs';
...@@ -48,6 +49,13 @@ export default class Breadcrumb extends Vue { ...@@ -48,6 +49,13 @@ export default class Breadcrumb extends Vue {
*/ */
private breadcrumbs: Array<any> = []; private breadcrumbs: Array<any> = [];
/**
* 面包屑分隔符
*
* @memberof Breadcrumb
*/
private separator:string = appConfig.breadcrumbSeparator;
/** /**
* 导航服务 * 导航服务
* *
......
...@@ -165,7 +165,7 @@ export default class AppFormGroup extends Vue { ...@@ -165,7 +165,7 @@ export default class AppFormGroup extends Vue {
const _item = ActionModel[key]; const _item = ActionModel[key];
if(_item && _item['dataaccaction'] && UIService){ if(_item && _item['dataaccaction'] && UIService){
let dataActionResult:any; let dataActionResult:any;
if(Object.is(_item['actiontarget'],"NONE")){ if(Object.is(_item['actiontarget'],"NONE") || Object.is(_item['actiontarget'],"")){
dataActionResult = UIService.getResourceOPPrivs(_item['dataaccaction']); dataActionResult = UIService.getResourceOPPrivs(_item['dataaccaction']);
}else{ }else{
if(data && Object.keys(data).length >0){ if(data && Object.keys(data).length >0){
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
</ul> </ul>
<!-- 预览 --> <!-- 预览 -->
<modal v-model="dialogVisible" footer-hide width="auto" class-name='app-image-preview-model'> <modal v-model="dialogVisible" footer-hide width="auto" class-name='app-image-preview-model'>
<el-image src="dialogImageUrl"> <el-image :src="dialogImageUrl">
<div slot='error' class='image-slot'> <div slot='error' class='image-slot'>
<img src="/assets/img/picture.png"> <img src="/assets/img/picture.png">
</div> </div>
......
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
</el-upload> </el-upload>
<!-- 预览 --> <!-- 预览 -->
<modal v-model="dialogVisible" footer-hide class-name='app-image-upload-model'> <modal v-model="dialogVisible" footer-hide class-name='app-image-upload-model'>
<el-image src="dialogImageUrl"> <el-image :src="dialogImageUrl">
<div slot='error' class='image-slot'> <div slot='error' class='image-slot'>
<i class='el-icon-picture-outline'></i> <i class='el-icon-picture-outline'></i>
</div> </div>
......
...@@ -35,5 +35,7 @@ export const appConfig = { ...@@ -35,5 +35,7 @@ export const appConfig = {
label: 'YouYuan', label: 'YouYuan',
value: 'YouYuan', value: 'YouYuan',
}, },
] ],
// 面包屑分隔符
breadcrumbSeparator:"/"
} }
\ No newline at end of file
...@@ -81,9 +81,6 @@ export default class CalendarExpViewEngine extends ViewEngine { ...@@ -81,9 +81,6 @@ export default class CalendarExpViewEngine extends ViewEngine {
this.view.$emit('viewload', args); this.view.$emit('viewload', args);
} }
if (Object.is(eventName, 'selectionchange')) { if (Object.is(eventName, 'selectionchange')) {
if(this.calendarExpBar && this.calendarExpBar.calcNavigationToolbarState && this.calendarExpBar.calcNavigationToolbarState instanceof Function){
this.calendarExpBar.calcNavigationToolbarState();
}
this.view.$emit('viewdataschange', args); this.view.$emit('viewdataschange', args);
} }
if (Object.is(eventName, 'activated')) { if (Object.is(eventName, 'activated')) {
......
...@@ -78,9 +78,6 @@ export default class DataViewExpViewEngine extends ViewEngine { ...@@ -78,9 +78,6 @@ export default class DataViewExpViewEngine extends ViewEngine {
*/ */
public dataviewExpBarEvent(eventName: string, args: any): void { public dataviewExpBarEvent(eventName: string, args: any): void {
if (Object.is(eventName, 'load')) { if (Object.is(eventName, 'load')) {
if(this.dataviewExpBar && this.dataviewExpBar.calcNavigationToolbarState && this.dataviewExpBar.calcNavigationToolbarState instanceof Function){
this.dataviewExpBar.calcNavigationToolbarState();
}
this.view.$emit('viewload', args); this.view.$emit('viewload', args);
} }
if (Object.is(eventName, 'selectionchange')) { if (Object.is(eventName, 'selectionchange')) {
......
...@@ -78,9 +78,6 @@ export default class GridExpViewEngine extends ViewEngine { ...@@ -78,9 +78,6 @@ export default class GridExpViewEngine extends ViewEngine {
*/ */
public gridExpBarEvent(eventName: string, args: any): void { public gridExpBarEvent(eventName: string, args: any): void {
if (Object.is(eventName, 'load')) { if (Object.is(eventName, 'load')) {
if(this.gridExpBar && this.gridExpBar.calcNavigationToolbarState && this.gridExpBar.calcNavigationToolbarState instanceof Function){
this.gridExpBar.calcNavigationToolbarState();
}
this.view.$emit('viewload', args); this.view.$emit('viewload', args);
} }
if (Object.is(eventName, 'selectionchange')) { if (Object.is(eventName, 'selectionchange')) {
......
...@@ -78,9 +78,6 @@ export default class ListExpViewEngine extends ViewEngine { ...@@ -78,9 +78,6 @@ export default class ListExpViewEngine extends ViewEngine {
*/ */
public listExpBarEvent(eventName: string, args: any): void { public listExpBarEvent(eventName: string, args: any): void {
if (Object.is(eventName, 'load')) { if (Object.is(eventName, 'load')) {
if(this.listExpBar && this.listExpBar.calcNavigationToolbarState && this.listExpBar.calcNavigationToolbarState instanceof Function){
this.listExpBar.calcNavigationToolbarState();
}
this.view.$emit('viewload', args); this.view.$emit('viewload', args);
} }
if (Object.is(eventName, 'selectionchange')) { if (Object.is(eventName, 'selectionchange')) {
......
...@@ -79,9 +79,6 @@ export default class TreeExpView extends ViewEngine { ...@@ -79,9 +79,6 @@ export default class TreeExpView extends ViewEngine {
*/ */
public treeExpBarEvent(eventName: string, args: any): void { public treeExpBarEvent(eventName: string, args: any): void {
if (Object.is(eventName, 'load')) { if (Object.is(eventName, 'load')) {
if(this.treeExpBar && this.treeExpBar.calcNavigationToolbarState && this.treeExpBar.calcNavigationToolbarState instanceof Function){
this.treeExpBar.calcNavigationToolbarState();
}
this.view.$emit('viewload', args); this.view.$emit('viewload', args);
} }
if (Object.is(eventName, 'selectionchange')) { if (Object.is(eventName, 'selectionchange')) {
......
...@@ -194,7 +194,7 @@ export default class ViewEngine { ...@@ -194,7 +194,7 @@ export default class ViewEngine {
const _item = _this.view.toolBarModels[key]; const _item = _this.view.toolBarModels[key];
if(_item && _item['dataaccaction'] && _this.view.appUIService){ if(_item && _item['dataaccaction'] && _this.view.appUIService){
let dataActionResult:any; let dataActionResult:any;
if (_item.uiaction && (Object.is(_item.uiaction.target, 'NONE'))){ if (_item.uiaction && (Object.is(_item.uiaction.target, "NONE") || Object.is(_item.uiaction.target, ""))){
dataActionResult = _this.view.appUIService.getResourceOPPrivs(_item['dataaccaction']); dataActionResult = _this.view.appUIService.getResourceOPPrivs(_item['dataaccaction']);
}else{ }else{
if(data && Object.keys(data).length >0){ if(data && Object.keys(data).length >0){
......
...@@ -78,7 +78,11 @@ export default class WizardViewEngine extends ViewEngine { ...@@ -78,7 +78,11 @@ export default class WizardViewEngine extends ViewEngine {
*/ */
public onfinish(args: any): void { public onfinish(args: any): void {
this.view.$emit('viewdataschange', [args]); this.view.$emit('viewdataschange', [args]);
if(!this.view.viewDefaultUsage){
this.view.$emit('close', null); this.view.$emit('close', null);
}else{
this.view.$tabPageExp.onClose(this.view.$route.fullPath);
}
} }
/** /**
......
...@@ -25,6 +25,8 @@ export const Environment = { ...@@ -25,6 +25,8 @@ export const Environment = {
devMode: true, devMode: true,
// 是否开启权限认证 // 是否开启权限认证
enablePermissionValid:false, enablePermissionValid:false,
// 菜单权限模式,可选值:RT(RT模式),RESOURCE(资源模式),MINIX(混合模式),默认MINIX
menuPermissionMode:"MINIX",
// 项目模板地址 // 项目模板地址
ProjectUrl: "http://demo.ibizlab.cn/ibizr7pfstdtempl/ibizvuer7", ProjectUrl: "http://demo.ibizlab.cn/ibizr7pfstdtempl/ibizvuer7",
// 打开目标工具,可选参数:sln、mos // 打开目标工具,可选参数:sln、mos
......
...@@ -201,7 +201,7 @@ export default class ViewMessageService { ...@@ -201,7 +201,7 @@ export default class ViewMessageService {
public async getViewMessageByTag(tag:string,context:any = {},viewparam:any = {}){ public async getViewMessageByTag(tag:string,context:any = {},viewparam:any = {}){
let messageService:any = await this.getService(tag); let messageService:any = await this.getService(tag);
if(messageService.dynamicMode && Object.is(messageService.dynamicMode,"STATIC")){ if(messageService.dynamicMode && Object.is(messageService.dynamicMode,"STATIC")){
return messageService.getStaticViewMessage(); return messageService.getStaticViewMessage(context,viewparam);
}else{ }else{
return messageService.getDynamicViewMessage(tag,messageService,context,viewparam); return messageService.getDynamicViewMessage(tag,messageService,context,viewparam);
} }
...@@ -210,9 +210,14 @@ export default class ViewMessageService { ...@@ -210,9 +210,14 @@ export default class ViewMessageService {
/** /**
* 转化消息模板标题和内容 * 转化消息模板标题和内容
* *
* @target {*} target 返回目标数据
* @param {*} context 应用上下文
* @param {*} viewparam 视图参数
* @param {*} item 源数据
*
* @memberof ViewMessageService * @memberof ViewMessageService
*/ */
public translateMessageTemp(target:any,item?:any){ public translateMessageTemp(target:any,context:any,viewparam:any,item?:any){
} }
...@@ -221,7 +226,7 @@ export default class ViewMessageService { ...@@ -221,7 +226,7 @@ export default class ViewMessageService {
* *
* @memberof ViewMessageService * @memberof ViewMessageService
*/ */
public getStaticViewMessage():Array<ViewMessage>{ public getStaticViewMessage(context:any,viewparam:any):Array<ViewMessage>{
let returnViewMessage:ViewMessage ={ let returnViewMessage:ViewMessage ={
id:this.id, id:this.id,
name:this.name, name:this.name,
...@@ -236,7 +241,7 @@ export default class ViewMessageService { ...@@ -236,7 +241,7 @@ export default class ViewMessageService {
dynamicMode:this.dynamicMode, dynamicMode:this.dynamicMode,
messageType:this.messageType messageType:this.messageType
}; };
this.translateMessageTemp(returnViewMessage); this.translateMessageTemp(returnViewMessage,context,viewparam);
return [returnViewMessage]; return [returnViewMessage];
} }
...@@ -259,10 +264,11 @@ export default class ViewMessageService { ...@@ -259,10 +264,11 @@ export default class ViewMessageService {
// 启用缓存 // 启用缓存
if(isEnableCache){ if(isEnableCache){
const callback:Function = (context:any ={},data:any ={},tag:string,promise:Promise<any>) =>{ const callback:Function = (context:any ={},data:any ={},tag:string,promise:Promise<any>) =>{
const callbackKey:string = `${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`;
promise.then((result:any) =>{ promise.then((result:any) =>{
if(result.length > 0){ if(result.length > 0){
ViewMessageService.messageCached.set(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`,{items:result}); ViewMessageService.messageCached.set(callbackKey,{items:result});
ViewMessageService.messageCache.delete(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`); ViewMessageService.messageCache.delete(callbackKey);
return resolve(result); return resolve(result);
}else{ }else{
return resolve([]); return resolve([]);
...@@ -271,9 +277,10 @@ export default class ViewMessageService { ...@@ -271,9 +277,10 @@ export default class ViewMessageService {
return reject(result); return reject(result);
}) })
} }
const key:string = `${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`;
// 加载完成,从本地缓存获取 // 加载完成,从本地缓存获取
if(ViewMessageService.messageCached.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`)){ if(ViewMessageService.messageCached.get(key)){
let items:any = ViewMessageService.messageCached.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`).items; let items:any = ViewMessageService.messageCached.get(key).items;
if(items.length >0){ if(items.length >0){
if(new Date().getTime() <= messageService.getExpirationTime()){ if(new Date().getTime() <= messageService.getExpirationTime()){
return resolve(items); return resolve(items);
...@@ -282,11 +289,11 @@ export default class ViewMessageService { ...@@ -282,11 +289,11 @@ export default class ViewMessageService {
} }
if (messageService) { if (messageService) {
// 加载中,UI又需要数据,解决连续加载同一代码表问题 // 加载中,UI又需要数据,解决连续加载同一代码表问题
if(ViewMessageService.messageCache.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`)){ if(ViewMessageService.messageCache.get(key)){
callback(context,data,tag,ViewMessageService.messageCache.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`)); callback(context,data,tag,ViewMessageService.messageCache.get(key));
}else{ }else{
let result:Promise<any> = messageService.getItems(context,data,isloading); let result:Promise<any> = messageService.getItems(context,data,isloading);
ViewMessageService.messageCache.set(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`,result); ViewMessageService.messageCache.set(key,result);
messageService.setExpirationTime(new Date().getTime() + cacheTimeout); messageService.setExpirationTime(new Date().getTime() + cacheTimeout);
callback(context,data,tag,result); callback(context,data,tag,result);
} }
......
...@@ -27,28 +27,32 @@ ...@@ -27,28 +27,32 @@
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem5.tip')}}</div> <div slot='content'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem5.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem7.visabled" :disabled="toolBarModels.tbitem7.disabled" class='' @click="toolbar_click({ tag: 'tbitem7' }, $event)"> <i-button v-show="toolBarModels.tbitem7.visabled" :disabled="toolBarModels.tbitem7.disabled" class='' @click="toolbar_click({ tag: 'tbitem7' }, $event)">
<i class='fa fa-remove'></i> <i class='fa fa-remove'></i>
<span class='caption'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem7.caption')}}</span> <span class='caption'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem7.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem7.tip')}}</div> <div slot='content'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem7.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem12.visabled" :disabled="toolBarModels.tbitem12.disabled" class='' @click="toolbar_click({ tag: 'tbitem12' }, $event)"> <i-button v-show="toolBarModels.tbitem12.visabled" :disabled="toolBarModels.tbitem12.disabled" class='' @click="toolbar_click({ tag: 'tbitem12' }, $event)">
<i class='fa fa-file-text-o'></i> <i class='fa fa-file-text-o'></i>
<span class='caption'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem12.caption')}}</span> <span class='caption'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem12.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem12.tip')}}</div> <div slot='content'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem12.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem14.visabled" :disabled="toolBarModels.tbitem14.disabled" class='' @click="toolbar_click({ tag: 'tbitem14' }, $event)"> <i-button v-show="toolBarModels.tbitem14.visabled" :disabled="toolBarModels.tbitem14.disabled" class='' @click="toolbar_click({ tag: 'tbitem14' }, $event)">
<i class='fa fa-copy'></i> <i class='fa fa-copy'></i>
<span class='caption'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem14.caption')}}</span> <span class='caption'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem14.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem14.tip')}}</div> <div slot='content'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem14.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem23.visabled" :disabled="toolBarModels.tbitem23.disabled" class='' @click="toolbar_click({ tag: 'tbitem23' }, $event)"> <i-button v-show="toolBarModels.tbitem23.visabled" :disabled="toolBarModels.tbitem23.disabled" class='' @click="toolbar_click({ tag: 'tbitem23' }, $event)">
<i class='fa fa-fast-backward'></i> <i class='fa fa-fast-backward'></i>
...@@ -76,7 +80,8 @@ ...@@ -76,7 +80,8 @@
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem26.tip')}}</div> <div slot='content'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem26.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem22.visabled" :disabled="toolBarModels.tbitem22.disabled" class='' @click="toolbar_click({ tag: 'tbitem22' }, $event)"> <i-button v-show="toolBarModels.tbitem22.visabled" :disabled="toolBarModels.tbitem22.disabled" class='' @click="toolbar_click({ tag: 'tbitem22' }, $event)">
<i class='fa fa-question'></i> <i class='fa fa-question'></i>
<span class='caption'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem22.caption')}}</span> <span class='caption'>{{$t('entities.msgopenaccess.editviewtoolbar_toolbar.tbitem22.caption')}}</span>
...@@ -86,9 +91,11 @@ ...@@ -86,9 +91,11 @@
</div> </div>
</div> </div>
<div class="content-container">
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div class="content-container">
<div class='view-body-messages'>
</div>
<view_form <view_form
:viewState="viewState" :viewState="viewState"
:viewparams="viewparams" :viewparams="viewparams"
...@@ -111,8 +118,8 @@ ...@@ -111,8 +118,8 @@
@load="form_load($event)" @load="form_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_form> </view_form>
<div class='view-bottom-messages'>
</div> </div>
<div class='view-bottom-messages'>
</div> </div>
</card> </card>
</div> </div>
...@@ -289,6 +296,18 @@ export default class MsgOpenAccessEditViewBase extends Vue { ...@@ -289,6 +296,18 @@ export default class MsgOpenAccessEditViewBase extends Vue {
view_form: { name: 'form', type: 'FORM' }, view_form: { name: 'form', type: 'FORM' },
}; };
/**
* 视图刷新
*
* @param {*} args
* @memberof MsgOpenAccessEditViewBase
*/
public refresh(args?: any): void {
const refs: any = this.$refs;
if (refs && refs.form) {
refs.form.refresh();
}
}
/** /**
* 计数器刷新 * 计数器刷新
* *
...@@ -395,6 +414,23 @@ export default class MsgOpenAccessEditViewBase extends Vue { ...@@ -395,6 +414,23 @@ export default class MsgOpenAccessEditViewBase extends Vue {
*/ */
public serviceStateEvent: Subscription | undefined; public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof MsgOpenAccessEditViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof MsgOpenAccessEditViewBase
*/
public portletStateEvent: Subscription | undefined;
/** /**
* 应用上下文 * 应用上下文
* *
...@@ -608,6 +644,16 @@ export default class MsgOpenAccessEditViewBase extends Vue { ...@@ -608,6 +644,16 @@ export default class MsgOpenAccessEditViewBase extends Vue {
}); });
} }
}); });
if(_this.portletState){
_this.portletStateEvent = _this.portletState.subscribe((res:any) =>{
if(!Object.is(res.name,'calendar-view9')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
} }
...@@ -1569,6 +1615,9 @@ export default class MsgOpenAccessEditViewBase extends Vue { ...@@ -1569,6 +1615,9 @@ export default class MsgOpenAccessEditViewBase extends Vue {
} }
}) })
} }
if(this.portletStateEvent){
this.portletStateEvent.unsubscribe();
}
} }
......
...@@ -5,9 +5,9 @@ ...@@ -5,9 +5,9 @@
<div slot='title' class="header-container"> <div slot='title' class="header-container">
<span class='caption-info'>{{$t(model.srfCaption)}}</span> <span class='caption-info'>{{$t(model.srfCaption)}}</span>
</div> </div>
<div class='content-container'>
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div class='content-container'>
<div style='margin-bottom: 6px;'> <div style='margin-bottom: 6px;'>
<i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' placeholder="开放平台" /> <i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' placeholder="开放平台" />
<div class='pull-right'> <div class='pull-right'>
...@@ -33,18 +33,21 @@ ...@@ -33,18 +33,21 @@
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem6.tip')}}</div> <div slot='content'>{{$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem6.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem8.visabled" :disabled="toolBarModels.tbitem8.disabled" class='' @click="toolbar_click({ tag: 'tbitem8' }, $event)"> <i-button v-show="toolBarModels.tbitem8.visabled" :disabled="toolBarModels.tbitem8.disabled" class='' @click="toolbar_click({ tag: 'tbitem8' }, $event)">
<i class='fa fa-remove'></i> <i class='fa fa-remove'></i>
<span class='caption'>{{$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem8.caption')}}</span> <span class='caption'>{{$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem8.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem8.tip')}}</div> <div slot='content'>{{$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem8.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<app-export-excel :item="toolBarModels.tbitem13" :caption="$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem13.caption')" @exportexcel="toolbar_click({ tag: 'tbitem13' }, $event)"></app-export-excel> <app-export-excel :item="toolBarModels.tbitem13" :caption="$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem13.caption')" @exportexcel="toolbar_click({ tag: 'tbitem13' }, $event)"></app-export-excel>
<div slot='content'>{{$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem13.tip')}}</div> <div slot='content'>{{$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem13.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <dropdown v-show="toolBarModels.tbitem16.visabled" trigger='click'> <span class='seperator'>|</span>
<dropdown v-show="toolBarModels.tbitem16.visabled" trigger='click'>
<tooltip :transfer="true" :max-width="600"> <tooltip :transfer="true" :max-width="600">
<i-button class=''> <i-button class=''>
<i class=''></i> <i class=''></i>
...@@ -78,7 +81,8 @@ ...@@ -78,7 +81,8 @@
</dropdown-item> </dropdown-item>
</dropdown-menu> </dropdown-menu>
</dropdown> </dropdown>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem19.visabled" :disabled="toolBarModels.tbitem19.disabled" class='' @click="toolbar_click({ tag: 'tbitem19' }, $event)"> <i-button v-show="toolBarModels.tbitem19.visabled" :disabled="toolBarModels.tbitem19.disabled" class='' @click="toolbar_click({ tag: 'tbitem19' }, $event)">
<i class='fa fa-filter'></i> <i class='fa fa-filter'></i>
<span class='caption'>{{$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem19.caption')}}</span> <span class='caption'>{{$t('entities.msgopenaccess.gridviewtoolbar_toolbar.tbitem19.caption')}}</span>
...@@ -111,6 +115,8 @@ ...@@ -111,6 +115,8 @@
@load="searchform_load($event)" @load="searchform_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_searchform> </view_searchform>
<div class='view-body-messages'>
</div>
<view_grid <view_grid
:viewState="viewState" :viewState="viewState"
:viewparams="viewparams" :viewparams="viewparams"
...@@ -138,8 +144,8 @@ ...@@ -138,8 +144,8 @@
@load="grid_load($event)" @load="grid_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_grid> </view_grid>
<div class='view-bottom-messages'>
</div> </div>
<div class='view-bottom-messages'>
</div> </div>
</card> </card>
</div> </div>
...@@ -320,6 +326,18 @@ export default class MsgOpenAccessGridViewBase extends Vue { ...@@ -320,6 +326,18 @@ export default class MsgOpenAccessGridViewBase extends Vue {
view_searchform: { name: 'searchform', type: 'SEARCHFORM' }, view_searchform: { name: 'searchform', type: 'SEARCHFORM' },
}; };
/**
* 视图刷新
*
* @param {*} args
* @memberof MsgOpenAccessGridViewBase
*/
public refresh(args?: any): void {
const refs: any = this.$refs;
if (refs && refs.grid) {
refs.grid.refresh();
}
}
/** /**
* 计数器刷新 * 计数器刷新
* *
...@@ -430,6 +448,23 @@ export default class MsgOpenAccessGridViewBase extends Vue { ...@@ -430,6 +448,23 @@ export default class MsgOpenAccessGridViewBase extends Vue {
*/ */
public serviceStateEvent: Subscription | undefined; public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof MsgOpenAccessGridViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof MsgOpenAccessGridViewBase
*/
public portletStateEvent: Subscription | undefined;
/** /**
* 应用上下文 * 应用上下文
* *
...@@ -643,6 +678,16 @@ export default class MsgOpenAccessGridViewBase extends Vue { ...@@ -643,6 +678,16 @@ export default class MsgOpenAccessGridViewBase extends Vue {
}); });
} }
}); });
if(_this.portletState){
_this.portletStateEvent = _this.portletState.subscribe((res:any) =>{
if(!Object.is(res.name,'calendar-view9')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
if(this.formDruipart){ if(this.formDruipart){
this.formDruipart.subscribe((res:any) =>{ this.formDruipart.subscribe((res:any) =>{
if(Object.is(res.action,'save')){ if(Object.is(res.action,'save')){
...@@ -1618,6 +1663,9 @@ export default class MsgOpenAccessGridViewBase extends Vue { ...@@ -1618,6 +1663,9 @@ export default class MsgOpenAccessGridViewBase extends Vue {
} }
}) })
} }
if(this.portletStateEvent){
this.portletStateEvent.unsubscribe();
}
} }
/** /**
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
<div class='view-container depickupgridview msg-open-access-pickup-grid-view'> <div class='view-container depickupgridview msg-open-access-pickup-grid-view'>
<app-studioaction :viewTitle="$t(model.srfCaption)" viewName="msgopenaccesspickupgridview"></app-studioaction> <app-studioaction :viewTitle="$t(model.srfCaption)" viewName="msgopenaccesspickupgridview"></app-studioaction>
<card class='view-card view-no-caption view-no-toolbar' :dis-hover="true" :bordered="false"> <card class='view-card view-no-caption view-no-toolbar' :dis-hover="true" :bordered="false">
<div class='content-container pickup-grid-view'>
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div class='content-container pickup-grid-view'>
<view_searchform <view_searchform
:viewState="viewState" :viewState="viewState"
:viewparams="viewparams" :viewparams="viewparams"
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
@load="searchform_load($event)" @load="searchform_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_searchform> </view_searchform>
<view_grid <div class='view-body-messages'> </div> <view_grid
:viewState="viewState" :viewState="viewState"
:viewparams="viewparams" :viewparams="viewparams"
:context="context" :context="context"
...@@ -42,8 +42,8 @@ ...@@ -42,8 +42,8 @@
@load="grid_load($event)" @load="grid_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_grid> </view_grid>
<div class='view-bottom-messages'>
</div> </div>
<div class='view-bottom-messages'>
</div> </div>
</card> </card>
</div> </div>
...@@ -220,6 +220,18 @@ export default class MsgOpenAccessPickupGridViewBase extends Vue { ...@@ -220,6 +220,18 @@ export default class MsgOpenAccessPickupGridViewBase extends Vue {
view_searchform: { name: 'searchform', type: 'SEARCHFORM' }, view_searchform: { name: 'searchform', type: 'SEARCHFORM' },
}; };
/**
* 视图刷新
*
* @param {*} args
* @memberof MsgOpenAccessPickupGridViewBase
*/
public refresh(args?: any): void {
const refs: any = this.$refs;
if (refs && refs.grid) {
refs.grid.refresh();
}
}
/** /**
* 计数器刷新 * 计数器刷新
* *
...@@ -289,6 +301,23 @@ export default class MsgOpenAccessPickupGridViewBase extends Vue { ...@@ -289,6 +301,23 @@ export default class MsgOpenAccessPickupGridViewBase extends Vue {
*/ */
public serviceStateEvent: Subscription | undefined; public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof MsgOpenAccessPickupGridViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof MsgOpenAccessPickupGridViewBase
*/
public portletStateEvent: Subscription | undefined;
/** /**
* 应用上下文 * 应用上下文
* *
...@@ -502,6 +531,16 @@ export default class MsgOpenAccessPickupGridViewBase extends Vue { ...@@ -502,6 +531,16 @@ export default class MsgOpenAccessPickupGridViewBase extends Vue {
}); });
} }
}); });
if(_this.portletState){
_this.portletStateEvent = _this.portletState.subscribe((res:any) =>{
if(!Object.is(res.name,'calendar-view9')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
} }
...@@ -679,6 +718,9 @@ export default class MsgOpenAccessPickupGridViewBase extends Vue { ...@@ -679,6 +718,9 @@ export default class MsgOpenAccessPickupGridViewBase extends Vue {
} }
}) })
} }
if(this.portletStateEvent){
this.portletStateEvent.unsubscribe();
}
} }
/** /**
* 选中数据字符串 * 选中数据字符串
......
...@@ -2,7 +2,11 @@ ...@@ -2,7 +2,11 @@
<div class="view-container depickupview msg-open-access-pickup-view"> <div class="view-container depickupview msg-open-access-pickup-view">
<app-studioaction :viewTitle="$t(model.srfCaption)" viewName="msgopenaccesspickupview"></app-studioaction> <app-studioaction :viewTitle="$t(model.srfCaption)" viewName="msgopenaccesspickupview"></app-studioaction>
<card class='view-card view-no-caption view-no-toolbar' :dis-hover="true" :padding="0" :bordered="false"> <card class='view-card view-no-caption view-no-toolbar' :dis-hover="true" :padding="0" :bordered="false">
<div class='view-top-messages'>
</div>
<div class="content-container pickup-view"> <div class="content-container pickup-view">
<div class='view-body-messages'>
</div>
<view_pickupviewpanel <view_pickupviewpanel
:viewState="viewState" :viewState="viewState"
:viewparams="JSON.parse(JSON.stringify(viewparams))" :viewparams="JSON.parse(JSON.stringify(viewparams))"
...@@ -25,6 +29,8 @@ ...@@ -25,6 +29,8 @@
</row> </row>
</card> </card>
</div> </div>
<div class='view-bottom-messages'>
</div>
</card> </card>
</div> </div>
</template> </template>
...@@ -278,6 +284,23 @@ export default class MsgOpenAccessPickupViewBase extends Vue { ...@@ -278,6 +284,23 @@ export default class MsgOpenAccessPickupViewBase extends Vue {
*/ */
public serviceStateEvent: Subscription | undefined; public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof MsgOpenAccessPickupViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof MsgOpenAccessPickupViewBase
*/
public portletStateEvent: Subscription | undefined;
/** /**
* 应用上下文 * 应用上下文
* *
...@@ -491,6 +514,16 @@ export default class MsgOpenAccessPickupViewBase extends Vue { ...@@ -491,6 +514,16 @@ export default class MsgOpenAccessPickupViewBase extends Vue {
}); });
} }
}); });
if(_this.portletState){
_this.portletStateEvent = _this.portletState.subscribe((res:any) =>{
if(!Object.is(res.name,'calendar-view9')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
} }
...@@ -623,6 +656,9 @@ export default class MsgOpenAccessPickupViewBase extends Vue { ...@@ -623,6 +656,9 @@ export default class MsgOpenAccessPickupViewBase extends Vue {
} }
}) })
} }
if(this.portletStateEvent){
this.portletStateEvent.unsubscribe();
}
} }
/** /**
* 选中数据的字符串 * 选中数据的字符串
......
...@@ -27,28 +27,32 @@ ...@@ -27,28 +27,32 @@
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem5.tip')}}</div> <div slot='content'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem5.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem7.visabled" :disabled="toolBarModels.tbitem7.disabled" class='' @click="toolbar_click({ tag: 'tbitem7' }, $event)"> <i-button v-show="toolBarModels.tbitem7.visabled" :disabled="toolBarModels.tbitem7.disabled" class='' @click="toolbar_click({ tag: 'tbitem7' }, $event)">
<i class='fa fa-remove'></i> <i class='fa fa-remove'></i>
<span class='caption'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem7.caption')}}</span> <span class='caption'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem7.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem7.tip')}}</div> <div slot='content'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem7.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem12.visabled" :disabled="toolBarModels.tbitem12.disabled" class='' @click="toolbar_click({ tag: 'tbitem12' }, $event)"> <i-button v-show="toolBarModels.tbitem12.visabled" :disabled="toolBarModels.tbitem12.disabled" class='' @click="toolbar_click({ tag: 'tbitem12' }, $event)">
<i class='fa fa-file-text-o'></i> <i class='fa fa-file-text-o'></i>
<span class='caption'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem12.caption')}}</span> <span class='caption'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem12.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem12.tip')}}</div> <div slot='content'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem12.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem14.visabled" :disabled="toolBarModels.tbitem14.disabled" class='' @click="toolbar_click({ tag: 'tbitem14' }, $event)"> <i-button v-show="toolBarModels.tbitem14.visabled" :disabled="toolBarModels.tbitem14.disabled" class='' @click="toolbar_click({ tag: 'tbitem14' }, $event)">
<i class='fa fa-copy'></i> <i class='fa fa-copy'></i>
<span class='caption'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem14.caption')}}</span> <span class='caption'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem14.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem14.tip')}}</div> <div slot='content'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem14.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem23.visabled" :disabled="toolBarModels.tbitem23.disabled" class='' @click="toolbar_click({ tag: 'tbitem23' }, $event)"> <i-button v-show="toolBarModels.tbitem23.visabled" :disabled="toolBarModels.tbitem23.disabled" class='' @click="toolbar_click({ tag: 'tbitem23' }, $event)">
<i class='fa fa-fast-backward'></i> <i class='fa fa-fast-backward'></i>
...@@ -76,7 +80,8 @@ ...@@ -76,7 +80,8 @@
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem26.tip')}}</div> <div slot='content'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem26.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem22.visabled" :disabled="toolBarModels.tbitem22.disabled" class='' @click="toolbar_click({ tag: 'tbitem22' }, $event)"> <i-button v-show="toolBarModels.tbitem22.visabled" :disabled="toolBarModels.tbitem22.disabled" class='' @click="toolbar_click({ tag: 'tbitem22' }, $event)">
<i class='fa fa-question'></i> <i class='fa fa-question'></i>
<span class='caption'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem22.caption')}}</span> <span class='caption'>{{$t('entities.msgtemplate.editviewtoolbar_toolbar.tbitem22.caption')}}</span>
...@@ -86,9 +91,11 @@ ...@@ -86,9 +91,11 @@
</div> </div>
</div> </div>
<div class="content-container">
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div class="content-container">
<div class='view-body-messages'>
</div>
<view_form <view_form
:viewState="viewState" :viewState="viewState"
:viewparams="viewparams" :viewparams="viewparams"
...@@ -111,8 +118,8 @@ ...@@ -111,8 +118,8 @@
@load="form_load($event)" @load="form_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_form> </view_form>
<div class='view-bottom-messages'>
</div> </div>
<div class='view-bottom-messages'>
</div> </div>
</card> </card>
</div> </div>
...@@ -289,6 +296,18 @@ export default class MsgTemplateEditViewBase extends Vue { ...@@ -289,6 +296,18 @@ export default class MsgTemplateEditViewBase extends Vue {
view_form: { name: 'form', type: 'FORM' }, view_form: { name: 'form', type: 'FORM' },
}; };
/**
* 视图刷新
*
* @param {*} args
* @memberof MsgTemplateEditViewBase
*/
public refresh(args?: any): void {
const refs: any = this.$refs;
if (refs && refs.form) {
refs.form.refresh();
}
}
/** /**
* 计数器刷新 * 计数器刷新
* *
...@@ -395,6 +414,23 @@ export default class MsgTemplateEditViewBase extends Vue { ...@@ -395,6 +414,23 @@ export default class MsgTemplateEditViewBase extends Vue {
*/ */
public serviceStateEvent: Subscription | undefined; public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof MsgTemplateEditViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof MsgTemplateEditViewBase
*/
public portletStateEvent: Subscription | undefined;
/** /**
* 应用上下文 * 应用上下文
* *
...@@ -608,6 +644,16 @@ export default class MsgTemplateEditViewBase extends Vue { ...@@ -608,6 +644,16 @@ export default class MsgTemplateEditViewBase extends Vue {
}); });
} }
}); });
if(_this.portletState){
_this.portletStateEvent = _this.portletState.subscribe((res:any) =>{
if(!Object.is(res.name,'calendar-view9')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
} }
...@@ -1569,6 +1615,9 @@ export default class MsgTemplateEditViewBase extends Vue { ...@@ -1569,6 +1615,9 @@ export default class MsgTemplateEditViewBase extends Vue {
} }
}) })
} }
if(this.portletStateEvent){
this.portletStateEvent.unsubscribe();
}
} }
......
...@@ -5,9 +5,9 @@ ...@@ -5,9 +5,9 @@
<div slot='title' class="header-container"> <div slot='title' class="header-container">
<span class='caption-info'>{{$t(model.srfCaption)}}</span> <span class='caption-info'>{{$t(model.srfCaption)}}</span>
</div> </div>
<div class='content-container'>
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div class='content-container'>
<div style='margin-bottom: 6px;'> <div style='margin-bottom: 6px;'>
<i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' placeholder="模板标题" /> <i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' placeholder="模板标题" />
<div class='pull-right'> <div class='pull-right'>
...@@ -33,18 +33,21 @@ ...@@ -33,18 +33,21 @@
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem6.tip')}}</div> <div slot='content'>{{$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem6.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem8.visabled" :disabled="toolBarModels.tbitem8.disabled" class='' @click="toolbar_click({ tag: 'tbitem8' }, $event)"> <i-button v-show="toolBarModels.tbitem8.visabled" :disabled="toolBarModels.tbitem8.disabled" class='' @click="toolbar_click({ tag: 'tbitem8' }, $event)">
<i class='fa fa-remove'></i> <i class='fa fa-remove'></i>
<span class='caption'>{{$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem8.caption')}}</span> <span class='caption'>{{$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem8.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem8.tip')}}</div> <div slot='content'>{{$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem8.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<app-export-excel :item="toolBarModels.tbitem13" :caption="$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem13.caption')" @exportexcel="toolbar_click({ tag: 'tbitem13' }, $event)"></app-export-excel> <app-export-excel :item="toolBarModels.tbitem13" :caption="$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem13.caption')" @exportexcel="toolbar_click({ tag: 'tbitem13' }, $event)"></app-export-excel>
<div slot='content'>{{$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem13.tip')}}</div> <div slot='content'>{{$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem13.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <dropdown v-show="toolBarModels.tbitem16.visabled" trigger='click'> <span class='seperator'>|</span>
<dropdown v-show="toolBarModels.tbitem16.visabled" trigger='click'>
<tooltip :transfer="true" :max-width="600"> <tooltip :transfer="true" :max-width="600">
<i-button class=''> <i-button class=''>
<i class=''></i> <i class=''></i>
...@@ -78,7 +81,8 @@ ...@@ -78,7 +81,8 @@
</dropdown-item> </dropdown-item>
</dropdown-menu> </dropdown-menu>
</dropdown> </dropdown>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem19.visabled" :disabled="toolBarModels.tbitem19.disabled" class='' @click="toolbar_click({ tag: 'tbitem19' }, $event)"> <i-button v-show="toolBarModels.tbitem19.visabled" :disabled="toolBarModels.tbitem19.disabled" class='' @click="toolbar_click({ tag: 'tbitem19' }, $event)">
<i class='fa fa-filter'></i> <i class='fa fa-filter'></i>
<span class='caption'>{{$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem19.caption')}}</span> <span class='caption'>{{$t('entities.msgtemplate.gridviewtoolbar_toolbar.tbitem19.caption')}}</span>
...@@ -111,6 +115,8 @@ ...@@ -111,6 +115,8 @@
@load="searchform_load($event)" @load="searchform_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_searchform> </view_searchform>
<div class='view-body-messages'>
</div>
<view_grid <view_grid
:viewState="viewState" :viewState="viewState"
:viewparams="viewparams" :viewparams="viewparams"
...@@ -138,8 +144,8 @@ ...@@ -138,8 +144,8 @@
@load="grid_load($event)" @load="grid_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_grid> </view_grid>
<div class='view-bottom-messages'>
</div> </div>
<div class='view-bottom-messages'>
</div> </div>
</card> </card>
</div> </div>
...@@ -320,6 +326,18 @@ export default class MsgTemplateGridViewBase extends Vue { ...@@ -320,6 +326,18 @@ export default class MsgTemplateGridViewBase extends Vue {
view_searchform: { name: 'searchform', type: 'SEARCHFORM' }, view_searchform: { name: 'searchform', type: 'SEARCHFORM' },
}; };
/**
* 视图刷新
*
* @param {*} args
* @memberof MsgTemplateGridViewBase
*/
public refresh(args?: any): void {
const refs: any = this.$refs;
if (refs && refs.grid) {
refs.grid.refresh();
}
}
/** /**
* 计数器刷新 * 计数器刷新
* *
...@@ -430,6 +448,23 @@ export default class MsgTemplateGridViewBase extends Vue { ...@@ -430,6 +448,23 @@ export default class MsgTemplateGridViewBase extends Vue {
*/ */
public serviceStateEvent: Subscription | undefined; public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof MsgTemplateGridViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof MsgTemplateGridViewBase
*/
public portletStateEvent: Subscription | undefined;
/** /**
* 应用上下文 * 应用上下文
* *
...@@ -643,6 +678,16 @@ export default class MsgTemplateGridViewBase extends Vue { ...@@ -643,6 +678,16 @@ export default class MsgTemplateGridViewBase extends Vue {
}); });
} }
}); });
if(_this.portletState){
_this.portletStateEvent = _this.portletState.subscribe((res:any) =>{
if(!Object.is(res.name,'calendar-view9')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
if(this.formDruipart){ if(this.formDruipart){
this.formDruipart.subscribe((res:any) =>{ this.formDruipart.subscribe((res:any) =>{
if(Object.is(res.action,'save')){ if(Object.is(res.action,'save')){
...@@ -1618,6 +1663,9 @@ export default class MsgTemplateGridViewBase extends Vue { ...@@ -1618,6 +1663,9 @@ export default class MsgTemplateGridViewBase extends Vue {
} }
}) })
} }
if(this.portletStateEvent){
this.portletStateEvent.unsubscribe();
}
} }
/** /**
......
...@@ -27,28 +27,32 @@ ...@@ -27,28 +27,32 @@
</i-button> </i-button>
<div slot='content'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem5.tip')}}</div> <div slot='content'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem5.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem7.visabled" :disabled="toolBarModels.tbitem7.disabled" class='' @click="toolbar_click({ tag: 'tbitem7' }, $event)"> <i-button v-show="toolBarModels.tbitem7.visabled" :disabled="toolBarModels.tbitem7.disabled" class='' @click="toolbar_click({ tag: 'tbitem7' }, $event)">
<i class='fa fa-remove'></i> <i class='fa fa-remove'></i>
<span class='caption'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem7.caption')}}</span> <span class='caption'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem7.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem7.tip')}}</div> <div slot='content'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem7.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem12.visabled" :disabled="toolBarModels.tbitem12.disabled" class='' @click="toolbar_click({ tag: 'tbitem12' }, $event)"> <i-button v-show="toolBarModels.tbitem12.visabled" :disabled="toolBarModels.tbitem12.disabled" class='' @click="toolbar_click({ tag: 'tbitem12' }, $event)">
<i class='fa fa-file-text-o'></i> <i class='fa fa-file-text-o'></i>
<span class='caption'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem12.caption')}}</span> <span class='caption'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem12.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem12.tip')}}</div> <div slot='content'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem12.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem14.visabled" :disabled="toolBarModels.tbitem14.disabled" class='' @click="toolbar_click({ tag: 'tbitem14' }, $event)"> <i-button v-show="toolBarModels.tbitem14.visabled" :disabled="toolBarModels.tbitem14.disabled" class='' @click="toolbar_click({ tag: 'tbitem14' }, $event)">
<i class='fa fa-copy'></i> <i class='fa fa-copy'></i>
<span class='caption'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem14.caption')}}</span> <span class='caption'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem14.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem14.tip')}}</div> <div slot='content'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem14.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem23.visabled" :disabled="toolBarModels.tbitem23.disabled" class='' @click="toolbar_click({ tag: 'tbitem23' }, $event)"> <i-button v-show="toolBarModels.tbitem23.visabled" :disabled="toolBarModels.tbitem23.disabled" class='' @click="toolbar_click({ tag: 'tbitem23' }, $event)">
<i class='fa fa-fast-backward'></i> <i class='fa fa-fast-backward'></i>
...@@ -76,7 +80,8 @@ ...@@ -76,7 +80,8 @@
</i-button> </i-button>
<div slot='content'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem26.tip')}}</div> <div slot='content'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem26.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem22.visabled" :disabled="toolBarModels.tbitem22.disabled" class='' @click="toolbar_click({ tag: 'tbitem22' }, $event)"> <i-button v-show="toolBarModels.tbitem22.visabled" :disabled="toolBarModels.tbitem22.disabled" class='' @click="toolbar_click({ tag: 'tbitem22' }, $event)">
<i class='fa fa-question'></i> <i class='fa fa-question'></i>
<span class='caption'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem22.caption')}}</span> <span class='caption'>{{$t('entities.msguseraccount.editviewtoolbar_toolbar.tbitem22.caption')}}</span>
...@@ -86,9 +91,11 @@ ...@@ -86,9 +91,11 @@
</div> </div>
</div> </div>
<div class="content-container">
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div class="content-container">
<div class='view-body-messages'>
</div>
<view_form <view_form
:viewState="viewState" :viewState="viewState"
:viewparams="viewparams" :viewparams="viewparams"
...@@ -111,8 +118,8 @@ ...@@ -111,8 +118,8 @@
@load="form_load($event)" @load="form_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_form> </view_form>
<div class='view-bottom-messages'>
</div> </div>
<div class='view-bottom-messages'>
</div> </div>
</card> </card>
</div> </div>
...@@ -289,6 +296,18 @@ export default class MsgUserAccountEditViewBase extends Vue { ...@@ -289,6 +296,18 @@ export default class MsgUserAccountEditViewBase extends Vue {
view_form: { name: 'form', type: 'FORM' }, view_form: { name: 'form', type: 'FORM' },
}; };
/**
* 视图刷新
*
* @param {*} args
* @memberof MsgUserAccountEditViewBase
*/
public refresh(args?: any): void {
const refs: any = this.$refs;
if (refs && refs.form) {
refs.form.refresh();
}
}
/** /**
* 计数器刷新 * 计数器刷新
* *
...@@ -395,6 +414,23 @@ export default class MsgUserAccountEditViewBase extends Vue { ...@@ -395,6 +414,23 @@ export default class MsgUserAccountEditViewBase extends Vue {
*/ */
public serviceStateEvent: Subscription | undefined; public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof MsgUserAccountEditViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof MsgUserAccountEditViewBase
*/
public portletStateEvent: Subscription | undefined;
/** /**
* 应用上下文 * 应用上下文
* *
...@@ -608,6 +644,16 @@ export default class MsgUserAccountEditViewBase extends Vue { ...@@ -608,6 +644,16 @@ export default class MsgUserAccountEditViewBase extends Vue {
}); });
} }
}); });
if(_this.portletState){
_this.portletStateEvent = _this.portletState.subscribe((res:any) =>{
if(!Object.is(res.name,'calendar-view9')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
} }
...@@ -1569,6 +1615,9 @@ export default class MsgUserAccountEditViewBase extends Vue { ...@@ -1569,6 +1615,9 @@ export default class MsgUserAccountEditViewBase extends Vue {
} }
}) })
} }
if(this.portletStateEvent){
this.portletStateEvent.unsubscribe();
}
} }
......
...@@ -5,9 +5,9 @@ ...@@ -5,9 +5,9 @@
<div slot='title' class="header-container"> <div slot='title' class="header-container">
<span class='caption-info'>{{$t(model.srfCaption)}}</span> <span class='caption-info'>{{$t(model.srfCaption)}}</span>
</div> </div>
<div class='content-container'>
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div class='content-container'>
<div style='margin-bottom: 6px;'> <div style='margin-bottom: 6px;'>
<i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' placeholder="认证标识" /> <i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' placeholder="认证标识" />
<div class='pull-right'> <div class='pull-right'>
...@@ -33,18 +33,21 @@ ...@@ -33,18 +33,21 @@
</i-button> </i-button>
<div slot='content'>{{$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem6.tip')}}</div> <div slot='content'>{{$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem6.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem8.visabled" :disabled="toolBarModels.tbitem8.disabled" class='' @click="toolbar_click({ tag: 'tbitem8' }, $event)"> <i-button v-show="toolBarModels.tbitem8.visabled" :disabled="toolBarModels.tbitem8.disabled" class='' @click="toolbar_click({ tag: 'tbitem8' }, $event)">
<i class='fa fa-remove'></i> <i class='fa fa-remove'></i>
<span class='caption'>{{$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem8.caption')}}</span> <span class='caption'>{{$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem8.caption')}}</span>
</i-button> </i-button>
<div slot='content'>{{$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem8.tip')}}</div> <div slot='content'>{{$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem8.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<app-export-excel :item="toolBarModels.tbitem13" :caption="$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem13.caption')" @exportexcel="toolbar_click({ tag: 'tbitem13' }, $event)"></app-export-excel> <app-export-excel :item="toolBarModels.tbitem13" :caption="$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem13.caption')" @exportexcel="toolbar_click({ tag: 'tbitem13' }, $event)"></app-export-excel>
<div slot='content'>{{$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem13.tip')}}</div> <div slot='content'>{{$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem13.tip')}}</div>
</tooltip> </tooltip>
<span class='seperator'>|</span> <dropdown v-show="toolBarModels.tbitem16.visabled" trigger='click'> <span class='seperator'>|</span>
<dropdown v-show="toolBarModels.tbitem16.visabled" trigger='click'>
<tooltip :transfer="true" :max-width="600"> <tooltip :transfer="true" :max-width="600">
<i-button class=''> <i-button class=''>
<i class=''></i> <i class=''></i>
...@@ -78,7 +81,8 @@ ...@@ -78,7 +81,8 @@
</dropdown-item> </dropdown-item>
</dropdown-menu> </dropdown-menu>
</dropdown> </dropdown>
<span class='seperator'>|</span> <tooltip :transfer="true" :max-width="600"> <span class='seperator'>|</span>
<tooltip :transfer="true" :max-width="600">
<i-button v-show="toolBarModels.tbitem19.visabled" :disabled="toolBarModels.tbitem19.disabled" class='' @click="toolbar_click({ tag: 'tbitem19' }, $event)"> <i-button v-show="toolBarModels.tbitem19.visabled" :disabled="toolBarModels.tbitem19.disabled" class='' @click="toolbar_click({ tag: 'tbitem19' }, $event)">
<i class='fa fa-filter'></i> <i class='fa fa-filter'></i>
<span class='caption'>{{$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem19.caption')}}</span> <span class='caption'>{{$t('entities.msguseraccount.gridviewtoolbar_toolbar.tbitem19.caption')}}</span>
...@@ -111,6 +115,8 @@ ...@@ -111,6 +115,8 @@
@load="searchform_load($event)" @load="searchform_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_searchform> </view_searchform>
<div class='view-body-messages'>
</div>
<view_grid <view_grid
:viewState="viewState" :viewState="viewState"
:viewparams="viewparams" :viewparams="viewparams"
...@@ -138,8 +144,8 @@ ...@@ -138,8 +144,8 @@
@load="grid_load($event)" @load="grid_load($event)"
@closeview="closeView($event)"> @closeview="closeView($event)">
</view_grid> </view_grid>
<div class='view-bottom-messages'>
</div> </div>
<div class='view-bottom-messages'>
</div> </div>
</card> </card>
</div> </div>
...@@ -320,6 +326,18 @@ export default class MsgUserAccountGridViewBase extends Vue { ...@@ -320,6 +326,18 @@ export default class MsgUserAccountGridViewBase extends Vue {
view_searchform: { name: 'searchform', type: 'SEARCHFORM' }, view_searchform: { name: 'searchform', type: 'SEARCHFORM' },
}; };
/**
* 视图刷新
*
* @param {*} args
* @memberof MsgUserAccountGridViewBase
*/
public refresh(args?: any): void {
const refs: any = this.$refs;
if (refs && refs.grid) {
refs.grid.refresh();
}
}
/** /**
* 计数器刷新 * 计数器刷新
* *
...@@ -430,6 +448,23 @@ export default class MsgUserAccountGridViewBase extends Vue { ...@@ -430,6 +448,23 @@ export default class MsgUserAccountGridViewBase extends Vue {
*/ */
public serviceStateEvent: Subscription | undefined; public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof MsgUserAccountGridViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof MsgUserAccountGridViewBase
*/
public portletStateEvent: Subscription | undefined;
/** /**
* 应用上下文 * 应用上下文
* *
...@@ -643,6 +678,16 @@ export default class MsgUserAccountGridViewBase extends Vue { ...@@ -643,6 +678,16 @@ export default class MsgUserAccountGridViewBase extends Vue {
}); });
} }
}); });
if(_this.portletState){
_this.portletStateEvent = _this.portletState.subscribe((res:any) =>{
if(!Object.is(res.name,'calendar-view9')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
if(this.formDruipart){ if(this.formDruipart){
this.formDruipart.subscribe((res:any) =>{ this.formDruipart.subscribe((res:any) =>{
if(Object.is(res.action,'save')){ if(Object.is(res.action,'save')){
...@@ -1592,6 +1637,9 @@ export default class MsgUserAccountGridViewBase extends Vue { ...@@ -1592,6 +1637,9 @@ export default class MsgUserAccountGridViewBase extends Vue {
} }
}) })
} }
if(this.portletStateEvent){
this.portletStateEvent.unsubscribe();
}
} }
/** /**
......
...@@ -262,6 +262,23 @@ export default class NotifyIndexViewBase extends Vue { ...@@ -262,6 +262,23 @@ export default class NotifyIndexViewBase extends Vue {
*/ */
public serviceStateEvent: Subscription | undefined; public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof NotifyIndexViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof NotifyIndexViewBase
*/
public portletStateEvent: Subscription | undefined;
/** /**
* 应用上下文 * 应用上下文
* *
...@@ -470,6 +487,16 @@ export default class NotifyIndexViewBase extends Vue { ...@@ -470,6 +487,16 @@ export default class NotifyIndexViewBase extends Vue {
}); });
} }
}); });
if(_this.portletState){
_this.portletStateEvent = _this.portletState.subscribe((res:any) =>{
if(!Object.is(res.name,'calendar-view9')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
} }
......
...@@ -32,23 +32,56 @@ export const getEnablePermissionValid = (state: any) => { ...@@ -32,23 +32,56 @@ export const getEnablePermissionValid = (state: any) => {
} }
/** /**
* 判断指定菜单是否显示 * 判断指定菜单是否显示(混合模式)
* *
* @param state * @param state
*/ */
export const getAuthMenu = (state: any) => (menu:any) =>{ export const getAuthMenu = (state: any) => (menu: any) => {
// 存在权限 if (state.enablePermissionValid) {
let resourceIndex: any; let resourceIndex: any;
let menuIndex:any; let menuIndex: any;
if(state.enablePermissionValid){ resourceIndex = state.resourceData.findIndex((resourcetag: any, objIndex: any, objs: any) => {
resourceIndex= state.resourceData.findIndex((resourcetag: any, objIndex: any, objs: any) => {
return Object.is(menu.resourcetag, resourcetag); return Object.is(menu.resourcetag, resourcetag);
}) })
menuIndex= state.menuData.findIndex((menutag: any, objIndex: any, objs: any) => { menuIndex = state.menuData.findIndex((menutag: any, objIndex: any, objs: any) => {
return Object.is(menu.authtag, menutag); return Object.is(menu.authtag, menutag);
}) })
return (resourceIndex !== -1 || menuIndex !== -1)?true:false; return (resourceIndex !== -1 || menuIndex !== -1) ? true : false;
}else{ } else {
return true;
}
}
/**
* 判断指定菜单是否显示(资源模式)
*
* @param state
*/
export const getAuthMenuWithResource = (state: any) => (menu: any) => {
if (state.enablePermissionValid && menu.resourcetag) {
let resourceIndex: any;
resourceIndex = state.resourceData.findIndex((resourcetag: any, objIndex: any, objs: any) => {
return Object.is(menu.resourcetag, resourcetag);
})
return resourceIndex !== -1 ? true : false;
} else {
return true;
}
}
/**
* 判断指定菜单是否显示(RT模式)
*
* @param state
*/
export const getAuthMenuWithRT = (state: any) => (menu: any) => {
if (state.enablePermissionValid) {
let menuIndex: any;
menuIndex = state.menuData.findIndex((menutag: any, objIndex: any, objs: any) => {
return Object.is(menu.authtag, menutag);
})
return menuIndex !== -1 ? true : false;
} else {
return true; return true;
} }
} }
\ No newline at end of file
...@@ -124,11 +124,14 @@ ...@@ -124,11 +124,14 @@
// flex-grow: 1; // flex-grow: 1;
height: calc(100% - 74px); height: calc(100% - 74px);
padding: 0px; padding: 0px;
display: flex;
flex-direction: column;
> .content-container { > .content-container {
height: 100%; height: 100%;
display: flex; display: flex;
margin: 0; margin: 0;
flex-direction: column; flex-direction: column;
overflow: auto;
} }
} }
} }
......
...@@ -201,7 +201,7 @@ export default class MsgOpenAccessUIServiceBase extends UIService { ...@@ -201,7 +201,7 @@ export default class MsgOpenAccessUIServiceBase extends UIService {
this.mainStateFields.forEach((singleMainField:any) =>{ this.mainStateFields.forEach((singleMainField:any) =>{
if(!(singleMainField in curData)){ if(!(singleMainField in curData)){
console.warn(`当前数据对象不包含属性${singleMainField},可能会发生错误`); console.warn(`当前数据对象不包含属性${singleMainField}」,根据「${singleMainField}」属性进行的主状态计算默认为空值`);
} }
}) })
for (let i = 0; i <= 1; i++) { for (let i = 0; i <= 1; i++) {
......
...@@ -199,7 +199,7 @@ export default class MsgTemplateUIServiceBase extends UIService { ...@@ -199,7 +199,7 @@ export default class MsgTemplateUIServiceBase extends UIService {
this.mainStateFields.forEach((singleMainField:any) =>{ this.mainStateFields.forEach((singleMainField:any) =>{
if(!(singleMainField in curData)){ if(!(singleMainField in curData)){
console.warn(`当前数据对象不包含属性${singleMainField},可能会发生错误`); console.warn(`当前数据对象不包含属性${singleMainField}」,根据「${singleMainField}」属性进行的主状态计算默认为空值`);
} }
}) })
for (let i = 0; i <= 1; i++) { for (let i = 0; i <= 1; i++) {
......
...@@ -199,7 +199,7 @@ export default class MsgUserAccountUIServiceBase extends UIService { ...@@ -199,7 +199,7 @@ export default class MsgUserAccountUIServiceBase extends UIService {
this.mainStateFields.forEach((singleMainField:any) =>{ this.mainStateFields.forEach((singleMainField:any) =>{
if(!(singleMainField in curData)){ if(!(singleMainField in curData)){
console.warn(`当前数据对象不包含属性${singleMainField},可能会发生错误`); console.warn(`当前数据对象不包含属性${singleMainField}」,根据「${singleMainField}」属性进行的主状态计算默认为空值`);
} }
}) })
for (let i = 0; i <= 1; i++) { for (let i = 0; i <= 1; i++) {
......
import { Store } from 'vuex'; import { Store } from 'vuex';
import AuthService from '@/authservice/auth-service';
/** /**
* 界面服务基类 * 界面服务基类
...@@ -63,6 +64,9 @@ export default class UIService { ...@@ -63,6 +64,9 @@ export default class UIService {
* @memberof UIService * @memberof UIService
*/ */
public getResourceOPPrivs(tag:any){ public getResourceOPPrivs(tag:any){
if(!this.authService) {
this.authService = new AuthService(this.getStore());
}
return this.authService.getResourcePermission(this.authService.sysOPPrivsMap.get(tag))?1:0; return this.authService.getResourcePermission(this.authService.sysOPPrivsMap.get(tag))?1:0;
} }
......
...@@ -260,7 +260,7 @@ export class ViewTool { ...@@ -260,7 +260,7 @@ export class ViewTool {
const _item = ActionModel[key]; const _item = ActionModel[key];
if(_item && _item['dataaccaction'] && UIService){ if(_item && _item['dataaccaction'] && UIService){
let dataActionResult:any; let dataActionResult:any;
if(Object.is(_item['actiontarget'],"NONE")){ if(Object.is(_item['actiontarget'],"NONE") || Object.is(_item['actiontarget'],"")){
dataActionResult = UIService.getResourceOPPrivs(_item['dataaccaction']); dataActionResult = UIService.getResourceOPPrivs(_item['dataaccaction']);
}else{ }else{
if(data && Object.keys(data).length >0){ if(data && Object.keys(data).length >0){
......
...@@ -223,6 +223,7 @@ export default class NotifyIndexViewBase extends Vue implements ControlInterface ...@@ -223,6 +223,7 @@ export default class NotifyIndexViewBase extends Vue implements ControlInterface
} }
/** /**
* 获取多项数据 * 获取多项数据
* *
......
...@@ -193,6 +193,7 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -193,6 +193,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
} }
/** /**
* 获取多项数据 * 获取多项数据
* *
......
...@@ -41,6 +41,14 @@ export default class DefaultService extends ControlService { ...@@ -41,6 +41,14 @@ export default class DefaultService extends ControlService {
this.model = new DefaultModel(); this.model = new DefaultModel();
} }
/**
* 远端数据
*
* @type {*}
* @memberof DefaultService
*/
private remoteCopyData:any = {};
/** /**
* 处理数据 * 处理数据
* *
...@@ -271,6 +279,7 @@ export default class DefaultService extends ControlService { ...@@ -271,6 +279,7 @@ export default class DefaultService extends ControlService {
result = this.appEntityService.Get(Context,Data, isloading); result = this.appEntityService.Get(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
this.handleResponse(action, response); this.handleResponse(action, response);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -301,6 +310,7 @@ export default class DefaultService extends ControlService { ...@@ -301,6 +310,7 @@ export default class DefaultService extends ControlService {
result = this.appEntityService.GetDraft(Context,Data, isloading); result = this.appEntityService.GetDraft(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -434,5 +444,24 @@ export default class DefaultService extends ControlService { ...@@ -434,5 +444,24 @@ export default class DefaultService extends ControlService {
return item; return item;
} }
/**
* 设置远端数据
*
* @param result 远端请求结果
* @memberof DefaultService
*/
public setRemoteCopyData(result:any){
if (result && result.status === 200) {
this.remoteCopyData = Util.deepCopy(result.data);
}
}
/**
* 获取远端数据
*
* @memberof DefaultService
*/
public getRemoteCopyData(){
return this.remoteCopyData;
}
} }
\ No newline at end of file
...@@ -41,6 +41,14 @@ export default class MainService extends ControlService { ...@@ -41,6 +41,14 @@ export default class MainService extends ControlService {
this.model = new MainModel(); this.model = new MainModel();
} }
/**
* 远端数据
*
* @type {*}
* @memberof MainService
*/
private remoteCopyData:any = {};
/** /**
* 处理数据 * 处理数据
* *
...@@ -271,6 +279,7 @@ export default class MainService extends ControlService { ...@@ -271,6 +279,7 @@ export default class MainService extends ControlService {
result = this.appEntityService.Get(Context,Data, isloading); result = this.appEntityService.Get(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
this.handleResponse(action, response); this.handleResponse(action, response);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -305,6 +314,7 @@ export default class MainService extends ControlService { ...@@ -305,6 +314,7 @@ export default class MainService extends ControlService {
result = this.appEntityService.GetDraft(Context,Data, isloading); result = this.appEntityService.GetDraft(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
response.data.id = PrimaryKey; response.data.id = PrimaryKey;
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
resolve(response); resolve(response);
...@@ -439,5 +449,24 @@ export default class MainService extends ControlService { ...@@ -439,5 +449,24 @@ export default class MainService extends ControlService {
return item; return item;
} }
/**
* 设置远端数据
*
* @param result 远端请求结果
* @memberof MainService
*/
public setRemoteCopyData(result:any){
if (result && result.status === 200) {
this.remoteCopyData = Util.deepCopy(result.data);
}
}
/**
* 获取远端数据
*
* @memberof MainService
*/
public getRemoteCopyData(){
return this.remoteCopyData;
}
} }
\ No newline at end of file
...@@ -255,6 +255,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -255,6 +255,7 @@ export default class MainBase extends Vue implements ControlInterface {
} }
/** /**
* 代码表服务对象 * 代码表服务对象
* *
...@@ -582,10 +583,10 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -582,10 +583,10 @@ export default class MainBase extends Vue implements ControlInterface {
/** /**
* 部件刷新 * 部件刷新
* *
* @param {any[]} args * @param {any} args
* @memberof MainBase * @memberof MainBase
*/ */
public refresh(args: any[]): void { public refresh(args?: any): void {
this.load(); this.load();
} }
...@@ -811,7 +812,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -811,7 +812,7 @@ export default class MainBase extends Vue implements ControlInterface {
this.totalrow = response.total; this.totalrow = response.total;
this.items = JSON.parse(JSON.stringify(data)); this.items = JSON.parse(JSON.stringify(data));
// 清空selections,gridItemsModel // 清空selections,gridItemsModel
this.selections = []; //this.selections = [];
this.gridItemsModel = []; this.gridItemsModel = [];
this.items.forEach(()=>{this.gridItemsModel.push(this.getGridRowModel())}); this.items.forEach(()=>{this.gridItemsModel.push(this.getGridRowModel())});
this.items.forEach((item:any)=>{ this.items.forEach((item:any)=>{
...@@ -821,8 +822,18 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -821,8 +822,18 @@ export default class MainBase extends Vue implements ControlInterface {
// 设置默认选中 // 设置默认选中
let _this = this; let _this = this;
setTimeout(() => { setTimeout(() => {
//在导航视图中,如已有选中数据,则右侧展开已选中数据的视图,如无选中数据则默认选中第一条
if(_this.isSelectFirstDefault){ if(_this.isSelectFirstDefault){
_this.rowClick(_this.items[0]); if(_this.selections && _this.selections.length > 0){
_this.selections.forEach((select: any)=>{
const index = _this.items.findIndex((item:any) => Object.is(item.srfkey,select.srfkey));
if(index != -1){
_this.rowClick(_this.items[index]);
}
})
}else{
_this.rowClick(this.items[0]);
}
} }
if(_this.selectedData){ if(_this.selectedData){
const refs: any = _this.$refs; const refs: any = _this.$refs;
...@@ -1950,6 +1961,33 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -1950,6 +1961,33 @@ export default class MainBase extends Vue implements ControlInterface {
public updateDefault(row: any){ public updateDefault(row: any){
} }
/**
* 计算数据对象类型的默认值
* @param {string} action 行为
* @param {string} param 默认值参数
* @param {*} data 当前行数据
* @memberof MainBase
*/
public computeDefaultValueWithParam(action:string,param:string,data:any){
if(Object.is(action,"UPDATE")){
const nativeData:any = this.service.getCopynativeData();
if(nativeData && (nativeData instanceof Array) && nativeData.length >0){
let targetData:any = nativeData.find((item:any) =>{
return item.id === data.srfkey;
})
if(targetData){
return targetData[param]?targetData[param]:null;
}else{
return null;
}
}else{
return null;
}
}else{
return this.service.getRemoteCopyData()[param]?this.service.getRemoteCopyData()[param]:null;
}
}
/** /**
* 校验属性值规则 * 校验属性值规则
* *
......
...@@ -47,7 +47,15 @@ export default class MainService extends ControlService { ...@@ -47,7 +47,15 @@ export default class MainService extends ControlService {
* @type {*} * @type {*}
* @memberof MainService * @memberof MainService
*/ */
public copynativeData:any; private copynativeData:any;
/**
* 远端数据
*
* @type {*}
* @memberof MainService
*/
private remoteCopyData:any = {};
/** /**
...@@ -239,7 +247,7 @@ export default class MainService extends ControlService { ...@@ -239,7 +247,7 @@ export default class MainService extends ControlService {
result =_appEntityService.FetchDefault(Context,Data, isloading); result =_appEntityService.FetchDefault(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.copynativeData = Util.deepCopy(response.data); this.setCopynativeData(response.data);
this.handleResponse(action, response); this.handleResponse(action, response);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -277,6 +285,7 @@ export default class MainService extends ControlService { ...@@ -277,6 +285,7 @@ export default class MainService extends ControlService {
//仿真主键数据 //仿真主键数据
response.data.id = Util.createUUID(); response.data.id = Util.createUUID();
} }
this.setRemoteCopyData(response);
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -443,4 +452,43 @@ export default class MainService extends ControlService { ...@@ -443,4 +452,43 @@ export default class MainService extends ControlService {
}); });
} }
/**
* 设置远端数据
*
* @param result 远端请求结果
* @memberof MainService
*/
public setRemoteCopyData(result:any){
if (result && result.status === 200) {
this.remoteCopyData = Util.deepCopy(result.data);
}
}
/**
* 获取远端数据
*
* @memberof MainService
*/
public getRemoteCopyData(){
return this.remoteCopyData;
}
/**
* 设置备份原生数据
*
* @param data 远端请求结果
* @memberof MainService
*/
public setCopynativeData(data:any){
this.copynativeData = Util.deepCopy(data);
}
/**
* 获取备份原生数据
*
* @memberof MainService
*/
public getCopynativeData(){
return this.copynativeData;
}
} }
\ No newline at end of file
...@@ -151,6 +151,7 @@ export default class PickupViewpickupviewpanelBase extends Vue implements Contro ...@@ -151,6 +151,7 @@ export default class PickupViewpickupviewpanelBase extends Vue implements Contro
/** /**
* 选中数据字符串 * 选中数据字符串
* *
......
...@@ -186,6 +186,7 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -186,6 +186,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
} }
/** /**
* 获取多项数据 * 获取多项数据
* *
......
...@@ -41,6 +41,14 @@ export default class DefaultService extends ControlService { ...@@ -41,6 +41,14 @@ export default class DefaultService extends ControlService {
this.model = new DefaultModel(); this.model = new DefaultModel();
} }
/**
* 远端数据
*
* @type {*}
* @memberof DefaultService
*/
private remoteCopyData:any = {};
/** /**
* 处理数据 * 处理数据
* *
...@@ -271,6 +279,7 @@ export default class DefaultService extends ControlService { ...@@ -271,6 +279,7 @@ export default class DefaultService extends ControlService {
result = this.appEntityService.Get(Context,Data, isloading); result = this.appEntityService.Get(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
this.handleResponse(action, response); this.handleResponse(action, response);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -301,6 +310,7 @@ export default class DefaultService extends ControlService { ...@@ -301,6 +310,7 @@ export default class DefaultService extends ControlService {
result = this.appEntityService.GetDraft(Context,Data, isloading); result = this.appEntityService.GetDraft(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -434,5 +444,24 @@ export default class DefaultService extends ControlService { ...@@ -434,5 +444,24 @@ export default class DefaultService extends ControlService {
return item; return item;
} }
/**
* 设置远端数据
*
* @param result 远端请求结果
* @memberof DefaultService
*/
public setRemoteCopyData(result:any){
if (result && result.status === 200) {
this.remoteCopyData = Util.deepCopy(result.data);
}
}
/**
* 获取远端数据
*
* @memberof DefaultService
*/
public getRemoteCopyData(){
return this.remoteCopyData;
}
} }
\ No newline at end of file
...@@ -50,6 +50,14 @@ export default class MainService extends ControlService { ...@@ -50,6 +50,14 @@ export default class MainService extends ControlService {
*/ */
public msgopenaccessService: MsgOpenAccessService = new MsgOpenAccessService(); public msgopenaccessService: MsgOpenAccessService = new MsgOpenAccessService();
/**
* 远端数据
*
* @type {*}
* @memberof MainService
*/
private remoteCopyData:any = {};
/** /**
* 处理数据 * 处理数据
* *
...@@ -283,6 +291,7 @@ export default class MainService extends ControlService { ...@@ -283,6 +291,7 @@ export default class MainService extends ControlService {
result = this.appEntityService.Get(Context,Data, isloading); result = this.appEntityService.Get(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
this.handleResponse(action, response); this.handleResponse(action, response);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -317,6 +326,7 @@ export default class MainService extends ControlService { ...@@ -317,6 +326,7 @@ export default class MainService extends ControlService {
result = this.appEntityService.GetDraft(Context,Data, isloading); result = this.appEntityService.GetDraft(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
response.data.tid = PrimaryKey; response.data.tid = PrimaryKey;
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
resolve(response); resolve(response);
...@@ -451,5 +461,24 @@ export default class MainService extends ControlService { ...@@ -451,5 +461,24 @@ export default class MainService extends ControlService {
return item; return item;
} }
/**
* 设置远端数据
*
* @param result 远端请求结果
* @memberof MainService
*/
public setRemoteCopyData(result:any){
if (result && result.status === 200) {
this.remoteCopyData = Util.deepCopy(result.data);
}
}
/**
* 获取远端数据
*
* @memberof MainService
*/
public getRemoteCopyData(){
return this.remoteCopyData;
}
} }
\ No newline at end of file
...@@ -269,6 +269,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -269,6 +269,7 @@ export default class MainBase extends Vue implements ControlInterface {
} }
/** /**
* 代码表服务对象 * 代码表服务对象
* *
...@@ -596,10 +597,10 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -596,10 +597,10 @@ export default class MainBase extends Vue implements ControlInterface {
/** /**
* 部件刷新 * 部件刷新
* *
* @param {any[]} args * @param {any} args
* @memberof MainBase * @memberof MainBase
*/ */
public refresh(args: any[]): void { public refresh(args?: any): void {
this.load(); this.load();
} }
...@@ -833,7 +834,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -833,7 +834,7 @@ export default class MainBase extends Vue implements ControlInterface {
this.totalrow = response.total; this.totalrow = response.total;
this.items = JSON.parse(JSON.stringify(data)); this.items = JSON.parse(JSON.stringify(data));
// 清空selections,gridItemsModel // 清空selections,gridItemsModel
this.selections = []; //this.selections = [];
this.gridItemsModel = []; this.gridItemsModel = [];
this.items.forEach(()=>{this.gridItemsModel.push(this.getGridRowModel())}); this.items.forEach(()=>{this.gridItemsModel.push(this.getGridRowModel())});
this.items.forEach((item:any)=>{ this.items.forEach((item:any)=>{
...@@ -843,8 +844,18 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -843,8 +844,18 @@ export default class MainBase extends Vue implements ControlInterface {
// 设置默认选中 // 设置默认选中
let _this = this; let _this = this;
setTimeout(() => { setTimeout(() => {
//在导航视图中,如已有选中数据,则右侧展开已选中数据的视图,如无选中数据则默认选中第一条
if(_this.isSelectFirstDefault){ if(_this.isSelectFirstDefault){
_this.rowClick(_this.items[0]); if(_this.selections && _this.selections.length > 0){
_this.selections.forEach((select: any)=>{
const index = _this.items.findIndex((item:any) => Object.is(item.srfkey,select.srfkey));
if(index != -1){
_this.rowClick(_this.items[index]);
}
})
}else{
_this.rowClick(this.items[0]);
}
} }
if(_this.selectedData){ if(_this.selectedData){
const refs: any = _this.$refs; const refs: any = _this.$refs;
...@@ -1981,6 +1992,33 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -1981,6 +1992,33 @@ export default class MainBase extends Vue implements ControlInterface {
public updateDefault(row: any){ public updateDefault(row: any){
} }
/**
* 计算数据对象类型的默认值
* @param {string} action 行为
* @param {string} param 默认值参数
* @param {*} data 当前行数据
* @memberof MainBase
*/
public computeDefaultValueWithParam(action:string,param:string,data:any){
if(Object.is(action,"UPDATE")){
const nativeData:any = this.service.getCopynativeData();
if(nativeData && (nativeData instanceof Array) && nativeData.length >0){
let targetData:any = nativeData.find((item:any) =>{
return item.tid === data.srfkey;
})
if(targetData){
return targetData[param]?targetData[param]:null;
}else{
return null;
}
}else{
return null;
}
}else{
return this.service.getRemoteCopyData()[param]?this.service.getRemoteCopyData()[param]:null;
}
}
/** /**
* 校验属性值规则 * 校验属性值规则
* *
......
...@@ -47,7 +47,15 @@ export default class MainService extends ControlService { ...@@ -47,7 +47,15 @@ export default class MainService extends ControlService {
* @type {*} * @type {*}
* @memberof MainService * @memberof MainService
*/ */
public copynativeData:any; private copynativeData:any;
/**
* 远端数据
*
* @type {*}
* @memberof MainService
*/
private remoteCopyData:any = {};
/** /**
...@@ -239,7 +247,7 @@ export default class MainService extends ControlService { ...@@ -239,7 +247,7 @@ export default class MainService extends ControlService {
result =_appEntityService.FetchDefault(Context,Data, isloading); result =_appEntityService.FetchDefault(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.copynativeData = Util.deepCopy(response.data); this.setCopynativeData(response.data);
this.handleResponse(action, response); this.handleResponse(action, response);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -277,6 +285,7 @@ export default class MainService extends ControlService { ...@@ -277,6 +285,7 @@ export default class MainService extends ControlService {
//仿真主键数据 //仿真主键数据
response.data.tid = Util.createUUID(); response.data.tid = Util.createUUID();
} }
this.setRemoteCopyData(response);
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -443,4 +452,43 @@ export default class MainService extends ControlService { ...@@ -443,4 +452,43 @@ export default class MainService extends ControlService {
}); });
} }
/**
* 设置远端数据
*
* @param result 远端请求结果
* @memberof MainService
*/
public setRemoteCopyData(result:any){
if (result && result.status === 200) {
this.remoteCopyData = Util.deepCopy(result.data);
}
}
/**
* 获取远端数据
*
* @memberof MainService
*/
public getRemoteCopyData(){
return this.remoteCopyData;
}
/**
* 设置备份原生数据
*
* @param data 远端请求结果
* @memberof MainService
*/
public setCopynativeData(data:any){
this.copynativeData = Util.deepCopy(data);
}
/**
* 获取备份原生数据
*
* @memberof MainService
*/
public getCopynativeData(){
return this.copynativeData;
}
} }
\ No newline at end of file
...@@ -172,6 +172,7 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -172,6 +172,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
} }
/** /**
* 获取多项数据 * 获取多项数据
* *
......
...@@ -41,6 +41,14 @@ export default class DefaultService extends ControlService { ...@@ -41,6 +41,14 @@ export default class DefaultService extends ControlService {
this.model = new DefaultModel(); this.model = new DefaultModel();
} }
/**
* 远端数据
*
* @type {*}
* @memberof DefaultService
*/
private remoteCopyData:any = {};
/** /**
* 处理数据 * 处理数据
* *
...@@ -271,6 +279,7 @@ export default class DefaultService extends ControlService { ...@@ -271,6 +279,7 @@ export default class DefaultService extends ControlService {
result = this.appEntityService.Get(Context,Data, isloading); result = this.appEntityService.Get(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
this.handleResponse(action, response); this.handleResponse(action, response);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -301,6 +310,7 @@ export default class DefaultService extends ControlService { ...@@ -301,6 +310,7 @@ export default class DefaultService extends ControlService {
result = this.appEntityService.GetDraft(Context,Data, isloading); result = this.appEntityService.GetDraft(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -434,5 +444,24 @@ export default class DefaultService extends ControlService { ...@@ -434,5 +444,24 @@ export default class DefaultService extends ControlService {
return item; return item;
} }
/**
* 设置远端数据
*
* @param result 远端请求结果
* @memberof DefaultService
*/
public setRemoteCopyData(result:any){
if (result && result.status === 200) {
this.remoteCopyData = Util.deepCopy(result.data);
}
}
/**
* 获取远端数据
*
* @memberof DefaultService
*/
public getRemoteCopyData(){
return this.remoteCopyData;
}
} }
\ No newline at end of file
...@@ -201,6 +201,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -201,6 +201,7 @@ export default class MainBase extends Vue implements ControlInterface {
} }
/** /**
* 视图默认使用 * 视图默认使用
* *
...@@ -445,72 +446,18 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -445,72 +446,18 @@ export default class MainBase extends Vue implements ControlInterface {
*/ */
public rules() :any { public rules() :any {
return { return {
srforikey: [
{ type: 'string', message: ' 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: ' 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.srforikey.required, type: 'string', message: ' 值不能为空', trigger: 'change' },
{ required: this.detailsModel.srforikey.required, type: 'string', message: ' 值不能为空', trigger: 'blur' },
],
srfkey: [
{ type: 'string', message: '标识 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: '标识 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.srfkey.required, type: 'string', message: '标识 值不能为空', trigger: 'change' },
{ required: this.detailsModel.srfkey.required, type: 'string', message: '标识 值不能为空', trigger: 'blur' },
],
srfmajortext: [
{ type: 'string', message: '认证标识 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: '认证标识 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.srfmajortext.required, type: 'string', message: '认证标识 值不能为空', trigger: 'change' },
{ required: this.detailsModel.srfmajortext.required, type: 'string', message: '认证标识 值不能为空', trigger: 'blur' },
],
srftempmode: [
{ type: 'string', message: ' 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: ' 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.srftempmode.required, type: 'string', message: ' 值不能为空', trigger: 'change' },
{ required: this.detailsModel.srftempmode.required, type: 'string', message: ' 值不能为空', trigger: 'blur' },
],
srfuf: [
{ type: 'string', message: ' 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: ' 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.srfuf.required, type: 'string', message: ' 值不能为空', trigger: 'change' },
{ required: this.detailsModel.srfuf.required, type: 'string', message: ' 值不能为空', trigger: 'blur' },
],
srfdeid: [
{ type: 'string', message: ' 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: ' 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.srfdeid.required, type: 'string', message: ' 值不能为空', trigger: 'change' },
{ required: this.detailsModel.srfdeid.required, type: 'string', message: ' 值不能为空', trigger: 'blur' },
],
srfsourcekey: [
{ type: 'string', message: ' 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: ' 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.srfsourcekey.required, type: 'string', message: ' 值不能为空', trigger: 'change' },
{ required: this.detailsModel.srfsourcekey.required, type: 'string', message: ' 值不能为空', trigger: 'blur' },
],
userid: [ userid: [
{ type: 'string', message: '用户标识 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: '用户标识 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.userid.required, type: 'string', message: '用户标识 值不能为空', trigger: 'change' }, { required: this.detailsModel.userid.required, type: 'string', message: '用户标识 值不能为空', trigger: 'change' },
{ required: this.detailsModel.userid.required, type: 'string', message: '用户标识 值不能为空', trigger: 'blur' }, { required: this.detailsModel.userid.required, type: 'string', message: '用户标识 值不能为空', trigger: 'blur' },
], ],
identity_type: [ identity_type: [
{ type: 'string', message: '认证类型 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: '认证类型 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.identity_type.required, type: 'string', message: '认证类型 值不能为空', trigger: 'change' }, { required: this.detailsModel.identity_type.required, type: 'string', message: '认证类型 值不能为空', trigger: 'change' },
{ required: this.detailsModel.identity_type.required, type: 'string', message: '认证类型 值不能为空', trigger: 'blur' }, { required: this.detailsModel.identity_type.required, type: 'string', message: '认证类型 值不能为空', trigger: 'blur' },
], ],
identifier: [ identifier: [
{ type: 'string', message: '认证标识 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: '认证标识 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.identifier.required, type: 'string', message: '认证标识 值不能为空', trigger: 'change' }, { required: this.detailsModel.identifier.required, type: 'string', message: '认证标识 值不能为空', trigger: 'change' },
{ required: this.detailsModel.identifier.required, type: 'string', message: '认证标识 值不能为空', trigger: 'blur' }, { required: this.detailsModel.identifier.required, type: 'string', message: '认证标识 值不能为空', trigger: 'blur' },
], ],
authid: [
{ type: 'string', message: '标识 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: '标识 值必须为字符串类型', trigger: 'blur' },
{ required: this.detailsModel.authid.required, type: 'string', message: '标识 值不能为空', trigger: 'change' },
{ required: this.detailsModel.authid.required, type: 'string', message: '标识 值不能为空', trigger: 'blur' },
],
} }
} }
...@@ -547,32 +494,38 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -547,32 +494,38 @@ export default class MainBase extends Vue implements ControlInterface {
falg.isPast = val; falg.isPast = val;
} }
} }
rule[name].forEach((item:any) => { for(let i=0;i<rule[name].length;i++){
let item:any = rule[name][i];
let dataValue = item.deName?this.data[this.service.getItemNameByDeName(item.deName)]:""; let dataValue = item.deName?this.data[this.service.getItemNameByDeName(item.deName)]:"";
// 常规规则 // 常规规则
if(item.type == 'SIMPLE'){ if(item.type == 'SIMPLE'){
startOp(!this.$verify.checkFieldSimpleRule(dataValue,item.condOP,item.paramValue,item.ruleInfo,item.paramType,this.data,item.isKeyCond)); startOp(!this.$verify.checkFieldSimpleRule(dataValue,item.condOP,item.paramValue,item.ruleInfo,item.paramType,this.data,item.isKeyCond));
falg.infoMessage = item.ruleInfo; falg.infoMessage = item.ruleInfo;
if(!falg.isPast) return falg;
} }
// 数值范围 // 数值范围
if(item.type == 'VALUERANGE2'){ if(item.type == 'VALUERANGE2'){
startOp( !this.$verify.checkFieldValueRangeRule(dataValue,item.minValue,item.isIncludeMinValue,item.maxValue,item.isIncludeMaxValue,item.ruleInfo,item.isKeyCond)); startOp( !this.$verify.checkFieldValueRangeRule(dataValue,item.minValue,item.isIncludeMinValue,item.maxValue,item.isIncludeMaxValue,item.ruleInfo,item.isKeyCond));
falg.infoMessage = item.ruleInfo; falg.infoMessage = item.ruleInfo;
if(!falg.isPast) return falg;
} }
// 正则式 // 正则式
if (item.type == "REGEX") { if (item.type == "REGEX") {
startOp(!this.$verify.checkFieldRegExRule(dataValue,item.regExCode,item.ruleInfo,item.isKeyCond)); startOp(!this.$verify.checkFieldRegExRule(dataValue,item.regExCode,item.ruleInfo,item.isKeyCond));
falg.infoMessage = item.ruleInfo; falg.infoMessage = item.ruleInfo;
if(!falg.isPast) return falg;
} }
// 长度 // 长度
if (item.type == "STRINGLENGTH") { if (item.type == "STRINGLENGTH") {
startOp(!this.$verify.checkFieldStringLengthRule(dataValue,item.minValue,item.isIncludeMinValue,item.maxValue,item.isIncludeMaxValue,item.ruleInfo,item.isKeyCond)); startOp(!this.$verify.checkFieldStringLengthRule(dataValue,item.minValue,item.isIncludeMinValue,item.maxValue,item.isIncludeMaxValue,item.ruleInfo,item.isKeyCond));
falg.infoMessage = item.ruleInfo; falg.infoMessage = item.ruleInfo;
if(!falg.isPast) return falg;
} }
// 系统值规则 // 系统值规则
if(item.type == "SYSVALUERULE") { if(item.type == "SYSVALUERULE") {
startOp(!this.$verify.checkFieldSysValueRule(dataValue,item.sysRule.regExCode,item.ruleInfo,item.isKeyCond)); startOp(!this.$verify.checkFieldSysValueRule(dataValue,item.sysRule.regExCode,item.ruleInfo,item.isKeyCond));
falg.infoMessage = item.ruleInfo; falg.infoMessage = item.ruleInfo;
if(!falg.isPast) return falg;
} }
// 分组 // 分组
if(item.type == 'GROUP'){ if(item.type == 'GROUP'){
...@@ -580,9 +533,9 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -580,9 +533,9 @@ export default class MainBase extends Vue implements ControlInterface {
if(item.isNotMode){ if(item.isNotMode){
falg.isPast = !falg.isPast; falg.isPast = !falg.isPast;
} }
if(!falg.isPast) return falg;
}
} }
});
if(!falg.hasOwnProperty("isPast")){ if(!falg.hasOwnProperty("isPast")){
falg.isPast = true; falg.isPast = true;
} }
...@@ -1181,12 +1134,12 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -1181,12 +1134,12 @@ export default class MainBase extends Vue implements ControlInterface {
/** /**
* 部件刷新 * 部件刷新
* *
* @param {any[]} args * @param {any} args
* @memberof MainBase * @memberof MainBase
*/ */
public refresh(args: any[]): void { public refresh(args?: any): void {
let arg: any = {}; let arg: any = {};
Object.assign(arg,args[0]); Object.assign(arg,args?args[0]:{});
if (this.data.srfkey && !Object.is(this.data.srfkey, '')) { if (this.data.srfkey && !Object.is(this.data.srfkey, '')) {
Object.assign(arg, { srfkey: this.data.srfkey }); Object.assign(arg, { srfkey: this.data.srfkey });
this.load(arg); this.load(arg);
......
...@@ -41,6 +41,14 @@ export default class MainService extends ControlService { ...@@ -41,6 +41,14 @@ export default class MainService extends ControlService {
this.model = new MainModel(); this.model = new MainModel();
} }
/**
* 远端数据
*
* @type {*}
* @memberof MainService
*/
private remoteCopyData:any = {};
/** /**
* 处理数据 * 处理数据
* *
...@@ -271,6 +279,7 @@ export default class MainService extends ControlService { ...@@ -271,6 +279,7 @@ export default class MainService extends ControlService {
result = this.appEntityService.Get(Context,Data, isloading); result = this.appEntityService.Get(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
this.handleResponse(action, response); this.handleResponse(action, response);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -305,6 +314,7 @@ export default class MainService extends ControlService { ...@@ -305,6 +314,7 @@ export default class MainService extends ControlService {
result = this.appEntityService.GetDraft(Context,Data, isloading); result = this.appEntityService.GetDraft(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.setRemoteCopyData(response);
response.data.id = PrimaryKey; response.data.id = PrimaryKey;
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
resolve(response); resolve(response);
...@@ -439,5 +449,24 @@ export default class MainService extends ControlService { ...@@ -439,5 +449,24 @@ export default class MainService extends ControlService {
return item; return item;
} }
/**
* 设置远端数据
*
* @param result 远端请求结果
* @memberof MainService
*/
public setRemoteCopyData(result:any){
if (result && result.status === 200) {
this.remoteCopyData = Util.deepCopy(result.data);
}
}
/**
* 获取远端数据
*
* @memberof MainService
*/
public getRemoteCopyData(){
return this.remoteCopyData;
}
} }
\ No newline at end of file
...@@ -243,6 +243,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -243,6 +243,7 @@ export default class MainBase extends Vue implements ControlInterface {
} }
/** /**
* 代码表服务对象 * 代码表服务对象
* *
...@@ -570,10 +571,10 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -570,10 +571,10 @@ export default class MainBase extends Vue implements ControlInterface {
/** /**
* 部件刷新 * 部件刷新
* *
* @param {any[]} args * @param {any} args
* @memberof MainBase * @memberof MainBase
*/ */
public refresh(args: any[]): void { public refresh(args?: any): void {
this.load(); this.load();
} }
...@@ -791,7 +792,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -791,7 +792,7 @@ export default class MainBase extends Vue implements ControlInterface {
this.totalrow = response.total; this.totalrow = response.total;
this.items = JSON.parse(JSON.stringify(data)); this.items = JSON.parse(JSON.stringify(data));
// 清空selections,gridItemsModel // 清空selections,gridItemsModel
this.selections = []; //this.selections = [];
this.gridItemsModel = []; this.gridItemsModel = [];
this.items.forEach(()=>{this.gridItemsModel.push(this.getGridRowModel())}); this.items.forEach(()=>{this.gridItemsModel.push(this.getGridRowModel())});
this.items.forEach((item:any)=>{ this.items.forEach((item:any)=>{
...@@ -801,8 +802,18 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -801,8 +802,18 @@ export default class MainBase extends Vue implements ControlInterface {
// 设置默认选中 // 设置默认选中
let _this = this; let _this = this;
setTimeout(() => { setTimeout(() => {
//在导航视图中,如已有选中数据,则右侧展开已选中数据的视图,如无选中数据则默认选中第一条
if(_this.isSelectFirstDefault){ if(_this.isSelectFirstDefault){
_this.rowClick(_this.items[0]); if(_this.selections && _this.selections.length > 0){
_this.selections.forEach((select: any)=>{
const index = _this.items.findIndex((item:any) => Object.is(item.srfkey,select.srfkey));
if(index != -1){
_this.rowClick(_this.items[index]);
}
})
}else{
_this.rowClick(this.items[0]);
}
} }
if(_this.selectedData){ if(_this.selectedData){
const refs: any = _this.$refs; const refs: any = _this.$refs;
...@@ -1929,6 +1940,33 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -1929,6 +1940,33 @@ export default class MainBase extends Vue implements ControlInterface {
public updateDefault(row: any){ public updateDefault(row: any){
} }
/**
* 计算数据对象类型的默认值
* @param {string} action 行为
* @param {string} param 默认值参数
* @param {*} data 当前行数据
* @memberof MainBase
*/
public computeDefaultValueWithParam(action:string,param:string,data:any){
if(Object.is(action,"UPDATE")){
const nativeData:any = this.service.getCopynativeData();
if(nativeData && (nativeData instanceof Array) && nativeData.length >0){
let targetData:any = nativeData.find((item:any) =>{
return item.id === data.srfkey;
})
if(targetData){
return targetData[param]?targetData[param]:null;
}else{
return null;
}
}else{
return null;
}
}else{
return this.service.getRemoteCopyData()[param]?this.service.getRemoteCopyData()[param]:null;
}
}
/** /**
* 校验属性值规则 * 校验属性值规则
* *
......
...@@ -47,7 +47,15 @@ export default class MainService extends ControlService { ...@@ -47,7 +47,15 @@ export default class MainService extends ControlService {
* @type {*} * @type {*}
* @memberof MainService * @memberof MainService
*/ */
public copynativeData:any; private copynativeData:any;
/**
* 远端数据
*
* @type {*}
* @memberof MainService
*/
private remoteCopyData:any = {};
/** /**
...@@ -239,7 +247,7 @@ export default class MainService extends ControlService { ...@@ -239,7 +247,7 @@ export default class MainService extends ControlService {
result =_appEntityService.FetchDefault(Context,Data, isloading); result =_appEntityService.FetchDefault(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
this.copynativeData = Util.deepCopy(response.data); this.setCopynativeData(response.data);
this.handleResponse(action, response); this.handleResponse(action, response);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -277,6 +285,7 @@ export default class MainService extends ControlService { ...@@ -277,6 +285,7 @@ export default class MainService extends ControlService {
//仿真主键数据 //仿真主键数据
response.data.id = Util.createUUID(); response.data.id = Util.createUUID();
} }
this.setRemoteCopyData(response);
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -443,4 +452,43 @@ export default class MainService extends ControlService { ...@@ -443,4 +452,43 @@ export default class MainService extends ControlService {
}); });
} }
/**
* 设置远端数据
*
* @param result 远端请求结果
* @memberof MainService
*/
public setRemoteCopyData(result:any){
if (result && result.status === 200) {
this.remoteCopyData = Util.deepCopy(result.data);
}
}
/**
* 获取远端数据
*
* @memberof MainService
*/
public getRemoteCopyData(){
return this.remoteCopyData;
}
/**
* 设置备份原生数据
*
* @param data 远端请求结果
* @memberof MainService
*/
public setCopynativeData(data:any){
this.copynativeData = Util.deepCopy(data);
}
/**
* 获取备份原生数据
*
* @memberof MainService
*/
public getCopynativeData(){
return this.copynativeData;
}
} }
\ No newline at end of file
...@@ -32,7 +32,7 @@ zuul: ...@@ -32,7 +32,7 @@ zuul:
serviceId: ${ibiz.ref.service.uaa:ibzuaa-api} serviceId: ${ibiz.ref.service.uaa:ibzuaa-api}
stripPrefix: false stripPrefix: false
config: config:
path: /config/** path: /configs/**
serviceId: ${ibiz.ref.service.uaa:ibzuaa-api} serviceId: ${ibiz.ref.service.uaa:ibzuaa-api}
stripPrefix: false stripPrefix: false
oucore: oucore:
......
...@@ -17,7 +17,7 @@ zuul: ...@@ -17,7 +17,7 @@ zuul:
serviceId: ${ibiz.ref.service.uaa:ibzuaa-api} serviceId: ${ibiz.ref.service.uaa:ibzuaa-api}
stripPrefix: false stripPrefix: false
config: config:
path: /config/** path: /configs/**
serviceId: ${ibiz.ref.service.uaa:ibzuaa-api} serviceId: ${ibiz.ref.service.uaa:ibzuaa-api}
stripPrefix: false stripPrefix: false
oucore: oucore:
......
...@@ -18,6 +18,7 @@ import cn.ibizlab.util.domain.EntityBase; ...@@ -18,6 +18,7 @@ import cn.ibizlab.util.domain.EntityBase;
import cn.ibizlab.util.annotation.DEField; import cn.ibizlab.util.annotation.DEField;
import cn.ibizlab.util.enums.DEPredefinedFieldType; import cn.ibizlab.util.enums.DEPredefinedFieldType;
import cn.ibizlab.util.enums.DEFieldDefaultValueType; import cn.ibizlab.util.enums.DEFieldDefaultValueType;
import cn.ibizlab.util.helper.DataObject;
import java.io.Serializable; import java.io.Serializable;
import lombok.*; import lombok.*;
import org.springframework.data.annotation.Transient; import org.springframework.data.annotation.Transient;
......
...@@ -18,6 +18,7 @@ import cn.ibizlab.util.domain.EntityBase; ...@@ -18,6 +18,7 @@ import cn.ibizlab.util.domain.EntityBase;
import cn.ibizlab.util.annotation.DEField; import cn.ibizlab.util.annotation.DEField;
import cn.ibizlab.util.enums.DEPredefinedFieldType; import cn.ibizlab.util.enums.DEPredefinedFieldType;
import cn.ibizlab.util.enums.DEFieldDefaultValueType; import cn.ibizlab.util.enums.DEFieldDefaultValueType;
import cn.ibizlab.util.helper.DataObject;
import java.io.Serializable; import java.io.Serializable;
import lombok.*; import lombok.*;
import org.springframework.data.annotation.Transient; import org.springframework.data.annotation.Transient;
......
...@@ -18,6 +18,7 @@ import cn.ibizlab.util.domain.EntityBase; ...@@ -18,6 +18,7 @@ import cn.ibizlab.util.domain.EntityBase;
import cn.ibizlab.util.annotation.DEField; import cn.ibizlab.util.annotation.DEField;
import cn.ibizlab.util.enums.DEPredefinedFieldType; import cn.ibizlab.util.enums.DEPredefinedFieldType;
import cn.ibizlab.util.enums.DEFieldDefaultValueType; import cn.ibizlab.util.enums.DEFieldDefaultValueType;
import cn.ibizlab.util.helper.DataObject;
import java.io.Serializable; import java.io.Serializable;
import lombok.*; import lombok.*;
import org.springframework.data.annotation.Transient; import org.springframework.data.annotation.Transient;
......
...@@ -18,6 +18,7 @@ import cn.ibizlab.util.domain.EntityBase; ...@@ -18,6 +18,7 @@ import cn.ibizlab.util.domain.EntityBase;
import cn.ibizlab.util.annotation.DEField; import cn.ibizlab.util.annotation.DEField;
import cn.ibizlab.util.enums.DEPredefinedFieldType; import cn.ibizlab.util.enums.DEPredefinedFieldType;
import cn.ibizlab.util.enums.DEFieldDefaultValueType; import cn.ibizlab.util.enums.DEFieldDefaultValueType;
import cn.ibizlab.util.helper.DataObject;
import java.io.Serializable; import java.io.Serializable;
import lombok.*; import lombok.*;
import org.springframework.data.annotation.Transient; import org.springframework.data.annotation.Transient;
......
...@@ -190,6 +190,7 @@ public class MsgBodyServiceImpl extends ServiceImpl<MsgBodyMapper, MsgBody> impl ...@@ -190,6 +190,7 @@ public class MsgBodyServiceImpl extends ServiceImpl<MsgBodyMapper, MsgBody> impl
} }
......
...@@ -193,6 +193,7 @@ public class MsgOpenAccessServiceImpl extends ServiceImpl<MsgOpenAccessMapper, M ...@@ -193,6 +193,7 @@ public class MsgOpenAccessServiceImpl extends ServiceImpl<MsgOpenAccessMapper, M
} }
......
...@@ -189,9 +189,7 @@ public class MsgTemplateServiceImpl extends ServiceImpl<MsgTemplateMapper, MsgTe ...@@ -189,9 +189,7 @@ public class MsgTemplateServiceImpl extends ServiceImpl<MsgTemplateMapper, MsgTe
if(!ObjectUtils.isEmpty(et.getAccessId())){ if(!ObjectUtils.isEmpty(et.getAccessId())){
cn.ibizlab.core.notify.domain.MsgOpenAccess openaccess=et.getOpenaccess(); cn.ibizlab.core.notify.domain.MsgOpenAccess openaccess=et.getOpenaccess();
if(ObjectUtils.isEmpty(openaccess)){ if(ObjectUtils.isEmpty(openaccess)){
cn.ibizlab.core.notify.domain.MsgOpenAccess majorEntity=msgopenaccessService.getById(et.getAccessId()); cn.ibizlab.core.notify.domain.MsgOpenAccess majorEntity=msgopenaccessService.get(et.getAccessId());
if(ObjectUtils.isEmpty(majorEntity))
return;
et.setOpenaccess(majorEntity); et.setOpenaccess(majorEntity);
openaccess=majorEntity; openaccess=majorEntity;
} }
...@@ -229,6 +227,7 @@ public class MsgTemplateServiceImpl extends ServiceImpl<MsgTemplateMapper, MsgTe ...@@ -229,6 +227,7 @@ public class MsgTemplateServiceImpl extends ServiceImpl<MsgTemplateMapper, MsgTe
} }
......
...@@ -190,6 +190,7 @@ public class MsgUserAccountServiceImpl extends ServiceImpl<MsgUserAccountMapper, ...@@ -190,6 +190,7 @@ public class MsgUserAccountServiceImpl extends ServiceImpl<MsgUserAccountMapper,
} }
......
<?xml version="1.1" encoding="UTF-8" standalone="no"?>
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog" xmlns:ext="http://www.liquibase.org/xml/ns/dbchangelog-ext" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog-ext http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-ext.xsd http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.9.xsd">
<changeSet author="Think (generated)" id="1592547336292-1">
<preConditions onFail="MARK_RAN" >
<not >
<tableExists tableName="IBZCFG" />
</not>
</preConditions>
<createTable remarks="配置" tableName="IBZCFG">
<column name="CFGID" remarks="配置标识" type="VARCHAR(100)">
<constraints primaryKey="true"/>
</column>
<column name="SYSTEMID" remarks="系统标识" type="VARCHAR(100)"/>
<column name="CFGTYPE" remarks="配置类型" type="VARCHAR(100)"/>
<column name="TARGETTYPE" remarks="引用对象" type="VARCHAR(100)"/>
<column name="USERID" remarks="用户标识" type="VARCHAR(100)"/>
<column name="CFG" remarks="配置" type="MEDIUMTEXT"/>
<column name="UPDATEDATE" remarks="更新时间" type="datetime"/>
</createTable>
</changeSet>
</databaseChangeLog>
...@@ -47,5 +47,6 @@ public class MsgBodyResource { ...@@ -47,5 +47,6 @@ public class MsgBodyResource {
@Lazy @Lazy
public MsgBodyMapping msgbodyMapping; public MsgBodyMapping msgbodyMapping;
} }
...@@ -156,5 +156,7 @@ public class MsgOpenAccessResource { ...@@ -156,5 +156,7 @@ public class MsgOpenAccessResource {
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(msgopenaccessMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements())); .body(new PageImpl(msgopenaccessMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
} }
} }
...@@ -156,5 +156,7 @@ public class MsgTemplateResource { ...@@ -156,5 +156,7 @@ public class MsgTemplateResource {
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(msgtemplateMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements())); .body(new PageImpl(msgtemplateMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
} }
} }
...@@ -156,5 +156,7 @@ public class MsgUserAccountResource { ...@@ -156,5 +156,7 @@ public class MsgUserAccountResource {
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(msguseraccountMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements())); .body(new PageImpl(msguseraccountMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
} }
} }
...@@ -54,6 +54,7 @@ public class AuditAspect ...@@ -54,6 +54,7 @@ public class AuditAspect
return; return;
Object serviceParam =args[0]; Object serviceParam =args[0];
if(serviceParam instanceof EntityBase){
EntityBase entity=(EntityBase)serviceParam;//创建数据 EntityBase entity=(EntityBase)serviceParam;//创建数据
Map<String, Audit> auditFields= DEFieldCacheMap.getAuditFields(entity.getClass()); Map<String, Audit> auditFields= DEFieldCacheMap.getAuditFields(entity.getClass());
if(auditFields.size()==0)//是否有审计属性 if(auditFields.size()==0)//是否有审计属性
...@@ -66,7 +67,7 @@ public class AuditAspect ...@@ -66,7 +67,7 @@ public class AuditAspect
} }
//记录审计日志 //记录审计日志
dataAuditService.createAudit(request,entity,idValue,auditFields); dataAuditService.createAudit(request,entity,idValue,auditFields);
return; }
} }
/** /**
...@@ -88,6 +89,7 @@ public class AuditAspect ...@@ -88,6 +89,7 @@ public class AuditAspect
return point.proceed(); return point.proceed();
Object arg=args[0]; Object arg=args[0];
if(arg instanceof EntityBase){
EntityBase entity= (EntityBase) arg; EntityBase entity= (EntityBase) arg;
Map<String, Audit> auditFields= DEFieldCacheMap.getAuditFields(entity.getClass()); Map<String, Audit> auditFields= DEFieldCacheMap.getAuditFields(entity.getClass());
...@@ -110,6 +112,8 @@ public class AuditAspect ...@@ -110,6 +112,8 @@ public class AuditAspect
dataAuditService.updateAudit(request,beforeEntity,serviceObj,idValue,auditFields); dataAuditService.updateAudit(request,beforeEntity,serviceObj,idValue,auditFields);
return true; return true;
} }
return point.proceed();
}
/** /**
* 实体数据更新切面,在成功更新数据后将新增数据内容记录审计日志内(审计明细【AuditInfo】中只记录审计属性变化情况,审计属性在平台属性中配置) * 实体数据更新切面,在成功更新数据后将新增数据内容记录审计日志内(审计明细【AuditInfo】中只记录审计属性变化情况,审计属性在平台属性中配置)
......
...@@ -11,6 +11,7 @@ import java.util.Map; ...@@ -11,6 +11,7 @@ import java.util.Map;
import java.util.concurrent.Callable; import java.util.concurrent.Callable;
import cn.ibizlab.util.cache.listener.RedisPublisher; import cn.ibizlab.util.cache.listener.RedisPublisher;
import cn.ibizlab.util.enums.RedisChannelTopic; import cn.ibizlab.util.enums.RedisChannelTopic;
import org.springframework.util.ObjectUtils;
/** /**
* 缓存分层类 * 缓存分层类
...@@ -58,11 +59,16 @@ public class LayeringCache extends AbstractValueAdaptingCache { ...@@ -58,11 +59,16 @@ public class LayeringCache extends AbstractValueAdaptingCache {
@Override @Override
public ValueWrapper get(Object key) { public ValueWrapper get(Object key) {
ValueWrapper wrapper = caffeineCache.get(key); ValueWrapper wrapper = caffeineCache.get(key);
log.debug("查询一级缓存 key:{},value:{}", key,wrapper); Object value=ObjectUtils.isEmpty(wrapper)?null:wrapper.get();
if (wrapper == null) { log.debug("查询一级缓存 key:{} ,value:{}", key,value);
if (ObjectUtils.isEmpty(value)) {
wrapper = redisCache.get(key); wrapper = redisCache.get(key);
caffeineCache.put(key, wrapper == null ? null : wrapper.get()); value=ObjectUtils.isEmpty(wrapper)?null:wrapper.get();
log.debug("查询二级缓存,并将数据放到一级缓存。 key:{}", key); log.debug("查询二级缓存 key:{} ,value:{}", key,value);
if(!ObjectUtils.isEmpty(value)){
caffeineCache.put(key, value);
log.debug("查询二级缓存,并将数据放到一级缓存。 key:{} ,value:{}", key,value);
}
} }
return wrapper; return wrapper;
} }
......
...@@ -67,7 +67,6 @@ public class SearchContextBase implements ISearchContext{ ...@@ -67,7 +67,6 @@ public class SearchContextBase implements ISearchContext{
* 工作流流程标识 * 工作流流程标识
*/ */
public String processDefinitionKey; public String processDefinitionKey;
/** /**
* 获取工作流步骤标识 * 获取工作流步骤标识
*/ */
......
...@@ -38,7 +38,7 @@ public class SimpleFileService implements FileService { ...@@ -38,7 +38,7 @@ public class SimpleFileService implements FileService {
FileCopyUtils.copy(multipartFile.getInputStream(),Files.newOutputStream(file.toPath())); FileCopyUtils.copy(multipartFile.getInputStream(),Files.newOutputStream(file.toPath()));
item=new FileItem(fileid,fileName,fileid,fileName,(int)multipartFile.getSize(),extname); item=new FileItem(fileid,fileName,fileid,fileName,(int)multipartFile.getSize(),extname);
} catch (IOException e) { } catch (IOException e) {
throw new InternalServerErrorException("文件上传失败"); throw new InternalServerErrorException("文件上传失败,"+e);
} }
return item; return item;
} }
......
#缓存、数据源 #缓存、数据源
spring: spring:
cache: cache:
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册