Your Name 2 年之前
父節點
當前提交
eb32a50417
共有 2 個文件被更改,包括 4 次插入4 次删除
  1. 1
    1
      src/pages/dish/list/index.jsx
  2. 3
    3
      src/pages/rotationChart/list/index.jsx

+ 1
- 1
src/pages/dish/list/index.jsx 查看文件

15
 
15
 
16
   const updata = (row) => {
16
   const updata = (row) => {
17
     if (row.id) {
17
     if (row.id) {
18
-      updataDish(row.id, { state: row.state === '1' ? '2' : '1' }).then((res) => {
18
+      updataDish(row.id, { status: row.status === '1' ? '2' : '1' }).then((res) => {
19
         // message.success('修改成功');
19
         // message.success('修改成功');
20
         actionRef.current.reload();
20
         actionRef.current.reload();
21
       });
21
       });

+ 3
- 3
src/pages/rotationChart/list/index.jsx 查看文件

14
 
14
 
15
   const updata = (row) => {
15
   const updata = (row) => {
16
     if (row.id) {
16
     if (row.id) {
17
-      updataBanner(row.id, { state: row.state === '1' ? '2' : '1' }).then((res) => {
17
+      updataBanner(row.id, { status: row.status === '1' ? '2' : '1' }).then((res) => {
18
         // message.success('修改成功');
18
         // message.success('修改成功');
19
         actionRef.current.reload();
19
         actionRef.current.reload();
20
       });
20
       });
57
     },
57
     },
58
     {
58
     {
59
       title: '状态',
59
       title: '状态',
60
-      dataIndex: 'state',
60
+      dataIndex: 'status',
61
       valueEnum: {
61
       valueEnum: {
62
         1: {
62
         1: {
63
           text: '上架',
63
           text: '上架',
90
             updata(record);
90
             updata(record);
91
           }}
91
           }}
92
         >
92
         >
93
-          {record.state === '1' ? '下架' : '上架'}
93
+          {record.status === 1 ? '下架' : '上架'}
94
         </Button>,
94
         </Button>,
95
          <Button
95
          <Button
96
          key={4}
96
          key={4}