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

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

上级 2b3611cb
......@@ -911,6 +911,14 @@
"viewname": "IBIZSample0003SPickupTreeView",
"viewtag": "a4333795f033ac3e573ec567d40ab208"
},
"ibizordercalendarexpview": {
"title": "订单日历导航视图",
"caption": "订单",
"viewtype": "DECALENDAREXPVIEW",
"viewmodule": "Sample",
"viewname": "IBIZOrderCalendarExpView",
"viewtag": "a682806a2655b566842d5495e43a06f3"
},
"ibizbookhaspanelkanbanview": {
"title": "图书看板视图(嵌入视图面板)",
"caption": "图书",
......
......@@ -255,6 +255,7 @@ export default {
menuitem114: "列表导航",
menuitem136: "树导航",
menuitem137: "卡片导航",
menuitem138: "日历导航",
menuitem129: "选项操作",
menuitem130: "选项操作视图",
menuitem131: "表格选项操作",
......
......@@ -255,6 +255,7 @@ export default {
menuitem114: "列表导航",
menuitem136: "树导航",
menuitem137: "卡片导航",
menuitem138: "日历导航",
menuitem129: "选项操作",
menuitem130: "选项操作视图",
menuitem131: "表格选项操作",
......
......@@ -149,6 +149,10 @@ export default {
caption: "订单",
title: "订单编辑视图",
},
calendarexpview: {
caption: "订单",
title: "订单日历导航视图",
},
f8editview: {
caption: "表单动态启用",
title: "表单动态启用",
......@@ -1989,4 +1993,9 @@ export default {
uiactions: {
},
},
ordercalendarnavigation_calendar: {
nodata:"",
uiactions: {
},
},
};
\ No newline at end of file
......@@ -148,6 +148,10 @@ export default {
caption: "订单",
title: "订单编辑视图",
},
calendarexpview: {
caption: "订单",
title: "订单日历导航视图",
},
f8editview: {
caption: "表单动态启用",
title: "表单动态启用",
......@@ -1988,4 +1992,9 @@ export default {
uiactions: {
},
},
ordercalendarnavigation_calendar: {
nodata:"",
uiactions: {
},
},
};
\ No newline at end of file
......@@ -1697,6 +1697,24 @@ mock.onGet('v7/main-menuappmenu').reply((config: any) => {
textcls: '',
appfunctag: 'AppFunc58',
resourcetag: '',
},
{
id: 'CD49E20C-A821-4058-9EF7-5061059DAD1B',
name: 'menuitem138',
text: '日历导航',
type: 'MENUITEM',
counterid: '',
tooltip: '日历导航',
expanded: false,
separator: false,
hidden: false,
hidesidebar: false,
opendefault: false,
iconcls: '',
icon: '',
textcls: '',
appfunctag: 'AppFunc59',
resourcetag: '',
},
],
},
......
......@@ -919,6 +919,14 @@ mock.onGet('./assets/json/view-config.json').reply((config: any) => {
"viewname": "IBIZSample0003SPickupTreeView",
"viewtag": "a4333795f033ac3e573ec567d40ab208"
},
"ibizordercalendarexpview": {
"title": "订单日历导航视图",
"caption": "订单",
"viewtype": "DECALENDAREXPVIEW",
"viewmodule": "Sample",
"viewname": "IBIZOrderCalendarExpView",
"viewtag": "a682806a2655b566842d5495e43a06f3"
},
"ibizbookhaspanelkanbanview": {
"title": "图书看板视图(嵌入视图面板)",
"caption": "图书",
......
.ibizorder-calendar-exp-view{
position: relative;
}
.ibizorder-calendar-exp-view{
display: block;
}
\ No newline at end of file
<script lang='tsx'>
import { Component } from 'vue-property-decorator';
import IBIZOrderCalendarExpViewBase from './ibizorder-calendar-exp-view-base.vue';
import view_calendarexpbar from '@widgets/ibizorder/calendar-exp-viewcalendarexpbar-calendarexpbar/calendar-exp-viewcalendarexpbar-calendarexpbar.vue';
@Component({
components: {
view_calendarexpbar,
},
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 IBIZOrderCalendarExpView extends IBIZOrderCalendarExpViewBase {
}
</script>
\ No newline at end of file
......@@ -93,6 +93,7 @@ export const PageComponents = {
Vue.component('ibizbookusr4-data-view', () => import('@pages/sample/ibizbookusr4-data-view/ibizbookusr4-data-view.vue'));
Vue.component('ibizorder-area-chart-view', () => import('@pages/sample/ibizorder-area-chart-view/ibizorder-area-chart-view.vue'));
Vue.component('ibizorder-sf20-grid-view', () => import('@pages/sample/ibizorder-sf20-grid-view/ibizorder-sf20-grid-view.vue'));
Vue.component('ibizorder-calendar-exp-view', () => import('@pages/sample/ibizorder-calendar-exp-view/ibizorder-calendar-exp-view.vue'));
Vue.component('ibizorder-grid-view9', () => import('@pages/sample/ibizorder-grid-view9/ibizorder-grid-view9.vue'));
Vue.component('ibizsample0003-spickup-view2', () => import('@pages/sample/ibizsample0003-spickup-view2/ibizsample0003-spickup-view2.vue'));
Vue.component('ibizorder-odsp-w10-wfgrid-view', () => import('@pages/sample/ibizorder-odsp-w10-wfgrid-view/ibizorder-odsp-w10-wfgrid-view.vue'));
......
......@@ -1517,6 +1517,20 @@ const router = new Router({
},
component: () => import('@pages/sample/ibizorder-sf20-grid-view/ibizorder-sf20-grid-view.vue'),
},
{
path: 'ibizorders/:ibizorder?/calendarexpview/:calendarexpview?',
meta: {
caption: 'entities.ibizorder.views.calendarexpview.caption',
info:'',
parameters: [
{ pathName: 'index', parameterName: 'index' },
{ pathName: 'ibizorders', parameterName: 'ibizorder' },
{ pathName: 'calendarexpview', parameterName: 'calendarexpview' },
],
requireAuth: true,
},
component: () => import('@pages/sample/ibizorder-calendar-exp-view/ibizorder-calendar-exp-view.vue'),
},
{
path: 'ibizorders/:ibizorder?/gridview9/:gridview9?',
meta: {
......@@ -4045,6 +4059,19 @@ const router = new Router({
},
component: () => import('@pages/sample/ibizsample0003-spickup-tree-view/ibizsample0003-spickup-tree-view.vue'),
},
{
path: '/ibizorders/:ibizorder?/calendarexpview/:calendarexpview?',
meta: {
caption: 'entities.ibizorder.views.calendarexpview.caption',
info:'',
parameters: [
{ pathName: 'ibizorders', parameterName: 'ibizorder' },
{ pathName: 'calendarexpview', parameterName: 'calendarexpview' },
],
requireAuth: true,
},
component: () => import('@pages/sample/ibizorder-calendar-exp-view/ibizorder-calendar-exp-view.vue'),
},
{
path: '/ibizbooks/:ibizbook?/haspanelkanbanview/:haspanelkanbanview?',
meta: {
......
......@@ -200,8 +200,8 @@ export const viewstate: any = {
'e7441fa67d425df343d996c745fb5d6b',
'2ccd29eeaeded3ea5a713a19cd67a83e',
'aa68a83577209ff0ec3864aec4e194f2',
'd69d223e4d3aeb8d947ac9b9ddc60a7e',
'692ede21641dfdb7075ede69d7c4ad33',
'd69d223e4d3aeb8d947ac9b9ddc60a7e',
'b1591dc4d651536bceb32b60310fd2a5',
'19d36909f837de28880553dc9a190922',
'3ebf0cd640e39a4e7efe30ec1cf32b43',
......@@ -240,6 +240,7 @@ export const viewstate: any = {
'd8a6379b9ddbd161045a288aba0890b6',
'd1f311d51e800e95e9b10c49a8b49b5a',
'f94df735642ce85ebb2fe3816c4dc77b',
'a682806a2655b566842d5495e43a06f3',
'ac9add3724d90fba46e7298ac051fa5f',
'16b68282950fb352dfe27e94bda47304',
'2bf74d5d66fa6d8d38b21b090586529b',
......@@ -1099,6 +1100,16 @@ export const viewstate: any = {
refviews: [
],
},
{
viewtag: 'a682806a2655b566842d5495e43a06f3',
viewmodule: 'Sample',
viewname: 'IBIZOrderCalendarExpView',
viewaction: '',
viewdatachange: false,
refviews: [
'b4db5cb272d2da535285852bc436e9de',
],
},
{
viewtag: 'a6cb9804bfd40d2542ae2c44e0cc3331',
viewmodule: 'Sample',
......
......@@ -127,6 +127,7 @@ export default class IBIZOrderUIServiceBase extends UIService {
this.allViewMap.set(':',{viewname:'piechartview',srfappde:'ibizorders',component:'ibizorder-pie-chart-view'});
this.allViewMap.set('WFMDATAVIEW:ODSP:W:10',{viewname:'odsp_w10_wfgridview',srfappde:'ibizorders',component:'ibizorder-odsp-w10-wfgrid-view'});
this.allViewMap.set(':',{viewname:'sf3editview',srfappde:'ibizorders',component:'ibizorder-sf3-edit-view'});
this.allViewMap.set(':',{viewname:'calendarexpview',srfappde:'ibizorders',component:'ibizorder-calendar-exp-view'});
this.allViewMap.set(':',{viewname:'f8editview',srfappde:'ibizorders',component:'ibizorder-f8-edit-view'});
this.allViewMap.set(':',{viewname:'odsp_wfexpview',srfappde:'ibizorders',component:'ibizorder-odsp-wfexp-view'});
this.allViewMap.set('WFMDATAVIEW:ODSP:D:30',{viewname:'odsp_d30_wfgridview',srfappde:'ibizorders',component:'ibizorder-odsp-d30-wfgrid-view'});
......
......@@ -713,6 +713,9 @@ export default class MainMenuBase extends Vue implements ControlInterface {
case 'Auto371':
this.clickAuto371(item);
return;
case 'AppFunc59':
this.clickAppFunc59(item);
return;
case 'Auto296':
this.clickAuto296(item);
return;
......@@ -2343,6 +2346,29 @@ export default class MainMenuBase extends Vue implements ControlInterface {
})
}
/**
* 功能名称
*
* @param {*} [item={}]
* @memberof MainMenu
*/
public clickAppFunc59(item: any = {}) {
const viewparam: any = {};
Object.assign(viewparam, {});
const deResParameters: any[] = [];
const parameters: any[] = [
{ pathName: 'ibizorders', parameterName: 'ibizorder' },
{ pathName: 'calendarexpview', parameterName: 'calendarexpview' },
];
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);
})
}
/**
* 索引实体
*
......
......@@ -1793,6 +1793,25 @@ export default class MainMenuModel {
appfunctag: 'AppFunc58',
resourcetag: '',
authtag:'Web-MainMenu-menuitem137',
},
{
id: 'CD49E20C-A821-4058-9EF7-5061059DAD1B',
name: 'menuitem138',
text: '日历导航',
type: 'MENUITEM',
counterid: '',
tooltip: '日历导航',
expanded: false,
separator: false,
hidden: false,
hidesidebar: false,
opendefault: false,
iconcls: '',
icon: '',
textcls: '',
appfunctag: 'AppFunc59',
resourcetag: '',
authtag:'Web-MainMenu-menuitem138',
},
],
},
......
/**
* CalendarExpViewcalendarexpbar 部件模型
*
* @export
* @class CalendarExpViewcalendarexpbarModel
*/
export default class CalendarExpViewcalendarexpbarModel {
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof CalendarExpViewcalendarexpbarCalendarexpbarMode
*/
public getDataItems(): any[] {
return [
]
}
}
\ 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 CalendarExpViewcalendarexpbarModel from './calendar-exp-viewcalendarexpbar-calendarexpbar-model';
/**
* CalendarExpViewcalendarexpbar 部件服务对象
*
* @export
* @class CalendarExpViewcalendarexpbarService
*/
export default class CalendarExpViewcalendarexpbarService extends ControlService {
/**
* 订单服务对象
*
* @type {IBIZOrderService}
* @memberof CalendarExpViewcalendarexpbarService
*/
public appEntityService: IBIZOrderService = new IBIZOrderService({ $store: this.getStore() });
/**
* 设置从数据模式
*
* @type {boolean}
* @memberof CalendarExpViewcalendarexpbarService
*/
public setTempMode(){
this.isTempMode = false;
}
/**
* Creates an instance of CalendarExpViewcalendarexpbarService.
*
* @param {*} [opts={}]
* @memberof CalendarExpViewcalendarexpbarService
*/
constructor(opts: any = {}) {
super(opts);
this.model = new CalendarExpViewcalendarexpbarModel();
}
}
\ No newline at end of file
.app-calendar-exp-bar {
> .ivu-split-horizontal {
> .ivu-split-trigger-con {
height: 100%;
width: 1px;
}
> .ivu-split-pane {
> div {
height: 100%;
overflow: auto;
display: flex;
flex-direction: column;
.calendar-exp-bar-header {
line-height: 50px;
border-bottom: 1px solid #ddd;
>div {
font-size: 18px;
i {
font-size: 20px;
margin-top: -2px;
}
}
}
.container-header{
display: flex;
justify-content: space-between;
align-items: center;
.search-container {
width: 30%;
height: 48px;
padding: 10px;
min-width: 200px;
max-width: 400px;
}
.toolbar-container{
padding: 4px;
display: flex;
flex-wrap: wrap;
align-items: center;
}
}
.calendar-exp-bar-content {
height: calc(100% - 40px);
overflow: auto;
padding: 16px 0;
margin-bottom: 10px;
}
.calendar-exp-bar-content2 {
height: 100%;
overflow: auto;
flex-grow: 1;
}
}
}
> .right-pane.ivu-split-pane {
> div {
padding-left: 10px;
}
}
> .left-pane.ivu-split-pane {
padding-right: 10px;
}
}
> .ivu-split-vertical{
> .ivu-split-pane {
> div {
height: 100%;
overflow: auto;
display: flex;
flex-direction: column;
.calendar-exp-bar-header {
line-height: 50px;
border-bottom: 1px solid #ddd;
>div {
font-size: 18px;
i {
font-size: 20px;
margin-top: -2px;
}
}
}
.container-header{
display: flex;
justify-content: space-between;
align-items: center;
.search-container {
width: 30%;
height: 48px;
padding: 10px 10px 10px 0;
min-width: 200px;
max-width: 400px;
}
.toolbar-container{
padding: 4px;
}
}
.calendar-exp-bar-content {
height: calc(100% - 40px);
overflow: auto;
margin-bottom: 10px;
}
.calendar-exp-bar-content2 {
height: 100%;
overflow: auto;
flex-grow: 1;
}
}
}
> .top-pane.ivu-split-pane {
> div {
padding-bottom: 10px;
}
}
> .bottom-pane.ivu-split-pane {
padding-top: 10px;
}
}
}
// this is less
<script lang='tsx'>
import { Component } from 'vue-property-decorator';
import CalendarExpViewcalendarexpbarBase from './calendar-exp-viewcalendarexpbar-calendarexpbar-base.vue';
import view_calendarexpbar_calendar from '@widgets/ibizorder/order-calendar-navigation-calendar/order-calendar-navigation-calendar.vue';
@Component({
components: {
view_calendarexpbar_calendar,
}
})
export default class CalendarExpViewcalendarexpbar extends CalendarExpViewcalendarexpbarBase {
}
</script>
\ No newline at end of file
/**
* OrderCalendarNavigation 部件模型
*
* @export
* @class OrderCalendarNavigationModel
*/
export default class OrderCalendarNavigationModel {
/**
* 日历项类型
*
* @returns {any[]}
* @memberof OrderCalendarNavigationCalendarexpbar_calendarMode
*/
public itemType: string = "";
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof OrderCalendarNavigationCalendarexpbar_calendarMode
*/
public getDataItems(): any[] {
let dataItems: any = [
// 前端新增修改标识,新增为"0",修改为"1"或未设值
{
name: 'srffrontuf',
prop: 'srffrontuf',
dataType: 'TEXT',
},
{
name: 'color',
},
{
name: 'textColor',
},
{
name: 'itemType',
},
{
name: 'query',
prop: 'query',
},
];
switch(this.itemType){
case "item1":
dataItems = [...dataItems,
{
name: 'ibizorder',
prop: 'ibizorderid'
},
{
name: 'title',
prop: 'ibizordername'
},
{
name:'start',
prop:'starttime'
},
{
name:'end',
prop:'endtime'
},
];
break;
}
return dataItems;
}
}
\ 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 OrderCalendarNavigationModel from './order-calendar-navigation-calendar-model';
/**
* OrderCalendarNavigation 部件服务对象
*
* @export
* @class OrderCalendarNavigationService
*/
export default class OrderCalendarNavigationService extends ControlService {
/**
* 订单服务对象
*
* @type {IBIZOrderService}
* @memberof OrderCalendarNavigationService
*/
public appEntityService: IBIZOrderService = new IBIZOrderService({ $store: this.getStore() });
/**
* 设置从数据模式
*
* @type {boolean}
* @memberof OrderCalendarNavigationService
*/
public setTempMode(){
this.isTempMode = false;
}
/**
* Creates an instance of OrderCalendarNavigationService.
*
* @param {*} [opts={}]
* @memberof OrderCalendarNavigationService
*/
constructor(opts: any = {}) {
super(opts);
this.model = new OrderCalendarNavigationModel();
}
/**
* 事件配置集合
*
* @public
* @type {any[]}
* @memberof OrderCalendarNavigation
*/
public eventsConfig: any[] = [
{
itemName : '订单',
itemType : 'item1',
color : '',
textColor : '',
},
];
/**
* 查询数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof OrderCalendarNavigationService
*/
@Errorlog
public search(action: string, context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let _this = this;
return new Promise((resolve: any, reject: any) => {
let promises:any = [];
let tempRequest:any;
tempRequest = this.handleRequestData(action,context,data,true,"item1");
promises.push(this.appEntityService.FetchDefault(tempRequest.context, tempRequest.data, isloading));
Promise.all(promises).then((resArray: any) => {
let _data:any = [];
resArray.forEach((response:any,resIndex:number) => {
if (!response || response.status !== 200) {
return;
}
let _response: any = JSON.parse(JSON.stringify(response));
_response.data.forEach((item:any,index:number) =>{
_response.data[index].color = _this.eventsConfig[resIndex].color;
_response.data[index].textColor = _this.eventsConfig[resIndex].textColor;
_response.data[index].itemType = _this.eventsConfig[resIndex].itemType;
});
;
_this.handleResponse(action, _response,false,_this.eventsConfig[resIndex].itemType);
_data.push(..._response.data);
});
// 排序
_data.sort((a:any, b:any)=>{
let dateA = new Date(Date.parse(a.start.replace(/-/g, "/")));
let dateB = new Date(Date.parse(b.start.replace(/-/g, "/")));
return dateA > dateB ? 1 : -1 ;
});
let result = {status: 200, data: _data};
resolve(result);
}).catch((response: any) => {
reject(response);
});
});
}
/**
* 修改数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof OrderCalendarNavigationService
*/
@Errorlog
public update(itemType: string, context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
return new Promise((resolve: any, reject: any) => {
let result: any;
let tempRequest:any;
switch(itemType) {
case "item1":
tempRequest = this.handleRequestData("",context,data,false,"item1");
result = this.appEntityService.Update(tempRequest.context, tempRequest.data, isloading);
break;
}
if(result){
result.then((response: any) => {
this.handleResponse("", response);
resolve(response);
}).catch((response: any) => {
reject(response);
});
}else{
reject("没有匹配的实体服务");
}
});
}
/**
* 处理request请求数据
*
* @param action 行为
* @param data 数据
* @memberof ControlService
*/
public handleRequestData(action: string,context:any ={},data: any = {},isMerge:boolean = false,itemType:string=""){
let model: any = this.getMode();
model.itemType = itemType;
return super.handleRequestData(action,context,data,isMerge);
}
/**
* 处理response返回数据
*
* @param {string} action
* @param {*} response
* @memberof ControlService
*/
public async handleResponse(action: string, response: any,isCreate:boolean = false,itemType:string=""){
let model: any = this.getMode();
model.itemType = itemType;
super.handleResponse(action,response,isCreate);
}
}
\ No newline at end of file
// this is less
@import '~@fullcalendar/core/main.css';
@import '~@fullcalendar/daygrid/main.css';
@import '~@fullcalendar/timegrid/main.css';
@import '~@fullcalendar/list/main.css';
.calendar{
height:100%;
overflow: auto;
.context-menu-container {
height: calc(100% - 70px);
}
.el-timeline{
padding-left: 2px;
}
.app-data-empty{
margin: 0 auto;
display: flex;
align-items: center;
justify-content: center;
height: 100%;
}
.event-legends{
width: 100%;
text-align: center;
.event-lengend{
display: inline-block;
margin-left: 10px;
height: 20px;
.lengend-icon{
display: inline-block;
width: 30px;
height: 20px;
border-radius: 5px;
}
span{
display: inline-block;
margin-left: 5px;
line-height: 20px;
vertical-align: top;
}
}
.event-lengend.event-disabled{
.lengend-icon{
background:#cccccc !important;
}
span{
color:#cccccc !important;
}
}
}
}
// 选中样式
.calendar .selected-event,
.select-first-calendar .select-first-event{
border: 2px solid #ff8711 !important;
}
.calendar .fc-dayGrid-view .selected-event:before,
.select-first-calendar .fc-dayGrid-view .select-first-event:before,
.calendar .fc-timeGrid-view .selected-event:before,
.select-first-calendar .fc-timeGrid-view .select-first-event:before{
content: '';
display: block;
position: absolute;
right: 0;
bottom: 0;
border: 9px solid #ff8711;
border-top-color: transparent;
border-left-color: transparent;
color: #fff;
}
.calendar .fc-dayGrid-view .selected-event:after,
.select-first-calendar .fc-dayGrid-view .select-first-event:after,
.calendar .fc-timeGrid-view .selected-event:after,
.select-first-calendar .fc-timeGrid-view .select-first-event:after{
content: '';
display: block;
width: 4px;
height: 11px;
position: absolute;
right: 1px;
bottom: 0px;
border: 2px solid #fff;
border-top-color: transparent;
border-left-color: transparent;
-webkit-transform: rotate(45deg);
transform: rotate(45deg);
box-sizing: content-box;
}
// 选择跳转日期模态
.date-select-modal{
display: flex;
align-items: center;
justify-content: center;
.ivu-modal{
top: 0;
.ivu-modal-body {
text-align: center;
}
}
}
\ No newline at end of file
<script lang='tsx'>
import { Component } from 'vue-property-decorator';
import OrderCalendarNavigationBase from './order-calendar-navigation-calendar-base.vue';
@Component({
components: {
}
})
export default class OrderCalendarNavigation extends OrderCalendarNavigationBase {
}
</script>
\ No newline at end of file
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册