Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
}
clonedThis.mquery.sort(params);
return _tunnelQueryCache(clonedThis);
};
_proto.limit = function limit(amount) {
if (this.op === 'findOne') throw newRxError('QU6');else {
var clonedThis = this._clone();
clonedThis.mquery.limit(amount);
return _tunnelQueryCache(clonedThis);
}
};
_createClass(RxQueryBase, [{
key: "$",
get: function get() {
var _this2 = this;
if (!this._$) {
/**
* We use _resultsDocs$ to emit new results
* This also ensure that there is a reemit on subscribe
*/
var results$ = this._resultsDocs$.pipe(mergeMap(function (docs) {
return _ensureEqual(_this2).then(function (hasChanged) {
if (hasChanged) return false; // wait for next emit
else return docs;
});
}), filter(function (docs) {
return !!docs;
function () {
/**
* @param {Integer} appID
*/
function AddRecordsRequest(appID) {
_classCallCheck(this, AddRecordsRequest);
this.app = appID;
this.records = [];
}
/**
* @return {Integer} appID
*/
_createClass(AddRecordsRequest, [{
key: "getAppID",
value: function getAppID() {
return this.app;
}
/**
* Add record item to execute the add multi records function
* @param {Record} record
* @return {this} AddRecordsRequest
*/
}, {
key: "addRecord",
value: function addRecord(record) {
this.records.push(record);
return this;
}
* @param {Integer} revision
*/
function AddFormFieldsRequest(app, fields, revision) {
_classCallCheck(this, AddFormFieldsRequest);
this.app = app;
this.fields = fields;
this.revision = revision;
}
/**
* Get JSON struct of this model
* @return {JSON}
*/
_createClass(AddFormFieldsRequest, [{
key: "toJSON",
value: function toJSON() {
var data = {
app: this.app,
properties: this.fields,
revision: this.revision
};
return data;
}
/**
* Convert this model to JSON string
* @return {String}
*/
}, {
key: "toJSONString",
* @param {String} payload
*/
function BulkRequestItem(method, api, payload) {
_classCallCheck(this, BulkRequestItem);
this.method = method;
this.api = api;
this.payload = payload.toJSON ? payload.toJSON() : payload;
}
/**
* Get JSON struct of this model
* @return {JSON}
*/
_createClass(BulkRequestItem, [{
key: "toJSON",
value: function toJSON() {
return {
method: this.method,
api: this.api,
payload: this.payload
};
}
/**
* Convert this model to JSON string
* @return {String}
*/
}, {
key: "toJSONString",
value: function toJSONString() {
* @param {String} username
* @param {String} password
*/
function Credential(username, password) {
_classCallCheck(this, Credential);
this.username = username;
this.password = password;
}
/**
* Get username of Credential model
* @return {String}
*/
_createClass(Credential, [{
key: "getUsername",
value: function getUsername() {
return this.username;
}
/**
* Get password of Credential model
* @return {String}
*/
}, {
key: "getPassword",
value: function getPassword() {
return this.password;
}
}]);
* @param {Integer} app
* @param {String} lang
*/
function GetViewsRequest(app, lang) {
_classCallCheck(this, GetViewsRequest);
this.app = app;
this.lang = lang;
}
/**
* Get JSON struct of this model
* @return {JSON}
*/
_createClass(GetViewsRequest, [{
key: "toJSON",
value: function toJSON() {
var data = {
app: this.app,
lang: this.lang
};
return data;
}
/**
* Convert this model to JSON string
* @return {String}
*/
}, {
key: "toJSONString",
value: function toJSONString() {
* @param {Integer} app
* @param {String} lang
*/
function GetGeneralSettingsRequest(app, lang) {
_classCallCheck(this, GetGeneralSettingsRequest);
this.app = app;
this.lang = lang;
}
/**
* Get JSON struct of this model
* @return {JSON}
*/
_createClass(GetGeneralSettingsRequest, [{
key: "toJSON",
value: function toJSON() {
var data = {
app: this.app,
lang: this.lang
};
return data;
}
/**
* Convert this model to JSON string
* @return {String}
*/
}, {
key: "toJSONString",
value: function toJSONString() {
_inherits(QueryBuilder, _React$Component);
function QueryBuilder(props) {
var _this;
_classCallCheck(this, QueryBuilder);
_this = _possibleConstructorReturn(this, _getPrototypeOf(QueryBuilder).call(this, props));
_this.state = _objectSpread({
query: props.query,
chartType: 'line'
}, props.vizState);
return _this;
}
_createClass(QueryBuilder, [{
key: "componentDidMount",
value: function () {
var _componentDidMount = _asyncToGenerator(
/*#__PURE__*/
_regeneratorRuntime.mark(function _callee() {
var meta;
return _regeneratorRuntime.wrap(function _callee$(_context) {
while (1) {
switch (_context.prev = _context.next) {
case 0:
_context.next = 2;
return this.cubejsApi().meta();
case 2:
meta = _context.sent;
this.setState({
function () {
function Common() {
_classCallCheck(this, Common);
}
_createClass(Common, [{
key: "sendRequest",
/**
* @param {String} method
* @param {String} url
* @param {RecordModel} model
* @param {Connection} connection
* @return {Promise} Promise
*/
value: function sendRequest(method, url, model, connection) {
var body = model.toJSON ? model.toJSON() : model;
return connection.request(method, url, body).then(function (result) {
return result;
}).catch(function (err) {
throw new KintoneAPIException(err.message, err);
});
function () {
function ProgressResult(progressResponse) {
_classCallCheck(this, ProgressResult);
this.progressResponse = progressResponse;
}
_createClass(ProgressResult, [{
key: "stage",
value: function stage() {
return this.progressResponse.stage;
}
}, {
key: "timeElapsed",
value: function timeElapsed() {
return this.progressResponse.timeElapsed;
}
}]);
return ProgressResult;
}();