首次提交

This commit is contained in:
何江明
2025-02-28 16:19:58 +08:00
commit 15014e22aa
92 changed files with 15941 additions and 0 deletions
+42
View File
@@ -0,0 +1,42 @@
"use strict";
const common_vendor = require("../../common/vendor.js");
const collection = "hello";
const _sfc_main = {
data() {
return {
name: ""
};
},
methods: {
add() {
common_vendor.index.showLoading();
let db = common_vendor.er.database();
db.collection(collection).add({
name: this.name
}).then((res) => {
common_vendor.index.showToast({
title: this.$t("schema.add-success")
});
}).catch((err) => {
common_vendor.index.showModal({
content: err.message,
showCancel: false
});
}).finally(() => {
common_vendor.index.hideLoading();
});
}
}
};
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
return {
a: common_vendor.t(_ctx.$t("schema.name")),
b: $data.name,
c: common_vendor.o(($event) => $data.name = $event.detail.value),
d: common_vendor.t(_ctx.$t("schema.add")),
e: common_vendor.o((...args) => $options.add && $options.add(...args))
};
}
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
wx.createPage(MiniProgramPage);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/schema/schema.js.map
+5
View File
@@ -0,0 +1,5 @@
{
"navigationBarTitleText": "Schema",
"enablePullDownRefresh": false,
"usingComponents": {}
}
+1
View File
@@ -0,0 +1 @@
<view class="container"><view>{{a}}</view><input class="input" value="{{b}}" bindinput="{{c}}"/><button type="primary" bindtap="{{e}}">{{d}}</button></view>
+8
View File
@@ -0,0 +1,8 @@
.input {
border: 1px solid #ebebeb;
border-radius: 3px;
margin-top: 15px;
margin-bottom: 15px;
padding: 8px;
}