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

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

上级 50886e5d
......@@ -1007,7 +1007,7 @@ mock.onGet('v7/main-menuappmenu').reply((config: any) => {
iconcls: '',
icon: '',
textcls: '',
appfunctag: '',
appfunctag: 'AppFunc35',
resourcetag: '',
},
],
......
<template>
<div class='view-container dechartview ibizorder-usr2-chart-view'>
<app-studioaction :viewTitle="$t(model.srfCaption)" viewName="ibizorderusr2chartview"></app-studioaction>
<card class='view-card view-no-toolbar' :bordered="false" :dis-hover="true" >
<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'>
<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_chart
:viewState="viewState"
:viewparams="viewparams"
:context="context"
fetchAction="FetchDefault"
:showBusyIndicator="true"
name="chart"
ref='chart'
@beforeload="chart_beforeload($event)"
@load="chart_load($event)"
@closeview="closeView($event)">
</view_chart>
</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 IBIZOrderService from '@/service/ibizorder/ibizorder-service';
import IBIZOrderAuthService from '@/authservice/ibizorder/ibizorder-auth-service';
import ChartViewEngine from '@engine/view/chart-view-engine';
import IBIZOrderUIService from '@/uiservice/ibizorder/ibizorder-ui-service';
import CodeListService from "@/codelist/codelist-service";
@Component({
components: {
},
})
export default class IBIZOrderUsr2ChartViewBase extends Vue {
/**
* 实体服务对象
*
* @type {IBIZOrderService}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public appEntityService: IBIZOrderService = new IBIZOrderService;
/**
* 实体UI服务对象
*
* @type IBIZOrderUIService
* @memberof IBIZOrderUsr2ChartViewBase
*/
public appUIService: IBIZOrderUIService = new IBIZOrderUIService(this.$store);
/**
* 数据变化
*
* @param {*} val
* @returns {*}
* @memberof IBIZOrderUsr2ChartViewBase
*/
@Emit()
public viewDatasChange(val: any):any {
return val;
}
/**
* 传入视图上下文
*
* @type {string}
* @memberof IBIZOrderUsr2ChartViewBase
*/
@Prop() public viewdata!: string;
/**
* 传入视图参数
*
* @type {string}
* @memberof IBIZOrderUsr2ChartViewBase
*/
@Prop() public viewparam!: string;
/**
* 视图默认使用
*
* @type {boolean}
* @memberof IBIZOrderUsr2ChartViewBase
*/
@Prop({ default: true }) public viewDefaultUsage!: boolean;
/**
* 视图默认使用
*
* @type {string}
* @memberof IBIZOrderUsr2ChartViewBase
*/
@Inject({from:'navModel',default: 'tab'})
public navModel!:string;
/**
* 视图标识
*
* @type {string}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public viewtag: string = '502736ae9280400d7b8f74f057d363ab';
/**
* 自定义视图导航上下文集合
*
* @type {*}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public customViewNavContexts:any ={
};
/**
* 自定义视图导航参数集合
*
* @type {*}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public customViewParams:any ={
};
/**
* 视图模型数据
*
* @type {*}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public model: any = {
srfCaption: 'entities.ibizorder.views.usr2chartview.caption',
srfTitle: 'entities.ibizorder.views.usr2chartview.title',
srfSubTitle: 'entities.ibizorder.views.usr2chartview.subtitle',
dataInfo: ''
}
/**
* 视图参数变化
*
* @param {*} newVal
* @param {*} oldVal
* @memberof IBIZOrderUsr2ChartViewBase
*/
@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 IBIZOrderUsr2ChartViewBase
*/
@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 IBIZOrderUsr2ChartViewBase
*/
public containerModel: any = {
view_chart: { name: 'chart', type: 'CHART' },
view_searchform: { name: 'searchform', type: 'SEARCHFORM' },
wflinks: [],
};
/**
* 计数器刷新
*
* @memberof IBIZOrderUsr2ChartViewBase
*/
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 IBIZOrderUsr2ChartViewBase
*/
public viewState: Subject<ViewState> = new Subject();
/**
* 视图引擎
*
* @public
* @type {Engine}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public engine: ChartViewEngine = new ChartViewEngine();
/**
* 引擎初始化
*
* @public
* @memberof IBIZOrderUsr2ChartViewBase
*/
public engineInit(): void {
this.engine.init({
view: this,
chart: this.$refs.chart,
searchform: this.$refs.searchform,
keyPSDEField: 'ibizorder',
majorPSDEField: 'ibizordername',
isLoadDefault: true,
});
}
/**
* 应用导航服务
*
* @type {*}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public navDataService = NavDataService.getInstance(this.$store);
/**
* 导航服务事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public serviceStateEvent: Subscription | undefined;
/**
* 门户部件状态对象
*
* @type {*}
* @memberof IBIZOrderUsr2ChartViewBase
*/
@Prop() public portletState?: any;
/**
* 门户部件状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public portletStateEvent: Subscription | undefined;
/**
* 应用上下文
*
* @type {*}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public context:any = {};
/**
* 视图参数
*
* @type {*}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public viewparams:any = {};
/**
* 视图缓存数据
*
* @type {*}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public viewCacheData:any;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public counterServiceArray:Array<any> = [];
/**
* 解析视图参数
*
* @public
* @memberof IBIZOrderUsr2ChartViewBase
*/
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,{'ibizorder':inputvalue});
}
//初始化视图唯一标识
Object.assign(this.context,{srfsessionid:this.$util.createUUID()});
this.handleCustomViewData();
//初始化导航数据
this.initNavDataWithRoute();
}
/**
* 处理自定义视图数据
*
* @memberof IBIZOrderUsr2ChartViewBase
*/
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 IBIZOrderUsr2ChartViewBase
*/
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 IBIZOrderUsr2ChartViewBase
*/
public initNavDataWithRoute(data:any = null, isNew:boolean = false, isAlways:boolean = false){
if( isAlways || (this.viewDefaultUsage && Object.is(this.navModel,"route")) ){
this.navDataService.addNavData({id:'ibizorder-usr2-chart-view',tag:this.viewtag,srfkey:isNew ? null : this.context.ibizorder,title:this.$t(this.model.srfCaption),data:data,context:this.context,viewparams:this.viewparams,path:this.$route.fullPath});
}
}
/**
* 初始化导航数据(分页模式)
*
* @memberof IBIZOrderUsr2ChartViewBase
*/
public initNavDataWithTab(data:any = null,isOnlyAdd:boolean = true, isAlways:boolean = false){
if( isAlways || (this.viewDefaultUsage && !Object.is(this.navModel,"route")) ){
this.navDataService.addNavDataByOnly({id:'ibizorder-usr2-chart-view',tag:this.viewtag,srfkey:this.context.ibizorder,title:this.$t(this.model.srfCaption),data:data,context:this.context,viewparams:this.viewparams,path:this.$route.fullPath},isOnlyAdd);
}
}
/**
* Vue声明周期
*
* @memberof IBIZOrderUsr2ChartViewBase
*/
public created() {
this.afterCreated();
}
/**
* 执行created后的逻辑
*
* @memberof IBIZOrderUsr2ChartViewBase
*/
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,'ibizorder-usr2-chart-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,'IBIZOrderUsr2ChartView')){
return;
}
if(Object.is(res.action,'refresh') && _this.refresh && _this.refresh instanceof Function){
_this.refresh();
}
})
}
}
/**
* 销毁之前
*
* @memberof IBIZOrderUsr2ChartViewBase
*/
public beforeDestroy() {
this.$store.commit('viewaction/removeView', this.viewtag);
}
/**
* Vue声明周期(组件初始化完毕)
*
* @memberof IBIZOrderUsr2ChartViewBase
*/
public mounted() {
this.afterMounted();
}
/**
* 执行mounted后的逻辑
*
* @memberof IBIZOrderUsr2ChartViewBase
*/
public afterMounted(){
const _this: any = this;
_this.engineInit();
if (_this.loadModel && _this.loadModel instanceof Function) {
_this.loadModel();
}
}
/**
* chart 部件 beforeload 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZOrderUsr2ChartViewBase
*/
public chart_beforeload($event: any, $event2?: any) {
this.engine.onCtrlEvent('chart', 'beforeload', $event);
}
/**
* chart 部件 load 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZOrderUsr2ChartViewBase
*/
public chart_load($event: any, $event2?: any) {
this.engine.onCtrlEvent('chart', 'load', $event);
}
/**
* searchform 部件 save 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZOrderUsr2ChartViewBase
*/
public searchform_save($event: any, $event2?: any) {
this.engine.onCtrlEvent('searchform', 'save', $event);
}
/**
* searchform 部件 search 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZOrderUsr2ChartViewBase
*/
public searchform_search($event: any, $event2?: any) {
this.engine.onCtrlEvent('searchform', 'search', $event);
}
/**
* searchform 部件 load 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBIZOrderUsr2ChartViewBase
*/
public searchform_load($event: any, $event2?: any) {
this.engine.onCtrlEvent('searchform', 'load', $event);
}
/**
* 关闭视图
*
* @param {any[]} args
* @memberof IBIZOrderUsr2ChartViewBase
*/
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 IBIZOrderUsr2ChartViewBase
*/
public destroyed(){
this.afterDestroyed();
}
/**
* 执行destroyed后的逻辑
*
* @memberof IBIZOrderUsr2ChartViewBase
*/
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 {string}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public query: string = '';
/**
* 是否展开搜索表单
*
* @type {boolean}
* @memberof IBIZOrderUsr2ChartViewBase
*/
public isExpandSearchForm: boolean = false;
/**
* 快速搜索
*
* @param {*} $event
* @memberof IBIZOrderUsr2ChartViewBase
*/
public onSearch($event: any): void {
const refs: any = this.$refs;
if (refs.chart) {
refs.chart.refresh({});
}
}
}
</script>
<style lang='less'>
@import './ibizorder-usr2-chart-view.less';
</style>
\ No newline at end of file
.ibizorder-usr2-chart-view{
position: relative;
}
.ibizorder-usr2-chart-view{
display: block;
> .view-card > .ivu-card-body > .content-container > .app-data-chart {
overflow: auto;
}
}
\ No newline at end of file
<script lang='tsx'>
import { Component } from 'vue-property-decorator';
import IBIZOrderUsr2ChartViewBase from './ibizorder-usr2-chart-view-base.vue';
import view_chart from '@widgets/ibizorder/usr-chart/usr-chart.vue';
import view_searchform from '@widgets/ibizorder/default-searchform/default-searchform.vue';
@Component({
components: {
view_chart,
view_searchform,
},
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 IBIZOrderUsr2ChartView extends IBIZOrderUsr2ChartViewBase {
}
</script>
\ No newline at end of file
......@@ -49,6 +49,7 @@ export const PageComponents = {
Vue.component('ibizorder-pickup-grid-view', () => import('@pages/sample/ibizorder-pickup-grid-view/ibizorder-pickup-grid-view.vue'));
Vue.component('ibizsample0017-f30-edit-view', () => import('@pages/sample/ibizsample0017-f30-edit-view/ibizsample0017-f30-edit-view.vue'));
Vue.component('ibizsample0003-f2-tree-exp-view', () => import('@pages/sample/ibizsample0003-f2-tree-exp-view/ibizsample0003-f2-tree-exp-view.vue'));
Vue.component('ibizorder-usr2-chart-view', () => import('@pages/sample/ibizorder-usr2-chart-view/ibizorder-usr2-chart-view.vue'));
Vue.component('ibizsample0003-sf3-edit-view', () => import('@pages/sample/ibizsample0003-sf3-edit-view/ibizsample0003-sf3-edit-view.vue'));
Vue.component('ibizorder-sf15-grid-view', () => import('@pages/sample/ibizorder-sf15-grid-view/ibizorder-sf15-grid-view.vue'));
Vue.component('ibizorder-line-chart-view', () => import('@pages/sample/ibizorder-line-chart-view/ibizorder-line-chart-view.vue'));
......
......@@ -766,6 +766,20 @@ const router = new Router({
},
component: () => import('@pages/sample/ibizsample0003-f2-tree-exp-view/ibizsample0003-f2-tree-exp-view.vue'),
},
{
path: 'ibizorders/:ibizorder?/usr2chartview/:usr2chartview?',
meta: {
caption: 'entities.ibizorder.views.usr2chartview.caption',
info:'',
parameters: [
{ pathName: 'index', parameterName: 'index' },
{ pathName: 'ibizorders', parameterName: 'ibizorder' },
{ pathName: 'usr2chartview', parameterName: 'usr2chartview' },
],
requireAuth: true,
},
component: () => import('@pages/sample/ibizorder-usr2-chart-view/ibizorder-usr2-chart-view.vue'),
},
{
path: 'ibizsample0003s/:ibizsample0003?/sf3editview/:sf3editview?',
meta: {
......@@ -2660,6 +2674,19 @@ const router = new Router({
},
component: () => import('@pages/sample/ibizsample0017-edit-view/ibizsample0017-edit-view.vue'),
},
{
path: '/ibizorders/:ibizorder?/usr2chartview/:usr2chartview?',
meta: {
caption: 'entities.ibizorder.views.usr2chartview.caption',
info:'',
parameters: [
{ pathName: 'ibizorders', parameterName: 'ibizorder' },
{ pathName: 'usr2chartview', parameterName: 'usr2chartview' },
],
requireAuth: true,
},
component: () => import('@pages/sample/ibizorder-usr2-chart-view/ibizorder-usr2-chart-view.vue'),
},
{
path: '/ibizsoftwaresuits/:ibizsoftwaresuit?/gridview9/:gridview9?',
meta: {
......
......@@ -222,6 +222,7 @@ export const viewstate: any = {
'd9f9f0dede285235e3d0ad5101188d1e',
'ffedffb9c57cb200c275ba15e9100da4',
'84904c93ceea3ab6551555ee20c41e27',
'502736ae9280400d7b8f74f057d363ab',
'6b3607e849c8517fd7ae1cab583f7393',
'41d3da0d37fb0135ace813f1ba06bd39',
'b1256beac1e95915b675893c61559b59',
......@@ -515,6 +516,15 @@ export const viewstate: any = {
refviews: [
],
},
{
viewtag: '502736ae9280400d7b8f74f057d363ab',
viewmodule: 'Sample',
viewname: 'IBIZOrderUsr2ChartView',
viewaction: '',
viewdatachange: false,
refviews: [
],
},
{
viewtag: '5147eb94c8aa1cf6ad57b360e0abde28',
viewmodule: 'Sample',
......
......@@ -647,6 +647,9 @@ export default class MainMenuBase extends Vue implements ControlInterface {
case 'AppFunc5':
this.clickAppFunc5(item);
return;
case 'AppFunc35':
this.clickAppFunc35(item);
return;
case 'AppFunc16':
this.clickAppFunc16(item);
return;
......@@ -1783,6 +1786,29 @@ export default class MainMenuBase extends Vue implements ControlInterface {
})
}
/**
* 图表视图(k线图)
*
* @param {*} [item={}]
* @memberof MainMenu
*/
public clickAppFunc35(item: any = {}) {
const viewparam: any = {};
Object.assign(viewparam, {});
const deResParameters: any[] = [];
const parameters: any[] = [
{ pathName: 'ibizorders', parameterName: 'ibizorder' },
{ pathName: 'usr2chartview', parameterName: 'usr2chartview' },
];
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);
})
}
/**
* 功能名称
*
......
......@@ -1065,7 +1065,7 @@ export default class MainMenuModel {
iconcls: '',
icon: '',
textcls: '',
appfunctag: '',
appfunctag: 'AppFunc35',
resourcetag: '',
authtag:'Web-MainMenu-menuitem44',
},
......
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${P.getPartCode(chartSeriese).code} [in template "TEMPLCODE_en_US" at line 508, column 14]
- Reached through: @ibizindent blank=8 [in template "TEMPLCODE_en_US" at line 506, column 13]
----
部件模板[@CONTROL/CHART]无法获取指定成员[SERIES_CANDLESTICK][CONTROL-BASE.vue]模板
\ No newline at end of file
/**
* Usr 部件模型
*
* @export
* @class UsrModel
*/
export default class UsrModel {
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof UsrChartMode
*/
public getDataItems(): any[] {
return [
{
name:'size',
prop:'size'
},
{
name:'query',
prop:'query'
},
{
name:'page',
prop:'page'
},
{
name:'sort',
prop:'sort'
}
]
}
}
\ No newline at end of file
import { Http,Util,Errorlog } from '@/utils';
import ControlService from '@/widgets/control-service';
import IBIZOrderService from '@/service/ibizorder/ibizorder-service';
import UsrModel from './usr-chart-model';
/**
* Usr 部件服务对象
*
* @export
* @class UsrService
*/
export default class UsrService extends ControlService {
/**
* 订单服务对象
*
* @type {IBIZOrderService}
* @memberof UsrService
*/
public appEntityService: IBIZOrderService = new IBIZOrderService({ $store: this.getStore() });
/**
* 设置从数据模式
*
* @type {boolean}
* @memberof UsrService
*/
public setTempMode(){
this.isTempMode = false;
}
/**
* Creates an instance of UsrService.
*
* @param {*} [opts={}]
* @memberof UsrService
*/
constructor(opts: any = {}) {
super(opts);
this.model = new UsrModel();
}
/**
* 查询数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof UsrService
*/
@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) => {
resolve(response);
}).catch(response => {
reject(response);
});
});
}
}
\ No newline at end of file
// this is less
.app-data-chart {
width: 100%;
height: 100%;
.chart-no-data{
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
i{
margin-right: 5px;
}
}
}
\ No newline at end of file
<script lang='tsx'>
import { Component } from 'vue-property-decorator';
import UsrBase from './usr-chart-base.vue';
@Component({
components: {
}
})
export default class Usr extends UsrBase {
}
</script>
\ No newline at end of file
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册