已支付订单列表:where.payStatus = 1;
This commit is contained in:
@@ -0,0 +1,144 @@
|
||||
"use strict";
|
||||
var _a, _b;
|
||||
const common_vendor = require("../../../../common/vendor.js");
|
||||
const props = {
|
||||
props: {
|
||||
value: {
|
||||
type: [String, Number],
|
||||
default: ""
|
||||
},
|
||||
modelValue: {
|
||||
type: [String, Number],
|
||||
default: ""
|
||||
},
|
||||
// 输入框为空时占位符
|
||||
placeholder: {
|
||||
type: [String, Number],
|
||||
default: ""
|
||||
},
|
||||
// 指定placeholder的样式类,注意页面或组件的style中写了scoped时,需要在类名前写/deep/
|
||||
placeholderClass: {
|
||||
type: String,
|
||||
default: "textarea-placeholder"
|
||||
},
|
||||
// 指定placeholder的样式
|
||||
placeholderStyle: {
|
||||
type: [String, Object],
|
||||
default: "color: #c0c4cc"
|
||||
},
|
||||
// 输入框高度
|
||||
height: {
|
||||
type: [String, Number],
|
||||
default: 70
|
||||
},
|
||||
// 设置键盘右下角按钮的文字,仅微信小程序,App-vue和H5有效
|
||||
confirmType: {
|
||||
type: String,
|
||||
default: "return"
|
||||
},
|
||||
// 是否禁用
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// 是否显示统计字数
|
||||
count: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// 是否自动获取焦点,nvue不支持,H5取决于浏览器的实现
|
||||
focus: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// 是否自动增加高度
|
||||
autoHeight: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// 如果textarea是在一个position:fixed的区域,需要显示指定属性fixed为true
|
||||
fixed: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// 指定光标与键盘的距离
|
||||
cursorSpacing: {
|
||||
type: Number,
|
||||
default: 0
|
||||
},
|
||||
// 指定focus时的光标位置
|
||||
cursor: {
|
||||
type: [String, Number],
|
||||
default: ""
|
||||
},
|
||||
// 是否显示键盘上方带有”完成“按钮那一栏,
|
||||
showConfirmBar: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
// 光标起始位置,自动聚焦时有效,需与selection-end搭配使用
|
||||
selectionStart: {
|
||||
type: Number,
|
||||
default: -1
|
||||
},
|
||||
// 光标结束位置,自动聚焦时有效,需与selection-start搭配使用
|
||||
selectionEnd: {
|
||||
type: Number,
|
||||
default: -1
|
||||
},
|
||||
// 键盘弹起时,是否自动上推页面
|
||||
adjustPosition: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
// 是否去掉 iOS 下的默认内边距,只微信小程序有效
|
||||
disableDefaultPadding: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// focus时,点击页面的时候不收起键盘,只微信小程序有效
|
||||
holdKeyboard: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// 最大输入长度,设置为 -1 的时候不限制最大长度
|
||||
maxlength: {
|
||||
type: [String, Number],
|
||||
default: 140
|
||||
},
|
||||
// 边框类型,surround-四周边框,bottom-底部边框
|
||||
border: {
|
||||
type: String,
|
||||
default: "surround"
|
||||
},
|
||||
// 用于处理或者过滤输入框内容的方法
|
||||
formatter: {
|
||||
type: [Function, null],
|
||||
default: null
|
||||
},
|
||||
// 是否忽略组件内对文本合成系统事件的处理
|
||||
ignoreCompositionEvent: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
// 是否忽略组件内对文本合成系统事件的处理
|
||||
confirmHold: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// 文本样式
|
||||
textStyle: {
|
||||
type: [Object, String],
|
||||
default: () => {
|
||||
}
|
||||
},
|
||||
// 统计数字的样式
|
||||
countStyle: {
|
||||
type: [Object, String],
|
||||
default: () => {
|
||||
}
|
||||
},
|
||||
...(_b = (_a = common_vendor.index.$uv) == null ? void 0 : _a.props) == null ? void 0 : _b.textarea
|
||||
}
|
||||
};
|
||||
exports.props = props;
|
||||
+144
@@ -0,0 +1,144 @@
|
||||
"use strict";
|
||||
const uni_modules_uvUiTools_libs_mixin_mpMixin = require("../../../uv-ui-tools/libs/mixin/mpMixin.js");
|
||||
const uni_modules_uvUiTools_libs_mixin_mixin = require("../../../uv-ui-tools/libs/mixin/mixin.js");
|
||||
const uni_modules_uvTextarea_components_uvTextarea_props = require("./props.js");
|
||||
const common_vendor = require("../../../../common/vendor.js");
|
||||
const _sfc_main = {
|
||||
name: "uv-textarea",
|
||||
mixins: [uni_modules_uvUiTools_libs_mixin_mpMixin.mpMixin, uni_modules_uvUiTools_libs_mixin_mixin.mixin, uni_modules_uvTextarea_components_uvTextarea_props.props],
|
||||
data() {
|
||||
return {
|
||||
// 输入框的值
|
||||
innerValue: "",
|
||||
// 是否处于获得焦点状态
|
||||
focused: false,
|
||||
// 过滤处理方法
|
||||
innerFormatter: (value) => value
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.innerValue = this.modelValue;
|
||||
},
|
||||
watch: {
|
||||
value(newVal) {
|
||||
this.innerValue = newVal;
|
||||
},
|
||||
modelValue(newVal) {
|
||||
this.innerValue = newVal;
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
// 组件的类名
|
||||
textareaClass() {
|
||||
let classes = [], { border, disabled } = this;
|
||||
border === "surround" && (classes = classes.concat(["uv-border", "uv-textarea--radius"]));
|
||||
border === "bottom" && (classes = classes.concat(["uv-border-bottom", "uv-textarea--no-radius"]));
|
||||
disabled && classes.push("uv-textarea--disabled");
|
||||
return classes.join(" ");
|
||||
},
|
||||
// 组件的样式
|
||||
textareaStyle() {
|
||||
const style = {};
|
||||
return this.$uv.deepMerge(style, this.$uv.addStyle(this.customStyle));
|
||||
},
|
||||
maxlen() {
|
||||
return this.maxlength < 0 ? this.maxlength < 0 ? -1 : 140 : this.maxlength;
|
||||
},
|
||||
getCount() {
|
||||
try {
|
||||
return this.innerValue.length > this.maxlen ? this.maxlen : this.innerValue.length;
|
||||
} catch (e) {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 在微信小程序中,不支持将函数当做props参数,故只能通过ref形式调用
|
||||
setFormatter(e) {
|
||||
this.innerFormatter = e;
|
||||
},
|
||||
onFocus(e) {
|
||||
this.$emit("focus", e);
|
||||
},
|
||||
onBlur(e) {
|
||||
this.$emit("blur", e);
|
||||
this.$uv.formValidate(this, "blur");
|
||||
},
|
||||
onLinechange(e) {
|
||||
this.$emit("linechange", e);
|
||||
},
|
||||
onInput(e) {
|
||||
let { value = "" } = e.detail || {};
|
||||
const formatter = this.formatter || this.innerFormatter;
|
||||
const formatValue = formatter(value);
|
||||
this.innerValue = value;
|
||||
this.$nextTick(() => {
|
||||
this.innerValue = formatValue;
|
||||
this.valueChange();
|
||||
});
|
||||
},
|
||||
// 内容发生变化,进行处理
|
||||
valueChange() {
|
||||
const value = this.innerValue;
|
||||
this.$nextTick(() => {
|
||||
this.$emit("input", value);
|
||||
this.$emit("update:modelValue", value);
|
||||
this.$emit("change", value);
|
||||
this.$uv.formValidate(this, "change");
|
||||
});
|
||||
},
|
||||
onConfirm(e) {
|
||||
this.$emit("confirm", e);
|
||||
},
|
||||
onKeyboardheightchange(e) {
|
||||
this.$emit("keyboardheightchange", e);
|
||||
}
|
||||
}
|
||||
};
|
||||
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
return common_vendor.e({
|
||||
a: $data.innerValue,
|
||||
b: common_vendor.s({
|
||||
height: _ctx.autoHeight ? "auto" : _ctx.$uv.addUnit(_ctx.height)
|
||||
}),
|
||||
c: common_vendor.s(_ctx.$uv.addStyle(_ctx.textStyle)),
|
||||
d: _ctx.placeholder,
|
||||
e: _ctx.$uv.addStyle(_ctx.placeholderStyle, "string"),
|
||||
f: _ctx.placeholderClass,
|
||||
g: _ctx.disabled,
|
||||
h: _ctx.focus,
|
||||
i: _ctx.autoHeight,
|
||||
j: _ctx.fixed,
|
||||
k: _ctx.cursorSpacing,
|
||||
l: _ctx.cursor,
|
||||
m: _ctx.showConfirmBar,
|
||||
n: _ctx.selectionStart,
|
||||
o: _ctx.selectionEnd,
|
||||
p: _ctx.adjustPosition,
|
||||
q: _ctx.disableDefaultPadding,
|
||||
r: _ctx.holdKeyboard,
|
||||
s: $options.maxlen,
|
||||
t: _ctx.confirmType,
|
||||
v: _ctx.ignoreCompositionEvent,
|
||||
w: _ctx.confirmHold,
|
||||
x: common_vendor.o((...args) => $options.onFocus && $options.onFocus(...args)),
|
||||
y: common_vendor.o((...args) => $options.onBlur && $options.onBlur(...args)),
|
||||
z: common_vendor.o((...args) => $options.onLinechange && $options.onLinechange(...args)),
|
||||
A: common_vendor.o((...args) => $options.onInput && $options.onInput(...args)),
|
||||
B: common_vendor.o((...args) => $options.onConfirm && $options.onConfirm(...args)),
|
||||
C: common_vendor.o((...args) => $options.onKeyboardheightchange && $options.onKeyboardheightchange(...args)),
|
||||
D: _ctx.count && $options.maxlen != -1
|
||||
}, _ctx.count && $options.maxlen != -1 ? {
|
||||
E: common_vendor.t($options.getCount),
|
||||
F: common_vendor.t($options.maxlen),
|
||||
G: common_vendor.s({
|
||||
"background-color": _ctx.disabled ? "transparent" : "#fff"
|
||||
}),
|
||||
H: common_vendor.s(_ctx.$uv.addStyle(_ctx.countStyle))
|
||||
} : {}, {
|
||||
I: common_vendor.n($options.textareaClass),
|
||||
J: common_vendor.s($options.textareaStyle)
|
||||
});
|
||||
}
|
||||
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-bd7341c1"], ["__file", "/Users/gxwebsoft/APP/gxtyzx-uniapp-cli/src/uni_modules/uv-textarea/components/uv-textarea/uv-textarea.vue"]]);
|
||||
wx.createComponent(Component);
|
||||
+4
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
+1
@@ -0,0 +1 @@
|
||||
<view class="{{['uv-textarea', 'data-v-bd7341c1', I]}}" style="{{J}}"><block wx:if="{{r0}}"><textarea class="uv-textarea__field data-v-bd7341c1" value="{{a}}" style="{{b + ';' + c}}" placeholder="{{d}}" placeholder-style="{{e}}" placeholder-class="{{f}}" disabled="{{g}}" focus="{{h}}" autoHeight="{{i}}" fixed="{{j}}" cursorSpacing="{{k}}" cursor="{{l}}" showConfirmBar="{{m}}" selectionStart="{{n}}" selectionEnd="{{o}}" adjustPosition="{{p}}" disableDefaultPadding="{{q}}" holdKeyboard="{{r}}" maxlength="{{s}}" confirmType="{{t}}" ignoreCompositionEvent="{{v}}" confirm-hold="{{w}}" bindfocus="{{x}}" bindblur="{{y}}" bindlinechange="{{z}}" bindinput="{{A}}" bindconfirm="{{B}}" bindkeyboardheightchange="{{C}}"></textarea></block><text wx:if="{{D}}" class="uv-textarea__count data-v-bd7341c1" style="{{G + ';' + H}}">{{E}}/{{F}}</text></view>
|
||||
+77
@@ -0,0 +1,77 @@
|
||||
/**
|
||||
* 这里是uni-app内置的常用样式变量
|
||||
*
|
||||
* uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量
|
||||
* 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能
|
||||
*
|
||||
* 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件
|
||||
*/
|
||||
/* 颜色变量 */
|
||||
/* 行为相关颜色 */
|
||||
/* 文字基本颜色 */
|
||||
/* 背景颜色 */
|
||||
/* 边框颜色 */
|
||||
/* 尺寸变量 */
|
||||
/* 文字尺寸 */
|
||||
/* 图片尺寸 */
|
||||
/* Border Radius */
|
||||
/* 水平间距 */
|
||||
/* 垂直间距 */
|
||||
/* 透明度 */
|
||||
/* 文章场景相关 */
|
||||
.uv-border.data-v-bd7341c1 {
|
||||
border-width: 0.5px !important;
|
||||
border-color: #dadbde !important;
|
||||
border-style: solid;
|
||||
}
|
||||
.uv-border-bottom.data-v-bd7341c1 {
|
||||
border-bottom-width: 0.5px !important;
|
||||
border-color: #dadbde !important;
|
||||
border-bottom-style: solid;
|
||||
}
|
||||
view.data-v-bd7341c1, scroll-view.data-v-bd7341c1, swiper-item.data-v-bd7341c1 {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex-shrink: 0;
|
||||
flex-grow: 0;
|
||||
flex-basis: auto;
|
||||
align-items: stretch;
|
||||
align-content: flex-start;
|
||||
}
|
||||
.uv-textarea.data-v-bd7341c1 {
|
||||
border-radius: 4px;
|
||||
background-color: #fff;
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
flex: 1;
|
||||
padding: 9px;
|
||||
}
|
||||
.uv-textarea--radius.data-v-bd7341c1 {
|
||||
border-radius: 4px;
|
||||
}
|
||||
.uv-textarea--no-radius.data-v-bd7341c1 {
|
||||
border-radius: 0;
|
||||
}
|
||||
.uv-textarea--disabled.data-v-bd7341c1 {
|
||||
background-color: #f5f7fa;
|
||||
}
|
||||
.uv-textarea__field.data-v-bd7341c1 {
|
||||
flex: 1;
|
||||
font-size: 15px;
|
||||
color: #606266;
|
||||
width: 100%;
|
||||
}
|
||||
.uv-textarea__count.data-v-bd7341c1 {
|
||||
position: absolute;
|
||||
right: 5px;
|
||||
bottom: 2px;
|
||||
font-size: 12px;
|
||||
color: #909193;
|
||||
background-color: #ffffff;
|
||||
padding: 1px 4px;
|
||||
}
|
||||
Reference in New Issue
Block a user