@nocobase/plugin-action-duplicate 1.2.13-alpha → 1.3.0-alpha.20240710084543
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/package.json +2 -2
- package/dist/client/DuplicateAction.Settings.d.ts +0 -16
- package/dist/client/DuplicateAction.d.ts +0 -11
- package/dist/client/DuplicateActionInitializer.d.ts +0 -10
- package/dist/client/DuplicatePluginProvider.d.ts +0 -10
- package/dist/client/index.d.ts +0 -14
- package/dist/client/index.js +0 -55
- package/dist/externalVersion.js +0 -21
- package/dist/index.d.ts +0 -10
- package/dist/index.js +0 -48
- package/dist/server/index.d.ts +0 -9
- package/dist/server/index.js +0 -42
- package/dist/server/plugin.d.ts +0 -19
- package/dist/server/plugin.js +0 -54
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nocobase/plugin-action-duplicate",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.0-alpha.20240710084543",
|
|
4
4
|
"main": "dist/server/index.js",
|
|
5
5
|
"homepage": "https://docs.nocobase.com/handbook/action-duplicate",
|
|
6
6
|
"homepage.zh-CN": "https://docs-cn.nocobase.com/handbook/action-duplicate",
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"@nocobase/server": "1.x",
|
|
15
15
|
"@nocobase/test": "1.x"
|
|
16
16
|
},
|
|
17
|
-
"gitHead": "
|
|
17
|
+
"gitHead": "07a8b596fc64a9779a194cb9b0dc2ca7570ed9d4",
|
|
18
18
|
"keywords": [
|
|
19
19
|
"Actions"
|
|
20
20
|
]
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
import { SchemaSettings } from '@nocobase/client';
|
|
10
|
-
/**
|
|
11
|
-
* @deprecated
|
|
12
|
-
* 用于兼容之前的 name
|
|
13
|
-
*/
|
|
14
|
-
declare const deprecatedDuplicateActionSettings: SchemaSettings<{}>;
|
|
15
|
-
declare const duplicateActionSettings: SchemaSettings<{}>;
|
|
16
|
-
export { deprecatedDuplicateActionSettings, duplicateActionSettings };
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
import React from 'react';
|
|
10
|
-
export declare const actionDesignerCss: string;
|
|
11
|
-
export declare const DuplicateAction: React.MemoExoticComponent<import("@formily/react").ReactFC<Omit<any, "ref">>>;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
import React from 'react';
|
|
10
|
-
export declare const DuplicateActionInitializer: (props: any) => React.JSX.Element;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
import React from 'react';
|
|
10
|
-
export declare const DuplicatePluginProvider: (props: any) => React.JSX.Element;
|
package/dist/client/index.d.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
import { Plugin } from '@nocobase/client';
|
|
10
|
-
export declare class PluginActionDuplicateClient extends Plugin {
|
|
11
|
-
load(): Promise<void>;
|
|
12
|
-
}
|
|
13
|
-
export default PluginActionDuplicateClient;
|
|
14
|
-
export * from './DuplicateAction';
|
package/dist/client/index.js
DELETED
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
(function(n,e){typeof exports=="object"&&typeof module!="undefined"?e(exports,require("@nocobase/client"),require("react/jsx-runtime"),require("@emotion/css"),require("@formily/react"),require("antd"),require("react"),require("react-i18next"),require("@formily/core"),require("lodash")):typeof define=="function"&&define.amd?define(["exports","@nocobase/client","react/jsx-runtime","@emotion/css","@formily/react","antd","react","react-i18next","@formily/core","lodash"],e):(n=typeof globalThis!="undefined"?globalThis:n||self,e(n["@nocobase/plugin-action-duplicate"]={},n["@nocobase/client"],n.jsxRuntime,n["@emotion/css"],n["@formily/react"],n.antd,n.react,n["react-i18next"],n["@formily/core"],n.lodash))})(this,function(n,e,i,p,r,M,y,q,C,I){"use strict";var ye=Object.defineProperty,Ce=Object.defineProperties;var be=Object.getOwnPropertyDescriptors;var j=Object.getOwnPropertySymbols;var ae=Object.prototype.hasOwnProperty,se=Object.prototype.propertyIsEnumerable;var ce=(n,e,i)=>e in n?ye(n,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):n[e]=i,x=(n,e)=>{for(var i in e||(e={}))ae.call(e,i)&&ce(n,i,e[i]);if(j)for(var i of j(e))se.call(e,i)&&ce(n,i,e[i]);return n},g=(n,e)=>Ce(n,be(e));var le=(n,e)=>{var i={};for(var p in n)ae.call(n,p)&&e.indexOf(p)<0&&(i[p]=n[p]);if(n!=null&&j)for(var p of j(n))e.indexOf(p)<0&&se.call(n,p)&&(i[p]=n[p]);return i};var z=(n,e,i)=>new Promise((p,r)=>{var M=C=>{try{q(i.next(C))}catch(I){r(I)}},y=C=>{try{q(i.throw(C))}catch(I){r(I)}},q=C=>C.done?p(C.value):Promise.resolve(C.value).then(M,y);q((i=i.apply(n,e)).next())});const $=p.css`
|
|
11
|
-
position: relative;
|
|
12
|
-
&:hover {
|
|
13
|
-
.general-schema-designer {
|
|
14
|
-
display: block;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
.general-schema-designer {
|
|
18
|
-
position: absolute;
|
|
19
|
-
z-index: 999;
|
|
20
|
-
top: 0;
|
|
21
|
-
bottom: 0;
|
|
22
|
-
left: 0;
|
|
23
|
-
right: 0;
|
|
24
|
-
display: none;
|
|
25
|
-
background: var(--colorBgSettingsHover);
|
|
26
|
-
border: 0;
|
|
27
|
-
top: 0;
|
|
28
|
-
bottom: 0;
|
|
29
|
-
left: 0;
|
|
30
|
-
right: 0;
|
|
31
|
-
pointer-events: none;
|
|
32
|
-
> .general-schema-designer-icons {
|
|
33
|
-
position: absolute;
|
|
34
|
-
right: 2px;
|
|
35
|
-
top: 2px;
|
|
36
|
-
line-height: 16px;
|
|
37
|
-
pointer-events: all;
|
|
38
|
-
.ant-space-item {
|
|
39
|
-
background-color: var(--colorSettings);
|
|
40
|
-
color: #fff;
|
|
41
|
-
line-height: 16px;
|
|
42
|
-
width: 16px;
|
|
43
|
-
padding-left: 1px;
|
|
44
|
-
align-self: stretch;
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
`,K=r.observer(t=>{var te,oe,ne;const{children:c}=t,{message:s}=M.App.useApp(),o=r.useField(),d=r.useFieldSchema(),v=e.useAPIClient(),u=o.disabled||t.disabled,{designable:b}=e.useDesignable(),[T,A]=y.useState(!1),[m,_]=y.useState(!1),{service:P,__parent:w,block:L,resource:B}=e.useBlockRequestContext(),{duplicateFields:D,duplicateMode:V="quickDulicate",duplicateCollection:l}=d["x-component-props"],f=e.useRecord(),a=e.useCollectionParentRecordData(),{id:h,__collection:k}=f,N=e.useActionContext(),{name:E}=e.useCollection_deprecated(),{getCollectionFields:me}=e.useCollectionManager_deprecated(),{t:F}=q.useTranslation(),he=me(k||E),xe=e.useFormBlockContext(),X=e.useACLActionParamsContext(),ge=y.useMemo(()=>{var S;return{opacity:b&&(((S=o==null?void 0:o.data)==null?void 0:S.hidden)||!X)&&.1}},[b,(te=o==null?void 0:o.data)==null?void 0:te.hidden]),Y={key:"duplicate",dataId:h,default:!0,fields:(D==null?void 0:D.filter(S=>he.find(O=>S.includes(O.name))))||[],collection:k||E},Z=d["x-component"]==="Action.Link",fe=()=>z(this,null,function*(){var S,O,ie;_(!0);try{const R=yield e.fetchTemplateData(v,Y,F);yield B.create({values:x({},R)}),s.success(F("Saved successfully")),L==="form"?(O=(S=w==null?void 0:w.service)==null?void 0:S.refresh)==null||O.call(S):yield(ie=P==null?void 0:P.refresh)==null?void 0:ie.call(P),_(!1)}catch(R){_(!1),console.error(R)}}),ee=()=>{!u&&!m&&X&&((D==null?void 0:D.length)>0?V==="quickDulicate"?fe():A(!0):s.error(F("Please configure the duplicate fields")))};return i.jsx("div",{className:p.cx($,{[p.css`
|
|
49
|
-
.general-schema-designer {
|
|
50
|
-
top: -10px;
|
|
51
|
-
bottom: -10px;
|
|
52
|
-
left: -10px;
|
|
53
|
-
right: -10px;
|
|
54
|
-
}
|
|
55
|
-
`]:Z}),children:i.jsx(e.FormBlockContext.Provider,{value:g(x({},xe),{duplicateData:{display:!1,enabled:!0,defaultTemplate:Y}}),children:i.jsxs("div",{children:[Z?i.jsx("a",{className:"nb-action-link",role:t.role,"aria-label":t["aria-label"],disabled:u,style:x({opacity:b&&((oe=o==null?void 0:o.data)==null?void 0:oe.hidden)&&.1,cursor:m?"not-allowed":"pointer",position:"relative"},ge),onClick:ee,children:m?F("Duplicating"):c||F("Duplicate")}):i.jsx(M.Button,g(x({role:t.role,"aria-label":t["aria-label"],disabled:u,style:{opacity:b&&((ne=o==null?void 0:o.data)==null?void 0:ne.hidden)&&.1}},t),{onClick:ee,children:m?F("Duplicating"):c||F("Duplicate")})),i.jsx(e.CollectionProvider_deprecated,{name:l||E,children:i.jsx(e.RecordProvider,{record:g(x({},a),{__collection:l||k}),children:i.jsx(e.ActionContextProvider,{value:g(x({},N),{visible:T,setVisible:A}),children:i.jsx(r.RecursionField,{schema:d,basePath:o.address,onlyRenderProperties:!0})})})})]})})})},{displayName:"DuplicateAction"}),G=r.connect(M.Tree,r.mapProps((t,c)=>{y.useEffect(()=>{c.value=t.defaultCheckedKeys||[]},[]);const[s,o]=y.useState(t.defaultCheckedKeys||[]),d=u=>{o(u),c.value=u};c.onCheck=d;const v=r.useForm();return g(x({},t),{checkedKeys:s,onCheck:d,treeData:t==null?void 0:t.treeData.map(u=>{var b;if(v.values.duplicateMode==="quickDulicate"){const T=(b=u==null?void 0:u.children)==null?void 0:b.map(A=>g(x({},A),{disabled:!1}));return g(x({},u),{disabled:!1,children:T})}return u})})})),H=(t,c)=>{for(let o=0;o<(t==null?void 0:t.length);o++){const s=t[o],{children:d}=s,v=le(s,["children"]);c.push(v.key),d&&H(d,c)}return c},U=t=>t.reduceProperties((s,o)=>o["x-decorator"]==="FormBlockProvider"?o:U(o),null);function re(){var L,B,D,V;const{dn:t}=e.useDesignable(),{t:c}=q.useTranslation(),s=r.useField(),o=r.useFieldSchema(),{name:d}=e.useCollection_deprecated(),{collectionList:v,getEnableFieldTree:u,getOnLoadData:b,getOnCheck:T}=e.useCollectionState(d),A=I.cloneDeep(((L=o["x-component-props"])==null?void 0:L.duplicateFields)||[]),m=e.useRecord(),_=y.useCallback((l,f,a)=>{a.query("duplicateFields").take(h=>{h.componentProps.treeData=l,h.componentProps.defaultCheckedKeys=f,h.setInitialValue(f),h==null||h.onCheck(f),a.setValues(g(x({},a.values),{treeData:l}))})},[]),P=l=>({run(){return z(this,null,function*(){l.query("duplicateFields").take(a=>{var k;const h=H(a.componentProps.treeData,[]);a.componentProps.defaultCheckedKeys=h,a.setInitialValue(h),(k=a==null?void 0:a.onCheck)==null||k.call(a,h)})})}}),w=l=>({run(){return z(this,null,function*(){l.query("duplicateFields").take(a=>{a.componentProps.defaultCheckedKeys=[],a.setInitialValue([]),a==null||a.onCheck([])})})}});return i.jsx(e.SchemaSettingsModalItem,{title:c("Duplicate mode"),components:{Tree:G},scope:{getEnableFieldTree:u,collectionName:((B=o["x-component-props"])==null?void 0:B.duplicateCollection)||(m==null?void 0:m.__collection)||d,currentCollection:(m==null?void 0:m.__collection)||d,getOnLoadData:b,getOnCheck:T,treeData:(D=o["x-component-props"])==null?void 0:D.treeData,duplicateValues:A,onFieldInputValueChange:C.onFieldInputValueChange},schema:{type:"object",title:c("Duplicate mode"),properties:{duplicateMode:{"x-decorator":"FormItem","x-component":"Radio.Group",title:c("Duplicate mode"),default:((V=o["x-component-props"])==null?void 0:V.duplicateMode)||"quickDulicate",enum:[{value:"quickDulicate",label:'{{t("Direct duplicate")}}'},{value:"continueduplicate",label:'{{t("Copy into the form and continue to fill in")}}'}]},collection:{type:"string",title:'{{ t("Target collection") }}',required:!0,description:c("If collection inherits, choose inherited collections as templates"),default:"{{ collectionName }}","x-display":v.length>1?"visible":"hidden","x-decorator":"FormItem","x-component":"Select","x-component-props":{options:v},"x-reactions":[{dependencies:[".duplicateMode"],fulfill:{state:{disabled:'{{ $deps[0]==="quickDulicate" }}',value:'{{ $deps[0]==="quickDulicate"? currentCollection:collectionName }}'}}}]},syncFromForm:{type:"void",title:'{{ t("Sync from form fields") }}',"x-component":"Action.Link","x-component-props":{type:"primary",style:{float:"right",position:"relative",zIndex:1200},useAction:()=>{var f;const l=y.useMemo(()=>U(o),[o]);return e.useSyncFromForm(l,((f=o["x-component-props"])==null?void 0:f.duplicateCollection)||(m==null?void 0:m.__collection)||d,_)}},"x-reactions":[{dependencies:[".duplicateMode"],fulfill:{state:{visible:'{{ $deps[0]!=="quickDulicate" }}'}}}]},selectAll:{type:"void",title:'{{ t("Select all") }}',"x-component":"Action.Link","x-reactions":[{dependencies:[".duplicateMode"],fulfill:{state:{visible:'{{ $deps[0]==="quickDulicate"}}'}}}],"x-component-props":{type:"primary",style:{float:"right",position:"relative",zIndex:1200},useAction:()=>{const l=r.useForm();return P(l)}}},unselectAll:{type:"void",title:'{{ t("UnSelect all") }}',"x-component":"Action.Link","x-reactions":[{dependencies:[".duplicateMode",".duplicateFields"],fulfill:{state:{visible:`{{ $deps[0]==="quickDulicate"&&$form.getValuesIn('duplicateFields').length>0 }}`}}}],"x-component-props":{type:"primary",style:{float:"right",position:"relative",zIndex:1200,marginRight:"10px"},useAction:()=>{const l=r.useForm();return w(l)}}},duplicateFields:{type:"array",title:'{{ t("Data fields") }}',required:!0,description:c("Only the selected fields will be used as the initialization data for the form"),"x-decorator":"FormItem","x-component":G,"x-component-props":{defaultCheckedKeys:A,treeData:[],checkable:!0,checkStrictly:!0,selectable:!1,loadData:"{{ getOnLoadData($self) }}",onCheck:"{{ getOnCheck($self) }}",rootStyle:{padding:"8px 0",border:"1px solid #d9d9d9",borderRadius:"2px",maxHeight:"30vh",overflow:"auto",margin:"2px 0"}},"x-reactions":[{dependencies:[".collection",".duplicateMode"],fulfill:{state:{disabled:"{{ !$deps[0] }}",componentProps:{treeData:"{{ getEnableFieldTree($deps[0], $self,treeData) }}"}}}}]}}},onSubmit:({duplicateMode:l,collection:f,duplicateFields:a,treeData:h})=>{var N;const k=Array.isArray(a)?a:a.checked||[];s.componentProps.duplicateMode=l,s.componentProps.duplicateFields=k,o["x-component-props"]=o["x-component-props"]||{},o["x-component-props"].duplicateMode=l,o["x-component-props"].duplicateFields=k,o["x-component-props"].duplicateCollection=f,o["x-component-props"].treeData=h||((N=s.componentProps)==null?void 0:N.treeData),t.emit("patch",{schema:{"x-uid":o["x-uid"],"x-component-props":x({},o["x-component-props"])}}),t.refresh()}})}const Q=[{name:"Customize",Component:t=>t.children,children:[{name:"editButton",Component:e.ActionDesigner.ButtonEditor,useComponentProps(){const{buttonEditorProps:t}=e.useSchemaToolbar();return t}},{name:"linkageRules",Component:e.SchemaSettingsLinkageRules,useComponentProps(){const{name:t}=e.useCollection_deprecated(),{linkageRulesProps:c}=e.useSchemaToolbar();return g(x({},c),{collectionName:t})}},{name:"duplicationMode",Component:re,useVisible(){return r.useFieldSchema()["x-action"]==="duplicate"}},{name:"openMode",Component:e.SchemaSettingOpenModeSchemaItems,useComponentProps(){const t=r.useFieldSchema(),c=["create","update","view","customize:popup","duplicate","customize:create"].includes(t["x-action"]||"");return{openMode:c,openSize:c}}},{name:"remove",sort:100,Component:e.ActionDesigner.RemoveButton,useComponentProps(){const{removeButtonProps:t}=e.useSchemaToolbar();return t}}]}],pe=new e.SchemaSettings({name:"ActionSettings:duplicate",items:Q}),de=new e.SchemaSettings({name:"actionSettings:duplicate",items:Q}),J=t=>{const c={type:"void","x-action":"duplicate","x-acl-action":"create",title:'{{ t("Duplicate") }}',"x-component":"Action.Link","x-decorator":"ACLActionProvider","x-component-props":{openMode:"drawer",component:"DuplicateAction"},properties:{drawer:{type:"void",title:'{{ t("Duplicate") }}',"x-component":"Action.Container","x-component-props":{className:"nb-action-popup"},properties:{tabs:{type:"void","x-component":"Tabs","x-component-props":{},"x-initializer":"popup:addTab",properties:{tab1:{type:"void",title:'{{t("Duplicate")}}',"x-component":"Tabs.TabPane","x-designer":"Tabs.Designer","x-component-props":{},properties:{grid:{type:"void","x-component":"Grid","x-initializer":"popup:addNew:addBlock",properties:{}}}}}}}}}};return i.jsx(e.ActionInitializerItem,g(x({},t),{schema:c}))},ue=t=>i.jsx(e.SchemaComponentOptions,{components:{DuplicateActionInitializer:J,DuplicateAction:K},children:t.children});class W extends e.Plugin{load(){return z(this,null,function*(){this.app.use(ue),this.app.addComponents({DuplicateActionInitializer:J,DuplicateAction:K}),this.app.schemaSettingsManager.add(pe),this.app.schemaSettingsManager.add(de);const c={title:'{{t("Duplicate")}}',Component:"DuplicateActionInitializer",schema:{"x-component":"Action.Link","x-action":"duplicate","x-toolbar":"ActionSchemaToolbar","x-settings":"actionSettings:duplicate","x-decorator":"ACLActionProvider","x-component-props":{type:"primary"}},useVisible(){const s=e.useCollection_deprecated();return(s.template!=="view"||(s==null?void 0:s.writableView))&&s.template!=="file"&&s.template!=="sql"}};this.app.schemaInitializerManager.addItem("table:configureItemActions","actions.duplicate",c)})}}n.DuplicateAction=K,n.PluginActionDuplicateClient=W,n.actionDesignerCss=$,n.default=W,Object.defineProperties(n,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
package/dist/externalVersion.js
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
module.exports = {
|
|
11
|
-
"@formily/core": "2.3.0",
|
|
12
|
-
"@formily/react": "2.3.0",
|
|
13
|
-
"@nocobase/client": "1.2.13-alpha",
|
|
14
|
-
"antd": "5.12.8",
|
|
15
|
-
"lodash": "4.17.21",
|
|
16
|
-
"react": "18.2.0",
|
|
17
|
-
"react-i18next": "11.18.6",
|
|
18
|
-
"@emotion/css": "11.11.2",
|
|
19
|
-
"@nocobase/server": "1.2.13-alpha",
|
|
20
|
-
"@nocobase/test": "1.2.13-alpha"
|
|
21
|
-
};
|
package/dist/index.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
export * from './server';
|
|
10
|
-
export { default } from './server';
|
package/dist/index.js
DELETED
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
var __create = Object.create;
|
|
11
|
-
var __defProp = Object.defineProperty;
|
|
12
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
13
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
14
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
15
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
16
|
-
var __export = (target, all) => {
|
|
17
|
-
for (var name in all)
|
|
18
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
19
|
-
};
|
|
20
|
-
var __copyProps = (to, from, except, desc) => {
|
|
21
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
22
|
-
for (let key of __getOwnPropNames(from))
|
|
23
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
24
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
25
|
-
}
|
|
26
|
-
return to;
|
|
27
|
-
};
|
|
28
|
-
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
29
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
30
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
31
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
32
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
33
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
34
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
35
|
-
mod
|
|
36
|
-
));
|
|
37
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
38
|
-
var src_exports = {};
|
|
39
|
-
__export(src_exports, {
|
|
40
|
-
default: () => import_server.default
|
|
41
|
-
});
|
|
42
|
-
module.exports = __toCommonJS(src_exports);
|
|
43
|
-
__reExport(src_exports, require("./server"), module.exports);
|
|
44
|
-
var import_server = __toESM(require("./server"));
|
|
45
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
46
|
-
0 && (module.exports = {
|
|
47
|
-
...require("./server")
|
|
48
|
-
});
|
package/dist/server/index.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
export { default } from './plugin';
|
package/dist/server/index.js
DELETED
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
var __create = Object.create;
|
|
11
|
-
var __defProp = Object.defineProperty;
|
|
12
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
13
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
14
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
15
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
16
|
-
var __export = (target, all) => {
|
|
17
|
-
for (var name in all)
|
|
18
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
19
|
-
};
|
|
20
|
-
var __copyProps = (to, from, except, desc) => {
|
|
21
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
22
|
-
for (let key of __getOwnPropNames(from))
|
|
23
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
24
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
25
|
-
}
|
|
26
|
-
return to;
|
|
27
|
-
};
|
|
28
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
29
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
30
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
31
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
32
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
33
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
34
|
-
mod
|
|
35
|
-
));
|
|
36
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
37
|
-
var server_exports = {};
|
|
38
|
-
__export(server_exports, {
|
|
39
|
-
default: () => import_plugin.default
|
|
40
|
-
});
|
|
41
|
-
module.exports = __toCommonJS(server_exports);
|
|
42
|
-
var import_plugin = __toESM(require("./plugin"));
|
package/dist/server/plugin.d.ts
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
import { InstallOptions, Plugin } from '@nocobase/server';
|
|
10
|
-
export declare class PluginActionDuplicateServer extends Plugin {
|
|
11
|
-
afterAdd(): void;
|
|
12
|
-
beforeLoad(): void;
|
|
13
|
-
load(): Promise<void>;
|
|
14
|
-
install(options?: InstallOptions): Promise<void>;
|
|
15
|
-
afterEnable(): Promise<void>;
|
|
16
|
-
afterDisable(): Promise<void>;
|
|
17
|
-
remove(): Promise<void>;
|
|
18
|
-
}
|
|
19
|
-
export default PluginActionDuplicateServer;
|
package/dist/server/plugin.js
DELETED
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
var __defProp = Object.defineProperty;
|
|
11
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
12
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
13
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
|
-
var __export = (target, all) => {
|
|
15
|
-
for (var name in all)
|
|
16
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
17
|
-
};
|
|
18
|
-
var __copyProps = (to, from, except, desc) => {
|
|
19
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
20
|
-
for (let key of __getOwnPropNames(from))
|
|
21
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
22
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
23
|
-
}
|
|
24
|
-
return to;
|
|
25
|
-
};
|
|
26
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
27
|
-
var plugin_exports = {};
|
|
28
|
-
__export(plugin_exports, {
|
|
29
|
-
PluginActionDuplicateServer: () => PluginActionDuplicateServer,
|
|
30
|
-
default: () => plugin_default
|
|
31
|
-
});
|
|
32
|
-
module.exports = __toCommonJS(plugin_exports);
|
|
33
|
-
var import_server = require("@nocobase/server");
|
|
34
|
-
class PluginActionDuplicateServer extends import_server.Plugin {
|
|
35
|
-
afterAdd() {
|
|
36
|
-
}
|
|
37
|
-
beforeLoad() {
|
|
38
|
-
}
|
|
39
|
-
async load() {
|
|
40
|
-
}
|
|
41
|
-
async install(options) {
|
|
42
|
-
}
|
|
43
|
-
async afterEnable() {
|
|
44
|
-
}
|
|
45
|
-
async afterDisable() {
|
|
46
|
-
}
|
|
47
|
-
async remove() {
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
var plugin_default = PluginActionDuplicateServer;
|
|
51
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
52
|
-
0 && (module.exports = {
|
|
53
|
-
PluginActionDuplicateServer
|
|
54
|
-
});
|