gm-printer 10.26.0-beta.1 → 10.26.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/.eslintcache CHANGED
@@ -1 +1 @@
1
- [{"/Users/min/Documents/GMFE/gm-util/gm-printer/src/util.js":"1","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/get_css.js":"2","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/barcode.js":"3","/Users/min/Documents/GMFE/gm-util/gm-printer/src/index.js":"4","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_stockout/context_menu.js":"5","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_stockin/context_menu.js":"6","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_statement/context_menu.js":"7","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_settle/context_menu.js":"8","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_salemenus/context_menu.js":"9","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_purchase/editor_special_table.js":"10","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_purchase/context_menu.js":"11","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_account/context_menu.js":"12","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor/context_menu.js":"13","/Users/min/Documents/GMFE/gm-util/gm-printer/src/config.js":"14","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/hoc_with_store.js":"15","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/hoc_with_shadow_dom.js":"16","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/get_editor_css.js":"17","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_title.js":"18","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_store.js":"19","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_select.js":"20","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_edit_field.js":"21","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/component.js":"22","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_stockout/editor.js":"23","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_stockin/editor.js":"24","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_statement/editor.js":"25","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_settle/editor.js":"26","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_salemenus/editor.js":"27","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_purchase/editor.js":"28","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_account_statement/editor.js":"29","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_account/editor.js":"30","/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor/editor.js":"31","/Users/min/Documents/GMFE/gm-util/gm-printer/src/components/tooltip/index.js":"32","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_special_field.js":"33","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/store.js":"34","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/index.js":"35","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/do_print.js":"36","/Users/min/Documents/GMFE/gm-util/gm-printer/src/finance_voucher/finance_printer.js":"37","/Users/min/Documents/GMFE/gm-util/gm-printer/src/finance_voucher/components/table_subtotal_tr.js":"38","/Users/min/Documents/GMFE/gm-util/gm-printer/src/finance_voucher/components/table.js":"39","/Users/min/Documents/GMFE/gm-util/gm-printer/src/finance_voucher/components/finance_batch_printer.js":"40","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/page.js":"41","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/table_subtotal_tr.js":"42","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/table.js":"43","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/printer.js":"44","/Users/min/Documents/GMFE/gm-util/gm-printer/src/components/flex/index.js":"45","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/table_overallOrder_tr.js":"46","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/util.js":"47","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_add_field.js":"48","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/counter.js":"49","/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/common_context_menu.js":"50","/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/table_diy_overallOrder_tr.js":"51"},{"size":7813,"mtime":1648799098282,"results":"52","hashOfConfig":"53"},{"size":291,"mtime":1638935573926,"results":"54","hashOfConfig":"55"},{"size":523,"mtime":1638935549030,"results":"56","hashOfConfig":"55"},{"size":1139,"mtime":1644572548725,"results":"57","hashOfConfig":"58"},{"size":2293,"mtime":1638948548042,"results":"59","hashOfConfig":"55"},{"size":2292,"mtime":1638948522492,"results":"60","hashOfConfig":"55"},{"size":1078,"mtime":1638948543271,"results":"61","hashOfConfig":"55"},{"size":2067,"mtime":1648466228565,"results":"62","hashOfConfig":"53"},{"size":2991,"mtime":1638948535719,"results":"63","hashOfConfig":"55"},{"size":4379,"mtime":1638935458586,"results":"64","hashOfConfig":"55"},{"size":2428,"mtime":1648466380496,"results":"65","hashOfConfig":"53"},{"size":2955,"mtime":1647850650993,"results":"66","hashOfConfig":"58"},{"size":5660,"mtime":1695026529575,"results":"67","hashOfConfig":"68"},{"size":2833,"mtime":1638861837310,"results":"69","hashOfConfig":"55"},{"size":4212,"mtime":1638935746667,"results":"70","hashOfConfig":"55"},{"size":861,"mtime":1638931446915,"results":"71","hashOfConfig":"55"},{"size":178,"mtime":1638931439249,"results":"72","hashOfConfig":"55"},{"size":3272,"mtime":1648713847909,"results":"73","hashOfConfig":"53"},{"size":46636,"mtime":1695028084459,"results":"74","hashOfConfig":"68"},{"size":4898,"mtime":1639992402586,"results":"75","hashOfConfig":"55"},{"size":21854,"mtime":1695028069713,"results":"76","hashOfConfig":"68"},{"size":15155,"mtime":1657626470824,"results":"77","hashOfConfig":"78"},{"size":2165,"mtime":1638949854481,"results":"79","hashOfConfig":"55"},{"size":2165,"mtime":1638949840121,"results":"80","hashOfConfig":"55"},{"size":2223,"mtime":1638949823846,"results":"81","hashOfConfig":"55"},{"size":2356,"mtime":1650083974574,"results":"82","hashOfConfig":"53"},{"size":3367,"mtime":1638949855771,"results":"83","hashOfConfig":"55"},{"size":2305,"mtime":1638949843817,"results":"84","hashOfConfig":"55"},{"size":3294,"mtime":1638949855131,"results":"85","hashOfConfig":"55"},{"size":2850,"mtime":1638949842017,"results":"86","hashOfConfig":"55"},{"size":4157,"mtime":1638949853726,"results":"87","hashOfConfig":"55"},{"size":605,"mtime":1638949882777,"results":"88","hashOfConfig":"55"},{"size":1175,"mtime":1638949720500,"results":"89","hashOfConfig":"55"},{"size":18215,"mtime":1670988134370,"results":"90","hashOfConfig":"78"},{"size":332,"mtime":1644573509040,"results":"91","hashOfConfig":"58"},{"size":4080,"mtime":1648536160221,"results":"92","hashOfConfig":"53"},{"size":8842,"mtime":1646363892377,"results":"93","hashOfConfig":"58"},{"size":4317,"mtime":1646376602197,"results":"94","hashOfConfig":"58"},{"size":9440,"mtime":1644993553716,"results":"95","hashOfConfig":"58"},{"size":724,"mtime":1644808940649,"results":"96","hashOfConfig":"58"},{"size":1717,"mtime":1648466368772,"results":"97","hashOfConfig":"53"},{"size":5563,"mtime":1658392065200,"results":"98","hashOfConfig":"78"},{"size":10376,"mtime":1695025236432,"results":"99","hashOfConfig":"68"},{"size":9001,"mtime":1648713828033,"results":"100","hashOfConfig":"53"},{"size":3152,"mtime":1648713745966},{"size":1901,"mtime":1650082399244,"results":"101","hashOfConfig":"53"},{"size":600,"mtime":1657507507231,"results":"102","hashOfConfig":"78"},{"size":1945,"mtime":1657624830918,"results":"103","hashOfConfig":"78"},{"size":2009,"mtime":1659343100368,"results":"104","hashOfConfig":"78"},{"size":9861,"mtime":1659343100367,"results":"105","hashOfConfig":"78"},{"size":2513,"mtime":1695028123275,"results":"106","hashOfConfig":"68"},{"filePath":"107","messages":"108","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"1h9xfdh",{"filePath":"109","messages":"110","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"jpc0be",{"filePath":"111","messages":"112","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"113","messages":"114","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"1qaimc",{"filePath":"115","messages":"116","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"117","messages":"118","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"119","messages":"120","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"121","messages":"122","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"123","messages":"124","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"125","messages":"126","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"127","messages":"128","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"129","messages":"130","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"131","messages":"132","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"yfiwrq",{"filePath":"133","messages":"134","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"135","messages":"136","errorCount":2,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"137","messages":"138","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"139","messages":"140","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"141","messages":"142","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"143","messages":"144","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"145","messages":"146","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"147","messages":"148","errorCount":1,"warningCount":4,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"149","messages":"150","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"su5mnm",{"filePath":"151","messages":"152","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"153","messages":"154","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"155","messages":"156","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"157","messages":"158","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"159","messages":"160","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"161","messages":"162","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"163","messages":"164","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"165","messages":"166","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"167","messages":"168","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"169","messages":"170","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"171","messages":"172","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"173","messages":"174","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"175","messages":"176","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"177","messages":"178","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"179","messages":"180","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"181","messages":"182","errorCount":1,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"183","messages":"184","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"185","messages":"186","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"187","messages":"188","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"189","messages":"190","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"191","messages":"192","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"193","messages":"194","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"195","messages":"196","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"197","messages":"198","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"199","messages":"200","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"201","messages":"202","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"203","messages":"204","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"205","messages":"206","errorCount":1,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},"/Users/min/Documents/GMFE/gm-util/gm-printer/src/util.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/get_css.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/barcode.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/index.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_stockout/context_menu.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_stockin/context_menu.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_statement/context_menu.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_settle/context_menu.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_salemenus/context_menu.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_purchase/editor_special_table.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_purchase/context_menu.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_account/context_menu.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor/context_menu.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/config.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/hoc_with_store.js",["207","208"],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/hoc_with_shadow_dom.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/get_editor_css.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_title.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_store.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_select.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_edit_field.js",["209","210","211","212","213"],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/component.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_stockout/editor.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_stockin/editor.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_statement/editor.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_settle/editor.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_salemenus/editor.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_purchase/editor.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_account_statement/editor.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor_account/editor.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/editor/editor.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/components/tooltip/index.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_special_field.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/store.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/index.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/do_print.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/finance_voucher/finance_printer.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/finance_voucher/components/table_subtotal_tr.js",["214"],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/finance_voucher/components/table.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/finance_voucher/components/finance_batch_printer.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/page.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/table_subtotal_tr.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/table.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/printer.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/table_overallOrder_tr.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/util.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/editor_add_field.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/counter.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/common/common_context_menu.js",[],"/Users/min/Documents/GMFE/gm-util/gm-printer/src/printer/table_diy_overallOrder_tr.js",["215"],{"ruleId":"216","severity":2,"message":"217","line":10,"column":29,"nodeType":"218","endLine":10,"endColumn":35},{"ruleId":"216","severity":2,"message":"219","line":145,"column":63,"nodeType":"218","endLine":145,"endColumn":71},{"ruleId":"220","severity":1,"message":"221","line":344,"column":13,"nodeType":"222","endLine":344,"endColumn":49},{"ruleId":"220","severity":1,"message":"221","line":362,"column":13,"nodeType":"222","endLine":362,"endColumn":56},{"ruleId":"220","severity":1,"message":"221","line":519,"column":15,"nodeType":"222","endLine":519,"endColumn":53},{"ruleId":"220","severity":1,"message":"221","line":568,"column":11,"nodeType":"222","endLine":568,"endColumn":53},{"ruleId":"223","severity":2,"message":"224","line":669,"column":22,"nodeType":"225","messageId":"226","endLine":669,"endColumn":31},{"ruleId":"223","severity":2,"message":"224","line":120,"column":14,"nodeType":"225","messageId":"226","endLine":120,"endColumn":23},{"ruleId":"227","severity":2,"message":"228","line":13,"column":5,"nodeType":"218","endLine":13,"endColumn":11},"react/prop-types","'config' is missing in props validation","Identifier","'mockData' is missing in props validation","react/jsx-handler-names","Handler function for onChange prop key must begin with 'handle'","JSXAttribute","gmfe/i18n-check","t函数的key只能为字符串常量(Literal),请使用单引号或双引号包裹","MemberExpression","isVariable","no-unused-vars","'config' is assigned a value but never used."]
1
+ [{"/Users/joke/work_code/gm-printer/src/printer/table.js":"1","/Users/joke/work_code/gm-printer/src/printer/store.js":"2","/Users/joke/work_code/gm-printer/src/printer/table_subtotal_tr.js":"3","/Users/joke/work_code/gm-printer/src/common/util.js":"4","/Users/joke/work_code/gm-printer/src/common/editor_store.js":"5","/Users/joke/work_code/gm-printer/src/common/editor_edit_field.js":"6"},{"size":10861,"mtime":1722841015622},{"size":18403,"mtime":1709723362583,"results":"7","hashOfConfig":"8"},{"size":6329,"mtime":1722840447954,"results":"9","hashOfConfig":"10"},{"size":648,"mtime":1722840447954,"results":"11","hashOfConfig":"10"},{"size":49196,"mtime":1722840447953,"results":"12","hashOfConfig":"10"},{"size":23532,"mtime":1722840447952,"results":"13","hashOfConfig":"10"},{"filePath":"14","messages":"15","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"1akqze6",{"filePath":"16","messages":"17","errorCount":1,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},"12qfxi0",{"filePath":"18","messages":"19","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"20","messages":"21","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"22","messages":"23","errorCount":1,"warningCount":5,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},"/Users/joke/work_code/gm-printer/src/printer/store.js",[],"/Users/joke/work_code/gm-printer/src/printer/table_subtotal_tr.js",["24"],"/Users/joke/work_code/gm-printer/src/common/util.js",[],"/Users/joke/work_code/gm-printer/src/common/editor_store.js",[],"/Users/joke/work_code/gm-printer/src/common/editor_edit_field.js",["25","26","27","28","29","30"],{"ruleId":"31","severity":2,"message":"32","line":49,"column":9,"nodeType":"33","endLine":49,"endColumn":16},{"ruleId":"34","severity":1,"message":"35","line":344,"column":13,"nodeType":"36","endLine":344,"endColumn":49},{"ruleId":"34","severity":1,"message":"35","line":362,"column":13,"nodeType":"36","endLine":362,"endColumn":56},{"ruleId":"34","severity":1,"message":"35","line":528,"column":15,"nodeType":"36","endLine":528,"endColumn":53},{"ruleId":"34","severity":1,"message":"35","line":595,"column":11,"nodeType":"36","endLine":595,"endColumn":53},{"ruleId":"34","severity":1,"message":"35","line":645,"column":19,"nodeType":"36","endLine":645,"endColumn":64},{"ruleId":"37","severity":2,"message":"38","line":712,"column":22,"nodeType":"39","messageId":"40","endLine":712,"endColumn":31},"no-unused-vars","'sumData' is assigned a value but never used.","Identifier","react/jsx-handler-names","Handler function for onChange prop key must begin with 'handle'","JSXAttribute","gmfe/i18n-check","t函数的key只能为字符串常量(Literal),请使用单引号或双引号包裹","MemberExpression","isVariable"]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gm-printer",
3
- "version": "10.26.0-beta.1",
3
+ "version": "10.26.1",
4
4
  "description": "diy printer",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -112,4 +112,4 @@
112
112
  "dependencies": {
113
113
  "qrcode.react": "^0.9.2"
114
114
  }
115
- }
115
+ }
@@ -455,6 +455,15 @@ class EditorField extends React.Component {
455
455
  <Flex>{i18next.t('合计栏打印金额')}:</Flex>
456
456
  <Flex style={{ marginLeft: 57 }}>
457
457
  {subtotalRadioList.map(fields => {
458
+ // 兼容
459
+ let subtotalFields = subtotal?.fields?.[0].valueField
460
+ if (subtotalFields === 'total_item_price')
461
+ subtotalFields = '下单金额'
462
+ if (
463
+ subtotalFields === 'real_item_price' ||
464
+ !subtotal?.fields?.[0].valueField
465
+ )
466
+ subtotalFields = '出库金额'
458
467
  return (
459
468
  <Radio
460
469
  style={{ marginLeft: 5 }}
@@ -462,7 +471,7 @@ class EditorField extends React.Component {
462
471
  value={fields.value}
463
472
  key={fields.id}
464
473
  inputName='subtotalRadio'
465
- checked={subtotal?.fields?.[0].valueField === fields.id}
474
+ checked={subtotalFields === fields.id}
466
475
  radioChecked={() => editStore.subtotalRadioCheck(fields)}
467
476
  />
468
477
  )
@@ -533,6 +542,24 @@ class EditorField extends React.Component {
533
542
  onChange={this.handleOverallOrderStyleChange}
534
543
  />
535
544
  </Flex>
545
+ <Flex style={{ marginLeft: 57 }}>
546
+ {subtotalRadioList.map((fields, i) => {
547
+ return (
548
+ <Radio
549
+ style={{ marginLeft: 5 }}
550
+ id={`${fields.id}${i}`}
551
+ value={fields.value}
552
+ key={fields.id}
553
+ inputName='overallOrderRadio'
554
+ checked={
555
+ (overallOrder?.fields?.[0]?.valueField ?? '出库金额') ===
556
+ fields.id
557
+ }
558
+ radioChecked={() => editStore.setOverallOrderValueField(fields)}
559
+ />
560
+ )
561
+ })}
562
+ </Flex>
536
563
  <EditorSubtotalCheck
537
564
  subtotalCheckDisabled
538
565
  subtotalChecked={overallOrderNeedUpperCase}
@@ -607,6 +607,26 @@ class EditorStore {
607
607
  if (this.selectedRegion) {
608
608
  this.overallOrderShow = !this.overallOrderShow
609
609
  const arr = this.selectedRegion.split('.')
610
+ const table = this.config.contents[arr[2]]
611
+ const colSpanLength = getColSpanLength(table)
612
+ if (!this.config.contents[arr[2]].subtotal.fields?.[0]) {
613
+ // 兼容已经存在的配送单据,他们的配置存在后端的,没有subtotal这个配置,给加上
614
+ set(table, {
615
+ subtotal: {
616
+ show: true,
617
+ fields: [
618
+ {
619
+ name: '每页合计:',
620
+ valueField: '下单金额',
621
+ style: {
622
+ fontWeight: 'bold'
623
+ },
624
+ colSpan: colSpanLength
625
+ }
626
+ ]
627
+ }
628
+ })
629
+ }
610
630
  this.config.contents[arr[2]].subtotal.fields[0].valueField = fields.id
611
631
 
612
632
  const fieldList = this.config.contents[arr[2]].subtotal.fields
@@ -672,7 +692,7 @@ class EditorStore {
672
692
  fields: [
673
693
  {
674
694
  name: '自定义整单合计:',
675
- valueField: '{{出库金额}}',
695
+ valueField: '{{列.出库金额}}',
676
696
  style: {
677
697
  fontWeight: 'bold'
678
698
  }
@@ -1208,7 +1228,7 @@ class EditorStore {
1208
1228
  fields: [
1209
1229
  {
1210
1230
  name: '每页合计:',
1211
- valueField: 'real_item_price',
1231
+ valueField: '出库金额',
1212
1232
  colSpan: colSpanLength
1213
1233
  }
1214
1234
  ]
@@ -1357,6 +1377,39 @@ class EditorStore {
1357
1377
  }
1358
1378
  }
1359
1379
 
1380
+ // 整单合计金额单选设置
1381
+ @action.bound
1382
+ setOverallOrderValueField({ id }) {
1383
+ if (this.selectedRegion) {
1384
+ this.overallOrderShow = !this.overallOrderShow
1385
+ const arr = this.selectedRegion.split('.')
1386
+ const table = this.config.contents[arr[2]]
1387
+ const colSpanLength = getColSpanLength(table)
1388
+ if (!this.config.contents[arr[2]].overallOrder.fields?.[0]) {
1389
+ // 兼容已经存在的配送单据,他们的配置存在后端的,没有overallOrder这个配置,给加上
1390
+ set(table, {
1391
+ overallOrder: {
1392
+ show: true,
1393
+ fields: [
1394
+ {
1395
+ name: '整单合计:',
1396
+ valueField: '下单金额',
1397
+ style: {
1398
+ fontWeight: 'bold'
1399
+ },
1400
+ colSpan: colSpanLength
1401
+ }
1402
+ ]
1403
+ }
1404
+ })
1405
+ }
1406
+ const overallOrderConfig = this.config.contents[arr[2]]?.overallOrder
1407
+ const oldValueField = overallOrderConfig.fields?.[0]
1408
+ this.config.contents[arr[2]]?.overallOrder &&
1409
+ set(oldValueField, { valueField: id })
1410
+ }
1411
+ }
1412
+
1360
1413
  // 整单合计设置大写金额
1361
1414
  @action.bound
1362
1415
  setOverallOrderUpperCase() {
@@ -3,22 +3,27 @@ import i18next from '../../locales'
3
3
  /**
4
4
  * 每页合计设置单选按钮
5
5
  * id的值是用来计算每页的金额总数,不要轻易随便改
6
- * id值暂时使用_origin的值,可优化改为{{列.xxxx}}的值,改起来有代价,先不改
7
6
  */
7
+ // 整单合计和每页合计栏都使用的这个
8
8
  const subtotalRadioList = [
9
9
  {
10
10
  value: i18next.t('下单金额'),
11
- id: 'total_item_price'
11
+ id: '下单金额'
12
12
  },
13
13
  {
14
14
  value: i18next.t('出库金额'),
15
- id: 'real_item_price'
15
+ id: '出库金额'
16
+ },
17
+ {
18
+ value: i18next.t('实际金额'),
19
+ id: '实际金额'
16
20
  }
17
21
  ]
18
22
 
19
23
  const accountRadioList = {
20
- total_item_price: i18next.t('下单金额'),
21
- real_item_price: i18next.t('出库金额')
24
+ 下单金额: i18next.t('下单金额'),
25
+ 出库金额: i18next.t('出库金额'),
26
+ 实际金额: i18next.t('实际金额')
22
27
  }
23
28
 
24
29
  export { subtotalRadioList, accountRadioList }
@@ -114,11 +114,10 @@ class Table extends React.Component {
114
114
  const data = {
115
115
  ...val,
116
116
  index,
117
- // 先匹配 {{ }}模版中的
118
117
  text: val.text.replace(/{{(.*?)}}/g, s => {
119
118
  // 再匹配 列.xxx 相关的
120
119
  s = s.replace(
121
- /(列.[\u4e00-\u9fa5]*[0-9A-Za-z_]?[\u4e00-\u9fa5]*[A-Za-z_]*[\u4e00-\u9fa5]*)/g,
120
+ /(列.[\u4e00-\u9fa5]*[0-9A-Za-z_]*[\u4e00-\u9fa5]*[A-Za-z_]*[\u4e00-\u9fa5]*)/g,
122
121
  m => m + `${MULTI_SUFFIX}${colNum}`
123
122
  )
124
123
  return s
@@ -291,13 +290,13 @@ class Table extends React.Component {
291
290
  dangerouslySetInnerHTML={{
292
291
  __html: col.isSpecialColumn
293
292
  ? printerStore.templateSpecialDetails(
294
- col,
295
- dataKey,
296
- i
297
- )
293
+ col,
294
+ dataKey,
295
+ i
296
+ )
298
297
  : printerStore
299
- .templateTable(col.text, dataKey, i, pageIndex)
300
- .replace(/\(\)/g, '')
298
+ .templateTable(col.text, dataKey, i, pageIndex)
299
+ .replace(/\(\)/g, '')
301
300
  }}
302
301
  />
303
302
  )
@@ -30,10 +30,11 @@ const SubtotalTr = props => {
30
30
  isUpperCaseBefore, // 决定小写金额是否在前
31
31
  isUpperLowerCaseSeparate, // 决定大小写金额是否分开在两端
32
32
  style,
33
+
33
34
  fields = [
34
35
  {
35
36
  name: i18next.t('每页合计:'),
36
- valueField: 'real_item_price'
37
+ valueField: '出库金额'
37
38
  }
38
39
  ],
39
40
  displayName = false // 是否展示字段名
@@ -68,6 +69,30 @@ const SubtotalTr = props => {
68
69
  ).toFixed(2)
69
70
  }
70
71
 
72
+ // 计算合计
73
+ const sumData2 = (list, field) => {
74
+ // 兼容之前
75
+ if (field === 'total_item_price') field = '下单金额'
76
+ if (field === 'real_item_price') field = '出库金额'
77
+ if (field === 'settle_money2') field = '结算金额'
78
+ if (field === 'total_money2') field = '金额'
79
+ return _.reduce(
80
+ list,
81
+ (a, b) => {
82
+ let result = a
83
+ result = a.plus(b[field] || 0)
84
+ if (b?.[field + MULTI_SUFFIX]) {
85
+ result = result.plus(b?.[field + MULTI_SUFFIX])
86
+ }
87
+ if (b?.[field + MULTI_SUFFIX3]) {
88
+ result = result.plus(b?.[field + MULTI_SUFFIX3])
89
+ }
90
+ return result
91
+ },
92
+ Big(0)
93
+ ).toFixed(2)
94
+ }
95
+
71
96
  const getData = field => {
72
97
  const data = printerStore.data.common
73
98
  return data?.[field] ?? ''
@@ -82,7 +107,7 @@ const SubtotalTr = props => {
82
107
  const sum = {}
83
108
 
84
109
  _.each(fields, v => {
85
- sum[v.name] = sumData(list, v.valueField)
110
+ sum[v.name] = sumData2(list, v.valueField)
86
111
  })
87
112
  let subtotalStr = ''
88
113
  for (const name in sum) {
@@ -140,7 +165,7 @@ const SubtotalTr = props => {
140
165
  {item.type === 'useSummarize'
141
166
  ? getData(item.valueField)
142
167
  : index === 0
143
- ? sumData(list, item.valueField)
168
+ ? sumData2(list, item.valueField)
144
169
  : ''}
145
170
  {/* {index === 0 ? sumData(list, item.valueField) : ''} */}
146
171
  </span>
@@ -151,7 +176,9 @@ const SubtotalTr = props => {
151
176
  coverDigit2Uppercase(getData(item.valueField))
152
177
  : index === 0
153
178
  ? '大写:' +
154
- coverDigit2Uppercase(sumData(list, item.valueField))
179
+ coverDigit2Uppercase(
180
+ sumData2(list, item.valueField)
181
+ )
155
182
  : ''}
156
183
  </span>
157
184
  )}