- Receivable 账户意味着别人应该给你钱,比如购物退货之后等待退款、借给别人钱等等。例如
2023-10-31 * "淘宝" “[退货] 表带"
Liabilities:CreditCard:CMB -83.00 CNY
Assets:Receivables
// 这个测试里我们用 mobx 来建立一个应用程序 | |
// 这个程序中,当 dialog 的 show 状态变为 true 时,我们开启一个定时器 | |
// 这个定时器每秒给一个全局自增 counter+1 | |
// 当 dialog 的状态变为 false 时,我们重置这个全局定时器 | |
// 在这个例子中,所有的清理工作都应该用 transaction / abortSignal 来完成,而不是调用方主动重置 | |
import { afterEach, beforeEach, expect, test, vi } from "vitest"; | |
import { makeAutoObservable, reaction } from "mobx" | |
import { interval } from "signal-timers"; | |
import { transaction } from "signal-transaction"; |
// 业务方法定义 | |
const getA = function(cb) { | |
cb(a); | |
} | |
const getB = function(a, cb) { | |
cb(b); | |
} | |
const getC = function(a, b, cb) { |
import { ChangeDetectorRef, OnDestroy, Pipe, PipeTransform, ɵisObservable, ɵisPromise } from '@angular/core'; | |
import { Observable } from 'rxjs/Observable'; | |
import { Observer } from 'rxjs/Observer'; | |
import 'rxjs/add/operator/map'; | |
import 'rxjs/add/operator/catch'; | |
interface SubscriptionStrategy { | |
createSubscription(async: any, updateLatestValue: any): any; | |
dispose(subscription: any): void; |
var ignoreRegexp = ['/^\\/?(?=/|$)/i', '/^(.*)\\/?$/i', '/^\\/ss\\/?(?=/|$)/i']; | |
var routerProto = express.Router().__proto__; | |
var regexpList = app._router.stack.reduce(function findProto(memo, curr) { | |
if (ignoreRegexp.indexOf(curr.regexp.toString()) === -1) { | |
memo.push(curr.regexp); | |
} | |
if (curr.handle.__proto__ === routerProto && curr.handle.stack) { | |
memo = curr.handle.stack.reduce(findProto, memo); | |
} |
function qs(arr) { | |
if (!arr || !arr.length) { | |
return []; | |
} | |
var split = arr.pop(); | |
return qs(arr.filter(function (item) { return item <= split; })) | |
.concat([split]) | |
.concat(qs(arr.filter(function (item) { return item > split; }))); | |
} |
(function (window) { | |
// prng4.js - uses Arcfour as a PRNG | |
function Arcfour() { | |
this.i = 0; | |
this.j = 0; | |
this.S = new Array(); | |
} | |
// Initialize arcfour context from key, an array of ints, each from [0..255] |
# Web App 实践经验 |
var files = fileEl.files; | |
var formData = new FormData(); | |
_.toArray(files).forEach(function (file) { | |
formData.append('images[]', file); | |
}); | |
var xhr = new XMLHttpRequest(); | |
xhr.open('post', '/uni/api/' + $routeParams.course + '/images', true); |