|
|
|
@ -19,7 +19,7 @@
|
|
|
|
|
<input name='search_codeno' id='search_codeno' class='form-control' placeholder='编码'/>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
<input name='search_name' id='search_name' class='form-control' placeholder='数据名称'/>
|
|
|
|
|
<input name='search_name' id='search_name' class='form-control' placeholder='描述'/>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="form-group">
|
|
|
|
@ -57,67 +57,28 @@
|
|
|
|
|
</div>
|
|
|
|
|
<div class="modal-body">
|
|
|
|
|
<div class="row">
|
|
|
|
|
<form name="Distionaryform" method="post" id="Distionaryform" class="form-horizontal" action="${ctx}/backstage/distionary/save">
|
|
|
|
|
<form name="Distionaryform" method="post" id="Distionaryform" class="form-horizontal" action="${ctx}/ocr/dictionary/save">
|
|
|
|
|
<input name="distionarytypeid" id="distionarytypeid" value="${distionarytypeid}" type="hidden">
|
|
|
|
|
<input name="distionatygroupid" id="distionatygroupid" value="${distionarygroupid}" type="hidden">
|
|
|
|
|
<input name="groupId" id="distionatygroupid" value="${distionarygroupid}" type="hidden">
|
|
|
|
|
<input name="id" id="id" type="hidden">
|
|
|
|
|
<div class="row">
|
|
|
|
|
<div class="col-sm-6">
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label class="col-sm-3 control-label is-required">* 编码:</label>
|
|
|
|
|
<div class="col-sm-9">
|
|
|
|
|
<input name="codeno" id="codeno" class="form-control" placeholder="编码" class="form-control" type="text" maxlength='25' required>
|
|
|
|
|
<input name="value" id="value" class="form-control" placeholder="编码" class="form-control" type="text" maxlength='25' required>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="col-sm-6">
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label class="col-sm-3 control-label is-required">* 数据名称:</label>
|
|
|
|
|
<label class="col-sm-3 control-label is-required">* 描述:</label>
|
|
|
|
|
<div class="col-sm-9">
|
|
|
|
|
<input name="name" id="name" class="form-control" placeholder="数据名称" class="form-control" type="text" maxlength='75' required>
|
|
|
|
|
<input name="lable" id="lable" class="form-control" placeholder="描述" class="form-control" type="text" maxlength='75' required>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="row">
|
|
|
|
|
<div class="col-sm-6">
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label class="col-sm-3 control-label is-required">* 字典内容:</label>
|
|
|
|
|
<div class="col-sm-9">
|
|
|
|
|
<input name="content" id="content" class="form-control" placeholder="字典内容" class="form-control" type="text" maxlength='50' required>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="col-sm-6">
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label class="col-sm-3 control-label is-required">* 是否启用:</label>
|
|
|
|
|
<div class="col-sm-9">
|
|
|
|
|
<div class="radio i-checks">
|
|
|
|
|
<label>
|
|
|
|
|
<input type="radio" checked="" value="1" name="enabled"> <i></i>启用
|
|
|
|
|
</label>
|
|
|
|
|
<label>
|
|
|
|
|
<input type="radio" value="0" name="enabled"> <i></i>禁用
|
|
|
|
|
</label>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="row">
|
|
|
|
|
<div class="col-sm-6">
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label class="col-sm-3 control-label is-required">* 排序:</label>
|
|
|
|
|
<div class="col-sm-9">
|
|
|
|
|
<input name="sorting" id="sorting" class="form-control" number="true" placeholder="排序" class="form-control" type="text" required>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</form>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
@ -159,7 +120,7 @@
|
|
|
|
|
radioClass: 'iradio_square-green',
|
|
|
|
|
});
|
|
|
|
|
_tableListDistionary = $('#Distionary_list').bootstrapTable({
|
|
|
|
|
url: '${ctx}/backstage/admin/distionary/list',
|
|
|
|
|
url: '${ctx}/ocr/dictionary/list',
|
|
|
|
|
pagination: true, //是否显示分页(*)
|
|
|
|
|
pageNumber:1, //初始化加载第一页,默认第一页
|
|
|
|
|
pageSize: 10, //每页的记录行数(*)
|
|
|
|
@ -170,8 +131,8 @@
|
|
|
|
|
},
|
|
|
|
|
queryParams: function queryParams(params) {
|
|
|
|
|
return {
|
|
|
|
|
sortorder: "asc",
|
|
|
|
|
sortname: "SORTING",
|
|
|
|
|
sortorder: "desc",
|
|
|
|
|
sortname: "ID",
|
|
|
|
|
pagesize: params.limit,
|
|
|
|
|
start: (params.offset / params.limit) + 1,
|
|
|
|
|
search_codeno:'{"value":"' + $("#search_codeno").val() + '","op":"equal","type":"string"}',
|
|
|
|
@ -186,21 +147,8 @@
|
|
|
|
|
{checkbox: true},
|
|
|
|
|
// { width:150,valign: "middle",field:'distionarytypeid',title:'数据字典分类主键',sortable:true},
|
|
|
|
|
// { width:150,valign: "middle",field:'distionatygroupid',title:'数据字典分组主键',sortable:true},
|
|
|
|
|
{ width:150,valign: "middle",field:'codeno',title:'编码',sortable:true},
|
|
|
|
|
{ width:150,valign: "middle",field:'name',title:'数据名称',sortable:true},
|
|
|
|
|
{ width:150,valign: "middle",field:'content',title:'字典内容',sortable:true},
|
|
|
|
|
{ width:150,valign: "middle",field:'enabled',title:'是否启用',sortable:true,
|
|
|
|
|
formatter:function(value,oData,index) {
|
|
|
|
|
var listOperation = "禁用";
|
|
|
|
|
if(oData.enabled == "0"){
|
|
|
|
|
listOperation = "禁用";
|
|
|
|
|
}else if(oData.enabled == "1"){
|
|
|
|
|
listOperation = "启用";
|
|
|
|
|
}
|
|
|
|
|
return listOperation;
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
{ width:150,valign: "middle",field:'sorting',title:'排序字段',sortable:true},
|
|
|
|
|
{ width:150,valign: "middle",field:'value',title:'编码',sortable:true},
|
|
|
|
|
{ width:150,valign: "middle",field:'lable',title:'描述',sortable:true},
|
|
|
|
|
{
|
|
|
|
|
width:200,
|
|
|
|
|
field: 'id',
|
|
|
|
@ -216,7 +164,7 @@
|
|
|
|
|
]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
$("#Distionaryform").attr("action","${ctx}/backstage/admin/distionary/save");
|
|
|
|
|
$("#Distionaryform").attr("action","${ctx}/ocr/dictionary/save");
|
|
|
|
|
var distionaryForm1 = $('#Distionaryform');
|
|
|
|
|
var distionaryError1 = $('.alert-danger', distionaryForm1);
|
|
|
|
|
distionaryForm1.validate({
|
|
|
|
@ -293,26 +241,17 @@
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
function _distionaryAdd(){
|
|
|
|
|
$("#Distionaryform")[0].reset();
|
|
|
|
|
showDistionaryModel();
|
|
|
|
|
$("#Distionaryform")[0].reset();
|
|
|
|
|
}
|
|
|
|
|
function _distionaryUpdateData(jframeid,str){
|
|
|
|
|
|
|
|
|
|
parent.axgetXiaoyao('${ctx}/backstage/admin/distionary/getdata/' + str,null,false , function(data){
|
|
|
|
|
parent.axgetXiaoyao('${ctx}/ocr/dictionary/getdata/' + str,null,false , function(data){
|
|
|
|
|
if(data.code == "OK"){
|
|
|
|
|
$("#id").val(data.data.id);
|
|
|
|
|
$("#distionarytypeid").val(data.data.distionarytypeid);
|
|
|
|
|
$("#distionatygroupid").val(data.data.distionatygroupid);
|
|
|
|
|
$("#codeno").val(data.data.codeno);
|
|
|
|
|
$("#name").val(data.data.name);
|
|
|
|
|
$("#content").val(data.data.content);
|
|
|
|
|
|
|
|
|
|
$("#sorting").val(data.data.sorting);
|
|
|
|
|
|
|
|
|
|
if(data.data.enabled == 1){
|
|
|
|
|
$("input:radio[name='enabled']").eq(0).attr('checked',true);
|
|
|
|
|
}else if(data.data.enabled == 0){
|
|
|
|
|
$("input:radio[name='enabled']").eq(1).attr('checked',true);
|
|
|
|
|
}
|
|
|
|
|
$("#value").val(data.data.value);
|
|
|
|
|
$("#lable").val(data.data.lable);
|
|
|
|
|
showDistionaryModel();
|
|
|
|
|
}else{
|
|
|
|
|
parent.toastr.error("非法请求。");
|
|
|
|
@ -335,7 +274,7 @@
|
|
|
|
|
}
|
|
|
|
|
function t_delete(str){
|
|
|
|
|
parent.layer.closeAll('loading');
|
|
|
|
|
parent.axgetXiaoyao('${ctx}/backstage/admin/distionary/delmore' , {id:str},false, function(data){
|
|
|
|
|
parent.axgetXiaoyao('${ctx}/ocr/dictionary/delmore' , {id:str},false, function(data){
|
|
|
|
|
parent.layer.closeAll('loading');
|
|
|
|
|
if(data.code == "OK"){
|
|
|
|
|
swal(data.message, "您已经永久删除了这条信息。", "success");
|
|
|
|
|