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

ShineKOT 发布系统代码 [后台服务,演示应用]

上级 e70c76f3
......@@ -336,9 +336,10 @@ export default {
menuitem45: "数据打印",
menuitem67: "索引实体",
menuitem68: "继承实体",
menuitem70: "表格主状态",
menuitem71: "多表单",
menuitem70: "表格主状态",
menuitem148: "列表主状态",
menuitem183: "数据主状态",
menuitem92: "其他",
menuitem93: "示例实体02示例数据补充",
menuitem100: "订单示例数据补充",
......
......@@ -336,9 +336,10 @@ export default {
menuitem45: "数据打印",
menuitem67: "索引实体",
menuitem68: "继承实体",
menuitem70: "表格主状态",
menuitem71: "多表单",
menuitem70: "表格主状态",
menuitem148: "列表主状态",
menuitem183: "数据主状态",
menuitem92: "其他",
menuitem93: "示例实体02示例数据补充",
menuitem100: "订单示例数据补充",
......
......@@ -684,12 +684,14 @@ export default {
remove: "Remove",
},
},
usr4_dataview: {
majorstatedata_dataview: {
nodata:"",
uiactions: {
ibizbook_edit: "编辑",
ibizbook_delete: "删除",
},
},
majorstatedata_dataview: {
usr4_dataview: {
nodata:"",
uiactions: {
},
......@@ -1089,6 +1091,8 @@ export default {
tip: "Remove {0}",
},
},
usr6dataviewtoolbar_toolbar: {
},
usr2calendarviewcalendar_batchtoolbar_toolbar: {
deuiaction1: {
caption: "Save",
......@@ -1741,8 +1745,6 @@ export default {
},
haspanellistviewtoolbar_toolbar: {
},
usr6dataviewtoolbar_toolbar: {
},
tree_treeview: {
nodata:"",
nodes: {
......
......@@ -683,12 +683,14 @@ export default {
remove: "删除",
},
},
usr4_dataview: {
majorstatedata_dataview: {
nodata:"",
uiactions: {
ibizbook_edit: "编辑",
ibizbook_delete: "删除",
},
},
majorstatedata_dataview: {
usr4_dataview: {
nodata:"",
uiactions: {
},
......@@ -1088,6 +1090,8 @@ export default {
tip: "删除",
},
},
usr6dataviewtoolbar_toolbar: {
},
usr2calendarviewcalendar_batchtoolbar_toolbar: {
deuiaction1: {
caption: "保存",
......@@ -1740,8 +1744,6 @@ export default {
},
haspanellistviewtoolbar_toolbar: {
},
usr6dataviewtoolbar_toolbar: {
},
tree_treeview: {
nodata:"",
nodes: {
......
......@@ -3067,12 +3067,12 @@ mock.onGet('v7/main-menuappmenu').reply((config: any) => {
resourcetag: '',
},
{
id: 'c931e0ff705c4be3c4199457a0ac5b75',
name: 'menuitem70',
text: '表格主状态',
id: '9026dcd0d3fc539fbe02d12cd15968f8',
name: 'menuitem71',
text: '多表单',
type: 'MENUITEM',
counterid: '',
tooltip: '表格主状态',
tooltip: '多表单',
expanded: false,
separator: false,
hidden: false,
......@@ -3081,16 +3081,16 @@ mock.onGet('v7/main-menuappmenu').reply((config: any) => {
iconcls: '',
icon: '',
textcls: '',
appfunctag: 'AppFunc79',
appfunctag: 'Auto116',
resourcetag: '',
},
{
id: '9026dcd0d3fc539fbe02d12cd15968f8',
name: 'menuitem71',
text: '多表单',
id: 'c931e0ff705c4be3c4199457a0ac5b75',
name: 'menuitem70',
text: '表格主状态',
type: 'MENUITEM',
counterid: '',
tooltip: '多表单',
tooltip: '表格主状态',
expanded: false,
separator: false,
hidden: false,
......@@ -3099,7 +3099,7 @@ mock.onGet('v7/main-menuappmenu').reply((config: any) => {
iconcls: '',
icon: '',
textcls: '',
appfunctag: 'Auto116',
appfunctag: 'AppFunc79',
resourcetag: '',
},
{
......@@ -3119,6 +3119,24 @@ mock.onGet('v7/main-menuappmenu').reply((config: any) => {
textcls: '',
appfunctag: 'AppFunc80',
resourcetag: '',
},
{
id: '4A657CD0-5B9E-4701-A600-33E4A981F549',
name: 'menuitem183',
text: '数据主状态',
type: 'MENUITEM',
counterid: '',
tooltip: '数据主状态',
expanded: false,
separator: false,
hidden: false,
hidesidebar: false,
opendefault: false,
iconcls: '',
icon: '',
textcls: '',
appfunctag: 'AppFunc81',
resourcetag: '',
},
],
},
......
<template>
<div class='view-container dedataview ibizbookusr6-data-view'>
<app-studioaction :viewTitle="$t(model.srfCaption)" viewName="ibizbookusr6dataview"></app-studioaction>
<card class='view-card ' :dis-hover="true" :bordered="false">
<div slot='title' class="header-container">
<span class='caption-info'>{{$t(model.srfCaption)}}</span>
</div>
<div class='view-top-messages'>
</div>
<div class='content-container'>
<div style="margin-bottom:6px;">
<i-input v-show='!this.isExpandSearchForm ' v-model='query' search @on-search='onSearch' placeholder="图书名称" class='pull-left' style='max-width: 400px;margin-top:6px;padding-left: 24px;' />
<div class='pull-right'>
<div class='toolbar-container'>
</div>
</div>
</div>
<view_searchform
:viewState="viewState"
:viewparams="viewparams"
:context="context"
:showBusyIndicator="true"
v-show="isExpandSearchForm"
loaddraftAction="FilterGetDraft"
loadAction="FilterGet"
name="searchform"
ref='searchform'
@save="searchform_save($event)"
@search="searchform_search($event)"
@load="searchform_load($event)"
@closeview="closeView($event)">
</view_searchform>
<div class='view-body-messages'>
</div>
<view_dataview
:viewState="viewState"
:viewparams="viewparams"
:context="context"
:isSingleSelect="isSingleSelect"
createAction="Create"
removeAction="Remove"
updateAction="Update"
fetchAction="FetchDefault"
:showBusyIndicator="true"
:newdata="newdata"
:opendata="opendata"
name="dataview"
ref='dataview'
@selectionchange="dataview_selectionchange($event)"
@beforeload="dataview_beforeload($event)"
@rowdblclick="dataview_rowdblclick($event)"
@remove="dataview_remove($event)"
@load="dataview_load($event)"
@closeview="closeView($event)">
</view_dataview>
</div>
<div class='view-bottom-messages'>
</div>
</card>
</div>
</template>
<script lang='tsx'>
import { Vue, Component, Prop, Provide, Emit, Watch,Inject } from 'vue-property-decorator';
import { UIActionTool,Util } from '@/utils';
import NavDataService from '@/service/app/navdata-service';
import { Subject,Subscription } from 'rxjs';
import IBIZBOOKService from '@/service/ibizbook/ibizbook-service';
import IBIZBOOKAuthService from '@/authservice/ibizbook/ibizbook-auth-service';
import DataViewEngine from '@engine/view/data-view-engine';
import IBIZBOOKUIService from '@/uiservice/ibizbook/ibizbook-ui-service';
import CodeListService from "@/codelist/codelist-service";
@Component({
components: {
},
})
export default class IBIZBOOKUsr6DataViewBase extends Vue {
/**
* 实体服务对象
*
* @type {IBIZBOOKService}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public appEntityService: IBIZBOOKService = new IBIZBOOKService;
/**
* 实体UI服务对象
*
* @type IBIZBOOKUIService
* @memberof IBIZBOOKUsr6DataViewBase
*/
public appUIService: IBIZBOOKUIService = new IBIZBOOKUIService(this.$store);
/**
* 数据变化
*
* @param {*} val
* @returns {*}
* @memberof IBIZBOOKUsr6DataViewBase
*/
@Emit()
public viewDatasChange(val: any):any {
return val;
}
/**
* 传入视图上下文
*
* @type {string}
* @memberof IBIZBOOKUsr6DataViewBase
*/
@Prop() public viewdata!: string;
/**
* 传入视图参数
*
* @type {string}
* @memberof IBIZBOOKUsr6DataViewBase
*/
@Prop() public viewparam!: string;
/**
* 视图默认使用
*
* @type {boolean}
* @memberof IBIZBOOKUsr6DataViewBase
*/
@Prop({ default: true }) public viewDefaultUsage!: boolean;
/**
* 视图默认使用
*
* @type {string}
* @memberof IBIZBOOKUsr6DataViewBase
*/
@Inject({from:'navModel',default: 'tab'})
public navModel!:string;
/**
* 视图标识
*
* @type {string}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public viewtag: string = 'c0129c921be7d85a22907979d8120c64';
/**
* 自定义视图导航上下文集合
*
* @type {*}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public customViewNavContexts:any ={
};
/**
* 自定义视图导航参数集合
*
* @type {*}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public customViewParams:any ={
};
/**
* 视图模型数据
*
* @type {*}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public model: any = {
srfCaption: 'entities.ibizbook.views.usr6dataview.caption',
srfTitle: 'entities.ibizbook.views.usr6dataview.title',
srfSubTitle: 'entities.ibizbook.views.usr6dataview.subtitle',
dataInfo: ''
}
/**
* 视图参数变化
*
* @param {*} newVal
* @param {*} oldVal
* @memberof IBIZBOOKUsr6DataViewBase
*/
@Watch('viewparam',{immediate: true, deep: true})
onParamData(newVal: any, oldVal: any) {
if(newVal){
this.viewparams = {};
if(typeof newVal == 'string') {
Object.assign(this.viewparams, JSON.parse(this.viewparam));
}else{
this.viewparams = Util.deepCopy(this.viewparam);
}
}
}
/**
* 处理应用上下文变化
*
* @param {*} newVal
* @param {*} oldVal
* @memberof IBIZBOOKUsr6DataViewBase
*/
@Watch('viewdata')
onViewData(newVal: any, oldVal: any) {
const _this: any = this;
if (!Object.is(newVal, oldVal) && _this.engine) {
this.$nextTick(()=>{
_this.parseViewParam();
_this.engine.load();
});
} else if(!Object.is(newVal, oldVal) && _this.refresh && _this.refresh instanceof Function) {
_this.refresh();
}
}
/**
* 容器模型
*
* @type {*}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public containerModel: any = {
view_toolbar: { name: 'toolbar', type: 'TOOLBAR' },
view_searchform: { name: 'searchform', type: 'SEARCHFORM' },
view_dataview: { name: 'dataview', type: 'DATAVIEW' },
};
/**
* 视图刷新
*
* @param {*} args
* @memberof IBIZBOOKUsr6DataViewBase
*/
public refresh(args?: any): void {
const refs: any = this.$refs;
if (refs && refs.dataview) {
refs.dataview.refresh();
}
}
/**
* 计数器刷新
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public counterRefresh(){
const _this:any =this;
if(_this.counterServiceArray && _this.counterServiceArray.length >0){
_this.counterServiceArray.forEach((item:any) =>{
if(item.refreshData && item.refreshData instanceof Function){
item.refreshData();
}
})
}
}
/**
* 视图状态订阅对象
*
* @public
* @type {Subject<{action: string, data: any}>}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public viewState: Subject<ViewState> = new Subject();
/**
* 工具栏模型
*
* @type {*}
* @memberof IBIZBOOKUsr6DataView
*/
public toolBarModels: any = {
};
/**
* 视图引擎
*
* @public
* @type {Engine}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public engine: DataViewEngine = new DataViewEngine();
/**
* 引擎初始化
*
* @public
* @memberof IBIZBOOKUsr6DataViewBase
*/
public engineInit(): void {
this.engine.init({
view: this,
opendata: (args: any[],fullargs?:any[],params?: any, $event?: any, xData?: any) => {
this.opendata(args,fullargs, params, $event, xData);
},
newdata: (args: any[],fullargs?:any[],params?: any, $event?: any, xData?: any) => {
this.newdata(args,fullargs, params, $event, xData);
},
searchform: this.$refs.searchform,
dataview: this.$refs.dataview,
keyPSDEField: 'ibizbook',
majorPSDEField: 'ibizbookname',
isLoadDefault: true,
});
}
/**
* 应用导航服务
*
* @type {*}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public navDataService = NavDataService.getInstance(this.$store);
/**
* 导航服务事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof IBIZBOOKUsr6DataViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public portletStateEvent: Subscription | undefined;
/**
* 应用上下文
*
* @type {*}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public context:any = {};
/**
* 视图参数
*
* @type {*}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public viewparams:any = {};
/**
* 视图缓存数据
*
* @type {*}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public viewCacheData:any;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public counterServiceArray:Array<any> = [];
/**
* 解析视图参数
*
* @public
* @memberof IBIZBOOKUsr6DataViewBase
*/
public parseViewParam(inputvalue:any = null): void {
for(let key in this.context){
delete this.context[key];
}
if(this.$store.getters.getAppData() && this.$store.getters.getAppData().context){
Object.assign(this.context,this.$store.getters.getAppData().context);
}
if (!this.viewDefaultUsage && this.viewdata && !Object.is(this.viewdata, '')) {
if(typeof this.viewdata == 'string') {
Object.assign(this.context, JSON.parse(this.viewdata));
}
if(this.context && this.context.srfparentdename){
Object.assign(this.viewparams,{srfparentdename:this.context.srfparentdename});
}
if(this.context && this.context.srfparentkey){
Object.assign(this.viewparams,{srfparentkey:this.context.srfparentkey});
}
this.handleCustomViewData();
return;
}
const path = (this.$route.matched[this.$route.matched.length - 1]).path;
const keys: Array<any> = [];
const curReg = this.$pathToRegExp.pathToRegexp(path, keys);
const matchArray = curReg.exec(this.$route.path);
let tempValue: Object = {};
keys.forEach((item: any, index: number) => {
Object.defineProperty(tempValue, item.name, {
enumerable: true,
value: matchArray[index + 1]
});
});
this.$viewTool.formatRouteParams(tempValue,this.$route,this.context,this.viewparams);
if(inputvalue){
Object.assign(this.context,{'ibizbook':inputvalue});
}
//初始化视图唯一标识
Object.assign(this.context,{srfsessionid:this.$util.createUUID()});
this.handleCustomViewData();
//初始化导航数据
this.initNavDataWithRoute();
}
/**
* 处理自定义视图数据
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public handleCustomViewData(){
if(Object.keys(this.customViewNavContexts).length > 0){
Object.keys(this.customViewNavContexts).forEach((item:any) =>{
let tempContext:any = {};
let curNavContext:any = this.customViewNavContexts[item];
this.handleCustomDataLogic(curNavContext,tempContext,item);
Object.assign(this.context,tempContext);
})
}
if(Object.keys(this.customViewParams).length > 0){
Object.keys(this.customViewParams).forEach((item:any) =>{
let tempParam:any = {};
let curNavParam:any = this.customViewParams[item];
this.handleCustomDataLogic(curNavParam,tempParam,item);
Object.assign(this.viewparams,tempParam);
})
}
}
/**
* 处理自定义视图数据逻辑
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public handleCustomDataLogic(curNavData:any,tempData:any,item:string){
// 直接值直接赋值
if(curNavData.isRawValue){
if(Object.is(curNavData.value,"null") || Object.is(curNavData.value,"")){
Object.defineProperty(tempData, item.toLowerCase(), {
value: null,
writable : true,
enumerable : true,
configurable : true
});
}else{
Object.defineProperty(tempData, item.toLowerCase(), {
value: curNavData.value,
writable : true,
enumerable : true,
configurable : true
});
}
}else{
// 先从导航上下文取数,没有再从导航参数(URL)取数,如果导航上下文和导航参数都没有则为null
if(this.context[(curNavData.value).toLowerCase()] != null){
Object.defineProperty(tempData, item.toLowerCase(), {
value: this.context[(curNavData.value).toLowerCase()],
writable : true,
enumerable : true,
configurable : true
});
}else{
if(this.viewparams[(curNavData.value).toLowerCase()] != null){
Object.defineProperty(tempData, item.toLowerCase(), {
value: this.viewparams[(curNavData.value).toLowerCase()],
writable : true,
enumerable : true,
configurable : true
});
}else{
Object.defineProperty(tempData, item.toLowerCase(), {
value: null,
writable : true,
enumerable : true,
configurable : true
});
}
}
}
}
/**
* 初始化导航数据(路由模式)
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public initNavDataWithRoute(data:any = null, isNew:boolean = false, isAlways:boolean = false){
if( isAlways || (this.viewDefaultUsage && Object.is(this.navModel,"route")) ){
this.navDataService.addNavData({id:'ibizbookusr6-data-view',tag:this.viewtag,srfkey:isNew ? null : this.context.ibizbook,title:this.$t(this.model.srfCaption),data:data,context:this.context,viewparams:this.viewparams,path:this.$route.fullPath});
}
}
/**
* 初始化导航数据(分页模式)
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public initNavDataWithTab(data:any = null,isOnlyAdd:boolean = true, isAlways:boolean = false){
if( isAlways || (this.viewDefaultUsage && !Object.is(this.navModel,"route")) ){
this.navDataService.addNavDataByOnly({id:'ibizbookusr6-data-view',tag:this.viewtag,srfkey:this.context.ibizbook,title:this.$t(this.model.srfCaption),data:data,context:this.context,viewparams:this.viewparams,path:this.$route.fullPath},isOnlyAdd);
}
}
/**
* Vue声明周期
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public created() {
this.afterCreated();
}
/**
* 执行created后的逻辑
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public afterCreated(){
let _this:any = this;
const secondtag = _this.$util.createUUID();
_this.$store.commit('viewaction/createdView', { viewtag: _this.viewtag, secondtag: secondtag });
_this.viewtag = secondtag;
_this.parseViewParam();
_this.serviceStateEvent = _this.navDataService.serviceState.subscribe(({ action,name, data }:{ action:string,name:any,data:any }) => {
if(!Object.is(name,'ibizbookusr6-data-view')){
return;
}
if (Object.is(action, 'viewrefresh')) {
_this.$nextTick(()=>{
_this.parseViewParam(data);
if(_this.engine){
_this.engine.load();
}
});
}
});
if(_this.portletState){
_this.portletStateEvent = _this.portletState.subscribe((res:any) =>{
if(!Object.is(res.name,'IBIZBOOKUsr6DataView')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
}
/**
* 销毁之前
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public beforeDestroy() {
this.$store.commit('viewaction/removeView', this.viewtag);
}
/**
* Vue声明周期(组件初始化完毕)
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public mounted() {
this.afterMounted();
}
/**
* 执行mounted后的逻辑
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public afterMounted(){
const _this: any = this;
_this.engineInit();
if (_this.loadModel && _this.loadModel instanceof Function) {
_this.loadModel();
}
}
/**
* searchform 部件 save 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZBOOKUsr6DataViewBase
*/
public searchform_save($event: any, $event2?: any) {
this.engine.onCtrlEvent('searchform', 'save', $event);
}
/**
* searchform 部件 search 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZBOOKUsr6DataViewBase
*/
public searchform_search($event: any, $event2?: any) {
this.engine.onCtrlEvent('searchform', 'search', $event);
}
/**
* searchform 部件 load 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZBOOKUsr6DataViewBase
*/
public searchform_load($event: any, $event2?: any) {
this.engine.onCtrlEvent('searchform', 'load', $event);
}
/**
* dataview 部件 selectionchange 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZBOOKUsr6DataViewBase
*/
public dataview_selectionchange($event: any, $event2?: any) {
this.engine.onCtrlEvent('dataview', 'selectionchange', $event);
}
/**
* dataview 部件 beforeload 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZBOOKUsr6DataViewBase
*/
public dataview_beforeload($event: any, $event2?: any) {
this.engine.onCtrlEvent('dataview', 'beforeload', $event);
}
/**
* dataview 部件 rowdblclick 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZBOOKUsr6DataViewBase
*/
public dataview_rowdblclick($event: any, $event2?: any) {
this.engine.onCtrlEvent('dataview', 'rowdblclick', $event);
}
/**
* dataview 部件 remove 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZBOOKUsr6DataViewBase
*/
public dataview_remove($event: any, $event2?: any) {
this.engine.onCtrlEvent('dataview', 'remove', $event);
}
/**
* dataview 部件 load 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZBOOKUsr6DataViewBase
*/
public dataview_load($event: any, $event2?: any) {
this.engine.onCtrlEvent('dataview', 'load', $event);
}
/**
* 打开新建数据视图
*
* @param {any[]} args
* @param {*} [params]
* @param {*} [fullargs]
* @param {*} [$event]
* @param {*} [xData]
* @memberof IBIZBOOKUsr6DataView
*/
public newdata(args: any[],fullargs?:any[], params?: any, $event?: any, xData?: any) {
let localContext:any = null;
let localViewParam:any =null;
const data: any = {};
if(args[0].srfsourcekey){
data.srfsourcekey = args[0].srfsourcekey;
}
let tempContext = JSON.parse(JSON.stringify(this.context));
delete tempContext.ibizbook;
if(args.length >0){
Object.assign(tempContext,args[0]);
}
const deResParameters: any[] = [];
const parameters: any[] = [
{ pathName: 'ibizbooks', parameterName: 'ibizbook' },
{ pathName: 'editview', parameterName: 'editview' },
];
const _this: any = this;
const openIndexViewTab = (data: any) => {
const _data: any = { w: (new Date().getTime()) };
Object.assign(_data, data);
const routePath = this.$viewTool.buildUpRoutePath(this.$route, tempContext, deResParameters, parameters, args, _data);
this.$router.push(routePath);
}
openIndexViewTab(data);
}
/**
* 打开编辑数据视图
*
* @param {any[]} args
* @param {*} [params]
* @param {*} [fullargs]
* @param {*} [$event]
* @param {*} [xData]
* @memberof IBIZBOOKUsr6DataView
*/
public opendata(args: any[],fullargs?:any,params?: any, $event?: any, xData?: any) {
if(!this.viewDefaultUsage){
if(Object.is(this.navModel,"route")){
this.initNavDataWithRoute(this.viewCacheData, false, true);
}else{
this.initNavDataWithTab(this.viewCacheData, false, true);
}
}
let localContext:any = null;
let localViewParam:any =null;
const data: any = {};
let tempContext = JSON.parse(JSON.stringify(this.context));
if(args.length >0){
Object.assign(tempContext,args[0]);
}
const deResParameters: any[] = [];
const parameters: any[] = [
{ pathName: 'ibizbooks', parameterName: 'ibizbook' },
{ pathName: 'editview', parameterName: 'editview' },
];
const _this: any = this;
if(fullargs && fullargs.copymode){
Object.assign(data,{copymode:true});
}
const openIndexViewTab = (data: any) => {
const routePath = this.$viewTool.buildUpRoutePath(this.$route, tempContext, deResParameters, parameters, args, data);
this.$router.push(routePath);
}
openIndexViewTab(data);
}
/**
* 关闭视图
*
* @param {any[]} args
* @memberof IBIZBOOKUsr6DataViewBase
*/
public closeView(args: any[]): void {
let _view: any = this;
if (_view.viewdata) {
_view.$emit('viewdataschange', [args]);
_view.$emit('close', [args]);
} else if (_view.$tabPageExp) {
_view.$tabPageExp.onClose(_view.$route.fullPath);
}
}
/**
* 销毁视图回调
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public destroyed(){
this.afterDestroyed();
}
/**
* 执行destroyed后的逻辑
*
* @memberof IBIZBOOKUsr6DataViewBase
*/
public afterDestroyed(){
if(this.viewDefaultUsage){
let localStoreLength = Object.keys(localStorage);
if(localStoreLength.length > 0){
localStoreLength.forEach((item:string) =>{
if(item.startsWith(this.context.srfsessionid)){
localStorage.removeItem(item);
}
})
}
if(Object.is(this.navModel,"tab")){
this.navDataService.removeNavDataByTag(this.viewtag);
}
if (this.serviceStateEvent) {
this.serviceStateEvent.unsubscribe();
}
}
// 销毁计数器定时器
if(this.counterServiceArray && this.counterServiceArray.length >0){
this.counterServiceArray.forEach((item:any) =>{
if(item.destroyCounter && item.destroyCounter instanceof Function){
item.destroyCounter();
}
})
}
if(this.portletStateEvent){
this.portletStateEvent.unsubscribe();
}
}
/**
* 是否单选
*
* @type {boolean}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public isSingleSelect: boolean = false;
/**
* 视图唯一标识
*
* @type {string}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public viewUID: string = 'sample-ibizbookusr6-data-view';
/**
* 搜索值
*
* @type {string}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public query: string = '';
/**
* 是否展开搜索表单
*
* @type {boolean}
* @memberof IBIZBOOKUsr6DataViewBase
*/
public isExpandSearchForm: boolean = false;
/**
* 快速搜索
*
* @param {*} $event
* @memberof IBIZBOOKUsr6DataViewBase
*/
public onSearch($event: any): void {
const refs: any = this.$refs;
if (refs.kanban) {
refs.kanban.refresh({});
}
}
}
</script>
<style lang='less'>
@import './ibizbookusr6-data-view.less';
</style>
\ No newline at end of file
.ibizbookusr6-data-view{
position: relative;
}
.toolbar-container {
button {
margin: 6px 0px 4px 4px;
.caption {
margin-left: 4px;
}
}
.seperator {
color: #dcdee2;
margin: 0 0px 0 4px;
}
}
// this is less
.ibizbookusr6-data-view{
display: block;
}
\ No newline at end of file
<script lang='tsx'>
import { Component } from 'vue-property-decorator';
import IBIZBOOKUsr6DataViewBase from './ibizbookusr6-data-view-base.vue';
import view_searchform from '@widgets/ibizbook/default-searchform/default-searchform.vue';
import view_dataview from '@widgets/ibizbook/major-state-data-dataview/major-state-data-dataview.vue';
@Component({
components: {
view_searchform,
view_dataview,
},
beforeRouteEnter: (to: any, from: any, next: any) => {
next((vm: any) => {
if(!Object.is(vm.navModel,"route")){
vm.initNavDataWithTab(vm.viewCacheData);
}
vm.$store.commit('addCurPageViewtag', { fullPath: to.fullPath, viewtag: vm.viewtag });
});
},
})
export default class IBIZBOOKUsr6DataView extends IBIZBOOKUsr6DataViewBase {
}
</script>
\ No newline at end of file
......@@ -173,6 +173,7 @@ export const PageComponents = {
Vue.component('ibizorder-detail-f6-edit-view', () => import('@pages/sample/ibizorder-detail-f6-edit-view/ibizorder-detail-f6-edit-view.vue'));
Vue.component('ibizbookusr2-medit-view9', () => import('@pages/sample/ibizbookusr2-medit-view9/ibizbookusr2-medit-view9.vue'));
Vue.component('ibizsample0001-usr3-edit-view', () => import('@pages/sample/ibizsample0001-usr3-edit-view/ibizsample0001-usr3-edit-view.vue'));
Vue.component('ibizbookusr6-data-view', () => import('@pages/sample/ibizbookusr6-data-view/ibizbookusr6-data-view.vue'));
Vue.component('ibizsample0003-sf2-edit-view', () => import('@pages/sample/ibizsample0003-sf2-edit-view/ibizsample0003-sf2-edit-view.vue'));
Vue.component('ibizbookinternal-func-grid-view', () => import('@pages/sample/ibizbookinternal-func-grid-view/ibizbookinternal-func-grid-view.vue'));
Vue.component('ibizorder-odsp-d10-wfgrid-view', () => import('@pages/sample/ibizorder-odsp-d10-wfgrid-view/ibizorder-odsp-d10-wfgrid-view.vue'));
......
......@@ -2711,6 +2711,20 @@ const router = new Router({
},
component: () => import('@pages/sample/ibizsample0001-usr3-edit-view/ibizsample0001-usr3-edit-view.vue'),
},
{
path: 'ibizbooks/:ibizbook?/usr6dataview/:usr6dataview?',
meta: {
caption: 'entities.ibizbook.views.usr6dataview.caption',
info:'',
parameters: [
{ pathName: 'index', parameterName: 'index' },
{ pathName: 'ibizbooks', parameterName: 'ibizbook' },
{ pathName: 'usr6dataview', parameterName: 'usr6dataview' },
],
requireAuth: true,
},
component: () => import('@pages/sample/ibizbookusr6-data-view/ibizbookusr6-data-view.vue'),
},
{
path: 'ibizsample0003s/:ibizsample0003?/sf2editview/:sf2editview?',
meta: {
......@@ -5106,6 +5120,19 @@ const router = new Router({
},
component: () => import('@pages/sample/ibizbookusr6-grid-view/ibizbookusr6-grid-view.vue'),
},
{
path: '/ibizbooks/:ibizbook?/usr6dataview/:usr6dataview?',
meta: {
caption: 'entities.ibizbook.views.usr6dataview.caption',
info:'',
parameters: [
{ pathName: 'ibizbooks', parameterName: 'ibizbook' },
{ pathName: 'usr6dataview', parameterName: 'usr6dataview' },
],
requireAuth: true,
},
component: () => import('@pages/sample/ibizbookusr6-data-view/ibizbookusr6-data-view.vue'),
},
{
path: '/ibizorders/:ibizorder?/ibizorderdetails/:ibizorderdetail?/editview/:editview?',
meta: {
......
......@@ -306,6 +306,7 @@ export const viewstate: any = {
'06E447F9-1AF8-464F-8F47-39CFC64B9A21',
'3bbf72a3e5b59fed0dee362a9b1384a8',
'f00438ae4a3c6969dfccd271c2be65da',
'c0129c921be7d85a22907979d8120c64',
'f73da4cb47a88d3fe5b92716e0137741',
'fdb8ed39fbfea00f65416b9aaebd64e7',
'd99f9680b535dcf3ad0d0f853a8b89d9',
......@@ -1578,6 +1579,17 @@ export const viewstate: any = {
'efbe72fe207c5bb7ada28b278a9ea920',
],
},
{
viewtag: 'c0129c921be7d85a22907979d8120c64',
viewmodule: 'Sample',
viewname: 'IBIZBOOKUsr6DataView',
viewaction: '',
viewdatachange: false,
refviews: [
'b3429ecc4d89a02bc5f5279f1bd7f620',
'0d9d3edf2d060a859fa7f2e206556730',
],
},
{
viewtag: 'c153da73d5d5b62475f4213de51a25e0',
viewmodule: 'Sample',
......
......@@ -791,6 +791,9 @@ export default class MainMenuBase extends Vue implements ControlInterface {
case 'AppFunc54':
this.clickAppFunc54(item);
return;
case 'AppFunc81':
this.clickAppFunc81(item);
return;
case 'AppFunc80':
this.clickAppFunc80(item);
return;
......@@ -3003,6 +3006,29 @@ export default class MainMenuBase extends Vue implements ControlInterface {
})
}
/**
* 数据视图主状态
*
* @param {*} [item={}]
* @memberof MainMenu
*/
public clickAppFunc81(item: any = {}) {
const viewparam: any = {};
Object.assign(viewparam, {});
const deResParameters: any[] = [];
const parameters: any[] = [
{ pathName: 'ibizbooks', parameterName: 'ibizbook' },
{ pathName: 'usr6dataview', parameterName: 'usr6dataview' },
];
const path: string = this.$viewTool.buildUpRoutePath(this.$route, {}, deResParameters, parameters, [], viewparam);
if(Object.is(this.$route.fullPath,path)){
return;
}
this.$nextTick(function(){
this.$router.push(path);
})
}
/**
* 列表主状态
*
......
......@@ -3237,12 +3237,12 @@ export default class MainMenuModel {
authtag:'Web-MainMenu-menuitem68',
},
{
id: 'c931e0ff705c4be3c4199457a0ac5b75',
name: 'menuitem70',
text: '表格主状态',
id: '9026dcd0d3fc539fbe02d12cd15968f8',
name: 'menuitem71',
text: '多表单',
type: 'MENUITEM',
counterid: '',
tooltip: '表格主状态',
tooltip: '多表单',
expanded: false,
separator: false,
hidden: false,
......@@ -3251,17 +3251,17 @@ export default class MainMenuModel {
iconcls: '',
icon: '',
textcls: '',
appfunctag: 'AppFunc79',
appfunctag: 'Auto116',
resourcetag: '',
authtag:'Web-MainMenu-menuitem70',
authtag:'Web-MainMenu-menuitem71',
},
{
id: '9026dcd0d3fc539fbe02d12cd15968f8',
name: 'menuitem71',
text: '多表单',
id: 'c931e0ff705c4be3c4199457a0ac5b75',
name: 'menuitem70',
text: '表格主状态',
type: 'MENUITEM',
counterid: '',
tooltip: '多表单',
tooltip: '表格主状态',
expanded: false,
separator: false,
hidden: false,
......@@ -3270,9 +3270,9 @@ export default class MainMenuModel {
iconcls: '',
icon: '',
textcls: '',
appfunctag: 'Auto116',
appfunctag: 'AppFunc79',
resourcetag: '',
authtag:'Web-MainMenu-menuitem71',
authtag:'Web-MainMenu-menuitem70',
},
{
id: '49662DB0-CAB1-4131-A322-EF4EAA92F332',
......@@ -3292,6 +3292,25 @@ export default class MainMenuModel {
appfunctag: 'AppFunc80',
resourcetag: '',
authtag:'Web-MainMenu-menuitem148',
},
{
id: '4A657CD0-5B9E-4701-A600-33E4A981F549',
name: 'menuitem183',
text: '数据主状态',
type: 'MENUITEM',
counterid: '',
tooltip: '数据主状态',
expanded: false,
separator: false,
hidden: false,
hidesidebar: false,
opendefault: false,
iconcls: '',
icon: '',
textcls: '',
appfunctag: 'AppFunc81',
resourcetag: '',
authtag:'Web-MainMenu-menuitem183',
},
],
},
......
<template>
<div class="app-data-view">
<app-sort-bar
:sortModel="sortModel"
:sortField="sortField"
:sortDir="sortDir"
entityName="ibizbook"
@clickSort="(val) => {sortClick(val);}">
</app-sort-bar>
<row class="data-view-container" v-if="items.length > 0" :gutter="20" type="flex" justify="start" style="margin:0px;">
<a v-for="(item,index) in items" :key="index" :href = "item.starturl">
<i-col style="min-height: 170px;margin-bottom: 10px;">
<el-card shadow="always" :class="[ item.isselected === true ? 'isselected' : false, 'single-card-data' ]" @click.native="handleClick(item)" @dblclick.native="handleDblClick(item)">
<div class="data-view-item">
<img v-if="item.srficonpath" :src="item.srficonpath" class="single-card-img" />
<img v-else src="/assets/img/noimage.png" class="single-card-img" />
<div class="single-card-default">
<Tooltip :content="item.srfmajortext">
{{item.srfmajortext}}
</Tooltip>
</div>
</div>
<div class="data-view-item-action">
<template v-for="(action,index) in Object.keys(actionModel)">
<button type="info" :key="index" @click="uiAction(item, action, $event)">
<i :class="actionModel[action].icon" style="margin-right:2px;"></i>
<span>{{actionModel[action].caption}}</span>
</button>
</template>
</div>
</el-card>
</i-col>
</a>
</row>
<div v-else class="app-data-empty">
{{ $t('entities.ibizbook.majorstatedata_dataview.nodata') }}
</div>
<el-backtop target=".content-container .app-data-view"></el-backtop>
</div>
</template>
<script lang='tsx'>
import { Vue, Component, Prop, Provide, Emit, Watch, Model,Inject } from 'vue-property-decorator';
import { CreateElement } from 'vue';
import { Subject, Subscription } from 'rxjs';
import { ControlInterface } from '@/interface/control';
import { UIActionTool,Util,ViewTool } from '@/utils';
import NavDataService from '@/service/app/navdata-service';
import AppCenterService from "@service/app/app-center-service";
import IBIZBOOKService from '@/service/ibizbook/ibizbook-service';
import MajorStateDataService from './major-state-data-dataview-service';
import IBIZBOOKUIService from '@/uiservice/ibizbook/ibizbook-ui-service';
import CodeListService from "@/codelist/codelist-service";
@Component({
components: {
}
})
export default class MajorStateDataBase extends Vue implements ControlInterface {
/**
* 名称
*
* @type {string}
* @memberof MajorStateDataBase
*/
@Prop() public name?: string;
/**
* 视图通讯对象
*
* @type {Subject<ViewState>}
* @memberof MajorStateDataBase
*/
@Prop() public viewState!: Subject<ViewState>;
/**
* 应用上下文
*
* @type {*}
* @memberof MajorStateDataBase
*/
@Prop() public context!: any;
/**
* 视图参数
*
* @type {*}
* @memberof MajorStateDataBase
*/
@Prop() public viewparams!: any;
/**
* 视图状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof MajorStateDataBase
*/
public viewStateEvent: Subscription | undefined;
/**
* 获取部件类型
*
* @returns {string}
* @memberof MajorStateDataBase
*/
public getControlType(): string {
return 'DATAVIEW'
}
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof MajorStateDataBase
*/
public counterServiceArray:Array<any> = [];
/**
* 建构部件服务对象
*
* @type {MajorStateDataService}
* @memberof MajorStateDataBase
*/
public service: MajorStateDataService = new MajorStateDataService({ $store: this.$store });
/**
* 实体服务对象
*
* @type {IBIZBOOKService}
* @memberof MajorStateDataBase
*/
public appEntityService: IBIZBOOKService = new IBIZBOOKService({ $store: this.$store });
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public dataview_item_u786fa64_click(params: any = {}, tag?: any, $event?: any) {
// 取数
let datas: any[] = [];
let xData: any = null;
// _this 指向容器对象
const _this: any = this;
let paramJO:any = {};
let contextJO:any = {};
xData = this;
if (_this.getDatas && _this.getDatas instanceof Function) {
datas = [..._this.getDatas()];
}
if(params){
datas = [params];
}
// 界面行为
const curUIService:IBIZBOOKUIService = new IBIZBOOKUIService();
curUIService.IBIZBOOK_Edit(datas,contextJO, paramJO, $event, xData,this,"IBIZBOOK");
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public dataview_item_u0a83fc3_click(params: any = {}, tag?: any, $event?: any) {
// 取数
let datas: any[] = [];
let xData: any = null;
// _this 指向容器对象
const _this: any = this;
let paramJO:any = {};
let contextJO:any = {};
xData = this;
if (_this.getDatas && _this.getDatas instanceof Function) {
datas = [..._this.getDatas()];
}
if(params){
datas = [params];
}
// 界面行为
const curUIService:IBIZBOOKUIService = new IBIZBOOKUIService();
curUIService.IBIZBOOK_Delete(datas,contextJO, paramJO, $event, xData,this,"IBIZBOOK");
}
/**
* 转化数据
*
* @param {any} args
* @memberof MajorStateDataBase
*/
public transformData(args: any) {
let _this: any = this;
if(_this.service && _this.service.handleRequestData instanceof Function && _this.service.handleRequestData('transform',_this.context,args)){
return _this.service.handleRequestData('transform',_this.context,args)['data'];
}
}
/**
* 关闭视图
*
* @param {any} args
* @memberof MajorStateDataBase
*/
public closeView(args: any): void {
let _this: any = this;
_this.$emit('closeview', [args]);
}
/**
* 计数器刷新
*
* @memberof MajorStateDataBase
*/
public counterRefresh(){
const _this:any =this;
if(_this.counterServiceArray && _this.counterServiceArray.length >0){
_this.counterServiceArray.forEach((item:any) =>{
if(item.refreshData && item.refreshData instanceof Function){
item.refreshData();
}
})
}
}
/**
* 代码表服务对象
*
* @type {CodeListService}
* @memberof MajorStateDataBase
*/
public codeListService:CodeListService = new CodeListService({ $store: this.$store });
/**
* 获取多项数据
*
* @returns {any[]}
* @memberof MajorStateDataBase
*/
public getDatas(): any[] {
return this.selections;
}
/**
* 获取单项树
*
* @returns {*}
* @memberof MajorStateDataBase
*/
public getData(): any {
return null;
}
/**
* 是否默认选中第一条数据
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
@Prop({ default: false }) public isSelectFirstDefault!: boolean;
/**
* 显示处理提示
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
@Prop({ default: true }) public showBusyIndicator?: boolean;
/**
* 部件行为--create
*
* @type {string}
* @memberof MajorStateDataBase
*/
@Prop() public createAction!: string;
/**
* 部件行为--remove
*
* @type {string}
* @memberof MajorStateDataBase
*/
@Prop() public removeAction!: string;
/**
* 部件行为--update
*
* @type {string}
* @memberof MajorStateDataBase
*/
@Prop() public updateAction!: string;
/**
* 部件行为--fetch
*
* @type {string}
* @memberof MajorStateDataBase
*/
@Prop() public fetchAction!: string;
/**
* 打开新建数据视图
*
* @type {any}
* @memberof MajorStateDataBase
*/
@Prop() public newdata: any;
/**
* 打开编辑数据视图
*
* @type {any}
* @memberof MajorStateDataBase
*/
@Prop() public opendata: any;
/**
* this引用
*
* @type {number}
* @memberof MajorStateDataBase
*/
public thisRef: any = this;
/**
* 拖拽元素对象
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
public dragEle:any;
/**
* 拖拽后位置left
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
public leftP:any;
/**
* 拖拽后位置top
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
public topP:any;
/**
* 拖拽标识
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
public dragflag:boolean=false;
/**
* 为拖拽不是点击
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
public moveflag:boolean = false;
/**
* 是否单选
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
@Prop() public isSingleSelect?: boolean;
/**
* 数据
*
* @type {any[]}
* @memberof MajorStateDataBase
*/
public items: any[] = [];
/**
* 操作栏模型数据
*
* @type {*}
* @memberof MajorStateDataBase
*/
public actionModel:any ={
"Edit":{name:"Edit",icon:"fa fa-edit",caption:"编辑",disabled: false, visabled: true,noprivdisplaymode:1,dataaccaction: "EDIT", actiontarget: "SINGLEKEY"},
"Delete":{name:"Delete",icon:"fa fa-remove",caption:"删除",disabled: false, visabled: true,noprivdisplaymode:1,dataaccaction: "DELETE", actiontarget: "SINGLEKEY"},
};
/**
* 是否支持分页
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
public isEnablePagingBar: boolean = true;;
/**
* 总条数
*
* @type {number}
* @memberof MajorStateDataBase
*/
public totalRecord: number = 0;
/**
* 加载的数据是否附加在items之后
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
public isAddBehind:boolean = false;
/**
* 选中数组
* @type {Array<any>}
* @memberof MajorStateDataBase
*/
public selections: Array<any> = [];
/**
* 当前页
*
* @type {number}
* @memberof MajorStateDataBase
*/
public curPage: number = 1;
/**
* 分页条数
*
* @type {number}
* @memberof MajorStateDataBase
*/
public limit: number = 20;
/**
* 排序方向
*
* @type {string}
* @memberof MajorStateDataBase
*/
public sortDir:string = '';
/**
* 排序字段
*
* @type {string}
* @memberof MajorStateDataBase
*/
public sortField: string = '';
/**
* 排序模型数据集
*
* @type {string}
* @memberof MajorStateDataBase
*/
public sortModel: any[] = [
'type',
'ibizbookname'
]
/**
* 应用状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof MajorStateDataBase
*/
public appStateEvent: Subscription | undefined;
/**
* 默认隐藏批量操作工具栏
*
* @type {boolean}
* @memberof MajorStateDataBase
*/
public flag: boolean = false;
/**
* 更改批量操作工具栏显示状态
*
* @param $event
* @memberof MajorStateDataBase
*/
public onClick($event: any){
if(!this.moveflag){
this.flag = !this.flag;
}
this.moveflag = false;
}
/**
* 排序点击事件
* @param {string} field 属性名
*
* @memberof MajorStateDataBase
*/
public sortClick(field:string) {
if(this.sortField !== field){
this.sortField = field;
this.sortDir = 'asc';
}else if(this.sortDir === 'asc'){
this.sortDir = 'desc';
}else if(this.sortDir === 'desc'){
this.sortDir = '';
}else{
this.sortDir = 'asc';
}
this.refresh();
}
/**
* 排序class变更
* @param {string} field 属性名
*
* @memberof MajorStateDataBase
*/
public getsortClass(field:string) {
if(this.sortField !== field || this.sortDir === ''){
return '';
}else if(this.sortDir === 'asc'){
return 'sort-ascending'
}else if(this.sortDir === 'desc'){
return 'sort-descending'
}
}
/**
* Vue声明周期,组件挂载完毕
*
* @memberof MajorStateDataBase
*/
public mounted () {
this.afterMounted();
}
/**
* 执行mounted后的逻辑
*
* @memberof MajorStateDataBase
*/
public afterMounted(){
this.$el.addEventListener('scroll', ()=> {
let el: any = this.$el.getElementsByClassName('dataview-pagination')[0];
el.style.top = 40 + this.$el.scrollTop + 'px';
if( this.$el.scrollTop + this.$el.clientHeight >= this.$el.scrollHeight) {
this.loadMore();
}
})
}
/**
* Vue声明周期,组件创建完毕
*
* @memberof MajorStateDataBase
*/
public created() {
this.afterCreated();
this.$nextTick(()=>{
this.mouseEvent();
})
}
/**
* 执行created后的逻辑
*
* @memberof MajorStateDataBase
*/
public afterCreated(){
if (this.viewState) {
this.viewStateEvent = this.viewState.subscribe(({ tag, action, data }) => {
if (!Object.is(this.name, tag)) {
return;
}
if (Object.is(action,'load')) {
this.refresh(data)
}
if (Object.is(action,'filter')) {
this.refresh(data)
}
});
}
if(AppCenterService && AppCenterService.getMessageCenter()){
this.appStateEvent = AppCenterService.getMessageCenter().subscribe(({ name, action, data }) =>{
if(!Object.is(name,"IBIZBOOK")){
return;
}
if(Object.is(action,'appRefresh')){
this.refresh([data]);
}
})
}
}
/**
* 鼠标移动+放下
*
* @memberof MajorStateDataBase
*/
public mouseEvent(){
this.dragEle = document.getElementsByClassName('drag-filed')[0];
document.onmousemove=(e:any)=>{
if(this.dragflag){
this.dragEle.style.left = (e.clientX - this.leftP) + 'px';
this.dragEle.style.top = (e.clientY - this.topP) + 'px';
this.moveflag = true;
}
}
document.onmouseup=(e:any)=>{
this.dragflag = false;
}
}
/**
* mousedown事件
*
* @param $event
* @memberof MajorStateDataBase
*/
public down(e:any){
this.leftP = e.clientX - this.dragEle.offsetLeft;
this.topP = e.clientY - this.dragEle.offsetTop;
this.dragflag = true;
}
/**
* 加载更多
*
* @memberof MajorStateDataBase
*/
public loadMore(){
if(this.totalRecord>this.items.length)
{
this.curPage = ++this.curPage;
this.isAddBehind = true;
this.load({});
}
}
/**
* 刷新
*
* @param {*} [args={}]
* @memberof MajorStateDataBase
*/
public refresh(args?: any) {
this.curPage = 1;
this.load(args, true);
}
/**
* vue 生命周期
*
* @memberof MajorStateDataBase
*/
public destroyed() {
this.afterDestroy();
}
/**
* 执行destroyed后的逻辑
*
* @memberof MajorStateDataBase
*/
public afterDestroy() {
if (this.viewStateEvent) {
this.viewStateEvent.unsubscribe();
}
if(this.appStateEvent){
this.appStateEvent.unsubscribe();
}
}
/**
* 表格数据加载
*
* @public
* @param {*} [arg={}]
* @param {boolean} [isReset=false] 是否重置items
* @memberof MajorStateDataBase
*/
public load(opt: any = {}, isReset: boolean = false): void {
if(!this.fetchAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKUsr6DataView' + (this.$t('app.list.notConfig.fetchAction') as string) });
return;
}
const arg: any = {...opt};
const page: any = {};
if (this.isEnablePagingBar) {
Object.assign(page, { page: this.curPage-1, size: this.limit });
}
// 设置排序
if (!Object.is(this.sortDir, '') && !Object.is(this.sortField, '')) {
const sort: string = this.sortField+","+this.sortDir;
Object.assign(page, { sort: sort });
}
Object.assign(arg, page);
const parentdata: any = {};
this.$emit('beforeload', parentdata);
Object.assign(arg, parentdata);
let tempViewParams:any = parentdata.viewparams?parentdata.viewparams:{};
Object.assign(tempViewParams,JSON.parse(JSON.stringify(this.viewparams)));
Object.assign(arg,{viewparams:tempViewParams});
const post: Promise<any> = this.service.search(this.fetchAction,JSON.parse(JSON.stringify(this.context)), arg, this.showBusyIndicator);
post.then((response: any) => {
if (!response || response.status !== 200) {
if (response.errorMessage) {
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: response.errorMessage });
}
return;
}
const data: any = response.data;
if(!this.isAddBehind){
this.items = [];
}
if (Object.keys(data).length > 0) {
let datas = JSON.parse(JSON.stringify(data));
datas.map((item: any) => {
Object.assign(item, { isselected: false });
});
this.totalRecord = response.total;
if(isReset){
this.items = datas;
}else{
this.items.push(...datas);
}
}
this.isAddBehind = false;
this.$emit('load', this.items);
//在导航视图中,如已有选中数据,则右侧展开已选中数据的视图,如无选中数据则默认选中第一条
if(this.isSelectFirstDefault){
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.handleClick(this.items[index]);
}
})
}else{
this.handleClick(this.items[0]);
}
}
}, (response: any) => {
if (response && response.status === 401) {
return;
}
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: response.errorMessage });
});
}
/**
* 删除
*
* @param {any[]} datas
* @returns {Promise<any>}
* @memberof MajorStateDataBase
*/
public async remove(datas: any[]): Promise<any> {
if(!this.removeAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKUsr6DataView' + (this.$t('app.gridpage.notConfig.removeAction') as string) });
return;
}
let _datas:any[] = [];
datas.forEach((record: any, index: number) => {
if (Object.is(record.srfuf, '0')) {
this.items.some((val: any, num: number) =>{
if(JSON.stringify(val) == JSON.stringify(record)){
this.items.splice(num,1);
return true;
}
});
}else{
_datas.push(datas[index]);
}
});
if (_datas.length === 0) {
return;
}
let dataInfo = '';
_datas.forEach((record: any, index: number) => {
let srfmajortext = record.srfmajortext;
if (index < 5) {
if (!Object.is(dataInfo, '')) {
dataInfo += '、';
}
dataInfo += srfmajortext;
} else {
return false;
}
});
if (_datas.length < 5) {
dataInfo = dataInfo + ' ' + (this.$t('app.dataView.sum') as string) + _datas.length + (this.$t('app.dataView.data') as string);
} else {
dataInfo = dataInfo + '...' + ' ' + (this.$t('app.dataView.sum') as string) + _datas.length + (this.$t('app.dataView.data') as string);
}
const removeData = () => {
let keys: any[] = [];
_datas.forEach((data: any) => {
keys.push(data.srfkey);
});
let _removeAction = keys.length > 1 ? 'removeBatch' : this.removeAction ;
const context:any = JSON.parse(JSON.stringify(this.context));
const post: Promise<any> = this.service.delete(_removeAction,Object.assign(context,{ ibizbook: keys.join(';') }),Object.assign({ ibizbook: keys.join(';') },{viewparams:this.viewparams}), this.showBusyIndicator);
return new Promise((resolve: any, reject: any) => {
post.then((response: any) => {
if (!response || response.status !== 200) {
this.$Notice.error({ title: '', desc: (this.$t('app.commonWords.delDataFail') as string) + ',' + response.info });
return;
} else {
this.$Notice.success({ title: '', desc: (this.$t('app.commonWords.deleteSuccess') as string) });
}
//删除items中已删除的项
_datas.forEach((data: any) => {
this.items.some((item:any,index:number)=>{
if(Object.is(item.srfkey,data.srfkey)){
this.items.splice(index,1);
return true;
}
});
});
this.$emit('remove', null);
this.selections = [];
resolve(response);
}).catch((response: any) => {
if (response && response.status === 401) {
return;
}
if (!response || !response.status || !response.data) {
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: (this.$t('app.commonWords.sysException') as string) });
reject(response);
return;
}
reject(response);
});
});
}
dataInfo = dataInfo.replace(/[null]/g, '').replace(/[undefined]/g, '').replace(/[ ]/g, '');
this.$Modal.confirm({
title: (this.$t('app.commonWords.warning') as string),
content: (this.$t('app.gridpage.confirmDel') as string) + ' ' + dataInfo + ',' + (this.$t('app.gridpage.notRecoverable') as string),
onOk: () => {
removeData();
},
onCancel: () => { }
});
return removeData;
}
/**
* 保存
*
* @param {*} $event
* @returns {Promise<any>}
* @memberof MajorStateDataBase
*/
public async save(args: any[], params?: any, $event?: any, xData?: any){
let _this = this;
let successItems:any = [];
let errorItems:any = [];
let errorMessage:any = [];
for (const item of _this.items) {
try {
if(Object.is(item.rowDataState, 'create')){
if(!this.createAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKUsr6DataView' + (this.$t('app.list.notConfig.createAction') as string) });
}else{
Object.assign(item,{viewparams:this.viewparams});
let response = await this.service.add(this.createAction, JSON.parse(JSON.stringify(this.context)),item, this.showBusyIndicator);
successItems.push(JSON.parse(JSON.stringify(response.data)));
}
}else if(Object.is(item.rowDataState, 'update')){
if(!this.updateAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKUsr6DataView' + (this.$t('app.list.notConfig.updateAction') as string) });
}else{
Object.assign(item,{viewparams:this.viewparams});
if(item.ibizbook){
Object.assign(this.context,{ibizbook:item.ibizbook});
}
let response = await this.service.add(this.updateAction,JSON.parse(JSON.stringify(this.context)),item, this.showBusyIndicator);
successItems.push(JSON.parse(JSON.stringify(response.data)));
}
}
} catch (error) {
errorItems.push(JSON.parse(JSON.stringify(item)));
errorMessage.push(error);
}
}
this.$emit('save', successItems);
this.refresh();
if(errorItems.length === 0){
this.$Notice.success({ title: '', desc: (this.$t('app.commonWords.saveSuccess') as string) });
}else{
errorItems.forEach((item:any,index:number)=>{
this.$Notice.error({ title: (this.$t('app.commonWords.saveFailed') as string), desc: item.majorentityname + (this.$t('app.commonWords.saveFailed') as string) + '!' });
console.error(errorMessage[index]);
});
}
return successItems;
}
/**
* 面板数据变化处理事件
* @param {any} item 当前卡片数据
* @param {any} $event 面板事件数据
*
* @memberof MajorStateDataBase
*/
public onPanelDataChange(item:any,$event:any) {
Object.assign(item, $event, {rowDataState:'update'});
}
/**
* 选择数据
* @memberof MajorStateDataBase
*
*/
public handleClick(args: any) {
args.isselected = !args.isselected;
if(this.isSingleSelect) {
this.items.forEach((item:any) =>{
if(item.srfkey !== args.srfkey){
item.isselected =false;
}
})
}
this.selectchange();
}
/**
* 双击数据
* @memberof MajorStateDataBase
*
*/
public handleDblClick(args: any) {
this.$emit('rowdblclick', args);
}
/**
* 触发事件
* @memberof MajorStateDataBase
*
*/
public selectchange() {
this.selections = [];
this.items.map((item: any) => {
if (item.isselected) {
this.selections.push(item);
}
});
this.$emit('selectionchange', this.selections);
}
/**
* 操作列界面行为
*
* @param {*} data
* @param {*} tag
* @param {*} $event
* @memberof MajorStateDataBase
*/
public uiAction(data: any, tag: any, $event: any) {
$event.stopPropagation();
if(Object.is('Edit', tag)) {
this.dataview_item_u786fa64_click(data, tag, $event);
}
if(Object.is('Delete', tag)) {
this.dataview_item_u0a83fc3_click(data, tag, $event);
}
}
}
</script>
<style lang='less'>
@import './major-state-data-dataview.less';
</style>
\ No newline at end of file
/**
* MajorStateData 部件模型
*
* @export
* @class MajorStateDataModel
*/
export default class MajorStateDataModel {
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof MajorStateDataDataViewMode
*/
public getDataItems(): any[] {
return [
{
name: 'srfdescription',
prop: 'type',
dataType: 'TEXT',
},
{
name: 'srfmstag',
},
{
name: 'srfkey',
prop: 'ibizbookid',
dataType: 'GUID',
},
{
name: 'srfmajortext',
prop: 'ibizbookname',
dataType: 'TEXT',
},
{
name: 'ibizbook',
prop: 'ibizbookid',
dataType: 'FONTKEY',
},
{
name: 'n_ibizbookname_like',
prop: 'n_ibizbookname_like',
dataType: 'QUERYPARAM'
},
{
name: 'n_price_gtandeq',
prop: 'n_price_gtandeq',
dataType: 'QUERYPARAM'
},
{
name:'size',
prop:'size'
},
{
name:'query',
prop:'query'
},
{
name:'sort',
prop:'sort'
},
{
name:'page',
prop:'page'
},
{
name:'srfparentdata',
prop:'srfparentdata'
},
// 前端新增修改标识,新增为"0",修改为"1"或未设值
{
name: 'srffrontuf',
prop: 'srffrontuf',
dataType: 'TEXT',
},
]
}
}
\ No newline at end of file
import { Http,Util,Errorlog } from '@/utils';
import ControlService from '@/widgets/control-service';
import IBIZBOOKService from '@/service/ibizbook/ibizbook-service';
import MajorStateDataModel from './major-state-data-dataview-model';
/**
* MajorStateData 部件服务对象
*
* @export
* @class MajorStateDataService
*/
export default class MajorStateDataService extends ControlService {
/**
* 图书服务对象
*
* @type {IBIZBOOKService}
* @memberof MajorStateDataService
*/
public appEntityService: IBIZBOOKService = new IBIZBOOKService({ $store: this.getStore() });
/**
* 设置从数据模式
*
* @type {boolean}
* @memberof MajorStateDataService
*/
public setTempMode(){
this.isTempMode = false;
}
/**
* Creates an instance of MajorStateDataService.
*
* @param {*} [opts={}]
* @memberof MajorStateDataService
*/
constructor(opts: any = {}) {
super(opts);
this.model = new MajorStateDataModel();
}
/**
* 查询数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof MajorStateDataService
*/
@Errorlog
public search(action: string,context: any = {}, data: any = {}, isloading?: boolean): Promise<any> {
const {data:Data,context:Context} = this.handleRequestData(action,context,data,true);
return new Promise((resolve: any, reject: any) => {
const _appEntityService: any = this.appEntityService;
let result: Promise<any>;
if (_appEntityService[action] && _appEntityService[action] instanceof Function) {
result = _appEntityService[action](Context,Data, isloading);
}else{
result =_appEntityService.FetchDefault(Context,Data, isloading);
}
result.then((response) => {
this.handleResponse(action, response);
resolve(response);
}).catch(response => {
reject(response);
});
});
}
/**
* 删除数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof MajorStateDataService
*/
@Errorlog
public delete(action: string,context: any = {}, data: any = {}, isloading?: boolean): Promise<any> {
const {data:Data,context:Context} = this.handleRequestData(action,context,data,true);
return new Promise((resolve: any, reject: any) => {
const _appEntityService: any = this.appEntityService;
let result: Promise<any>;
if (_appEntityService[action] && _appEntityService[action] instanceof Function) {
result = _appEntityService[action](Context,Data, isloading);
}else{
result =_appEntityService.remove(Context,Data, isloading);
}
result.then((response) => {
this.handleResponse(action, response);
resolve(response);
}).catch(response => {
reject(response);
});
});
}
/**
* 添加数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof MajorStateDataService
*/
@Errorlog
public add(action: string, context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
const {data:Data,context:Context} = this.handleRequestData(action,context,data,true);
return new Promise((resolve: any, reject: any) => {
const _appEntityService: any = this.appEntityService;
let result: Promise<any>;
if (_appEntityService[action] && _appEntityService[action] instanceof Function) {
result = _appEntityService[action](Context,Data, isloading);
}else{
result =_appEntityService.Create(Context,Data, isloading);
}
result.then((response) => {
this.handleResponse(action, response);
resolve(response);
}).catch(response => {
reject(response);
});
});
}
/**
* 修改数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof MajorStateDataService
*/
@Errorlog
public update(action: string, context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
const {data:Data,context:Context} = this.handleRequestData(action,context,data,true);
return new Promise((resolve: any, reject: any) => {
const _appEntityService: any = this.appEntityService;
let result: Promise<any>;
if (_appEntityService[action] && _appEntityService[action] instanceof Function) {
result = _appEntityService[action](Context,Data,isloading);
}else{
result =_appEntityService.Update(Context,Data,isloading);
}
result.then((response) => {
this.handleResponse(action, response);
resolve(response);
}).catch(response => {
reject(response);
});
});
}
}
\ No newline at end of file
.app-data-view {
height: 100%;
overflow-y: auto;
overflow-x: hidden;
position: relative;
// 排序栏样式
.bar-container{
padding: 6px 8px;
background-color: #F1F1F1;
.ivu-row-flex.page-sort-bar{
width: 100%;
height: 30px;
.ivu-col{
user-select: none;
text-align: center;
display: flex;
align-items: flex-end;
padding-bottom: 4px;
background-color: #FFF;
border: 1px solid #CCC;
margin-left: -1px;
.sort-field-text{
margin-left: 7px;
}
.caret-wrapper{
width: 15px;
display: inline-block;
padding-bottom: 2px;
.ivu-icon{
display: block;
line-height: 0.5;
color: #c5c8ce;
}
}
}
// 悬浮样式
.ivu-col:hover{
border:1px solid #82bff7;
position:relative;
z-index:2;
.sort-field-text{
color: #82bff7;
}
}
// 选中样式
.sort-ascending, .sort-descending{
border:1px solid #82bff7;
position:relative;
z-index:2;
.sort-field-text{
color:#82bff7;
font-weight: 800;
}
}
.sort-ascending .caret-wrapper .ivu-icon.ivu-icon-md-arrow-dropup,
.sort-descending .caret-wrapper .ivu-icon.ivu-icon-md-arrow-dropdown{
color: #82bff7;
}
}
}
.data-view-container {
height: calc(100% - 42px);
align-content: start;
.el-collapse{
width: 100%;
.el-collapse-item__content{
padding: 10px 0px 0px 0px;
display: flex;
.item-nodata {
padding-bottom: 10px;
width: 100%;
text-align: center;
}
}
}
.el-collapse-item__header.is-active{
color: #409eff;
background-color: #ecf5ff;
}
.ivu-col{
padding: 10px;
.el-card__body{
padding: 10px;
}
}
.el-card{
background-color: #f6f6f6;
color: #666666;
box-shadow: 0 2px 12px 0 #909399;
}
.single-card-data{
height: 100%;
width: 100%;
cursor: pointer;
border: 2px solid transparent;
.data-view-item{
.single-card-default {
.ivu-tooltip{
.ivu-tooltip-rel{
width: 150px;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
text-align: left;
padding-left: 5px;
font-size: 18px;
font-weight: 800;
}
}
}
.single-card-img {
width: 150px;
height: calc(100% - 32px);
}
}
.data-view-item-action{
button{
margin: 0 3px;
cursor: pointer;
padding:3px;
}
button:hover{
color: #409eff;
}
}
}
.isselected{
border: 2px solid #82bff7;
box-shadow: 5px 5px 12px 0 #82bff7;
.ivu-tooltip{
color: #82bff7;
font-weight: 800;
}
}
.single-card-data:hover{
border: 2px solid #82bff7;
box-shadow: 5px 5px 12px 0 #82bff7;
.ivu-tooltip{
color: #82bff7;
font-weight: 800;
}
}
}
// 空值文本
.app-data-empty {
height: calc(100% - 42px);
color: #909399;
display: flex;
justify-content: center;
align-items: center;
}
.el-backtop {
position: absolute;
}
}
// this is less
<script lang='tsx'>
import { Component } from 'vue-property-decorator';
import MajorStateDataBase from './major-state-data-dataview-base.vue';
@Component({
components: {
}
})
export default class MajorStateData extends MajorStateDataBase {
}
</script>
\ No newline at end of file
......@@ -326,7 +326,7 @@
{
"appid":"Web",
"appname":"演示应用",
"appmenu":[{"menuid":"MainMenu", "menuname":"MainMenu", "menuitem":[{ "id":"menuitem1" , "name":"工作台" },{ "id":"menuitem3" , "name":"控件" , "items":[{ "id":"menuitem6" , "name":"默认数据类型" },{ "id":"menuitem7" , "name":"默认编辑器类型" },{ "id":"menuitem15" , "name":"基础表单项" },{ "id":"menuitem72" , "name":"扩展编辑器" },{ "id":"menuitem151" , "name":"自定义扩展编辑器" }]},{ "id":"menuitem4" , "name":"部件" , "items":[{ "id":"menuitem101" , "name":"实体看板" , "items":[{ "id":"menuitem102" , "name":"内置功能" },{ "id":"menuitem104" , "name":"代码表分组" },{ "id":"menuitem105" , "name":"项布局面板" }]},{ "id":"menuitem18" , "name":"界面行为" , "items":[{ "id":"menuitem65" , "name":"前端界面行为" },{ "id":"menuitem66" , "name":"后台界面行为" }]},{ "id":"menuitem129" , "name":"选项操作" , "items":[{ "id":"menuitem131" , "name":"表格选项操作" }]},{ "id":"menuitem142" , "name":"选择视图" , "items":[{ "id":"menuitem130" , "name":"索引关系选择视图" },{ "id":"menuitem145" , "name":"选择视图" }]},{ "id":"menuitem112" , "name":"应用类" , "items":[{ "id":"menuitem125" , "name":"数据看板" , "items":[{ "id":"menuitem126" , "name":"实体数据看板" }]}]},{ "id":"menuitem156" , "name":"表单类" , "items":[{ "id":"menuitem12" , "name":"编辑表单" , "items":[{ "id":"menuitem107" , "name":"内置功能" },{ "id":"menuitem47" , "name":"新建默认值" },{ "id":"menuitem99" , "name":"更新默认值" },{ "id":"menuitem48" , "name":"输入提示" },{ "id":"menuitem49" , "name":"辅助输入" },{ "id":"menuitem50" , "name":"自动填充" },{ "id":"menuitem51" , "name":"超链接" },{ "id":"menuitem52" , "name":"表单值重置" },{ "id":"menuitem55" , "name":"动态显示" },{ "id":"menuitem53" , "name":"动态启用" },{ "id":"menuitem54" , "name":"动态空输入" },{ "id":"menuitem56" , "name":"表单项更新" },{ "id":"menuitem108" , "name":"表单值规则" }]},{ "id":"menuitem121" , "name":"多编辑视图" , "items":[{ "id":"menuitem115" , "name":"多表单(行记录)" },{ "id":"menuitem123" , "name":"多表单(上分页)" }]},{ "id":"menuitem16" , "name":"搜索表单" }]},{ "id":"menuitem157" , "name":"导航类" , "items":[{ "id":"menuitem122" , "name":"数据关系栏" , "items":[{ "id":"menuitem116" , "name":"编辑视图(左右关系)" },{ "id":"menuitem117" , "name":"编辑视图(上下关系)" },{ "id":"menuitem118" , "name":"编辑视图(分页关系)" }]},{ "id":"menuitem120" , "name":"分页导航" },{ "id":"menuitem128" , "name":"表格导航" },{ "id":"menuitem136" , "name":"树导航" },{ "id":"menuitem137" , "name":"卡片导航" },{ "id":"menuitem139" , "name":"时间轴导航" },{ "id":"menuitem114" , "name":"列表导航" },{ "id":"menuitem138" , "name":"日历导航" }]},{ "id":"menuitem158" , "name":"面板类" , "items":[{ "id":"menuitem17" , "name":"向导面板" , "items":[{ "id":"menuitem134" , "name":"基础用法" },{ "id":"menuitem135" , "name":"状态属性" }]}]},{ "id":"menuitem119" , "name":"多数据类" , "items":[{ "id":"menuitem13" , "name":"表格" , "items":[{ "id":"menuitem57" , "name":"禁用排序" },{ "id":"menuitem59" , "name":"行操作" },{ "id":"menuitem58" , "name":"行编辑" },{ "id":"menuitem73" , "name":"内置功能" },{ "id":"menuitem74" , "name":"表格行编辑" },{ "id":"menuitem75" , "name":"新建默认值" },{ "id":"menuitem76" , "name":"更新默认值" },{ "id":"menuitem77" , "name":"表格值规则" },{ "id":"menuitem132" , "name":"表格列更新" },{ "id":"menuitem133" , "name":"表格列重置" },{ "id":"menuitem78" , "name":"自动分组" },{ "id":"menuitem80" , "name":"代码表分组" },{ "id":"menuitem81" , "name":"当前页聚合" },{ "id":"menuitem82" , "name":"远程聚合" }]},{ "id":"menuitem95" , "name":"日历" , "items":[{ "id":"menuitem96" , "name":"内置功能" },{ "id":"menuitem97" , "name":"时间轴样式" },{ "id":"menuitem109" , "name":"项布局面板" },{ "id":"menuitem64" , "name":"自定义插件" }]},{ "id":"menuitem110" , "name":"树表格" },{ "id":"menuitem111" , "name":"甘特图" },{ "id":"menuitem87" , "name":"数据视图" , "items":[{ "id":"menuitem88" , "name":"内置功能" },{ "id":"menuitem89" , "name":"自动分组" },{ "id":"menuitem90" , "name":"代码表分组" },{ "id":"menuitem94" , "name":"项布局面板" },{ "id":"menuitem152" , "name":"自定义插件" }]},{ "id":"menuitem14" , "name":"树视图" , "items":[{ "id":"menuitem60" , "name":"静态节点" },{ "id":"menuitem61" , "name":"动态节点(代码表)" },{ "id":"menuitem62" , "name":"动态节点(实体)" },{ "id":"menuitem63" , "name":"右键操作" }]},{ "id":"menuitem37" , "name":"图表" , "items":[{ "id":"menuitem38" , "name":"柱状图" },{ "id":"menuitem39" , "name":"折线图" },{ "id":"menuitem40" , "name":"饼图" },{ "id":"menuitem41" , "name":"区域图" },{ "id":"menuitem42" , "name":"雷达图" }]},{ "id":"menuitem83" , "name":"列表" , "items":[{ "id":"menuitem84" , "name":"内置功能" },{ "id":"menuitem85" , "name":"自动分组" },{ "id":"menuitem86" , "name":"代码表分组" },{ "id":"menuitem91" , "name":"项布局面板" },{ "id":"menuitem143" , "name":"自定义插件" }]}]},{ "id":"menuitem159" , "name":"其他类" }]},{ "id":"menuitem5" , "name":"视图" , "items":[{ "id":"menuitem26" , "name":"选择视图" , "items":[{ "id":"menuitem27" , "name":"单选视图" },{ "id":"menuitem28" , "name":"多选视图" },{ "id":"menuitem29" , "name":"树形选择视图" },{ "id":"menuitem30" , "name":"左右单选视图" },{ "id":"menuitem31" , "name":"左右多选视图" }]},{ "id":"menuitem10" , "name":"导航视图" , "items":[{ "id":"menuitem32" , "name":"常规导航视图" },{ "id":"menuitem33" , "name":"分页导航视图" },{ "id":"menuitem34" , "name":"嵌入导航视图" },{ "id":"menuitem176" , "name":"实体表格导航视图" },{ "id":"menuitem177" , "name":"实体列表导航视图" },{ "id":"menuitem178" , "name":"实体卡片导航视图" },{ "id":"menuitem179" , "name":"实体日历导航视图" },{ "id":"menuitem180" , "name":"实体树导航视图" }]},{ "id":"menuitem11" , "name":"其他视图" , "items":[{ "id":"menuitem35" , "name":"图表视图" },{ "id":"menuitem36" , "name":"报表视图" },{ "id":"menuitem98" , "name":"自定义视图" }]},{ "id":"menuitem140" , "name":"单数据视图" , "items":[{ "id":"menuitem8" , "name":"编辑视图" , "items":[{ "id":"menuitem22" , "name":"常规编辑视图" },{ "id":"menuitem23" , "name":"左右编辑视图" },{ "id":"menuitem24" , "name":"分页编辑视图" },{ "id":"menuitem25" , "name":"嵌入编辑视图" }]},{ "id":"menuitem161" , "name":"实体向导视图" },{ "id":"menuitem162" , "name":"实体编辑视图(分页关系)" },{ "id":"menuitem163" , "name":"实体编辑视图(上下关系)" },{ "id":"menuitem164" , "name":"实体编辑视图(左右关系)" },{ "id":"menuitem165" , "name":"实体分页导航视图" },{ "id":"menuitem166" , "name":"实体数据看板视图" },{ "id":"menuitem167" , "name":"实体选项操作视图" }]},{ "id":"menuitem141" , "name":"多数据视图" , "items":[{ "id":"menuitem9" , "name":"列表视图" , "items":[{ "id":"menuitem21" , "name":"左右表格视图" },{ "id":"menuitem20" , "name":"嵌入表格视图" }]},{ "id":"menuitem79" , "name":"表格视图" , "items":[{ "id":"menuitem19" , "name":"常规表格视图" }]},{ "id":"menuitem168" , "name":"实体多表单编辑视图" },{ "id":"menuitem169" , "name":"实体甘特视图" },{ "id":"menuitem170" , "name":"实体日历视图" },{ "id":"menuitem171" , "name":"实体看板视图" },{ "id":"menuitem172" , "name":"实体树表格视图" },{ "id":"menuitem173" , "name":"实体树视图" },{ "id":"menuitem174" , "name":"实体数据视图" },{ "id":"menuitem175" , "name":"实体图表视图" }]}]},{ "id":"menuitem69" , "name":"工作流" },{ "id":"menuitem153" , "name":"逻辑" , "items":[{ "id":"menuitem154" , "name":"应用功能" , "items":[{ "id":"menuitem127" , "name":"打开应用视图" },{ "id":"menuitem147" , "name":"打开HTML页面" },{ "id":"menuitem160" , "name":"执行JavaScript" }]},{ "id":"menuitem155" , "name":"界面行为" , "items":[{ "id":"menuitem181" , "name":"前端界面行为" },{ "id":"menuitem182" , "name":"后台界面行为" }]}]},{ "id":"menuitem2" , "name":"更多" , "items":[{ "id":"menuitem46" , "name":"数据导出导入" },{ "id":"menuitem45" , "name":"数据打印" },{ "id":"menuitem67" , "name":"索引实体" },{ "id":"menuitem68" , "name":"继承实体" },{ "id":"menuitem70" , "name":"表格主状态" },{ "id":"menuitem71" , "name":"多表单" },{ "id":"menuitem148" , "name":"列表主状态" }]},{ "id":"menuitem92" , "name":"其他" , "items":[{ "id":"menuitem93" , "name":"示例实体02示例数据补充" },{ "id":"menuitem100" , "name":"订单示例数据补充" },{ "id":"menuitem103" , "name":"产品示例数据补充" },{ "id":"menuitem106" , "name":"示例实体03示例数据补充" },{ "id":"menuitem113" , "name":"订单类型添加" },{ "id":"menuitem124" , "name":"示例实体01数据补充" },{ "id":"menuitem144" , "name":"客户实体示例数据补充" },{ "id":"menuitem146" , "name":"应用视图数据补充" },{ "id":"menuitem149" , "name":"应用部件数据补充" },{ "id":"menuitem150" , "name":"编辑器数据补充" }]}] }]
"appmenu":[{"menuid":"MainMenu", "menuname":"MainMenu", "menuitem":[{ "id":"menuitem1" , "name":"工作台" },{ "id":"menuitem3" , "name":"控件" , "items":[{ "id":"menuitem6" , "name":"默认数据类型" },{ "id":"menuitem7" , "name":"默认编辑器类型" },{ "id":"menuitem15" , "name":"基础表单项" },{ "id":"menuitem72" , "name":"扩展编辑器" },{ "id":"menuitem151" , "name":"自定义扩展编辑器" }]},{ "id":"menuitem4" , "name":"部件" , "items":[{ "id":"menuitem101" , "name":"实体看板" , "items":[{ "id":"menuitem102" , "name":"内置功能" },{ "id":"menuitem104" , "name":"代码表分组" },{ "id":"menuitem105" , "name":"项布局面板" }]},{ "id":"menuitem18" , "name":"界面行为" , "items":[{ "id":"menuitem65" , "name":"前端界面行为" },{ "id":"menuitem66" , "name":"后台界面行为" }]},{ "id":"menuitem129" , "name":"选项操作" , "items":[{ "id":"menuitem131" , "name":"表格选项操作" }]},{ "id":"menuitem142" , "name":"选择视图" , "items":[{ "id":"menuitem130" , "name":"索引关系选择视图" },{ "id":"menuitem145" , "name":"选择视图" }]},{ "id":"menuitem112" , "name":"应用类" , "items":[{ "id":"menuitem125" , "name":"数据看板" , "items":[{ "id":"menuitem126" , "name":"实体数据看板" }]}]},{ "id":"menuitem156" , "name":"表单类" , "items":[{ "id":"menuitem12" , "name":"编辑表单" , "items":[{ "id":"menuitem107" , "name":"内置功能" },{ "id":"menuitem47" , "name":"新建默认值" },{ "id":"menuitem99" , "name":"更新默认值" },{ "id":"menuitem48" , "name":"输入提示" },{ "id":"menuitem49" , "name":"辅助输入" },{ "id":"menuitem50" , "name":"自动填充" },{ "id":"menuitem51" , "name":"超链接" },{ "id":"menuitem52" , "name":"表单值重置" },{ "id":"menuitem55" , "name":"动态显示" },{ "id":"menuitem53" , "name":"动态启用" },{ "id":"menuitem54" , "name":"动态空输入" },{ "id":"menuitem56" , "name":"表单项更新" },{ "id":"menuitem108" , "name":"表单值规则" }]},{ "id":"menuitem121" , "name":"多编辑视图" , "items":[{ "id":"menuitem115" , "name":"多表单(行记录)" },{ "id":"menuitem123" , "name":"多表单(上分页)" }]},{ "id":"menuitem16" , "name":"搜索表单" }]},{ "id":"menuitem157" , "name":"导航类" , "items":[{ "id":"menuitem122" , "name":"数据关系栏" , "items":[{ "id":"menuitem116" , "name":"编辑视图(左右关系)" },{ "id":"menuitem117" , "name":"编辑视图(上下关系)" },{ "id":"menuitem118" , "name":"编辑视图(分页关系)" }]},{ "id":"menuitem120" , "name":"分页导航" },{ "id":"menuitem128" , "name":"表格导航" },{ "id":"menuitem136" , "name":"树导航" },{ "id":"menuitem137" , "name":"卡片导航" },{ "id":"menuitem139" , "name":"时间轴导航" },{ "id":"menuitem114" , "name":"列表导航" },{ "id":"menuitem138" , "name":"日历导航" }]},{ "id":"menuitem158" , "name":"面板类" , "items":[{ "id":"menuitem17" , "name":"向导面板" , "items":[{ "id":"menuitem134" , "name":"基础用法" },{ "id":"menuitem135" , "name":"状态属性" }]}]},{ "id":"menuitem119" , "name":"多数据类" , "items":[{ "id":"menuitem13" , "name":"表格" , "items":[{ "id":"menuitem57" , "name":"禁用排序" },{ "id":"menuitem59" , "name":"行操作" },{ "id":"menuitem58" , "name":"行编辑" },{ "id":"menuitem73" , "name":"内置功能" },{ "id":"menuitem74" , "name":"表格行编辑" },{ "id":"menuitem75" , "name":"新建默认值" },{ "id":"menuitem76" , "name":"更新默认值" },{ "id":"menuitem77" , "name":"表格值规则" },{ "id":"menuitem132" , "name":"表格列更新" },{ "id":"menuitem133" , "name":"表格列重置" },{ "id":"menuitem78" , "name":"自动分组" },{ "id":"menuitem80" , "name":"代码表分组" },{ "id":"menuitem81" , "name":"当前页聚合" },{ "id":"menuitem82" , "name":"远程聚合" }]},{ "id":"menuitem95" , "name":"日历" , "items":[{ "id":"menuitem96" , "name":"内置功能" },{ "id":"menuitem97" , "name":"时间轴样式" },{ "id":"menuitem109" , "name":"项布局面板" },{ "id":"menuitem64" , "name":"自定义插件" }]},{ "id":"menuitem110" , "name":"树表格" },{ "id":"menuitem111" , "name":"甘特图" },{ "id":"menuitem87" , "name":"数据视图" , "items":[{ "id":"menuitem88" , "name":"内置功能" },{ "id":"menuitem89" , "name":"自动分组" },{ "id":"menuitem90" , "name":"代码表分组" },{ "id":"menuitem94" , "name":"项布局面板" },{ "id":"menuitem152" , "name":"自定义插件" }]},{ "id":"menuitem14" , "name":"树视图" , "items":[{ "id":"menuitem60" , "name":"静态节点" },{ "id":"menuitem61" , "name":"动态节点(代码表)" },{ "id":"menuitem62" , "name":"动态节点(实体)" },{ "id":"menuitem63" , "name":"右键操作" }]},{ "id":"menuitem37" , "name":"图表" , "items":[{ "id":"menuitem38" , "name":"柱状图" },{ "id":"menuitem39" , "name":"折线图" },{ "id":"menuitem40" , "name":"饼图" },{ "id":"menuitem41" , "name":"区域图" },{ "id":"menuitem42" , "name":"雷达图" }]},{ "id":"menuitem83" , "name":"列表" , "items":[{ "id":"menuitem84" , "name":"内置功能" },{ "id":"menuitem85" , "name":"自动分组" },{ "id":"menuitem86" , "name":"代码表分组" },{ "id":"menuitem91" , "name":"项布局面板" },{ "id":"menuitem143" , "name":"自定义插件" }]}]},{ "id":"menuitem159" , "name":"其他类" }]},{ "id":"menuitem5" , "name":"视图" , "items":[{ "id":"menuitem26" , "name":"选择视图" , "items":[{ "id":"menuitem27" , "name":"单选视图" },{ "id":"menuitem28" , "name":"多选视图" },{ "id":"menuitem29" , "name":"树形选择视图" },{ "id":"menuitem30" , "name":"左右单选视图" },{ "id":"menuitem31" , "name":"左右多选视图" }]},{ "id":"menuitem10" , "name":"导航视图" , "items":[{ "id":"menuitem32" , "name":"常规导航视图" },{ "id":"menuitem33" , "name":"分页导航视图" },{ "id":"menuitem34" , "name":"嵌入导航视图" },{ "id":"menuitem176" , "name":"实体表格导航视图" },{ "id":"menuitem177" , "name":"实体列表导航视图" },{ "id":"menuitem178" , "name":"实体卡片导航视图" },{ "id":"menuitem179" , "name":"实体日历导航视图" },{ "id":"menuitem180" , "name":"实体树导航视图" }]},{ "id":"menuitem11" , "name":"其他视图" , "items":[{ "id":"menuitem35" , "name":"图表视图" },{ "id":"menuitem36" , "name":"报表视图" },{ "id":"menuitem98" , "name":"自定义视图" }]},{ "id":"menuitem140" , "name":"单数据视图" , "items":[{ "id":"menuitem8" , "name":"编辑视图" , "items":[{ "id":"menuitem22" , "name":"常规编辑视图" },{ "id":"menuitem23" , "name":"左右编辑视图" },{ "id":"menuitem24" , "name":"分页编辑视图" },{ "id":"menuitem25" , "name":"嵌入编辑视图" }]},{ "id":"menuitem161" , "name":"实体向导视图" },{ "id":"menuitem162" , "name":"实体编辑视图(分页关系)" },{ "id":"menuitem163" , "name":"实体编辑视图(上下关系)" },{ "id":"menuitem164" , "name":"实体编辑视图(左右关系)" },{ "id":"menuitem165" , "name":"实体分页导航视图" },{ "id":"menuitem166" , "name":"实体数据看板视图" },{ "id":"menuitem167" , "name":"实体选项操作视图" }]},{ "id":"menuitem141" , "name":"多数据视图" , "items":[{ "id":"menuitem9" , "name":"列表视图" , "items":[{ "id":"menuitem21" , "name":"左右表格视图" },{ "id":"menuitem20" , "name":"嵌入表格视图" }]},{ "id":"menuitem79" , "name":"表格视图" , "items":[{ "id":"menuitem19" , "name":"常规表格视图" }]},{ "id":"menuitem168" , "name":"实体多表单编辑视图" },{ "id":"menuitem169" , "name":"实体甘特视图" },{ "id":"menuitem170" , "name":"实体日历视图" },{ "id":"menuitem171" , "name":"实体看板视图" },{ "id":"menuitem172" , "name":"实体树表格视图" },{ "id":"menuitem173" , "name":"实体树视图" },{ "id":"menuitem174" , "name":"实体数据视图" },{ "id":"menuitem175" , "name":"实体图表视图" }]}]},{ "id":"menuitem69" , "name":"工作流" },{ "id":"menuitem153" , "name":"逻辑" , "items":[{ "id":"menuitem154" , "name":"应用功能" , "items":[{ "id":"menuitem127" , "name":"打开应用视图" },{ "id":"menuitem147" , "name":"打开HTML页面" },{ "id":"menuitem160" , "name":"执行JavaScript" }]},{ "id":"menuitem155" , "name":"界面行为" , "items":[{ "id":"menuitem181" , "name":"前端界面行为" },{ "id":"menuitem182" , "name":"后台界面行为" }]}]},{ "id":"menuitem2" , "name":"更多" , "items":[{ "id":"menuitem46" , "name":"数据导出导入" },{ "id":"menuitem45" , "name":"数据打印" },{ "id":"menuitem67" , "name":"索引实体" },{ "id":"menuitem68" , "name":"继承实体" },{ "id":"menuitem71" , "name":"多表单" },{ "id":"menuitem70" , "name":"表格主状态" },{ "id":"menuitem148" , "name":"列表主状态" },{ "id":"menuitem183" , "name":"数据主状态" }]},{ "id":"menuitem92" , "name":"其他" , "items":[{ "id":"menuitem93" , "name":"示例实体02示例数据补充" },{ "id":"menuitem100" , "name":"订单示例数据补充" },{ "id":"menuitem103" , "name":"产品示例数据补充" },{ "id":"menuitem106" , "name":"示例实体03示例数据补充" },{ "id":"menuitem113" , "name":"订单类型添加" },{ "id":"menuitem124" , "name":"示例实体01数据补充" },{ "id":"menuitem144" , "name":"客户实体示例数据补充" },{ "id":"menuitem146" , "name":"应用视图数据补充" },{ "id":"menuitem149" , "name":"应用部件数据补充" },{ "id":"menuitem150" , "name":"编辑器数据补充" }]}] }]
}
]
}
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册