diff --git a/erp_web/js/pages/materials/in_out.js b/erp_web/js/pages/materials/in_out.js index ba5f7819..4e245de0 100644 --- a/erp_web/js/pages/materials/in_out.js +++ b/erp_web/js/pages/materials/in_out.js @@ -48,7 +48,6 @@ initSelectInfo_account(); initSupplier(); //供应商 initSalesman(); //销售人员 - initGift(); //初始化礼品卡 initOutItemList(); //初始化支出项目 initMProperty(); //初始化商品属性 initTableData(); @@ -66,7 +65,14 @@ var supUrl = "/supplier/findBySelect_sup"; //供应商接口 var cusUrl = "/supplier/findBySelect_cus?UBType=UserCustomer&UBKeyId=" + kid; //客户接口 var retailUrl = "/supplier/findBySelect_retail"; //散户接口 - if(listTitle === "采购入库列表"){ + if(listTitle === "采购订单列表"){ + listType = "其它"; + listSubType = "采购订单"; + payTypeTitle = "隐藏"; + organUrl = supUrl; + amountNum = "CGDD"; + } + else if(listTitle === "采购入库列表"){ listType = "入库"; listSubType = "采购"; payTypeTitle = "付款"; @@ -101,6 +107,13 @@ organUrl = retailUrl; amountNum = "LSCK"; } + else if(listTitle === "销售订单列表"){ + listType = "其它"; + listSubType = "销售订单"; + payTypeTitle = "隐藏"; + organUrl = cusUrl; + amountNum = "XSDD"; + } else if(listTitle === "销售出库列表"){ listType = "出库"; listSubType = "销售"; @@ -129,20 +142,6 @@ organUrl = supUrl; amountNum = "DBCK"; } - else if(listTitle === "礼品充值列表"){ - listType = "出库"; - listSubType = "礼品充值"; - payTypeTitle = "隐藏"; - organUrl = supUrl; - amountNum = "LPCZ"; - } - else if(listTitle === "礼品销售列表"){ - listType = "出库"; - listSubType = "礼品销售"; - payTypeTitle = "隐藏"; - organUrl = supUrl; - amountNum = "LPXS"; - } else if(listTitle === "组装单列表"){ listType = "其它"; listSubType = "组装单"; @@ -310,34 +309,6 @@ }); } - //初始化-礼品卡 - function initGift(){ - if(listSubType == "礼品充值"|| listSubType == "礼品销售"){ - $('#GiftId').combobox({ - url: "/depot/findGiftByType?type=1", - valueField:'id', - textField:'name' - }); - $('#searchGiftId').combobox({ - url: "/depot/findGiftByType?type=1", - valueField:'id', - textField:'name' - }); - } - if(listSubType == "礼品销售"){ - $.ajax({ - type:"post", - url: "/supplier/findBySelectRetailNoPeople.action", //散户接口 - dataType: "json", - success: function (res){ - if(res && res[0]){ - orgDefaultId = res[0].id; - } - } - }); - } - } - //初始化收入项目列表 function initOutItemList(){ $.ajax({ @@ -525,19 +496,19 @@ isHiddenStatus = true; //隐藏 } var isShowLastMoneyColumn = false; //是否显示优惠后金额和价税合计,true为隐藏,false为显示 - if(listSubType == "调拨" || listSubType == "其它" || listSubType == "零售" || listSubType == "零售退货" || listSubType == "礼品充值" || listSubType == "礼品销售" || listSubType == "组装单" || listSubType == "拆卸单"){ + if(listSubType == "调拨" || listSubType == "其它" || listSubType == "零售" || listSubType == "零售退货" || listSubType == "采购订单" || listSubType == "销售订单" || listSubType == "组装单" || listSubType == "拆卸单"){ isShowLastMoneyColumn = true; //隐藏 } var isShowOrganNameColumn = false; //是否显示供应商、客户等信息,true为隐藏,false为显示 var organNameTitle = ""; //组织名称标题 - if(listSubType == "调拨" || listSubType == "礼品充值" || listSubType == "礼品销售" || listSubType == "组装单" || listSubType == "拆卸单"){ + if(listSubType == "调拨" || listSubType == "组装单" || listSubType == "拆卸单"){ isShowOrganNameColumn = true; //隐藏 } else { - if(listTitle == "采购入库列表" || listTitle == "采购退货列表" || listTitle == "其它入库列表"){ + if(listTitle == "采购订单列表" || listTitle == "采购入库列表" || listTitle == "采购退货列表" || listTitle == "其它入库列表"){ organNameTitle = "供应商名称"; } - else if(listTitle == "销售退货列表" || listTitle == "销售出库列表" || listTitle == "其它出库列表"){ + else if(listTitle == "销售订单列表" || listTitle == "销售退货列表" || listTitle == "销售出库列表" || listTitle == "其它出库列表"){ organNameTitle = "客户名称"; } else if(listTitle == "零售出库列表" || listTitle == "零售退货列表"){ @@ -637,7 +608,7 @@ var basicUnit = unitArr[0]; //基础单位 var otherUnit = unitArr[1]; //副单位 var unitSetInput =""; //单位 - if(listSubType === "采购" || listSubType === "采购退货"){ + if(listSubType === "采购订单" || listSubType === "采购" || listSubType === "采购退货"){ unitSetInput = rec.data[0].firstinunit; if(basicUnit==unitSetInput){ //基础单位等于选择的单位 loadRatio = 1; @@ -646,7 +617,7 @@ loadRatio = thisRatio; } } - else if(listSubType === "销售" || listSubType === "销售退货" || listTitle == "礼品充值" || listTitle == "礼品销售" || listSubType === "零售" || listSubType === "零售退货"){ + else if(listSubType === "销售订单" || listSubType === "销售" || listSubType === "销售退货" || listSubType === "零售" || listSubType === "零售退货"){ unitSetInput = rec.data[0].firstoutunit; if(basicUnit==unitSetInput){ //基础单位等于选择的单位 loadRatio = 1; @@ -757,30 +728,11 @@ anotherDepotUrl = '/depot/findDepotByUserId?UBType=UserDepot&UBKeyId='+kid; anotherDepotTextField = "depotName"; } - if(listSubType == "礼品充值"){ - /** - * who added the .action - * */ - isShowAnotherDepot = false; //礼品充值时候显示礼品卡 - anotherDepotHeadName = "礼品卡"; - anotherDepotUrl = "/depot/findGiftByType?type=1"; - anotherDepotTextField = "name"; - } - if(listSubType == "礼品销售"){ - /** - * who added the .action - * */ - depotHeadName = "礼品卡"; - depotUrl = "/depot/findGiftByType?type=1"; - depotTextField = "name"; - } - else { - depotHeadName = "仓库名称"; - depotUrl = '/depot/findDepotByUserId?UBType=UserDepot&UBKeyId='+kid; - depotTextField = "depotName"; - } + depotHeadName = "仓库名称"; + depotUrl = '/depot/findDepotByUserId?UBType=UserDepot&UBKeyId='+kid; + depotTextField = "depotName"; var isShowTaxColumn = false; //是否显示税率相关的列,true为隐藏,false为显示 - if(listSubType == "调拨" || listSubType == "其它" || listSubType == "零售" || listSubType == "零售退货" || listSubType == "礼品充值" || listSubType == "礼品销售" || listSubType == "组装单" || listSubType == "拆卸单"){ + if(listSubType == "调拨" || listSubType == "其它" || listSubType == "零售" || listSubType == "零售退货" || listSubType == "采购订单" || listSubType == "销售订单" || listSubType == "组装单" || listSubType == "拆卸单"){ isShowTaxColumn = true; //隐藏 } var isShowMaterialTypeColumn = true; //是否显示商品类型相关的列,true为隐藏,false为显示 @@ -911,7 +863,7 @@ var unitSetInput =""; //单位 body.find("[field='Unit']").find(input).prop("readonly","readonly"); //设置计量单位为只读 var loadRatio = 1; //在单位输入框上面加载比例字段 - if(listSubType === "采购" || listSubType === "采购退货"){ + if(listSubType === "采购" || listSubType === "采购退货" || listSubType === "采购订单"){ unitSetInput = res.data[0].firstinunit; //给单位文本框赋值 if(basicUnit==unitSetInput){ //基础单位等于选择的单位 loadRatio = 1; @@ -920,7 +872,7 @@ loadRatio = ratio; } } - else if(listSubType === "销售" || listSubType === "销售退货" || listSubType === "礼品充值" || listSubType === "礼品销售" || listSubType === "零售" || listSubType === "零售退货"){ + else if(listSubType === "销售" || listSubType === "销售退货" || listSubType === "销售订单" || listSubType === "零售" || listSubType === "零售退货"){ unitSetInput = res.data[0].firstoutunit; //给单位文本框赋值 if(basicUnit==unitSetInput){ //基础单位等于选择的单位 loadRatio = 1; @@ -958,10 +910,10 @@ var type = $(this).attr("data-type"); var UnitPrice = 0; if(type === "basic"){ - if(listTitle == "采购入库列表" || listTitle == "销售退货列表" || listTitle == "其它入库列表") { + if(listTitle == "采购订单列表" || listTitle == "采购入库列表" || listTitle == "销售退货列表" || listTitle == "其它入库列表") { UnitPrice = basicPresetPriceOne; } - else if(listTitle == "销售出库列表" || listTitle == "采购退货列表" || listTitle == "其它出库列表" || listTitle == "调拨出库列表" || listTitle == "礼品充值列表" || listTitle == "礼品销售列表") { + else if(listTitle == "销售订单列表" || listTitle == "销售出库列表" || listTitle == "采购退货列表" || listTitle == "其它出库列表" || listTitle == "调拨出库列表") { UnitPrice = basicPresetPriceTwo; } else if(listTitle == "零售出库列表" || listTitle == "零售退货列表"){ @@ -970,10 +922,10 @@ body.find("[field='Stock']").find(input).val(stock); //修改库存 } else if(type === "other"){ - if(listTitle == "采购入库列表" || listTitle == "销售退货列表" || listTitle == "其它入库列表") { + if(listTitle == "采购订单列表" || listTitle == "采购入库列表" || listTitle == "销售退货列表" || listTitle == "其它入库列表") { UnitPrice = otherPresetPriceOne; } - else if(listTitle == "销售出库列表" || listTitle == "采购退货列表" || listTitle == "其它出库列表" || listTitle == "调拨出库列表" || listTitle == "礼品充值列表" || listTitle == "礼品销售列表") { + else if(listTitle == "销售订单列表" || listTitle == "销售出库列表" || listTitle == "采购退货列表" || listTitle == "其它出库列表" || listTitle == "调拨出库列表") { UnitPrice = otherPresetPriceTwo; } else if(listTitle == "零售出库列表" || listTitle == "零售退货列表"){ @@ -1011,7 +963,7 @@ } } } - else if(listTitle == "采购入库列表" || listTitle == "销售退货列表" || listTitle == "其它入库列表") { + else if(listTitle == "采购订单列表" || listTitle == "采购入库列表" || listTitle == "销售退货列表" || listTitle == "其它入库列表") { if(res.data[0].unit) { //如果存在计量单位信息 detailPrice = presetPriceOne; } @@ -1024,7 +976,7 @@ } } } - else if(listTitle == "销售出库列表" || listTitle == "采购退货列表" || listTitle == "其它出库列表" || listTitle == "调拨出库列表" || listTitle == "礼品充值列表" || listTitle == "礼品销售列表") { + else if(listTitle == "销售订单列表" || listTitle == "销售出库列表" || listTitle == "采购退货列表" || listTitle == "其它出库列表" || listTitle == "调拨出库列表") { if(res.data[0].unit) { //如果存在计量单位信息 detailPrice = presetPriceTwo; } @@ -1175,18 +1127,9 @@ isShowAnotherDepot = false; //调拨时候显示对方仓库 anotherDepotHeadName = "调入仓库"; } - if(listSubType == "礼品充值"){ - isShowAnotherDepot = false; //礼品充值时候显示礼品卡 - anotherDepotHeadName = "礼品卡"; - } - if(listSubType == "礼品销售"){ - depotHeadName = "礼品卡"; - } - else { - depotHeadName = "仓库名称"; - } + depotHeadName = "仓库名称"; var isShowTaxColumn = false; //是否显示税率相关的列,true为隐藏,false为显示 - if(listSubType == "调拨" || listSubType == "其它" || listSubType == "零售" || listSubType == "零售退货" || listSubType == "礼品充值" || listSubType == "礼品销售" || listSubType == "组装单" || listSubType == "拆卸单"){ + if(listSubType == "调拨" || listSubType == "其它" || listSubType == "零售" || listSubType == "零售退货" || listSubType == "采购订单" || listSubType == "销售订单" || listSubType == "组装单" || listSubType == "拆卸单"){ isShowTaxColumn = true; //隐藏 } var isShowMaterialTypeColumn = true; //是否显示商品类型相关的列,true为隐藏,false为显示 @@ -1623,15 +1566,9 @@ return; } var depotHeadInfo = depotHeadTotalInfo.split("AaBb"); - if(listSubType==="礼品销售"){ - $("#GiftId").combobox('setValue',depotHeadInfo[1]); - } - else{ - $("#ProjectId").focus().val(depotHeadInfo[1]); - } + $("#ProjectId").focus().val(depotHeadInfo[1]); var ProjectId=depotHeadInfo[1]; - if(ProjectId!='') - { + if(ProjectId!='') { initSystemData_person(ProjectId); initSelectInfo_person(); } @@ -1651,9 +1588,6 @@ var TotalPrice = depotHeadInfo[14]; preTotalPrice = depotHeadInfo[14]; //记录前一次合计金额,用于扣预付款 $("#AllocationProjectId").val(depotHeadInfo[15]); - if(listSubType==="礼品充值"){ - $("#GiftId").combobox('setValue', depotHeadInfo[15]); - } oldNumber = depotHeadInfo[2]; //记录编辑前的单据编号 oldId = depotHeadInfo[0]; //记录单据Id var editTitle = listTitle.replace("列表","信息"); @@ -1933,7 +1867,13 @@ } } //输入框提示 - if(listTitle === "采购入库列表"){ + if(listTitle === "采购订单列表"){ + if(!$('#OrganId').combobox('getValue')){ + $.messager.alert('提示','请选择供应商!','warning'); + return; + } + } + else if(listTitle === "采购入库列表"){ if(!$('#OrganId').combobox('getValue')){ $.messager.alert('提示','请选择供应商!','warning'); return; @@ -1984,6 +1924,12 @@ } } + else if(listTitle === "销售订单列表"){ + if(!$('#OrganId').combobox('getValue')){ + $.messager.alert('提示','请选择购买单位!','warning'); + return; + } + } else if(listTitle === "销售出库列表"){ if(!$('#OrganId').combobox('getValue')){ $.messager.alert('提示','请选择购买单位!','warning'); @@ -2040,7 +1986,7 @@ accountMoneyList = accountMoneyList.replace(reg,""); //替换所有的双引号 accountMoneyArr = accountMoneyList.split(","); //转为数组 } - if(listSubType === "采购"||listSubType === "零售退货"||listSubType === "销售退货"){ + if(listSubType === "采购订单"||listSubType === "采购"||listSubType === "零售退货"||listSubType === "销售退货"){ //付款为负数 ChangeAmount = 0 - ChangeAmount; TotalPrice = 0 - TotalPrice; diff --git a/erp_web/pages/manage/depotGift.html b/erp_web/pages/manage/depotGift.html deleted file mode 100644 index 3b0bb1b7..00000000 --- a/erp_web/pages/manage/depotGift.html +++ /dev/null @@ -1,462 +0,0 @@ - - - - 礼品卡管理 - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
礼品卡名称: - -   描        述: - -     - 查询   - 重置 -
-
- - -
-
-
- -
-
- - - - - - - - - - - - - -
-
-
-
- 保存 - 取消 -
- - - - \ No newline at end of file diff --git a/erp_web/pages/materials/gift_recharge_list.html b/erp_web/pages/materials/gift_recharge_list.html deleted file mode 100644 index 93541e34..00000000 --- a/erp_web/pages/materials/gift_recharge_list.html +++ /dev/null @@ -1,135 +0,0 @@ - - - - 礼品充值 - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
单据编号: - - 商品信息: - - 单据日期: - - - - -   - 查询  - 重置 -
-
- - -
-
-
- -
-
- - - - - - - - - - - - - - - - - - -
单据日期: - - 单据编号: - -
- -
-
- -
- -
-
-
- 保存 - 取消 -
-
- - - - - - - - - - - - - - - - - - - -
单据日期: - - 单据编号: - -
- -
-
单据备注: - -
-
- - \ No newline at end of file diff --git a/erp_web/pages/materials/purchase_orders_list.html b/erp_web/pages/materials/purchase_orders_list.html new file mode 100644 index 00000000..ada1eb90 --- /dev/null +++ b/erp_web/pages/materials/purchase_orders_list.html @@ -0,0 +1,300 @@ + + + + 采购订单 + + + + + + + + + + + + + + + + + +
+ + + + + + + + + + + + + +
单据编号: + + 商品信息: + + 单据日期: + + - + +   + 查询  + 重置 +
+
+ + +
+
+
+ +
+
+ + + + + + + + + + + + + + + + + + +
供应商: +
+ +
+
+ 增加供应商 +
+
单据日期: + + 单据编号: + + +
+ +
+
+ +
+ +
+
+
+ 保存 + 取消 +
+
+ + + + + + + + + + + + + + + + + + + +
供应商: + + 单据日期: + + 单据编号: + +
+ +
+
单据备注: + +
+
+
+ + + + + + + + + + + +
合计:
+ + + + + + +
+
+
+ 保存 + 取消 +
+
+ + + + + + + + + + + +
结算账户金额
合计:
+ + + + + + +
+
+
+ 保存 + 取消 +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
名称 + + 联系人 + +
手机号码 + + 电子邮箱 + +
联系电话 + + 传真 + +
期初应收 + + 期初应付 + +
累计应收 + + 累计应付 + +
纳税人识别号 + + 税率 + +
开户行 + + 账号 + +
地址 + +
备注 + +
+
+
+
+ 保存 + 取消 +
+ + diff --git a/erp_web/pages/materials/gift_out_list.html b/erp_web/pages/materials/sale_orders_list.html similarity index 59% rename from erp_web/pages/materials/gift_out_list.html rename to erp_web/pages/materials/sale_orders_list.html index 2d577861..9295ce9f 100644 --- a/erp_web/pages/materials/gift_out_list.html +++ b/erp_web/pages/materials/sale_orders_list.html @@ -1,7 +1,7 @@ - 礼品销售 + 销售订单 @@ -51,17 +51,25 @@ -
-
- + + + + + - - - - @@ -102,7 +106,15 @@ closed="true" modal="true" cache="false" collapsible="false" closable="true">
单据日期:客户: + + 销售人员: + + 单据日期: 单据编号: + data-options="required:true,validType:'length[2,30]'" style="width: 150px;" readonly/>
- + + + + + @@ -110,10 +122,6 @@ - - - - @@ -130,5 +138,58 @@
单据日期:客户: + + 销售人员: + + 单据日期:
+
+ + + + + + + + + + + +
合计:
+ + + + + + +
+
+
+ 保存 + 取消 +
+
+ + + + + + + + + + + +
结算账户金额
合计:
+ + + + + + +
+
+
+ 保存 + 取消 +
+ \ No newline at end of file diff --git a/erp_web/pages/reports/gift_manage_report.html b/erp_web/pages/reports/gift_manage_report.html deleted file mode 100644 index f7e43d7a..00000000 --- a/erp_web/pages/reports/gift_manage_report.html +++ /dev/null @@ -1,270 +0,0 @@ - - - - 礼品卡统计 - - - - - - - - - - - - - - - -
- - - - - - - -
礼品卡: - -   - 查询 -
-
- - -
-
-
- - - - \ No newline at end of file diff --git a/sql/jsh_erp.sql b/sql/jsh_erp.sql index e49423cd..3c0aaa1f 100644 --- a/sql/jsh_erp.sql +++ b/sql/jsh_erp.sql @@ -5339,3 +5339,14 @@ ALTER TABLE jsh_materialcategory DROP FOREIGN KEY FK3EE7F725237A77D8; -- 修改根目录父节点id为-1 -- ---------------------------- update jsh_materialcategory set ParentId='-1' where id='1' + +-- ---------------------------- +-- 删除礼品卡管理、礼品充值、礼品销售、礼品卡统计的功能数据 +-- ---------------------------- +delete from jsh_functions where id in (213,214,215,216) + +-- ---------------------------- +-- 新增采购订单、销售订单的功能数据 +-- ---------------------------- +insert into `jsh_functions` values ('242', '050202', '采购订单', '0502', '../materials/purchase_orders_list.html', b'0', '0335',b'1', '电脑版', ''); +insert into `jsh_functions` values ('243', '060301', '销售订单', '0603', '../materials/sale_orders_list.html', b'0', '0392', b'1', '电脑版', ''); \ No newline at end of file diff --git a/sql/华夏ERP数据库设计汇总.xlsx b/sql/华夏ERP数据库设计汇总.xlsx index 634e8785..8a9e3ebf 100644 Binary files a/sql/华夏ERP数据库设计汇总.xlsx and b/sql/华夏ERP数据库设计汇总.xlsx differ