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

lab_qyk 发布系统代码

上级 ad3bc930
...@@ -281,14 +281,14 @@ export default class AppAutocomplete extends Vue { ...@@ -281,14 +281,14 @@ export default class AppAutocomplete extends Vue {
return false; return false;
} }
// 合并表单参数 // 合并表单参数
arg.param = JSON.parse(JSON.stringify(this.viewparams)); arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = JSON.parse(JSON.stringify(this.context)); arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
// 附加参数处理 // 附加参数处理
if (this.itemParam.context) { if (this.itemParam && this.itemParam.context) {
let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context); let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context);
Object.assign(arg.context,_context); Object.assign(arg.context,_context);
} }
if (this.itemParam.param) { if (this.itemParam && this.itemParam.param) {
let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param); let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param);
Object.assign(arg.param,_param); Object.assign(arg.param,_param);
} }
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
</template> </template>
<script lang="ts"> <script lang="ts">
import { Component, Vue, Prop, Model } from 'vue-property-decorator'; import { Component, Vue, Prop, Model, Watch } from 'vue-property-decorator';
import CodeListService from "@service/app/codelist-service"; import CodeListService from "@service/app/codelist-service";
@Component({ @Component({
...@@ -207,14 +207,14 @@ export default class AppCheckBox extends Vue { ...@@ -207,14 +207,14 @@ export default class AppCheckBox extends Vue {
*/ */
public handlePublicParams(arg: any) { public handlePublicParams(arg: any) {
// 合并表单参数 // 合并表单参数
arg.param = JSON.parse(JSON.stringify(this.viewparams)); arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = JSON.parse(JSON.stringify(this.context)); arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
// 附加参数处理 // 附加参数处理
if (this.itemParam.context) { if (this.itemParam && this.itemParam.context) {
let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context); let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context);
Object.assign(arg.context,_context); Object.assign(arg.context,_context);
} }
if (this.itemParam.param) { if (this.itemParam && this.itemParam.param) {
let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param); let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param);
Object.assign(arg.param,_param); Object.assign(arg.param,_param);
} }
...@@ -250,6 +250,29 @@ export default class AppCheckBox extends Vue { ...@@ -250,6 +250,29 @@ export default class AppCheckBox extends Vue {
} }
} }
/**
* 监听表单数据变化
*
* @memberof AppOrgSelect
*/
@Watch('data',{immediate:true,deep:true})
onDataChange(newVal: any, oldVal: any) {
if(newVal){
if(this.tag && this.codelistType == 'DYNAMIC'){
// 公共参数处理
let data: any = {};
this.handlePublicParams(data);
// 参数处理
let _context = data.context;
let _param = data.param;
this.codeListService.getItems(this.tag,_context,_param).then((res:any) => {
this.items = res;
}).catch((error:any)=>{
console.log(`----${this.tag}----代码表不存在!`);
})
}
}
}
} }
</script> </script>
......
...@@ -279,8 +279,8 @@ export default class AppColumnLink extends Vue { ...@@ -279,8 +279,8 @@ export default class AppColumnLink extends Vue {
return false; return false;
} }
// 合并表单参数 // 合并表单参数
arg.param = JSON.parse(JSON.stringify(this.viewparams)); arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = JSON.parse(JSON.stringify(this.context)); arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
return true; return true;
} }
......
...@@ -246,14 +246,14 @@ export default class AppMpicker extends Vue { ...@@ -246,14 +246,14 @@ export default class AppMpicker extends Vue {
return false; return false;
} }
// 合并表单参数 // 合并表单参数
arg.param = JSON.parse(JSON.stringify(this.viewparams)); arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = JSON.parse(JSON.stringify(this.context)); arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
// 附加参数处理 // 附加参数处理
if (this.itemParam.context) { if (this.itemParam && this.itemParam.context) {
let _context = this.$util.formatData(this.activeData,arg.context,this.itemParam.context); let _context = this.$util.formatData(this.activeData,arg.context,this.itemParam.context);
Object.assign(arg.context,_context); Object.assign(arg.context,_context);
} }
if (this.itemParam.param) { if (this.itemParam && this.itemParam.param) {
let _param = this.$util.formatData(this.activeData,arg.param,this.itemParam.param); let _param = this.$util.formatData(this.activeData,arg.param,this.itemParam.param);
Object.assign(arg.param,_param); Object.assign(arg.param,_param);
} }
......
...@@ -22,6 +22,14 @@ ...@@ -22,6 +22,14 @@
.ivu-select-dropdown{ .ivu-select-dropdown{
max-height: 200px; max-height: 200px;
overflow: scroll; overflow: scroll;
margin: 0;
padding: 0;
.ivu-dropdown-menu{
.view-container{
margin: 0;
padding: 0;
}
}
.tree-contant{ .tree-contant{
overflow:inherit; overflow:inherit;
} }
......
...@@ -255,8 +255,8 @@ export default class AppPickerSelectView extends Vue { ...@@ -255,8 +255,8 @@ export default class AppPickerSelectView extends Vue {
return false; return false;
} }
// 合并表单参数 // 合并表单参数
arg.param = JSON.parse(JSON.stringify(this.viewparams)); arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = JSON.parse(JSON.stringify(this.context)); arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
// 附加参数处理 // 附加参数处理
if (this.itemParam.context) { if (this.itemParam.context) {
let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context); let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context);
......
...@@ -410,9 +410,9 @@ export default class AppPicker extends Vue { ...@@ -410,9 +410,9 @@ export default class AppPicker extends Vue {
// 判断打开方式 // 判断打开方式
if (view.placement && !Object.is(view.placement, '')) { if (view.placement && !Object.is(view.placement, '')) {
if (Object.is(view.placement, 'POPOVER')) { if (Object.is(view.placement, 'POPOVER')) {
this.openPopOver($event, view, _context, data); this.openPopOver($event, view, _context, _param);
} else { } else {
this.openDrawer(view, _context, data); this.openDrawer(view, _context, _param);
} }
} else { } else {
this.openPopupModal(view, _context, _param); this.openPopupModal(view, _context, _param);
...@@ -647,14 +647,14 @@ export default class AppPicker extends Vue { ...@@ -647,14 +647,14 @@ export default class AppPicker extends Vue {
return false; return false;
} }
// 合并表单参数 // 合并表单参数
arg.param = JSON.parse(JSON.stringify(this.viewparams)); arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = JSON.parse(JSON.stringify(this.context)); arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
// 附加参数处理 // 附加参数处理
if (this.itemParam.context) { if (this.itemParam && this.itemParam.context) {
let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context); let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context);
Object.assign(arg.context,_context); Object.assign(arg.context,_context);
} }
if (this.itemParam.param) { if (this.itemParam && this.itemParam.param) {
let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param); let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param);
Object.assign(arg.param,_param); Object.assign(arg.param,_param);
} }
...@@ -687,9 +687,9 @@ export default class AppPicker extends Vue { ...@@ -687,9 +687,9 @@ export default class AppPicker extends Vue {
// 判断打开方式 // 判断打开方式
if (view.placement && !Object.is(view.placement, '')) { if (view.placement && !Object.is(view.placement, '')) {
if (Object.is(view.placement, 'POPOVER')) { if (Object.is(view.placement, 'POPOVER')) {
this.openPopOver($event, view, _context, data); this.openPopOver($event, view, _context, _param);
} else { } else {
this.openDrawer(view, _context, data); this.openDrawer(view, _context, _param);
} }
} else { } else {
this.openPopupModal(view, _context, _param); this.openPopupModal(view, _context, _param);
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
</radio-group> </radio-group>
</template> </template>
<script lang = 'ts'> <script lang = 'ts'>
import { Component, Vue, Prop, Model } from 'vue-property-decorator'; import { Component, Vue, Prop, Model,Watch } from 'vue-property-decorator';
import CodeListService from "@service/app/codelist-service"; import CodeListService from "@service/app/codelist-service";
@Component({}) @Component({})
...@@ -69,6 +69,31 @@ export default class AppRadioGroup extends Vue { ...@@ -69,6 +69,31 @@ export default class AppRadioGroup extends Vue {
*/ */
@Prop() public data?: any; @Prop() public data?: any;
/**
* 监听表单数据变化
*
* @memberof AppOrgSelect
*/
@Watch('data',{immediate:true,deep:true})
onDataChange(newVal: any, oldVal: any) {
if(newVal){
if(this.tag && this.codelistType == 'DYNAMIC'){
// 公共参数处理
let data: any = {};
this.handlePublicParams(data);
// 参数处理
let _context = data.context;
let _param = data.param;
console.log("app-radio-group")
this.codeListService.getItems(this.tag,_context,_param).then((res:any) => {
this.items = res;
}).catch((error:any)=>{
console.log(`----${this.tag}----代码表不存在!`);
})
}
}
}
/** /**
* 是否禁用 * 是否禁用
* *
...@@ -140,14 +165,14 @@ export default class AppRadioGroup extends Vue { ...@@ -140,14 +165,14 @@ export default class AppRadioGroup extends Vue {
*/ */
public handlePublicParams(arg: any) { public handlePublicParams(arg: any) {
// 合并表单参数 // 合并表单参数
arg.param = JSON.parse(JSON.stringify(this.viewparams)); arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = JSON.parse(JSON.stringify(this.context)); arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
// 附加参数处理 // 附加参数处理
if (this.itemParam.context) { if (this.itemParam && this.itemParam.context) {
let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context); let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context);
Object.assign(arg.context,_context); Object.assign(arg.context,_context);
} }
if (this.itemParam.param) { if (this.itemParam && this.itemParam.param) {
let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param); let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param);
Object.assign(arg.param,_param); Object.assign(arg.param,_param);
} }
...@@ -169,8 +194,8 @@ export default class AppRadioGroup extends Vue { ...@@ -169,8 +194,8 @@ export default class AppRadioGroup extends Vue {
let _context = data.context; let _context = data.context;
let _param = data.param; let _param = data.param;
this.codeListService.getItems(this.tag,_context,_param).then((res:any) => { this.codeListService.getItems(this.tag,_context,_param).then((res:any) => {
this.items = data; this.items = res;
}).catch((data:any)=>{ }).catch((error:any)=>{
console.log(`----${this.tag}----代码表不存在!`); console.log(`----${this.tag}----代码表不存在!`);
}) })
} }
......
...@@ -104,7 +104,7 @@ export default class AppRichTextEditor extends Vue { ...@@ -104,7 +104,7 @@ export default class AppRichTextEditor extends Vue {
* @type {*} * @type {*}
* @memberof AppRichTextEditor * @memberof AppRichTextEditor
*/ */
public langu: any = localStorage.getItem('local') ? localStorage.getItem('local') : 'zh_CN' ; public langu: any = localStorage.getItem('local') ? localStorage.getItem('local') : 'zh-CN' ;
/** /**
* 语言映射文件 * 语言映射文件
......
<template> <template>
<codelist v-if="tag" :tag="tag" :value="value" :codelistType="codelistType" :renderMode="renderMode" :valueSeparator="valueSeparator" :textSeparator="textSeparator"></codelist> <codelist v-if="tag" :tag="tag" :value="value" :codelistType="codelistType" :renderMode="renderMode" :valueSeparator="valueSeparator" :textSeparator="textSeparator" :data="data" :itemParam="itemParam" :context="context" :viewparams="viewparams"></codelist>
<app-upload-file-info v-else-if="Object.is(this.editorType,'PICTURE') || Object.is(this.editorType,'PICTURE_ONE') || Object.is(this.editorType,'FILEUPLOADER')" :value="value" :name="name"></app-upload-file-info> <app-upload-file-info v-else-if="Object.is(this.editorType,'PICTURE') || Object.is(this.editorType,'PICTURE_ONE') || Object.is(this.editorType,'FILEUPLOADER')" :value="value" :name="name"></app-upload-file-info>
<span class="app-span" v-else >{{text}}</span> <span class="app-span" v-else >{{text}}</span>
</template> </template>
<script lang="ts"> <script lang="ts">
import { Vue, Component, Prop, Watch, Model } from 'vue-property-decorator'; import { Vue, Component, Prop, Watch, Model } from 'vue-property-decorator';
import CodeListService from "@service/app/codelist-service";
@Component({}) @Component({})
export default class AppSpan extends Vue { export default class AppSpan extends Vue {
...@@ -64,6 +63,38 @@ export default class AppSpan extends Vue { ...@@ -64,6 +63,38 @@ export default class AppSpan extends Vue {
*/ */
@Prop({default:','}) public valueSeparator?: string; @Prop({default:','}) public valueSeparator?: string;
/**
* 传入表单数据
*
* @type {*}
* @memberof AppSpan
*/
@Prop() public data?: any;
/**
* 传入额外参数
*
* @type {*}
* @memberof AppSpan
*/
@Prop() public itemParam?: any;
/**
* 视图上下文
*
* @type {*}
* @memberof AppSpan
*/
@Prop() public context!: any;
/**
* 视图参数
*
* @type {*}
* @memberof AppSpan
*/
@Prop() public viewparams!: any;
/** /**
* 监控表单属性 data 值 * 监控表单属性 data 值
* *
......
...@@ -37,14 +37,14 @@ export default class CodeList extends Vue { ...@@ -37,14 +37,14 @@ export default class CodeList extends Vue {
* 代码表类型 * 代码表类型
* *
* @type {string} * @type {string}
* @memberof AppCheckBox * @memberof CodeList
*/ */
@Prop() public codelistType?: string; @Prop() public codelistType?: string;
/** /**
* 当前值 * 当前值
* @type {any} * @type {any}
* @memberof SelectPicker * @memberof CodeList
* *
*/ */
@Prop() public value?: string; @Prop() public value?: string;
...@@ -52,24 +52,56 @@ export default class CodeList extends Vue { ...@@ -52,24 +52,56 @@ export default class CodeList extends Vue {
/** /**
* 获取或模式 * 获取或模式
* @type {boolean} * @type {boolean}
* @memberof SelectPicker * @memberof CodeList
*/ */
@Prop({default:"STR"}) public renderMode?: string; @Prop({default:"STR"}) public renderMode?: string;
/** /**
* 文本分隔符 * 文本分隔符
* @type {boolean} * @type {boolean}
* @memberof SelectPicker * @memberof CodeList
*/ */
@Prop({default:'、'}) public textSeparator?: string; @Prop({default:'、'}) public textSeparator?: string;
/** /**
* 值分隔符 * 值分隔符
* @type {boolean} * @type {boolean}
* @memberof SelectPicker * @memberof CodeList
*/ */
@Prop({default:','}) public valueSeparator?: string; @Prop({default:','}) public valueSeparator?: string;
/**
* 传入表单数据
*
* @type {*}
* @memberof CodeList
*/
@Prop() public data?: any;
/**
* 传入额外参数
*
* @type {*}
* @memberof CodeList
*/
@Prop() public itemParam?: any;
/**
* 视图上下文
*
* @type {*}
* @memberof CodeList
*/
@Prop() public context!: any;
/**
* 视图参数
*
* @type {*}
* @memberof CodeList
*/
@Prop() public viewparams!: any;
/** /**
* 是否为空 * 是否为空
* *
...@@ -101,7 +133,7 @@ export default class CodeList extends Vue { ...@@ -101,7 +133,7 @@ export default class CodeList extends Vue {
*/ */
public isUseLangres:boolean = false; public isUseLangres:boolean = false;
/** /**
* 数据值变化 * 数据值变化
* *
* @param {*} newval * @param {*} newval
...@@ -112,7 +144,18 @@ export default class CodeList extends Vue { ...@@ -112,7 +144,18 @@ export default class CodeList extends Vue {
@Watch('value') @Watch('value')
public onValueChange(newVal: any, oldVal: any) { public onValueChange(newVal: any, oldVal: any) {
this.dataHandle(); this.dataHandle();
}
/**
* 监听表单数据变化
*
* @memberof CodeList
*/
@Watch('data',{immediate:true,deep:true})
onDataChange(newVal: any, oldVal: any) {
if(newVal){
this.dataHandle();
}
} }
/** /**
...@@ -131,7 +174,13 @@ export default class CodeList extends Vue { ...@@ -131,7 +174,13 @@ export default class CodeList extends Vue {
this.ifEmpty = false; this.ifEmpty = false;
// 动态代码表处理 // 动态代码表处理
if (Object.is(this.codelistType, "DYNAMIC")) { if (Object.is(this.codelistType, "DYNAMIC")) {
this.codeListService.getItems(this.tag).then((res: any) => { // 公共参数处理
let data: any = {};
this.handlePublicParams(data);
// 参数处理
let _context = data.context;
let _param = data.param;
this.codeListService.getItems(this.tag,_context,_param).then((res:any) => {
let items = res; let items = res;
_this.setItems(items, _this); _this.setItems(items, _this);
}).catch((error: any) => { }).catch((error: any) => {
...@@ -209,6 +258,28 @@ export default class CodeList extends Vue { ...@@ -209,6 +258,28 @@ export default class CodeList extends Vue {
} }
} }
/**
* 公共参数处理
*
* @param {*} arg
* @returns
* @memberof CodeList
*/
public handlePublicParams(arg: any) {
// 合并表单参数
arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
// 附加参数处理
if (this.itemParam && this.itemParam.context) {
let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context);
Object.assign(arg.context,_context);
}
if (this.itemParam && this.itemParam.param) {
let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param);
Object.assign(arg.param,_param);
}
}
} }
</script> </script>
......
...@@ -169,8 +169,8 @@ export default class DropDownListDynamic extends Vue { ...@@ -169,8 +169,8 @@ export default class DropDownListDynamic extends Vue {
*/ */
public handlePublicParams(arg: any) { public handlePublicParams(arg: any) {
// 合并表单参数 // 合并表单参数
arg.param = JSON.parse(JSON.stringify(this.viewparams)); arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = JSON.parse(JSON.stringify(this.context)); arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
// 附加参数处理 // 附加参数处理
if (this.itemParam.context) { if (this.itemParam.context) {
let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context); let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context);
......
...@@ -154,8 +154,8 @@ export default class DropDownListMpicker extends Vue { ...@@ -154,8 +154,8 @@ export default class DropDownListMpicker extends Vue {
*/ */
public handlePublicParams(arg: any) { public handlePublicParams(arg: any) {
// 合并表单参数 // 合并表单参数
arg.param = JSON.parse(JSON.stringify(this.viewparams)); arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = JSON.parse(JSON.stringify(this.context)); arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
// 附加参数处理 // 附加参数处理
if (this.itemParam.context) { if (this.itemParam.context) {
let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context); let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context);
......
...@@ -169,14 +169,14 @@ export default class DropDownList extends Vue { ...@@ -169,14 +169,14 @@ export default class DropDownList extends Vue {
*/ */
public handlePublicParams(arg: any) { public handlePublicParams(arg: any) {
// 合并表单参数 // 合并表单参数
arg.param = JSON.parse(JSON.stringify(this.viewparams)); arg.param = this.viewparams ? JSON.parse(JSON.stringify(this.viewparams)) : {};
arg.context = JSON.parse(JSON.stringify(this.context)); arg.context = this.context ? JSON.parse(JSON.stringify(this.context)) : {};
// 附加参数处理 // 附加参数处理
if (this.itemParam.context) { if (this.itemParam && this.itemParam.context) {
let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context); let _context = this.$util.formatData(this.data,arg.context,this.itemParam.context);
Object.assign(arg.context,_context); Object.assign(arg.context,_context);
} }
if (this.itemParam.param) { if (this.itemParam && this.itemParam.param) {
let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param); let _param = this.$util.formatData(this.data,arg.param,this.itemParam.param);
Object.assign(arg.param,_param); Object.assign(arg.param,_param);
} }
......
...@@ -122,6 +122,14 @@ export class ChartSeries { ...@@ -122,6 +122,14 @@ export class ChartSeries {
*/ */
public seriesLayoutBy:string = "column"; public seriesLayoutBy:string = "column";
/**
* 序列代码表
*
* @type {*}
* @memberof ChartSeries
*/
public seriesCodeList:any;
/** /**
* Creates an instance of ChartSeries. * Creates an instance of ChartSeries.
* ChartSeries 实例 * ChartSeries 实例
...@@ -144,6 +152,7 @@ export class ChartSeries { ...@@ -144,6 +152,7 @@ export class ChartSeries {
this.dataSetFields = opts.dataSetFields ? opts.dataSetFields:[]; this.dataSetFields = opts.dataSetFields ? opts.dataSetFields:[];
this.seriesMap = opts.seriesMap ? opts.seriesMap:null; this.seriesMap = opts.seriesMap ? opts.seriesMap:null;
this.seriesIndex = opts.seriesIndex? opts.seriesIndex:0; this.seriesIndex = opts.seriesIndex? opts.seriesIndex:0;
this.seriesCodeList = opts.seriesCodeList?opts.seriesCodeList:null;
} }
/** /**
...@@ -285,4 +294,14 @@ export class ChartSeries { ...@@ -285,4 +294,14 @@ export class ChartSeries {
public setSeriesIndex(state: number): void { public setSeriesIndex(state: number): void {
this.seriesIndex = state; this.seriesIndex = state;
} }
/**
* 设置序列代码表
*
* @param {any} state
* @memberof ChartSeries
*/
public setSeriesCodeList(state: any): void {
this.seriesCodeList = state;
}
} }
\ No newline at end of file
...@@ -3,12 +3,14 @@ ...@@ -3,12 +3,14 @@
} }
.view-container { .app-modal{
.view-card { .view-container {
.ivu-card-body { .view-card {
.content-container{ .ivu-card-body {
height: calc(100% - 64px); .content-container{
} height: calc(100% - 64px);
}
}
} }
} }
} }
\ No newline at end of file
...@@ -4,5 +4,5 @@ ...@@ -4,5 +4,5 @@
.ibzdepartment-pickup-grid-view{ .ibzdepartment-pickup-grid-view{
width:100%; display: block;
} }
\ No newline at end of file
...@@ -3,12 +3,14 @@ ...@@ -3,12 +3,14 @@
} }
.view-container { .app-modal{
.view-card { .view-container {
.ivu-card-body { .view-card {
.content-container{ .ivu-card-body {
height: calc(100% - 64px); .content-container{
} height: calc(100% - 64px);
}
}
} }
} }
} }
\ No newline at end of file
...@@ -4,5 +4,5 @@ ...@@ -4,5 +4,5 @@
.ibzemployee-pickup-grid-view{ .ibzemployee-pickup-grid-view{
width:100%; display: block;
} }
\ No newline at end of file
...@@ -3,12 +3,14 @@ ...@@ -3,12 +3,14 @@
} }
.view-container { .app-modal{
.view-card { .view-container {
.ivu-card-body { .view-card {
.content-container{ .ivu-card-body {
height: calc(100% - 64px); .content-container{
} height: calc(100% - 64px);
}
}
} }
} }
} }
\ No newline at end of file
...@@ -4,5 +4,5 @@ ...@@ -4,5 +4,5 @@
.ibzorganization-pickup-grid-view{ .ibzorganization-pickup-grid-view{
width:100%; display: block;
} }
\ No newline at end of file
...@@ -9,6 +9,7 @@ ...@@ -9,6 +9,7 @@
height: 100%; height: 100%;
padding: 0; padding: 0;
margin: 0; margin: 0;
overflow: hidden;
.index_header{ .index_header{
height:65px; height:65px;
padding:0 20px; padding:0 20px;
...@@ -52,14 +53,11 @@ ...@@ -52,14 +53,11 @@
} }
} }
.ivu-layout .ivu-layout-sider .ivu-layout-sider-children .sider-top{ .ivu-layout .ivu-layout-sider .ivu-layout-sider-children .sider-top{
padding: 4px;
margin-top: -2px;
line-height: 58px; line-height: 58px;
text-align: center; text-align: center;
padding-right: 18px;
}
.ivu-layout .ivu-layout-sider .ivu-layout-sider-children .sider-top{
font-size: 20px; font-size: 20px;
padding: 4px;
margin-top: -2px;
cursor: pointer; cursor: pointer;
} }
.sider-top{ .sider-top{
......
...@@ -4,5 +4,5 @@ ...@@ -4,5 +4,5 @@
.sys-permission-pickup-grid-view{ .sys-permission-pickup-grid-view{
width:100%; display: block;
} }
\ No newline at end of file
...@@ -4,5 +4,5 @@ ...@@ -4,5 +4,5 @@
.sys-role-pickup-grid-view{ .sys-role-pickup-grid-view{
width:100%; display: block;
} }
\ No newline at end of file
...@@ -4,5 +4,5 @@ ...@@ -4,5 +4,5 @@
.sys-user-pickup-grid-view{ .sys-user-pickup-grid-view{
width:100%; display: block;
} }
\ No newline at end of file
...@@ -4,5 +4,5 @@ ...@@ -4,5 +4,5 @@
.wfgroup-pickup-grid-view{ .wfgroup-pickup-grid-view{
width:100%; display: block;
} }
\ No newline at end of file
...@@ -4,5 +4,5 @@ ...@@ -4,5 +4,5 @@
.wfuser-pickup-grid-view{ .wfuser-pickup-grid-view{
width:100%; display: block;
} }
\ No newline at end of file
...@@ -40,6 +40,14 @@ export default class CodeListService { ...@@ -40,6 +40,14 @@ export default class CodeListService {
*/ */
public static codelistCache:Map<string,any> = new Map(); public static codelistCache:Map<string,any> = new Map();
/**
* 动态代码表缓存(已完成)
*
* @type {Map<string,any>}
* @memberof CodeListService
*/
public static codelistCached:Map<string,any> = new Map();
/** /**
* 获取动态代码表 * 获取动态代码表
...@@ -51,31 +59,22 @@ export default class CodeListService { ...@@ -51,31 +59,22 @@ export default class CodeListService {
*/ */
public getItems(tag: string,context:any = {}, data?: any, isloading?: boolean,): Promise<any[]> { public getItems(tag: string,context:any = {}, data?: any, isloading?: boolean,): Promise<any[]> {
let _this: any = this; let _this: any = this;
if(context && context.srfsessionid){
delete context.srfsessionid;
}
let isEnableCache:boolean = _this[tag].isEnableCache; let isEnableCache:boolean = _this[tag].isEnableCache;
let cacheTimeout:any = _this[tag].cacheTimeout; let cacheTimeout:any = _this[tag].cacheTimeout;
return new Promise((resolve:any,reject:any) =>{ return new Promise((resolve:any,reject:any) =>{
// 如有查询参数传递过来,需直接加载,不能使用缓存
if(data && Object.keys(data).length >0){
if (_this[tag]) {
_this[tag].getItems(context,JSON.parse(JSON.stringify(data)),isloading).then((result:any) =>{
resolve(result);
}).catch((error:any) =>{
Promise.reject([]);
})
}else{
return Promise.reject([]);
}
}else{
// 启用缓存 // 启用缓存
if(isEnableCache){ if(isEnableCache){
// 加载完成,从store获取 // 加载完成,从本地缓存获取
if(this.$store && _this.$store.getters){ if(CodeListService.codelistCached.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`)){
let items:any = _this.$store.getters.getCodeListItems(tag); let items:any = CodeListService.codelistCached.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`);
if(items.length >0){ if(items.length >0){
if(cacheTimeout !== -1){ if(cacheTimeout !== -1){
if(new Date().getTime() > _this[tag].expirationTime){ if(new Date().getTime() > _this[tag].expirationTime){
_this[tag].getItems(context,data,isloading).then((result:any) =>{ _this[tag].getItems(context,data,isloading).then((result:any) =>{
_this.$store.commit('updateCodeList',{srfkey:tag,items:result}); CodeListService.codelistCached.set(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`,{items:result});
_this[tag].expirationTime = new Date().getTime() + cacheTimeout; _this[tag].expirationTime = new Date().getTime() + cacheTimeout;
resolve(result); resolve(result);
}).catch((error:any) =>{ }).catch((error:any) =>{
...@@ -90,10 +89,11 @@ export default class CodeListService { ...@@ -90,10 +89,11 @@ export default class CodeListService {
} }
} }
if (_this[tag]) { if (_this[tag]) {
const callback:Function = (tag:string,promise:Promise<any>) =>{ const callback:Function = (context:any ={},data:any ={},tag:string,promise:Promise<any>) =>{
promise.then((result:any) =>{ promise.then((result:any) =>{
console.log()
if(result.length > 0){ if(result.length > 0){
_this.$store.commit('updateCodeList',{srfkey:tag,items:result}); CodeListService.codelistCached.set(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`,{items:result});
return resolve(result); return resolve(result);
}else{ }else{
return resolve([]); return resolve([]);
...@@ -103,15 +103,15 @@ export default class CodeListService { ...@@ -103,15 +103,15 @@ export default class CodeListService {
}) })
} }
// 加载中,UI又需要数据,解决连续加载同一代码表问题 // 加载中,UI又需要数据,解决连续加载同一代码表问题
if(CodeListService.codelistCache.get(tag)){ if(CodeListService.codelistCache.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`)){
callback(tag,CodeListService.codelistCache.get(tag)); callback(context,data,tag,CodeListService.codelistCache.get(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`));
}else{ }else{
let result:Promise<any> = _this[tag].getItems(context,data,isloading); let result:Promise<any> = _this[tag].getItems(context,data,isloading);
CodeListService.codelistCache.set(tag,result); CodeListService.codelistCache.set(`${JSON.stringify(context)}-${JSON.stringify(data)}-${tag}`,result);
if(cacheTimeout !== -1){ if(cacheTimeout !== -1){
_this[tag].expirationTime = new Date().getTime() + cacheTimeout; _this[tag].expirationTime = new Date().getTime() + cacheTimeout;
} }
callback(tag,result); callback(context,data,tag,result);
} }
} }
}else{ }else{
...@@ -125,7 +125,6 @@ export default class CodeListService { ...@@ -125,7 +125,6 @@ export default class CodeListService {
return Promise.reject([]); return Promise.reject([]);
} }
} }
}
}) })
} }
} }
\ No newline at end of file
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
i:hover{ i:hover{
color:#fff; color:#fff;
} }
> .app-breadcrumb{ .app-breadcrumb{
> span .el-breadcrumb__item .el-breadcrumb__inner{ > span .el-breadcrumb__item .el-breadcrumb__inner{
a{ a{
color:#b4bcc8 !important; color:#b4bcc8 !important;
...@@ -125,5 +125,8 @@ ...@@ -125,5 +125,8 @@
.sider-top{ .sider-top{
color:#fff; color:#fff;
} }
div.ivu-divider{
background-color: #c9dff5;
}
} }
/*** END:默认蓝色主题 ***/ /*** END:默认蓝色主题 ***/
\ No newline at end of file
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
i:hover{ i:hover{
color:#fff; color:#fff;
} }
> .app-breadcrumb{ .app-breadcrumb{
> span .el-breadcrumb__item .el-breadcrumb__inner{ > span .el-breadcrumb__item .el-breadcrumb__inner{
a{ a{
color:#b4bcc8 !important; color:#b4bcc8 !important;
...@@ -120,5 +120,8 @@ ...@@ -120,5 +120,8 @@
.sider-top{ .sider-top{
color:#fff; color:#fff;
} }
div.ivu-divider{
background-color: #b4bcc8;
}
} }
/*** END:默认Dark Blue主题 ***/ /*** END:默认Dark Blue主题 ***/
\ No newline at end of file
...@@ -99,5 +99,8 @@ ...@@ -99,5 +99,8 @@
.sider-top{ .sider-top{
color:#000; color:#000;
} }
div.ivu-divider{
background-color: #b3b3b3;
}
} }
/*** END:默认亮色主题 ***/ /*** END:默认亮色主题 ***/
\ No newline at end of file
...@@ -74,8 +74,8 @@ ...@@ -74,8 +74,8 @@
} }
} }
.ivu-divider-horizontal { .ivu-divider-horizontal {
width: calc(100% - 32px); width: 100%;
min-width: calc(100% - 32px); min-width: 100%;
margin: 4px auto; margin: 4px auto;
margin-bottom: 1px; margin-bottom: 1px;
} }
...@@ -103,8 +103,8 @@ ...@@ -103,8 +103,8 @@
} }
} }
.ivu-divider-horizontal { .ivu-divider-horizontal {
width: calc(100% - 12px); width: 100%;
min-width: calc(100% - 12px); min-width: 100%;
margin: 4px auto; margin: 4px auto;
margin-bottom: 1px; margin-bottom: 1px;
} }
......
.tree-right-menu { .tree-right-menu {
.ivu-divider-horizontal { .ivu-divider-horizontal {
width: calc(100% - 32px); width: 100%;
min-width: calc(100% - 32px); min-width: 100%;
margin: 0 auto; margin: 0 auto;
} }
.ivu-dropdown-item { .ivu-dropdown-item {
......
...@@ -74,14 +74,22 @@ ...@@ -74,14 +74,22 @@
<i-col v-show="detailsModel.createdate.visible" :style="{}" :lg="{ span: 24, offset: 0 }"> <i-col v-show="detailsModel.createdate.visible" :style="{}" :lg="{ span: 24, offset: 0 }">
<app-form-item name='createdate' :itemRules="this.rules.createdate" class='' :caption="$t('entities.ibzdepartment.main_form.details.createdate')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.createdate.error" :isEmptyCaption="false" labelPos="LEFT"> <app-form-item name='createdate' :itemRules="this.rules.createdate" class='' :caption="$t('entities.ibzdepartment.main_form.details.createdate')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.createdate.error" :isEmptyCaption="false" labelPos="LEFT">
<app-span name='createdate' <app-span name='createdate'
:value="data.createdate" style=""></app-span> :value="data.createdate" :data="data"
:context="context"
:viewparams="viewparams"
:itemParam="{}"
style=""></app-span>
</app-form-item> </app-form-item>
</i-col> </i-col>
<i-col v-show="detailsModel.updatedate.visible" :style="{}" :lg="{ span: 24, offset: 0 }"> <i-col v-show="detailsModel.updatedate.visible" :style="{}" :lg="{ span: 24, offset: 0 }">
<app-form-item name='updatedate' :itemRules="this.rules.updatedate" class='' :caption="$t('entities.ibzdepartment.main_form.details.updatedate')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.updatedate.error" :isEmptyCaption="false" labelPos="LEFT"> <app-form-item name='updatedate' :itemRules="this.rules.updatedate" class='' :caption="$t('entities.ibzdepartment.main_form.details.updatedate')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.updatedate.error" :isEmptyCaption="false" labelPos="LEFT">
<app-span name='updatedate' <app-span name='updatedate'
:value="data.updatedate" style=""></app-span> :value="data.updatedate" :data="data"
:context="context"
:viewparams="viewparams"
:itemParam="{}"
style=""></app-span>
</app-form-item> </app-form-item>
</i-col> </i-col>
......
...@@ -42,14 +42,22 @@ ...@@ -42,14 +42,22 @@
<i-col v-show="detailsModel.createdate.visible" :style="{}" :lg="{ span: 24, offset: 0 }"> <i-col v-show="detailsModel.createdate.visible" :style="{}" :lg="{ span: 24, offset: 0 }">
<app-form-item name='createdate' :itemRules="this.rules.createdate" class='' :caption="$t('entities.ibzorganization.main_form.details.createdate')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.createdate.error" :isEmptyCaption="false" labelPos="LEFT"> <app-form-item name='createdate' :itemRules="this.rules.createdate" class='' :caption="$t('entities.ibzorganization.main_form.details.createdate')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.createdate.error" :isEmptyCaption="false" labelPos="LEFT">
<app-span name='createdate' <app-span name='createdate'
:value="data.createdate" style=""></app-span> :value="data.createdate" :data="data"
:context="context"
:viewparams="viewparams"
:itemParam="{}"
style=""></app-span>
</app-form-item> </app-form-item>
</i-col> </i-col>
<i-col v-show="detailsModel.updatedate.visible" :style="{}" :lg="{ span: 24, offset: 0 }"> <i-col v-show="detailsModel.updatedate.visible" :style="{}" :lg="{ span: 24, offset: 0 }">
<app-form-item name='updatedate' :itemRules="this.rules.updatedate" class='' :caption="$t('entities.ibzorganization.main_form.details.updatedate')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.updatedate.error" :isEmptyCaption="false" labelPos="LEFT"> <app-form-item name='updatedate' :itemRules="this.rules.updatedate" class='' :caption="$t('entities.ibzorganization.main_form.details.updatedate')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.updatedate.error" :isEmptyCaption="false" labelPos="LEFT">
<app-span name='updatedate' <app-span name='updatedate'
:value="data.updatedate" style=""></app-span> :value="data.updatedate" :data="data"
:context="context"
:viewparams="viewparams"
:itemParam="{}"
style=""></app-span>
</app-form-item> </app-form-item>
</i-col> </i-col>
......
.tree-right-menu { .tree-right-menu {
.ivu-divider-horizontal { .ivu-divider-horizontal {
width: calc(100% - 32px); width: 100%;
min-width: calc(100% - 32px); min-width: 100%;
margin: 0 auto; margin: 0 auto;
} }
.ivu-dropdown-item { .ivu-dropdown-item {
......
...@@ -15,7 +15,11 @@ ...@@ -15,7 +15,11 @@
<i-col v-show="detailsModel.sys_user_roleid.visible" :style="{}" :lg="{ span: 24, offset: 0 }"> <i-col v-show="detailsModel.sys_user_roleid.visible" :style="{}" :lg="{ span: 24, offset: 0 }">
<app-form-item name='sys_user_roleid' :itemRules="this.rules.sys_user_roleid" class='' :caption="$t('entities.sysuserrole.main_form.details.sys_user_roleid')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.sys_user_roleid.error" :isEmptyCaption="false" labelPos="LEFT"> <app-form-item name='sys_user_roleid' :itemRules="this.rules.sys_user_roleid" class='' :caption="$t('entities.sysuserrole.main_form.details.sys_user_roleid')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.sys_user_roleid.error" :isEmptyCaption="false" labelPos="LEFT">
<app-span name='sys_user_roleid' <app-span name='sys_user_roleid'
:value="data.sys_user_roleid" style=""></app-span> :value="data.sys_user_roleid" :data="data"
:context="context"
:viewparams="viewparams"
:itemParam="{}"
style=""></app-span>
</app-form-item> </app-form-item>
</i-col> </i-col>
......
...@@ -51,5 +51,9 @@ public enum DEPredefinedFieldType { ...@@ -51,5 +51,9 @@ public enum DEPredefinedFieldType {
/** /**
* 不处理 * 不处理
*/ */
NONE NONE,
/**
* 其它
*/
ORDERVALUE
} }
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册