Commit 70f0dae4 authored by 季圣华's avatar 季圣华
Browse files

优化表结构

parent 13932441
This diff is collapsed.
...@@ -820,4 +820,86 @@ ROW_FORMAT=COMPACT ...@@ -820,4 +820,86 @@ ROW_FORMAT=COMPACT
-- 修改jsh_material_initial_stock表的删除字段 -- 修改jsh_material_initial_stock表的删除字段
-- -------------------------------------------------------- -- --------------------------------------------------------
alter table jsh_material_stock rename to jsh_material_initial_stock; alter table jsh_material_stock rename to jsh_material_initial_stock;
alter table jsh_material_initial_stock change delete_fag delete_flag varchar(1) NULL DEFAULT '0' COMMENT '删除标记,0未删除,1删除'; alter table jsh_material_initial_stock change delete_fag delete_flag varchar(1) NULL DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
\ No newline at end of file
-- --------------------------------------------------------
-- 时间 2020年07月20日
-- by jishenghua
-- 优化表和字段的格式
-- --------------------------------------------------------
alter table jsh_log change userID user_id bigint(20) DEFAULT NULL COMMENT '用户id';
alter table jsh_log change clientIP client_ip varchar(50) DEFAULT NULL COMMENT '客户端IP';
alter table jsh_log change createtime create_time datetime DEFAULT NULL COMMENT '创建时间';
alter table jsh_log change contentdetails content varchar(1000) DEFAULT NULL COMMENT '详情';
alter table jsh_log drop column remark;
alter table jsh_materialcategory rename to jsh_material_category;
alter table jsh_material_category change Id id bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键';
alter table jsh_material_category change Name name varchar(50) DEFAULT NULL COMMENT '名称';
alter table jsh_material_category change CategoryLevel category_level smallint(6) DEFAULT NULL COMMENT '等级';
alter table jsh_material_category change ParentId parent_id bigint(20) DEFAULT NULL COMMENT '上级id';
alter table jsh_materialproperty rename to jsh_material_property;
alter table jsh_material_property change nativeName native_name varchar(50) DEFAULT NULL COMMENT '原始名称';
alter table jsh_material_property change anotherName another_name varchar(50) DEFAULT NULL COMMENT '别名';
alter table jsh_material_property change delete_Flag delete_flag varchar(1) DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
alter table jsh_role change Id id bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键';
alter table jsh_role change Name name varchar(50) DEFAULT NULL COMMENT '名称';
alter table jsh_role change delete_Flag delete_flag varchar(1) DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
alter table jsh_person change Id id bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键';
alter table jsh_person change Type type varchar(20) DEFAULT NULL COMMENT '类型';
alter table jsh_person change Name name varchar(50) DEFAULT NULL COMMENT '姓名';
alter table jsh_person change delete_Flag delete_flag varchar(1) DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
alter table jsh_systemconfig rename to jsh_system_config;
alter table jsh_system_config change delete_Flag delete_flag varchar(1) DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
alter table jsh_account change Id id bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键';
alter table jsh_account change Name name varchar(50) DEFAULT NULL COMMENT '名称';
alter table jsh_account change SerialNo serial_no varchar(50) DEFAULT NULL COMMENT '编号';
alter table jsh_account change InitialAmount initial_amount decimal(24,6) DEFAULT NULL COMMENT '期初金额';
alter table jsh_account change CurrentAmount current_amount decimal(24,6) DEFAULT NULL COMMENT '当前余额';
alter table jsh_account change Remark remark varchar(100) DEFAULT NULL COMMENT '备注';
alter table jsh_account change IsDefault is_default bit(1) DEFAULT NULL COMMENT '是否默认';
alter table jsh_account change delete_Flag delete_flag varchar(1) DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
alter table jsh_functions rename to jsh_function;
alter table jsh_function change Id id bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键';
alter table jsh_function change Number number varchar(50) DEFAULT NULL COMMENT '编号';
alter table jsh_function change Name name varchar(50) DEFAULT NULL COMMENT '名称';
alter table jsh_function change PNumber parent_number varchar(50) DEFAULT NULL COMMENT '上级编号';
alter table jsh_function change URL url varchar(100) DEFAULT NULL COMMENT '链接';
alter table jsh_function change State state bit(1) DEFAULT NULL COMMENT '收缩';
alter table jsh_function change Sort sort varchar(50) DEFAULT NULL COMMENT '排序';
alter table jsh_function change Enabled enabled bit(1) DEFAULT NULL COMMENT '启用';
alter table jsh_function change Type type varchar(50) DEFAULT NULL COMMENT '类型';
alter table jsh_function change PushBtn push_btn varchar(50) DEFAULT NULL COMMENT '功能按钮';
alter table jsh_function change delete_Flag delete_flag varchar(1) DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
alter table jsh_userbusiness rename to jsh_user_business;
alter table jsh_user_business change Id id bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键';
alter table jsh_user_business change Type type varchar(50) DEFAULT NULL COMMENT '类别';
alter table jsh_user_business change KeyId key_id varchar(50) DEFAULT NULL COMMENT '主id';
alter table jsh_user_business change Value value varchar(10000) DEFAULT NULL COMMENT '值';
alter table jsh_user_business change BtnStr btn_str varchar(2000) DEFAULT NULL COMMENT '按钮权限';
alter table jsh_user_business change delete_Flag delete_flag varchar(1) DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
alter table jsh_unit change UName name varchar(50) DEFAULT NULL COMMENT '名称,支持多单位';
alter table jsh_unit change delete_Flag delete_flag varchar(1) DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
alter table jsh_inoutitem rename to jsh_in_out_item;
alter table jsh_in_out_item change Id id bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键';
alter table jsh_in_out_item change Name name varchar(50) DEFAULT NULL COMMENT '名称';
alter table jsh_in_out_item change Type type varchar(20) DEFAULT NULL COMMENT '类型';
alter table jsh_in_out_item change Remark remark varchar(100) DEFAULT NULL COMMENT '备注';
alter table jsh_in_out_item change delete_Flag delete_flag varchar(1) DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
alter table jsh_serial_number change material_Id material_id bigint(20) DEFAULT NULL COMMENT '产品表id';
alter table jsh_serial_number change serial_Number serial_number varchar(64) DEFAULT NULL COMMENT '序列号';
alter table jsh_serial_number change is_Sell is_sell varchar(1) DEFAULT '0' COMMENT '是否卖出,0未卖出,1卖出';
alter table jsh_serial_number change delete_Flag delete_flag varchar(1) DEFAULT '0' COMMENT '删除标记,0未删除,1删除';
alter table jsh_serial_number change create_Time create_time datetime DEFAULT NULL COMMENT '创建时间';
alter table jsh_serial_number change update_Time update_time datetime DEFAULT NULL COMMENT '更新时间';
alter table jsh_serial_number change depothead_Id depot_head_id bigint(20) DEFAULT NULL COMMENT '单据主表id,用于跟踪序列号流向';
\ No newline at end of file
...@@ -42,7 +42,7 @@ function initSelectInfo(lei) { ...@@ -42,7 +42,7 @@ function initSelectInfo(lei) {
} }
//按钮权限列表 //按钮权限列表
else if (lei == 3) { else if (lei == 3) {
var btnStr = userBusinessList[0].btnstr; var btnStr = userBusinessList[0].btnStr;
if (btnStr != null) { if (btnStr != null) {
var btnObj = JSON.parse(btnStr); var btnObj = JSON.parse(btnStr);
for (var j = 0; j < btnObj.length; j++) { for (var j = 0; j < btnObj.length; j++) {
...@@ -71,10 +71,10 @@ if (btnStrList.length > 0) { ...@@ -71,10 +71,10 @@ if (btnStrList.length > 0) {
} }
$.ajax({ $.ajax({
type: "post", type: "post",
url: "/functions/findMenu", url: "/function/findMenu",
data: ({ data: ({
pNumber: 0, pNumber: 0,
hasFunctions: functions hasFunction: functions
}), }),
dataType: "json", dataType: "json",
async: false, async: false,
......
...@@ -312,8 +312,8 @@ ...@@ -312,8 +312,8 @@
options += "<option value='many' class='many' data-manyAmount=''>多账户</option>"; options += "<option value='many' class='many' data-manyAmount=''>多账户</option>";
for(var i = 0 ;i < accountList.length;i++) { for(var i = 0 ;i < accountList.length;i++) {
var account = accountList[i]; var account = accountList[i];
options += '<option value="' + account.id + '" data-currentAmount="' + account.currentamount + '">' + account.name + '</option>'; options += '<option value="' + account.id + '" data-currentAmount="' + account.currentAmount + '">' + account.name + '</option>';
if(account.isdefault) { if(account.isDefault) {
defaultAccountId = account.id; //给账户赋值默认id defaultAccountId = account.id; //给账户赋值默认id
} }
} }
......
...@@ -124,13 +124,13 @@ ...@@ -124,13 +124,13 @@
columns: [[ columns: [[
{field: 'id', width: 35, align: "center", checkbox: true}, {field: 'id', width: 35, align: "center", checkbox: true},
{title: '名称', field: 'name', width: 100}, {title: '名称', field: 'name', width: 100},
{title: '编号', field: 'serialno', width: 150, align: "center"}, {title: '编号', field: 'serialNo', width: 150, align: "center"},
{title: '期初金额', field: 'initialamount', width: 100, align: "center"}, {title: '期初金额', field: 'initialAmount', width: 100, align: "center"},
{title: '当前余额', field: 'currentamount', width: 100, align: "center"}, {title: '当前余额', field: 'currentAmount', width: 100, align: "center"},
{ {
title: '是否默认', field: 'isdefault', width: 100, align: "center", title: '是否默认', field: 'isDefault', width: 100, align: "center",
formatter: function (value, rec) { formatter: function (value, rec) {
if (rec.isdefault) { if (rec.isDefault) {
return "<span style='color:green'>是</span>"; return "<span style='color:green'>是</span>";
} }
else { else {
...@@ -456,17 +456,14 @@ ...@@ -456,17 +456,14 @@
//编辑结算账户 //编辑结算账户
function editAccount(index) { function editAccount(index) {
var rowsdata = $("#tableData").datagrid("getRows")[index]; var rowsdata = $("#tableData").datagrid("getRows")[index];
var row = { $("#name").textbox("setValue", rowsdata.name);
name: rowsdata.name, $("#serialNo").textbox("setValue", rowsdata.serialNo);
serialNo: rowsdata.serialno, $("#initialAmount").textbox("setValue", rowsdata.initialAmount);
initialAmount: rowsdata.initialamount, $("#currentAmount").textbox("setValue", rowsdata.currentAmount);
currentAmount: rowsdata.currentamount, $("#remark").textbox("setValue", rowsdata.remark);
remark: rowsdata.remark
};
oldAccount = rowsdata.name; oldAccount = rowsdata.name;
$('#accountDlg').dialog('open').dialog('setTitle', '<img src="/js/easyui/themes/icons/pencil.png"/>&nbsp;编辑结算账户'); $('#accountDlg').dialog('open').dialog('setTitle', '<img src="/js/easyui/themes/icons/pencil.png"/>&nbsp;编辑结算账户');
$(".window-mask").css({width: webW, height: webH}); $(".window-mask").css({width: webW, height: webH});
$('#accountFM').form('load', row);
accountID = rowsdata.id; accountID = rowsdata.id;
url = '/account/update?id=' + rowsdata.id; url = '/account/update?id=' + rowsdata.id;
} }
...@@ -558,7 +555,7 @@ ...@@ -558,7 +555,7 @@
function showAccountInOutList(index) { function showAccountInOutList(index) {
var rowsdata = $("#tableData").datagrid("getRows")[index]; var rowsdata = $("#tableData").datagrid("getRows")[index];
var accountId = rowsdata.id; var accountId = rowsdata.id;
var initialAmount = rowsdata.initialamount; var initialAmount = rowsdata.initialAmount;
$('#accountDetailListDlg').dialog('open').dialog('setTitle', '<img src="/js/easyui/themes/icons/pencil.png"/>&nbsp;查看账户流水'); $('#accountDetailListDlg').dialog('open').dialog('setTitle', '<img src="/js/easyui/themes/icons/pencil.png"/>&nbsp;查看账户流水');
$(".window-mask").css({width: webW, height: webH}); $(".window-mask").css({width: webW, height: webH});
initAccountDetailData(accountId); initAccountDetailData(accountId);
......
...@@ -172,10 +172,10 @@ ...@@ -172,10 +172,10 @@
}, },
{title: '仓库名称', field: 'name', width: 200}, {title: '仓库名称', field: 'name', width: 200},
{title: '仓库地址', field: 'address', width: 200}, {title: '仓库地址', field: 'address', width: 200},
{title: '仓储费', field: 'warehousing', width: 60}, {title: '仓储费', field: 'warehousing', width: 100},
{title: '搬运费', field: 'truckage', width: 60}, {title: '搬运费', field: 'truckage', width: 100},
{title: '负责人', field: 'principalName', width: 60}, {title: '负责人', field: 'principalName', width: 100},
{title: '排序', field: 'sort', width: 60}, {title: '排序', field: 'sort', width: 80},
{ {
title: '是否默认', field: 'isDefault', width: 100, align: "center", title: '是否默认', field: 'isDefault', width: 100, align: "center",
formatter: function (value, rec) { formatter: function (value, rec) {
......
...@@ -153,7 +153,7 @@ ...@@ -153,7 +153,7 @@
{field: 'id', width: 35, align: "center", checkbox: true}, {field: 'id', width: 35, align: "center", checkbox: true},
{title: '编号 ', field: 'number', width: 80}, {title: '编号 ', field: 'number', width: 80},
{title: '名称', field: 'name', width: 100}, {title: '名称', field: 'name', width: 100},
{title: '上级编号', field: 'pnumber', width: 80}, {title: '上级编号', field: 'parentNumber', width: 80},
{title: '链接', field: 'url', width: 250}, {title: '链接', field: 'url', width: 250},
{title: '排序', field: 'sort', width: 60}, {title: '排序', field: 'sort', width: 60},
{ {
...@@ -257,7 +257,7 @@ ...@@ -257,7 +257,7 @@
if (r) { if (r) {
$.ajax({ $.ajax({
type: "post", type: "post",
url: "/functions/batchDeleteFunctionsByIds", url: "/function/batchDeleteFunctionsByIds",
dataType: "json", dataType: "json",
data: ({ data: ({
ids: functionsID ids: functionsID
...@@ -299,7 +299,7 @@ ...@@ -299,7 +299,7 @@
} }
$.ajax({ $.ajax({
type: "post", type: "post",
url: "/functions/batchDeleteFunctionsByIds", url: "/function/batchDeleteFunctionsByIds",
dataType: "json", dataType: "json",
async: false, async: false,
data: ({ data: ({
...@@ -339,7 +339,7 @@ ...@@ -339,7 +339,7 @@
iconBtnFun(); iconBtnFun();
oldFunctions = ""; oldFunctions = "";
functionsID = 0; functionsID = 0;
url = '/functions/add'; url = '/function/add';
} }
//保存信息 //保存信息
...@@ -380,7 +380,7 @@ ...@@ -380,7 +380,7 @@
var rowsdata = $("#tableData").datagrid("getRows")[index]; var rowsdata = $("#tableData").datagrid("getRows")[index];
$("#Number").textbox("setValue", rowsdata.number); $("#Number").textbox("setValue", rowsdata.number);
$("#Name").focus().textbox("setValue", rowsdata.name); $("#Name").focus().textbox("setValue", rowsdata.name);
$("#PNumber").textbox("setValue", rowsdata.pnumber); $("#PNumber").textbox("setValue", rowsdata.parentNumber);
$("#URL").textbox("setValue", rowsdata.url); $("#URL").textbox("setValue", rowsdata.url);
$("#State").attr("checked", rowsdata.state); $("#State").attr("checked", rowsdata.state);
$("#Sort").textbox("setValue", rowsdata.sort); $("#Sort").textbox("setValue", rowsdata.sort);
...@@ -389,8 +389,8 @@ ...@@ -389,8 +389,8 @@
$("#Type").textbox("setValue", rowsdata.type); $("#Type").textbox("setValue", rowsdata.type);
//点击icon图标弹出页面 //点击icon图标弹出页面
iconBtnFun(); iconBtnFun();
if (rowsdata.pushbtn) { if (rowsdata.pushBtn) {
var arr = rowsdata.pushbtn.split(","); var arr = rowsdata.pushBtn.split(",");
var pushBtnArray = []; var pushBtnArray = [];
for (var i = 0; i < arr.length; i++) { for (var i = 0; i < arr.length; i++) {
if (arr[i]) { if (arr[i]) {
...@@ -411,7 +411,7 @@ ...@@ -411,7 +411,7 @@
functionsID = rowsdata.id; functionsID = rowsdata.id;
//焦点在名称输入框==定焦在输入文字后面 //焦点在名称输入框==定焦在输入文字后面
$("#Name").val("").focus().val(rowsdata.name); $("#Name").val("").focus().val(rowsdata.name);
url = '/functions/update?id=' + rowsdata.id; url = '/function/update?id=' + rowsdata.id;
} }
//点击icon图标弹出页面 //点击icon图标弹出页面
...@@ -432,7 +432,7 @@ ...@@ -432,7 +432,7 @@
if (name.length > 0 && (oldFunctions.length == 0 || name != oldFunctions)) { if (name.length > 0 && (oldFunctions.length == 0 || name != oldFunctions)) {
$.ajax({ $.ajax({
type: "get", type: "get",
url: "/functions/checkIsNameExist", url: "/function/checkIsNameExist",
dataType: "json", dataType: "json",
async: false, async: false,
data: ({ data: ({
...@@ -480,7 +480,7 @@ ...@@ -480,7 +480,7 @@
var type = $.trim($("#searchType").val()); var type = $.trim($("#searchType").val());
$.ajax({ $.ajax({
type: "get", type: "get",
url: "/functions/list", url: "/function/list",
dataType: "json", dataType: "json",
data: ({ data: ({
search: JSON.stringify({ search: JSON.stringify({
......
...@@ -114,12 +114,12 @@ ...@@ -114,12 +114,12 @@
pageList: initPageNum, pageList: initPageNum,
columns: [[ columns: [[
{title: '操作模块', field: 'operation', width: 120}, {title: '操作模块', field: 'operation', width: 120},
{title: '操作详情', field: 'contentdetails', width: 350}, {title: '操作详情', field: 'content', width: 350},
{title: '操作人员', field: 'username', width: 100, align: "center"}, {title: '操作人员', field: 'userName', width: 100, align: "center"},
{title: '操作状态',field: 'status',width:80,align:"center",formatter:function(value){ {title: '操作状态',field: 'status',width:80,align:"center",formatter:function(value){
return value? "失败":"成功"; return value? "失败":"成功";
}}, }},
{title: '操作IP', field: 'clientip', width: 100, align: "center"}, {title: '操作IP', field: 'clientIp', width: 100, align: "center"},
{title: '操作时间', field: 'createTimeStr', width: 150, align: "center"} {title: '操作时间', field: 'createTimeStr', width: 150, align: "center"}
]], ]],
onLoadError: function () { onLoadError: function () {
...@@ -222,25 +222,25 @@ ...@@ -222,25 +222,25 @@
function showLogDetails(pageNo, pageSize) { function showLogDetails(pageNo, pageSize) {
var operation = $.trim($("#searchOperation").val()); var operation = $.trim($("#searchOperation").val());
var usernameID = $.trim($("#searchUsernameID").val()); var userId = $.trim($("#searchUsernameID").val());
var clientIp = $.trim($("#searchIP").val()); var clientIp = $.trim($("#searchIP").val());
var status = $.trim($("#searchStatus").val()); var status = $.trim($("#searchStatus").val());
var beginTime = $.trim($("#searchBeginTime").datebox("getValue")); var beginTime = $.trim($("#searchBeginTime").datebox("getValue"));
var endTime = $.trim($("#searchEndTime").datebox("getValue")); var endTime = $.trim($("#searchEndTime").datebox("getValue"));
var contentdetails = $.trim($("#searchDesc").val()); var content = $.trim($("#searchDesc").val());
$.ajax({ $.ajax({
type: "get", type: "get",
url: "/log/list", url: "/log/list",
dataType: "json", dataType: "json",
data: ({ data: ({
search: JSON.stringify({ search: JSON.stringify({
operation: operation, operation: operation,
usernameID: usernameID, userId: userId,
clientIp: clientIp, clientIp: clientIp,
status: status, status: status,
beginTime: beginTime, beginTime: beginTime,
endTime: endTime, endTime: endTime,
contentdetails: contentdetails content: content
}), }),
currentPage: pageNo, currentPage: pageNo,
pageSize: pageSize pageSize: pageSize
......
...@@ -64,7 +64,7 @@ ...@@ -64,7 +64,7 @@
$(function () { $(function () {
$('#tt').tree({ $('#tt').tree({
url: '/functions/findRoleFunctions?UBType=' + type + '&UBKeyId=' + url_id, url: '/function/findRoleFunction?UBType=' + type + '&UBKeyId=' + url_id,
animate: true, animate: true,
checkbox: true checkbox: true
}); });
......
...@@ -145,7 +145,7 @@ ...@@ -145,7 +145,7 @@
var arr = getValue.split("]["); var arr = getValue.split("][");
arr = arr.toString(); arr = arr.toString();
$.ajax({ $.ajax({
url: "/functions/findByIds", url: "/function/findByIds",
type: "get", type: "get",
data: { data: {
functionsIds: arr functionsIds: arr
......
...@@ -118,7 +118,7 @@ ...@@ -118,7 +118,7 @@
return str; return str;
} }
}, },
{title: '计量单位', field: 'uname', width: 200} {title: '计量单位', field: 'name', width: 200}
]], ]],
toolbar: [ toolbar: [
{ {
...@@ -356,7 +356,7 @@ ...@@ -356,7 +356,7 @@
dataType: "json", dataType: "json",
data: ({ data: ({
info: JSON.stringify({ info: JSON.stringify({
uname: name, name: name,
basicUnit: basicName, basicUnit: basicName,
otherUnit: otherName, otherUnit: otherName,
ratio: otherNum ratio: otherNum
......
...@@ -115,7 +115,7 @@ ...@@ -115,7 +115,7 @@
<input name="parentName" id="parentName" class="easyui-textbox" style="width: 180px;" readonly="readonly"/> <input name="parentName" id="parentName" class="easyui-textbox" style="width: 180px;" readonly="readonly"/>
<a href="javascript:void(0)" class="l-btn l-btn-plain" group="" id="lookForMaterialCategory"> <a href="javascript:void(0)" class="l-btn l-btn-plain" group="" id="lookForMaterialCategory">
<span class="l-btn-left"><span class="l-btn-text icon-search l-btn-icon-left" style="height: 20px;"></span></span></a> <span class="l-btn-left"><span class="l-btn-text icon-search l-btn-icon-left" style="height: 20px;"></span></span></a>
<input name="parentid" id="parentid" type="hidden"/> <input name="parentId" id="parentId" type="hidden"/>
</td> </td>
<td style="text-align: left;"></td> <td style="text-align: left;"></td>
</tr> </tr>
...@@ -362,7 +362,7 @@ ...@@ -362,7 +362,7 @@
var thisRows = res.data.page.rows; //属性列表 var thisRows = res.data.page.rows; //属性列表
for (var i = 0; i < thisRows.length; i++) { for (var i = 0; i < thisRows.length; i++) {
if (thisRows[i].enabled) { if (thisRows[i].enabled) {
mPropertyListShort += thisRows[i].nativename + ","; mPropertyListShort += thisRows[i].nativeName + ",";
} }
} }
if (mPropertyListShort) { if (mPropertyListShort) {
...@@ -906,9 +906,9 @@ ...@@ -906,9 +906,9 @@
//表格模板变更 //表格模板变更
$(".tb-other-info").html(""); $(".tb-other-info").html("");
for (var i = 0; i < mPropertyList.length; i++) { for (var i = 0; i < mPropertyList.length; i++) {
if (mPropertyList[i].nativename === "制造商") { if (mPropertyList[i].nativeName === "制造商") {
$(".tb-other-info").append(trMfrs); $(".tb-other-info").append(trMfrs);
$(".tr-mfrs td").first().text(mPropertyList[i].anothername); $(".tr-mfrs td").first().text(mPropertyList[i].anotherName);
if (mPropertyList[i].enabled) { if (mPropertyList[i].enabled) {
$(".tr-mfrs").show(); $(".tr-mfrs").show();
} }
...@@ -916,9 +916,9 @@ ...@@ -916,9 +916,9 @@
$(".tr-mfrs").hide(); $(".tr-mfrs").hide();
} }
} }
if (mPropertyList[i].nativename === "自定义1") { if (mPropertyList[i].nativeName === "自定义1") {
$(".tb-other-info").append(trOtherField1); $(".tb-other-info").append(trOtherField1);
$(".tr-otherField1 td").first().text(mPropertyList[i].anothername); $(".tr-otherField1 td").first().text(mPropertyList[i].anotherName);
if (mPropertyList[i].enabled) { if (mPropertyList[i].enabled) {
$(".tr-otherField1").show(); $(".tr-otherField1").show();
} }
...@@ -926,9 +926,9 @@ ...@@ -926,9 +926,9 @@
$(".tr-otherField1").hide(); $(".tr-otherField1").hide();
} }
} }
if (mPropertyList[i].nativename === "自定义2") { if (mPropertyList[i].nativeName === "自定义2") {
$(".tb-other-info").append(trOtherField2); $(".tb-other-info").append(trOtherField2);
$(".tr-otherField2 td").first().text(mPropertyList[i].anothername); $(".tr-otherField2 td").first().text(mPropertyList[i].anotherName);
if (mPropertyList[i].enabled) { if (mPropertyList[i].enabled) {
$(".tr-otherField2").show(); $(".tr-otherField2").show();
} }
...@@ -936,9 +936,9 @@ ...@@ -936,9 +936,9 @@
$(".tr-otherField2").hide(); $(".tr-otherField2").hide();
} }
} }
if (mPropertyList[i].nativename === "自定义3") { if (mPropertyList[i].nativeName === "自定义3") {
$(".tb-other-info").append(trOtherField3); $(".tb-other-info").append(trOtherField3);
$(".tr-otherField3 td").first().text(mPropertyList[i].anothername); $(".tr-otherField3 td").first().text(mPropertyList[i].anotherName);
if (mPropertyList[i].enabled) { if (mPropertyList[i].enabled) {
$(".tr-otherField3").show(); $(".tr-otherField3").show();
} }
...@@ -1156,7 +1156,7 @@ ...@@ -1156,7 +1156,7 @@
} }
var objInfo = $("#materialFM").serializeObject(); var objInfo = $("#materialFM").serializeObject();
objInfo.UnitId = $("#manyUnit").val(); objInfo.UnitId = $("#manyUnit").val();
objInfo.CategoryId =$("#parentid").val(); objInfo.CategoryId =$("#parentId").val();
//初始库存信息 //初始库存信息
var stockArr = []; var stockArr = [];
$("#initDepot input").each(function () { $("#initDepot input").each(function () {
...@@ -1221,7 +1221,7 @@ ...@@ -1221,7 +1221,7 @@
$("#Name").focus().textbox("setValue", rowsdata.name); $("#Name").focus().textbox("setValue", rowsdata.name);
$("#EnableSerialNumber").val(rowsdata.enableserialnumber=='1'?'1':'0'); $("#EnableSerialNumber").val(rowsdata.enableserialnumber=='1'?'1':'0');
//商品类别id //商品类别id
$("#parentid").val(rowsdata.categoryid); $("#parentId").val(rowsdata.categoryid);
//商品类别名称 //商品类别名称
$("#parentName").textbox("setValue", rowsdata.categoryName); $("#parentName").textbox("setValue", rowsdata.categoryName);
mId = rowsdata.categoryid; mId = rowsdata.categoryid;
...@@ -1397,7 +1397,7 @@ ...@@ -1397,7 +1397,7 @@
console.log(res.length); console.log(res.length);
if (res.length) { if (res.length) {
for (var i = 0; i < res.length; i++) { for (var i = 0; i < res.length; i++) {
options += '<option value="' + res[i].id + '">' + res[i].uname + '</option>'; options += '<option value="' + res[i].id + '">' + res[i].name + '</option>';
} }
$("#manyUnit").empty().append('<option value="">(空)</option>').append(options); $("#manyUnit").empty().append('<option value="">(空)</option>').append(options);
//下拉框事件 //下拉框事件
......
...@@ -111,7 +111,7 @@ ...@@ -111,7 +111,7 @@
//loadFilter: pagerFilter, //loadFilter: pagerFilter,
columns: [[ columns: [[
{field: 'id', width: 10, align: "center", hidden: true}, {field: 'id', width: 10, align: "center", hidden: true},
{title: '名称', field: 'nativename', width: 100}, {title: '名称', field: 'nativeName', width: 100},
{ {
title: '是否启用', field: 'enabled', width: 100, formatter: function (value, rec) { title: '是否启用', field: 'enabled', width: 100, formatter: function (value, rec) {
if (rec.enabled) { if (rec.enabled) {
...@@ -123,7 +123,7 @@ ...@@ -123,7 +123,7 @@
} }
}, },
{title: '排序', field: 'sort', width: 100}, {title: '排序', field: 'sort', width: 100},
{title: '别名', field: 'anothername', width: 100}, {title: '别名', field: 'anotherName', width: 100},
{ {
title: '操作', field: 'op', align: "center", width: 80, formatter: function (value, rec, index) { title: '操作', field: 'op', align: "center", width: 80, formatter: function (value, rec, index) {
var str = ''; var str = '';
...@@ -213,10 +213,10 @@ ...@@ -213,10 +213,10 @@
//编辑信息 //编辑信息
function editMaterialProperty(index) { function editMaterialProperty(index) {
var rowsdata = $("#tableData").datagrid("getRows")[index]; var rowsdata = $("#tableData").datagrid("getRows")[index];
$("#nativeName").text(rowsdata.nativename); $("#nativeName").text(rowsdata.nativeName);
$("#enabled").attr("checked", rowsdata.enabled == true ? true : false); $("#enabled").attr("checked", rowsdata.enabled == true ? true : false);
$("#sort").textbox("setValue", rowsdata.sort); $("#sort").textbox("setValue", rowsdata.sort);
$("#anotherName").textbox("setValue", rowsdata.anothername); $("#anotherName").textbox("setValue", rowsdata.anotherName);
$('#materialPropertyDlg').dialog('open').dialog('setTitle', '<img src="/js/easyui/themes/icons/pencil.png"/>&nbsp;编辑商品属性'); $('#materialPropertyDlg').dialog('open').dialog('setTitle', '<img src="/js/easyui/themes/icons/pencil.png"/>&nbsp;编辑商品属性');
$(".window-mask").css({width: webW, height: webH}); $(".window-mask").css({width: webW, height: webH});
//焦点在名称输入框==定焦在输入文字后面 //焦点在名称输入框==定焦在输入文字后面
......
...@@ -36,13 +36,13 @@ ...@@ -36,13 +36,13 @@
<input name="parentName" id="parentName" class="easyui-textbox" style="width: 200px;" readonly="readonly"/> <input name="parentName" id="parentName" class="easyui-textbox" style="width: 200px;" readonly="readonly"/>
<a href="javascript:void(0)" class="l-btn l-btn-plain" group="" id="lookForSelectMaterialCategory"> <a href="javascript:void(0)" class="l-btn l-btn-plain" group="" id="lookForSelectMaterialCategory">
<span class="l-btn-left"><span class="l-btn-text icon-search l-btn-icon-left" style="height: 20px;"></span></span></a> <span class="l-btn-left"><span class="l-btn-text icon-search l-btn-icon-left" style="height: 20px;"></span></span></a>
<input name="parentid" id="parentid" type="hidden"/> <input name="parentId" id="parentId" type="hidden"/>
</td> </td>
</tr> </tr>
<tr> <tr>
<td>名称</td> <td>名称</td>
<td style="padding:5px"> <td style="padding:5px">
<input name="Name" id="Name" class="easyui-textbox" <input name="name" id="name" class="easyui-textbox"
data-options="required:true,validType:'length[2,30]'" style="width: 200px;"/> data-options="required:true,validType:'length[2,30]'" style="width: 200px;"/>
<input name="id" id="id" type="hidden"/> <input name="id" id="id" type="hidden"/>
</td> </td>
...@@ -145,9 +145,9 @@ ...@@ -145,9 +145,9 @@
$('#materialCategoryFM').form('clear'); $('#materialCategoryFM').form('clear');
$('#materialCategoryDlg').dialog('open').dialog('setTitle', '<img src="/js/easyui/themes/icons/edit_add.png"/>&nbsp;修改商品类别信息'); $('#materialCategoryDlg').dialog('open').dialog('setTitle', '<img src="/js/easyui/themes/icons/edit_add.png"/>&nbsp;修改商品类别信息');
$(".window-mask").css({width: webW, height: webH}); $(".window-mask").css({width: webW, height: webH});
$("#Name").textbox("setValue", res.data.name).focus(); $("#name").textbox("setValue", res.data.name).focus();
$("#parentName").textbox("setValue", res.data.parentName); $("#parentName").textbox("setValue", res.data.parentName);
$("#parentid").val(res.data.parentId); $("#parentId").val(res.data.parentId);
$("#serialNo").textbox("setValue", res.data.serialNo); $("#serialNo").textbox("setValue", res.data.serialNo);
$("#sort").textbox("setValue", res.data.sort); $("#sort").textbox("setValue", res.data.sort);
$("#remark").textbox("setValue", res.data.remark); $("#remark").textbox("setValue", res.data.remark);
...@@ -250,7 +250,7 @@ ...@@ -250,7 +250,7 @@
//保存信息 //保存信息
$("#saveMaterialCategory").off("click").on("click", function () { $("#saveMaterialCategory").off("click").on("click", function () {
if (!$("#Name").val()) { if (!$("#name").val()) {
$.messager.alert('提示', '商品类别名称不能为空!', 'warning'); $.messager.alert('提示', '商品类别名称不能为空!', 'warning');
return; return;
} }
......
...@@ -56,12 +56,12 @@ ...@@ -56,12 +56,12 @@
initMCData(node.id); initMCData(node.id);
} else if(clickType == "editBtn") { } else if(clickType == "editBtn") {
$("#parentName").textbox("setValue", node.text); $("#parentName").textbox("setValue", node.text);
$("#parentid").val(node.id); $("#parentId").val(node.id);
} }
} }
else { else {
$("#parentName").textbox("setValue", node.text); $("#parentName").textbox("setValue", node.text);
$("#parentid").val(node.id); $("#parentId").val(node.id);
} }
$('#forSelectMaterialCategoryDlg').dialog('close'); $('#forSelectMaterialCategoryDlg').dialog('close');
} }
......
...@@ -88,14 +88,14 @@ ...@@ -88,14 +88,14 @@
pageList: initPageNum, pageList: initPageNum,
columns: [[ columns: [[
{title: '名称', field: 'name', width: 100}, {title: '名称', field: 'name', width: 100},
{title: '编号', field: 'serialno', width: 150, align: "center"}, {title: '编号', field: 'serialNo', width: 150, align: "center"},
{title: '期初金额', field: 'initialamount', width: 100, align: "center"}, {title: '期初金额', field: 'initialAmount', width: 100, align: "center"},
{title: '本月发生额', field: 'thismonthamount', width: 100, align: "center"}, {title: '本月发生额', field: 'thisMonthAmount', width: 100, align: "center"},
{title: '当前余额', field: 'currentamount', width: 100, align: "center"}, {title: '当前余额', field: 'currentAmount', width: 100, align: "center"},
{ {
title: '操作', field: 'op', width: 100, align: "center", formatter: function (value, rec) { title: '操作', field: 'op', width: 100, align: "center", formatter: function (value, rec) {
var str = ''; var str = '';
var rowInfo = rec.id + 'AaBb' + rec.name + 'AaBb' + rec.serialno + 'AaBb' + rec.initialamount + 'AaBb' + rec.currentamount; var rowInfo = rec.id + 'AaBb' + rec.name + 'AaBb' + rec.serialNo + 'AaBb' + rec.initialAmount + 'AaBb' + rec.currentAmount;
str += '<img src="/js/easyui/themes/icons/list.png" style="cursor: pointer;" onclick="showAccountInOutList(\'' + rowInfo + '\');"/>&nbsp;<a onclick="showAccountInOutList(\'' + rowInfo + '\');" style="text-decoration:none;color:black;" href="javascript:void(0)">流水</a>&nbsp;&nbsp;'; str += '<img src="/js/easyui/themes/icons/list.png" style="cursor: pointer;" onclick="showAccountInOutList(\'' + rowInfo + '\');"/>&nbsp;<a onclick="showAccountInOutList(\'' + rowInfo + '\');" style="text-decoration:none;color:black;" href="javascript:void(0)">流水</a>&nbsp;&nbsp;';
return str; return str;
} }
......
...@@ -84,6 +84,8 @@ ...@@ -84,6 +84,8 @@
type: "get", type: "get",
url: "/materialProperty/list", url: "/materialProperty/list",
dataType: "json", dataType: "json",
//设置为同步
async: false,
data: ({ data: ({
search: JSON.stringify({ search: JSON.stringify({
name: "" name: ""
...@@ -96,7 +98,7 @@ ...@@ -96,7 +98,7 @@
var thisRows = res.data.page.rows; var thisRows = res.data.page.rows;
for (var i = 0; i < thisRows.length; i++) { for (var i = 0; i < thisRows.length; i++) {
if (thisRows[i].enabled) { if (thisRows[i].enabled) {
mPropertyList += thisRows[i].nativename + ","; mPropertyList += thisRows[i].nativeName + ",";
} }
} }
if (mPropertyList) { if (mPropertyList) {
......
...@@ -187,6 +187,8 @@ ...@@ -187,6 +187,8 @@
type: "get", type: "get",
url: "/materialProperty/list", url: "/materialProperty/list",
dataType: "json", dataType: "json",
//设置为同步
async: false,
data: ({ data: ({
search: JSON.stringify({ search: JSON.stringify({
name: "" name: ""
...@@ -199,7 +201,7 @@ ...@@ -199,7 +201,7 @@
var thisRows = res.data.page.rows; var thisRows = res.data.page.rows;
for (var i = 0; i < thisRows.length; i++) { for (var i = 0; i < thisRows.length; i++) {
if (thisRows[i].enabled) { if (thisRows[i].enabled) {
mPropertyList += thisRows[i].nativename + ","; mPropertyList += thisRows[i].nativeName + ",";
} }
} }
if (mPropertyList) { if (mPropertyList) {
......
...@@ -88,6 +88,8 @@ ...@@ -88,6 +88,8 @@
type: "get", type: "get",
url: "/materialProperty/list", url: "/materialProperty/list",
dataType: "json", dataType: "json",
//设置为同步
async: false,
data: ({ data: ({
search: JSON.stringify({ search: JSON.stringify({
name: "" name: ""
...@@ -100,7 +102,7 @@ ...@@ -100,7 +102,7 @@
var thisRows = res.data.page.rows; var thisRows = res.data.page.rows;
for (var i = 0; i < thisRows.length; i++) { for (var i = 0; i < thisRows.length; i++) {
if (thisRows[i].enabled) { if (thisRows[i].enabled) {
mPropertyList += thisRows[i].nativename + ","; mPropertyList += thisRows[i].nativeName + ",";
} }
} }
if (mPropertyList) { if (mPropertyList) {
......
...@@ -155,6 +155,8 @@ ...@@ -155,6 +155,8 @@
type: "get", type: "get",
url: "/materialProperty/list", url: "/materialProperty/list",
dataType: "json", dataType: "json",
//设置为同步
async: false,
data: ({ data: ({
search: JSON.stringify({ search: JSON.stringify({
name: "" name: ""
...@@ -167,7 +169,7 @@ ...@@ -167,7 +169,7 @@
var thisRows = res.data.page.rows; var thisRows = res.data.page.rows;
for (var i = 0; i < thisRows.length; i++) { for (var i = 0; i < thisRows.length; i++) {
if (thisRows[i].enabled) { if (thisRows[i].enabled) {
mPropertyList += thisRows[i].nativename + ","; mPropertyList += thisRows[i].nativeName + ",";
} }
} }
if (mPropertyList) { if (mPropertyList) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment