|
@ -45,6 +45,8 @@ |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
<th:block th:include="include :: footer" /> |
|
|
<th:block th:include="include :: footer" /> |
|
|
|
|
|
<th:block th:include="include :: bootstrap-table-editable-js" /> |
|
|
|
|
|
<th:block th:include="include :: select2-js" /> |
|
|
<script th:inline="javascript"> |
|
|
<script th:inline="javascript"> |
|
|
var prefix = ctx + "erp/developModifyOrder"; |
|
|
var prefix = ctx + "erp/developModifyOrder"; |
|
|
var sysUnitClassDatas = [[${@dict.getType('sys_unit_class')}]]; |
|
|
var sysUnitClassDatas = [[${@dict.getType('sys_unit_class')}]]; |
|
@ -83,76 +85,6 @@ |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
var options = { |
|
|
|
|
|
id: "bootstrap-sub-table-developModify", |
|
|
|
|
|
// url: prefix + "/getDevelopModifyOrderList", |
|
|
|
|
|
showSearch: false, |
|
|
|
|
|
showRefresh: false, |
|
|
|
|
|
showToggle: false, |
|
|
|
|
|
showColumns: false, |
|
|
|
|
|
columns: [ |
|
|
|
|
|
{checkbox: true}, |
|
|
|
|
|
{field: 'index',align: 'center', title: "序号", |
|
|
|
|
|
formatter: function (value, row, index) { |
|
|
|
|
|
var columnIndex = $.common.sprintf("<input type='hidden' name='index' value='%s'>", $.table.serialNumber(index)); |
|
|
|
|
|
return columnIndex + $.table.serialNumber(index); |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{title: '物料索引id',field: 'materialId',align: 'center',visible: false}, |
|
|
|
|
|
{title: '料号',field: 'materialCode',align: 'center'}, |
|
|
|
|
|
{title: '物料名称',field: 'materialName',align: 'center'}, |
|
|
|
|
|
{title: '图片',field: 'photoUrl', |
|
|
|
|
|
formatter: function(value, row, index) { |
|
|
|
|
|
if(value == null || value == ""){ |
|
|
|
|
|
value = ""; |
|
|
|
|
|
return "<img src='' herf='' />"; |
|
|
|
|
|
} |
|
|
|
|
|
return $.table.imageView(value); |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{title: '物料类型',field: 'materialType',align: 'center', |
|
|
|
|
|
formatter: function(value, row, index) { |
|
|
|
|
|
return $.table.selectCategoryLabel(materialTypeDatas, value); |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{ title: '描述',field: 'describe',align: 'center'}, |
|
|
|
|
|
{title: '品牌',field: 'brand',align: 'center'}, |
|
|
|
|
|
{ title: '单位',field: 'unit',align: 'center', |
|
|
|
|
|
formatter: function(value, row, index) { |
|
|
|
|
|
return $.table.selectDictLabel(sysUnitClassDatas, value); |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{title: '半成品类型',field: 'processMethod',align: 'center', |
|
|
|
|
|
formatter: function(value, row, index) { |
|
|
|
|
|
return $.table.selectDictLabel(processMethodDatas, value); |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{ title: '对外售价',field: 'materialSole',}, |
|
|
|
|
|
{title: '国内税率',field: 'countTax',align: 'center',}, |
|
|
|
|
|
{ title: '美元汇率',field: 'usdTax', align: 'center',}, |
|
|
|
|
|
{field: 'materialNum',align: 'center',title: '物料的数量',}, |
|
|
|
|
|
{ title: '物料的不含税单价(RMB)',field: 'materialNoRmb',align: 'center',}, |
|
|
|
|
|
{title: '物料的不含税单价(美元)',field: 'materialNoUsd',align: 'center',}, |
|
|
|
|
|
{title: '修改详情',align: 'center', |
|
|
|
|
|
formatter:function formatterForm(value, row, index) { |
|
|
|
|
|
// 这里的代码会为每行生成一个表单 |
|
|
|
|
|
var form = $('<form></form>').append( |
|
|
|
|
|
$('<input/>', { type: 'text', value: row.name, name: 'name', placeholder: 'Name' }), |
|
|
|
|
|
$('<input/>', { type: 'email', value: row.email, name: 'email', placeholder: 'Email' }), |
|
|
|
|
|
$('<button/>', { type: 'submit' }).text('Submit') |
|
|
|
|
|
); |
|
|
|
|
|
form.on('submit', function(e) { |
|
|
|
|
|
e.preventDefault(); // 阻止表单默认提交行为 |
|
|
|
|
|
var formData = form.serializeArray(); // 序列化表单数据为数组 |
|
|
|
|
|
console.log(formData); // 在控制台输出表单数据 |
|
|
|
|
|
// 这里可以添加代码处理表单提交,例如发送到服务器等 |
|
|
|
|
|
}); |
|
|
|
|
|
return form; // 返回生成的表单HTML |
|
|
|
|
|
}}, |
|
|
|
|
|
] |
|
|
|
|
|
}; |
|
|
|
|
|
$.table.init(options); |
|
|
|
|
|
|
|
|
|
|
|
var option1 = { |
|
|
var option1 = { |
|
|
id: "bootstrap-sub-table-material", |
|
|
id: "bootstrap-sub-table-material", |
|
|
// url: prefix + "/list", |
|
|
// url: prefix + "/list", |
|
@ -192,31 +124,6 @@ |
|
|
}] |
|
|
}] |
|
|
}; |
|
|
}; |
|
|
$.table.init(option1); |
|
|
$.table.init(option1); |
|
|
|
|
|
|
|
|
var option2 = { |
|
|
|
|
|
id: "bootstrap-sub-table-biztoitem", |
|
|
|
|
|
// url: prefix + "/list", |
|
|
|
|
|
showSearch: false, |
|
|
|
|
|
showRefresh: false, |
|
|
|
|
|
showToggle: false, |
|
|
|
|
|
showColumns: false, |
|
|
|
|
|
modalName: "通知人", |
|
|
|
|
|
detailView: true, |
|
|
|
|
|
height: $(window).height() - 100, |
|
|
|
|
|
//指定父id列 |
|
|
|
|
|
columns: [ |
|
|
|
|
|
{checkbox: false}, |
|
|
|
|
|
{title: '通知人',field: 'item', }, |
|
|
|
|
|
{title: '确认时间',field: 'materialNo', }, |
|
|
|
|
|
{title: '操作',align: 'center', |
|
|
|
|
|
formatter: function(value, row, index) { |
|
|
|
|
|
var actions = []; |
|
|
|
|
|
actions.push('<a class="btn btn-danger btn-xs" href="javascript:void(0)" onclick="remove(\'' + row.id + '\')"><i class="fa fa-eye"></i> 删除</a> '); |
|
|
|
|
|
return actions.join(''); |
|
|
|
|
|
} |
|
|
|
|
|
}] |
|
|
|
|
|
}; |
|
|
|
|
|
$.table.init(option2); |
|
|
|
|
|
}); |
|
|
}); |
|
|
initAllLevelTable = function(index, row, $detail) { |
|
|
initAllLevelTable = function(index, row, $detail) { |
|
|
$("#"+"all_level_table_"+row.id).bootstrapTable({ |
|
|
$("#"+"all_level_table_"+row.id).bootstrapTable({ |
|
|