1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071 |
- <template>
- <view class="reset" v-if="ctrlModel.funcname">
- <view class="update-line">
- <view class="label">
- {{ ctrlModel.funcname }}
- </view>
- <view
- class="content"
- hover-class="navigator-hover"
- @click="onClick(ctrlModel)"
- >复位
- </view>
- </view>
- <My_input ref="MyInput" />
- </view>
- </template>
- <script>
- export default {
- name: "basics",
- data() {
- return {
- ctrlModel: {},
- };
- },
- methods: {
- onClick() {
- let that = this;
- uni.showModal({
- title: "提示",
- content: "确定复位吗?",
- success: ({ confirm }) => {
- if (confirm) {
- let paramName = that.ctrlModel.paramName;
- for (const key in paramName) {
- paramName[key] = 0;
- }
- that.$refs.MyInput.submit(that.ctrlModel.w_functionid, paramName);
- }
- },
- });
- },
- },
- };
- </script>
- <style lang="scss" scoped>
- .reset {
- margin-bottom: 12px;
- .update-line {
- display: flex;
- justify-content: space-between;
- align-items: center;
- .label {
- font-size: 3.7333333333333vw;
- color: #fff;
- font-weight: bold;
- text-indent: 1.6vw;
- }
- .content {
- background-color: #004a92;
- font-size: 12px;
- padding: 4px 8px;
- border-radius: 4px;
- box-sizing: border-box;
- color: #fff;
- }
- }
- }
- </style>
|