kmkf-work-order-service-component 0.3.6-alpha.6 → 0.3.6-alpha.8

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.
@@ -76,6 +76,7 @@ var SingleShopWorkOrder = function SingleShopWorkOrder() {
76
76
  var submit = search.submit;
77
77
  var dataSource = tableProps.dataSource,
78
78
  pagination = tableProps.pagination;
79
+ console.log('pagination', pagination);
79
80
  useEffect(function () {
80
81
  dispatch(fetchTemplateList);
81
82
  }, []);
@@ -92,6 +93,13 @@ var SingleShopWorkOrder = function SingleShopWorkOrder() {
92
93
  dispatch(setTemplateId(id));
93
94
  };
94
95
 
96
+ var handleChangePagination = function handleChangePagination(page, pageSize) {
97
+ tableProps === null || tableProps === void 0 ? void 0 : tableProps.onChange(_objectSpread(_objectSpread({}, pagination), {}, {
98
+ current: page,
99
+ pageSize: pageSize
100
+ }));
101
+ };
102
+
95
103
  return /*#__PURE__*/_jsxs(Spin, {
96
104
  spinning: loading,
97
105
  children: [(templateList === null || templateList === void 0 ? void 0 : templateList.length) === 0 ? /*#__PURE__*/_jsx(Empty, {}) : /*#__PURE__*/_jsx("div", {
@@ -105,7 +113,7 @@ var SingleShopWorkOrder = function SingleShopWorkOrder() {
105
113
  children: t.label
106
114
  });
107
115
  })
108
- }), /*#__PURE__*/_jsxs("main", {
116
+ }), (templateList === null || templateList === void 0 ? void 0 : templateList.length) > 0 && /*#__PURE__*/_jsxs("main", {
109
117
  className: "list-container",
110
118
  children: [/*#__PURE__*/_jsxs(Form, {
111
119
  form: form,
@@ -140,7 +148,9 @@ var SingleShopWorkOrder = function SingleShopWorkOrder() {
140
148
  })]
141
149
  }), (dataSource === null || dataSource === void 0 ? void 0 : dataSource.length) > 0 ? /*#__PURE__*/_jsx(OrderList, {
142
150
  list: dataSource
143
- }) : /*#__PURE__*/_jsx(Empty, {}), (dataSource === null || dataSource === void 0 ? void 0 : dataSource.length) > 0 && /*#__PURE__*/_jsx(Pagination, _objectSpread({}, pagination)), /*#__PURE__*/_jsx(DeleteCustomizeOrderModal, {
151
+ }) : /*#__PURE__*/_jsx(Empty, {}), (dataSource === null || dataSource === void 0 ? void 0 : dataSource.length) > 0 && /*#__PURE__*/_jsx(Pagination, _objectSpread(_objectSpread({}, pagination), {}, {
152
+ onChange: handleChangePagination
153
+ })), /*#__PURE__*/_jsx(DeleteCustomizeOrderModal, {
144
154
  submit: submit
145
155
  }), /*#__PURE__*/_jsx(CustomizeFormModal, {
146
156
  shopList: [],
@@ -5,6 +5,7 @@
5
5
  overflow-y: auto;
6
6
  background: #fff;
7
7
  .template-button {
8
+ height: 32px;
8
9
  margin: 4px;
9
10
  padding: 4px 8px;
10
11
  border: 1px solid #d9d9d9;
@@ -36,7 +36,7 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
36
36
  import React from 'react';
37
37
  import BasicComponent from "../../BasicComponent";
38
38
  import { getFormItem } from "../../common/formItemWrap";
39
- import { ApaasUploadAsync } from '@raycloud-apaas-fe-setup/apaas-react-basics-widgets';
39
+ import { ApaasUploadAsync, ApaasUpload } from '@raycloud-apaas-fe-setup/apaas-react-basics-widgets';
40
40
  import { Image } from 'antd';
41
41
  import { imgResize } from "../../../../../common/utils/tools";
42
42
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -79,10 +79,9 @@ var BasicPicture = /*#__PURE__*/function (_BasicComponent) {
79
79
  name: _this.id,
80
80
  rules: [],
81
81
  required: (_this$componentConfig = _this.componentConfig) === null || _this$componentConfig === void 0 ? void 0 : _this$componentConfig.required,
82
- component: /*#__PURE__*/_jsx(ApaasUploadAsync, _objectSpread(_objectSpread({}, _this.componentConfig), {}, {
82
+ component: _this.componentConfig.isSingleShop ? /*#__PURE__*/_jsx(ApaasUpload, _objectSpread({}, _this.componentConfig)) : /*#__PURE__*/_jsx(ApaasUploadAsync, _objectSpread(_objectSpread({}, _this.componentConfig), {}, {
83
83
  uniqueKey: _this.id,
84
- hostUrl: "https://kefu.kuaimai.com",
85
- actionUrl: _this.componentConfig.isSingleShop ? '/gdfw/common/uploadWorkOrderImg' : '/qy/common/uploadWorkOrderImg'
84
+ hostUrl: "https://kefu.kuaimai.com"
86
85
  }))
87
86
  }, value));
88
87
  });
@@ -27,7 +27,6 @@ var requestApi = function requestApi(_ref) {
27
27
  params.data = data;
28
28
  }
29
29
 
30
- debugger;
31
30
  request(url, params).then(function (res) {
32
31
  if (res.result === 100 || res.success) {
33
32
  resolve(res);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kmkf-work-order-service-component",
3
- "version": "0.3.6-alpha.6",
3
+ "version": "0.3.6-alpha.8",
4
4
  "scripts": {
5
5
  "start": "dumi dev",
6
6
  "docs:build": "dumi build",