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

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

上级 ef3e282a
...@@ -109,7 +109,7 @@ import AppInputIp from './components/app-input-ip/app-input-ip.vue'; ...@@ -109,7 +109,7 @@ import AppInputIp from './components/app-input-ip/app-input-ip.vue';
import Loadding from './directive/loadding/loadding'; import Loadding from './directive/loadding/loadding';
import AppColorSpan from './components/app-color-span/app-color-span.vue'; import AppColorSpan from './components/app-color-span/app-color-span.vue';
import AppColorPicker from './components/app-color-picker/app-color-picker.vue'; import AppColorPicker from './components/app-color-picker/app-color-picker.vue';
import AppScrollContainer from './components/layout-container/app-scroll-container/app-scroll-container.vue';
// 全局挂载UI实体服务注册中心 // 全局挂载UI实体服务注册中心
window['uiServiceRegister'] = uiServiceRegister; window['uiServiceRegister'] = uiServiceRegister;
...@@ -234,5 +234,6 @@ export const AppComponents = { ...@@ -234,5 +234,6 @@ export const AppComponents = {
v.directive('loading',Loadding); v.directive('loading',Loadding);
v.component('app-color-span', AppColorSpan); v.component('app-color-span', AppColorSpan);
v.component('app-color-picker', AppColorPicker); v.component('app-color-picker', AppColorPicker);
v.component('app-scroll-container', AppScrollContainer);
}, },
}; };
\ No newline at end of file
.app-scroll-container {
height: 100%;
width: 100%;
border: 1px solid red;
.app-scroll-container__header,
.app-scroll-container__bottom {
width: 100%;
}
.app-scroll-container__middle {
display: flex;
width: 100%;
.app-scroll-container__left,
.app-scroll-container__center,
.app-scroll-container__right {
height: 100%;
}
}
.no-style {
padding: 0;
margin: 0;
}
.overflow-auto {
overflow: auto;
}
}
\ No newline at end of file
<template>
<div class="app-scroll-container">
<div
v-if="containerModel.NORTH"
:style="containerModel.NORTH.style"
class="no-style overflow-auto app-scroll-container__header"
>
<template v-for="name of containerModel.NORTH.name">
<slot :name="name"></slot>
</template>
</div>
<div class="app-scroll-container__middle" :style="middleContainerStyle">
<div
v-if="containerModel.WEST"
:style="containerModel.WEST.style"
class="no-style overflow-auto app-scroll-container__left"
>
<template v-for="name of containerModel.WEST.name">
<slot :name="name"></slot>
</template>
</div>
<div
v-if="containerModel.CENTER"
:style="containerModel.CENTER.style"
class="no-style overflow-auto app-scroll-container__center"
>
<template v-for="name of containerModel.CENTER.name">
<slot :name="name"></slot>
</template>
</div>
<div
v-if="containerModel.EAST"
:style="containerModel.EAST.style"
class="no-style overflow-auto app-scroll-container__right"
>
<template v-for="name of containerModel.EAST.name">
<slot :name="name"></slot>
</template>
</div>
</div>
<div
v-if="containerModel.SOUTH"
:style="containerModel.SOUTH.style"
class="no-style overflow-auto app-scroll-container__bottom"
>
<template v-for="name of containerModel.SOUTH.name">
<slot :name="name"></slot>
</template>
</div>
</div>
</template>
<script lang="ts">
import { Component, Prop, Vue } from 'vue-property-decorator';
@Component({})
export default class AppScrollContainer extends Vue {
/**
* 名称
*
* @type {string}
* @memberof AppScrollContainer
*/
@Prop() public name!: string;
/**
* 布局模型详情
*
* @type {string}
* @memberof AppScrollContainer
*/
@Prop() public layoutModelDetails: any;
/**
* 插槽对象
*
* @memberof AppScrollContainer
*/
public containerModel: any = {};
/**
* 中间区域样式
*
* @memberof AppScrollContainer
*/
public middleContainerStyle: any = {};
/**
* 组件初始化
*
* @memberof AppScrollContainer
*/
public created() {
this.initScrollContainer();
}
/**
* 初始化滚动容器
*
* @memberof AppScrollContainer
*/
public initScrollContainer() {
let minusHeight = 0;
let minusWidth = 0;
const curLayoutModelDetails = this.layoutModelDetails[this.name];
if (curLayoutModelDetails && curLayoutModelDetails.details && curLayoutModelDetails.details.length > 0) {
curLayoutModelDetails.details.forEach((key: string) => {
const { name, layoutWidth, layoutHeight, layoutPos } = this.layoutModelDetails[key];
const style = {};
if (layoutWidth) {
Object.assign(style, { width: `${layoutWidth}px` });
if (layoutPos && (Object.is(layoutPos, 'WEST') || Object.is(layoutPos, 'EAST'))) {
minusWidth += layoutWidth;
}
}
if (layoutHeight) {
Object.assign(style, { height: `${layoutHeight}px` });
if (layoutPos && (Object.is(layoutPos, 'NORTH') || Object.is(layoutPos, 'SOUTH'))) {
minusHeight += layoutHeight;
}
}
if (this.containerModel.hasOwnProperty(layoutPos)) {
Object.assign(this.containerModel[layoutPos], { style });
this.containerModel[layoutPos].name.push(name);
} else {
this.containerModel[layoutPos] = { style, name: [name] };
}
});
}
this.middleContainerStyle.height = minusHeight ? `calc(100% - ${minusHeight}px)` : '100%';
if (this.containerModel.CENTER) {
this.containerModel.CENTER.style.width = minusWidth ? `calc(100% - ${minusWidth}px)` : '100%';
}
console.log(this.containerModel);
}
}
</script>
<style lang='less'>
@import 'app-scroll-container.less';
</style>
\ No newline at end of file
...@@ -24,6 +24,7 @@ export class PanelContainerModel extends PanelDetailModel { ...@@ -24,6 +24,7 @@ export class PanelContainerModel extends PanelDetailModel {
*/ */
public constructor(opts: any = {}) { public constructor(opts: any = {}) {
super(opts); super(opts);
this.details = opts.details;
} }
......
...@@ -65,10 +65,10 @@ ...@@ -65,10 +65,10 @@
/** /**
* 布局高度 * 布局高度
* *
* @type {string} * @type {number}
* @memberof PanelDetailModel * @memberof PanelDetailModel
*/ */
public layoutHeight:string = ''; public layoutHeight:number = 0;
/** /**
* 高度模式 * 高度模式
...@@ -81,10 +81,10 @@ ...@@ -81,10 +81,10 @@
/** /**
* 布局宽度 * 布局宽度
* *
* @type {string} * @type {number}
* @memberof PanelDetailModel * @memberof PanelDetailModel
*/ */
public layoutWidth:string = ''; public layoutWidth:number = 0;
/** /**
* 宽度模式 * 宽度模式
......
...@@ -211,75 +211,75 @@ export default class IndexBase extends Vue { ...@@ -211,75 +211,75 @@ export default class IndexBase extends Vue {
public layoutModelDetails:any = { public layoutModelDetails:any = {
nav_tabs1:new PanelCtrlPosModel({ name: 'nav_tabs1',caption: '标签页导航栏',itemType: 'CTRLPOS',visible: true, nav_tabs1:new PanelCtrlPosModel({ name: 'nav_tabs1',caption: '标签页导航栏',itemType: 'CTRLPOS',visible: true,
disabled: false,layout:'BORDER', disabled: false,layout:'BORDER',
layoutPos:'CENTER',layoutHeight:'70',heightMode:'PX', layoutPos:'CENTER',layoutHeight:70,heightMode:'PX',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this }), spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this }),
nav_pos1:new PanelCtrlPosModel({ name: 'nav_pos1',caption: '导航区占位',itemType: 'CTRLPOS',visible: true, nav_pos1:new PanelCtrlPosModel({ name: 'nav_pos1',caption: '导航区占位',itemType: 'CTRLPOS',visible: true,
disabled: false,layout:'BORDER', disabled: false,layout:'BORDER',
layoutPos:'CENTER',layoutHeight:'',heightMode:'', layoutPos:'CENTER',layoutHeight:0,heightMode:'',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this }), spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this }),
container_scroll_main1:new PanelContainerModel({ name: 'container_scroll_main1',caption: '面板容器',itemType: 'CONTAINER',visible: true, container_scroll_main1:new PanelContainerModel({ name: 'container_scroll_main1',caption: '面板容器',itemType: 'CONTAINER',visible: true,
disabled: false,layout:'BORDER', disabled: false,layout:'BORDER',
layoutPos:'CENTER',layoutHeight:'',heightMode:'', layoutPos:'CENTER',layoutHeight:0,heightMode:'',
layoutWidth:'80',widthMode:'PERCENTAGE',spacingBottom:'',spacingLeft:'', layoutWidth:80,widthMode:'PERCENTAGE',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this, spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this,
details:['nav_tabs1','nav_pos1']}), details:['nav_tabs1','nav_pos1']}),
appmenu1:new PanelCtrlPosModel({ name: 'appmenu1',caption: '首页菜单',itemType: 'CTRLPOS',visible: true, appmenu1:new PanelCtrlPosModel({ name: 'appmenu1',caption: '首页菜单',itemType: 'CTRLPOS',visible: true,
disabled: false,layout:'BORDER', disabled: false,layout:'BORDER',
layoutPos:'CENTER',layoutHeight:'',heightMode:'', layoutPos:'CENTER',layoutHeight:0,heightMode:'',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this }), spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this }),
container_scroll_left1:new PanelContainerModel({ name: 'container_scroll_left1',caption: '面板容器',itemType: 'CONTAINER',visible: true, container_scroll_left1:new PanelContainerModel({ name: 'container_scroll_left1',caption: '面板容器',itemType: 'CONTAINER',visible: true,
disabled: false,layout:'BORDER', disabled: false,layout:'BORDER',
layoutPos:'WEST',layoutHeight:'',heightMode:'', layoutPos:'WEST',layoutHeight:0,heightMode:'',
layoutWidth:'20',widthMode:'PERCENTAGE',spacingBottom:'',spacingLeft:'', layoutWidth:20,widthMode:'PERCENTAGE',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this, spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this,
details:['appmenu1']}), details:['appmenu1']}),
app_apptitle:new PanelFieldModel({ name: 'app_apptitle',caption: '应用标题',itemType: 'FIELD',visible: true, app_apptitle:new PanelFieldModel({ name: 'app_apptitle',caption: '应用标题',itemType: 'FIELD',visible: true,
disabled: false,layout:'SIMPLEFLEX', disabled: false,layout:'SIMPLEFLEX',
layoutPos:'',layoutHeight:'',heightMode:'', layoutPos:'',layoutHeight:0,heightMode:'',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this }), spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this }),
container1:new PanelContainerModel({ name: 'container1',caption: '面板容器',itemType: 'CONTAINER',visible: true, container1:new PanelContainerModel({ name: 'container1',caption: '面板容器',itemType: 'CONTAINER',visible: true,
disabled: false,layout:'SIMPLEFLEX', disabled: false,layout:'SIMPLEFLEX',
layoutPos:'',layoutHeight:'',heightMode:'', layoutPos:'',layoutHeight:0,heightMode:'',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this, spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this,
details:['app_apptitle']}), details:['app_apptitle']}),
container2:new PanelContainerModel({ name: 'container2',caption: '面板容器',itemType: 'CONTAINER',visible: true, container2:new PanelContainerModel({ name: 'container2',caption: '面板容器',itemType: 'CONTAINER',visible: true,
disabled: false,layout:'SIMPLEFLEX', disabled: false,layout:'SIMPLEFLEX',
layoutPos:'',layoutHeight:'',heightMode:'', layoutPos:'',layoutHeight:0,heightMode:'',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this, spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this,
details:[]}), details:[]}),
auth_userinfo1:new PanelCtrlPosModel({ name: 'auth_userinfo1',caption: '用户信息',itemType: 'CTRLPOS',visible: true, auth_userinfo1:new PanelCtrlPosModel({ name: 'auth_userinfo1',caption: '用户信息',itemType: 'CTRLPOS',visible: true,
disabled: false,layout:'SIMPLEFLEX', disabled: false,layout:'SIMPLEFLEX',
layoutPos:'',layoutHeight:'',heightMode:'', layoutPos:'',layoutHeight:0,heightMode:'',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this }), spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this }),
container3:new PanelContainerModel({ name: 'container3',caption: '面板容器',itemType: 'CONTAINER',visible: true, container3:new PanelContainerModel({ name: 'container3',caption: '面板容器',itemType: 'CONTAINER',visible: true,
disabled: false,layout:'SIMPLEFLEX', disabled: false,layout:'SIMPLEFLEX',
layoutPos:'',layoutHeight:'',heightMode:'', layoutPos:'',layoutHeight:0,heightMode:'',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this, spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this,
details:['auth_userinfo1']}), details:['auth_userinfo1']}),
container_grid1:new PanelContainerModel({ name: 'container_grid1',caption: '栅格容器',itemType: 'CONTAINER',visible: true, container_grid1:new PanelContainerModel({ name: 'container_grid1',caption: '栅格容器',itemType: 'CONTAINER',visible: true,
disabled: false,layout:'BORDER', disabled: false,layout:'BORDER',
layoutPos:'CENTER',layoutHeight:'',heightMode:'', layoutPos:'CENTER',layoutHeight:0,heightMode:'',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this, spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this,
details:['container1','container2','container3']}), details:['container1','container2','container3']}),
container_scroll_header1:new PanelContainerModel({ name: 'container_scroll_header1',caption: '面板容器',itemType: 'CONTAINER',visible: true, container_scroll_header1:new PanelContainerModel({ name: 'container_scroll_header1',caption: '面板容器',itemType: 'CONTAINER',visible: true,
disabled: false,layout:'BORDER', disabled: false,layout:'BORDER',
layoutPos:'NORTH',layoutHeight:'80',heightMode:'PX', layoutPos:'NORTH',layoutHeight:80,heightMode:'PX',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this, spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this,
details:['container_grid1']}), details:['container_grid1']}),
container_scroll1:new PanelContainerModel({ name: 'container_scroll1',caption: '滚动条容器',itemType: 'CONTAINER',visible: true, container_scroll1:new PanelContainerModel({ name: 'container_scroll1',caption: '滚动条容器',itemType: 'CONTAINER',visible: true,
disabled: false,layout:'FLEX', disabled: false,layout:'FLEX',
layoutPos:'',layoutHeight:'',heightMode:'', layoutPos:'',layoutHeight:0,heightMode:'',
layoutWidth:'',widthMode:'',spacingBottom:'',spacingLeft:'', layoutWidth:0,widthMode:'',spacingBottom:'',spacingLeft:'',
spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this, spacingRight:'',spacingTop:'',hAlignSelf:'',vAlignSelf:'',panel: this,
details:['container_scroll_main1','container_scroll_left1','container_scroll_header1']}) details:['container_scroll_main1','container_scroll_left1','container_scroll_header1']})
}; };
...@@ -815,6 +815,7 @@ export default class IndexBase extends Vue { ...@@ -815,6 +815,7 @@ export default class IndexBase extends Vue {
let left_move :any= document.getElementById("left_move"); let left_move :any= document.getElementById("left_move");
let right_move :any= document.getElementById("right_move"); let right_move :any= document.getElementById("right_move");
let movebox :any= document.getElementById("movebox"); let movebox :any= document.getElementById("movebox");
if(left_move && right_move && move_axis && movebox){
let leftWidth :number = parseInt(left_move.style.width); let leftWidth :number = parseInt(left_move.style.width);
move_axis.onmousedown = (e:any) =>{ move_axis.onmousedown = (e:any) =>{
let startX = e.clientX; let startX = e.clientX;
...@@ -846,7 +847,7 @@ export default class IndexBase extends Vue { ...@@ -846,7 +847,7 @@ export default class IndexBase extends Vue {
move_axis.setCapture && move_axis.setCapture(); move_axis.setCapture && move_axis.setCapture();
return false; return false;
} }
}
} }
} }
......
...@@ -94,8 +94,8 @@ export default class BookCalendarMajorStateService extends ControlService { ...@@ -94,8 +94,8 @@ export default class BookCalendarMajorStateService extends ControlService {
}); });
// 排序 // 排序
_data.sort((a:any, b:any)=>{ _data.sort((a:any, b:any)=>{
let dateA = new Date(Date.parse(a.start?.replace(/-/g, "/"))); let dateA = new Date(Date.parse(a.start.replace(/-/g, "/")));
let dateB = new Date(Date.parse(b.start?.replace(/-/g, "/"))); let dateB = new Date(Date.parse(b.start.replace(/-/g, "/")));
return dateA > dateB ? 1 : -1 ; return dateA > dateB ? 1 : -1 ;
}); });
let result = {status: 200, data: _data}; let result = {status: 200, data: _data};
......
...@@ -94,8 +94,8 @@ export default class CustomCalendarService extends ControlService { ...@@ -94,8 +94,8 @@ export default class CustomCalendarService extends ControlService {
}); });
// 排序 // 排序
_data.sort((a:any, b:any)=>{ _data.sort((a:any, b:any)=>{
let dateA = new Date(Date.parse(a.start?.replace(/-/g, "/"))); let dateA = new Date(Date.parse(a.start.replace(/-/g, "/")));
let dateB = new Date(Date.parse(b.start?.replace(/-/g, "/"))); let dateB = new Date(Date.parse(b.start.replace(/-/g, "/")));
return dateA > dateB ? 1 : -1 ; return dateA > dateB ? 1 : -1 ;
}); });
let result = {status: 200, data: _data}; let result = {status: 200, data: _data};
......
...@@ -663,7 +663,7 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -663,7 +663,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/ */
public load(opt: any = {}): void { public load(opt: any = {}): void {
if(!this.loadAction){ if(!this.loadAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKUsr9GridView' + (this.$t('app.searchForm.notConfig.loadAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKUsr5GridView' + (this.$t('app.searchForm.notConfig.loadAction') as string) });
return; return;
} }
const arg: any = { ...opt }; const arg: any = { ...opt };
...@@ -699,7 +699,7 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -699,7 +699,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/ */
public loadDraft(opt: any = {},mode?:string): void { public loadDraft(opt: any = {},mode?:string): void {
if(!this.loaddraftAction){ if(!this.loaddraftAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKUsr9GridView' + (this.$t('app.searchForm.notConfig.loaddraftAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKUsr5GridView' + (this.$t('app.searchForm.notConfig.loaddraftAction') as string) });
return; return;
} }
const arg: any = { ...opt } ; const arg: any = { ...opt } ;
......
...@@ -844,7 +844,7 @@ export default class GroupByCodelistKanBanBase extends Vue implements ControlInt ...@@ -844,7 +844,7 @@ export default class GroupByCodelistKanBanBase extends Vue implements ControlInt
* @memberof GroupByCodelistKanBanBase * @memberof GroupByCodelistKanBanBase
*/ */
public uiAction(tag: any, $event: any, group: any) { public uiAction(tag: any, $event: any, group: any) {
let row = this.selections.length > 0 && group?.items.includes(this.selections[0])? this.selections[0] : {}; let row = this.selections.length > 0 && group && group.items.includes(this.selections[0])? this.selections[0] : {};
if(!row.hasOwnProperty('srfgroup')){ if(!row.hasOwnProperty('srfgroup')){
Object.assign(row,{srfgroup: group? group.value:null}); Object.assign(row,{srfgroup: group? group.value:null});
} }
......
...@@ -844,7 +844,7 @@ export default class HasPanelKanBanBase extends Vue implements ControlInterface ...@@ -844,7 +844,7 @@ export default class HasPanelKanBanBase extends Vue implements ControlInterface
* @memberof HasPanelKanBanBase * @memberof HasPanelKanBanBase
*/ */
public uiAction(tag: any, $event: any, group: any) { public uiAction(tag: any, $event: any, group: any) {
let row = this.selections.length > 0 && group?.items.includes(this.selections[0])? this.selections[0] : {}; let row = this.selections.length > 0 && group && group.items.includes(this.selections[0])? this.selections[0] : {};
if(!row.hasOwnProperty('srfgroup')){ if(!row.hasOwnProperty('srfgroup')){
Object.assign(row,{srfgroup: group? group.value:null}); Object.assign(row,{srfgroup: group? group.value:null});
} }
......
...@@ -94,8 +94,8 @@ export default class IBIZBOOKMONTHService extends ControlService { ...@@ -94,8 +94,8 @@ export default class IBIZBOOKMONTHService extends ControlService {
}); });
// 排序 // 排序
_data.sort((a:any, b:any)=>{ _data.sort((a:any, b:any)=>{
let dateA = new Date(Date.parse(a.start?.replace(/-/g, "/"))); let dateA = new Date(Date.parse(a.start.replace(/-/g, "/")));
let dateB = new Date(Date.parse(b.start?.replace(/-/g, "/"))); let dateB = new Date(Date.parse(b.start.replace(/-/g, "/")));
return dateA > dateB ? 1 : -1 ; return dateA > dateB ? 1 : -1 ;
}); });
let result = {status: 200, data: _data}; let result = {status: 200, data: _data};
......
...@@ -94,8 +94,8 @@ export default class IBIZBOOKPANELService extends ControlService { ...@@ -94,8 +94,8 @@ export default class IBIZBOOKPANELService extends ControlService {
}); });
// 排序 // 排序
_data.sort((a:any, b:any)=>{ _data.sort((a:any, b:any)=>{
let dateA = new Date(Date.parse(a.start?.replace(/-/g, "/"))); let dateA = new Date(Date.parse(a.start.replace(/-/g, "/")));
let dateB = new Date(Date.parse(b.start?.replace(/-/g, "/"))); let dateB = new Date(Date.parse(b.start.replace(/-/g, "/")));
return dateA > dateB ? 1 : -1 ; return dateA > dateB ? 1 : -1 ;
}); });
let result = {status: 200, data: _data}; let result = {status: 200, data: _data};
......
...@@ -94,8 +94,8 @@ export default class IBIZBOOKTIMELINEService extends ControlService { ...@@ -94,8 +94,8 @@ export default class IBIZBOOKTIMELINEService extends ControlService {
}); });
// 排序 // 排序
_data.sort((a:any, b:any)=>{ _data.sort((a:any, b:any)=>{
let dateA = new Date(Date.parse(a.start?.replace(/-/g, "/"))); let dateA = new Date(Date.parse(a.start.replace(/-/g, "/")));
let dateB = new Date(Date.parse(b.start?.replace(/-/g, "/"))); let dateB = new Date(Date.parse(b.start.replace(/-/g, "/")));
return dateA > dateB ? 1 : -1 ; return dateA > dateB ? 1 : -1 ;
}); });
let result = {status: 200, data: _data}; let result = {status: 200, data: _data};
......
...@@ -882,7 +882,7 @@ export default class InterFuncKanbanBase extends Vue implements ControlInterface ...@@ -882,7 +882,7 @@ export default class InterFuncKanbanBase extends Vue implements ControlInterface
* @memberof InterFuncKanbanBase * @memberof InterFuncKanbanBase
*/ */
public uiAction(tag: any, $event: any, group: any) { public uiAction(tag: any, $event: any, group: any) {
let row = this.selections.length > 0 && group?.items.includes(this.selections[0])? this.selections[0] : {}; let row = this.selections.length > 0 && group && group.items.includes(this.selections[0])? this.selections[0] : {};
if(!row.hasOwnProperty('srfgroup')){ if(!row.hasOwnProperty('srfgroup')){
Object.assign(row,{srfgroup: group? group.value:null}); Object.assign(row,{srfgroup: group? group.value:null});
} }
......
...@@ -94,8 +94,8 @@ export default class OrderCalendarNavigationService extends ControlService { ...@@ -94,8 +94,8 @@ export default class OrderCalendarNavigationService extends ControlService {
}); });
// 排序 // 排序
_data.sort((a:any, b:any)=>{ _data.sort((a:any, b:any)=>{
let dateA = new Date(Date.parse(a.start?.replace(/-/g, "/"))); let dateA = new Date(Date.parse(a.start.replace(/-/g, "/")));
let dateB = new Date(Date.parse(b.start?.replace(/-/g, "/"))); let dateB = new Date(Date.parse(b.start.replace(/-/g, "/")));
return dateA > dateB ? 1 : -1 ; return dateA > dateB ? 1 : -1 ;
}); });
let result = {status: 200, data: _data}; let result = {status: 200, data: _data};
......
...@@ -94,8 +94,8 @@ export default class OrderCalendarTimelineNavigationService extends ControlServi ...@@ -94,8 +94,8 @@ export default class OrderCalendarTimelineNavigationService extends ControlServi
}); });
// 排序 // 排序
_data.sort((a:any, b:any)=>{ _data.sort((a:any, b:any)=>{
let dateA = new Date(Date.parse(a.start?.replace(/-/g, "/"))); let dateA = new Date(Date.parse(a.start.replace(/-/g, "/")));
let dateB = new Date(Date.parse(b.start?.replace(/-/g, "/"))); let dateB = new Date(Date.parse(b.start.replace(/-/g, "/")));
return dateA > dateB ? 1 : -1 ; return dateA > dateB ? 1 : -1 ;
}); });
let result = {status: 200, data: _data}; let result = {status: 200, data: _data};
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册