DefaultFunctionsCreator.cs 83 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808
  1. using System;
  2. using System.IO;
  3. using System.Linq;
  4. using System.Text;
  5. using Abp.Extensions;
  6. using ShwasherSys.BaseSysInfo;
  7. using ShwasherSys.EntityFramework;
  8. namespace ShwasherSys.Migrations.SeedData
  9. {
  10. public class DefaultFunctionsCreator
  11. {
  12. private readonly ShwasherDbContext _context;
  13. private string PermissionStr { get; set; }
  14. public DefaultFunctionsCreator(ShwasherDbContext context)
  15. {
  16. _context = context;
  17. }
  18. public void Create()
  19. {
  20. CreateFunctions("HTSystem", "后台管理系统", "0", 0, "Index", "Home", "icon-home", 0, 0, null, "", "", "Pages");
  21. OrderMenu1();
  22. FaHuo2();
  23. FaPiao3();
  24. ProductionOrder10();
  25. SemiProductStoreMenu11();
  26. JianYan12();
  27. Baozhuang13();
  28. Store14();
  29. InventoryCheck15();
  30. RawMaterialStore16();
  31. ScrapStore17();
  32. Company30();
  33. CustomerInfoMenu31();
  34. NotificationInfo32();
  35. ProductMenu33();
  36. Statistic40();
  37. B100();
  38. Sys101();
  39. Help102();
  40. WritePermission();
  41. }
  42. #region 订单,发货,发票
  43. public void OrderMenu1()
  44. {
  45. CreateFunctions("OrderInfo", "订单管理", "HTSystem", 0, "", "", "icon-system", 1, 1, "");
  46. CreateFunctions("OrderStatusMg", "订单状态", "OrderInfo", 1, "OrderStatusMg", "OrderInfo", "icon-menu", 1, 2);
  47. CreateFunctions("QueryPage", "查看页面", "OrderStatusMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  48. CreateFunctions("Print", "打印订单", "OrderStatusMg", 2, "", "", "icon-folder", 1, 3, "", "btn btn-default", "btnPrint");
  49. CreateFunctions("Query", "查看订单", "OrderStatusMg", 2, "", "", "icon-search", 2, 3, "", "btn btn-default", "btnQuery");
  50. CreateFunctions("Audit", "审核", "OrderStatusMg", 2, "", "", "icon-edit", 3, 3, "/api/services/app/OrderHeaders/Audit", "btn btn-default", "btnAudit");
  51. CreateFunctions("AuditItem", "审核订单明细", "OrderStatusMg", 2, "", "", "icon-edit", 4, 3, "/api/services/app/OrderItems/Audit", "btn btn-default", "N_btnAudit");
  52. CreateFunctions("EndItem", "结束订单明细", "OrderStatusMg", 2, "", "", "icon-edit", 5, 3, "/api/services/app/OrderItems/End", "btn btn-default", "N_btnEnd");
  53. CreateFunctions("SendItem", "发货", "OrderStatusMg", 2, "", "", "icon-edit",6, 3, "/api/services/app/OrderItems/SendOrderAction", "btn btn-default", "N_btnSend");
  54. CreateFunctions("ChangeStatus", "订单明细状态变更", "OrderStatusMg", 2, "", "", "icon-edit", 7, 3, "/api/services/app/OrderItems/ChangeOrderItemStatus", "btn btn-default", "N_btnChangeStatus");
  55. CreateFunctions("QueryOrderPrice", "查看订单价格", "OrderStatusMg", 2, "", "", "", 8, 3, "", "btn btn-default", "None");
  56. CreateFunctions("ReplaceSendItem", "替代发货", "OrderStatusMg", 2, "", "", "icon-edit", 9, 3, "/api/services/app/OrderItems/SendOrderAction", "btn btn-default", "N_btnSend");
  57. CreateFunctions("OrderMg", "订单维护", "OrderInfo", 1, "OrderMg", "OrderInfo", "icon-menu", 2, 2);
  58. CreateFunctions("Query", "查看页面", "OrderMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  59. CreateFunctions("Create", "创建订单", "OrderMg", 2, "", "", "icon-add", 1, 3, "/api/services/app/OrderHeaders/Create", "btn btn-default", "_btnCreate");
  60. CreateFunctions("Update", "修改订单", "OrderMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/OrderHeaders/Update", "btn btn-default", "N_btnUpdate");
  61. CreateFunctions("Delete", "删除订单", "OrderMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/OrderHeaders/Delete", "btn btn-default", "btnDelete");
  62. CreateFunctions("ShowDetail", "查看订单", "OrderMg", 2, "", "", "icon-search", 4, 3, "", "btn btn-default", "btnShow");
  63. CreateFunctions("CreateOrderItem", "创建订单明细", "OrderMg", 2, "", "", "icon-add", 4, 3, "/api/services/app/OrderItems/Create", "btn btn-default", "N_btnCreate");
  64. CreateFunctions("UpdateOrderItem", "修改订单明细", "OrderMg", 2, "", "", "icon-edit", 5, 3, "/api/services/app/OrderItems/Update", "btn btn-default", "N_btnUpdate");
  65. CreateFunctions("DeleteOrderItem", "删除订单明细", "OrderMg", 2, "", "", "icon-delete", 6, 3, "/api/services/app/OrderItems/Delete", "btn btn-default", "N_btnDelete");
  66. CreateFunctions("QueryOrderPrice", "查看订单价格", "OrderMg", 2, "", "", "", 7, 3, "", "btn btn-default", "None");
  67. CreateFunctions("OrderQueryMg", "订单查询", "OrderInfo", 1, "OrderQueryMg", "OrderInfo", "icon-menu", 3, 2);
  68. CreateFunctions("Query", "查看页面", "OrderQueryMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  69. CreateFunctions("ExportExcel", "导出Excel", "OrderQueryMg", 2, "", "", "icon-download", 1, 3, "/api/services/app/OrderItems/ExportExcel", "btn btn-default", "_btnExportExcel");
  70. CreateFunctions("QueryOrderPrice", "查看订单价格", "OrderQueryMg", 2, "", "", "", 2, 3, "", "btn btn-default", "None");
  71. CreateFunctions("NotCompleteOrderItem", "未完成订单明细", "OrderInfo", 1, "NotCompleteOrderItem", "OrderInfo", "icon-menu", 4, 2);
  72. CreateFunctions("Query", "查看页面", "NotCompleteOrderItem", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  73. CreateFunctions("ExportExcel", "导出Excel", "NotCompleteOrderItem", 2, "", "", "icon-download", 1, 3, "/api/services/app/OrderItems/ExportExcel", "btn btn-default", "_btnExportExcel");
  74. CreateFunctions("QueryOrderPrice", "查看订单价格", "NotCompleteOrderItem", 2, "", "", "", 2, 3, "", "btn btn-default", "None");
  75. CreateFunctions("OrderItemStatistics", "订单明细统计", "OrderInfo", 1, "OrderItemStatistics", "OrderInfo", "icon-menu", 5, 2);
  76. CreateFunctions("Query", "查看页面", "OrderItemStatistics", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  77. CreateFunctions("OrderSendWarn", "订单分批发货提醒", "OrderInfo", 1, "OrderSendWarn", "OrderInfo", "icon-menu", 6, 2);
  78. CreateFunctions("Query", "查看页面", "OrderSendWarn", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  79. CreateFunctions("ChangeStatus", "取消提醒(已发货)", "OrderSendWarn", 2, "", "", "icon-delete", 1, 3, "/api/services/app/OrderItems/ChangeOrderItemStatus", "btn btn-default", "btnChangeStatus");
  80. }
  81. public void FaHuo2()
  82. {
  83. CreateFunctions("SendGoods", "发货管理", "HTSystem", 0, "", "", "icon-system", 2, 1, "");
  84. CreateFunctions("OrderSendBillCreate", "发货单生成", "SendGoods", 1, "OrderSendBillCreate", "SendGoods", "icon-menu", 1, 2);
  85. CreateFunctions("QueryPage", "查看页面", "OrderSendBillCreate", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  86. CreateFunctions("Create", "生成发货单", "OrderSendBillCreate", 2, "", "", "icon-add", 1, 3, "", "btn btn-default", "btnCreate");
  87. CreateFunctions("Delete", "撤销发货", "OrderSendBillCreate", 2, "", "", "icon-delete", 2, 3, "", "btn btn-default", "btnDelete");
  88. CreateFunctions("OrderSendBillMg", "发货单维护", "SendGoods", 1, "OrderSendBillMg", "SendGoods", "icon-menu", 2, 2);
  89. CreateFunctions("QueryPage", "查看页面", "OrderSendBillMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  90. CreateFunctions("ShowSendBill", "查看发货单", "OrderSendBillMg", 2, "", "", "icon-search", 1, 3, "", "btn btn-default", "btnShow");
  91. CreateFunctions("Delete", "撤销发货单", "OrderSendBillMg", 2, "", "", "icon-delete", 2, 3, "/api/services/app/OrderSendBill/Delete", "btn btn-default", "btnDelete");
  92. CreateFunctions("OrderSendQueryMg", "客户发货统计", "SendGoods", 1, "OrderSendQueryMg", "SendGoods", "icon-menu", 3, 2);
  93. CreateFunctions("QueryPage", "查看页面", "OrderSendQueryMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  94. CreateFunctions("ExportExcel", "导出Excel", "OrderSendQueryMg", 2, "", "", "icon-download", 1, 3, "/api/services/app/OrderSend/ExportExcel", "btn btn-default", "_btnExportExcel");
  95. CreateFunctions("QueryPrice", "查看金额", "OrderSendQueryMg", 2, "", "", "icon-search", 1, 4, "", "btn btn-default", "N_btnQueryPrice");
  96. CreateFunctions("ReturnGoodMg", "退货退款信息", "SendGoods", 1, "ReturnGood", "SendGoods", "icon-menu", 4, 2);
  97. CreateFunctions("Query", "查看页面", "ReturnGoodMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  98. CreateFunctions("Create", "创建退货记录", "ReturnGoodMg", 2, "", "", "icon-add", 1, 3, "/api/services/app/ReturnGoodOrder/Create", "btn btn-default", "_btnCreate");
  99. CreateFunctions("Update", "修改记录", "ReturnGoodMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/ReturnGoodOrder/Update", "btn btn-default", "btnUpdate");
  100. CreateFunctions("Delete", "删除记录", "ReturnGoodMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ReturnGoodOrder/Delete", "btn btn-default", "btnDelete");
  101. CreateFunctions("ChangeState", "申请检验", "ReturnGoodMg", 2, "", "", "icon-delete", 4, 3, "/api/services/app/ReturnGoodOrder/ChangeState", "btn btn-default", "btnChangeState");
  102. CreateFunctions("ExportReturn", "导出退货单", "ReturnGoodMg", 2, "", "", "icon-delete", 5, 3, "/api/services/app/ReturnGoodOrder/ExportReturn", "btn btn-default", "btnExportReturn");
  103. CreateFunctions("RefundApply", "申请退款", "ReturnGoodMg", 2, "", "", "icon-edit", 6, 3, "/api/services/app/ReturnGoodOrder/RefundApply", "btn btn-default", "btnRefundApply");
  104. CreateFunctions("RefundConfirm", "确认退款", "ReturnGoodMg", 2, "", "", "icon-add", 7, 3, "/api/services/app/ReturnGoodOrder/RefundConfirm", "btn btn-default", "btnRefundConfirm");
  105. }
  106. public void FaPiao3()
  107. {
  108. CreateFunctions("InvoiceInfo", "发票管理", "HTSystem", 0, "", "", "icon-system", 3, 1, "");
  109. CreateFunctions("InvoiceCreate", "客户发票生成", "InvoiceInfo", 1, "InvoiceCreate", "InvoiceInfo", "icon-menu", 1, 2);
  110. CreateFunctions("QueryPage", "查看页面", "InvoiceCreate", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  111. CreateFunctions("Create", "生成发票", "InvoiceCreate", 2, "", "", "icon-add", 1, 3, "/api/services/app/OrderStickBill/Create", "btn btn-default", "btnCreate");
  112. CreateFunctions("InvoiceMg", "客户发票维护", "InvoiceInfo", 1, "InvoiceMg", "InvoiceInfo", "icon-menu", 2, 2);
  113. CreateFunctions("QueryPage", "查看页面", "InvoiceMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  114. CreateFunctions("ShowStickBill", "查看发票", "InvoiceMg", 2, "", "", "icon-search", 1, 3, "", "btn btn-default", "btnShow");
  115. CreateFunctions("Delete", "作废发票", "InvoiceMg", 2, "", "", "icon-delete", 2, 3, "/api/services/app/OrderStickBill/Delete", "btn btn-default", "btnDelete");
  116. CreateFunctions("CreateRed", "添加红冲发票", "InvoiceMg", 2, "", "", "icon-add", 3, 3, "/api/services/app/OrderStickBill/CreateRed", "btn btn-default", "_btnCreateRed");
  117. CreateFunctions("Update", "发票号修改", "InvoiceMg", 2, "", "", "icon-edit", 5, 3, "/api/services/app/OrderStickBill/UpdateStickNum", "btn btn-default", "btnUpdate");
  118. CreateFunctions("UpdateState", "确认收(退)款", "InvoiceMg", 2, "", "", "icon-edit", 6, 3, "/api/services/app/OrderStickBill/UpdateState", "btn btn-default", "btnUpdateState");
  119. CreateFunctions("ExportInvoices", "导出发票", "InvoiceMg", 2, "", "", "icon-edit", 7, 3, "/api/services/app/OrderStickBill/ExportInvoices", "btn btn-default", "_btnExportInvoices");
  120. //CreateFunctions("UpdateInvoiceDesc", "修改备注", "InvoiceMg", 2, "", "", "icon-edit", 8, 3, "/api/services/app/OrderStickBill/UpdateInvoiceDesc", "btn btn-default", "btnUpdateInvoiceDesc");
  121. CreateFunctions("StatementBill", "客户对账单维护", "InvoiceInfo", 1, "StatementBill", "InvoiceInfo", "icon-menu", 1, 2);
  122. CreateFunctions("QueryPage", "查看页面", "StatementBill", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  123. CreateFunctions("Create", "生成对账单", "StatementBill", 2, "", "", "icon-add", 1, 3, "/api/services/app/StatementBill/Create", "btn btn-default", "N_btnCreate");
  124. CreateFunctions("ShowStickBill", "查看对账单", "StatementBill", 2, "", "", "icon-search", 1, 3, "", "btn btn-default", "btnShow");
  125. CreateFunctions("Delete", "撤销对账单", "StatementBill", 2, "", "", "icon-delete", 2, 3, "/api/services/app/StatementBill/Delete", "btn btn-default", "btnDelete");
  126. CreateFunctions("UpdateDesc", "修改备注", "StatementBill", 2, "", "", "icon-edit", 3, 3, "/api/services/app/StatementBill/UpdateDesc", "btn btn-default", "btnUpdateDesc");
  127. }
  128. #endregion
  129. #region 生产,仓库,检验
  130. public void ProductionOrder10()
  131. {
  132. CreateFunctions("ProductionInfo", "生产管理", "HTSystem", 0, "", "", "icon-system", 10, 1, "");
  133. CreateFunctions("ProductionOrderMg", "排产信息维护", "ProductionInfo", 1, "ProductionOrderMg", "ProductionInfo", "icon-menu", 1, 2);
  134. CreateFunctions("Query", "查看页面", "ProductionOrderMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  135. CreateFunctions("Create", "创建排产单", "ProductionOrderMg", 2, "", "", "icon-add", 1, 3, "/api/services/app/ProductionOrders/Create", "btn btn-default", "_btnCreate");
  136. CreateFunctions("Update", "修改排产单", "ProductionOrderMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/ProductionOrders/Update", "btn btn-default", "btnUpdate");
  137. CreateFunctions("Delete", "删除排产单", "ProductionOrderMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ProductionOrders/Delete", "btn btn-default", "btnDelete");
  138. CreateFunctions("Export", "导出流转单", "ProductionOrderMg", 2, "", "", "icon-add", 3, 3, "/api/services/app/ProductionOrders/ExcelExport", "btn btn-default", "btnExport");
  139. CreateFunctions("OutProductionOrderMg", "外协信息维护", "ProductionInfo", 1, "OutProductionOrderMg", "ProductionInfo", "icon-menu", 2, 2);
  140. CreateFunctions("Query", "查看页面", "OutProductionOrderMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  141. CreateFunctions("Create", "创建外协单", "OutProductionOrderMg", 2, "", "", "icon-add", 2, 3, "/api/services/app/ProductionOrders/CreateOutProductionOrder", "btn btn-default", "N_btnCreate");
  142. CreateFunctions("Update", "修改外协单", "OutProductionOrderMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/ProductionOrders/UpdateOutProductionOrder", "btn btn-default", "btnUpdate");
  143. CreateFunctions("Delete", "删除外协单", "OutProductionOrderMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ProductionOrders/DeleteOutProductionOrder", "btn btn-default", "btnDelete");
  144. CreateFunctions("ExportOut", "导出外协单", "OutProductionOrderMg", 2, "", "", "icon-add", 4, 3, "/api/services/app/ProductionOrders/ExcelExportOut", "btn btn-default", "_btnExportOut");
  145. CreateFunctions("ProductionEnterStoreApplyMg", "生产入库申请", "ProductionInfo", 1, "ProductionEnterStoreApplyMg", "ProductionInfo", "icon-menu", 3, 2);
  146. CreateFunctions("Query", "查看页面", "ProductionEnterStoreApplyMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  147. CreateFunctions("Update", "修改入库申请", "ProductionEnterStoreApplyMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/ProductionOrders/UpdateEnterStoreApply", "btn btn-default", "btnUpdate");
  148. CreateFunctions("Cancel", "取消入库申请", "ProductionEnterStoreApplyMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ProductionOrders/CancelEnterStoreApply", "btn btn-default", "N_btnCancel");
  149. CreateFunctions("Recovery", "恢复入库申请", "ProductionEnterStoreApplyMg", 2, "", "", "icon-add", 3, 3, "/api/services/app/ProductionOrders/RecoveryEnterStoreApply", "btn btn-default", "N_btnRecovery");
  150. CreateFunctions("Confirm", "确认入库申请", "ProductionEnterStoreApplyMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ProductionOrders/ConfirmEnterStoreApply", "btn btn-default", "N_btnConfirm");
  151. CreateFunctions("Close", "取消入库申请", "ProductionEnterStoreApplyMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ProductionOrders/CloseEnterStoreApply", "btn btn-default", "N_btnClose");
  152. CreateFunctions("ProductionOutStoreApplyMg", "外协出库申请", "ProductionInfo", 1, "ProductionOutStoreApplyMg", "ProductionInfo", "icon-menu", 4, 2);
  153. CreateFunctions("Query", "查看页面", "ProductionOutStoreApplyMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  154. CreateFunctions("Create", "创建出库申请", "ProductionOutStoreApplyMg", 2, "", "", "icon-add", 1, 3, "/api/services/app/ProductionOrders/CreateOutStoreApply", "btn btn-default", "_btnCreate");
  155. CreateFunctions("Update", "修改出库申请", "ProductionOutStoreApplyMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/ProductionOrders/UpdateOutStoreApply", "btn btn-default", "N_btnUpdate");
  156. CreateFunctions("QueryStroe", "实时库存", "ProductionOutStoreApplyMg", 2, "", "", "icon-list", 3, 3, "", "btn btn-default", "_btnQueryStore");
  157. CreateFunctions("Cancel", "取消出库申请", "ProductionOutStoreApplyMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ProductionOrders/CancelOutStoreApply", "btn btn-default", "N_btnCancel");
  158. CreateFunctions("Recovery", "恢复出库申请", "ProductionOutStoreApplyMg", 2, "", "", "icon-add", 3, 3, "/api/services/app/ProductionOrders/RecoveryOutStoreApply", "btn btn-default", "N_btnRecovery");
  159. CreateFunctions("Confirm", "确认出库申请", "ProductionOutStoreApplyMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ProductionOrders/ConfirmOutStoreApply", "btn btn-default", "N_btnConfirm");
  160. CreateFunctions("Close", "关闭出库申请", "ProductionOutStoreApplyMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ProductionOrders/CloseOutStoreApply", "btn btn-default", "N_btnClose");
  161. CreateFunctions("RePlatingOutStoreApplyMg", "改镀出库申请", "ProductionInfo", 1, "RePlatingOutStoreApplyMg", "ProductionInfo", "icon-menu", 5, 2);
  162. //add
  163. CreateFunctions("Query", "查看页面", "RePlatingOutStoreApplyMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  164. CreateFunctions("Confirm", "确认出库申请", "RePlatingOutStoreApplyMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/ProductionOrders/UpdateFinishOutStoreApply", "btn btn-default", "N_btnConfirm");
  165. CreateFunctions("Cancel", "取消出库申请", "RePlatingOutStoreApplyMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ProductionOrders/CancelFinishOutStoreApply", "btn btn-default", "N_btnCancel");
  166. CreateFunctions("Export", "导出改镀申请单", "RePlatingOutStoreApplyMg", 2, "", "", "icon-delete", 4, 3, "/api/services/app/ProductionOrders/RePlatingExportApply", "btn btn-default", "N_btnExport");
  167. //CreateFunctions("Create", "创建外协单", "RePlatingOutStoreApplyMg", 2, "", "", "icon-add", 4, 3, "/api/services/app/ProductionOrders/CreateOutProductionOrder", "btn btn-default", "N_btnCreate");
  168. CreateFunctions("OutSourcingMissStoreMg", "生产入库缺失记录", "ProductionInfo", 1, "OutSourcingMissStoreMg", "ProductionInfo", "icon-menu", 6, 2);
  169. CreateFunctions("Query", "查看", "OutSourcingMissStoreMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  170. }
  171. public void SemiProductStoreMenu11()
  172. {
  173. CreateFunctions("SemiProductStoreInfo", "半成品仓库管理", "HTSystem", 0, "", "", "icon-system", 11, 1, "");
  174. CreateFunctions("SemiEnterStoreApplyMg", "半成品入库申请审核", "SemiProductStoreInfo", 1, "SemiEnterStoreApplyMg", "SemiProductStoreInfo", "icon-menu", 1, 2);
  175. CreateFunctions("Query", "查看页面", "SemiEnterStoreApplyMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  176. CreateFunctions("Update", "审核通过", "SemiEnterStoreApplyMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/SemiEnterStores/Audit", "btn btn-default", "btnUpdate");
  177. CreateFunctions("Refuse", "拒绝申请", "SemiEnterStoreApplyMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/SemiEnterStores/Refuse", "btn btn-default", "btnDelete");
  178. //CreateFunctions("QueryStore", "实时库存", "SemiEnterStoreApplyMg", 2, "", "", "icon-task", 4, 3, "", "btn btn-default", "_btnQueryStore");
  179. CreateFunctions("SemiEnterStoreMg", "半成品入库信息", "SemiProductStoreInfo", 1, "SemiEnterStoreMg", "SemiProductStoreInfo", "icon-menu", 2, 2);
  180. CreateFunctions("Query", "查看页面", "SemiEnterStoreMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  181. CreateFunctions("SemiOutStoreApplyMg", "半成品出库申请审核", "SemiProductStoreInfo", 1, "SemiOutStoreApplyMg", "SemiProductStoreInfo", "icon-menu", 3, 2);
  182. CreateFunctions("Query", "查看页面", "SemiOutStoreApplyMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  183. CreateFunctions("Update", "审核通过", "SemiOutStoreApplyMg", 2, "", "", "icon-edit", 1, 3, "/api/services/app/SemiOutStore/Audit", "btn btn-default", "btnUpdate");
  184. CreateFunctions("Refuse", "拒绝申请", "SemiOutStoreApplyMg", 2, "", "", "icon-delete", 2, 3, "/api/services/app/SemiOutStore/Refuse", "btn btn-default", "btnDelete");
  185. //CreateFunctions("QueryStore", "实时库存", "SemiOutStoreApplyMg", 2, "", "", "icon-task", 4, 3, "", "btn btn-default", "_btnQueryStore");
  186. CreateFunctions("SemiOutStoreMg", "半成品出库信息", "SemiProductStoreInfo", 1, "SemiOutStoreMg", "SemiProductStoreInfo", "icon-menu", 4, 2);
  187. CreateFunctions("Query", "查看页面", "SemiOutStoreMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  188. CreateFunctions("CurrentSemiStoreHouseMg", "半成品库存信息", "SemiProductStoreInfo", 1, "CurrentSemiStoreHouseMg", "SemiProductStoreInfo", "icon-menu", 5, 2);
  189. CreateFunctions("Query", "查看页面", "CurrentSemiStoreHouseMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  190. CreateFunctions("PackageApply", "申请包装", "CurrentSemiStoreHouseMg", 2, "", "", "",1, 3, "/api/services/app/SemiOutStore/PackageApply", "btn btn-default", "btnPackage");
  191. CreateFunctions("UpdateKgWeight", "修改千斤重", "CurrentSemiStoreHouseMg", 2, "", "", "",2, 3, "/api/services/app/CurrentSemiStoreHouses/UpdateKgWeight", "btn btn-default", "N_btnUpdateKgWeight");
  192. CreateFunctions("AddEnter", "入库平衡", "CurrentSemiStoreHouseMg", 2, "", "", "icon-add", 3, 3, "/api/services/app/CurrentSemiStoreHouses/AddEnter", "btn btn-default", "_btnAddEnter");
  193. CreateFunctions("AddOut", "出库平衡", "CurrentSemiStoreHouseMg", 2, "", "", "icon-delete", 4, 3, "/api/services/app/CurrentSemiStoreHouses/AddOut", "btn btn-default", "N_btnAddOut");
  194. CreateFunctions("ChangeStoreHouse", "仓库移库", "CurrentSemiStoreHouseMg", 2, "", "", "icon-edit", 5, 3, "/api/services/app/CurrentSemiStoreHouses/ChangeStoreHouse", "btn btn-default", "btnChangeStoreHouse");
  195. CreateFunctions("CurrentSemiStoreQueryMg", "半成品库存数量查询", "SemiProductStoreInfo", 1, "CurrentSemiStoreHouseQueryMg", "SemiProductStoreInfo", "icon-menu", 6, 2);
  196. CreateFunctions("Query", "查看页面", "CurrentSemiStoreQueryMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  197. CreateFunctions("Print", "库存报表打印", "CurrentSemiStoreQueryMg", 2, "", "", "icon-search", 2, 3, "", "btn btn-default", "_btnPrint");
  198. CreateFunctions("QueryEnterOut", "查看进出货明细信息", "CurrentSemiStoreQueryMg", 2, "", "", "icon-search", 3, 3, "", "btn btn-default", "N_btnPrint");
  199. }
  200. public void JianYan12()
  201. {
  202. CreateFunctions("ProductInspect", "技术检验管理", "HTSystem", 0, "", "", "icon-system", 12, 1, "");
  203. CreateFunctions("ProductItemInspectMg", "半成品入库检验", "ProductInspect", 1, "ProductItem", "ProductInspect", "icon-menu", 1, 2);
  204. CreateFunctions("Query", "查看页面", "ProductItemInspectMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  205. CreateFunctions("Check", "检验合格", "ProductItemInspectMg", 2, "", "", "icon-add", 1, 3, "/api/services/app/ProductInspect/Check", "btn btn-default", "btnCheck");
  206. CreateFunctions("UnCheck", "检验不合格", "ProductItemInspectMg", 2, "", "", "icon-delete", 2, 3, "/api/services/app/ProductInspect/UnCheck", "btn btn-default", "btnUnCheck");
  207. CreateFunctions("ShowUnqualified", "不合格查看", "ProductItemInspectMg", 2, "", "", "icon-search", 2, 3, "/api/services/app/ProductInspect/UnCheck", "btn btn-default", "btnUnCheck");
  208. CreateFunctions("DisqualifiedProductMg", "退货产品处理", "ProductInspect", 1, "DisqualifiedProduct", "ProductInspect", "icon-menu", 2, 2);
  209. CreateFunctions("Query", "查看页面", "DisqualifiedProductMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  210. CreateFunctions("CheckDowngrade", "检验选项", "DisqualifiedProductMg", 2, "", "", "icon-add", 1, 3, "/api/services/app/DisqualifiedProduct/CheckDowngrade", "btn btn-default", "btnCheckDowngrade");
  211. CreateFunctions("UseDowngrade", "降级使用", "DisqualifiedProductMg", 2, "", "", "icon-add", 2, 3, "/api/services/app/DisqualifiedProduct/UseDowngrade", "btn btn-default", "btnUseDowngrade");
  212. //CreateFunctions("Scrapped", "报废处理", "DisqualifiedProductMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/DisqualifiedProduct/Scrapped", "btn btn-default", "btnScrap");
  213. CreateFunctions("ConfirmScrapped", "确认报废", "DisqualifiedProductMg", 2, "", "", "icon-delete", 4, 3, "/api/services/app/DisqualifiedProduct/ConfirmScrapped", "btn btn-default", "btnConfirmScrapped");
  214. CreateFunctions("UnScrapped", "拒绝报废", "DisqualifiedProductMg", 2, "", "", "icon-delete", 5, 3, "/api/services/app/DisqualifiedProduct/UnScrapped", "btn btn-default", "btnUnScrapped");
  215. CreateFunctions("DisqualifiedSemiProductMg", "不合格半成品处理", "ProductInspect", 1, "DisqualifiedSemiProduct", "ProductInspect", "icon-menu", 3, 2);
  216. CreateFunctions("Query", "查看页面", "DisqualifiedSemiProductMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  217. CreateFunctions("CheckDowngrade", "检验选项", "DisqualifiedSemiProductMg", 2, "", "", "icon-add", 1, 3, "/api/services/app/DisqualifiedProduct/CheckDowngrade", "btn btn-default", "btnCheckDowngrade");
  218. CreateFunctions("UseDowngrade", "降级使用", "DisqualifiedSemiProductMg", 2, "", "", "icon-add", 2, 3, "/api/services/app/DisqualifiedProduct/UseDowngrade", "btn btn-default", "btnUseDowngrade");
  219. //CreateFunctions("Scrapped", "报废处理", "DisqualifiedProductMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/DisqualifiedProduct/Scrapped", "btn btn-default", "btnScrap");
  220. CreateFunctions("ConfirmScrapped", "确认报废", "DisqualifiedSemiProductMg", 2, "", "", "icon-delete", 4, 3, "/api/services/app/DisqualifiedProduct/ConfirmScrapped", "btn btn-default", "btnConfirmScrapped");
  221. CreateFunctions("UnScrapped", "拒绝报废", "DisqualifiedSemiProductMg", 2, "", "", "icon-delete", 5, 3, "/api/services/app/DisqualifiedProduct/UnScrapped", "btn btn-default", "btnUnScrapped");
  222. //CreateFunctions("AntiPlating", "确认反镀", "DisqualifiedProductMg", 2, "", "", "icon-delete", 6, 3, "/api/services/app/DisqualifiedProduct/AntiPlating", "btn btn-default", "btnAntiPlating");
  223. CreateFunctions("ProductInspectMg", "检验报告生成", "ProductInspect", 1, "Index", "ProductInspect", "icon-menu", 3, 2);
  224. CreateFunctions("Query", "查看页面", "ProductInspectMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  225. CreateFunctions("Template", "报告模板", "ProductInspectMg", 2, "", "", "icon-task", 1, 3, "/api/services/app/ProductInspect/Template", "btn btn-default", "_btnTemplate");
  226. CreateFunctions("Create", "添加报告", "ProductInspectMg", 2, "", "", "icon-add", 2, 3, "/api/services/app/ProductInspect/CreateInspect", "btn btn-default", "btnCreate");
  227. CreateFunctions("Export", "导出信息", "ProductInspectMg", 2, "", "", "icon-add", 3, 3, "/api/services/app/ProductInspect/ExportInspect", "btn btn-default", "_btnExport");
  228. CreateFunctions("InspectReport", "检验报告确认", "ProductInspect", 1, "Report", "ProductInspect", "icon-menu", 4, 2);
  229. CreateFunctions("Query", "查看页面", "InspectReport", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  230. CreateFunctions("Update", "修改报告", "InspectReport", 2, "", "", "icon-edit", 1, 3, "/api/services/app/ProductInspect/UpdateInspect", "btn btn-default", "N_btnUpdate");
  231. CreateFunctions("ConfirmReport", "确认最终报告", "InspectReport", 2, "", "", "icon-edit", 2, 3, "/api/services/app/ProductInspect/ConfirmReport", "btn btn-default", "btnConfirmReport");
  232. CreateFunctions("QueryReport", "查看报告", "InspectReport", 2, "", "", "icon-task", 3, 3, "/api/services/app/ProductInspect/QueryReport", "btn btn-default", "btnQueryReport");
  233. }
  234. public void Baozhuang13()
  235. {
  236. CreateFunctions("PackInfo", "包装管理", "HTSystem", 0, "", "", "icon-system", 13, 1, "");
  237. //CreateFunctions("PackInfoApply", "包装申请", "PackInfo", 1, "PackInfoApply", "PackInfo", "icon-menu", 1, 2);
  238. //CreateFunctions("Query", "查看页面", "PackInfoApply", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  239. //CreateFunctions("Create", "发起出库申请", "PackInfoApply", 2, "", "", "icon-edit", 1, 3, "/api/services/app/PackInfoApply/CreatePackInfoApply", "btn btn-default", "_btnCreate");
  240. //CreateFunctions("Update", "修改出库申请", "PackInfoApply", 2, "", "", "icon-edit", 2, 3, "/api/services/app/PackInfoApply/UpdatePackInfoApply", "btn btn-default", "btnUpdate");
  241. //CreateFunctions("Delete", "取消出库申请", "PackInfoApply", 2, "", "", "icon-delete", 3, 3, "/api/services/app/PackInfoApply/DeletePackInfoApply", "btn btn-default", "btnDelete");
  242. CreateFunctions("PackageApplyInfo", "包装申请信息查询", "PackInfo", 1, "PackageApplyInfo", "PackInfo", "icon-menu", 1, 2);
  243. CreateFunctions("Query", "查看页面", "PackageApplyInfo", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  244. CreateFunctions("PackInfoMg", "包装信息维护", "PackInfo", 1, "Index", "PackInfo", "icon-menu", 2, 2);
  245. CreateFunctions("Query", "查看页面", "PackInfoMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  246. CreateFunctions("Create", "确认包装", "PackInfoMg", 2, "", "", "icon-add", 1, 3, "/api/services/app/PackInfoApply/CreatePackInfo", "btn btn-default", "btnCreate");
  247. CreateFunctions("Refuse", "拒绝包装", "PackInfoMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/PackInfoApply/RefusePackInfoApply", "btn btn-default", "btnRefuse");
  248. CreateFunctions("Close", "关闭申请", "PackInfoMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/PackInfoApply/ClosePackInfoApply", "btn btn-default", "btnClose");
  249. CreateFunctions("PackageInfoMg", "产品包装维护", "PackInfoMg", 4, "", "", "icon-edit", 3, 3, "", "btn btn-default", "NotShow");
  250. CreateFunctions("Query", "查看页面", "PackageInfoMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  251. CreateFunctions("EnterBatch", "一键入库", "PackageInfoMg", 2, "", "", "icon-edit", 1, 3, "/api/services/app/PackInfoApply/CreateProductApplyBatch", "btn btn-default", "_btnEnterBatch");
  252. CreateFunctions("Add", "增加包装规格", "PackageInfoMg", 2, "", "", "icon-add", 2, 3, "/api/services/app/PackInfoApply/AddPackInfo", "btn btn-default", "_btnAdd");
  253. CreateFunctions("Update", "修改包装规格", "PackageInfoMg", 2, "", "", "icon-edit", 3, 3, "/api/services/app/PackInfoApply/UpdatePackInfo", "btn btn-default", "btnUpdate");
  254. CreateFunctions("Delete", "删除包装规格", "PackageInfoMg", 2, "", "", "icon-delete", 4, 3, "/api/services/app/PackInfoApply/DeletePackInfo", "btn btn-default", "btnDelete");
  255. CreateFunctions("Enter", "包装入库申请", "PackageInfoMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/PackInfoApply/CreateProductApply", "btn btn-default", "N_btnEnter");
  256. //CreateFunctions("Delete", "删除入库申请", "PackageInfoMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/PackInfoApply/DeleteProductApply", "btn btn-default", "N_btnDelete");
  257. CreateFunctions("Cancel", "取消入库申请", "PackageInfoMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/PackInfoApply/CancelProductApply", "btn btn-default", "N_btnCancel");
  258. CreateFunctions("Recovery", "恢复申请", "PackageInfoMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/PackInfoApply/RecoveryProductApply", "btn btn-default", "N_btnRecovery");
  259. CreateFunctions("Confirm", "确认入库申请", "PackageInfoMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/PackInfoApply/ConfirmProductApply", "btn btn-default", "N_btnConfirm");
  260. CreateFunctions("Close", "关闭入库申请", "PackageInfoMg", 2, "", "", "icon-delete", 2, 3, "/api/services/app/PackInfoApply/CloseProductApply", "btn btn-default", "N_btnClose");
  261. }
  262. public void Store14()
  263. {
  264. CreateFunctions("FinshedStoreInfo", "成品仓库管理", "HTSystem", 0, "", "", "icon-system", 14, 1, "");
  265. CreateFunctions("FinshedEnterStoreApplyMg", "成品入库申请审核", "FinshedStoreInfo", 1, "FinshedEnterStoreApplyMg", "FinshedStoreInfo", "icon-menu", 1, 2);
  266. CreateFunctions("Query", "查看页面", "FinshedEnterStoreApplyMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  267. CreateFunctions("Update", "审核通过", "FinshedEnterStoreApplyMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/FinshedEnterStore/Audit", "btn btn-default", "btnUpdate");
  268. CreateFunctions("Refuse", "拒绝申请", "FinshedEnterStoreApplyMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/FinshedEnterStore/Refuse", "btn btn-default", "btnDelete");
  269. //CreateFunctions("QueryStore", "实时库存", "FinshedEnterStoreApplyMg", 2, "", "", "icon-task", 4, 3, "", "btn btn-default", "_btnQueryStore");
  270. CreateFunctions("FinshedEnterStoreMg", "成品入库信息", "FinshedStoreInfo", 1, "FinshedEnterStoreMg", "FinshedStoreInfo", "icon-menu", 2, 2);
  271. CreateFunctions("Query", "查看页面", "FinshedEnterStoreMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  272. CreateFunctions("FinshedOutStoreApplyMg", "成品出库申请审核", "FinshedStoreInfo", 1, "FinshedOutStoreApplyMg", "FinshedStoreInfo", "icon-menu", 3, 2);
  273. CreateFunctions("Query", "查看页面", "FinshedOutStoreApplyMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  274. CreateFunctions("Update", "审核通过", "FinshedOutStoreApplyMg", 2, "", "", "icon-edit", 1, 3, "/api/services/app/FinshedOutStore/Audit", "btn btn-default", "btnUpdate");
  275. CreateFunctions("BatchAudit", "批量审核", "FinshedOutStoreApplyMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/FinshedOutStore/AuditBatch", "btn btn-default", "a_btnAuditBatch");
  276. CreateFunctions("Refuse", "拒绝申请", "FinshedOutStoreApplyMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/FinshedOutStore/Refuse", "btn btn-default", "btnRefuse");
  277. CreateFunctions("Recovery", "恢复申请", "FinshedOutStoreApplyMg", 2, "", "", "icon-add", 4, 3, "/api/services/app/FinshedOutStore/Recovery", "btn btn-default", "btnRecovery");
  278. //CreateFunctions("QueryStore", "实时库存", "FinshedOutStoreApplyMg", 2, "", "", "icon-task", 4, 3, "", "btn btn-default", "_btnQueryStore");
  279. CreateFunctions("FinshedOutStoreMg", "成品出库信息", "FinshedStoreInfo", 1, "FinshedOutStoreMg", "FinshedStoreInfo", "icon-menu", 4, 2);
  280. CreateFunctions("Query", "查看页面", "FinshedOutStoreMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  281. CreateFunctions("CurrentFinshedStoreHouseMg", "成品库存信息", "FinshedStoreInfo", 1, "CurrentFinshedStoreHouseMg", "FinshedStoreInfo", "icon-menu", 5, 2);
  282. CreateFunctions("Query", "查看页面", "CurrentFinshedStoreHouseMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  283. CreateFunctions("PackageApply", "申请包装", "CurrentFinshedStoreHouseMg", 2, "", "", "", 1, 3, "/api/services/app/FinshedOutStore/PackageApply", "btn btn-default", "btnPackage");
  284. //CreateFunctions("AddVirtualStore", "添加临时库存", "CurrentFinshedStoreHouseMg", 2, "", "", "icon-add", 2, 3, "/api/services/app/CurrentFinshedStoreHouse/AddVirtualStore", "btn btn-default", "_btnAddVirtualStore");
  285. CreateFunctions("ExportExcel", "导出Excel", "CurrentFinshedStoreHouseMg", 2, "", "", "icon-download", 3, 3, "/api/services/app/CurrentFinshedStoreHouse/ExportExcel", "btn btn-default", "_btnExportExcel");
  286. CreateFunctions("AddEnter", "入库平衡", "CurrentFinshedStoreHouseMg", 2, "", "", "icon-add", 4, 3, "/api/services/app/CurrentFinshedStoreHouse/AddEnter", "btn btn-default", "_btnAddEnter");
  287. CreateFunctions("AddOut", "出库平衡", "CurrentFinshedStoreHouseMg", 2, "", "", "icon-delete", 5, 3, "/api/services/app/CurrentFinshedStoreHouse/AddOut", "btn btn-default", "N_btnAddOut");
  288. CreateFunctions("UpdateStoreLocation", "仓库移库", "CurrentFinshedStoreHouseMg", 2, "", "", "icon-edit", 6, 3, "/api/services/app/CurrentFinshedStoreHouse/UpdateStoreLocation", "btn btn-default", "btnUpdateStoreLocation");
  289. //add
  290. CreateFunctions("RePlating", "改镀", "CurrentFinshedStoreHouseMg", 2, "", "", "icon-add", 7, 3, "/api/services/app/FinshedOutStore/RePlating", "btn btn-default", "btnRePlating");
  291. CreateFunctions("CurrentStoreHouseQueryMg", "库存数量查询", "FinshedStoreInfo", 1, "CurrentStoreHouseQueryMg", "FinshedStoreInfo", "icon-menu", 6, 2);
  292. CreateFunctions("Query", "查看页面", "CurrentStoreHouseQueryMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  293. CreateFunctions("Print", "库存报表打印", "CurrentStoreHouseQueryMg", 2, "", "", "icon-search", 2, 3, "/api/services/app/CurrentStoreHouseQueryMg/Print", "btn btn-default", "_btnPrint");
  294. CreateFunctions("QueryEnterOut", "查看进出货明细信息", "CurrentStoreHouseQueryMg", 2, "", "", "icon-search", 3, 3, "/api/services/app/CurrentStoreHouseQueryMg/Print", "btn btn-default", "N_btnPrint");
  295. CreateFunctions("EnterOutStoreHouseQueryMg", "进出库数量查询", "FinshedStoreInfo", 1, "EnterOutStoreHouseQueryMg", "FinshedStoreInfo", "icon-menu", 7, 2);
  296. CreateFunctions("Query", "查看页面", "EnterOutStoreHouseQueryMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  297. CreateFunctions("ExportExcel", "导出Excel", "EnterOutStoreHouseQueryMg", 2, "", "", "icon-download", 1, 3, "/api/services/app/CurrentFinshedStoreHouse/ExportExcel", "btn btn-default", "_btnExportExcel");
  298. }
  299. public void InventoryCheck15()
  300. {
  301. CreateFunctions("InventoryCheckInfo", "仓库盘点管理", "HTSystem", 0, "", "", "icon-system", 15, 1, "");
  302. CreateFunctions("InventoryCheckCreate", "库存创建盘点", "InventoryCheckInfo", 1, "InventoryCheckCreate", "FinshedStoreInfo", "icon-menu", 8, 2);
  303. CreateFunctions("Query", "查看页面", "InventoryCheckCreate", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  304. CreateFunctions("Create", "盘点任务创建", "InventoryCheckCreate", 2, "", "", "icon-add", 2, 3, "/api/services/app/InventoryCheck/Create", "btn btn-default", "N_btnCreate");
  305. CreateFunctions("Update", "修改盘点任务", "InventoryCheckCreate", 2, "", "", "icon-edit", 3, 3, "/api/services/app/InventoryCheck/Update", "btn btn-default", "btnUpdate");
  306. CreateFunctions("ChangeState", "修改盘点任务状态", "InventoryCheckCreate", 2, "", "", "icon-edit", 3, 3, "/api/services/app/InventoryCheck/ChangeState", "btn btn-default", "N_btnChangeState");
  307. CreateFunctions("CheckData", "盘点库存", "InventoryCheckCreate", 2, "", "", "icon-edit", 3, 3, "/api/services/app/InventoryCheck/CheckData", "btn btn-default", "N_btnCheckData");
  308. CreateFunctions("InventoryCheck", "库存盘点", "InventoryCheckInfo", 1, "InventoryCheck", "FinshedStoreInfo", "icon-menu", 9, 2);
  309. CreateFunctions("Query", "查看页面", "InventoryCheck", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  310. CreateFunctions("ChangeState", "修改盘点任务状态", "InventoryCheck", 2, "", "", "icon-edit", 3, 3, "/api/services/app/InventoryCheck/UpdateState", "btn btn-default", "N_btnChangeState");
  311. CreateFunctions("CheckData", "盘点库存", "InventoryCheck", 2, "", "", "icon-edit", 3, 3, "/api/services/app/InventoryCheck/CheckData", "btn btn-default", "N_btnCheckData");
  312. }
  313. public void RawMaterialStore16()
  314. {
  315. CreateFunctions("RawMaterialStore", "原材料仓库管理", "HTSystem", 0, "", "", "icon-system", 16, 1, "");
  316. CreateFunctions("RmStoreEnterMg", "原材料入库信息维护", "RawMaterialStore", 1, "RmStoreEnterMg", "RmStoreInfo", "icon-menu", 1, 2);
  317. CreateFunctions("Query", "查看页面", "RmStoreEnterMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  318. CreateFunctions("Create", "申请入库", "RmStoreEnterMg", 2, "", "", "icon-add", 1, 3, "/api/services/app/RmEnterStore/Create", "btn btn-default", "_btnCreate");
  319. CreateFunctions("Update", "审核入库", "RmStoreEnterMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/RmEnterStore/UpdateState", "btn btn-default", "btnUpdate");
  320. CreateFunctions("Delete", "取消入库", "RmStoreEnterMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/RmEnterStore/UpdateState", "btn btn-default", "btnDelete");
  321. CreateFunctions("RmStoreOutMg", "原材料出库信息维护", "RawMaterialStore", 1, "RmStoreOutMg", "RmStoreInfo", "icon-menu", 1, 2);
  322. CreateFunctions("Query", "查看页面", "RmStoreOutMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  323. //CreateFunctions("Create", "申请入库", "RmStoreEnterMg", 2, "", "", "icon-add", 1, 3, "/api/services/app/RawMaterialStore/CreateEnter", "btn btn-default", "_btnCreate");
  324. CreateFunctions("Update", "审核出库", "RmStoreOutMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/RmOutStore/UpdateState", "btn btn-default", "btnUpdate");
  325. CreateFunctions("Delete", "取消出库", "RmStoreOutMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/RmOutStore/UpdateState", "btn btn-default", "btnDelete");
  326. CreateFunctions("RmCurrentStoreMg", "原材料库存信息维护", "RawMaterialStore", 1, "RmCurrentStoreMg", "RmStoreInfo", "icon-menu", 1, 2);
  327. CreateFunctions("Query", "查看页面", "RmCurrentStoreMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  328. CreateFunctions("AddEnter", "入库平衡", "RmCurrentStoreMg", 2, "", "", "icon-add", 3, 3, "/api/services/app/CurrentRmStoreHouse/AddEnter", "btn btn-default", "N_btnAddEnter");
  329. CreateFunctions("AddOut", "出库平衡", "RmCurrentStoreMg", 2, "", "", "icon-delete", 4, 3, "/api/services/app/CurrentRmStoreHouse/AddOut", "btn btn-default", "N_btnAddOut");
  330. }
  331. public void ScrapStore17()
  332. {
  333. CreateFunctions("ScrapStore", "废品仓库管理", "HTSystem", 0, "", "", "icon-system", 17, 1, "");
  334. CreateFunctions("ScrapStoreEnterMg", "废品入库信息维护", "ScrapStore", 1, "ScrapStoreEnterMg", "ScrapStoreInfo", "icon-menu", 1, 2);
  335. CreateFunctions("Query", "查看页面", "ScrapStoreEnterMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  336. CreateFunctions("Update", "审核入库", "ScrapStoreEnterMg", 2, "", "", "icon-edit", 2, 3, "/api/services/app/RmEnterStore/UpdateState", "btn btn-default", "N_btnUpdate");
  337. CreateFunctions("Delete", "取消入库", "ScrapStoreEnterMg", 2, "", "", "icon-delete", 3, 3, "/api/services/app/RmEnterStore/UpdateState", "btn btn-default", "N_btnDelete");
  338. }
  339. #endregion
  340. #region 公司基础信息
  341. private void Company30()
  342. {
  343. CreateFunctions("Company", "公司信息管理", "HTSystem", 0, "", "", "icon-system", 30, 1, "");
  344. CreateFunctions("Employee", "人员管理", "Company", 1, "Employee", "Company", "icon-menu", 2, 2);
  345. CreateFunctions("Query", "查看页面", "Employee", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  346. CreateFunctions("Create", "创建人员", "Employee", 2, "", "", "icon-add", 1, 3, "/api/services/app/Employee/Create", "btn btn-default", "_btnCreate");
  347. CreateFunctions("Update", "修改人员", "Employee", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Employee/Update", "btn btn-default", "btnUpdate");
  348. CreateFunctions("Delete", "删除人员", "Employee", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Employee/Delete", "btn btn-default", "btnDelete");
  349. CreateFunctions("Bind", "绑定账号", "Employee", 2, "", "", "icon-add", 4, 3, "/api/services/app/Employee/Bind", "btn btn-default", "btnBind");
  350. CreateFunctions("UnBind", "解绑账号", "Employee", 2, "", "", "icon-delete", 5, 3, "/api/services/app/Employee/UnBind", "btn btn-default", "btnUnBind");
  351. CreateFunctions("EmployeePerformance", "绩效查询", "Company", 1, "Performance", "Company", "icon-menu", 3, 2);
  352. CreateFunctions("Query", "查看页面", "EmployeePerformance", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  353. CreateFunctions("LicenseDocument", "证照信息维护", "Company", 1, "LicenseDocument", "Company", "icon-menu", 4, 2);
  354. CreateFunctions("Query", "查看页面", "LicenseDocument", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  355. CreateFunctions("Create", "创建证照", "LicenseDocument", 2, "", "", "icon-add", 1, 3, "/api/services/app/LicenseDocument/Create", "btn btn-default", "_btnCreate");
  356. CreateFunctions("Update", "修改证照", "LicenseDocument", 2, "", "", "icon-edit", 2, 3, "/api/services/app/LicenseDocument/Update", "btn btn-default", "btnUpdate");
  357. CreateFunctions("Delete", "删除证照", "LicenseDocument", 2, "", "", "icon-delete", 3, 3, "/api/services/app/LicenseDocument/Delete", "btn btn-default", "btnDelete");
  358. CreateFunctions("DownLoad", "下载证照", "LicenseDocument", 2, "", "", "icon-delete", 3, 3, "/api/services/app/LicenseDocument/DownLoad", "btn btn-default", "btnDownLoad");
  359. CreateFunctions("DieMaintenance", "机模设备维护管理", "Company", 0, "", "", "icon-system", 5, 3, "");
  360. CreateFunctions("FixedAsset", "设备固定资产维护", "DieMaintenance", 1, "FixedAsset", "Company", "icon-menu", 1, 4);
  361. CreateFunctions("Query", "查看页面", "FixedAsset", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  362. CreateFunctions("Create", "创建资产", "FixedAsset", 2, "", "", "icon-add", 1, 3, "/api/services/app/FixedAsset/Create", "btn btn-default", "_btnCreate");
  363. CreateFunctions("Update", "修改资产", "FixedAsset", 2, "", "", "icon-edit", 2, 3, "/api/services/app/FixedAsset/Update", "btn btn-default", "btnUpdate");
  364. CreateFunctions("Delete", "删除资产", "FixedAsset", 2, "", "", "icon-delete", 3, 3, "/api/services/app/FixedAsset/Delete", "btn btn-default", "btnDelete");
  365. CreateFunctions("Mold", "模具信息维护", "DieMaintenance", 1, "Mold", "Company", "icon-menu", 2, 4);
  366. CreateFunctions("Query", "查看页面", "Mold", 2, "", "", "", 0, 5, "", "btn btn-default", "None");
  367. CreateFunctions("Create", "创建模具", "Mold", 2, "", "", "icon-add", 1, 5, "/api/services/app/Mold/Create", "btn btn-default", "_btnCreate");
  368. CreateFunctions("Update", "修改模具", "Mold", 2, "", "", "icon-edit", 2, 5, "/api/services/app/Mold/Update", "btn btn-default", "btnUpdate");
  369. CreateFunctions("Delete", "删除模具", "Mold", 2, "", "", "icon-delete", 3, 5, "/api/services/app/Mold/Delete", "btn btn-default", "btnDelete");
  370. //CreateFunctions("MoldMg", "模具维护计划", "DieMaintenance", 1, "MoldMg", "Company", "icon-menu", 1, 4);
  371. //CreateFunctions("Query", "查看页面", "MoldMg", 2, "", "", "", 0, 5, "", "btn btn-default", "None");
  372. //CreateFunctions("Create", "创建模具", "MoldMg", 2, "", "", "icon-add", 1, 5, "/api/services/app/Mold/Create", "btn btn-default", "_btnCreate");
  373. //CreateFunctions("Update", "修改模具", "MoldMg", 2, "", "", "icon-edit", 2, 5, "/api/services/app/Mold/Update", "btn btn-default", "btnUpdate");
  374. //CreateFunctions("Delete", "删除模具", "MoldMg", 2, "", "", "icon-delete", 3, 5, "/api/services/app/Mold/Delete", "btn btn-default", "btnDelete");
  375. //CreateFunctions("Maintain", "添加维护记录", "MoldMg", 2, "", "", "icon-add", 4, 5, "/api/services/app/Mold/Maintain", "btn btn-default", "btnMaintain");
  376. CreateFunctions("DeviceMgPlan", "机模维护计划", "DieMaintenance", 1, "DeviceMgPlan", "Company", "icon-menu", 3, 4);
  377. CreateFunctions("Query", "查看页面", "DeviceMgPlan", 2, "", "", "", 0, 5, "", "btn btn-default", "None");
  378. CreateFunctions("Create", "创建计划", "DeviceMgPlan", 2, "", "", "icon-add", 1, 5, "/api/services/app/DeviceMgPlan/Create", "btn btn-default", "_btnCreate");
  379. CreateFunctions("Update", "修改计划", "DeviceMgPlan", 2, "", "", "icon-edit", 2, 5, "/api/services/app/DeviceMgPlan/Update", "btn btn-default", "btnUpdate");
  380. CreateFunctions("Delete", "删除计划", "DeviceMgPlan", 2, "", "", "icon-delete", 3, 5, "/api/services/app/DeviceMgPlan/Delete", "btn btn-default", "btnDelete");
  381. CreateFunctions("Maintain", "添加维护记录", "DeviceMgPlan", 2, "", "", "icon-add", 5, 5, "/api/services/app/DeviceMgPlan/Maintain", "btn btn-default", "btnMaintain");
  382. CreateFunctions("MaintainRecord", "机模维护记录", "DieMaintenance", 1, "MaintainRecord", "Company", "icon-menu", 4, 4);
  383. CreateFunctions("Query", "查看页面", "MaintainRecord", 2, "", "", "", 0, 5, "", "btn btn-default", "None");
  384. CreateFunctions("Create", "创建维护记录", "MaintainRecord", 2, "", "", "icon-add", 1, 5, "/api/services/app/MaintainRecord/Create", "btn btn-default", "_btnCreate");
  385. CreateFunctions("Update", "修改维护记录", "MaintainRecord", 2, "", "", "icon-edit", 2, 5, "/api/services/app/MaintainRecord/Update", "btn btn-default", "btnUpdate");
  386. CreateFunctions("Delete", "删除维护记录", "MaintainRecord", 2, "", "", "icon-delete", 3, 5, "/api/services/app/MaintainRecord/Delete", "btn btn-default", "btnDelete");
  387. CreateFunctions("AddMember", "添加维护人员", "MaintainRecord", 2, "", "", "icon-delete", 3, 5, "/api/services/app/MaintainRecord/AddMember", "btn btn-default", "btnAddMember");
  388. CreateFunctions("Complete", "完成维护", "MaintainRecord", 2, "", "", "icon-delete", 3, 5, "/api/services/app/MaintainRecord/Complete", "btn btn-default", "btnComplete");
  389. CreateFunctions("MaintainMember", "维护人员", "DieMaintenance", 3, "MaintainRecord", "Company", "icon-menu", 5, 4);
  390. CreateFunctions("Update", "修改信息", "MaintainMember", 2, "", "", "icon-edit", 1, 5, "/api/services/app/MaintainRecord/UpdateMember", "btn btn-default", "btnUpdateMember");
  391. CreateFunctions("Delete", "删除信息", "MaintainMember", 2, "", "", "icon-delete", 1, 5, "/api/services/app/MaintainRecord/DeleteMember", "btn btn-default", "btnDeleteMember");
  392. }
  393. public void CustomerInfoMenu31()
  394. {
  395. CreateFunctions("CustomerInfo", "客户管理", "HTSystem", 0, "", "", "icon-system", 31, 1, "");
  396. CreateFunctions("Customers", "客户基础信息维护", "CustomerInfo", 1, "Customers", "CustomerInfo", "icon-menu", 1, 2);
  397. CreateFunctions("Query", "查看页面", "Customers", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  398. CreateFunctions("Create", "创建客户", "Customers", 2, "", "", "icon-add", 1, 3, "/api/services/app/Customers/Create", "btn btn-default", "_btnCreate");
  399. CreateFunctions("Update", "修改客户", "Customers", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Customers/Update", "btn btn-default", "btnUpdate");
  400. CreateFunctions("Delete", "删除客户", "Customers", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Customers/Delete", "btn btn-default", "btnDelete");
  401. /*CreateFunctions("CustomerSends", "客户送货地址维护", "CustomerInfo", 1, "CustomerSends", "CustomerInfo", "icon-menu", 2, 2);
  402. CreateFunctions("Create", "添加", "CustomerSends", 2, "", "", "icon-add", 4, 3, "/api/services/app/CustomerSends/Create", "btn btn-default", "_btnCreate");
  403. CreateFunctions("Update", "修改", "CustomerSends", 2, "", "", "icon-edit", 5, 3, "/api/services/app/CustomerSends/Update", "btn btn-default", "btnUpdate");
  404. CreateFunctions("Delete", "删除", "CustomerSends", 2, "", "", "icon-delete", 6, 3, "/api/services/app/CustomerSends/Delete", "btn btn-default", "btnDelete");*/
  405. CreateFunctions("CreateSend", "添加客户发货地址", "Customers", 2, "", "", "icon-add", 4, 3, "/api/services/app/CustomerSends/Create", "btn btn-default", "N_btnCreate");
  406. CreateFunctions("UpdateSend", "修改客户发货地址", "Customers", 2, "", "", "icon-edit", 5, 3, "/api/services/app/CustomerSends/Update", "btn btn-default", "N_btnUpdate");
  407. CreateFunctions("DeleteSend", "删除客户发货地址", "Customers", 2, "", "", "icon-delete", 6, 3, "/api/services/app/CustomerSends/Delete", "btn btn-default", "N_btnDelete");
  408. CreateFunctions("CreateDefaultProduct", "添加客户默认产品", "Customers", 2, "", "", "icon-add", 7, 3, "/api/services/app/CustomerDefaultProduct/Create", "btn btn-default", "N_btnCreate");
  409. CreateFunctions("UpdateDefaultProduct", "修改客户默认产品", "Customers", 2, "", "", "icon-edit", 8, 3, "/api/services/app/CustomerDefaultProduct/Update", "btn btn-default", "N_btnUpdate");
  410. CreateFunctions("DeleteDefaultProduct", "删除客户默认产品", "Customers", 2, "", "", "icon-delete", 9, 3, "/api/services/app/CustomerDefaultProduct/Delete", "btn btn-default", "N_btnDelete");
  411. /*CreateFunctions("QueryCustomerDefaultProduct", "查询客户默认产品", "Customers", 2, "", "", "icon-add", 10, 3, "/api/services/app/Products/GetQueryCustomerDefaultProduct", "btn btn-default", "N_btnQuery");*/
  412. CreateFunctions("CustomerInvoices", "客户发票地址维护", "CustomerInfo", 3, "", "", "icon-menu", 2, 2);
  413. CreateFunctions("Create", "添加发票地址", "CustomerInvoices", 2, "", "", "icon-add", 4, 3, "/api/services/app/CustomerInvoiceAddress/Create", "btn btn-default", "_btnCreate");
  414. CreateFunctions("Update", "修改发票地址", "CustomerInvoices", 2, "", "", "icon-edit", 5, 3, "/api/services/app/CustomerInvoiceAddress/Update", "btn btn-default", "btnUpdate");
  415. CreateFunctions("Delete", "删除发票地址", "CustomerInvoices", 2, "", "", "icon-delete", 6, 3, "/api/services/app/CustomerInvoiceAddress/Delete", "btn btn-default", "btnDelete");
  416. }
  417. public void NotificationInfo32()
  418. {
  419. CreateFunctions("NotificationInfo", "消息管理", "HTSystem", 0, "", "", "icon-system", 32, 1, "");
  420. CreateFunctions("BulletinInfos", "通告管理", "NotificationInfo", 1, "BulletinInfos", "NotificationInfo", "icon-menu", 1, 2);
  421. CreateFunctions("Query", "查看页面", "BulletinInfos", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  422. CreateFunctions("Create", "创建通知", "BulletinInfos", 2, "", "", "icon-add", 1, 3, "/api/services/app/BulletinInfos/Create", "btn btn-default", "_btnCreate");
  423. CreateFunctions("Update", "修改通知", "BulletinInfos", 2, "", "", "icon-edit", 2, 3, "/api/services/app/BulletinInfos/Update", "btn btn-default", "btnUpdate");
  424. CreateFunctions("Delete", "删除通知", "BulletinInfos", 2, "", "", "icon-delete", 3, 3, "/api/services/app/BulletinInfos/Delete", "btn btn-default", "btnDelete");
  425. CreateFunctions("ShortMsgMg", "短消息管理", "NotificationInfo", 1, "ShortMsgMg", "NotificationInfo", "icon-menu", 2, 2);
  426. CreateFunctions("Query", "查看页面", "ShortMsgMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  427. /*CreateFunctions("Create", "创建通知", "BulletinInfos", 2, "", "", "icon-add", 1, 3, "/api/services/app/BulletinInfos/Create", "btn btn-default", "_btnCreate");*/
  428. CreateFunctions("SetRead", "已读", "ShortMsgMg", 2, "", "", "icon-edit", 1, 3, "/api/services/app/ShortMsgDetail/SetRead", "btn btn-default", "a_btnSetRead");
  429. CreateFunctions("Delete", "删除消息", "ShortMsgMg", 2, "", "", "icon-delete", 2, 3, "/api/services/app/ShortMsgDetail/BatchDelete", "btn btn-default", "a_btnDelete");
  430. }
  431. public void ProductMenu33()
  432. {
  433. CreateFunctions("ProductInfo", "产品管理", "HTSystem", 0, "", "", "icon-system", 33, 1, "");
  434. CreateFunctions("Products", "成品维护", "ProductInfo", 1, "Products", "ProductInfo", "icon-menu", 1, 2);
  435. CreateFunctions("Query", "查看页面", "Products", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  436. CreateFunctions("Create", "创建成品", "Products", 2, "", "", "icon-add", 1, 3, "/api/services/app/Products/Create", "btn btn-default", "_btnCreate");
  437. CreateFunctions("Update", "修改成品", "Products", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Products/Update", "btn btn-default", "btnUpdate");
  438. CreateFunctions("Delete", "删除成品", "Products", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Products/Delete", "btn btn-default", "btnDelete");
  439. CreateFunctions("ExportExcel", "Excel导出", "Products", 2, "", "", "icon-add", 4, 3, "/api/services/app/Products/ExportExcel", "btn btn-default", "_btnExport");
  440. CreateFunctions("SemiProducts", "半成品维护", "ProductInfo", 1, "SemiProducts", "ProductInfo", "icon-menu", 2, 2);
  441. CreateFunctions("Query", "查看页面", "SemiProducts", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  442. CreateFunctions("Create", "创建半成品", "SemiProducts", 2, "", "", "icon-add", 1, 3, "/api/services/app/SemiProducts/Create", "btn btn-default", "_btnCreate");
  443. CreateFunctions("Update", "修改半成品", "SemiProducts", 2, "", "", "icon-edit", 2, 3, "/api/services/app/SemiProducts/Update", "btn btn-default", "btnUpdate");
  444. CreateFunctions("Delete", "删除半成品", "SemiProducts", 2, "", "", "icon-delete", 3, 3, "/api/services/app/SemiProducts/Delete", "btn btn-default", "btnDelete");
  445. CreateFunctions("ImportExcel", "Excel导入", "SemiProducts", 2, "", "", "icon-add", 4, 3, "/api/services/app/SemiProducts/ImportExcel", "btn btn-default", "_btnImport");
  446. CreateFunctions("Standards", "标准维护", "ProductInfo", 1, "Standards", "ProductInfo", "icon-menu", 3, 2);
  447. CreateFunctions("Query", "查看页面", "Standards", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  448. CreateFunctions("Create", "创建标准", "Standards", 2, "", "", "icon-add", 1, 3, "/api/services/app/Standards/Create", "btn btn-default", "_btnCreate");
  449. CreateFunctions("Update", "修改标准", "Standards", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Standards/Update", "btn btn-default", "btnUpdate");
  450. CreateFunctions("Delete", "删除标准", "Standards", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Standards/Delete", "btn btn-default", "btnDelete");
  451. CreateFunctions("RmProduct", "原材料维护", "ProductInfo", 1, "RmProduct", "ProductInfo", "icon-menu", 4, 2);
  452. CreateFunctions("Query", "查看页面", "RmProduct", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  453. CreateFunctions("Create", "创建原材料", "RmProduct", 2, "", "", "icon-add", 1, 3, "/api/services/app/RmProduct/Create", "btn btn-default", "_btnCreate");
  454. CreateFunctions("Update", "修改原材料", "RmProduct", 2, "", "", "icon-edit", 2, 3, "/api/services/app/RmProduct/Update", "btn btn-default", "btnUpdate");
  455. CreateFunctions("Delete", "删除原材料", "RmProduct", 2, "", "", "icon-delete", 3, 3, "/api/services/app/RmProduct/Delete", "btn btn-default", "btnDelete");
  456. CreateFunctions("ImportExcel", "Excel导入", "RmProduct", 2, "", "", "icon-add", 4, 3, "/api/services/app/RmProduct/ImportExcel", "btn btn-default", "_btnImport");
  457. CreateFunctions("ProductProperty", "产品属性维护", "ProductInfo", 1, "ProductProperty", "ProductInfo", "icon-menu", 4, 2);
  458. CreateFunctions("Query", "查看页面", "ProductProperty", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  459. CreateFunctions("Create", "创建产品属性", "ProductProperty", 2, "", "", "icon-add", 1, 3, "/api/services/app/ProductProperty/Create", "btn btn-default", "_btnCreate");
  460. CreateFunctions("Update", "修改产品属性", "ProductProperty", 2, "", "", "icon-edit", 2, 3, "/api/services/app/ProductProperty/Update", "btn btn-default", "btnUpdate");
  461. CreateFunctions("Delete", "删除产品属性", "ProductProperty", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ProductProperty/Delete", "btn btn-default", "btnDelete");
  462. CreateFunctions("ImportExcel", "Excel导入", "ProductProperty", 2, "", "", "icon-add", 4, 3, "/api/services/app/ProductProperty/ImportExcel", "btn btn-default", "_btnImport");
  463. CreateFunctions("ProductMapper", "新旧产品编码替换", "ProductInfo", 1, "ProductMapper", "ProductInfo", "icon-menu", 4, 2);
  464. CreateFunctions("Query", "查看页面", "ProductMapper", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  465. }
  466. #endregion
  467. #region 数据统计
  468. public void Statistic40()
  469. {
  470. CreateFunctions("StatisticMg", "数据统计报表", "HTSystem", 0, "", "", "icon-system", 40, 1, "");
  471. CreateFunctions("OutsourcingReportMg", "采购数据统计", "StatisticMg", 1, "OutsourcingReport", "Statistic","icon-menu", 1, 2);
  472. CreateFunctions("Query", "查看页面", "OutsourcingReportMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  473. CreateFunctions("Export", "导出Excel", "OutsourcingReportMg", 2, "", "", "", 1, 3, "", "btn btn-default", "None");
  474. CreateFunctions("ProductionReportMg", "车间生产数据统计", "StatisticMg", 1, "ProductionReport", "Statistic","icon-menu", 2, 2);
  475. CreateFunctions("Query", "查看页面", "ProductionReportMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  476. CreateFunctions("PackageDailyMg", "车间包装数据统计", "StatisticMg", 1, "PackageDaily","Statistic", "icon-menu", 3, 2);
  477. CreateFunctions("Query", "查看页面", "PackageDailyMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  478. CreateFunctions("InventoryCheckReportMg", "盘点数据统计", "StatisticMg", 1, "InventoryCheckReport", "Statistic", "icon-menu", 4, 2);
  479. CreateFunctions("Query", "查看页面", "InventoryCheckReportMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  480. CreateFunctions("StatementBillReportMg", "对账单数据统计", "StatisticMg", 1, "StatementBillReport", "Statistic", "icon-menu", 4, 2);
  481. CreateFunctions("Query", "查看页面", "StatementBillReportMg", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  482. }
  483. #endregion
  484. #region 基础信息
  485. private void B100()
  486. {
  487. CreateFunctions("BasicInfo", "基础信息", "HTSystem", 0, "", "", "icon-system", 100, 1, "");
  488. CreateFunctions("Departments", "部门信息管理", "BasicInfo", 1, "Departments", "BasicInfo", "icon-menu", 1, 2);
  489. CreateFunctions("Create", "创建部门", "Departments", 2, "", "", "icon-add", 1, 3, "/api/services/app/Departments/Create", "btn btn-default", "_btnCreate");
  490. CreateFunctions("Update", "修改部门", "Departments", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Departments/Update", "btn btn-default", "btnUpdate");
  491. CreateFunctions("Delete", "删除部门", "Departments", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Departments/Delete", "btn btn-default", "btnDelete");
  492. CreateFunctions("Dutys", "职务信息管理", "BasicInfo", 1, "Dutys", "BasicInfo", "icon-menu", 2, 2);
  493. CreateFunctions("Create", "创建职务", "Dutys", 2, "", "", "icon-add", 1, 3, "/api/services/app/Dutys/Create", "btn btn-default", "_btnCreate");
  494. CreateFunctions("Update", "修改职务", "Dutys", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Dutys/Update", "btn btn-default", "btnUpdate");
  495. CreateFunctions("Delete", "删除职务", "Dutys", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Dutys/Delete", "btn btn-default", "btnDelete");
  496. CreateFunctions("StoreHouses", "仓库信息管理", "BasicInfo", 1, "StoreHouses", "BasicInfo", "icon-menu", 3, 2);
  497. CreateFunctions("Create", "创建仓库", "StoreHouses", 2, "", "", "icon-add", 1, 3, "/api/services/app/StoreHouses/Create", "btn btn-default", "_btnCreate");
  498. CreateFunctions("Update", "修改仓库", "StoreHouses", 2, "", "", "icon-edit", 2, 3, "/api/services/app/StoreHouses/Update", "btn btn-default", "btnUpdate");
  499. CreateFunctions("Delete", "删除仓库", "StoreHouses", 2, "", "", "icon-delete", 3, 3, "/api/services/app/StoreHouses/Delete", "btn btn-default", "btnDelete");
  500. CreateFunctions("StoreHouseLocations", "仓库位置管理", "BasicInfo", 1, "StoreHouseLocations", "BasicInfo", "icon-menu", 4, 2);
  501. CreateFunctions("Create", "创建库位", "StoreHouseLocations", 2, "", "", "icon-add", 1, 3, "/api/services/app/StoreHouseLocations/Create", "btn btn-default", "_btnCreate");
  502. CreateFunctions("Update", "修改库位", "StoreHouseLocations", 2, "", "", "icon-edit", 2, 3, "/api/services/app/StoreHouseLocations/Update", "btn btn-default", "btnUpdate");
  503. CreateFunctions("Delete", "删除库位", "StoreHouseLocations", 2, "", "", "icon-delete", 3, 3, "/api/services/app/StoreHouseLocations/Delete", "btn btn-default", "btnDelete");
  504. CreateFunctions("Regions", "区域管理", "BasicInfo", 1, "Regions", "BasicInfo", "icon-menu", 5, 2);
  505. CreateFunctions("Create", "创建区域", "Regions", 2, "", "", "icon-add", 1, 3, "/api/services/app/Regions/Create", "btn btn-default", "_btnCreate");
  506. CreateFunctions("Update", "修改区域", "Regions", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Regions/Update", "btn btn-default", "btnUpdate");
  507. CreateFunctions("Delete", "删除区域", "Regions", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Regions/Delete", "btn btn-default", "btnDelete");
  508. CreateFunctions("Factories", "办公场所信息管理", "BasicInfo", 1, "Factories", "BasicInfo", "icon-menu", 6, 2);
  509. CreateFunctions("Create", "创建场所", "Factories", 2, "", "", "icon-add", 1, 3, "/api/services/app/Factories/Create", "btn btn-default", "_btnCreate");
  510. CreateFunctions("Update", "修改场所", "Factories", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Factories/Update", "btn btn-default", "btnUpdate");
  511. CreateFunctions("Delete", "删除场所场所", "Factories", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Factories/Delete", "btn btn-default", "btnDelete");
  512. CreateFunctions("OutFactory", "外协加工厂商管理", "BasicInfo", 1, "OutFactory", "BasicInfo", "icon-menu", 7, 2);
  513. CreateFunctions("Create", "创建外协厂商", "OutFactory", 2, "", "", "icon-add", 1, 3, "/api/services/app/OutFactory/Create", "btn btn-default", "_btnCreate");
  514. CreateFunctions("Update", "修改外协厂商", "OutFactory", 2, "", "", "icon-edit", 2, 3, "/api/services/app/OutFactory/Update", "btn btn-default", "btnUpdate");
  515. CreateFunctions("Delete", "删除外协厂商", "OutFactory", 2, "", "", "icon-delete", 3, 3, "/api/services/app/OutFactory/Delete", "btn btn-default", "btnDelete");
  516. CreateFunctions("Currency", "货币汇率管理", "BasicInfo", 1, "Currency", "BasicInfo", "icon-menu", 8, 2);
  517. CreateFunctions("Create", "创建货币", "Currency", 2, "", "", "icon-add", 1, 3, "/api/services/app/Currency/Create", "btn btn-default", "_btnCreate");
  518. CreateFunctions("Update", "修改货币", "Currency", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Currency/Update", "btn btn-default", "btnUpdate");
  519. CreateFunctions("Delete", "删除货币", "Currency", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Currency/Delete", "btn btn-default", "btnDelete");
  520. //CreateFunctions("", "编辑汇率", "Currency", 2, "", "", "icon-delete", 3, 3, "/api/services/app/OutFactory/Delete", "btn btn-default", "btnDelete");
  521. CreateFunctions("Express", "快递公司管理", "BasicInfo", 1, "Express", "BasicInfo", "icon-menu", 8, 2);
  522. CreateFunctions("Create", "创建快递公司", "Express", 2, "", "", "icon-add", 1, 3, "/api/services/app/Express/Create", "btn btn-default", "_btnCreate");
  523. CreateFunctions("Update", "修改快递公司", "Express", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Express/Update", "btn btn-default", "btnUpdate");
  524. CreateFunctions("Delete", "删除快递公司", "Express", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Express/Delete", "btn btn-default", "btnDelete");
  525. CreateFunctions("LicenseType", "证照类型管理", "BasicInfo", 1, "LicenseType", "BasicInfo", "icon-menu", 9, 2);
  526. CreateFunctions("Query", "查看页面", "LicenseType", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  527. CreateFunctions("Create", "创建证照类型", "LicenseType", 2, "", "", "icon-add", 1, 3, "/api/services/app/LicenseType/Create", "btn btn-default", "_btnCreate");
  528. CreateFunctions("Update", "修改证照类型", "LicenseType", 2, "", "", "icon-edit", 2, 3, "/api/services/app/LicenseType/Update", "btn btn-default", "btnUpdate");
  529. CreateFunctions("Delete", "删除证照类型", "LicenseType", 2, "", "", "icon-delete", 3, 3, "/api/services/app/LicenseType/Delete", "btn btn-default", "btnDelete");
  530. CreateFunctions("QualityIssueLabel", "质量问题标签管理", "BasicInfo", 1, "QualityIssueLabel", "BasicInfo", "icon-menu", 10, 2);
  531. CreateFunctions("Query", "查看页面", "QualityIssueLabel", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  532. CreateFunctions("Create", "创建标签", "QualityIssueLabel", 2, "", "", "icon-add", 1, 3, "/api/services/app/QualityIssueLabel/Create", "btn btn-default", "_btnCreate");
  533. CreateFunctions("Update", "修改标签", "QualityIssueLabel", 2, "", "", "icon-edit", 2, 3, "/api/services/app/QualityIssueLabel/Update", "btn btn-default", "btnUpdate");
  534. CreateFunctions("Delete", "删除标签", "QualityIssueLabel", 2, "", "", "icon-delete", 3, 3, "/api/services/app/QualityIssueLabel/Delete", "btn btn-default", "btnDelete");
  535. CreateFunctions("ScrapType", "报废类型管理", "BasicInfo", 1, "ScrapType", "BasicInfo", "icon-menu", 11, 2);
  536. CreateFunctions("Query", "查看页面", "ScrapType", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  537. CreateFunctions("Create", "创建报废类型", "ScrapType", 2, "", "", "icon-add", 1, 3, "/api/services/app/ScrapType/Create", "btn btn-default", "_btnCreate");
  538. CreateFunctions("Update", "修改报废类型", "ScrapType", 2, "", "", "icon-edit", 2, 3, "/api/services/app/ScrapType/Update", "btn btn-default", "btnUpdate");
  539. CreateFunctions("Delete", "删除报废类型", "ScrapType", 2, "", "", "icon-delete", 3, 3, "/api/services/app/ScrapType/Delete", "btn btn-default", "btnDelete");
  540. CreateFunctions("FixedAssetType", "固定资产类型管理", "BasicInfo", 1, "FixedAssetType", "BasicInfo", "icon-menu", 12, 2);
  541. CreateFunctions("Query", "查看页面", "FixedAssetType", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  542. CreateFunctions("Create", "创建资产类型", "FixedAssetType", 2, "", "", "icon-add", 1, 3, "/api/services/app/FixedAssetType/Create", "btn btn-default", "_btnCreate");
  543. CreateFunctions("Update", "修改资产类型", "FixedAssetType", 2, "", "", "icon-edit", 2, 3, "/api/services/app/FixedAssetType/Update", "btn btn-default", "btnUpdate");
  544. CreateFunctions("Delete", "删除资产类型", "FixedAssetType", 2, "", "", "icon-delete", 3, 3, "/api/services/app/FixedAssetType/Delete", "btn btn-default", "btnDelete");
  545. }
  546. private void Sys101()
  547. {
  548. CreateFunctions("System", "系统信息管理", "HTSystem", 0, "", "", "icon-system", 101, 1, "");
  549. CreateFunctions("Roles", "角色管理", "System", 1, "SysRoles", "System", "icon-menu", 1, 2);
  550. CreateFunctions("Query", "查看页面", "Roles", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  551. CreateFunctions("Create", "创建角色", "Roles", 2, "", "", "icon-add", 1, 3, "/api/services/app/Roles/Create", "btn btn-default", "_btnCreate");
  552. CreateFunctions("Update", "修改角色", "Roles", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Roles/Update", "btn btn-default", "btnUpdate");
  553. CreateFunctions("Delete", "删除角色", "Roles", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Roles/Delete", "btn btn-default", "btnDelete");
  554. CreateFunctions("Auth", "角色权限", "Roles", 2, "", "", "icon-perm-list", 4, 3, "/api/services/app/Roles/Auth", "btn btn-default", "btnAuth");
  555. CreateFunctions("Users", "用户管理", "System", 1, "SysUsers", "System", "icon-menu", 2, 2);
  556. CreateFunctions("Query", "查看页面", "Users", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  557. CreateFunctions("Create", "创建用户", "Users", 2, "", "", "icon-add", 1, 3, "/api/services/app/Users/Create", "btn btn-default", "_btnCreate");
  558. CreateFunctions("Update", "修改用户", "Users", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Users/Update", "btn btn-default", "btnUpdate");
  559. CreateFunctions("Delete", "删除用户", "Users", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Users/Delete", "btn btn-default", "btnDelete");
  560. CreateFunctions("ResetPassword", "重置密码", "Users", 2, "", "", "icon-perm-list", 5, 3, "/api/services/app/Users/ResetPassword", "btn btn-default", "btnResetPwd");
  561. CreateFunctions("Auth", "用户权限", "Users", 2, "", "", "icon-perm-list", 6, 3, "/api/services/app/Users/Auth", "btn btn-default", "btnAuth");
  562. CreateFunctions("SysState", "系统字典管理", "System", 1, "SysStates", "System", "icon-menu", 3, 2);
  563. CreateFunctions("Query", "查看页面", "SysState", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  564. CreateFunctions("Create", "创建字典", "SysState", 2, "", "", "icon-add", 1, 3, "/api/services/app/States/Create", "btn btn-default", "_btnCreate");
  565. CreateFunctions("Update", "修改字典", "SysState", 2, "", "", "icon-edit", 2, 3, "/api/services/app/States/Update", "btn btn-default", "btnUpdate");
  566. CreateFunctions("Delete", "删除字典", "SysState", 2, "", "", "icon-delete", 3, 3, "/api/services/app/States/Delete", "btn btn-default", "btnDelete");
  567. CreateFunctions("SysSetting", "系统配置管理", "System", 1, "SysSettings", "System", "icon-menu", 4, 2);
  568. CreateFunctions("Query", "查看页面", "SysSetting", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  569. CreateFunctions("Create", "创建配置", "SysSetting", 2, "", "", "icon-add", 1, 3, "/api/services/app/Settings/Create", "btn btn-default", "_btnCreate");
  570. CreateFunctions("Update", "修改配置", "SysSetting", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Settings/Update", "btn btn-default", "btnUpdate");
  571. CreateFunctions("Delete", "删除配置", "SysSetting", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Settings/Delete", "btn btn-default", "btnDelete");
  572. CreateFunctions("Refresh", "强制刷新", "SysSetting", 2, "", "", "icon-refresh", 4, 3, "/api/services/app/Settings/Refresh", "btn btn-default", "_btnRefresh");
  573. /*CreateFunctions("LoginSetting", "登陆页面图片配置", "SysSetting", 2, "", "", "icon-detail", 5, 3, "/Settings/LoginImage", "btn btn-default", "_btnLoginSetting");*/
  574. CreateFunctions("SysFunction", "功能菜单管理", "System", 1, "SysFunctions", "System", "icon-menu", 5, 2);
  575. CreateFunctions("Query", "查看页面", "SysFunction", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  576. CreateFunctions("Create", "创建菜单", "SysFunction", 2, "", "", "icon-add", 1, 3, "/api/services/app/Functions/Create", "btn btn-default", "_btnCreate");
  577. CreateFunctions("Update", "修改菜单", "SysFunction", 2, "", "", "icon-edit", 2, 3, "/api/services/app/Functions/Update", "btn btn-default", "btnUpdate");
  578. CreateFunctions("Delete", "删除菜单", "SysFunction", 2, "", "", "icon-delete", 3, 3, "/api/services/app/Functions/Delete", "btn btn-default", "btnDelete");
  579. CreateFunctions("MoveUp", "上移菜单", "SysFunction", 2, "", "", "icon-moveup", 4, 3, "/api/services/app/Functions/MoveUp", "btn btn-default", "btnMoveUp");
  580. CreateFunctions("MoveDown", "下移菜单", "SysFunction", 2, "", "", "icon-movedown", 5, 3, "/api/services/app/Functions/MoveDown", "btn btn-default", "btnMoveDown");
  581. CreateFunctions("Refresh", "强制刷新", "SysFunction", 2, "", "", "icon-refresh", 6, 3, "/api/services/app/Functions/Refresh", "btn btn-default", "_btnRefresh");
  582. CreateFunctions("SysLog", "系统日志管理", "System", 1, "SysLogs", "System", "icon-menu", 6, 2);
  583. CreateFunctions("SysHelp", "系统帮助管理", "System", 1, "SysHelps", "System", "icon-menu", 7, 2);
  584. CreateFunctions("Query", "查看页面", "SysHelp", 2, "", "", "", 0, 3, "", "btn btn-default", "None");
  585. CreateFunctions("Create", "创建帮助", "SysHelp", 2, "", "", "icon-add", 1, 3, "/api/services/app/SysHelps/Create", "btn btn-default", "_btnCreate");
  586. CreateFunctions("Update", "修改帮助", "SysHelp", 2, "", "", "icon-edit", 2, 3, "/api/services/app/SysHelps/Update", "btn btn-default", "btnUpdate");
  587. CreateFunctions("Delete", "删除帮助", "SysHelp", 2, "", "", "icon-delete", 3, 3, "/api/services/app/SysHelps/Delete", "btn btn-default", "btnDelete");
  588. }
  589. private void Help102()
  590. {
  591. CreateFunctions("SysHelpPreview", "系统帮助", "HTSystem", 1, "SysHelpPreview", "System", "icon-menu", 102, 2);
  592. }
  593. #endregion
  594. private void CreateFunctions(string funNo, string funName, string parentNo, int funType,
  595. string action, string controller, string icon, int sort, int depth, string url = null, string c = "", string s = "", string path = "")
  596. {
  597. var fun = _context.Functions.FirstOrDefault(e => e.FunctionNo == funNo && e.ParentNo == parentNo);
  598. if (fun == null)
  599. {
  600. string permissionName = path;
  601. if (path.IsNullOrEmpty())
  602. {
  603. var parentFun = _context.Functions.FirstOrDefault(f => f.FunctionNo == parentNo);
  604. if (parentFun != null)
  605. {
  606. path = parentFun.FunctionPath + "," + funNo;
  607. permissionName = parentFun.PermissionName + "." + funNo;
  608. }
  609. }
  610. url = url ?? controller + "/" + action;
  611. fun = new SysFunction
  612. {
  613. FunctionNo = funNo,
  614. ParentNo = parentNo,
  615. FunctionName = funName,
  616. PermissionName = permissionName,
  617. FunctionPath = path,
  618. FunctionType = funType + 1,
  619. Controller = controller,
  620. Action = action,
  621. Icon = icon,
  622. Sort = sort,
  623. Depth = depth,
  624. Class = c,
  625. Script = s,
  626. Url = url
  627. };
  628. _context.Functions.Add(fun);
  629. _context.SaveChanges();
  630. }
  631. PermissionStr += $" public const string {fun.FunctionPath.Replace(",", "")} = \"{fun.PermissionName}\";\r\n";
  632. }
  633. private void WritePermission()
  634. {
  635. if (string.IsNullOrEmpty(PermissionStr))
  636. {
  637. return;
  638. }
  639. try
  640. {
  641. string content = "namespace ShwasherSys.Authorization.Permissions\r\n";
  642. content += "{\r\n";
  643. content += " public static class PermissionNames\r\n";
  644. content += " {\r\n";
  645. content += PermissionStr;
  646. content += " }\r\n";
  647. content += "}\r\n";
  648. var path = AppDomain.CurrentDomain.BaseDirectory;
  649. var basePath = AppDomain.CurrentDomain.BaseDirectory.Substring(0, path.IndexOf("\\ShwasherSys.EntityFramework", StringComparison.Ordinal));
  650. var filePath = Path.Combine(basePath, "ShwasherSys.Core\\Authorization\\Permissions\\PermissionNames.cs");
  651. var fs = new FileStream(filePath, FileMode.Truncate, FileAccess.ReadWrite);//清空文件内容
  652. fs.Close();
  653. using (FileStream fr = new FileStream(filePath, FileMode.Append, FileAccess.Write))
  654. {
  655. fr.Seek(0, SeekOrigin.Begin);
  656. byte[] bytes = Encoding.UTF8.GetBytes(content);
  657. fr.Write(bytes, 0, bytes.Length);
  658. fr.Flush();
  659. }
  660. }
  661. catch (Exception e)
  662. {
  663. throw (new Exception("Permission:" + e.Message));
  664. }
  665. }
  666. }
  667. }