Merge branch 'dev' of codeup.aliyun.com:61c14a7efa282c88e103c23f/oak-general-business into dev
This commit is contained in:
commit
b34e486970
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import './index.less';
|
||||
declare const Empty: () => JSX.Element;
|
||||
export default Empty;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import './index.less';
|
||||
declare const Empty: () => JSX.Element;
|
||||
export default Empty;
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ declare type IQrCodeProps = {
|
|||
size?: number;
|
||||
url: string;
|
||||
loading?: boolean;
|
||||
disableDownload?: boolean;
|
||||
};
|
||||
declare function QrCode(props: IQrCodeProps): JSX.Element;
|
||||
export default QrCode;
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ function isBase64(url) {
|
|||
return /data:image\/[\w|\W]+(;base64,)[\w|\W]*/.test(url);
|
||||
}
|
||||
function QrCode(props) {
|
||||
var _a = props.filename, filename = _a === void 0 ? 'qrCode.png' : _a, expiresAt = props.expiresAt, tips = props.tips, onDownload = props.onDownload, onRefresh = props.onRefresh, _b = props.size, size = _b === void 0 ? 280 : _b, url = props.url, _c = props.loading, loading = _c === void 0 ? false : _c;
|
||||
var _a = props.filename, filename = _a === void 0 ? 'qrCode.png' : _a, expiresAt = props.expiresAt, tips = props.tips, onDownload = props.onDownload, onRefresh = props.onRefresh, _b = props.size, size = _b === void 0 ? 280 : _b, url = props.url, _c = props.loading, loading = _c === void 0 ? false : _c, _d = props.disableDownload, disableDownload = _d === void 0 ? false : _d;
|
||||
var prefixCls = 'oak';
|
||||
var V;
|
||||
if (expiresAt) {
|
||||
|
|
@ -34,8 +34,9 @@ function QrCode(props) {
|
|||
return ((0, jsx_runtime_1.jsxs)("div", tslib_1.__assign({ id: "oakQrCode", className: "".concat(prefixCls, "-qrCodeBox") }, { children: [(0, jsx_runtime_1.jsx)("div", tslib_1.__assign({ className: "".concat(prefixCls, "-qrCodeBox_imgBox"), style: {
|
||||
width: size,
|
||||
height: size,
|
||||
marginBottom: 10,
|
||||
} }, { children: isBase64(url) ? ((0, jsx_runtime_1.jsx)("img", { src: url, alt: "qrCode", width: size, height: size })) : url ? ((0, jsx_runtime_1.jsx)(qrcode_react_1.QRCodeCanvas, { value: url, size: size })) : null })), V, tips, (0, jsx_runtime_1.jsxs)(antd_1.Space, tslib_1.__assign({ className: "".concat(prefixCls, "-qrCodeBox_actions") }, { children: [!!url && ((0, jsx_runtime_1.jsx)(antd_1.Button, tslib_1.__assign({ type: "text", onClick: function () {
|
||||
marginBottom: 16,
|
||||
marginTop: 16
|
||||
} }, { children: isBase64(url) ? ((0, jsx_runtime_1.jsx)("img", { src: url, alt: "qrCode", width: size, height: size })) : url ? ((0, jsx_runtime_1.jsx)(qrcode_react_1.QRCodeCanvas, { value: url, size: size })) : null })), V, tips, (0, jsx_runtime_1.jsxs)(antd_1.Space, tslib_1.__assign({ className: "".concat(prefixCls, "-qrCodeBox_actions") }, { children: [!!url && !disableDownload && ((0, jsx_runtime_1.jsx)(antd_1.Button, tslib_1.__assign({ type: "text", onClick: function () {
|
||||
var _a;
|
||||
if (typeof onDownload === 'function') {
|
||||
onDownload(url, filename);
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { AppType, WebConfig, WechatPublicConfig, WechatMpConfig } from '../../../general-app-domain/Application/Schema';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebConfig } from '../../../../general-app-domain/Application/Schema';
|
||||
export default function Web(props: {
|
||||
config: WebConfig;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WechatMpConfig } from '../../../../general-app-domain/Application/Schema';
|
||||
export default function WechatMp(props: {
|
||||
config: WechatMpConfig;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WechatPublicConfig } from '../../../../general-app-domain/Application/Schema';
|
||||
export default function WechatPublic(props: {
|
||||
isService?: boolean;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { Style as StyleType } from '../../../types/Style';
|
||||
declare type StyleProps = {
|
||||
value?: StyleType | null;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { Config } from '../../../../types/Config';
|
||||
export default function Account(props: {
|
||||
account: Required<Config>['Account'];
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { Config } from '../../../../types/Config';
|
||||
export default function Cos(props: {
|
||||
cos: Required<Config>['Cos'];
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { Config } from '../../../../types/Config';
|
||||
export default function Cos(props: {
|
||||
live: Required<Config>['Live'];
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { Config } from '../../../../types/Config';
|
||||
export default function Cos(props: {
|
||||
map: Required<Config>['Map'];
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { Config } from '../../../../types/Config';
|
||||
export default function Sms(props: {
|
||||
sms: Required<Config>['Sms'];
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { Config } from '../../../types/Config';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'extraFile', true, {
|
||||
|
|
|
|||
|
|
@ -1,2 +1 @@
|
|||
/// <reference types="react" />
|
||||
export default function render(): JSX.Element;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { UploadFile } from 'antd';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from "oak-frontend-base";
|
||||
import { EntityDict } from "../../../general-app-domain";
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'user', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'address', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'message', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { MessageProps } from 'oak-frontend-base/lib/types/Message';
|
||||
export default function render(props: {
|
||||
data: {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from "oak-frontend-base";
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'messageTypeTemplateId', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { AvatarSize } from 'antd/es/avatar/SizeContext';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'token', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'token', false, {
|
||||
|
|
|
|||
|
|
@ -0,0 +1,6 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
declare const _default: (props: import("oak-frontend-base").ReactComponentProps<EntityDict, keyof EntityDict, false, {
|
||||
type: "bind" | "login";
|
||||
}>) => import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>;
|
||||
export default _default;
|
||||
|
|
@ -0,0 +1,159 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
var tslib_1 = require("tslib");
|
||||
var uuid_1 = require("oak-domain/lib/utils/uuid");
|
||||
var Interval = 2 * 60 * 1000;
|
||||
exports.default = OakComponent({
|
||||
isList: false,
|
||||
lifetimes: {
|
||||
attached: function () {
|
||||
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
||||
var _this = this;
|
||||
return tslib_1.__generator(this, function (_a) {
|
||||
this.createWechatLogin();
|
||||
this.createTimer = setInterval(function () {
|
||||
_this.createWechatLogin();
|
||||
}, Interval);
|
||||
return [2 /*return*/];
|
||||
});
|
||||
});
|
||||
},
|
||||
detached: function () {
|
||||
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
||||
return tslib_1.__generator(this, function (_a) {
|
||||
if (this.createTimer) {
|
||||
clearInterval(this.createTimer);
|
||||
}
|
||||
return [2 /*return*/];
|
||||
});
|
||||
});
|
||||
},
|
||||
},
|
||||
data: {
|
||||
loading: false,
|
||||
},
|
||||
properties: {
|
||||
type: 'bind',
|
||||
},
|
||||
methods: {
|
||||
createWechatLogin: function () {
|
||||
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
||||
var userId, wechatLoginId, _a, type, _b, _c, _d;
|
||||
var _e;
|
||||
var _this = this;
|
||||
return tslib_1.__generator(this, function (_f) {
|
||||
switch (_f.label) {
|
||||
case 0:
|
||||
userId = this.features.token.getUserId();
|
||||
return [4 /*yield*/, (0, uuid_1.generateNewIdAsync)()];
|
||||
case 1:
|
||||
wechatLoginId = _f.sent();
|
||||
_a = this.props.type, type = _a === void 0 ? 'bind' : _a;
|
||||
_c = (_b = this.features.cache).operate;
|
||||
_d = ['wechatLogin'];
|
||||
_e = {};
|
||||
return [4 /*yield*/, (0, uuid_1.generateNewIdAsync)()];
|
||||
case 2: return [4 /*yield*/, _c.apply(_b, _d.concat([(_e.id = _f.sent(),
|
||||
_e.action = 'create',
|
||||
_e.data = {
|
||||
id: wechatLoginId,
|
||||
userId: userId,
|
||||
type: type,
|
||||
expiresAt: Date.now() + Interval,
|
||||
expired: false,
|
||||
qrCodeType: 'wechatPublic',
|
||||
successed: false,
|
||||
},
|
||||
_e)]))];
|
||||
case 3:
|
||||
_f.sent();
|
||||
this.setState({
|
||||
wechatLoginId: wechatLoginId,
|
||||
}, function () {
|
||||
_this.getWechatLogin();
|
||||
});
|
||||
return [2 /*return*/];
|
||||
}
|
||||
});
|
||||
});
|
||||
},
|
||||
getWechatLogin: function () {
|
||||
var _a, _b;
|
||||
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
||||
var wechatLoginId, _c, wechatLogin, qrCodeUrl, buffer, newBuffer, newBufferToUint16, i, base64Str, binary, bytes, len, i, base64Str;
|
||||
return tslib_1.__generator(this, function (_d) {
|
||||
switch (_d.label) {
|
||||
case 0:
|
||||
wechatLoginId = this.state.wechatLoginId;
|
||||
return [4 /*yield*/, this.features.cache.refresh('wechatLogin', {
|
||||
data: {
|
||||
id: 1,
|
||||
userId: 1,
|
||||
type: 1,
|
||||
qrCodeType: 1,
|
||||
remark: 1,
|
||||
expired: 1,
|
||||
expiresAt: 1,
|
||||
successed: 1,
|
||||
wechatQrCode$entity: {
|
||||
$entity: 'wechatQrCode',
|
||||
data: {
|
||||
id: 1,
|
||||
entity: 1,
|
||||
entityId: 1,
|
||||
type: 1,
|
||||
ticket: 1,
|
||||
url: 1,
|
||||
buffer: 1,
|
||||
expired: 1,
|
||||
expiresAt: 1,
|
||||
applicationId: 1,
|
||||
},
|
||||
filter: {
|
||||
entity: 'wechatLogin',
|
||||
},
|
||||
indexFrom: 0,
|
||||
count: 1,
|
||||
},
|
||||
},
|
||||
filter: {
|
||||
id: wechatLoginId,
|
||||
},
|
||||
})];
|
||||
case 1:
|
||||
_c = tslib_1.__read.apply(void 0, [(_d.sent()).data, 1]), wechatLogin = _c[0];
|
||||
qrCodeUrl = (_a = wechatLogin === null || wechatLogin === void 0 ? void 0 : wechatLogin.wechatQrCode$entity[0]) === null || _a === void 0 ? void 0 : _a.url;
|
||||
buffer = (_b = wechatLogin === null || wechatLogin === void 0 ? void 0 : wechatLogin.wechatQrCode$entity[0]) === null || _b === void 0 ? void 0 : _b.buffer;
|
||||
if (buffer) {
|
||||
newBuffer = new ArrayBuffer(buffer.length * 2);
|
||||
newBufferToUint16 = new Uint16Array(newBuffer);
|
||||
for (i = 0; i < buffer.length; i++) {
|
||||
newBufferToUint16[i] = buffer.charCodeAt(i);
|
||||
}
|
||||
if (process.env.OAK_PLATFORM === 'wechatMp') {
|
||||
base64Str = wx.arrayBufferToBase64(newBufferToUint16);
|
||||
qrCodeUrl = 'data:image/png;base64,' + base64Str;
|
||||
}
|
||||
else {
|
||||
binary = '';
|
||||
bytes = new Uint8Array(newBufferToUint16);
|
||||
len = bytes.byteLength;
|
||||
for (i = 0; i < len; i++) {
|
||||
binary += String.fromCharCode(bytes[i]);
|
||||
}
|
||||
base64Str = window.btoa(binary);
|
||||
// const buffer2 = Buffer.from(newBufferToUint16, 'base64');
|
||||
// const base64Str = buffer2.toString('base64');
|
||||
qrCodeUrl = 'data:image/png;base64,' + base64Str;
|
||||
}
|
||||
}
|
||||
this.setState({
|
||||
qrCodeUrl: qrCodeUrl,
|
||||
});
|
||||
return [2 /*return*/];
|
||||
}
|
||||
});
|
||||
});
|
||||
},
|
||||
},
|
||||
});
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'wechatLogin', true, {
|
||||
wechatLoginId: string;
|
||||
qrCodeUrl: string;
|
||||
loading: boolean;
|
||||
}, {}>): JSX.Element;
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
var tslib_1 = require("tslib");
|
||||
var jsx_runtime_1 = require("react/jsx-runtime");
|
||||
var qrCode_1 = tslib_1.__importDefault(require("../../../components/common/qrCode"));
|
||||
function Render(props) {
|
||||
var _a = props.data, oakFullpath = _a.oakFullpath, qrCodeUrl = _a.qrCodeUrl, loading = _a.loading;
|
||||
return ((0, jsx_runtime_1.jsx)("div", { children: (0, jsx_runtime_1.jsx)(qrCode_1.default, { loading: loading, url: qrCodeUrl, disableDownload: true, tips: (0, jsx_runtime_1.jsx)("div", { children: "\u5FAE\u4FE1\u626B\u4E00\u626B" }) }) }));
|
||||
}
|
||||
exports.default = Render;
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
.container {
|
||||
display: flex;
|
||||
}
|
||||
|
|
@ -104,10 +104,10 @@ function setUserUnsubscribed(openId, context) {
|
|||
}
|
||||
function setUserSubscribed(openId, eventKey, context) {
|
||||
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
||||
var _a, applicationId, applicationType, list, now, data, doUpdate, sceneStr, wcqId, _b, wechatQrCode, application, _c, type, config, systemId, _d, appId, appSecret, wechatInstance, expired, entity, entityId, _e, _f, userEntityGrant, _g, id, granter, expired_1, entity2, qrCodeType, name_1, _h, appMp, config_1, appId_1, url, content, _j, domain, url;
|
||||
var _a, applicationId, applicationType, list, now, data, doUpdate, sceneStr, wcqId, _b, wechatQrCode, application, _c, type, config, systemId, _d, appId, appSecret, wechatInstance, expired, entity, entityId, _e, _f, userEntityGrant, _g, id, granter, expired_1, entity2, qrCodeType, name_1, _h, appMp, config_1, appId_1, url, content, _j, domain, url, _k, wechatLogin, qrCodeType, expired_2, userId, type_1, successed, _l, domain, url, title, description;
|
||||
var _this = this;
|
||||
return tslib_1.__generator(this, function (_k) {
|
||||
switch (_k.label) {
|
||||
return tslib_1.__generator(this, function (_m) {
|
||||
switch (_m.label) {
|
||||
case 0:
|
||||
_a = context.getApplication(), applicationId = _a.id, applicationType = _a.type;
|
||||
return [4 /*yield*/, context.select('wechatUser', {
|
||||
|
|
@ -124,7 +124,7 @@ function setUserSubscribed(openId, eventKey, context) {
|
|||
count: 1,
|
||||
}, { dontCollect: true })];
|
||||
case 1:
|
||||
list = _k.sent();
|
||||
list = _m.sent();
|
||||
now = Date.now();
|
||||
data = {
|
||||
// activeAt: now,
|
||||
|
|
@ -196,7 +196,7 @@ function setUserSubscribed(openId, eventKey, context) {
|
|||
}
|
||||
});
|
||||
}); };
|
||||
if (!eventKey) return [3 /*break*/, 11];
|
||||
if (!eventKey) return [3 /*break*/, 18];
|
||||
sceneStr = void 0;
|
||||
if (eventKey.startsWith('qrscene_')) {
|
||||
sceneStr = eventKey.slice(eventKey.indexOf('qrscene_') + 8);
|
||||
|
|
@ -219,8 +219,8 @@ function setUserSubscribed(openId, eventKey, context) {
|
|||
count: 10,
|
||||
}, { dontCollect: true })];
|
||||
case 2:
|
||||
_b = tslib_1.__read.apply(void 0, [_k.sent(), 1]), wechatQrCode = _b[0];
|
||||
if (!wechatQrCode) return [3 /*break*/, 10];
|
||||
_b = tslib_1.__read.apply(void 0, [_m.sent(), 1]), wechatQrCode = _b[0];
|
||||
if (!wechatQrCode) return [3 /*break*/, 17];
|
||||
application = context.getApplication();
|
||||
_c = application, type = _c.type, config = _c.config, systemId = _c.systemId;
|
||||
(0, assert_1.default)(type === 'wechatPublic');
|
||||
|
|
@ -241,17 +241,18 @@ function setUserSubscribed(openId, eventKey, context) {
|
|||
switch (_e) {
|
||||
case 'user': return [3 /*break*/, 3];
|
||||
case 'userEntityGrant': return [3 /*break*/, 4];
|
||||
case 'wechatLogin': return [3 /*break*/, 10];
|
||||
}
|
||||
return [3 /*break*/, 9];
|
||||
return [3 /*break*/, 15];
|
||||
case 3:
|
||||
{
|
||||
// 裂变获得的用户
|
||||
if (list[0] && !list[0].userId) {
|
||||
Object.assign(data, { userId: entityId });
|
||||
}
|
||||
return [3 /*break*/, 9];
|
||||
return [3 /*break*/, 16];
|
||||
}
|
||||
_k.label = 4;
|
||||
_m.label = 4;
|
||||
case 4: return [4 /*yield*/, context.select('userEntityGrant', {
|
||||
data: {
|
||||
id: 1,
|
||||
|
|
@ -266,10 +267,10 @@ function setUserSubscribed(openId, eventKey, context) {
|
|||
},
|
||||
filter: {
|
||||
id: entityId,
|
||||
}
|
||||
},
|
||||
}, { dontCollect: true })];
|
||||
case 5:
|
||||
_f = tslib_1.__read.apply(void 0, [_k.sent(), 1]), userEntityGrant = _f[0];
|
||||
_f = tslib_1.__read.apply(void 0, [_m.sent(), 1]), userEntityGrant = _f[0];
|
||||
_g = userEntityGrant, id = _g.id, granter = _g.granter, expired_1 = _g.expired, entity2 = _g.entity, qrCodeType = _g.qrCodeType;
|
||||
name_1 = (granter === null || granter === void 0 ? void 0 : granter.name) || (granter === null || granter === void 0 ? void 0 : granter.nickname) || '某用户';
|
||||
if (!(qrCodeType === 'wechatPublicForMp')) return [3 /*break*/, 7];
|
||||
|
|
@ -284,7 +285,7 @@ function setUserSubscribed(openId, eventKey, context) {
|
|||
},
|
||||
}, { dontCollect: true })];
|
||||
case 6:
|
||||
_h = tslib_1.__read.apply(void 0, [_k.sent(), 1]), appMp = _h[0];
|
||||
_h = tslib_1.__read.apply(void 0, [_m.sent(), 1]), appMp = _h[0];
|
||||
(0, assert_1.default)(appMp, '公众号推送小程序码时找不到关联的小程序');
|
||||
config_1 = appMp.config;
|
||||
appId_1 = config_1.appId;
|
||||
|
|
@ -293,7 +294,6 @@ function setUserSubscribed(openId, eventKey, context) {
|
|||
time: "".concat(Date.now()),
|
||||
});
|
||||
content = "".concat(name_1, "\u4E3A\u60A8\u521B\u5EFA\u4E86\u4E00\u4E2A\u6388\u6743\uFF0C<a href='#' data-miniprogram-appid='").concat(appId_1, "' data-miniprogram-path='").concat(url, "'>\u8BF7\u70B9\u51FB\u9886\u53D6</a>");
|
||||
// assert(!expired); // 如果生成的wechatQrCode没过期,userEntityGrant就不可能过期。
|
||||
if (!expired_1) {
|
||||
wechatInstance.sendServeMessage({
|
||||
openId: openId,
|
||||
|
|
@ -326,19 +326,18 @@ function setUserSubscribed(openId, eventKey, context) {
|
|||
},
|
||||
filter: {
|
||||
id: applicationId,
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}, { dontCollect: true })];
|
||||
case 8:
|
||||
_j = tslib_1.__read.apply(void 0, [_k.sent(), 1]), domain = _j[0];
|
||||
_j = tslib_1.__read.apply(void 0, [_m.sent(), 1]), domain = _j[0];
|
||||
(0, assert_1.default)(domain, "\u5904\u7406userEntityGrant\u65F6\uFF0C\u627E\u4E0D\u5230\u5BF9\u5E94\u7684domain\uFF0CapplicationId\u662F\u300C".concat(applicationId, "\u300D"));
|
||||
url = (0, domain_1.composeDomainUrl)(domain, 'wechatQrCode/scan', {
|
||||
scene: sceneStr,
|
||||
time: "".concat(Date.now()),
|
||||
});
|
||||
// assert(!expired); // 如果生成的wechatQrCode没过期,userEntityGrant就不可能过期。
|
||||
if (!expired_1) {
|
||||
wechatInstance.sendServeMessage({
|
||||
openId: openId,
|
||||
|
|
@ -356,14 +355,88 @@ function setUserSubscribed(openId, eventKey, context) {
|
|||
content: '您好,您扫描的二维码已经过期,请联系管理员重新获取',
|
||||
});
|
||||
}
|
||||
_k.label = 9;
|
||||
case 9: return [3 /*break*/, 11];
|
||||
case 10:
|
||||
_m.label = 9;
|
||||
case 9: return [3 /*break*/, 16];
|
||||
case 10: return [4 /*yield*/, context.select('wechatLogin', {
|
||||
data: {
|
||||
id: 1,
|
||||
qrCodeType: 1,
|
||||
expired: 1,
|
||||
userId: 1,
|
||||
type: 1,
|
||||
successed: 1,
|
||||
},
|
||||
filter: {
|
||||
id: entityId,
|
||||
},
|
||||
}, { dontCollect: true })];
|
||||
case 11:
|
||||
_k = tslib_1.__read.apply(void 0, [_m.sent(), 1]), wechatLogin = _k[0];
|
||||
qrCodeType = wechatLogin.qrCodeType, expired_2 = wechatLogin.expired, userId = wechatLogin.userId, type_1 = wechatLogin.type, successed = wechatLogin.successed;
|
||||
if (!(qrCodeType === 'wechatPublicForMp')) return [3 /*break*/, 12];
|
||||
return [3 /*break*/, 14];
|
||||
case 12: return [4 /*yield*/, context.select('domain', {
|
||||
data: {
|
||||
id: 1,
|
||||
url: 1,
|
||||
apiPath: 1,
|
||||
protocol: 1,
|
||||
port: 1,
|
||||
},
|
||||
filter: {
|
||||
systemId: {
|
||||
$in: {
|
||||
entity: 'application',
|
||||
data: {
|
||||
systemId: 1,
|
||||
},
|
||||
filter: {
|
||||
id: applicationId,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}, { dontCollect: true })];
|
||||
case 13:
|
||||
_l = tslib_1.__read.apply(void 0, [_m.sent(), 1]), domain = _l[0];
|
||||
(0, assert_1.default)(domain, "\u5904\u7406wechatLogin\u65F6\uFF0C\u627E\u4E0D\u5230\u5BF9\u5E94\u7684domain\uFF0CapplicationId\u662F\u300C".concat(applicationId, "\u300D"));
|
||||
url = (0, domain_1.composeDomainUrl)(domain, 'wechatQrCode/scan', {
|
||||
scene: sceneStr,
|
||||
time: "".concat(Date.now()),
|
||||
});
|
||||
title = type_1 === 'bind' ? '扫码绑定' : '扫码登录';
|
||||
description = type_1 === 'bind' ? '去绑定' : '去登录';
|
||||
if (!expired_2) {
|
||||
wechatInstance.sendServeMessage({
|
||||
openId: openId,
|
||||
type: 'news',
|
||||
url: url,
|
||||
title: title,
|
||||
description: description,
|
||||
picurl: 'http://img95.699pic.com/element/40018/2473.png_860.png',
|
||||
});
|
||||
}
|
||||
else {
|
||||
wechatInstance.sendServeMessage({
|
||||
openId: openId,
|
||||
type: 'text',
|
||||
content: '您好,您扫描的二维码已经过期,请重新生成',
|
||||
});
|
||||
}
|
||||
_m.label = 14;
|
||||
case 14: return [3 /*break*/, 16];
|
||||
case 15:
|
||||
{
|
||||
return [3 /*break*/, 16];
|
||||
}
|
||||
_m.label = 16;
|
||||
case 16: return [3 /*break*/, 18];
|
||||
case 17:
|
||||
console.warn("\u7EBF\u4E0A\u6709\u626B\u63CF\u4E8C\u7EF4\u7801\u573A\u666F\u503C\uFF0C\u4F46\u627E\u4E0D\u5230\u5BF9\u5E94\u7684qrCode\uFF0CeventKey\u662F".concat(eventKey));
|
||||
_k.label = 11;
|
||||
case 11: return [4 /*yield*/, doUpdate()];
|
||||
case 12:
|
||||
_k.sent();
|
||||
_m.label = 18;
|
||||
case 18: return [4 /*yield*/, doUpdate()];
|
||||
case 19:
|
||||
_m.sent();
|
||||
return [2 /*return*/];
|
||||
}
|
||||
});
|
||||
|
|
|
|||
|
|
@ -0,0 +1,15 @@
|
|||
import { Text, Datetime } from 'oak-domain/lib/types/DataType';
|
||||
import { EntityShape } from 'oak-domain/lib/types/Entity';
|
||||
import { Schema as User } from './User';
|
||||
import { Schema as WechatQrCode } from './WechatQrCode';
|
||||
import { QrCodeType } from '../types/Config';
|
||||
export interface Schema extends EntityShape {
|
||||
user?: User;
|
||||
type: 'bind' | 'login';
|
||||
successed: Boolean;
|
||||
remark?: Text;
|
||||
qrCodeType: QrCodeType;
|
||||
expiresAt?: Datetime;
|
||||
expired?: Boolean;
|
||||
codes: Array<WechatQrCode>;
|
||||
}
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
var indexes = [
|
||||
{
|
||||
name: 'index_uuid',
|
||||
attributes: [
|
||||
{
|
||||
name: 'expired',
|
||||
},
|
||||
{
|
||||
name: 'expiresAt',
|
||||
}
|
||||
],
|
||||
},
|
||||
];
|
||||
var locale = {
|
||||
zh_CN: {
|
||||
name: '绑定微信号',
|
||||
attr: {
|
||||
user: '用户',
|
||||
type: '类型',
|
||||
successed: '是否成功',
|
||||
remark: '备注',
|
||||
codes: '微信码',
|
||||
expired: '是否过期',
|
||||
expiresAt: '过期时间',
|
||||
qrCodeType: '二维码类型',
|
||||
},
|
||||
action: {
|
||||
success: '成功',
|
||||
},
|
||||
v: {
|
||||
type: {
|
||||
bind: '绑定',
|
||||
login: '登录',
|
||||
},
|
||||
qrCodeType: {
|
||||
webForWechatPublic: '网站引流到公众号',
|
||||
wechatMpDomainUrl: '小程序url码',
|
||||
wechatMpWxaCode: '小程序码',
|
||||
wechatPublic: '公众号关注码',
|
||||
wechatPublicForMp: '公众号跳转小程序码',
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
|
|
@ -8,6 +8,7 @@ import { BasicFeatures } from 'oak-frontend-base/lib/features';
|
|||
import { AspectDict } from '../aspects/AspectDict';
|
||||
import { AppType } from '../general-app-domain/Application/Schema';
|
||||
import { EntityDict } from '../general-app-domain';
|
||||
import Theme from './theme';
|
||||
import { BackendRuntimeContext } from '../context/BackendRuntimeContext';
|
||||
import { FrontendRuntimeContext } from '../context/FrontendRuntimeContext';
|
||||
export declare function initialize<ED extends EntityDict, Cxt extends BackendRuntimeContext<ED>, FrontCxt extends FrontendRuntimeContext<ED, Cxt, AD>, AD extends AspectDict<ED, Cxt> & CommonAspectDict<ED, Cxt>>(basicFeatures: BasicFeatures<ED, Cxt, FrontCxt, AD>, type: AppType, domain: string): GeneralFeatures<ED, Cxt, FrontCxt, AD>;
|
||||
|
|
@ -17,4 +18,5 @@ export declare type GeneralFeatures<ED extends EntityDict, Cxt extends BackendRu
|
|||
application: Application<ED, Cxt, FrontCxt, AD>;
|
||||
config: Config<ED, Cxt, FrontCxt, AD>;
|
||||
weiXinJsSdk: WeiXinJsSdk<ED, Cxt, FrontCxt, AD>;
|
||||
theme: Theme<ED, Cxt, FrontCxt, AD>;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,23 +1,27 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.initialize = void 0;
|
||||
var tslib_1 = require("tslib");
|
||||
var token_1 = require("./token");
|
||||
var extraFile_1 = require("./extraFile");
|
||||
var application_1 = require("./application");
|
||||
var config_1 = require("./config");
|
||||
var weiXinJsSdk_1 = require("./weiXinJsSdk");
|
||||
var theme_1 = tslib_1.__importDefault(require("./theme"));
|
||||
function initialize(basicFeatures, type, domain) {
|
||||
var application = new application_1.Application(type, domain, basicFeatures.cache, basicFeatures.localStorage);
|
||||
var token = new token_1.Token(basicFeatures.cache, basicFeatures.localStorage);
|
||||
var extraFile = new extraFile_1.ExtraFile(basicFeatures.cache, application);
|
||||
var config = new config_1.Config(basicFeatures.cache);
|
||||
var weiXinJsSdk = new weiXinJsSdk_1.WeiXinJsSdk(basicFeatures.cache, basicFeatures.localStorage);
|
||||
var theme = new theme_1.default(basicFeatures.cache, basicFeatures.localStorage);
|
||||
return {
|
||||
token: token,
|
||||
extraFile: extraFile,
|
||||
application: application,
|
||||
config: config,
|
||||
weiXinJsSdk: weiXinJsSdk,
|
||||
theme: theme,
|
||||
};
|
||||
}
|
||||
exports.initialize = initialize;
|
||||
|
|
|
|||
|
|
@ -29,4 +29,5 @@ export declare const ActionDefDict: {
|
|||
userState: import("oak-domain/lib/types").ActionDef<string, string>;
|
||||
};
|
||||
userEntityGrant: {};
|
||||
wechatLogin: {};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ var Action_7 = require("./Notification/Action");
|
|||
var Action_8 = require("./Token/Action");
|
||||
var Action_9 = require("./User/Action");
|
||||
var Action_10 = require("./UserEntityGrant/Action");
|
||||
var Action_11 = require("./WechatLogin/Action");
|
||||
exports.ActionDefDict = {
|
||||
modi: Action_1.ActionDefDict,
|
||||
article: Action_2.ActionDefDict,
|
||||
|
|
@ -21,5 +22,6 @@ exports.ActionDefDict = {
|
|||
notification: Action_7.ActionDefDict,
|
||||
token: Action_8.ActionDefDict,
|
||||
user: Action_9.ActionDefDict,
|
||||
userEntityGrant: Action_10.ActionDefDict
|
||||
userEntityGrant: Action_10.ActionDefDict,
|
||||
wechatLogin: Action_11.ActionDefDict
|
||||
};
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@ import { EntityDef as System } from "./System/Schema";
|
|||
import { EntityDef as Token } from "./Token/Schema";
|
||||
import { EntityDef as UserSystem } from "./UserSystem/Schema";
|
||||
import { EntityDef as UserWechatPublicTag } from "./UserWechatPublicTag/Schema";
|
||||
import { EntityDef as WechatLogin } from "./WechatLogin/Schema";
|
||||
import { EntityDef as WechatPublicTag } from "./WechatPublicTag/Schema";
|
||||
import { EntityDef as WechatQrCode } from "./WechatQrCode/Schema";
|
||||
import { EntityDef as WechatUser } from "./WechatUser/Schema";
|
||||
|
|
@ -74,6 +75,7 @@ export declare type EntityDict = {
|
|||
token: Token;
|
||||
userSystem: UserSystem;
|
||||
userWechatPublicTag: UserWechatPublicTag;
|
||||
wechatLogin: WechatLogin;
|
||||
wechatPublicTag: WechatPublicTag;
|
||||
wechatQrCode: WechatQrCode;
|
||||
wechatUser: WechatUser;
|
||||
|
|
|
|||
|
|
@ -9,24 +9,26 @@ import * as User from "../User/Schema";
|
|||
import * as UserEntityGrant from "../UserEntityGrant/Schema";
|
||||
import * as UserSystem from "../UserSystem/Schema";
|
||||
import * as UserWechatPublicTag from "../UserWechatPublicTag/Schema";
|
||||
import * as WechatLogin from "../WechatLogin/Schema";
|
||||
import * as WechatPublicTag from "../WechatPublicTag/Schema";
|
||||
import * as WechatQrCode from "../WechatQrCode/Schema";
|
||||
import * as WechatUser from "../WechatUser/Schema";
|
||||
export declare type OpSchema = EntityShape & {
|
||||
modiId: ForeignKey<"modi">;
|
||||
entity: "user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string;
|
||||
entity: "user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatLogin" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string;
|
||||
entityId: String<64>;
|
||||
};
|
||||
export declare type OpAttr = keyof OpSchema;
|
||||
export declare type Schema = EntityShape & {
|
||||
modiId: ForeignKey<"modi">;
|
||||
entity: "user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string;
|
||||
entity: "user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatLogin" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string;
|
||||
entityId: String<64>;
|
||||
modi: Modi.Schema;
|
||||
user?: User.Schema;
|
||||
userEntityGrant?: UserEntityGrant.Schema;
|
||||
userSystem?: UserSystem.Schema;
|
||||
userWechatPublicTag?: UserWechatPublicTag.Schema;
|
||||
wechatLogin?: WechatLogin.Schema;
|
||||
wechatPublicTag?: WechatPublicTag.Schema;
|
||||
wechatQrCode?: WechatQrCode.Schema;
|
||||
wechatUser?: WechatUser.Schema;
|
||||
|
|
@ -46,11 +48,12 @@ declare type AttrFilter<E> = {
|
|||
userEntityGrant: UserEntityGrant.Filter;
|
||||
userSystem: UserSystem.Filter;
|
||||
userWechatPublicTag: UserWechatPublicTag.Filter;
|
||||
wechatLogin: WechatLogin.Filter;
|
||||
wechatPublicTag: WechatPublicTag.Filter;
|
||||
wechatQrCode: WechatQrCode.Filter;
|
||||
wechatUser: WechatUser.Filter;
|
||||
};
|
||||
export declare type Filter<E = Q_EnumValue<"user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string>> = MakeFilter<AttrFilter<E> & ExprOp<OpAttr | string>>;
|
||||
export declare type Filter<E = Q_EnumValue<"user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatLogin" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string>> = MakeFilter<AttrFilter<E> & ExprOp<OpAttr | string>>;
|
||||
export declare type Projection = {
|
||||
"#id"?: NodeId;
|
||||
[k: string]: any;
|
||||
|
|
@ -66,6 +69,7 @@ export declare type Projection = {
|
|||
userEntityGrant?: UserEntityGrant.Projection;
|
||||
userSystem?: UserSystem.Projection;
|
||||
userWechatPublicTag?: UserWechatPublicTag.Projection;
|
||||
wechatLogin?: WechatLogin.Projection;
|
||||
wechatPublicTag?: WechatPublicTag.Projection;
|
||||
wechatQrCode?: WechatQrCode.Projection;
|
||||
wechatUser?: WechatUser.Projection;
|
||||
|
|
@ -88,6 +92,9 @@ declare type UserSystemIdProjection = OneOf<{
|
|||
declare type UserWechatPublicTagIdProjection = OneOf<{
|
||||
entityId: number;
|
||||
}>;
|
||||
declare type WechatLoginIdProjection = OneOf<{
|
||||
entityId: number;
|
||||
}>;
|
||||
declare type WechatPublicTagIdProjection = OneOf<{
|
||||
entityId: number;
|
||||
}>;
|
||||
|
|
@ -121,6 +128,8 @@ export declare type SortAttr = {
|
|||
userSystem: UserSystem.SortAttr;
|
||||
} | {
|
||||
userWechatPublicTag: UserWechatPublicTag.SortAttr;
|
||||
} | {
|
||||
wechatLogin: WechatLogin.SortAttr;
|
||||
} | {
|
||||
wechatPublicTag: WechatPublicTag.SortAttr;
|
||||
} | {
|
||||
|
|
@ -190,6 +199,17 @@ export declare type CreateOperationData = FormCreateData<Omit<OpSchema, "entity"
|
|||
} | {
|
||||
entity: "userWechatPublicTag";
|
||||
entityId: String<64>;
|
||||
} | {
|
||||
entity?: never;
|
||||
entityId?: never;
|
||||
wechatLogin: WechatLogin.CreateSingleOperation;
|
||||
} | {
|
||||
entity: "wechatLogin";
|
||||
entityId: String<64>;
|
||||
wechatLogin: WechatLogin.UpdateOperation;
|
||||
} | {
|
||||
entity: "wechatLogin";
|
||||
entityId: String<64>;
|
||||
} | {
|
||||
entity?: never;
|
||||
entityId?: never;
|
||||
|
|
@ -259,6 +279,10 @@ export declare type UpdateOperationData = FormUpdateData<Omit<OpSchema, "entity"
|
|||
userWechatPublicTag?: UserWechatPublicTag.CreateSingleOperation | UserWechatPublicTag.UpdateOperation | UserWechatPublicTag.RemoveOperation;
|
||||
entityId?: never;
|
||||
entity?: never;
|
||||
} | {
|
||||
wechatLogin?: WechatLogin.CreateSingleOperation | WechatLogin.UpdateOperation | WechatLogin.RemoveOperation;
|
||||
entityId?: never;
|
||||
entity?: never;
|
||||
} | {
|
||||
wechatPublicTag?: WechatPublicTag.CreateSingleOperation | WechatPublicTag.UpdateOperation | WechatPublicTag.RemoveOperation;
|
||||
entityId?: never;
|
||||
|
|
@ -272,7 +296,7 @@ export declare type UpdateOperationData = FormUpdateData<Omit<OpSchema, "entity"
|
|||
entityId?: never;
|
||||
entity?: never;
|
||||
} | {
|
||||
entity?: ("user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string) | null;
|
||||
entity?: ("user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatLogin" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string) | null;
|
||||
entityId?: String<64> | null;
|
||||
}) & {
|
||||
[k: string]: any;
|
||||
|
|
@ -288,6 +312,8 @@ export declare type RemoveOperationData = {} & (({
|
|||
userSystem?: UserSystem.UpdateOperation | UserSystem.RemoveOperation;
|
||||
} | {
|
||||
userWechatPublicTag?: UserWechatPublicTag.UpdateOperation | UserWechatPublicTag.RemoveOperation;
|
||||
} | {
|
||||
wechatLogin?: WechatLogin.UpdateOperation | WechatLogin.RemoveOperation;
|
||||
} | {
|
||||
wechatPublicTag?: WechatPublicTag.UpdateOperation | WechatPublicTag.RemoveOperation;
|
||||
} | {
|
||||
|
|
@ -304,6 +330,7 @@ export declare type UserIdSubQuery = Selection<UserIdProjection>;
|
|||
export declare type UserEntityGrantIdSubQuery = Selection<UserEntityGrantIdProjection>;
|
||||
export declare type UserSystemIdSubQuery = Selection<UserSystemIdProjection>;
|
||||
export declare type UserWechatPublicTagIdSubQuery = Selection<UserWechatPublicTagIdProjection>;
|
||||
export declare type WechatLoginIdSubQuery = Selection<WechatLoginIdProjection>;
|
||||
export declare type WechatPublicTagIdSubQuery = Selection<WechatPublicTagIdProjection>;
|
||||
export declare type WechatQrCodeIdSubQuery = Selection<WechatQrCodeIdProjection>;
|
||||
export declare type WechatUserIdSubQuery = Selection<WechatUserIdProjection>;
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ exports.desc = {
|
|||
params: {
|
||||
length: 32
|
||||
},
|
||||
ref: ["user", "userEntityGrant", "userSystem", "userWechatPublicTag", "wechatPublicTag", "wechatQrCode", "wechatUser"]
|
||||
ref: ["user", "userEntityGrant", "userSystem", "userWechatPublicTag", "wechatLogin", "wechatPublicTag", "wechatQrCode", "wechatUser"]
|
||||
},
|
||||
entityId: {
|
||||
notNull: true,
|
||||
|
|
|
|||
|
|
@ -9,24 +9,26 @@ import * as User from "../User/Schema";
|
|||
import * as UserEntityGrant from "../UserEntityGrant/Schema";
|
||||
import * as UserSystem from "../UserSystem/Schema";
|
||||
import * as UserWechatPublicTag from "../UserWechatPublicTag/Schema";
|
||||
import * as WechatLogin from "../WechatLogin/Schema";
|
||||
import * as WechatPublicTag from "../WechatPublicTag/Schema";
|
||||
import * as WechatQrCode from "../WechatQrCode/Schema";
|
||||
import * as WechatUser from "../WechatUser/Schema";
|
||||
export declare type OpSchema = EntityShape & {
|
||||
operId: ForeignKey<"oper">;
|
||||
entity: "user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string;
|
||||
entity: "user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatLogin" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string;
|
||||
entityId: String<64>;
|
||||
};
|
||||
export declare type OpAttr = keyof OpSchema;
|
||||
export declare type Schema = EntityShape & {
|
||||
operId: ForeignKey<"oper">;
|
||||
entity: "user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string;
|
||||
entity: "user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatLogin" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string;
|
||||
entityId: String<64>;
|
||||
oper: Oper.Schema;
|
||||
user?: User.Schema;
|
||||
userEntityGrant?: UserEntityGrant.Schema;
|
||||
userSystem?: UserSystem.Schema;
|
||||
userWechatPublicTag?: UserWechatPublicTag.Schema;
|
||||
wechatLogin?: WechatLogin.Schema;
|
||||
wechatPublicTag?: WechatPublicTag.Schema;
|
||||
wechatQrCode?: WechatQrCode.Schema;
|
||||
wechatUser?: WechatUser.Schema;
|
||||
|
|
@ -46,11 +48,12 @@ declare type AttrFilter<E> = {
|
|||
userEntityGrant: UserEntityGrant.Filter;
|
||||
userSystem: UserSystem.Filter;
|
||||
userWechatPublicTag: UserWechatPublicTag.Filter;
|
||||
wechatLogin: WechatLogin.Filter;
|
||||
wechatPublicTag: WechatPublicTag.Filter;
|
||||
wechatQrCode: WechatQrCode.Filter;
|
||||
wechatUser: WechatUser.Filter;
|
||||
};
|
||||
export declare type Filter<E = Q_EnumValue<"user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string>> = MakeFilter<AttrFilter<E> & ExprOp<OpAttr | string>>;
|
||||
export declare type Filter<E = Q_EnumValue<"user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatLogin" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string>> = MakeFilter<AttrFilter<E> & ExprOp<OpAttr | string>>;
|
||||
export declare type Projection = {
|
||||
"#id"?: NodeId;
|
||||
[k: string]: any;
|
||||
|
|
@ -66,6 +69,7 @@ export declare type Projection = {
|
|||
userEntityGrant?: UserEntityGrant.Projection;
|
||||
userSystem?: UserSystem.Projection;
|
||||
userWechatPublicTag?: UserWechatPublicTag.Projection;
|
||||
wechatLogin?: WechatLogin.Projection;
|
||||
wechatPublicTag?: WechatPublicTag.Projection;
|
||||
wechatQrCode?: WechatQrCode.Projection;
|
||||
wechatUser?: WechatUser.Projection;
|
||||
|
|
@ -88,6 +92,9 @@ declare type UserSystemIdProjection = OneOf<{
|
|||
declare type UserWechatPublicTagIdProjection = OneOf<{
|
||||
entityId: number;
|
||||
}>;
|
||||
declare type WechatLoginIdProjection = OneOf<{
|
||||
entityId: number;
|
||||
}>;
|
||||
declare type WechatPublicTagIdProjection = OneOf<{
|
||||
entityId: number;
|
||||
}>;
|
||||
|
|
@ -121,6 +128,8 @@ export declare type SortAttr = {
|
|||
userSystem: UserSystem.SortAttr;
|
||||
} | {
|
||||
userWechatPublicTag: UserWechatPublicTag.SortAttr;
|
||||
} | {
|
||||
wechatLogin: WechatLogin.SortAttr;
|
||||
} | {
|
||||
wechatPublicTag: WechatPublicTag.SortAttr;
|
||||
} | {
|
||||
|
|
@ -187,6 +196,17 @@ export declare type CreateOperationData = FormCreateData<Omit<OpSchema, "entity"
|
|||
} | {
|
||||
entity: "userWechatPublicTag";
|
||||
entityId: String<64>;
|
||||
} | {
|
||||
entity?: never;
|
||||
entityId?: never;
|
||||
wechatLogin: WechatLogin.CreateSingleOperation;
|
||||
} | {
|
||||
entity: "wechatLogin";
|
||||
entityId: String<64>;
|
||||
wechatLogin: WechatLogin.UpdateOperation;
|
||||
} | {
|
||||
entity: "wechatLogin";
|
||||
entityId: String<64>;
|
||||
} | {
|
||||
entity?: never;
|
||||
entityId?: never;
|
||||
|
|
@ -250,6 +270,10 @@ export declare type UpdateOperationData = FormUpdateData<Omit<OpSchema, "entity"
|
|||
userWechatPublicTag?: UserWechatPublicTag.CreateSingleOperation | UserWechatPublicTag.UpdateOperation | UserWechatPublicTag.RemoveOperation;
|
||||
entityId?: never;
|
||||
entity?: never;
|
||||
} | {
|
||||
wechatLogin?: WechatLogin.CreateSingleOperation | WechatLogin.UpdateOperation | WechatLogin.RemoveOperation;
|
||||
entityId?: never;
|
||||
entity?: never;
|
||||
} | {
|
||||
wechatPublicTag?: WechatPublicTag.CreateSingleOperation | WechatPublicTag.UpdateOperation | WechatPublicTag.RemoveOperation;
|
||||
entityId?: never;
|
||||
|
|
@ -263,7 +287,7 @@ export declare type UpdateOperationData = FormUpdateData<Omit<OpSchema, "entity"
|
|||
entityId?: never;
|
||||
entity?: never;
|
||||
} | {
|
||||
entity?: ("user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string) | null;
|
||||
entity?: ("user" | "userEntityGrant" | "userSystem" | "userWechatPublicTag" | "wechatLogin" | "wechatPublicTag" | "wechatQrCode" | "wechatUser" | string) | null;
|
||||
entityId?: String<64> | null;
|
||||
}) & {
|
||||
[k: string]: any;
|
||||
|
|
@ -277,6 +301,8 @@ export declare type RemoveOperationData = {} & ({
|
|||
userSystem?: UserSystem.UpdateOperation | UserSystem.RemoveOperation;
|
||||
} | {
|
||||
userWechatPublicTag?: UserWechatPublicTag.UpdateOperation | UserWechatPublicTag.RemoveOperation;
|
||||
} | {
|
||||
wechatLogin?: WechatLogin.UpdateOperation | WechatLogin.RemoveOperation;
|
||||
} | {
|
||||
wechatPublicTag?: WechatPublicTag.UpdateOperation | WechatPublicTag.RemoveOperation;
|
||||
} | {
|
||||
|
|
@ -293,6 +319,7 @@ export declare type UserIdSubQuery = Selection<UserIdProjection>;
|
|||
export declare type UserEntityGrantIdSubQuery = Selection<UserEntityGrantIdProjection>;
|
||||
export declare type UserSystemIdSubQuery = Selection<UserSystemIdProjection>;
|
||||
export declare type UserWechatPublicTagIdSubQuery = Selection<UserWechatPublicTagIdProjection>;
|
||||
export declare type WechatLoginIdSubQuery = Selection<WechatLoginIdProjection>;
|
||||
export declare type WechatPublicTagIdSubQuery = Selection<WechatPublicTagIdProjection>;
|
||||
export declare type WechatQrCodeIdSubQuery = Selection<WechatQrCodeIdProjection>;
|
||||
export declare type WechatUserIdSubQuery = Selection<WechatUserIdProjection>;
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ exports.desc = {
|
|||
params: {
|
||||
length: 32
|
||||
},
|
||||
ref: ["user", "userEntityGrant", "userSystem", "userWechatPublicTag", "wechatPublicTag", "wechatQrCode", "wechatUser"]
|
||||
ref: ["user", "userEntityGrant", "userSystem", "userWechatPublicTag", "wechatLogin", "wechatPublicTag", "wechatQrCode", "wechatUser"]
|
||||
},
|
||||
entityId: {
|
||||
notNull: true,
|
||||
|
|
|
|||
|
|
@ -37,9 +37,10 @@ var Storage_33 = require("./System/Storage");
|
|||
var Storage_34 = require("./Token/Storage");
|
||||
var Storage_35 = require("./UserSystem/Storage");
|
||||
var Storage_36 = require("./UserWechatPublicTag/Storage");
|
||||
var Storage_37 = require("./WechatPublicTag/Storage");
|
||||
var Storage_38 = require("./WechatQrCode/Storage");
|
||||
var Storage_39 = require("./WechatUser/Storage");
|
||||
var Storage_37 = require("./WechatLogin/Storage");
|
||||
var Storage_38 = require("./WechatPublicTag/Storage");
|
||||
var Storage_39 = require("./WechatQrCode/Storage");
|
||||
var Storage_40 = require("./WechatUser/Storage");
|
||||
exports.storageSchema = {
|
||||
actionAuth: Storage_1.desc,
|
||||
modi: Storage_2.desc,
|
||||
|
|
@ -77,7 +78,8 @@ exports.storageSchema = {
|
|||
token: Storage_34.desc,
|
||||
userSystem: Storage_35.desc,
|
||||
userWechatPublicTag: Storage_36.desc,
|
||||
wechatPublicTag: Storage_37.desc,
|
||||
wechatQrCode: Storage_38.desc,
|
||||
wechatUser: Storage_39.desc
|
||||
wechatLogin: Storage_37.desc,
|
||||
wechatPublicTag: Storage_38.desc,
|
||||
wechatQrCode: Storage_39.desc,
|
||||
wechatUser: Storage_40.desc
|
||||
};
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@ import * as Token from "../Token/Schema";
|
|||
import * as UserEntityGrant from "../UserEntityGrant/Schema";
|
||||
import * as UserSystem from "../UserSystem/Schema";
|
||||
import * as UserWechatPublicTag from "../UserWechatPublicTag/Schema";
|
||||
import * as WechatLogin from "../WechatLogin/Schema";
|
||||
import * as WechatUser from "../WechatUser/Schema";
|
||||
import * as ModiEntity from "../ModiEntity/Schema";
|
||||
import * as OperEntity from "../OperEntity/Schema";
|
||||
|
|
@ -73,6 +74,8 @@ export declare type Schema = EntityShape & {
|
|||
userSystem$user$$aggr?: AggregationResult<UserSystem.Schema>;
|
||||
userWechatPublicTag$user?: Array<UserWechatPublicTag.Schema>;
|
||||
userWechatPublicTag$user$$aggr?: AggregationResult<UserWechatPublicTag.Schema>;
|
||||
wechatLogin$user?: Array<WechatLogin.Schema>;
|
||||
wechatLogin$user$$aggr?: AggregationResult<WechatLogin.Schema>;
|
||||
wechatUser$user?: Array<WechatUser.Schema>;
|
||||
wechatUser$user$$aggr?: AggregationResult<WechatUser.Schema>;
|
||||
modiEntity$entity?: Array<ModiEntity.Schema>;
|
||||
|
|
@ -202,6 +205,12 @@ export declare type Projection = {
|
|||
userWechatPublicTag$user$$aggr?: UserWechatPublicTag.Aggregation & {
|
||||
$entity: "userWechatPublicTag";
|
||||
};
|
||||
wechatLogin$user?: WechatLogin.Selection & {
|
||||
$entity: "wechatLogin";
|
||||
};
|
||||
wechatLogin$user$$aggr?: WechatLogin.Aggregation & {
|
||||
$entity: "wechatLogin";
|
||||
};
|
||||
wechatUser$user?: WechatUser.Selection & {
|
||||
$entity: "wechatUser";
|
||||
};
|
||||
|
|
@ -302,6 +311,7 @@ export declare type CreateOperationData = FormCreateData<Omit<OpSchema, "refId">
|
|||
userEntityGrant$grantee?: OakOperation<UserEntityGrant.UpdateOperation["action"], Omit<UserEntityGrant.UpdateOperationData, "grantee" | "granteeId">, UserEntityGrant.Filter> | OakOperation<"create", Omit<UserEntityGrant.CreateOperationData, "grantee" | "granteeId">[]> | Array<OakOperation<"create", Omit<UserEntityGrant.CreateOperationData, "grantee" | "granteeId">> | OakOperation<UserEntityGrant.UpdateOperation["action"], Omit<UserEntityGrant.UpdateOperationData, "grantee" | "granteeId">, UserEntityGrant.Filter>>;
|
||||
userSystem$user?: OakOperation<UserSystem.UpdateOperation["action"], Omit<UserSystem.UpdateOperationData, "user" | "userId">, UserSystem.Filter> | OakOperation<"create", Omit<UserSystem.CreateOperationData, "user" | "userId">[]> | Array<OakOperation<"create", Omit<UserSystem.CreateOperationData, "user" | "userId">> | OakOperation<UserSystem.UpdateOperation["action"], Omit<UserSystem.UpdateOperationData, "user" | "userId">, UserSystem.Filter>>;
|
||||
userWechatPublicTag$user?: OakOperation<UserWechatPublicTag.UpdateOperation["action"], Omit<UserWechatPublicTag.UpdateOperationData, "user" | "userId">, UserWechatPublicTag.Filter> | OakOperation<"create", Omit<UserWechatPublicTag.CreateOperationData, "user" | "userId">[]> | Array<OakOperation<"create", Omit<UserWechatPublicTag.CreateOperationData, "user" | "userId">> | OakOperation<UserWechatPublicTag.UpdateOperation["action"], Omit<UserWechatPublicTag.UpdateOperationData, "user" | "userId">, UserWechatPublicTag.Filter>>;
|
||||
wechatLogin$user?: OakOperation<WechatLogin.UpdateOperation["action"], Omit<WechatLogin.UpdateOperationData, "user" | "userId">, WechatLogin.Filter> | OakOperation<"create", Omit<WechatLogin.CreateOperationData, "user" | "userId">[]> | Array<OakOperation<"create", Omit<WechatLogin.CreateOperationData, "user" | "userId">> | OakOperation<WechatLogin.UpdateOperation["action"], Omit<WechatLogin.UpdateOperationData, "user" | "userId">, WechatLogin.Filter>>;
|
||||
wechatUser$user?: OakOperation<WechatUser.UpdateOperation["action"], Omit<WechatUser.UpdateOperationData, "user" | "userId">, WechatUser.Filter> | OakOperation<"create", Omit<WechatUser.CreateOperationData, "user" | "userId">[]> | Array<OakOperation<"create", Omit<WechatUser.CreateOperationData, "user" | "userId">> | OakOperation<WechatUser.UpdateOperation["action"], Omit<WechatUser.UpdateOperationData, "user" | "userId">, WechatUser.Filter>>;
|
||||
modiEntity$entity?: OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">>>;
|
||||
operEntity$entity?: OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">>>;
|
||||
|
|
@ -338,6 +348,7 @@ export declare type UpdateOperationData = FormUpdateData<Omit<OpSchema, "refId">
|
|||
userEntityGrant$grantee?: UserEntityGrant.UpdateOperation | UserEntityGrant.RemoveOperation | OakOperation<"create", Omit<UserEntityGrant.CreateOperationData, "grantee" | "granteeId">[]> | Array<OakOperation<"create", Omit<UserEntityGrant.CreateOperationData, "grantee" | "granteeId">> | UserEntityGrant.UpdateOperation | UserEntityGrant.RemoveOperation>;
|
||||
userSystem$user?: UserSystem.UpdateOperation | UserSystem.RemoveOperation | OakOperation<"create", Omit<UserSystem.CreateOperationData, "user" | "userId">[]> | Array<OakOperation<"create", Omit<UserSystem.CreateOperationData, "user" | "userId">> | UserSystem.UpdateOperation | UserSystem.RemoveOperation>;
|
||||
userWechatPublicTag$user?: UserWechatPublicTag.UpdateOperation | UserWechatPublicTag.RemoveOperation | OakOperation<"create", Omit<UserWechatPublicTag.CreateOperationData, "user" | "userId">[]> | Array<OakOperation<"create", Omit<UserWechatPublicTag.CreateOperationData, "user" | "userId">> | UserWechatPublicTag.UpdateOperation | UserWechatPublicTag.RemoveOperation>;
|
||||
wechatLogin$user?: WechatLogin.UpdateOperation | WechatLogin.RemoveOperation | OakOperation<"create", Omit<WechatLogin.CreateOperationData, "user" | "userId">[]> | Array<OakOperation<"create", Omit<WechatLogin.CreateOperationData, "user" | "userId">> | WechatLogin.UpdateOperation | WechatLogin.RemoveOperation>;
|
||||
wechatUser$user?: WechatUser.UpdateOperation | WechatUser.RemoveOperation | OakOperation<"create", Omit<WechatUser.CreateOperationData, "user" | "userId">[]> | Array<OakOperation<"create", Omit<WechatUser.CreateOperationData, "user" | "userId">> | WechatUser.UpdateOperation | WechatUser.RemoveOperation>;
|
||||
modiEntity$entity?: OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">>>;
|
||||
operEntity$entity?: OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">>>;
|
||||
|
|
|
|||
|
|
@ -0,0 +1,5 @@
|
|||
import { GenericAction } from "oak-domain/lib/actions/action";
|
||||
export declare type ParticularAction = 'success';
|
||||
export declare type Action = GenericAction | ParticularAction | string;
|
||||
export declare const actions: string[];
|
||||
export declare const ActionDefDict: {};
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.ActionDefDict = exports.actions = void 0;
|
||||
exports.actions = ["count", "stat", "download", "select", "aggregate", "create", "remove", "update", "success"];
|
||||
exports.ActionDefDict = {};
|
||||
|
|
@ -0,0 +1,186 @@
|
|||
import { String, Boolean, Text, Datetime, ForeignKey } from "oak-domain/lib/types/DataType";
|
||||
import { Q_DateValue, Q_BooleanValue, Q_StringValue, Q_EnumValue, NodeId, MakeFilter, ExprOp, ExpressionKey } from "oak-domain/lib/types/Demand";
|
||||
import { OneOf } from "oak-domain/lib/types/Polyfill";
|
||||
import * as SubQuery from "../_SubQuery";
|
||||
import { FormCreateData, FormUpdateData, DeduceAggregation, Operation as OakOperation, Selection as OakSelection, MakeAction as OakMakeAction, EntityShape, AggregationResult } from "oak-domain/lib/types/Entity";
|
||||
import { Action, ParticularAction } from "./Action";
|
||||
import { QrCodeType } from "../../types/Config";
|
||||
import * as User from "../User/Schema";
|
||||
import * as ModiEntity from "../ModiEntity/Schema";
|
||||
import * as OperEntity from "../OperEntity/Schema";
|
||||
import * as WechatQrCode from "../WechatQrCode/Schema";
|
||||
export declare type OpSchema = EntityShape & {
|
||||
userId?: ForeignKey<"user"> | null;
|
||||
type: 'bind' | 'login';
|
||||
successed: Boolean;
|
||||
remark?: Text | null;
|
||||
qrCodeType: QrCodeType;
|
||||
expiresAt?: Datetime | null;
|
||||
expired?: Boolean | null;
|
||||
};
|
||||
export declare type OpAttr = keyof OpSchema;
|
||||
export declare type Schema = EntityShape & {
|
||||
userId?: ForeignKey<"user"> | null;
|
||||
type: 'bind' | 'login';
|
||||
successed: Boolean;
|
||||
remark?: Text | null;
|
||||
qrCodeType: QrCodeType;
|
||||
expiresAt?: Datetime | null;
|
||||
expired?: Boolean | null;
|
||||
user?: User.Schema | null;
|
||||
modiEntity$entity?: Array<ModiEntity.Schema>;
|
||||
modiEntity$entity$$aggr?: AggregationResult<ModiEntity.Schema>;
|
||||
operEntity$entity?: Array<OperEntity.Schema>;
|
||||
operEntity$entity$$aggr?: AggregationResult<OperEntity.Schema>;
|
||||
wechatQrCode$entity?: Array<WechatQrCode.Schema>;
|
||||
wechatQrCode$entity$$aggr?: AggregationResult<WechatQrCode.Schema>;
|
||||
} & {
|
||||
[A in ExpressionKey]?: any;
|
||||
};
|
||||
declare type AttrFilter = {
|
||||
id: Q_StringValue | SubQuery.WechatLoginIdSubQuery;
|
||||
$$createAt$$: Q_DateValue;
|
||||
$$seq$$: Q_StringValue;
|
||||
$$updateAt$$: Q_DateValue;
|
||||
userId: Q_StringValue | SubQuery.UserIdSubQuery;
|
||||
user: User.Filter;
|
||||
type: Q_EnumValue<'bind' | 'login'>;
|
||||
successed: Q_BooleanValue;
|
||||
remark: Q_StringValue;
|
||||
qrCodeType: Q_EnumValue<QrCodeType>;
|
||||
expiresAt: Q_DateValue;
|
||||
expired: Q_BooleanValue;
|
||||
};
|
||||
export declare type Filter = MakeFilter<AttrFilter & ExprOp<OpAttr | string>>;
|
||||
export declare type Projection = {
|
||||
"#id"?: NodeId;
|
||||
[k: string]: any;
|
||||
id?: number;
|
||||
$$createAt$$?: number;
|
||||
$$updateAt$$?: number;
|
||||
$$seq$$?: number;
|
||||
userId?: number;
|
||||
user?: User.Projection;
|
||||
type?: number;
|
||||
successed?: number;
|
||||
remark?: number;
|
||||
qrCodeType?: number;
|
||||
expiresAt?: number;
|
||||
expired?: number;
|
||||
modiEntity$entity?: ModiEntity.Selection & {
|
||||
$entity: "modiEntity";
|
||||
};
|
||||
modiEntity$entity$$aggr?: ModiEntity.Aggregation & {
|
||||
$entity: "modiEntity";
|
||||
};
|
||||
operEntity$entity?: OperEntity.Selection & {
|
||||
$entity: "operEntity";
|
||||
};
|
||||
operEntity$entity$$aggr?: OperEntity.Aggregation & {
|
||||
$entity: "operEntity";
|
||||
};
|
||||
wechatQrCode$entity?: WechatQrCode.Selection & {
|
||||
$entity: "wechatQrCode";
|
||||
};
|
||||
wechatQrCode$entity$$aggr?: WechatQrCode.Aggregation & {
|
||||
$entity: "wechatQrCode";
|
||||
};
|
||||
} & Partial<ExprOp<OpAttr | string>>;
|
||||
declare type WechatLoginIdProjection = OneOf<{
|
||||
id: number;
|
||||
}>;
|
||||
declare type UserIdProjection = OneOf<{
|
||||
userId: number;
|
||||
}>;
|
||||
export declare type SortAttr = {
|
||||
id: number;
|
||||
} | {
|
||||
$$createAt$$: number;
|
||||
} | {
|
||||
$$seq$$: number;
|
||||
} | {
|
||||
$$updateAt$$: number;
|
||||
} | {
|
||||
userId: number;
|
||||
} | {
|
||||
user: User.SortAttr;
|
||||
} | {
|
||||
type: number;
|
||||
} | {
|
||||
successed: number;
|
||||
} | {
|
||||
remark: number;
|
||||
} | {
|
||||
qrCodeType: number;
|
||||
} | {
|
||||
expiresAt: number;
|
||||
} | {
|
||||
expired: number;
|
||||
} | {
|
||||
[k: string]: any;
|
||||
} | OneOf<ExprOp<OpAttr | string>>;
|
||||
export declare type SortNode = {
|
||||
$attr: SortAttr;
|
||||
$direction?: "asc" | "desc";
|
||||
};
|
||||
export declare type Sorter = SortNode[];
|
||||
export declare type SelectOperation<P extends Object = Projection> = OakSelection<"select", P, Filter, Sorter>;
|
||||
export declare type Selection<P extends Object = Projection> = Omit<SelectOperation<P>, "action">;
|
||||
export declare type Aggregation = DeduceAggregation<Projection, Filter, Sorter>;
|
||||
export declare type CreateOperationData = FormCreateData<Omit<OpSchema, "userId">> & (({
|
||||
userId?: never;
|
||||
user?: User.CreateSingleOperation;
|
||||
} | {
|
||||
userId: String<64>;
|
||||
user?: User.UpdateOperation;
|
||||
} | {
|
||||
userId?: String<64>;
|
||||
})) & {
|
||||
modiEntity$entity?: OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">>>;
|
||||
operEntity$entity?: OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">>>;
|
||||
wechatQrCode$entity?: OakOperation<WechatQrCode.UpdateOperation["action"], Omit<WechatQrCode.UpdateOperationData, "entity" | "entityId">, WechatQrCode.Filter> | OakOperation<"create", Omit<WechatQrCode.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<WechatQrCode.CreateOperationData, "entity" | "entityId">> | OakOperation<WechatQrCode.UpdateOperation["action"], Omit<WechatQrCode.UpdateOperationData, "entity" | "entityId">, WechatQrCode.Filter>>;
|
||||
};
|
||||
export declare type CreateSingleOperation = OakOperation<"create", CreateOperationData>;
|
||||
export declare type CreateMultipleOperation = OakOperation<"create", Array<CreateOperationData>>;
|
||||
export declare type CreateOperation = CreateSingleOperation | CreateMultipleOperation;
|
||||
export declare type UpdateOperationData = FormUpdateData<Omit<OpSchema, "userId">> & (({
|
||||
user: User.CreateSingleOperation;
|
||||
userId?: never;
|
||||
} | {
|
||||
user: User.UpdateOperation;
|
||||
userId?: never;
|
||||
} | {
|
||||
user: User.RemoveOperation;
|
||||
userId?: never;
|
||||
} | {
|
||||
user?: never;
|
||||
userId?: String<64> | null;
|
||||
})) & {
|
||||
[k: string]: any;
|
||||
modiEntity$entity?: OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">>>;
|
||||
operEntity$entity?: OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">>>;
|
||||
wechatQrCode$entity?: WechatQrCode.UpdateOperation | WechatQrCode.RemoveOperation | OakOperation<"create", Omit<WechatQrCode.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<WechatQrCode.CreateOperationData, "entity" | "entityId">> | WechatQrCode.UpdateOperation | WechatQrCode.RemoveOperation>;
|
||||
};
|
||||
export declare type UpdateOperation = OakOperation<"update" | ParticularAction | string, UpdateOperationData, Filter, Sorter>;
|
||||
export declare type RemoveOperationData = {} & (({
|
||||
user?: User.UpdateOperation | User.RemoveOperation;
|
||||
}));
|
||||
export declare type RemoveOperation = OakOperation<"remove", RemoveOperationData, Filter, Sorter>;
|
||||
export declare type Operation = CreateOperation | UpdateOperation | RemoveOperation;
|
||||
export declare type UserIdSubQuery = Selection<UserIdProjection>;
|
||||
export declare type WechatLoginIdSubQuery = Selection<WechatLoginIdProjection>;
|
||||
export declare type EntityDef = {
|
||||
Schema: Schema;
|
||||
OpSchema: OpSchema;
|
||||
Action: OakMakeAction<Action> | string;
|
||||
Selection: Selection;
|
||||
Aggregation: Aggregation;
|
||||
Operation: Operation;
|
||||
Create: CreateOperation;
|
||||
Update: UpdateOperation;
|
||||
Remove: RemoveOperation;
|
||||
CreateSingle: CreateSingleOperation;
|
||||
CreateMulti: CreateMultipleOperation;
|
||||
ParticularAction: ParticularAction;
|
||||
};
|
||||
export {};
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
import { StorageDesc } from "oak-domain/lib/types/Storage";
|
||||
import { OpSchema } from "./Schema";
|
||||
export declare const desc: StorageDesc<OpSchema>;
|
||||
|
|
@ -0,0 +1,50 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.desc = void 0;
|
||||
var Action_1 = require("./Action");
|
||||
exports.desc = {
|
||||
attributes: {
|
||||
userId: {
|
||||
type: "ref",
|
||||
ref: "user"
|
||||
},
|
||||
type: {
|
||||
notNull: true,
|
||||
type: "enum",
|
||||
enumeration: ["bind", "login"]
|
||||
},
|
||||
successed: {
|
||||
notNull: true,
|
||||
type: "boolean"
|
||||
},
|
||||
remark: {
|
||||
type: "text"
|
||||
},
|
||||
qrCodeType: {
|
||||
notNull: true,
|
||||
type: "enum",
|
||||
enumeration: ["wechatMpDomainUrl", "wechatMpWxaCode", "wechatPublic", "wechatPublicForMp", "webForWechatPublic"]
|
||||
},
|
||||
expiresAt: {
|
||||
type: "datetime"
|
||||
},
|
||||
expired: {
|
||||
type: "boolean"
|
||||
}
|
||||
},
|
||||
actionType: "crud",
|
||||
actions: Action_1.actions,
|
||||
indexes: [
|
||||
{
|
||||
name: 'index_uuid',
|
||||
attributes: [
|
||||
{
|
||||
name: 'expired'
|
||||
},
|
||||
{
|
||||
name: 'expiresAt'
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
};
|
||||
|
|
@ -0,0 +1 @@
|
|||
{ "name": "绑定微信号", "attr": { "user": "用户", "type": "类型", "successed": "是否成功", "remark": "备注", "codes": "微信码", "expired": "是否过期", "expiresAt": "过期时间", "qrCodeType": "二维码类型" }, "action": { "success": "成功" }, "v": { "type": { "bind": "绑定", "login": "登录" }, "qrCodeType": { "webForWechatPublic": "网站引流到公众号", "wechatMpDomainUrl": "小程序url码", "wechatMpWxaCode": "小程序码", "wechatPublic": "公众号关注码", "wechatPublicForMp": "公众号跳转小程序码" } } }
|
||||
|
|
@ -8,6 +8,7 @@ import { QrCodeType } from "../../types/Config";
|
|||
import * as Application from "../Application/Schema";
|
||||
import * as User from "../User/Schema";
|
||||
import * as UserEntityGrant from "../UserEntityGrant/Schema";
|
||||
import * as WechatLogin from "../WechatLogin/Schema";
|
||||
import * as ModiEntity from "../ModiEntity/Schema";
|
||||
import * as OperEntity from "../OperEntity/Schema";
|
||||
export declare type WechatQrCodeProps = {
|
||||
|
|
@ -17,7 +18,7 @@ export declare type WechatQrCodeProps = {
|
|||
isTabBar?: boolean;
|
||||
};
|
||||
export declare type OpSchema = EntityShape & {
|
||||
entity: "user" | "userEntityGrant" | string;
|
||||
entity: "user" | "userEntityGrant" | "wechatLogin" | string;
|
||||
entityId: String<64>;
|
||||
type: QrCodeType;
|
||||
allowShare: Boolean;
|
||||
|
|
@ -34,7 +35,7 @@ export declare type OpSchema = EntityShape & {
|
|||
};
|
||||
export declare type OpAttr = keyof OpSchema;
|
||||
export declare type Schema = EntityShape & {
|
||||
entity: "user" | "userEntityGrant" | string;
|
||||
entity: "user" | "userEntityGrant" | "wechatLogin" | string;
|
||||
entityId: String<64>;
|
||||
type: QrCodeType;
|
||||
allowShare: Boolean;
|
||||
|
|
@ -51,6 +52,7 @@ export declare type Schema = EntityShape & {
|
|||
application: Application.Schema;
|
||||
user?: User.Schema;
|
||||
userEntityGrant?: UserEntityGrant.Schema;
|
||||
wechatLogin?: WechatLogin.Schema;
|
||||
modiEntity$entity?: Array<ModiEntity.Schema>;
|
||||
modiEntity$entity$$aggr?: AggregationResult<ModiEntity.Schema>;
|
||||
operEntity$entity?: Array<OperEntity.Schema>;
|
||||
|
|
@ -80,8 +82,9 @@ declare type AttrFilter<E> = {
|
|||
props: Q_EnumValue<WechatQrCodeProps>;
|
||||
user: User.Filter;
|
||||
userEntityGrant: UserEntityGrant.Filter;
|
||||
wechatLogin: WechatLogin.Filter;
|
||||
};
|
||||
export declare type Filter<E = Q_EnumValue<"user" | "userEntityGrant" | string>> = MakeFilter<AttrFilter<E> & ExprOp<OpAttr | string>>;
|
||||
export declare type Filter<E = Q_EnumValue<"user" | "userEntityGrant" | "wechatLogin" | string>> = MakeFilter<AttrFilter<E> & ExprOp<OpAttr | string>>;
|
||||
export declare type Projection = {
|
||||
"#id"?: NodeId;
|
||||
[k: string]: any;
|
||||
|
|
@ -106,6 +109,7 @@ export declare type Projection = {
|
|||
props?: number;
|
||||
user?: User.Projection;
|
||||
userEntityGrant?: UserEntityGrant.Projection;
|
||||
wechatLogin?: WechatLogin.Projection;
|
||||
modiEntity$entity?: ModiEntity.Selection & {
|
||||
$entity: "modiEntity";
|
||||
};
|
||||
|
|
@ -131,6 +135,9 @@ declare type UserIdProjection = OneOf<{
|
|||
declare type UserEntityGrantIdProjection = OneOf<{
|
||||
entityId: number;
|
||||
}>;
|
||||
declare type WechatLoginIdProjection = OneOf<{
|
||||
entityId: number;
|
||||
}>;
|
||||
export declare type SortAttr = {
|
||||
id: number;
|
||||
} | {
|
||||
|
|
@ -173,6 +180,8 @@ export declare type SortAttr = {
|
|||
user: User.SortAttr;
|
||||
} | {
|
||||
userEntityGrant: UserEntityGrant.SortAttr;
|
||||
} | {
|
||||
wechatLogin: WechatLogin.SortAttr;
|
||||
} | {
|
||||
[k: string]: any;
|
||||
} | OneOf<ExprOp<OpAttr | string>>;
|
||||
|
|
@ -214,6 +223,17 @@ export declare type CreateOperationData = FormCreateData<Omit<OpSchema, "entity"
|
|||
} | {
|
||||
entity: "userEntityGrant";
|
||||
entityId: String<64>;
|
||||
} | {
|
||||
entity?: never;
|
||||
entityId?: never;
|
||||
wechatLogin: WechatLogin.CreateSingleOperation;
|
||||
} | {
|
||||
entity: "wechatLogin";
|
||||
entityId: String<64>;
|
||||
wechatLogin: WechatLogin.UpdateOperation;
|
||||
} | {
|
||||
entity: "wechatLogin";
|
||||
entityId: String<64>;
|
||||
} | {
|
||||
entity?: string;
|
||||
entityId?: string;
|
||||
|
|
@ -246,7 +266,11 @@ export declare type UpdateOperationData = FormUpdateData<Omit<OpSchema, "entity"
|
|||
entityId?: never;
|
||||
entity?: never;
|
||||
} | {
|
||||
entity?: ("user" | "userEntityGrant" | string) | null;
|
||||
wechatLogin?: WechatLogin.CreateSingleOperation | WechatLogin.UpdateOperation | WechatLogin.RemoveOperation;
|
||||
entityId?: never;
|
||||
entity?: never;
|
||||
} | {
|
||||
entity?: ("user" | "userEntityGrant" | "wechatLogin" | string) | null;
|
||||
entityId?: String<64> | null;
|
||||
}) & {
|
||||
[k: string]: any;
|
||||
|
|
@ -260,6 +284,8 @@ export declare type RemoveOperationData = {} & (({
|
|||
user?: User.UpdateOperation | User.RemoveOperation;
|
||||
} | {
|
||||
userEntityGrant?: UserEntityGrant.UpdateOperation | UserEntityGrant.RemoveOperation;
|
||||
} | {
|
||||
wechatLogin?: WechatLogin.UpdateOperation | WechatLogin.RemoveOperation;
|
||||
} | {
|
||||
[k: string]: any;
|
||||
});
|
||||
|
|
@ -268,6 +294,7 @@ export declare type Operation = CreateOperation | UpdateOperation | RemoveOperat
|
|||
export declare type ApplicationIdSubQuery = Selection<ApplicationIdProjection>;
|
||||
export declare type UserIdSubQuery = Selection<UserIdProjection>;
|
||||
export declare type UserEntityGrantIdSubQuery = Selection<UserEntityGrantIdProjection>;
|
||||
export declare type WechatLoginIdSubQuery = Selection<WechatLoginIdProjection>;
|
||||
export declare type WechatQrCodeIdSubQuery = Selection<WechatQrCodeIdProjection>;
|
||||
export declare type EntityDef = {
|
||||
Schema: Schema;
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ exports.desc = {
|
|||
params: {
|
||||
length: 32
|
||||
},
|
||||
ref: ["user", "userEntityGrant"]
|
||||
ref: ["user", "userEntityGrant", "wechatLogin"]
|
||||
},
|
||||
entityId: {
|
||||
notNull: true,
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@ import * as System from "./System/Schema";
|
|||
import * as Token from "./Token/Schema";
|
||||
import * as UserSystem from "./UserSystem/Schema";
|
||||
import * as UserWechatPublicTag from "./UserWechatPublicTag/Schema";
|
||||
import * as WechatLogin from "./WechatLogin/Schema";
|
||||
import * as WechatPublicTag from "./WechatPublicTag/Schema";
|
||||
import * as WechatQrCode from "./WechatQrCode/Schema";
|
||||
import * as WechatUser from "./WechatUser/Schema";
|
||||
|
|
@ -105,6 +106,8 @@ export declare type UserIdSubQuery = {
|
|||
entity: "userSystem";
|
||||
}) | (UserWechatPublicTag.UserIdSubQuery & {
|
||||
entity: "userWechatPublicTag";
|
||||
}) | (WechatLogin.UserIdSubQuery & {
|
||||
entity: "wechatLogin";
|
||||
}) | (WechatUser.UserIdSubQuery & {
|
||||
entity: "wechatUser";
|
||||
}) | (User.UserIdSubQuery & {
|
||||
|
|
@ -291,6 +294,11 @@ export declare type UserWechatPublicTagIdSubQuery = {
|
|||
entity: "userWechatPublicTag";
|
||||
}) | any;
|
||||
};
|
||||
export declare type WechatLoginIdSubQuery = {
|
||||
[K in "$in" | "$nin"]?: (WechatLogin.WechatLoginIdSubQuery & {
|
||||
entity: "wechatLogin";
|
||||
}) | any;
|
||||
};
|
||||
export declare type WechatPublicTagIdSubQuery = {
|
||||
[K in "$in" | "$nin"]?: (UserWechatPublicTag.WechatPublicTagIdSubQuery & {
|
||||
entity: "userWechatPublicTag";
|
||||
|
|
|
|||
|
|
@ -23,5 +23,11 @@
|
|||
"shrink": "收起",
|
||||
"$$createAt$$": "创建时间",
|
||||
"$$updateAt$$": "更新时间",
|
||||
"$$deleteAt$$": "删除时间"
|
||||
"$$deleteAt$$": "删除时间",
|
||||
"$$seq$$": "序号",
|
||||
"message": "消息",
|
||||
"more": "更多",
|
||||
"view": "查看",
|
||||
"scan": "扫一扫",
|
||||
"bind": "绑定"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'address', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'address', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { AppType, WebConfig, WechatPublicConfig, WechatMpConfig } from '../../../../general-app-domain/Application/Schema';
|
||||
import { EntityDict } from '../../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebConfig, WechatPublicConfig, WechatMpConfig } from '../../../general-app-domain/Application/Schema';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps, RowWithActions } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'application', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'application', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from './../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'article', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'article', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'article', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import '@wangeditor/editor/dist/css/style.css';
|
||||
import { EntityDict } from './../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'domain', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps, RowWithActions } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'domain', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'domain', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'token', true, {}, {}>): JSX.Element;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../general-app-domain';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'token', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'message', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'message', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'message', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'message', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps, RowWithActions } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'message', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'token', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'token', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'mobile', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'mobile', true, {
|
||||
|
|
|
|||
|
|
@ -1,2 +1 @@
|
|||
/// <reference types="react" />
|
||||
export default function Render(): JSX.Element;
|
||||
|
|
|
|||
|
|
@ -1,2 +1 @@
|
|||
/// <reference types="react" />
|
||||
export default function Render(): JSX.Element;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'area', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { Config } from '../../../../types/Config';
|
||||
import { EntityDict } from '../../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { Config } from '../../../types/Config';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps, RowWithActions } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'platform', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'platform', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
import { EntityDict } from '../../general-app-domain';
|
||||
export default function render(props: WebComponentProps<EntityDict, 'user', false, {
|
||||
|
|
|
|||
|
|
@ -1,2 +1 @@
|
|||
/// <reference types="react" />
|
||||
export default function Render(): JSX.Element;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WechatPublicConfig } from '../../../../general-app-domain/Application/Schema';
|
||||
import { EntityDict } from '../../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { WechatPublicConfig } from '../../../general-app-domain/Application/Schema';
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'subscription', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'subscription', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../../general-app-domain';
|
||||
import { Config } from '../../../../types/Config';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { Config } from '../../../types/Config';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps, RowWithActions } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'system', true, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'system', false, {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="react" />
|
||||
import { EntityDict } from '../../../general-app-domain';
|
||||
import { WebComponentProps } from 'oak-frontend-base';
|
||||
export default function Render(props: WebComponentProps<EntityDict, 'token', true, {
|
||||
|
|
|
|||
|
|
@ -47,6 +47,21 @@ exports.default = OakComponent({
|
|||
indexFrom: 0,
|
||||
count: 1,
|
||||
},
|
||||
wechatUser$user: {
|
||||
$entity: 'wechatUser',
|
||||
data: {
|
||||
id: 1,
|
||||
openId: 1,
|
||||
unionId: 1,
|
||||
userId: 1,
|
||||
origin: 1,
|
||||
user: {
|
||||
id: 1,
|
||||
userState: 1,
|
||||
refId: 1,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
isList: false,
|
||||
formData: function (_a) {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"navigationBarTitleText": "修改个人信息",
|
||||
"navigationBarTitleText": "个人设置",
|
||||
"oakDisablePulldownRefresh": true,
|
||||
"usingComponents": {
|
||||
"l-button": "@oak-frontend-base/miniprogram_npm/lin-ui/button/index",
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue