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

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

上级 0c784557
......@@ -185,6 +185,7 @@ export default {
type: "图书类型",
press: "图书出版社",
price: "图书价格",
booknumber: "图书数量",
},
nodata:"",
uiactions: {
......
......@@ -184,6 +184,7 @@ export default {
type: "图书类型",
press: "图书出版社",
price: "图书价格",
booknumber: "图书数量",
},
nodata:"",
uiactions: {
......
......@@ -160,6 +160,33 @@
</template>
</el-table-column>
</template>
<template v-if="getColumnState('booknumber')">
<el-table-column show-overflow-tooltip :prop="'booknumber'" :label="$t('entities.ibizbook.rowrules_grid.columns.booknumber')" :width="100" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.ibizbook.rowrules_grid.columns.booknumber')}}
</span>
</template>
<template v-slot="{row,column,$index}">
<template v-if="actualIsOpenEdit && !row.children">
<app-form-item :error="gridItemsModel[$index][column.property].error">
<input-box
:disabled="getColumnDisabled(row,column.property)"
v-model="row[column.property]"
type="number"
:precision="0"
style=""
@change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}">
</input-box>
</app-form-item>
</template>
<template v-if="!actualIsOpenEdit">
<app-span name='booknumber' editorType="NUMBER" :value="row.booknumber" dataType="INT" precision="0" ></app-span>
</template>
</template>
</el-table-column>
</template>
<template v-if="adaptiveState">
<el-table-column></el-table-column>
</template>
......@@ -639,7 +666,7 @@ export default class RowRulesBase extends Vue implements ControlInterface {
*
* @memberof RowRulesBase
*/
public defaultUpdateItems:Array<any> =[,,,,,];
public defaultUpdateItems:Array<any> =[,,,,,,];
/**
* 选中行数据
......@@ -762,6 +789,15 @@ export default class RowRulesBase extends Vue implements ControlInterface {
isEnableRowEdit: true,
enableCond: 3 ,
},
{
name: 'booknumber',
label: '图书数量',
langtag: 'entities.ibizbook.rowrules_grid.columns.booknumber',
show: true,
unit: 'PX',
isEnableRowEdit: true,
enableCond: 3 ,
},
]
/**
......@@ -852,6 +888,7 @@ export default class RowRulesBase extends Vue implements ControlInterface {
press: new FormItemModel(),
ibizbookname: new FormItemModel(),
price: new FormItemModel(),
booknumber: new FormItemModel(),
type: new FormItemModel(),
srfkey: new FormItemModel(),
}
......@@ -864,6 +901,27 @@ export default class RowRulesBase extends Vue implements ControlInterface {
* @memberof RowRulesBase
*/
public deRules:any = {
booknumber:[
{
type:"SIMPLE",
condOP:"GT",
ruleInfo:"",
isKeyCond:false,
paramValue:"0",
isNotMode:false,
deName:"booknumber",
},
],
author:[
{
type:"SIMPLE",
condOP:"ISNOTNULL",
ruleInfo:"",
isKeyCond:false,
isNotMode:false,
deName:"author",
},
],
};
/**
......@@ -876,6 +934,7 @@ export default class RowRulesBase extends Vue implements ControlInterface {
author: [
{ required: false, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: '图书作者 值不能为空', trigger: 'change' },
{ required: false, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: '图书作者 值不能为空', trigger: 'blur' },
{validator:(rule:any, value:any, callback:any)=>{return this.verifyDeRules("author",this.deRules,"AND",value).isPast},message: "作者名非空", trigger: 'blur' },
],
press: [
{ required: false, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: '图书出版社 值不能为空', trigger: 'change' },
......@@ -889,6 +948,11 @@ export default class RowRulesBase extends Vue implements ControlInterface {
{ required: false, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: '图书价格 值不能为空', trigger: 'change' },
{ required: false, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: '图书价格 值不能为空', trigger: 'blur' },
],
booknumber: [
{ required: false, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: '图书数量 值不能为空', trigger: 'change' },
{ required: false, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: '图书数量 值不能为空', trigger: 'blur' },
{validator:(rule:any, value:any, callback:any)=>{return this.verifyDeRules("booknumber",this.deRules,"AND",value).isPast},message: "图书数量大于0", trigger: 'blur' },
],
type: [
{ required: false, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: '图书类型 值不能为空', trigger: 'change' },
{ required: false, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: '图书类型 值不能为空', trigger: 'blur' },
......@@ -1484,7 +1548,7 @@ export default class RowRulesBase extends Vue implements ControlInterface {
* @memberof RowRulesBase
*/
public arraySpanMethod({row, column, rowIndex, columnIndex} : any) {
let allColumns:Array<any> = ['ibizbookname','author','type','press','price'];
let allColumns:Array<any> = ['ibizbookname','author','type','press','price','booknumber'];
if(row && row.children) {
if(columnIndex == (this.isSingleSelect ? 0:1)) {
return [1, allColumns.length+1];
......@@ -1569,6 +1633,7 @@ export default class RowRulesBase extends Vue implements ControlInterface {
type:'',
press:'',
price:'',
booknumber:'',
children: children
}
groupTree.push(tree);
......@@ -1601,6 +1666,7 @@ export default class RowRulesBase extends Vue implements ControlInterface {
type:'',
press:'',
price:'',
booknumber:'',
children: child
}
if(child && child.length > 0){
......@@ -1666,6 +1732,7 @@ export default class RowRulesBase extends Vue implements ControlInterface {
type:'',
press:'',
price:'',
booknumber:'',
children: children,
}
groupTree.push(tree);
......
......@@ -50,6 +50,12 @@ export default class RowRulesModel {
dataType: 'CURRENCY',
isEditable:true
},
{
name: 'booknumber',
prop: 'booknumber',
dataType: 'INT',
isEditable:true
},
{
name: 'ibizbookid',
prop: 'ibizbookid',
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册