This commit is contained in:
thinkgem
2021-06-04 15:49:14 +08:00
parent f26ee82475
commit fc81166915
4 changed files with 29 additions and 44 deletions

View File

@@ -84,7 +84,6 @@ public @interface ExcelField {
/** /**
* 反射类型 * 反射类型
* MoneyType.class 金额类型转换(保留两位) * MoneyType.class 金额类型转换(保留两位)
* DateTimeType.class 日期时间类型转换 yyyy-MM-dd HH:mm:ss
*/ */
Class<? extends FieldType> fieldType() default FieldType.class; Class<? extends FieldType> fieldType() default FieldType.class;

View File

@@ -13,6 +13,7 @@
增行=New line 增行=New line
刷新=Refresh 刷新=Refresh
查看=View 查看=View
编辑=Edit
展开=Expand 展开=Expand
展开一级=Expand level 1 展开一级=Expand level 1
折叠=Collapse 折叠=Collapse

View File

@@ -13,6 +13,7 @@
增行=行作成 增行=行作成
刷新=リフレッシュ 刷新=リフレッシュ
查看=詳細 查看=詳細
编辑=編集
展开=展開 展开=展開
展开一级=一階層展開 展开一级=一階層展開
折叠=収束 折叠=収束

View File

@@ -216,7 +216,7 @@ $("#testDataChildDataGrid").dataGrid({
} }
} }
}, },
{header:'${text("下拉多选")}', name:'testSelectMultiple', width:120, {header:'${text("下拉多选")}', name:'testSelectMultiple', width:130,
editable:true, edittype:'select', editoptions:{multiple:true, 'class':'form-control', editable:true, edittype:'select', editoptions:{multiple:true, 'class':'form-control',
items: $.merge([], ${@DictUtils.getDictListJson('sys_menu_type')}), items: $.merge([], ${@DictUtils.getDictListJson('sys_menu_type')}),
itemLabel: 'dictLabel', itemValue: 'dictValue', dataInit: function(element){ itemLabel: 'dictLabel', itemValue: 'dictValue', dataInit: function(element){
@@ -232,14 +232,6 @@ $("#testDataChildDataGrid").dataGrid({
} }
} }
}, },
{header:'${text("复选框")}', name:'testCheckbox', width:100,
editable:true, edittype:'select', editoptions:{multiple:true, 'class':'form-control',
items: $.merge([], ${@DictUtils.getDictListJson('sys_menu_type')}),
itemLabel: 'dictLabel', itemValue: 'dictValue', dataInit: function(element){
$(element).select2().on("change",function(){$(this).resetValid()});
}
}
},
{header:'${text("日期选择")}', name:'testDate', width:150, {header:'${text("日期选择")}', name:'testDate', width:150,
formatter:'date', formatoptions:{srcformat:'Y-m-d H:i:s',newformat:'Y-m-d'}, formatter:'date', formatoptions:{srcformat:'Y-m-d H:i:s',newformat:'Y-m-d'},
editable:true, edittype:'text', editoptions:{'class':'form-control laydate', 'readonly':'true', editable:true, edittype:'text', editoptions:{'class':'form-control laydate', 'readonly':'true',
@@ -251,40 +243,32 @@ $("#testDataChildDataGrid").dataGrid({
} }
} }
}, },
{header:'${text("日期时间")}', name:'testDatetime', width:150, // {header:'${text("用户选择")}', name:'testUser', width:150,
formatter:'date', formatoptions:{srcformat:'Y-m-d H:i:s',newformat:'Y-m-d H:i:s'}, // formatter: function(val, obj, row, act){
editable:true, edittype:'text', editoptions:{'class':'form-control laydate', 'readonly':'true', // return js.val(row, 'testUser.userCode')+'|'+js.val(row, 'testUser.userName');
dataInit: function(element){ // }, editable: true, edittype: "custom", editoptions: {
laydate.render({elem:element, type:'datetime', format:'yyyy-MM-dd HH:mm'}); // custom_element: function(val, editOptions) {
} // return js.template('treeselectTpl', {
} // id: 'user_'+editOptions.id, title: '用户选择',
}, // name: 'testUser.userCode', value: val.split('|')[0],
{header:'${text("用户选择")}', name:'testUser', width:150, // labelName: 'testUser.userName', labelValue: val.split('|')[1],
formatter: function(val, obj, row, act){ // url: '${ctx}/sys/office/treeData?isLoadUser=true', cssClass: '', readonly: false
return js.val(row, 'testUser.userCode')+'|'+js.val(row, 'testUser.userName'); // });
}, editable: true, edittype: "custom", editoptions: { // },
custom_element: function(val, editOptions) { // custom_value: function(element, act){
return js.template('treeselectTpl', { // return {userCode: element.find('[type=hidden]').val(),
id: 'user_'+editOptions.id, title: '用户选择', // userName: element.find('[type=text]').val()};
name: 'testUser.userCode', value: val.split('|')[0], // },
labelName: 'testUser.userName', labelValue: val.split('|')[1], // dataInit: function(element){
url: '${ctx}/sys/office/treeData?isLoadUser=true', cssClass: '', readonly: false // // 初始化控件后设置只读模式(实例)
}); // // $(element).find('.form-control, .btn').addClass('disabled');
}, // }
custom_value: function(element, act){ // },
return {userCode: element.find('[type=hidden]').val(), // unformat: function(val, obj, cell){
userName: element.find('[type=text]').val()}; // return $('#user_'+obj.rowId+'_'+obj.colModel.name+'Code', cell).val();
}, // }
dataInit: function(element){ // },
// 初始化控件后设置只读模式(实例) {header:'${text("用户选择")}', name:'testUser2', width:150,
// $(element).find('.form-control, .btn').addClass('disabled');
}
},
unformat: function(val, obj, cell){
return $('#user_'+obj.rowId+'_'+obj.colModel.name+'Code', cell).val();
}
},
{header:'${text("列表选择")}', name:'testUser2', width:150,
formatter: function(val, obj, row, act){ formatter: function(val, obj, row, act){
return js.val(row, 'testUser.userCode')+'|'+js.val(row, 'testUser.userName'); return js.val(row, 'testUser.userCode')+'|'+js.val(row, 'testUser.userName');
}, editable: true, edittype: "custom", editoptions: { }, editable: true, edittype: "custom", editoptions: {